/ Модель

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

Контекст
32 768 токенов
Параметры
257 млн
Лицензия
Gemma
Архитектура
gemma3_text · dense
Базовая модель
gemma-3-270m
Библиотека
transformers
Опубликована
1 мар 2026

AISA-AR-FunctionCall-Think

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

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

281скачиваний за 30 дней3лайкавеса обновлены1 июн 2026

Бенчмарки

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

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

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

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

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

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

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

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

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

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

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

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

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

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

AISA-AR-FunctionCall-Think — компактная текстовая модель Tuwaiq Academy для вызова функций по арабским запросам. Это официальный базовый вариант для Track B задания AISA-ArabicFC на ArabicNLP 2026: модель формирует короткую цепочку рассуждений на арабском языке, затем выдаёт структурированный вызов выбранного инструмента либо пропускает вызов, если он не нужен.

Модель построена на Gemma 3 и дообучена методом LoRA на данных AISA-ArabicFC с арабскими примерами рассуждений; адаптер объединён с базовой моделью для обычного инференса. В ней около 257 млн параметров, архитектура Gemma3ForCausalLM, формат весов safetensors, контекст — до 32 768 токенов. Она рассчитана на запросы на арабском языке, включая пять диалектов, и на заданный формат диалога и схемы инструментов.

На тестовом наборе авторы сообщают точность выбора функции 0,982 и точное совпадение аргументов 0,541; результаты относятся к заданию и его тестовому набору. Модель предназначена прежде всего для воспроизведения базового результата и экспериментов с арабским вызовом инструментов. Она ограничена схемой из 27 инструментов и восьми предметных областей, однократным вызовом в одном ходе и заданным форматом подсказки; качество извлечения аргументов и устойчивость между диалектами неодинаковы. Лицензия — Gemma.

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

  • Выбор нужного инструмента по запросу на арабском языке
  • Извлечение аргументов для структурированного вызова функции
  • Определение, требует ли запрос вызова инструмента
  • Эксперименты с агентами, использующими инструменты на арабском языке
  • Воспроизведение базового результата Track B задания AISA-ArabicFC

Ограничения

Модель обучена под заданную схему из 27 инструментов и формат подсказки AISA-ArabicFC; поведение с произвольными инструментами, многошаговым диалогом и несколькими вызовами не определено. Точное извлечение аргументов несовершенно, а качество различается между диалектами, особенно для диалектов Магриба, представленных мало в обучающих данных.

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

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

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

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

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

Открыть на Hugging Face

AISA-AR-FunctionCall-Think

🏷️ Official Track B baseline for the AISA-ArabicFC shared task @ ArabicNLP 2026 (co-located with EMNLP 2026, Budapest)

This model is the organizer-provided baseline for Track B — Reasoning-Augmented Function Calling. It defines the reference score that participating systems are expected to beat. It is released for reproducibility and as a starting point — it is not a competition entry.

A compact (270M-parameter) Arabic function-calling model that, given an Arabic user query (in any of 5 dialects) and a set of candidate tools, writes a short Arabic <think> reasoning trace and then emits a structured tool call. Fine-tuned (LoRA) from google/gemma-3-270m on the AISA-ArabicFC reasoning data.

For the non-reasoning Track A baseline, see the sibling model AISA-AR-FunctionCall-FT.


At a glance

RoleOfficial baseline — Track B (Reasoning-Augmented)
Base modelgoogle/gemma-3-270m (270M params)
AdaptationLoRA fine-tune (merged), then full causal-LM inference
LanguagesArabic — MSA, Gulf, Egyptian, Levantine, Maghrebi
Behaviour<think> Arabic reasoning → structured function call
Training dataTuwaiqAcademy/AISA-ArabicFC
LicenseGemma (see License below)

The shared task

Given an Arabic user query and a set of candidate tool definitions, a system must:

  1. Decide whether a function call is required (some queries need no tool),
  2. Select the correct function name,
  3. Extract the structured arguments,
  4. (Track B) Generate an Arabic reasoning trace (<think> … </think>) before the call.
TrackDescription
A — CoreDecide / Select / Extract
B — Reasoning-Augmented ← this modelTrack A + an Arabic <think> reasoning trace
C — Cross-Dialect RobustnessDiagnostic: dialect-stratified evaluation of A/B submissions

How it works — input / output format

This model uses Gemma 3 chat turns with a custom function-calling schema (it does not emit plain JSON). The exact prompt is the text field in the dataset; the structure is:

<bos><start_of_turn>developer
<system instruction in Arabic>
<start_function_declaration>declaration:NAME{description:<escape>…<escape>,parameters:{…}}<end_function_declaration>
…one declaration per candidate tool…<end_of_turn>
<start_of_turn>developer
التاريخ والوقت الحالي …: 2024-04-12T23:05:24
اليوم هو الجمعة
أنت نموذج يمكنه استدعاء الوظائف التالية<end_of_turn>
<start_of_turn>user
أريد مقارنة أسعار تلفاز سامسونج في الأردن<end_of_turn>
<start_of_turn>model

The model then generates:

<think>
يبدو أن نية المستخدم هي الحصول على مقارنة لأسعار تلفاز سامسونج في الأردن. أداة "compare_prices" هي الأنسب …
</think>
<start_function_call>call:compare_prices{country:<escape>Jordan<escape>,product_name:<escape>Samsung TV<escape>}<end_function_call>

For a query that needs no tool, the model omits the <start_function_call> block (→ requires_function = false).


Usage

import re, torch
from transformers import AutoTokenizer, AutoModelForCausalLM

MODEL_ID = "TuwaiqAcademy/AISA-AR-FunctionCall-Think"
tok   = AutoTokenizer.from_pretrained(MODEL_ID)
model = AutoModelForCausalLM.from_pretrained(
    MODEL_ID, torch_dtype=torch.float32, device_map="auto"
).eval()

def parse_model_output(text: str) -> dict:
    """Turn raw generation into the shared-task submission schema."""
    out = {"requires_function": False, "function_name": "none", "arguments": {}, "think": ""}
    if (m := re.search(r"<think>\s*(.*?)\s*</think>", text, re.DOTALL)):
        out["think"] = m.group(1).strip()
    if (m := re.search(r"<start_function_call>\s*call:(\w+)\{(.*?)\}\s*<end_function_call>", text, re.DOTALL)):
        out["requires_function"] = True
        out["function_name"] = m.group(1)
        for key, str_val, num_val in re.findall(r"(\w+):(?:<escape>(.*?)<escape>|([^,}]+))", m.group(2)):
            val = str_val if str_val else num_val
            try:
                val = float(val) if "." in str(val) else int(val)
            except (ValueError, TypeError):
                pass
            out["arguments"][key] = val
    return out

# Easiest path: take the ready-made prompt from the dataset's `text` field and
# cut it at the model turn (everything after is what the model should produce).
from datasets import load_dataset
row = load_dataset("TuwaiqAcademy/AISA-ArabicFC", split="validation")[0]
prompt = row["text"].split("<start_of_turn>model\n")[0] + "<start_of_turn>model\n"

inputs = tok(prompt, return_tensors="pt", add_special_tokens=False).to(model.device)
with torch.no_grad():
    gen = model.generate(**inputs, max_new_tokens=250, do_sample=False)  # greedy
raw = tok.decode(gen[0][inputs["input_ids"].shape[1]:], skip_special_tokens=False)

print(parse_model_output(raw))
# → {'requires_function': True, 'function_name': 'compare_prices',
#    'arguments': {'country': 'Jordan', 'product_name': 'Samsung TV'},
#    'think': 'يبدو أن نية المستخدم …'}

The parsed dict maps directly onto a leaderboard submission line: {"id", "tool_called", "arguments", "think"} (use function_name → tool_called).


Evaluation

Scored on the AISA-ArabicFC held-out test set (1,000 positive + negative examples) using the official v2 metrics:

  • FnAcc — function-name accuracy over all samples (also penalises hallucinated / missed calls; negatives have gold none)
  • ArgEM — strict argument exact match, over positives only
  • ThinkRate — fraction of outputs with a non-empty <think> trace
  • Overall (Track A) = 0.40·FnAcc + 0.60·ArgEM
  • Overall (Track B) = 0.30·FnAcc + 0.50·ArgEM + 0.20·ThinkRate

Baseline results

SystemFnAccArgEMOverall (A)Overall (B)
AISA-AR-FunctionCall-Think (270M) ← this0.9820.5410.7170.739
GPT-4o — zero-shot0.9270.0700.4130.313
GPT-4o — 3-shot0.8540.1220.4150.317
Random baseline0.0470.0330.0390.031
  • Think-Before-Call rate (ThinkRate): 0.868 for this model; 0.000 for all non-reasoning baselines.
  • Hallucination rate: 0.000 on negative (no-tool) queries.

Key takeaways

  • 🎯 Argument extraction is the open challenge. Tool selection is largely solved (FnAcc ≈ 0.98), but strict argument exact match tops out at 0.541 — and GPT-4o reaches only 0.070 zero-shot. This is where the task is won or lost.
  • 🪶 A 270M model beats GPT-4o across every metric here, showing the value of task-specific Arabic training and lowering the compute barrier to entry.
  • 🗣️ Cross-dialect gaps remain. FnAcc varies by roughly 10–15 points across dialects, with Gulf and Levantine consistently the hardest and Maghrebi (small sample) the easiest — see the Track C diagnostic in the task overview paper.

Training

  • Base: google/gemma-3-270m
  • Method: LoRA (rank 64), 3 epochs, cosine LR scheduler
  • Data: AISA-ArabicFC training split (~10.5K examples) with 12,000 Arabic reasoning annotations for the <think> traces
  • Objective: produce a short Arabic reasoning trace followed by a single structured tool call (or no call for negatives)

Intended use & limitations

Intended use

  • A reference baseline to compare against and reproduce for the AISA-ArabicFC shared task.
  • A lightweight starting point for Arabic tool-use / agentic experiments.

Out of scope / limitations

  • Trained for the 27-tool, 8-domain AISA-ArabicFC schema and its prompt format; behaviour on arbitrary tools or free-form chat is undefined.
  • Single-turn, single-call setting — no multi-tool or multi-turn dialogue.
  • Argument extraction is imperfect (ArgEM 0.541): expect errors in date normalisation, numeric typing, and dialectal argument phrasing.
  • Uneven dialect coverage (Maghrebi is only ~1.3% of data); robustness varies by dialect.
  • A 270M model — capacity-limited by design to keep the baseline accessible.

Related resources


Citation

@inproceedings{najar2026aisaarabicfc,
  title     = {AISA-ArabicFC: Arabic Function Calling for Agentic AI Systems},
  author    = {Najar, Omar},
  booktitle = {Proceedings of the Fourth Arabic Natural Language Processing Conference (ArabicNLP 2026)},
  year      = {2026}
}

License

This model is a derivative of Gemma 3 and is distributed under the Gemma Terms of Use. By using it you agree to those terms and to the Gemma Prohibited Use Policy. The AISA-ArabicFC dataset is released separately under Apache-2.0.

Contact

Shared-task organizers — trdc@tuwaiq.edu.sa · Tuwaiq Academy

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

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

GPU в ailist

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

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

Подбираем GPU…

Класс архитектуры
Gemma3ForCausalLM
Ревизия весов
a146440

0 моделей