Skip to content

Fix client in VLM JS inference snippet #1013

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

Merged
merged 1 commit into from
Nov 5, 2024
Merged

Conversation

Wauplin
Copy link
Contributor

@Wauplin Wauplin commented Nov 5, 2024

Small typo. In JS, the library should be huggingface.js not huggingface_hub.

@Wauplin Wauplin merged commit f2795a8 into main Nov 5, 2024
5 checks passed
@Wauplin Wauplin deleted the fix-vlm-library-typo branch November 5, 2024 10:27
@@ -57,7 +57,7 @@ export const snippetTextGeneration = (
if (streaming) {
return [
{
client: "huggingface_hub",
client: "huggingface.js",
Copy link
Collaborator

@mishig25 mishig25 Nov 5, 2024

Choose a reason for hiding this comment

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

actually, not this? @huggingface/inference because we use like

import { HfInference } from "@huggingface/inference"
const client = new HfInference("hf_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx")

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll let @coyotte508 decide what the best name is between huggingface.js and @huggingface/inference

Copy link
Member

Choose a reason for hiding this comment

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

where is the huggingface.js shown?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

here: https://huggingface.co/meta-llama/Llama-3.1-8B-Instruct?inference_api=true
Go to "JavaScript". At the moment it's huggingface_hub. In this PR I changed it to huggingface.js but happy to change it to @huggingface/inference if it's better.

Copy link
Member

Choose a reason for hiding this comment

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

i think huggingface.js is good

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.

4 participants