Instructions to use Shiveshs/DialoGPT-small-harry with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Shiveshs/DialoGPT-small-harry with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Shiveshs/DialoGPT-small-harry")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Shiveshs/DialoGPT-small-harry") model = AutoModelForCausalLM.from_pretrained("Shiveshs/DialoGPT-small-harry", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Shiveshs/DialoGPT-small-harry with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Shiveshs/DialoGPT-small-harry" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Shiveshs/DialoGPT-small-harry", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Shiveshs/DialoGPT-small-harry
- SGLang
How to use Shiveshs/DialoGPT-small-harry with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Shiveshs/DialoGPT-small-harry" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Shiveshs/DialoGPT-small-harry", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Shiveshs/DialoGPT-small-harry" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Shiveshs/DialoGPT-small-harry", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Shiveshs/DialoGPT-small-harry with Docker Model Runner:
docker model run hf.co/Shiveshs/DialoGPT-small-harry
- Xet hash:
- 9a196198a84c28f6d5a22e5d4d5c30a8176cb9fa63f4653ebf6cd1258f9666e1
- Size of remote file:
- 510 MB
- SHA256:
- ad4255239d21525b7cd7e33d856574763608b77bec98097a4b1c318495e47170
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.