Instructions to use jamesdborin/ct2-int8-mtb-7b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use jamesdborin/ct2-int8-mtb-7b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="jamesdborin/ct2-int8-mtb-7b", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("jamesdborin/ct2-int8-mtb-7b", trust_remote_code=True) model = AutoModelForCausalLM.from_pretrained("jamesdborin/ct2-int8-mtb-7b", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use jamesdborin/ct2-int8-mtb-7b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "jamesdborin/ct2-int8-mtb-7b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "jamesdborin/ct2-int8-mtb-7b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/jamesdborin/ct2-int8-mtb-7b
- SGLang
How to use jamesdborin/ct2-int8-mtb-7b 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 "jamesdborin/ct2-int8-mtb-7b" \ --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": "jamesdborin/ct2-int8-mtb-7b", "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 "jamesdborin/ct2-int8-mtb-7b" \ --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": "jamesdborin/ct2-int8-mtb-7b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use jamesdborin/ct2-int8-mtb-7b with Docker Model Runner:
docker model run hf.co/jamesdborin/ct2-int8-mtb-7b
Download ct_output_models/model.bin from jamesdborin/ct2-int8-mtb-7b: direct link, hf CLI and curl.
- Browser
- Download file 6.66 GB
-
https://huggingface.co/jamesdborin/ct2-int8-mtb-7b/resolve/main/ct_output_models/model.bin
- Command line
-
hf download hf://jamesdborin/ct2-int8-mtb-7b/ct_output_models/model.bin
-
curl -L -o model.bin https://huggingface.co/jamesdborin/ct2-int8-mtb-7b/resolve/main/ct_output_models/model.bin
6.66 GB
- Xet hash:
- 0f6cdf2b176795a0079df56adb2a18af2bacb42cb06a24830e847d01e404fa11
- Size of remote file:
- 6.66 GB
- SHA256:
- 159e586fe7da49bbd56b9dcde6dd38c42c6b9aeee7e39dca8ae13ecadfc586ac
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.