Datrics Text-to-SQL engine designed to understand databases effortlessly, turning plain English into accurate SQL queries. Our solution emphasizes advanced Retrieval-Augmented Generation (RAG) techniques rather than simply providing frameworks for developers to fine-tune models themselves and can work out-of-the-box.
-
Semantic Layer: We leverage your database documentation and examples, extracting meaningful concepts to enhance precision.
-
Smart Example Matching: While other solutions struggle with unseen tables, our advanced search and reranking capabilities intelligently generalize from similar examples, ensuring reliable query generation.
-
Instant Documentation: Connect your database and instantly generate detailed documentation—no manual effort required.
-
Flexible AI Integration: Easily integrate with existing LLMs for enhanced, customized performance.
Text2SQL agent uses chromadb to store vector embeddings and it relies on OpenAI Embeddings function Support for other LLMs and Vector DBs is coming soon.
python >= 3.11 docker for running local test database
python3 -m venv .venv
source .venv/bin/activate
pip install .
- open
descriptors/default/t2sql_descriptor.json
with any text editor - set litellm settings to router_model_list
docker-compose up -d
streamlit run main.py
In the app: open "Documentation" tab and click on "Run schema indexing" - this will create the semantic layer of the database You can start asking question right after it's finished.
open descriptors/default/t2sql_descriptor.json with any text editor set access to your database "db" object in case if you needd to use ssh tunnel, add ssh_tunnel to your descriptor:
"ssh_tunnel": {
"username": "",
"private_key_path": "",
}
You can provide the documentation in the "documentation" tab or click on "Run schema indexing" - this will create the semantic layer of the database.
You can start using app just right after that.
- Tetyana Hladkykh: FireFlyTy (@FireFlyTy)
- Kirill Kirikov: kkirikov (@kkirikov)
Contact sales@datrics.ai
Contact kk@datrics.ai