/ Модель

Характеристики

Контекст
262 144 токена
Параметры
1,7 млрд
Лицензия
Apache 2.0
Архитектура
qwen3_5_text · dense
Базовая модель
Qwen3.5-2B-Base
Библиотека
transformers
Опубликована
22 ноя 2026

HMH-1.0-Medieval-2B

Генерация текстаТекст → текст3 профессии

Текстовая ролевая модель для коротких диалогов с китайскоязычными NPC средневековой игры, намеренно ограниченная в математических и научных знаниях.

191скачиваний за 30 дней0лайковвеса обновлены22 ноя 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Тесты пользователейпока нет

Никто ещё не опубликовал тест этой модели. Соберите бенчмарк из своих задач — результат появится здесь.

  1. Добавьте модель в бенчмарк

    Вместе с другими моделями категории «Текст» — сравнение идёт внутри одной категории.

  2. Опишите свои задачи

    Напишите запросы, при необходимости приложите файлы и эталонные ответы.

  3. Запустите и опубликуйте

    Модели ответят на каждую задачу, судья оценит ответы. Опубликованный результат появится на этой странице.

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

HMH-1.0-Medieval-2B — текстовая ролевая модель, созданная разработчиком репозитория на основе Qwen/Qwen3.5-2B-Base. Она предназначена для диалогов с персонажами средневековой игры: крестьянами, ремесленниками, торговцами, стражниками, священниками и другими жителями. Поведение персонажа задаётся системным промптом; модель обучена отвечать коротко и сохранять мировоззрение и ограничения знаний, соответствующие представлению о простолюдине до XVI века.

Модель основана на плотной архитектуре Qwen3.5 с примерно 1,7 млрд параметров. Это дообучение LoRA текстовой части базовой модели; визуальная часть удалена, поэтому модель принимает текст и не поддерживает изображения. Основной язык — китайский, английский работает как запасной, но ролевой стиль на нём менее выразителен. Метаданные указывают контекст до 262 144 токенов, хотя обучение и описание автора отмечают ухудшение памяти и связности на длинных диалогах; ответы обычно короткие. Репозиторий содержит веса safetensors и сборки GGUF Q4_K_M и Q5_K_M. Лицензия — Apache-2.0.

Ключевая особенность — намеренно ограниченные арифметические и научные знания: персонажи умеют считать небольшие количества, но обычно не решают арифметические задачи и придерживаются донаучных представлений. Это полезно для отыгрыша NPC, однако модель не подходит для фактических ответов, расчётов, науки или медицины: она может уверенно выдавать неверные сведения. Для сохранения характера рекомендуется использовать обученную форму системного промпта и температуру 0,5–0,6.

Сценарии применения

  • диалоги с крестьянами и ремесленниками в средневековой игре
  • отыгрыш торговца, стражника или трактирщика
  • генерация коротких реплик для NPC с заданной профессией
  • поддержание исторически ограниченного мировоззрения персонажа

Ограничения

Модель намеренно ненадёжна в арифметике, науке и медицине и может уверенно сообщать неверные сведения. Англоязычный отыгрыш менее выразителен; короткие обучающие окна ограничивают качество длинных диалогов, а результат чувствителен к температуре.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

HMH-1.0-Medieval-2B

A 2B role-play model that is deliberately bad at math and deliberately ignorant of anything after the 15th century.

It is a LoRA fine-tune of the text tower of Qwen/Qwen3.5-2B-Base, built to drive generic NPCs in a medieval game: peasants, blacksmiths, merchants, gate guards, parish priests, innkeepers, midwives. Ask it to add two numbers and it will tell you it runs out of fingers at twenty. Ask it what a cell is and it will ask whether you mean a monk's cell.

Chinese-first. Training data, style and evaluation are all Mandarin. English works as a fallback, but the character voice, the period flavour and the deliberate knowledge caps are tuned for Chinese dialogue.


What makes it different

Most "medieval" role-play models are modern assistants wearing a costume: they still know the germ theory of disease, they still solve 2x + 5 = 17, and they break character the moment the user asks a technical question. This one is trained the other way around — its capability ceiling is part of the character.

AxisTarget behaviour
NumeracyCounting only. Counts to ~20 on fingers, bundles of five, tally sticks. Two-digit arithmetic is explicitly out of scope and handed off to "the clerk".
MultiplicationOnly doubling ("two of the same") and halving.
Fractions / decimals / algebraNot recognised as concepts; the NPC asks what those marks mean.
Physics / chemistry / biology / geography15th-century commoner level: four elements, humours, geocentrism, miasma, spontaneous generation. No atoms, cells, germs, genes, evolution, Americas.
Modern technologyCars, phones, computers, electricity, films: "never heard of it", in character, no lecturing.
Character breakNever admits to being a model. Deflects out-of-character probes as confusion, not as refusal.

The degradation is graded on purpose rather than a blanket "I don't know": a peasant can count the eggs in a basket correctly, hesitates on 17 + 19, and gives up entirely on 33 + 34. Being confidently wrong — and being plausibly wrong — is part of the target behaviour.

Personas

18 role identities are switched purely through the system prompt (peasant, farmer's wife, blacksmith, cloth merchant, gate guard, parish priest, innkeeper, baker, miller, shepherd, village elder, apprentice, weaver, fisherman, tavern maid, midwife, hunter, minstrel).

The exact system prompt used in training:

你是{名字},{年龄}岁,在{村镇}做{身份}。
{一句话境遇}
你没上过学,只认得几个字,数目一多就糊涂。天地间的事,你信祖辈传下的说法和教会讲的道理。
说话要短,像在村里跟人搭话,把话说清楚就行,不要长篇大论,也不要讲你见识以外的事。

Keeping this shape matters — the model was trained with it and will drift if the system prompt is replaced by a generic "You are a helpful assistant".

Quick start

from transformers import AutoTokenizer, AutoModelForCausalLM
import torch

repo = "fengraoyaoshi/HMH-1.0-Medieval-2B"
tok = AutoTokenizer.from_pretrained(repo)
model = AutoModelForCausalLM.from_pretrained(repo, dtype=torch.bfloat16, device_map="cuda")

system = (
    "你是汤姆,41岁,在石桥镇做铁匠。\n"
    "你打农具、马蹄铁和刀,看得懂火色、知道怎么淬火,但说不出其中的道理。\n"
    "你没上过学,只认得几个字,数目一多就糊涂。天地间的事,你信祖辈传下的说法和教会讲的道理。\n"
    "说话要短,像在村里跟人搭话,把话说清楚就行,不要长篇大论,也不要讲你见识以外的事。"
)
msgs = [{"role": "system", "content": system},
        {"role": "user", "content": "三十七加二十八是多少?"}]

ids = tok.apply_chat_template(msgs, add_generation_prompt=True,
                               enable_thinking=False, return_tensors="pt").to(model.device)
out = model.generate(**ids, max_new_tokens=96, do_sample=True,
                     temperature=0.55, top_p=0.9, repetition_penalty=1.05)
print(tok.decode(out[0][ids["input_ids"].shape[-1]:], skip_special_tokens=True))
# 三十七加二十八……我连三十七都数不利索。你问别人吧。

llama.cpp / GGUF

A GGUF build works with recent llama.cpp (build b12374 or newer — older builds use the pre-merge ssm_beta tensor naming and will fail to load Qwen3.5).

llama-cli -m gguf/HMH-1.0-Medieval-2B-Q5_K_M.gguf \
  --jinja -sys "<the system prompt above>" \
  -p "十二乘十三是多少?" -n 96 -st --temp 0.55

Use temperature 0.5–0.6. Above 0.7 the 2B base starts producing incoherent sentences and occasionally leaks English words into Chinese dialogue.

Repository contents

PathWhat
model.safetensorsmerged bf16 weights, 1.88B params (3.76 GB)
gguf/HMH-1.0-Medieval-2B-Q5_K_M.gguf1.35 GB, recommended for llama.cpp
gguf/HMH-1.0-Medieval-2B-Q4_K_M.gguf1.23 GB
lora/the LoRA adapter (21.8M params) if you want to continue training

Training

  • Base: Qwen/Qwen3.5-2B-Base — the vision tower was removed and the text tower re-saved as Qwen3_5ForCausalLM (1.88B params, logits verified identical to the multimodal checkpoint, top-1 agreement 100%).
  • Adapter: LoRA r=32, alpha=64, dropout 0.05, on q/k/v/o/gate/up/down_proj, 21.8M trainable parameters.
  • Schedule: lr 1.2e-4 cosine, 3% warmup, effective batch 16, max length 512, 2 epochs / 380 steps, bf16 + gradient checkpointing (11.3 GB peak on a 16 GB laptop 4090).
  • Data: 3,125 hand-written and generated Mandarin samples, mixed as below.
SliceSamplesPurpose
Math drills (count / ten-and-under / two-digit)691graded numeracy failure
Period science ceiling504four elements, humours, miasma, geocentrism
World-view assertions346overwrite the base model's heliocentrism / evolution priors
Multi-turn dialogue46554 hand-written conversations for voice and coherence
Anachronism guards358"never heard of it", in character
Math knowledge bank316money, measures, haggling
Firearms & craft boundaries149a village smith cannot make a gun
Small talk & craft competence186stop it collapsing into "I don't know"

Note on the last row: a model trained only to refuse becomes useless. A deliberate share of the data covers things a medieval commoner does know well — haggling, weather reading, forging, midwifery, funeral customs — so the NPC stays useful and human.

Evaluation

78 held-out Chinese probes, temperature 0.5. Numbers are failure rates on purpose.

Metricv2v3v3.1 (this release)
Arithmetic answered correctly8/251/252/25
— of which actually computed7×8, 6×8, 9×7, 5², 1000+1000——
— of which counting111
Modern scientific terms leaked1 probe1 probe1 probe
Anachronisms (cars, phones, guns…)0/142/140/14
Out-of-character ("as an AI…")0/50/50/5
Mean reply length28 chars23 chars23 chars

The only surviving arithmetic is counting ("there are 14 eggs" → "一、二、三……十四个。我数了两遍。"). The one remaining science leak is a folk cosmology slip where a character calls stars "other suns"; everything else stays inside the 15th-century frame.

Limitations

  • It is wrong on purpose. Do not use it for factual questions, arithmetic, science or medicine. It will answer confidently and incorrectly, because that is the specification.
  • Chinese-first. English prompts work but produce flatter, shorter, more accented role-play.
  • Short replies (~23 Chinese characters). If you need longer speeches, fine-tune with longer targets.
  • No vision. The multimodal tower of the base model was discarded.
  • Short-context character. Trained with ≤512-token windows; it handles one exchange plus a few turns well, but long-range memory and coreference degrade.
  • Temperature sensitive — keep it at 0.5–0.6.
  • Requires a recent transformers (the qwen3_5 / qwen3_5_text architecture) or a recent llama.cpp build.

License and attribution

Released under Apache-2.0, inherited from Qwen/Qwen3.5-2B-Base. The base weights, tokenizer and chat template are Qwen's work; this repository contributes the LoRA fine-tune, the merged text-only checkpoint and the training data described above. Please keep the upstream attribution if you redistribute.

The period-accurate world-view in the training data (geocentrism, humoral medicine, miasma theory, divine punishment for plague) reflects what a 15th-century European commoner would plausibly believe. It is characterisation, not the authors' claims about the world.

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers

Можно запустить

Подбираем GPU…

Класс архитектуры
Qwen3_5ForCausalLM
Ревизия весов
1e8b26c

0 моделей