shroominic / codeinterpreter-api

👾 Open source implementation of the ChatGPT Code Interpreter
https://discord.gg/Vaq25XJvvW
MIT License
3.8k stars 405 forks source link

Use Additional Tools #91

Open sankethgadadinni opened 1 year ago

sankethgadadinni commented 1 year ago

async with CodeInterpreterSession(llm=llm, tools = [SimulatorTool()]) as session:

print("Code Interpreter Session started.")
prompt = '''
Simulate the sales, if unemployment_rate is 5.5, and fed_rate is 0.8? '''
user_request = prompt
files = [
File.from_path("/content/Final_Financial_Data_v2.csv"),]

response = await session.generate_response(user_request, files=files)

print(response)

why is the additional tools list is still empty even though I'm sending a tool here.
YiruMu commented 1 year ago

I used additional_tools = [MyTool()] and it worked for me