/ Модель

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

Лицензия
Llama 3
Базовая модель
Meta-Llama-3-8B
Библиотека
transformers
Опубликована
25 мая 2024

openchat-3.6-8b-20240522-GGUF

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

OpenChat 3.6 8B 20240522 — языковая модель семейства OpenChat, разработанная командой OpenChat и основанная на Meta Llama 3 8B.

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

Бенчмарки

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

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

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

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

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

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

Данный репозиторий содержит её GGUF-квантизации, предназначенные для локального запуска и эффективного развертывания. Модель работает в режиме генерации текста и диалогов, поддерживает совместимый с OpenAI ChatCompletion API сервер и может использоваться через OpenChat Web UI.

Модель имеет около 8 миллиардов параметров, относится к текстовым моделям и обучалась с применением подхода C-RLFT на данных смешанного качества. README не указывает точный размер контекстного окна и перечень поддерживаемых языков. Для работы рекомендуется шаблон подсказок на основе формата Llama 3; сервер оптимизирован для высокой пропускной способности и, согласно README, может запускаться на потребительском GPU с 24 ГБ памяти. Квантизация снижает требования к ресурсам, но конкретные варианты GGUF могут различаться по размеру и качеству.

Сильными сторонами заявлены производительность на уровне открытых 8B-моделей и улучшенное следование инструкциям и few-shot-шаблонам по сравнению с некоторыми альтернативами. Ограничениями являются зависимость качества и скорости от выбранного типа квантизации, а также отсутствие в предоставленных данных подробных результатов тестирования, точного контекстного окна и языкового охвата. Репозиторий распространяется по лицензии Llama 3; условия её применения следует учитывать при использовании модели.

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

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

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

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

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

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

Открыть на Hugging Face

Quantization Description

This repo holds GGUF Quantizations of the openchat-3.6-8b-20240522 model.

Prompt Template

<|begin_of_text|><|start_header_id|>System<|end_header_id|>

{system}<|eot_id|><|start_header_id|>GPT4 Correct User<|end_header_id|>

{prompt}<|eot_id|><|start_header_id|>GPT4 Correct Assistant<|end_header_id|>

ORIGINAL MODEL CARD

To use this model, we highly recommend installing the OpenChat package by following the installation guide in our repository and using the OpenChat OpenAI-compatible API server by running the serving command from the table below. The server is optimized for high-throughput deployment using vLLM and can run on a consumer GPU with 24GB RAM. To enable tensor parallelism, append --tensor-parallel-size N to the serving command.

Once started, the server listens at localhost:18888 for requests and is compatible with the OpenAI ChatCompletion API specifications. Please refer to the example request below for reference. Additionally, you can use the OpenChat Web UI for a user-friendly experience.

If you want to deploy the server as an online service, you can use --api-keys sk-KEY1 sk-KEY2 ... to specify allowed API keys and --disable-log-requests --disable-log-stats --log-file openchat.log for logging only to a file. For security purposes, we recommend using an HTTPS gateway in front of the server.

ModelSizeContextWeightsServing
OpenChat-3.6-202405228B8192Huggingfacepython -m ochat.serving.openai_api_server --model openchat/openchat-3.6-8b-20240522
curl http://localhost:18888/v1/chat/completions \
  -H "Content-Type: application/json" \
  -d '{
    "model": "openchat_3.6",
    "messages": [{"role": "user", "content": "You are a large language model named OpenChat. Write a poem to describe yourself"}]
  }'

Conversation templates

💡 Default Mode: Best for coding, chat and general tasks.

It's a modified version of the Llama 3 Instruct template, the only difference is role names, which are either GPT4 Correct User or GPT4 Correct Assistant

<|start_header_id|>GPT4 Correct User<|end_header_id|>\n\nHello<|eot_id|><|start_header_id|>GPT4 Correct Assistant<|end_header_id|>\n\nHi<|eot_id|><|start_header_id|>GPT4 Correct User<|end_header_id|>\n\nHow are you today?<|eot_id|><|start_header_id|>GPT4 Correct Assistant<|end_header_id|>\n\n

⚠️ Notice: Remember to set <|eot_id|> as end of generation token.

The default template is also available as the integrated tokenizer.chat_template, which can be used instead of manually specifying the template:

messages = [
    {"role": "user", "content": "Hello"},
    {"role": "assistant", "content": "Hi"},
    {"role": "user", "content": "How are you today?"}
]
tokens = tokenizer.apply_chat_template(messages, add_generation_prompt=True)

Inference using Transformers

from transformers import AutoTokenizer, AutoModelForCausalLM
import torch

model_id = "openchat/openchat-3.6-8b-20240522"

tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id, torch_dtype=torch.bfloat16, device_map="auto")

messages = [
    {"role": "user", "content": "Explain how large language models work in detail."},
]
input_ids = tokenizer.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt").to(model.device)

outputs = model.generate(input_ids,
    do_sample=True,
    temperature=0.5,
    max_new_tokens=1024
)
response = outputs[0][input_ids.shape[-1]:]
print(tokenizer.decode(response, skip_special_tokens=True))

Foundation Model Limitations Despite its advanced capabilities, OpenChat is still bound by the limitations inherent in its foundation models. These limitations may impact the model's performance in areas such as:

  • Complex reasoning
  • Mathematical and arithmetic tasks
  • Programming and coding challenges

Hallucination of Non-existent Information OpenChat may sometimes generate information that does not exist or is not accurate, also known as "hallucination". Users should be aware of this possibility and verify any critical information obtained from the model.

Safety OpenChat may sometimes generate harmful, hate speech, biased responses, or answer unsafe questions. It's crucial to apply additional AI safety measures in use cases that require safe and moderated responses.

We look forward to hearing from you and collaborating on this exciting project!

Project Lead:

  • Guan Wang [imonenext at gmail dot com]
  • Alpay Ariyak [aariyak at wpi dot edu]
@article{wang2023openchat,
  title={OpenChat: Advancing Open-source Language Models with Mixed-Quality Data},
  author={Wang, Guan and Cheng, Sijie and Zhan, Xianyuan and Li, Xiangang and Song, Sen and Liu, Yang},
  journal={arXiv preprint arXiv:2309.11235},
  year={2023}
}

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

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

GPU в ailist

llama.cpp

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

GGUF-модель ждёт проверки: нужно выбрать файл кванта под доступные GPU.

Ревизия весов
957d901

0 моделей