functime-org / functime

Time-series machine learning at scale. Built with Polars for embarrassingly parallel feature extraction and forecasts on panel data.
https://docs.functime.ai
Apache License 2.0
1.02k stars 55 forks source link

fix: update api call to current openai python format #128

Closed TomBurdge closed 10 months ago

TomBurdge commented 10 months ago

The way to call the OpenAI python API has changed since the original functime LLM code was written.

If you try to use LLM now, it does nothing and says that you need to downgrade your version of the openai library to use the library. We could alternatively enforce that the functime[llm] addon has a compatible version of openai, but I don't think it is desirable to keep an outdated version of the library when upgrading the code is so easy.

I have made some changes which fix the issue. These are fairly superficial.

I haven't written any tests for this, which would need some good mocks, etc. I 'tested' this by running the llm.iypnb notebook. This is fixing breaking issues.

vercel[bot] commented 10 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
functime-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 29, 2023 4:20pm