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

Add note on local inference alternative to HfApiModel #327

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

HKanoje
Copy link

@HKanoje HKanoje commented Mar 16, 2025

This PR adds a note in the docs explaining how users can run models locally using Ollama + LiteLLM as an alternative to HfApiModel() in case they hit Hugging Face API credit limits.

It includes a sample code snippet using:

LiteLLMModel with model_id="ollama_chat/qwen2.5:7b"

It closes huggingface/smolagents#967 Issues

@davidberenstein1957
Copy link
Member

Hi @HKanoje, this could be a nice addition if we could scope this a bit more uniform.

Could you create a uniform section on this within the onboarding? I think we can just mention local serving and ideally use similar API classed (the HF ones) but explain how to redirect the base URL that relies on OpenAIAPI spec for something like ollama.

WDYT?

@HKanoje
Copy link
Author

HKanoje commented Mar 17, 2025

@davidberenstein1957 Yes I think you're right. It makes more sense to put in as a different section because HfApiModel() is been used everywhere what do you suggest where should I make this section? During the onboarding steps?

@HKanoje HKanoje force-pushed the add-local-inference-note branch from ae82b7b to 2139435 Compare March 19, 2025 19:28
@HKanoje
Copy link
Author

HKanoje commented Mar 19, 2025

Hey, @davidberenstein1957 I’ve added the local inference section to the onboarding as you suggested. Let me know if there’s anything you'd like me to adjust or improve! Check here #327

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.

List of Free Local LLM Models - Up and Running
2 participants