https://github.com/tomasonjo-labs/text2cypher_llama_agent
A collection of LlamaIndex Workflows-powered agents that convert natural language to Cypher queries designed to retrieve information from a Neo4j database to answer the question with included benchmark data.
https://github.com/tomasonjo-labs/text2cypher_llama_agent
graph graphrag llamaindex llm neo4j workflows
Last synced: 3 months ago
JSON representation
A collection of LlamaIndex Workflows-powered agents that convert natural language to Cypher queries designed to retrieve information from a Neo4j database to answer the question with included benchmark data.
- Host: GitHub
- URL: https://github.com/tomasonjo-labs/text2cypher_llama_agent
- Owner: tomasonjo-labs
- License: mit
- Created: 2024-12-12T11:28:32.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2025-02-16T13:41:43.000Z (5 months ago)
- Last Synced: 2025-04-09T15:01:13.674Z (3 months ago)
- Topics: graph, graphrag, llamaindex, llm, neo4j, workflows
- Language: Jupyter Notebook
- Homepage: https://text2cypher-llama-agent.up.railway.app
- Size: 497 KB
- Stars: 75
- Watchers: 3
- Forks: 17
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Text2Cypher LLama Agents
A collection of LlamaIndex Workflows-powered agents that convert natural language to Cypher queries designed to retrieve information from a Neo4j database to answer the question.
Hosted web application is available [here](https://text2cypher-llama-agent.up.railway.app/).
## 🎯 Features
- Multiple text2Cypher agents
- Built-in benchmarking suite
- Interactive web UI for testing
- Powered by LlamaIndex Workflows## 🚀 Getting Started with web UI
### Prerequisites
1. Create `.env` file based on `.env.example`
```
cp .env.example .env
```
2. Edit `.env` and include your `OPENAI_API_KEY` (or at least one api key from available options).Available API key options:
- `OPENAI_API_KEY`
- `GOOGLE_API_KEY`
- `ANTHROPIC_API_KEY`
- `MISTRAL_API_KEY`
- `DEEPSEEK_API_KEY`### Installation
1. Install `uv` package manager:
```bash
curl -LsSf https://astral.sh/uv/install.sh | sh
```
2. Install dependencies:
```bash
uv sync
```### Run Development Server
Start the FastAPI server:
```bash
uv run fastapi dev
```Open the `localhost:8000`
## 📊 Benchmarking
The `benchmark` directory contains:
- Test datasets
- Evaluation notebooks using RagasThe benchmark can be evaluated against the `recommendations` database.
```
URI: neo4j+s://demo.neo4jlabs.com
username: recommendations
password: recommendations
database: recommendations
```## 🤝 Contributing
Contributions are welcome! Please feel free to submit a Pull Request.