Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/enumera8or/react-sql-agent
ReAct SQL Agent implemented with Langchain, pydantic, openai, gorq & python.
https://github.com/enumera8or/react-sql-agent
gorq jupyter-notebook langchain openai pydantic python sql sqlite3
Last synced: 12 days ago
JSON representation
ReAct SQL Agent implemented with Langchain, pydantic, openai, gorq & python.
- Host: GitHub
- URL: https://github.com/enumera8or/react-sql-agent
- Owner: ENUMERA8OR
- Created: 2024-12-02T16:49:48.000Z (about 1 month ago)
- Default Branch: main2
- Last Pushed: 2024-12-03T08:12:58.000Z (about 1 month ago)
- Last Synced: 2024-12-22T15:14:52.241Z (12 days ago)
- Topics: gorq, jupyter-notebook, langchain, openai, pydantic, python, sql, sqlite3
- Homepage:
- Size: 304 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ReAct-SQL-Agent
This is intended to be a proof of concept for a ReAct Agent that works in text to sql scenario.
For the code in React SQL Agent, it is without memory. I have tested it with the following groq models:
| Model | Performance | Details |
|-------|-------------|---------|
| llama-3.1-70b-versatile | Success | Got answer in 10 iterations |
| llama3-70b-8192 | Success | Got answer in 5 iterations |
| llama3-8b-8192 | Partial | Partial answer |
| gemma2-9b-it | Partial | Partial answer, couldn't extract year of joining |
| mixtral-8x7b-32768 | Failure | No answer |
| llama-3.1-8b-instant | Failure | No answer |
| gemma-7b-it | Failure | No answer |
| distil-whisper-large-v3-en | Failure | Doesn't support chat completions |
| llama-3.2-1b-preview | Failure | Got stuck in Agent Executor chain, no answer |I had also tested it with Openai's gpt-4o, it worked flawlessly. You can also pass the parameter max_execution_time=10, when you are testing with Openai models, as they have no problem with it. But be aware that, when you pass the same parameter when you are using Groq's models you will get Agent terminated due to limit or iteration time error, use them without this parameter.
# ReAct SQL Agent with Memory
For ReAct SQL Agent with memory, I had tested them with groq models, but the best groq model currently llama 3:70b & its flavours couldn't detect the memory even if it was in the execution chain(agent executor). I will upload a version that works with them soon.
# ENVIRONMENT DEPENDENCIES:
## LANGCHAIN=0.3.0
## PYDANTIC=2.9.2
## PYTHON=3.10.15