-
Notifications
You must be signed in to change notification settings - Fork 19
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
Update API endpoints #50
Comments
I can plink away this weekend as well, maybe we can create a branch for every item listed to reduce stepping on toes |
Btw I’ll tackle gpt-4 vision first! Also, I forgot to add the finetuning API - I’ll add that to the list. |
A few updates from my end, the functionality I've tried so far does not require any changes to the Vision comprehension(not image generation)
Notice the array in the "content" key. I propose no action here (but some examples in the docs would be probably useful for newcomers!) JSON modeNice utility to enforce JSON output format. You can use the prompt when you need some exact keys/information.
Seed model parameterSeed parameter should enhance reproducibility (it's not perfect but it goes much further than just
Function callingAsk for structured output that matches your required schema (advantage over "JSON mode"), but there is little bit of extra latency, because of it. It's super useful for data extraction - I use it often for mini-extraction tasks. Note: Supported already by the previous GPT 3.5 Turbo and GPT 4, but not available in the GPT4V model.
To get the arguments only (useful for extraction of data):
Logprobs model parameterAdding EDIT: The specs for function calling have changed! Now it should be referred to as tools. |
Catching up after having no time the past week.. As far as JSON mode, what do you think of this? It seems to be at least tangentially related. BTW, I'm all ears (and approvals 😆 ) on improvements, nicer interfaces, etc. from power users like yourself. I favor a laissez-faire approach in these initial stages, so feel free to open PRs and we can discuss. |
I’ve commented on the above mentioned thread. I personally know very little about the streaming use case - everything I do doesn’t need it. I’m familiar with it only for the ChatGPT-like interfaces. As far as the nicer interfaces go, I am not sure I have any ideas. I think what you’ve done is actually great and allows everyone who wants to build on top of OpenAI API to get started. Based on my experience and talking to a few people, I think the issue now is awareness and how-tos. IMO, we need to focus on surfacing practical applications and lowering the barrier to entry for first time users, eg, examples, blogs, and potentially also some downstream libraries that can be very opinionated and focus on specific tasks. That’s why I have bundled up bunch of scripts I had and wrapped them in a library: PromptingTools.jl. The hope is to abstract and re-use prompts and be backend-agnostic (eg, switch between Open AI API or Mistral depending on your needs/tasks). I’m targeting the daily “mini-tasks” that we all have and don’t enjoy. You’ll see that some of the Issues I opened today reflect the above beliefs. I’m keen to add the above APIs, but I don’t have any mini-tasks that need them right now, so I might not get to it for 1-2 weeks. |
Agreed on documentation and lowering the barrier to entry, I updated the readme yesterday with an example of overriding the base URL. I'm starting on the Files item above, then Finetuning because the latter is dependent on the former. |
#57 tackles the assistant stuff. I'll leave the file stuff out of that PR until the Files API is implemented. |
It would be excellent to add the newly available API endpoints and capabilities that have been announced today, eg,
[ ] Assistants (incl. Code Interpreter): https://platform.openai.com/docs/assistants/overview
[x] Vision (with B64 encoding of images): https://platform.openai.com/docs/guides/vision
[ ] Image generation (with DALL-E 3): https://platform.openai.com/docs/guides/images/usage?context=node
[ ] Audio (TTS/STT): https://platform.openai.com/docs/guides/text-to-speech
[ ] Moderations: https://platform.openai.com/docs/guides/moderation/quickstart
[ ] Files upload: https://platform.openai.com/docs/api-reference/files
[ ] Finetuning: https://platform.openai.com/docs/guides/fine-tuning
Extending current API calls, eg,
[x] JSON mode
[x] Seed
[ ] Logprobs -- not available on the API as of 11th Nov
[ ] Function calling (available through the current interface but we should add some examples here)
Ideally, we would also add some simple examples to the docs.
There are many cool capabilities (eg, function calling, logit-bias-classifiers, ...) that are easy to do with the existing APIs, but hard to access for beginners.
I'm happy to take a stab at it over the weekend if no one is interested!
The text was updated successfully, but these errors were encountered: