alexanderatallah / window.ai

Use your own AI models on the web
https://windowai.io
MIT License
806 stars 70 forks source link

Allow user to configure multiple local / custom models #14

Closed handrew closed 1 year ago

handrew commented 1 year ago

Would be cool to allow users to specify multiple custom endpoints (local, hosted, or otherwise) which Window apps could then call separately and potentially chain together.

alexanderatallah commented 1 year ago

The second option actually strikes me as a bit simpler, and more consistent with the way external apis (like OpenAI) work. a model param could be sent to the local model (very easy to change), and an api there does the routing to the right model, avoiding the need to clutter your system's ports if you don't want to.

Will post up a starter PR to illustrate this idea, since it makes local more consistent with the rest anyway.

handrew commented 1 year ago

Yeah happy to take direction here, but then the worry is that the user has to do a bunch of bespoke routing themselves / the interface at the API level becomes nonstandard relative to the other endpoints Window developers might expect.

Also happy to make changes to the local hugging face Flask API once you make it possible to get a model param.