-
Notifications
You must be signed in to change notification settings - Fork 91
Open
Labels
type: bugSomething isn't workingSomething isn't working
Description
I don't know if this is expected behavior, but I have to call load_dotenv() otherwise I get this:
result.result.UnwrapError: Called Result.unwrap()on anErr value: "Missing API key 'OPENAI_API_KEY' in environment"
Repro:
Follow the pydata demo steps.
- Put .env in working directory
- run this
from aiconfig import AIConfigRuntime, InferenceOptions
import asyncio
config = AIConfigRuntime.load("pydata.aiconfig.yaml")
inference_options = InferenceOptions(stream=True)
async def main():
query_question = input()
print("thinking...")
await config.run("sql-generator", params = {"function" : query_question}, options=inference_options)
print("done")
if __name__=="__main__":
asyncio.run(main())
cc @saqadri , @Ankush-lastmile , @rossdanlm
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
type: bugSomething isn't workingSomething isn't working