stanfordnlp / dspy

DSPy: The framework for programming—not prompting—foundation models
https://dspy-docs.vercel.app/
MIT License
18.23k stars 1.39k forks source link

Issue on loading dspy.HFModel #1423

Closed andrelima666 closed 1 month ago

andrelima666 commented 2 months ago

Hello,

I was trying to test dspy with HuggingFace models instead of going into my Azure OpenAI. As I was trying to test this out, I'm having this issue recurrently with every model I tryout. These are the code instructions I'm passing (removed the token for HF access): image

This is the error I'm facing. ( ValueError: You are trying to offload the whole model to the disk. Please use the disk_offload function instead. ) image

okhat commented 2 months ago

For local models, please use TGI or VLLM, not HFModel

andrelima666 commented 2 months ago

So model needs to be always deployed in some sort of api/uri, it cannot be called from downloading HF model locally? 🤔 I'll try it.

okhat commented 2 months ago

Awesome. Let us know how it goes.