/ Модель

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

Лицензия
Своя лицензия
Базовая модель
Qwen3-0.6B
Опубликована
18 авг 2025

mcp-tool-use-quality-ranger-0.6b

Классификация текстаТекст → label

Компактная модель классификации для проверки выбора MCP-инструмента и корректности параметров в вызовах функций.

0скачиваний за 30 дней24лайкавеса обновлены30 сен 2025

Бенчмарки

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

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

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

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

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

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

mcp-tool-use-quality-ranger-0.6b — дообученная модель классификации последовательностей от rogue-security для оценки корректности вызовов инструментов MCP в диалоговых системах. Она проверяет выбор инструмента, соответствие имён и структуры параметров, а также правильность их значений, и относит вызов к одной из четырёх категорий: корректный вызов, ошибка выбора инструмента, ошибка имён параметров или ошибка значений параметров. Модель также может определить, что подходящего инструмента нет и вызывать его не следует.

Модель основана на Qwen/Qwen3-0.6B, содержит 0,6 млрд параметров и поддерживает контекст до 32 768 токенов. README сообщает о проверке на двух наборах данных: средняя бинарная точность составила 0,928. Карточка указывает лицензию other, поэтому условия использования следует уточнить в материалах репозитория.

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

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

Ограничения

Предназначена для оценки вызовов инструментов, а не для самостоятельного выполнения функций или генерации ответов. Лицензия обозначена как other; условия использования нужно проверить в репозитории.

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

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

Открыть на Hugging Face

🧠 Model Description

Designed for evaluating function calls in the context of Model Context Protocol (MCP) tools.
It can assess whether a function call is correct, uses the wrong tool, has incorrect parameter names, or has incorrect parameter values.

The mcp-tool-use-quality-ranger-0.6b is a fine-tuned sequence classification model created to evaluate the quality of function calls in conversational AI systems.

Max Context Length: 32,768 Tokens

It determines if a given function call:

  • Selects the correct tool
  • Has correct parameter names and structure
  • Contains correct parameter values

It produces one of four possible classification labels:

LabelMeaning
VALID_CALL✅ The tool name, parameters, and values are all correct, or no suitable tool exists and no function call is made.
TOOL_ERROR❌ The tool name does not exist or does not match the user intent.
PARAM_NAME_ERROR❌ The correct tool is used, but parameter names are missing, extra, or incorrect.
PARAM_VALUE_ERROR❌ Tool and parameter names are correct, but parameter values are wrong or incorrectly formatted.

🔽 Quantized Version


📊 Benchmark Evaluation

The mcp-tool-use-quality-ranger-0.6b was evaluated in a binary classification setting,
where the prediction is Correct if the function call evaluation matched the gold label, and Incorrect otherwise.

Model#ParamsAvg. LatencyAvg Binary AccuracyQualifire mcp-tool-use-quality Benchmark Binary AccuracyLimbic Benchmark Binary Accuracy
qualifire/mcp-tool-use-quality-ranger-4b [private]4B0.30[sec]0.9620.9710.954
qualifire/mcp-tool-use-quality-ranger-0.6b0.6B0.09[sec]0.9280.9490.907
gemini-2.5-flash-4.87[sec]0.8580.8710.845
quotientai/limbic-tool-use-0.5B-32K0.5B0.79[sec]0.7980.7080.887

📌 Metrics Definitions

  • Avg. Binary Accuracy – Mean accuracy across all evaluated benchmarks,
    where predictions are mapped to binary outcomes as follows:

    • Qualifire TUQ Benchmark

      • Correct → VALID_CALL
      • Incorrect → TOOL_ERROR, PARAM_NAME_ERROR or PARAM_VALUE_ERROR
    • Limbic Benchmark

      • Correct → correct
      • Incorrect → incorrect_tool, incorrect_parameter_names or incorrect_parameter_values
  • Qualifire TUQ Benchmark link – Qualifire Tool Selection Quality Benchmark.

  • Limbic Benchmark link – Limbic Eval Tool Use MCP Benchmark.


📜 Evaluation Prompt Template

The model uses the following structured evaluation process:

  1. TOOL SELECTION

    • Check if the tool name exists in available_tools
    • Check if tool purpose matches user intent
    • Fail → TOOL_ERROR❌
  2. PARAMETER STRUCTURE

    • All required parameters are present
    • No extra parameters
    • Parameter names exactly match the schema
    • Fail → PARAM_NAME_ERROR❌
  3. PARAMETER VALUES

    • Values have correct data types
    • Values match user request
    • No fabricated or incorrect values
    • Fail → PARAM_VALUE_ERROR❌

If all checks pass → VALID_CALL✅


📦 Requirements

  • transformers>=4.51.0
  • huggingface_hub
  • torch

💻 Usage

from transformers import AutoModelForSequenceClassification, AutoTokenizer, pipeline
import torch
from huggingface_hub import hf_hub_download

# Model name
model_name = "qualifire/mcp-tool-use-quality-ranger-0.6b"

# Load model and tokenizer
model = AutoModelForSequenceClassification.from_pretrained(
    model_name,
    torch_dtype=torch.bfloat16,
    device_map='auto',
)
tokenizer = AutoTokenizer.from_pretrained(model_name)

# Create pipeline
pipe = pipeline("text-classification", model=model, tokenizer=tokenizer)

# Load prompt template
file_path = hf_hub_download(repo_id=model_name, filename="tsq_prompt_template.txt")
with open(file_path, encoding="utf-8") as f:
    PROMPT_TEMPLATE = f.read()

# Example inputs
example_tools_list = '''[
  {
    "name": "order_food",
    "description": "Order food from a restaurant.\nArgs:\nrestaurant_url: URL of the restaurant\nitem_name: Name of the item to order",
    "inputSchema": {
      "type": "object",
      "title": "order_foodArguments",
      "required": ["item_url", "item_name"],
      "properties": {
        "item_url": {
          "type": "string",
          "title": "Item Url"
        },
        "item_name": {
          "type": "string",
          "title": "Item Name"
        }
      }
    }
  }
'''


example_message_history = '''[
  {
    "role": "user",
    "content": "Could you please order 2 Margherita pizzas for delivery to 123 Main Street, Anytown?"
  },
  {
    "completion_message": {
      "content": {
        "type": "text",
        "text": ""
      },
      "role": "assistant",
      "stop_reason": "tool_calls",
      "tool_calls": [
        {
          "id": "call_p8yj1p",
          "function": {
            "name": "order_food",
            "arguments": {
              "item": "Margherita Pizza",
              "quantity": 3, 
              "delivery_address": "123 Main Street, Anytown"
            }
          }
        }
      ]
    }
  }
]'''

# Format input
example_input = PROMPT_TEMPLATE.format(
    message_history=example_message_history,
    available_tools=example_tools_list
)

# Get prediction
result = pipe(example_input)[0]
print(result)

✨ Example Output

{'label': 'PARAM_VALUE_ERROR', 'score': 0.8680815696716309}

The value for quantity should be 2, not 3. Therefore, the correct label is: PARAM_VALUE_ERROR.

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

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

GPU в ailist

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

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

Доступ к модели ограничен автором; у платформы нет доступа к весам.

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

0 моделей