Skip to main content

A context-aware AI agent that turns data goals into investigation paths, powered by DataHub.

Project description

SAINT — Context-Aware Path to Insight

"People don't need more information. They need help discovering which information matters, why it matters, and what to do with it."

PyPI License: Apache 2.0 Python 3.11+ Built with DataHub Hackathon


SAINT is an AI agent that turns user goals into contextual paths — grounded in your organization's actual DataHub metadata. It reads your data catalog, reasons about what you need to understand, walks you through a structured investigation, and writes the result back to DataHub so the next person inherits your knowledge.

It is not a chatbot. It is not a search tool. It is a goal-driven agent that uses DataHub's context graph to figure out what you need to do next.


How It Works

You give Saint a goal
        ↓
Saint interprets your intent
        ↓
You confirm the interpretation
        ↓
Saint reads your DataHub context graph
(schemas, lineage, ownership, quality, glossary)
        ↓
Saint builds a Contextual Path
(ordered steps grounded in real assets)
        ↓
You explore, learn, or act
        ↓
Saint synthesizes the final outcome
        ↓
You publish the investigation to DataHub
(so the next person or agent inherits your knowledge)

This is the key loop that DataHub's context graph makes possible. Without real metadata, every step would be generic advice. With DataHub, the path reflects the actual data environment around your goal.


Quick Start

No DataHub, no Docker, no credentials required to try:

Option A — Install from PyPI (easiest):

pip install saint-datahub
saint demo

Option B — Install from source:

git clone https://github.com/einzeinn/saint.git
cd saint
python -m venv .venv

# macOS / Linux
source .venv/bin/activate

# Windows (PowerShell)
.\.venv\Scripts\Activate.ps1

pip install -e .
saint demo

saint demo runs a complete, deterministic investigation journey using built-in sample context. No tokens, no configuration, nothing to break.


Modes

Command What it does Requires DataHub?
saint demo Full guided walkthrough with built-in sample context No
saint demo --live Same journey, but using your real DataHub connection Yes
saint Interactive menu — Learn, Explore, or Solve Optional
saint solve Hypothesis testing mode against DataHub evidence Optional
saint doctor Diagnose your DataHub and LLM configuration Optional
saint init Configure your DataHub connection

What SAINT Does That DataHub Doesn't

DataHub is a metadata platform. SAINT is a goal-oriented agent that uses that platform to help you answer questions you didn't know how to ask.

Capability DataHub Catalog SAINT
Browse assets ✅ (via context graph)
Search metadata ✅ (via Agent Context Kit)
Interpret user goals
Build a contextual investigation path
Synthesize findings from evidence
Write structured outcomes back to catalog ✅ (publish_result)
Ground reasoning in real lineage/ownership

Architecture

┌────────────────────────────────┐
│             CLI                │
│  saint / saint demo / solve    │
└─────────────┬──────────────────┘
              │
┌─────────────▼──────────────────┐
│         Orchestrator           │
│  interpret → path → synthesize │
│  → assess → publish            │
└──────┬──────────────┬──────────┘
       │              │
┌──────▼──────┐ ┌─────▼────────┐
│ LLM Adapter │ │ DataHub      │
│ (Groq /     │ │ Adapter      │
│  Gemini)    │ │ (Agent Ctx / │
└─────────────┘ │  Mock)       │
                └──────┬───────┘
                       │
                ┌──────▼───────┐
                │   DataHub    │
                │  Context     │
                │  Graph       │
                └──────────────┘

Key modules:


DataHub Integration

SAINT uses DataHub's Agent Context Kit (datahub-agent-context) as its primary integration. It does not require an MCP server to run.

saint[agent-context]
    ↓
datahub_agent_context SDK
    ↓
DataHub GMS (REST)
    ↓
Context graph: schemas, lineage, ownership, quality, domains

Read operations (via search_entities, get_entity_relationships, get_lineage):

  • Schema and field-level metadata
  • Upstream/downstream lineage
  • Asset ownership and domain membership
  • Data quality signals

Write operations (via save_document):

  • Investigation summaries published as DataHub Documents
  • Related assets linked by entity-level URN
  • Tagged with saint-analysis and intent topic

Connected Mode (Optional)

pip install "saint-datahub[agent-context]"

Set environment variables:

DATAHUB_PROVIDER=agent_context
DATAHUB_GMS_URL=http://localhost:8080
DATAHUB_GMS_TOKEN=<personal-access-token>

Then run:

saint demo --live   # Full demo with your real DataHub data
saint               # Interactive mode

saint doctor will confirm your connection is healthy before you start.


Sample Output

See examples/ for example investigation outputs, including a published DataHub Document from a real saint solve session.


Project Structure

backend/
  app/
    cli.py                  # Terminal UI — all modes
    orchestration/          # SaintOrchestrator — core agent logic
    adapters/               # DataHub + LLM adapters
    domain/                 # Pydantic models (GoalRequest, ContextualPath, etc.)
    config.py               # Settings (pydantic-settings, .env)
docs/
  RFC/                      # Technical RFCs (including RFC-003: DataHub write-back)
  Architecture.md
  Hackathon.md
  JudgeSetup.md
skills/
  saint_investigator.py     # DataHub Skill entry-point
tests/
  test_datahub_integration.py
  test_health.py

For Hackathon Judges

See docs/JudgeSetup.md for the reproducible judge setup. The one-line quickstart:

pip install -e . && saint demo

No DataHub instance, no API key, no Docker. The demo runs a complete investigation journey with deterministic built-in context, ending with a simulated publish preview that shows exactly what would be written back to DataHub.

If you have a DataHub instance running locally, see docs/JudgeSetup.md for the connected mode setup.


Compatibility API

A FastAPI surface is available for existing integrations:

uvicorn backend.app.main:app --reload
# → http://127.0.0.1:8000/health

This is a secondary surface; the primary product is the CLI.


License

Apache 2.0 — open source and free to use, modify, and distribute.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

saint_datahub-0.1.0.tar.gz (50.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

saint_datahub-0.1.0-py3-none-any.whl (45.4 kB view details)

Uploaded Python 3

File details

Details for the file saint_datahub-0.1.0.tar.gz.

File metadata

  • Download URL: saint_datahub-0.1.0.tar.gz
  • Upload date:
  • Size: 50.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.14.4

File hashes

Hashes for saint_datahub-0.1.0.tar.gz
Algorithm Hash digest
SHA256 3d25733a3c2dbe7918b84b35b0fa20fb65f7b73eebc49c0e943a81b6f3c8b5d7
MD5 0526f1a3a334b73f16ce90ce4bf7acca
BLAKE2b-256 da71cb0290975755e6b1ef434c9b3fc82fb3fd39c1a8c960903932409624fb4d

See more details on using hashes here.

File details

Details for the file saint_datahub-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: saint_datahub-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 45.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.14.4

File hashes

Hashes for saint_datahub-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7e4a7a81c84e96728969af5eca22ec66db563d905de1a626ee377ccca5493a54
MD5 6c30f4bb7798ea687f8c2dfa1603d2eb
BLAKE2b-256 98c97e51ece253195888f112512e30068b5d4ad39446be80f30424c0d5838420

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page