Instructions to use yujiepan/kimi-k3-bf16-tiny-random with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use yujiepan/kimi-k3-bf16-tiny-random with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="yujiepan/kimi-k3-bf16-tiny-random", trust_remote_code=True)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("yujiepan/kimi-k3-bf16-tiny-random", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use yujiepan/kimi-k3-bf16-tiny-random with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "yujiepan/kimi-k3-bf16-tiny-random" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "yujiepan/kimi-k3-bf16-tiny-random", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/yujiepan/kimi-k3-bf16-tiny-random
- SGLang
How to use yujiepan/kimi-k3-bf16-tiny-random 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 "yujiepan/kimi-k3-bf16-tiny-random" \ --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": "yujiepan/kimi-k3-bf16-tiny-random", "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 "yujiepan/kimi-k3-bf16-tiny-random" \ --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": "yujiepan/kimi-k3-bf16-tiny-random", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use yujiepan/kimi-k3-bf16-tiny-random with Docker Model Runner:
docker model run hf.co/yujiepan/kimi-k3-bf16-tiny-random
| { | |
| "media_proc_cfg": { | |
| "in_patch_limit": 65536, | |
| "patch_size": 14, | |
| "image_mean": [ | |
| 0.5, | |
| 0.5, | |
| 0.5 | |
| ], | |
| "image_std": [ | |
| 0.5, | |
| 0.5, | |
| 0.5 | |
| ], | |
| "merge_kernel_size": 2, | |
| "fixed_output_tokens": null, | |
| "patch_limit_on_one_side": 512, | |
| "in_patch_limit_each_frame": 16384, | |
| "in_patch_limit_video": 655360, | |
| "sample_fps": 8.0, | |
| "max_num_frames_each_video": null, | |
| "temporal_merge_kernel_size": 4, | |
| "timestamp_mode": "hh:mm:ss.fff", | |
| "transparent_bg_config": { | |
| "pattern": "chessboard", | |
| "chessboard_square_size": 8, | |
| "chessboard_square_on_top_left": true, | |
| "chessboard_white_value": 255, | |
| "chessboard_gray_value": 180 | |
| }, | |
| "transparent_bg_fill_stage": "after_resize", | |
| "config_type": "media_proc.processors.moonvit.MoonViTMediaProcessorConfig" | |
| }, | |
| "auto_map": { | |
| "AutoProcessor": "kimi_k3_processor.KimiK3Processor", | |
| "AutoImageProcessor": "kimi_k3_vision_processing.KimiK3VisionProcessor" | |
| } | |
| } |