Image-Text-to-Text
Transformers
Safetensors
kimi_k31
text-generation
mixture-of-experts
expert-upcycling
scientific-ai
chip-design
space
physics
s-t-a-r
custom_code
8-bit precision
Instructions to use STAR-future/Trinity with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use STAR-future/Trinity with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="STAR-future/Trinity", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForSeq2SeqLM model = AutoModelForSeq2SeqLM.from_pretrained("STAR-future/Trinity", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use STAR-future/Trinity with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "STAR-future/Trinity" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "STAR-future/Trinity", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/STAR-future/Trinity
- SGLang
How to use STAR-future/Trinity 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 "STAR-future/Trinity" \ --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": "STAR-future/Trinity", "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 "STAR-future/Trinity" \ --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": "STAR-future/Trinity", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use STAR-future/Trinity with Docker Model Runner:
docker model run hf.co/STAR-future/Trinity
Download eval/k3pass_train2.log from STAR-future/Trinity: direct link, hf CLI and curl.
- Browser
- Download file 2.35 kB
-
https://huggingface.co/STAR-future/Trinity/resolve/f8aef0743bc8ed88e849346528d7dfe34ec00228/eval/k3pass_train2.log
- Command line
-
hf download hf://STAR-future/Trinity@f8aef0743bc8ed88e849346528d7dfe34ec00228/eval/k3pass_train2.log
-
curl -L -o k3pass_train2.log https://huggingface.co/STAR-future/Trinity/resolve/f8aef0743bc8ed88e849346528d7dfe34ec00228/eval/k3pass_train2.log
2.35 kB
| [transformers] A new version of the following files was downloaded from https://huggingface.co/moonshotai/Kimi-K3.1-Pro: | |
| - configuration_kimi_k3.py | |
| . Make sure to double-check they do not contain any added malicious code. To avoid downloading new versions of the code file, you can pin a revision. | |
| /usr/local/lib/python3.13/dist-packages/transformers/configuration_utils.py:723: FutureWarning: `rope_scaling` is deprecated and will be removed in a future version. Set `rope_parameters` instead, with `rope_type` and `rope_theta` included. | |
| warnings.warn( | |
| [transformers] A new version of the following files was downloaded from https://huggingface.co/moonshotai/Kimi-K3.1-Pro: | |
| - encoding_k3.py | |
| . Make sure to double-check they do not contain any added malicious code. To avoid downloading new versions of the code file, you can pin a revision. | |
| [transformers] A new version of the following files was downloaded from https://huggingface.co/moonshotai/Kimi-K3.1-Pro: | |
| - tokenization_kimi.py | |
| - encoding_k3.py | |
| . Make sure to double-check they do not contain any added malicious code. To avoid downloading new versions of the code file, you can pin a revision. | |
| 19:01:46 sequences 663 streams 663 tokens 1357824 sets ['general_wiki', 'train_chemistry', 'train_chips', 'train_physics', 'train_space'] | |
| 19:11:03 resumed from the checkpoint after layer 89 ram_free 161.5 GiB disk_free 168 GiB | |
| 19:11:03 fingerprint a5859af858d3178b start at layer 90 ram_free 161.5 GiB disk_free 168 GiB | |
| 19:11:26 GPU NVIDIA A100-SXM4-80GB 79.3 GiB, sub-chunk 65536 expert group 524288 | |
| 19:22:15 layer 90 wait 83s attn 448s mlp 117s new-share(LB) 0.0491 ram_free 157.6 GiB disk_free 106 GiB | |
| 19:31:14 layer 91 wait 0s attn 424s mlp 114s new-share(LB) 0.1190 ram_free 157.4 GiB disk_free 106 GiB | |
| 19:40:59 layer 92 wait 0s attn 374s mlp 209s new-share(LB) 0.0819 ram_free 157.2 GiB disk_free 90 GiB | |
| 19:48:39 DONE {"littleboy": {"general_wiki": {"mean_nll": 0.09477635473012924, "ppl": 1.0994129491235647, "n_seqs": 64}, "train_chemistry": {"mean_nll": 1.856353759765625, "ppl": 6.4003569341129, "n_seqs": 151}, "train_chips": {"mean_nll": 1.905556559562683, "ppl": 6.723148419095742, "n_seqs": 150}, "train_physics": {"mean_nll": 1.844360113143921, "ppl": 6.324051817782593, "n_seqs": 149}, "train_space": {"mean_nll": 1.6743470430374146, "ppl": 5.335310283466217, "n_seqs": 149}}} | |