/ Модель

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

Контекст
32 768 токенов
Параметры
13,7 млрд
Размер весов
28,9 ГБ
Архитектура
baichuan_m1 · dense
Опубликована
23 янв 2025

Baichuan-M1-14B-Instruct

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

Baichuan-M1-14B-Instruct — диалоговая языковая модель Baichuan Intelligence для медицинских вопросов, клинических рассуждений и общих задач на английском и китайском языках.

657скачиваний за 30 дней67лайковвеса обновлены20 фев 2025

Бенчмарки

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Baichuan-M1-14B-Instruct — открытая инструктивная языковая модель компании Baichuan Intelligence, разработанная с нуля и оптимизированная для медицинских сценариев. Она предназначена для диалога, ответов на вопросы и рассуждений в медицинской и общей тематике, включая сложные клинические случаи и задачи из более чем 20 медицинских специальностей.

Модель имеет плотную авторегрессионную архитектуру BaichuanM1ForCausalLM и содержит 13,7 млрд параметров. Контекст — до 32 768 токенов. Обучение проводилось на медицинских и общих данных, в том числе на английском, китайском и данных ещё примерно на 30 языках; карточка указывает английский и китайский. В архитектуре используются короткая свёртка в механизме внимания и скользящее оконное внимание в части слоёв для работы с контекстом и снижения расхода KV-кэша.

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

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

  • ответы на медицинские вопросы на английском и китайском
  • подготовка черновиков ответов для медицинских диалогов
  • анализ текстовых описаний клинических случаев
  • обобщение медицинских статей и учебных материалов
  • решение общих вопросов и инструкций в чат-формате

Ограничения

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

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

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

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

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

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

Открыть на Hugging Face

📖 Table of Contents


🏁 Model Introduction

Baichuan-14B-M1 is the industry's first open-source large language model developed from scratch by Baichuan Intelligence, specifically optimized for medical scenarios. While excelling in general capabilities, it demonstrates powerful performance in the medical field. It achieves results comparable to models of similar size in most general benchmark evaluations, while outperforming models five times larger in medical scenarios. Below are the core features of the model:

  • Trained from scratch on 20 trillion tokens of high-quality medical and general data.
  • Specialized modeling for 20+ medical departments with fine-grained medical expertise.
  • Introduces innovative model architecture, significantly improving context understanding and long-sequence task performance.
  • Provides 🤗 Base Model and 🤗 Instruct Model.

🔬 Data Collection and Processing

Medical Data Collection

We conducted meticulous data collection and synthesis for the medical field, including:

  • Tens of millions of professional medical data: Chinese/English professional papers, medical cases, medical textbooks, knowledge bases, etc.
  • Hundreds of millions of medical Q&A and clinical data: Covering complex medical reasoning and real-world clinical cases.
  • Comprehensive data classification and evaluation: Categorized by medical departments, content, and value to ensure balanced data distribution and filter out truly valuable medical data.

Data Synthesis and Optimization

  • Synthetic data design: Combining knowledge graphs, cases, and textbooks to generate diverse, high-quality medical reasoning data.
  • Self-reflection mechanism and reward model: Continuously improving the quality of synthetic data, ultimately generating nearly a trillion tokens of reasoning data, covering long-tail knowledge and complex scenarios.

General Data Collection

  • 20T multilingual general dataset: Including 14T English data, 4T Chinese data, and 2T data covering 30 mainstream languages.
  • Deduplication and upsampling strategy: Upsampling high-quality data to significantly enhance model performance.
  • 27 global knowledge categories: Optimizing data ratios based on small model experiments to balance general and domain-specific capabilities.

🧠 New Model Architecture

Short Convolution Attention Mechanism

  • By introducing lightweight short convolution operations when computing Key and Value, the reliance of standard Transformer models on induction heads for learning is significantly reduced. Traditional Transformers rely on induction heads to capture repetitive patterns and contextual dependencies in sequences, which requires a certain model width and depth. Short convolution decouples the Key and Value sequences in the time dimension, enhancing context learning capabilities. Extensive experiments from toy models to models with over ten billion parameters show that the short convolution attention mechanism excels in language modeling tasks, especially those heavily dependent on contextual information.

Sliding Window Attention Mechanism

  • Adopting a sliding window attention mechanism in some layers to reduce KV Cache memory usage.
  • Optimization: Balancing computational efficiency and performance, especially suitable for long-sequence tasks.

Optimizing Position Encoding Oscillation

  • By increasing the dimensions of some attention heads, RoPE curve oscillation is reduced.
  • Result: More stable performance in long-sequence tasks while maintaining the model's ability to capture diverse features.

High Peak Learning Rate Strategy

  • Using WSD learning rate scheduling strategy with high peak learning rates to promote model generalization.
  • Comparison results: Significant improvement in benchmark task performance.

Adaptive Gradient Update

  • Dynamic gradient clipping: Skipping updates when gradients are too large to reduce instability caused by special samples or steep loss spaces.

⚙️ Training Methodology

We innovatively adopted a multi-stage curriculum learning and alignment optimization approach, systematically enhancing model capabilities through the following two parts:

1. Multi-Stage Curriculum Learning

Training is divided into three stages, progressively optimizing the model's general and medical domain capabilities:

  1. General Knowledge Enhancement Stage: Focused on general language modeling to improve basic language and common sense.
  2. Medical Basic Knowledge Enhancement Stage: Introducing high-quality medical data to enhance reasoning, mathematical, and medical knowledge.
  3. Medical Advanced Knowledge Enhancement Stage: Further optimizing data quality, focusing on complex medical reasoning, disease diagnosis, and long-tail knowledge.

2. Alignment Optimization

Enhancing model generation quality, logical reasoning, and user preference alignment through reinforcement learning and pairwise data optimization:

  1. Pairwise Data: Covering multi-turn dialogues, instruction following, math and code, and reasoning tasks, sourced from human annotations and multi-model generation.
  2. Optimization Process:
    • ELO: Optimizing diverse, high-quality chain-of-thought generation based on maximum likelihood.
    • TDPO: Using pairwise data to optimize the generation model for better user preference alignment.
    • PPO: Further enhancing generation logic and task performance through policy optimization.

This combined approach of multi-stage and alignment optimization enables the model to achieve exceptional performance in both general and medical domain capabilities.


📊 Benchmark Results

Our evaluation covers all mainstream benchmarks, achieving excellent metrics in both open-source and closed-source evaluations, demonstrating outstanding medical scenario capabilities while maintaining strong general performance.


🚀 Quick Start

🤗 Hugging Face Transformers

We recommend using the latest version of the Transformers library (at least 4.47.0). The following code snippet demonstrates how to use the Baichuan-M1-14B-Instruct model:

from transformers import AutoModelForCausalLM, AutoTokenizer
import torch
# 1. Load pre-trained model and tokenizer
model_name = "baichuan-inc/Baichuan-M1-14B-Instruct"  
tokenizer = AutoTokenizer.from_pretrained(model_name,trust_remote_code=True)
model = AutoModelForCausalLM.from_pretrained(model_name,trust_remote_code=True,torch_dtype = torch.bfloat16).cuda()
# 2. Input prompt text
prompt = "May I ask you some questions about medical knowledge?"

# 3. Encode the input text for the model
messages = [
    {"role": "system", "content": "You are a helpful assistant."},
    {"role": "user", "content": prompt}
]
text = tokenizer.apply_chat_template(
    messages,
    tokenize=False,
    add_generation_prompt=True
)
model_inputs = tokenizer([text], return_tensors="pt").to(model.device)

# 4. Generate text
generated_ids = model.generate(
    **model_inputs,
    max_new_tokens=512
)
generated_ids = [
    output_ids[len(input_ids):] for input_ids, output_ids in zip(model_inputs.input_ids, generated_ids)
]

# 5. Decode the generated text
response = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)[0]


# 6. Output the result
print("Generated text:")
print(response)

📜 License and Statement

The use of the model must comply with 《Baichuan-M1-14B模型社区许可协议》.

The development team of Baichuan has not developed any commercial applications based on this model. All users must comply with laws and regulations and must not use the model for harmful national security or illegal purposes.


🏷️ Reference

If you need to cite our work, please use the following reference:

@article{baichuan-m1-2025,
  title={Baichuan-M1: Pushing the Medical Capability of Large Language Models},
  author={Bingning Wang, Haizhou Zhao, Huozhi Zhou, Liang Song, Mingyu Xu, Wei Cheng, Xiangrong Zeng, Yupeng Zhang, Yuqi Huo, Zecheng Wang, Zhengyun Zhao and others},
  journal={arXiv preprint arXiv:2502.12671},
  year={2025}
}

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

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

GPU в ailist

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

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

Подбираем GPU…

Класс архитектуры
BaichuanM1ForCausalLM
Ревизия весов
c1798df

0 моделей