/ Модель

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

Контекст
4 096 токенов
Параметры
1,9 млрд
Размер весов
79,9 ГБ
Лицензия
Apache 2.0
Архитектура
yuan · dense
Опубликована
27 мая 2024

Yuan2-M32-hf

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

Разреженная языковая модель Yuan2.0-M32 для генерации текста, написания кода и решения математических и логических задач.

193скачиваний за 30 дней62лайкавеса обновлены30 мая 2024

Бенчмарки

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

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

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

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

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

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

Yuan2.0-M32-HF — языковая модель семейства Yuan, разработанная командой Yuan и опубликованная в формате Hugging Face. Это разреженная архитектура Mixture of Experts с 32 экспертами, из которых для каждого токена активируются два; в README указано 40 млрд общих и 3,7 млрд активных параметров. Метаданные репозитория указывают 1,9 млрд параметров, поэтому размер конкретной HF-сборки расходится с описанием семейства в README. Модель обучена с нуля на 2000 млрд токенов и предназначена для генерации текста, в том числе написания кода, математических вычислений и рассуждений, а также ответов на вопросы общего характера.

В карточке модели заявлены результаты на HumanEval, GSM8K, MMLU, Math и ARC-Challenge, а архитектура с разреженной активацией призвана снизить вычислительные затраты при работе. Метаданные указывают контекст 4096 токенов, тогда как README для Yuan2.0-M32 сообщает длину последовательности 16K; эти значения относятся к разным описаниям и не совпадают. Модель принимает текст и генерирует текст. Репозиторий использует PyTorch и лицензию Apache 2.0; README также отсылает к отдельному лицензионному соглашению Yuan2.0. Авторы предупреждают, что ответы могут быть неточными и модель может поддаваться вводящим в заблуждение инструкциям.

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

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

Ограничения

В README и метаданных не перечислены поддерживаемые естественные языки. Авторы предупреждают о возможных неточностях и уязвимости к вводящим в заблуждение инструкциям; заявленная длина последовательности 16K в README расходится с контекстом 4096 токенов в метаданных.

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

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

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

Также подходит для

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

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

Открыть на Hugging Face

1. Introduction

Yuan2.0-M32 is a Mixture-of-Experts (MoE) language model with 32 experts, of which 2 are active. A new router network, Attention Router, is proposed and has been adopted for more efficient expert selection, boosting accuracy by 3.8% over models using a classical router network. Yuan 2.0-M32 is trained from scratch with 2000B tokens, and its training computation is only 9.25% of that required by a dense model of the same parameter scale. Demonstrating competitive capabilities in coding, math, and various specialized fields, Yuan2.0-M32 operates with only 3.7B active parameters out of a total 40B, and a forward computation of 7.4 GFLOPS per token, which is just 1/19th of Llama3-70B's requirement. Yuan 2.0-M32 has surpassed Llama3-70B on the MATH and ARC-Challenge benchmarks, achieving accuracies of 55.9% and 95.8%, respectively. The basic information of the Yuan2.0-M32 model is as follows:

  • Total Parameters : 40B
  • Experts: 32
  • Active Experts: 2
  • Active Parameters: 3.7B
  • Training Tokens: 2000B tokens
  • Sequence Length: 16K

The technical report for the Yuan2.0-M32 model has been released, and you can find more detailed technical information and evaluation results by referring to the paper.

2. Model Downloads

ModelSequence LengthTypeDownload
Yuan2.0-M3216KMegatronHuggingFace
Yuan2.0-M32-HF16KHuggingFaceHuggingFace
Yuan2.0-M32-GGUF16KGGUFHuggingFace
Yuan2.0-M32-GGUF-INT416KGGUFHuggingFace

3. Evaluation

3.1 Benchmarks 🏆

We conducted a thorough evaluation of the Yuan2.0-M32 model across a range of benchmarks, including HumanEval, GSM8K, MMLU, Math, and ARC-Challenge. These benchmarks are designed to test the model's proficiency in key areas such as natural language understanding, knowledge acquisition, mathematical computation and reasoning, and code generation. The Yuan2.0-M32 has shown a consistent and significant advantage over other models like Llama3-8B and Mistral-8×7B, excelling in all evaluated tasks. Remarkably, its overall performance is on par with the more substantial Llama3-70B model.The detailed evaluation results are outlined in the subsequent table.

ModelHumanEvalGSM8KMMLUMathARC-C*
Llama3-70B81.7%93%80.350.4%93.3%
Llama3-8B62.2%79.6%68.4%30%78.6%
Phi-3-medium62.2%91.0%78.0%-91.6%
Phi-3-small61%89.6%75.7%-90.7%
Phi-3-mini58.5%82.5%68.8%-84.9%
Mistral-8*22B45.1%78.6%77.8%41,8%91.3%
Mistral-8*7B40.2%58.4%70.86%28.4%85.9%
Yuan2.0-M3274.4%92.7%72.2%55.9%95.8%

* ARC-C: AI2 Reasoning Challenge (ARC) benchmark contains more complex parts that need further reasoning.


3.2 Computational Utilization for Model

ModelParams (B)Active Params (B)GFLOPs/token (Inference)GFLOPS/token (Fine-tune)Mean AccuracyAverage Accuracy/GFLOPSs per token (Inference)
Llama3-70B707014042079.250.57
Llama3-8B88164864.154.00
Mistral-8*22B141397823472.380.93
Mistral-8*7B4712.925.877.360.832.36
Yuan2.0-M32403.77.422.279.1510.69

4. Quick Start

4.1 Environment Config

We strongly recommend using the latest release of docker images of Yuan2.0-M32.You can launch an instance of the Yuan 2.0 container with the following Docker commands:

docker pull yuanmodel/yuan2.0:m32
docker run --gpus all --privileged --ulimit stack=68719476736 --shm-size=1000G -itd -v /path/to/yuan_2.0:/workspace/yuan_2.0 -v /path/to/dataset:/workspace/dataset -v /path/to/checkpoints:/workspace/checkpoints --name your_name yuanmodel/yuan2.0:m32
docker exec -it your_name bash

4.2 Data Preprocess

We have provided the data preprocess script. See documentation here.

4.3 Model Pretrain

We've provided several scripts for pretraining in the example. The details can be seen from documentation here.

4.4 Inference Service

For a detailed deployment plan, please refer to vllm.

  • For more information, please refer to GitHub repository.

5. Statement of Agreement

The use of the source code in this repository requires compliance with the open source license agreement Apache 2.0. The Yuan2.0 model supports commercial use and does not require authorization. Please understand and comply with the 《Yuan2.0 Model License Agreement》. Do not use the open source model and code, as well as derivatives generated from open source projects, for any purposes that may cause harm to the country and society, or for any services that have not undergone security assessment and filing. Although we have taken measures to ensure the compliance and accuracy of the data during training, the model has a huge number of parameters and is affected by probability and randomness factors. We cannot guarantee the accuracy of the output content, and the model is easily misled by input instructions. This project does not assume any data security, public opinion risks, or any model misleading, abusing, spreading caused by open-source models and code Risks and responsibilities arising from improper utilization You will be solely responsible for the risks and consequences arising from the use, copying, distribution, and modification of the model in this open source project

6. Contact Us

If you have any questions, please raise an issue or contact us at air_service@ieisystem.com

paper:arxiv.org/abs/2405.17976

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

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

GPU в ailist

vLLM

Нельзя запустить

Модели нужен код из репозитория; автор пока не в списке доверенных организаций.

Класс архитектуры
YuanForCausalLM
Ревизия весов
3f5371b

0 моделей