Instructions to use cuijian0819/gpt-oss-20b-function-calling with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use cuijian0819/gpt-oss-20b-function-calling with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="cuijian0819/gpt-oss-20b-function-calling") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("cuijian0819/gpt-oss-20b-function-calling", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use cuijian0819/gpt-oss-20b-function-calling with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "cuijian0819/gpt-oss-20b-function-calling" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "cuijian0819/gpt-oss-20b-function-calling", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/cuijian0819/gpt-oss-20b-function-calling
- SGLang
How to use cuijian0819/gpt-oss-20b-function-calling 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 "cuijian0819/gpt-oss-20b-function-calling" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "cuijian0819/gpt-oss-20b-function-calling", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "cuijian0819/gpt-oss-20b-function-calling" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "cuijian0819/gpt-oss-20b-function-calling", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use cuijian0819/gpt-oss-20b-function-calling with Docker Model Runner:
docker model run hf.co/cuijian0819/gpt-oss-20b-function-calling
Download tokenizer.json from cuijian0819/gpt-oss-20b-function-calling: direct link, hf CLI and curl.
- Browser
- Download file 27.9 MB
-
https://huggingface.co/cuijian0819/gpt-oss-20b-function-calling/resolve/main/tokenizer.json
- Command line
-
hf download hf://cuijian0819/gpt-oss-20b-function-calling/tokenizer.json
-
curl -L -o tokenizer.json https://huggingface.co/cuijian0819/gpt-oss-20b-function-calling/resolve/main/tokenizer.json
27.9 MB
- Xet hash:
- 59f22360b51bf1a137fb80e14df310b4b249bed6cc64565aa0c401ca19ffcd04
- Size of remote file:
- 27.9 MB
- SHA256:
- 0614fe83cadab421296e664e1f48f4261fa8fef6e03e63bb75c20f38e37d07d3
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.