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(tools): Basic tool support for OpenAI models #1447

Merged
merged 11 commits into from
Oct 4, 2024

Conversation

gladish
Copy link
Contributor

@gladish gladish commented Sep 3, 2024

No description provided.

@harisyammnv
Copy link
Contributor

really helpful

@nsarrazin nsarrazin added enhancement New feature or request models This issue is related to model performance/reliability tools labels Sep 9, 2024
@nsarrazin nsarrazin self-assigned this Sep 9, 2024
@nsarrazin nsarrazin self-requested a review September 9, 2024 12:51
Copy link
Collaborator

@nsarrazin nsarrazin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Type checks seems to fail in src/lib/server/textGeneration/tools.ts with

Property 'correlationKey' is missing in type '{ name: string; parameters: Record<string, string>; }' but required in type 'ToolCall'.ts(2741)

could you take a look ?

Copy link
Collaborator

@nsarrazin nsarrazin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR! I fixed a couple things and made it a bit more robust but I believe it's ready to go now. I'll merge but if you see issues with this please let me know 🚀

@nsarrazin nsarrazin merged commit 9cf27f0 into huggingface:main Oct 4, 2024
3 checks passed
ice91 pushed a commit to ice91/chat-ui that referenced this pull request Oct 30, 2024
* feat(tools): Basic tool support for OpenAI models

* feat(tools): Basic tool support for OpenAI models

* fix: tools with document input (not image)

* fix: double yield of streaming tokens

* fix: boolean parameter processing error

took me a while to find this one lol

* feat: throw error if using tools in `completions` mode

* feat: fix image processing in tools mode

* fix: remove correlationKey and clean up types

---------

Co-authored-by: Jacob Gladish <jacob_gladish@comcast.com>
Co-authored-by: Nathan Sarrazin <sarrazin.nathan@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request models This issue is related to model performance/reliability tools
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants