← Back to archive

Repo of the Day

agno-agi/dash: A self-learning data agent built with systems engineering principles. It grounds answers in 6 layers of context and improves with every query.

Published: Aug 30, 2026

Open repository ↗

A self-learning data agent built with systems engineering principles. It grounds answers in 6 layers of context and improves with every query. - agno-agi/dash

Summary

Dash is a self-learning text-to-SQL data agent built on Agno that answers natural-language questions against a database by grounding responses in six layers of context: table metadata, business annotations, query patterns, institutional knowledge, error learnings, and runtime schema. A two-agent team (an Analyst with read-only SQL access and an Engineer that writes to a separate dash schema) is coordinated by a leader, so validated queries and learned error fixes persist between sessions.

What it is useful for

Dash targets the failure modes of raw LLM-to-SQL: schemas that lack meaning, misleading types, missing tribal knowledge, and no way to recover from repeated mistakes. Concrete uses the README calls out:

  • Letting non-engineers query a synthetic B2B SaaS dataset (customers, subscriptions, MRR, churn, usage, support tickets) via CLI, the AgentOS web UI, or Slack DMs and thread replies.
  • Repurposing the architecture for a domain-specific text-to-SQL agent by replacing the bundled SaaS data and knowledge/*.json files with your own table metadata, SQL patterns, and metric definitions.
  • Running the bundled evals (python -m evals) across accuracy, routing, security, governance, and schema-boundary categories to check that the agent stays in its lane and refuses destructive writes.
  • Studying the dual-schema pattern: public is company-owned and read-only at the PostgreSQL level (default_transaction_read_only=on), while dash is where the Engineer builds reusable assets like monthly_mrr or customer_health_score that the Analyst prefers over raw tables.

How engineers can use it

The README documents a Docker Compose path for local development and a Railway path for production. Local setup:

git clone https://github.com/agno-agi/dash.git && cd dash
cp example.env .env
# add OPENAI_API_KEY
docker compose up -d --build
docker exec -it dash-api python scripts/generate_data.py
docker exec -it dash-api python scripts/load_knowledge.py

The API is then served at http://localhost:8000/docs. For iteration without Docker, the README lists ./scripts/venv_setup.sh, then python -m dash (CLI) or python -m app.main (web UI). Knowledge is file-based JSON/SQL in knowledge/tables/, knowledge/queries/, and knowledge/business/; reload with python scripts/load_knowledge.py (or --recreate to reset).

Documented constraints: OPENAI_API_KEY is required and no alternative provider is configured in the supplied material. Production requires JWT_VERIFICATION_KEY from AgentOS or all endpoints reject requests; local dev uses RUNTIME_ENV=dev with no auth. Read-only and schema boundaries are enforced by the database and SQLAlchemy, not by prompts. Slack needs SLACK_TOKEN and SLACK_SIGNING_SECRET plus a public URL, with full setup in docs/SLACK_CONNECT.md.