YIAN-4B

YIAN-4B is a LoRA adapter fine-tuned on Qwen3-4B-Instruct-2507 with the TCM-YIAN instruction-tuning dataset (12,500 instructions organized into four tasks over seven TCM clinical element categories) for noise-resistant structured extraction of Traditional Chinese Medicine (TCM) medical cases.

Given a full-length case text as published — including theoretical narration, post-case efficacy descriptions, and commentator notes — the model locates the complete medical case within the noisy text and outputs a standardized JSON with seven fields: patient information, main symptoms, tongue manifestations, pulse manifestations, syndrome, treatment method, and Chinese herbs (with dosages).

Training

Hyperparameter Value
Base model Qwen3-4B-Instruct-2507
Method LoRA (r = 8, α = 16, dropout = 0.1, all attention and FFN projections)
Optimizer AdamW, lr 2e-5, cosine schedule, warmup ratio 0.1, weight decay 0.01
Effective batch size 64
Epochs 3
Framework LLaMA-Factory

Best checkpoint selected by validation loss (0.0337). Full training and evaluation code is available in the paper's supplementary repository.

Usage

transformers + PEFT

from peft import PeftModel
from transformers import AutoModelForCausalLM, AutoTokenizer

base = AutoModelForCausalLM.from_pretrained(
    "Qwen/Qwen3-4B-Instruct-2507", torch_dtype="bfloat16", device_map="auto")
model = PeftModel.from_pretrained(base, "mark1111222/YIAN-4B")
tok = AutoTokenizer.from_pretrained("Qwen/Qwen3-4B-Instruct-2507")

vLLM (as used in the paper)

from vllm import LLM, SamplingParams
from vllm.lora.request import LoRARequest

llm = LLM(model="Qwen/Qwen3-4B-Instruct-2507",
          max_model_len=8192, enable_lora=True,
          max_lora_rank=8)
out = llm.generate(
    prompts,
    SamplingParams(temperature=0.2, max_tokens=2048),
    lora_request=LoRARequest("yian", 1, "mark1111222/YIAN-4B"))

Training data

TCM-YIAN (12,500 instructions, CC BY-NC 4.0): https://doi.org/10.5281/zenodo.XXXXXXX

License

CC BY-NC 4.0 (Attribution-NonCommercial 4.0 International). Released for non-commercial research use only, because the training data are derived from published TCM case-record compilations.

Citation

@article{yian4b2026,
  title  = {YIAN-4B: A Noise-Resistant Instruction-Tuned Model for Structured Extraction of TCM Medical Cases},
  author = {Zhao, ...},
  journal= {...},
  year   = {2026}
}
Downloads last month
-
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for mark1111222/YIAN-4B

Adapter
(5727)
this model