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

[tool] hugging face docs tool #1323

Closed
wants to merge 1 commit into from
Closed

[tool] hugging face docs tool #1323

wants to merge 1 commit into from

Conversation

mishig25
Copy link
Collaborator

@mishig25 mishig25 commented Jul 1, 2024

Addition of new hfDocs tool

Given a user query about hugging face libraries usage, this tool will call space huggingchat/hf-docs to get relevant docs snippets so that LLM can answer more accurately.

Related to huggingface/doc-builder#506

image

Comment on lines 26 to 31
? `Previous questions: \n${previousUserMessages
.map(({ content }) => `- ${content}`)
.join("\n")}`
: "") +
"\n\nCurrent Question: " +
String(prompt);
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

tried to match with

from: "user",
content:
(previousUserMessages.length > 0
? `Previous questions: \n${previousUserMessages
.map(({ content }) => `- ${content}`)
.join("\n")}`
: "") +
"\n\nCurrent Question: " +
lastMessage.content,
},

@nsarrazin
Copy link
Collaborator

that's pretty cool 👀 will give it a try!

@mishig25
Copy link
Collaborator Author

mishig25 commented Jul 5, 2024

closing it for now as we might go with a different approach

@mishig25 mishig25 deleted the tool_hf_docs branch July 5, 2024 22:02
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.

2 participants