/ Модель

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

Лицензия
Своя лицензия
Опубликована
11 мая 2024

Phi-3-mini-128k-instruct-imatrix-GGUF

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

duyntnet/Phi-3-mini-128k-instruct-imatrix-GGUF — это набор пере-квантизированных GGUF-файлов модели Phi-3 Mini-128K-Instruct, разработанной Microsoft и повторно опубликованной пользователем duyntnet.

2 620скачиваний за 30 дней0лайковвеса обновлены6 июл 2024

Бенчмарки

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

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

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

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

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

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

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

Версия ориентирована на улучшенное понимание кода на Python, C++, Rust и TypeScript, более структурированные ответы, многоэтапное следование инструкциям, рассуждения и обработку длинного контекста. В README заявлена длина контекста 128K токенов; также указано, что модель поддерживает системный тег <|system|>. Формат GGUF позволяет запускать её через llama.cpp, JanAI, KoboldCPP, text-generation-webui и Ollama. Данные о точной архитектуре, количестве параметров и конкретных вариантах квантизации не приведены, поэтому характеристики производительности и требования к ресурсам определить нельзя.

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

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

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

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

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

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

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

Открыть на Hugging Face

Quantizations of https://huggingface.co/microsoft/Phi-3-mini-128k-instruct

Requantized and reuploaded! GGUFs for the latest Phi-3 mini model (July 2024 update), which includes these changes:

  • Significantly increased code understanding in Python, C++, Rust, and Typescript.
  • Enhanced post-training for better-structured output.
  • Improved multi-turn instruction following.
  • Support for <|system|> tag.
  • Improved reasoning and long-context understanding.

Inference Clients/UIs


From original readme

How to Use

Phi-3 Mini-4K-Instruct has been integrated in the 4.41.2 version of transformers. The current transformers version can be verified with: pip list | grep transformers.

Examples of required packages:

flash_attn==2.5.8
torch==2.3.1
accelerate==0.31.0
transformers==4.41.2

Phi-3 Mini-4K-Instruct is also available in Azure AI Studio

Tokenizer

Phi-3 Mini-4K-Instruct supports a vocabulary size of up to 32064 tokens. The tokenizer files already provide placeholder tokens that can be used for downstream fine-tuning, but they can also be extended up to the model's vocabulary size.

Chat Format

Given the nature of the training data, the Phi-3 Mini-4K-Instruct model is best suited for prompts using the chat format as follows. You can provide the prompt as a question with a generic template as follow:

<|system|>
You are a helpful assistant.<|end|>
<|user|>
Question?<|end|>
<|assistant|>

For example:

<|system|>
You are a helpful assistant.<|end|>
<|user|>
How to explain Internet for a medieval knight?<|end|>
<|assistant|> 

where the model generates the text after <|assistant|> . In case of few-shots prompt, the prompt can be formatted as the following:

<|system|>
You are a helpful travel assistant.<|end|>
<|user|>
I am going to Paris, what should I see?<|end|>
<|assistant|>
Paris, the capital of France, is known for its stunning architecture, art museums, historical landmarks, and romantic atmosphere. Here are some of the top attractions to see in Paris:\n\n1. The Eiffel Tower: The iconic Eiffel Tower is one of the most recognizable landmarks in the world and offers breathtaking views of the city.\n2. The Louvre Museum: The Louvre is one of the world's largest and most famous museums, housing an impressive collection of art and artifacts, including the Mona Lisa.\n3. Notre-Dame Cathedral: This beautiful cathedral is one of the most famous landmarks in Paris and is known for its Gothic architecture and stunning stained glass windows.\n\nThese are just a few of the many attractions that Paris has to offer. With so much to see and do, it's no wonder that Paris is one of the most popular tourist destinations in the world."<|end|>
<|user|>
What is so great about #1?<|end|>
<|assistant|>

Sample inference code

This code snippets show how to get quickly started with running the model on a GPU:

import torch 
from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline 

torch.random.manual_seed(0) 
model = AutoModelForCausalLM.from_pretrained( 
    "microsoft/Phi-3-mini-4k-instruct",  
    device_map="cuda",  
    torch_dtype="auto",  
    trust_remote_code=True,  
) 

tokenizer = AutoTokenizer.from_pretrained("microsoft/Phi-3-mini-4k-instruct") 

messages = [ 
    {"role": "system", "content": "You are a helpful AI assistant."}, 
    {"role": "user", "content": "Can you provide ways to eat combinations of bananas and dragonfruits?"}, 
    {"role": "assistant", "content": "Sure! Here are some ways to eat bananas and dragonfruits together: 1. Banana and dragonfruit smoothie: Blend bananas and dragonfruits together with some milk and honey. 2. Banana and dragonfruit salad: Mix sliced bananas and dragonfruits together with some lemon juice and honey."}, 
    {"role": "user", "content": "What about solving an 2x + 3 = 7 equation?"}, 
] 

pipe = pipeline( 
    "text-generation", 
    model=model, 
    tokenizer=tokenizer, 
) 

generation_args = { 
    "max_new_tokens": 500, 
    "return_full_text": False, 
    "temperature": 0.0, 
    "do_sample": False, 
} 

output = pipe(messages, **generation_args) 
print(output[0]['generated_text']) 

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

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

GPU в ailist

llama.cpp

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

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

Ревизия весов
cc13d44

0 моделей