Text Generation
Transformers
Safetensors
Russian
gpt2
gpt-2
russian
conversational
text-generation-inference
Instructions to use Dmitriy-Zemskov/CalmaCatLM-2-mini with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Dmitriy-Zemskov/CalmaCatLM-2-mini with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Dmitriy-Zemskov/CalmaCatLM-2-mini") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Dmitriy-Zemskov/CalmaCatLM-2-mini") model = AutoModelForCausalLM.from_pretrained("Dmitriy-Zemskov/CalmaCatLM-2-mini") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use Dmitriy-Zemskov/CalmaCatLM-2-mini with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Dmitriy-Zemskov/CalmaCatLM-2-mini" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Dmitriy-Zemskov/CalmaCatLM-2-mini", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Dmitriy-Zemskov/CalmaCatLM-2-mini
- SGLang
How to use Dmitriy-Zemskov/CalmaCatLM-2-mini 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 "Dmitriy-Zemskov/CalmaCatLM-2-mini" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Dmitriy-Zemskov/CalmaCatLM-2-mini", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "Dmitriy-Zemskov/CalmaCatLM-2-mini" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Dmitriy-Zemskov/CalmaCatLM-2-mini", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Dmitriy-Zemskov/CalmaCatLM-2-mini with Docker Model Runner:
docker model run hf.co/Dmitriy-Zemskov/CalmaCatLM-2-mini
File size: 1,512 Bytes
54b5ce1 b2bca84 e8ba300 54b5ce1 e8ba300 1a04bdd b97355d 3c699c5 b97355d 1a04bdd 5ab5657 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | ---
license: mit
language:
- ru
base_model: gpt-2
tags:
- gpt-2
- russian
- conversational
model-index:
- name: CalmaCatLM-2
results: []
library_name: transformers
model_creator: ViorikaAI
pipeline_tag: text-generation
---
# 🐈⬛ CalmaCatLM-2-MINI
# Подробнее:
## ⚙️ Детали модели
- **Архитектура: GPT-3**
- **Параметры: 125M**
- **Язык: Русский**
- **Лицения: MIT**
## 🏋️ Детали Тренировки
- **Датасет:** ``
- **Железо:** **ОДНА** NVIDIA **GEFORCE RTX 5060 TI** (16GB VRAM)
- **Эпохи:** ...
- **Шагов:** - 20 тысяч
- **СРЕДНИЙ LOSS:** 0.9000
- **Оптимизатор:** 3e-4
- **Контекст:** 1024 токенов
## 🏋️ Использование
```python
from transformers import GPT2LMHeadModel, GPT2Tokenizer
model = GPT2LMHeadModel.from_pretrained("ViorikaAI/CalmaCatLM-2-mini")
tokenizer = GPT2Tokenizer.from_pretrained("ViorikaAI/CalmaCatLM-2-mini")
tokenizer.pad_token = tokenizer.eos_token
inputs = tokenizer("Привет, как дела?", return_tensors="pt")
outputs = model.generate(
**inputs,
max_new_tokens=80,
temperature=0.7,
top_k=50,
do_sample=True,
pad_token_id=tokenizer.eos_token_id,
)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
```
## 🛜 Наши Соц. Сети
- **Discord:** https://discord.gg/8JwTv8zj8d , https://discord.gg/7JE7maH6cf
- **Telegram:** https://t.me/viorika_official
|