Text Generation
Transformers
PyTorch
English
gpt2
multi-token-prediction
mathematics
MetaMathQA
transformer
speculative-decoding
text-generation-inference
Instructions to use grpvam/multitoken-gpt2-metamathqa with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use grpvam/multitoken-gpt2-metamathqa with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="grpvam/multitoken-gpt2-metamathqa")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("grpvam/multitoken-gpt2-metamathqa") model = AutoModelForCausalLM.from_pretrained("grpvam/multitoken-gpt2-metamathqa", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use grpvam/multitoken-gpt2-metamathqa with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "grpvam/multitoken-gpt2-metamathqa" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "grpvam/multitoken-gpt2-metamathqa", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/grpvam/multitoken-gpt2-metamathqa
- SGLang
How to use grpvam/multitoken-gpt2-metamathqa 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 "grpvam/multitoken-gpt2-metamathqa" \ --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": "grpvam/multitoken-gpt2-metamathqa", "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 "grpvam/multitoken-gpt2-metamathqa" \ --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": "grpvam/multitoken-gpt2-metamathqa", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use grpvam/multitoken-gpt2-metamathqa with Docker Model Runner:
docker model run hf.co/grpvam/multitoken-gpt2-metamathqa
- Xet hash:
- 66f95ab237a63e791d781294d145db4562c9fc576a20685f9bb4e95343c2c7ad
- Size of remote file:
- 5.24 kB
- SHA256:
- e6a677d8267e403ee6e61f8cd7dcd956d32959303d2ab209618047ecbea6b4a5
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.