like-gold
like-goldβ€’5w ago

Python Example "SQL_Agent" not working

Hey! First of all a huge fan of composio's work and I have just started to test out all the local tools and examples available on composio. I cloned the repo, setup the Virtual env and then went through the required steps written in README.md for sql-agent python example. Did everything as stated, entered the API key. But I got the output as shown in the image attached. I tried debugging it by placing print statements inside of the sqltool python local-tool, and it seems that the execute() method for SQLQuery class (in file sql_query.py) does not seem to be called itself. Is it just me or is it a known issue? Would really appreciate your help 😁
No description
20 Replies
Soham
Sohamβ€’5w ago
can you try doing composio apps update Does that solve issue for you?
like-gold
like-goldβ€’5w ago
let me try, one moment please
like-gold
like-goldβ€’5w ago
The same thing πŸ˜…
No description
Soham
Sohamβ€’5w ago
ok one more thing. pip install composio-core -U does this help?
like-gold
like-goldβ€’5w ago
one moment please
like-gold
like-goldβ€’5w ago
same thing πŸ˜…
No description
Soham
Sohamβ€’5w ago
interesting. And what's the framework you are using? ok crewai. So two things pip install composio-crewai -U composio apps update your crewai version is older, I can see in screenshot. so may be this should solve.
like-gold
like-goldβ€’5w ago
oh okay, I will do that, one moment
like-gold
like-goldβ€’5w ago
I updated crewAI and ran composio apps update Now i get this error
No description
Soham
Sohamβ€’5w ago
This is openai error. You can try different models if you don't have access to gpt-4o. may be gpt-4-turbo?
like-gold
like-goldβ€’5w ago
okay, let me try that its the same error tried it with gpt-4, gpt-4-turbo and gpt-4o
Soham
Sohamβ€’5w ago
Were you able to use openai key independently?
like-gold
like-goldβ€’5w ago
sorry, I dont follow, what do you mean by using openai key independently? I generated the api key in openai and then put it in the .env file explicitly. Is that what you are asking?
Soham
Sohamβ€’5w ago
yes exactly. https://platform.openai.com/playground/chat?models=gpt-4o Can you click on this link and try a model here. If it works you have access to the model.
like-gold
like-goldβ€’5w ago
I have these models available
No description