/ Модель

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

Контекст
2 048 токенов
Параметры
65 млрд
Размер весов
83,7 ГБ
Лицензия
Apache 2.0
Архитектура
RefinedWeb · dense
Опубликована
29 июл 2023

alfred-40b-0723

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

Alfred-40B-0723 — дообученная LightOn с помощью RLHF модель Falcon-40B для диалогов и выполнения инструкций на нескольких европейских языках.

125скачиваний за 30 дней46лайковвеса обновлены11 авг 2023

Бенчмарки

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

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

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

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

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

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

Alfred-40B-0723 — языковая модель LightOn для диалогов и выполнения инструкций, созданная дообучением Falcon-40B с помощью обучения с подкреплением на основе отзывов людей (RLHF) в июле 2023 года. Это авторегрессионная модель с архитектурой decoder-only семейства RefinedWeb; в метаданных указан размер 65 млрд параметров. Модель предназначена для генерации ответов в формате чата и исследовательской работы с RLHF-моделями.

Модель лучше всего работает на английском, немецком, испанском и французском языках; также заявлены ограниченные возможности для итальянского, португальского, польского, нидерландского, румынского, чешского и шведского. Она распространяется под лицензией Apache 2.0. В README отмечены снижение результатов в арифметике и вопросах-ответах, а также нестабильный выбор испанского языка на короткие английские запросы и отдельные особенности формата ответов. Обучение преимущественно на этих языках ограничивает перенос на другие языки; модель может воспроизводить стереотипы из интернет-данных.

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

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

Ограничения

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

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

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

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

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

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

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

Открыть на Hugging Face

Model Card for Alfred-40B-0723

a witty and elegant butler with a falcon on his shoulder, smile, flat illustration, simple shapes, colorful, lo-fi aesthetics

Alfred-40B-0723 is a finetuned version of Falcon-40B, obtained with Reinforcement Learning from Human Feedback (RLHF). Finetuning was performed in July 2023. It is the first of a series of RLHF models based on Falcon-40B that will be regularly released. It is made available under the Apache 2.0 License.

Model Details

Model Description

Uses

Direct Use

Alfred-40B-0723 can be used as an instruct or chat model. We encourage its usage for research on large language models finetuned with RLHF as well.

The prefix to use Alfred in chat mode is:

Alfred is a large language model trained by LightOn. Knowledge cutoff: November 2022. Current date: 31 July, 2023

User: {user query}
Alfred:

The stop word User: should be used.

Out-of-Scope Use

Production use without adequate assessment of risks and mitigation; any use cases which may be considered irresponsible or harmful.

Bias, Risks, and Limitations

Alfred-40B-0723 is a finetune of Falcon-40B. As such, it is trained mostly on English, German, Spanish, French, with limited capabilities also in in Italian, Portuguese, Polish, Dutch, Romanian, Czech, Swedish. It will not generalize appropriately to other languages. Furthermore, as it is trained on a large-scale corpora representative of the web, it will carry the stereotypes and biases commonly encountered online.

Recommendations

We recommend users of Alfred-40B-0723 to implement appropriate guardrails and precautions in any production use.

Observed failure modes

From internal testing, the following failure modes have been observed:

  • The model has a tendency to respond in Spanish to very short prompts in English, such as shorter greetings (e.g. "Hello", "Hi");
  • At times, the model encloses its response in quotes;
  • A times, the model adds a sentiment in brackets to its output (e.g. "[sadly] model response")

These are mainly due to certain patterns prevalent in the open source datasets used, and will be adressed in future iterations of Alfred.

If you encounter any other recurring failure modes, please open a community discussion, or contact us.

How to Get Started with the Model

Use the code below to get started with the model.

from transformers import AutoTokenizer, AutoModelForCausalLM
import transformers
import torch

model = "lightonai/alfred-40b-0723"
tokenizer = AutoTokenizer.from_pretrained(model)

pipeline = transformers.pipeline(
    "text-generation",
    model=model,
    tokenizer=tokenizer,
    torch_dtype=torch.bfloat16,
    trust_remote_code=True,
    device_map="auto",
)


sequences = pipeline(
   "Write a short text to announce that the new transformer model Alfred is available in open-source on Huggingface, include emojis.",
    max_length=200,
    do_sample=True,
    top_k=10,
    num_return_sequences=1,
    eos_token_id=tokenizer.eos_token_id,
)
for seq in sequences:
    print(f"Result: {seq['generated_text']}")

Training Details

Training Data

Alfred-40B-0723 was trained on a mixture of publicly available and in-house curated datasets.

Data source
oasst1
hh-rlhf
dolly
NatInstV2
momentum-internal

momentum-internal is a collection of prompts rated as gold quality from the staff of LightOn in their daily workflow.

Training Procedure

Alfred-40B-0723 was trained on 128 A100 40GB GPUs, using a 3D parallelism strategy (TP=8, PP=4, DP=4) combined with ZeRO. The value model is initialized from the reward model and does not have any shared parameters with the policy network.

Preprocessing

Samples from each of the datasets have been programmatically formatted to chat, instructions and few-shot promtps.

Training Hyperparameters

Policy and Value Optimizer Config
HyperparameterValueComment
Precisionbfloat16
OptimizerAdamW
Learning rate1.85e-610 warm-up steps, cosine decay over a 100 steps to 1.85e-7
Trainer config
HyperparameterValue
Num Rollouts1024
Policy Epochs1
Value Epochs1
KL Coef0.01
Gamma1.0
GAE Lambda0.95
Clip Range Policy0.2
Clip Range Value0.2
Whiten Advantagestrue
Whiten Rewardsfalse
Score on EODtrue
Max Steps200
PPO steps/epoch1
Value steps/epoch8
Trajectory data config
HyperparameterValue
Continuation Max Len1024
Continuation Min Len0
Top P1.0
Temperature1.0
Of interest to the community

The following hyper parameters have not been extensively explored and should not be taken as a gold standard:

  • learning rate
  • number of rollouts
  • number of epochs
  • steps per epoch

Evaluation

aggregated evaluation of RAW vs SFT vs PPO - including random baseline - PPO suffers in arithmetic due to effects on calibration

Initial evaluation results derived from the EleutherAI harness are as follows:

  • Arithmetic capabilities exhibit a significant decline.
  • Common Sense, Paraphrase, Reasoning, and Reading Comprehension remain relatively stable.
  • Natural Language Inference (NLI) demonstrates improvement while Question Answering (QA) shows deterioration.

These outcomes align with existing literature expectations. It is worth noting that benchmark metrics do not necessarily align with human preferences. Moreover, all these metrics employ a Select methodology which penalizes RLHF models due to their sub-standard calibration compared to raw LLMs.

Human evaluation is currently underway.

Compute Infrastructure

Hardware

Alfred-40B-0723 was trained on AWS SageMaker, on 128 A100 40GB GPUs in P4d instances.

Software

Alfred-40B-0723 was trained with a custom RLHF codebase. Training leverages a 3D parallelism approach combined with ZeRO, as well as high-performance kernels such as FlashAttention.

Model Card Contact

Please open a Community Discussion for any support request related to using Alfred with HuggingFace transformers.

For any other inquiry: contact@lighton.ai

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

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

GPU в ailist

vLLM

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

Код из репозитория вместе с pickle-весами (.bin) не запускается из соображений безопасности.

Класс архитектуры
RWForCausalLM
Ревизия весов
45ef7a5

0 моделей