Особенности / Key facts:
Бенчмарки / Benchmarks
RU
Замеры на ru-llm-arena-hard (судья — GPT-4o, базовая модель — GPT-3.5-turbo) и MERA. Колонка Avg #Tokens — средняя длина ответа на ru-llm-arena: контроль длины удерживает её низкой при росте качества.
EN
Evaluated on ru-llm-arena-hard (judge: GPT-4o, baseline: GPT-3.5-turbo) and MERA. The Avg #Tokens column is the mean response length on ru-llm-arena — length control keeps it low while quality improves.
Table with columns: Model, ru-llm-arena-hard, MERA, Avg #Tokens| Model | ru-llm-arena-hard | MERA | Avg #Tokens |
|---|
| Qwen/Qwen2.5-3B-Instruct | 38.1 | 0.423 | 431 |
| Qwen2.5-1.5B-Instruct-GRPO-LC | 36.1 | 0.301 | 558 |
| Vikhrmodels/QVikhr-2.5-1.5B-Instruct-SMPO | 33.4 | 0.301 | 510 |
| Qwen/Qwen3-1.7B (non-thinking) | 31.4 | 0.3 | 910 |
Обучение / Training:
RU
Базовая SFT-модель Vikhr-Qwen-2.5-1.5B-Instruct дообучена онлайн-методом GRPO (вариант Dr. GRPO, scale_rewards=none). Для каждого промпта генерировалось 16 ответов, которые оценивались reward-моделью Skywork-Reward-V2-Llama-3.1-8B. Поскольку reward-модель смещена в сторону длинных ответов, к награде добавлялся штраф за длину (целевая длина ≈ 640 токенов) — это удерживает среднюю длину ответа низкой и борется с «раздуванием». Промпты — подвыборка датасета t-tech/T-Wix, отобранная по разнообразию инструкций с помощью InsTag.
Ключевые гиперпараметры: beta=0.1, learning_rate=1e-6, косинусный планировщик с прогревом 10%, 1 эпоха, temperature=0.9, max_completion_length=2048, обучение в bf16. Генерация на vLLM (colocate).
EN
The Vikhr-Qwen-2.5-1.5B-Instruct SFT base was further trained with the online RL method GRPO (Dr. GRPO variant, scale_rewards=none). For each prompt, 16 candidate responses were sampled and scored by the Skywork-Reward-V2-Llama-3.1-8B reward model. Because the reward model is length-biased toward longer answers, a length penalty was added to the reward (target length ≈ 640 tokens) to keep mean response length low and counteract verbosity inflation. Prompts were an instruction-diversity (InsTag) subsample of the t-tech/T-Wix dataset.
Key hyperparameters: beta=0.1, learning_rate=1e-6, cosine schedule with 10% warmup, 1 epoch, temperature=0.9, max_completion_length=2048, bf16 training. Generation served by vLLM (colocate mode).
Пример кода для запуска / Sample code to run:
Рекомендуемые параметры генерации совпадают с generation_config.json модели / Recommended generation settings match the model's generation_config.json (temperature=0.7, top_p=0.8, top_k=20, repetition_penalty=1.1).
from transformers import AutoModelForCausalLM, AutoTokenizer # Load the model and tokenizermodel_name = "concretejungles/Qwen2.5-1.5B-Instruct-GRPO-LC"model = AutoModelForCausalLM.from_pretrained(model_name)tokenizer = AutoTokenizer.from_pretrained(model_name) # Prepare the input textinput_text = "Напиши краткое описание книги Гарри Поттер." messages = [ {"role": "system", "content": "Вы — ИИ-помощник. Отвечайте полезно, честно и безопасно."}, {"role": "user", "content": input_text},] # Tokenize and generate textinput_ids = tokenizer.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt")output = model.generate( input_ids, max_new_tokens=1024, do_sample=True, temperature=0.7, top_p=0.8, top_k=20, repetition_penalty=1.1,) # Decode and print only the newly generated tokensgenerated_text = tokenizer.decode(output[0][input_ids.shape[-1]:], skip_special_tokens=True)print(generated_text)
Благодарности / Acknowledgements
Результат был получен во время работы в СКБ Контур.
Основано на Vikhrmodels/Vikhr-Qwen-2.5-1.5B-Instruct.
@inproceedings{nikolich2024vikhr, title={Vikhr: Advancing Open-Source Bilingual Instruction-Following Large Language Models for Russian and English}, author={Aleksandr Nikolich and Konstantin Korolev and Sergei Bratchikov and Nikolay Kompanets and Igor Kiselev and Artem Shelmanov}, booktitle={Proceedings of the 4th Workshop on Multilingual Representation Learning (MRL) @ EMNLP-2024}, year={2024}, publisher={Association for Computational Linguistics}, url={https://arxiv.org/pdf/2405.13929}}