Instructions to use unamedai/KateAI with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use unamedai/KateAI with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="unamedai/KateAI")# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("unamedai/KateAI", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use unamedai/KateAI with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "unamedai/KateAI" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "unamedai/KateAI", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/unamedai/KateAI
- SGLang
How to use unamedai/KateAI 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 "unamedai/KateAI" \ --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": "unamedai/KateAI", "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 "unamedai/KateAI" \ --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": "unamedai/KateAI", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use unamedai/KateAI with Docker Model Runner:
docker model run hf.co/unamedai/KateAI
Download custom_tokenizer.json from unamedai/KateAI: direct link, hf CLI and curl.
- Browser
- Download file 409 Bytes
-
https://huggingface.co/unamedai/KateAI/resolve/refs%2Fpr%2F1/custom_tokenizer.json
- Command line
-
hf download hf://unamedai/KateAI@refs/pr/1/custom_tokenizer.json
-
curl -L -o custom_tokenizer.json https://huggingface.co/unamedai/KateAI/resolve/refs%2Fpr%2F1/custom_tokenizer.json
409 Bytes
| {"word_to_index": {"[PAD]": 0, "[UNK]": 1, "[SOS]": 2, "[EOS]": 3, "a": 4, "sentence.": 5, "are": 6, "language": 7, "this": 8, "is": 9, "test": 10, "another": 11, "example": 12, "transformers": 13, "powerful": 14, "models.": 15, "let's": 16, "train": 17, "simple": 18, "model.": 19, "models": 20, "amazing": 21, "at": 22, "generating": 23, "text.": 24}, "special_tokens": ["[PAD]", "[UNK]", "[SOS]", "[EOS]"]} |