Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add support for other base urls, gpt 16k #84

Closed
wants to merge 4 commits into from

Conversation

alexkreidler
Copy link

Motivation

This allows people to use OpenAI-compatible models like LocalAI, and closes #82. Or it allows people to use their own openai proxy for api key safety or observability, or LLMOps products like Helicone or Portkey (although these services need you to pass additional headers; maybe that's the next thing to add).

Solution

Adds an API Base URL field to the settings page. I removed the API key modal because it seemed like duplicating functionality that's already in the settings modal. I do get the argument for simplicity, so maybe we could rework the settings modal UI e.g. hide extra options under a dropdown. I also put both the API key and base URL state in the same settings localStorage JSON object. I updated openai-streams package to fix typescript errors on the apiBase property. Also added a few missing dependencies that caused pnpm to fail.

Checklist

  • Tested in Chrome
  • Tested in Safari

also updated openai-streams package to fix typescript errors with apiBase
@vercel
Copy link

vercel bot commented Jun 14, 2023

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

Name Status Preview Updated (UTC)
flux ✅ Ready (Inspect) Visit Preview Jun 18, 2023 9:25pm

@transmissions11
Copy link
Member

transmissions11 commented Jun 14, 2023

nice this looks good! can you get it to build on vercel tho 😅 also i'd like to stick with npm vs pnpm here if possible

I removed the API key modal because it seemed like duplicating functionality that's already in the settings modal.

i felt the API key modal was important for the first time users interact w/ the app as otherwise they have no idea they need to enter anything and will just be annoyed their requests are failing?

@alexkreidler
Copy link
Author

alexkreidler commented Jun 14, 2023

I have the settings modal open when no API key is set so that first time users are prompted to put in their info.

I got rid of the pnpm lockfile, but that hasn't fixed the Vercel build. I don't have access to the logs, so maybe @transmissions11 could you paste them here? Or maybe make this repo public on Vercel?

@transmissions11
Copy link
Member

whoops my bad didn't know you couldn't see logs, here ya go:

Screenshot 2023-06-15 at 6 27 39 AM

@alexkreidler
Copy link
Author

@transmissions11 I've fixed the build and merged. I'd be happy to make any other changes- I think this will be a great feature to have on flux.paradigm.xyz!

@transmissions11
Copy link
Member

transmissions11 commented Jun 28, 2023

can you add the api key modal back as well?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: Local Model Compatibility
2 participants