Instructions to use huggingtweets/elonmusk with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use huggingtweets/elonmusk with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="huggingtweets/elonmusk")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("huggingtweets/elonmusk") model = AutoModelForCausalLM.from_pretrained("huggingtweets/elonmusk") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use huggingtweets/elonmusk with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "huggingtweets/elonmusk" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "huggingtweets/elonmusk", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/huggingtweets/elonmusk
- SGLang
How to use huggingtweets/elonmusk 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 "huggingtweets/elonmusk" \ --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": "huggingtweets/elonmusk", "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 "huggingtweets/elonmusk" \ --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": "huggingtweets/elonmusk", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use huggingtweets/elonmusk with Docker Model Runner:
docker model run hf.co/huggingtweets/elonmusk
Adding `safetensors` variant of this model
#70 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#69 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#68 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#67 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#66 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#65 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#64 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#63 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#62 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#61 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#60 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#59 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#58 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#57 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#56 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#55 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#54 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#53 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#52 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#51 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#50 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#49 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#48 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#47 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#46 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#45 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#44 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#43 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#42 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#41 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#40 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#39 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#38 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#37 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#36 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#35 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#34 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#33 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#32 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#31 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#30 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#29 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#28 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#27 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#26 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#25 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#24 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#23 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#22 opened almost 3 years ago
by
SFconvertbot
Adding `safetensors` variant of this model
#21 opened almost 3 years ago
by
SFconvertbot