/ Модель

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

Контекст
4 096 токенов
Параметры
3,7 млрд
Размер весов
7,6 ГБ
Архитектура
phi3 · dense
Базовая модель
Phi-3-mini-4k-instruct
Библиотека
transformers
Опубликована
29 июн 2025

phi-3-M3-coder

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

Дообученная на базе Phi-3 Mini диалоговая модель для генерации и исправления кода.

67скачиваний за 30 дней48лайковвеса обновлены6 июл 2025

Бенчмарки

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

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

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

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

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

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

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

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

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

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

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

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

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

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

moelanoby/phi-3-M3-coder — дообученная модель на базе Microsoft Phi-3 Mini Instruct, предназначенная для генерации кода и диалогового взаимодействия. Это плотная причинная языковая модель архитектуры Phi-3 с 3,7 млрд параметров и контекстом до 4096 токенов; карточка указывает поддержку кода и чата, а также языки Arabic, English, German, French, Portuguese и Polish.

Модель рассчитана на написание и исправление программного кода, в том числе с экспериментальным режимом самокоррекции в несколько проходов. В README приведены результаты на HumanEval и других тестах, однако отдельные показатели заявлены самим автором и могут не отражать качество на иных задачах. Карточка рекомендует проверять баланс между числом проходов самокоррекции, связностью и точностью. Указана лицензия Apache 2.0, допускающая коммерческое использование.

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

  • генерация фрагментов кода по текстовому описанию
  • написание функций на Python и JavaScript
  • поиск и исправление ошибок в коде
  • ответы на вопросы о программировании
  • самокоррекция сгенерированного кода в несколько проходов

Ограничения

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

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

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

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

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

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

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

Открыть на Hugging Face

M3-V2: An Open Source Model for State-of-the-Art Code Generation

License Support via PayPal

M3-V2 is a state-of-the-art causal language model featuring a novel architecture that enables advanced reasoning and self-correction. This model is fully open source under the Apache 2.0 license, making it available for academic, personal, and commercial use.

The model achieves a groundbreaking 98.17% Pass@1 score on the HumanEval benchmark, placing it at the cutting edge of AI code generation and making it one of the most powerful open-source code generation engines available today.


Benchmark Performance

The benchmark results demonstrate a level of performance that significantly surpasses many publicly available models.

HumanEval Benchmark Chart

Performance Comparison

ModelHumanEval Pass@1 ScoreNote
moelanoby/phi3-M3-V2 (This Model)95.12% / 98.17% / 98.56%Apache 2.0 License. Scores correspond to 0, 1, and 2 self-correction passes, with 1 being the default.
GPT-4.5 / "Orion"~96.00%Projected (Late 2025)
Gemini 2.5 Pro~95.00%Projected (Late 2025)
Claude 4~94.00%Projected (Late 2025)

A more reliable benchmark is one that's made by u/Chromix_

TestThis LLMPhi3-Mini-Instruct
junior-v2 Python8390 / 83
junior-v2 JavaScript7285 / 79
senior Python2559 / 30
senior JavaScript3937 / 23

Support the Project

M3-V2 is an open-source project, free for everyone to use. I am passionate about creating powerful and accessible AI tools for the community.

If you find this model helpful in your work, research, or personal projects, please consider supporting its development. Your contribution helps cover training costs, allows me to dedicate more time to improvements, and fuels the creation of new open-source models. Every little bit helps and is greatly appreciated!

Support via PayPal


License

This model is licensed under the Apache 2.0 License. You are free to use, modify, and distribute this model and its source code for any purpose, including commercial applications, subject to the terms of the license. You can find a copy of the license in the repository.

Ethical Considerations

While this model is open source, users are encouraged to use it responsibly. Finetuning the model to generate harmful, illegal, or unethical content is strongly discouraged. I advocate for the use of this technology to build positive and safe applications.

And please don't put the architecture in any image generation AI models I love supporting real artists very much and it would be sad that it gets taken over by AI art :/


How to Use

use the installation guide AND the python implementation :]

Installation

First, ensure you have the necessary libraries installed:

# python version >= 3.11
pip install torch transformers accelerate

Python Implementation

You can easily integrate the model into your application. You must use trust_remote_code=True for the custom architecture to load correctly from the Hub.

import torch
from transformers import AutoTokenizer, AutoModelForCausalLM

MODEL_ID = "moelanoby/phi3-M3-V2"

print("Loading tokenizer and model...")
tokenizer = AutoTokenizer.from_pretrained(
    MODEL_ID, 
    trust_remote_code=True, 
)
model = AutoModelForCausalLM.from_pretrained(
    MODEL_ID,
    trust_remote_code=True,
    torch_dtype=torch.bfloat16,
    device_map="auto",
)
print("Model loaded successfully.")

# --- Controlling the model's self-correction feature ---
# Default is 1 pass. You can adjust it for different performance profiles.
try:
    target_layer_path = "model.layers.15.mlp.gate_up_proj" 
    custom_layer = model
    for part in target_layer_path.split('.'):
        custom_layer = getattr(custom_layer, part)
        
    # Set the number of self-correction passes (e.g., 0, 1, 2, or 3)
    custom_layer.num_correction_passes = 2 
    print(f"✅ Number of self-correction passes set to: {custom_layer.num_correction_passes}")
except AttributeError:
    print("⚠️ Could not access the custom layer. The model will run with its default settings.")

# (Example generation code would follow here)

Important Notes

  • Downside: The model might become more incoherent or less accurate as you add more self-correction passes. Experiment to find the best balance for your use case.
  • Recommendations: You can use 1, 2, or 3 self-correction passes if needed. 2 passes is the most recommended setting for a balance of performance and coherence.

Acknowledgements

  • The base of this model utilizes the Phi-3 architecture developed by Microsoft.
  • The benchmark results were obtained using the HumanEval dataset from OpenAI.
  • I thank the open-source community for their continuous contributions to AI research.

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

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

GPU в ailist

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

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

Подбираем GPU…

Класс архитектуры
Phi3ForCausalLM
Ревизия весов
1f173e2

0 моделей