/ Модель

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

Контекст
40 960 токенов
Параметры
1,7 млрд
Лицензия
Apache 2.0
Архитектура
qwen3 · dense
Базовая модель
Qwen3-1.7B
Библиотека
transformers
Опубликована
14 июл 2026

AHA-L2A-Qwen3-1.7B-repro

Генерация текстаТекст → текст

Экспериментальный пакет на базе Qwen3-1.7B для обучения и сравнения двух вариантов разреженного внимания в задачах длинного контекста.

20скачиваний за 30 дней0лайковвеса обновлены14 июл 2026

Бенчмарки

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

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

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

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

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

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

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

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

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

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

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

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

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

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

jiamingshan/AHA-L2A-Qwen3-1.7B-repro — пакет для воспроизводимого обучения и сравнения двух вариантов разреженного внимания на базе Qwen3-1.7B: AHA и L2A-style shared-gate. Это экспериментальный исследовательский репозиторий с кодом, рецептом обучения и оценивания; выбранные обученные чекпойнты AHA и L2A-style в репозитории отсутствуют и создаются при запуске обучения. Модель относится к плотной архитектуре Qwen3ForCausalLM, содержит 1,7 млрд параметров и поддерживает контекст до 40 960 токенов. В метаданных указаны английский язык и возможность диалога.

Варианты различаются гранулярностью маршрутизатора: AHA использует отдельный gate для каждого токена, KV-головы и слоя, а L2A-style — общий gate для всех голов токена в каждом слое. Оба варианта используют локальное внимание, дистилляцию скрытых состояний и восстановительное дообучение; пакет предназначен для воспроизведения эксперимента и сравнения качества со степенью разреженности на задачах длинного контекста. Авторы не заявляют ускорение, а результаты качества и разреженности не являются измерениями задержки.

Модель основана на дообученном чекпойнте Qwen/Qwen3-1.7B. Для обучения требуются Linux, Docker и видеокарта NVIDIA с 80 ГБ памяти; опубликованная конфигурация рассчитана на один GPU на вариант. Лицензия — Apache-2.0. Поскольку в репозитории нет готовых выходных чекпойнтов, для получения вариантов AHA и L2A-style необходимо выполнить описанный рецепт обучения.

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

  • воспроизведение эксперимента по разреженному вниманию
  • сравнение маршрутизации внимания по токенам и KV-головам
  • оценка качества и разреженности на задачах длинного контекста
  • обучение вариантов AHA и L2A-style на базе Qwen3-1.7B

Ограничения

Готовые обученные выходные чекпойнты AHA и L2A-style в репозитории отсутствуют, поэтому их нужно получить запуском рецепта на GPU NVIDIA с 80 ГБ памяти. Пакет не заявляет ускорения: метрики качества и разреженности не измеряют задержку.

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

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

Открыть на Hugging Face

AHA vs L2A-style shared-gate: Qwen3-1.7B reproducibility package

This repository is a self-contained package for training and evaluating two matched sparse-attention variants from the same tuned Qwen3-1.7B checkpoint. No separate source repository, starting checkpoint, or training dataset is required.

Start here

An arm means one independent experimental variant. It does not refer to an ARM processor or a group of GPUs.

VariantRouter granularitySelected output checkpoint
AHAone gate per token, KV head, and layer (token_kv_head)outputs/aha/stage2/checkpoint-25
L2A-style shared-gateone gate per token and layer, shared by every head (token)outputs/l2a_style/stage2/checkpoint-25

The L2A-style variant is not an official L2A implementation or a claim of exact L2A reproduction. Both variants use the same AHA code, local attention, losses, data, optimizer settings, and two-stage protocol. Router granularity is the only experimental variable.

The downloaded repository contains the exact tuned-vanilla starting checkpoint at its root. It does not contain pre-trained AHA or L2A-style output checkpoints; the training command below creates them.

Hardware and GPU behavior

  • Linux with Docker and NVIDIA Container Toolkit.
  • At least one NVIDIA GPU with 80 GB of memory. The protocol has been run on an A100 80 GB. H100 is expected to be compatible, but this release has not completed a separate end-to-end H100 validation.
  • At least 120 GB of free disk space is recommended for the Docker image, optimizer states, and intermediate checkpoints.
  • Internet access is needed for the initial Docker build and for public evaluation task dependencies.

Each variant is a single-GPU, world-size-1 run with global batch size 1:

  • With one GPU, AHA and L2A-style run sequentially on GPU 0.
  • With two or more GPUs, AHA runs on GPU 0 and L2A-style runs on GPU 1 concurrently.
  • On an eight-GPU machine, the default launcher still uses only GPUs 0 and 1; the other six GPUs remain unused.
  • The launcher does not use torchrun, DDP, FSDP, or DeepSpeed.

Using eight-way DDP for one variant would change the declared global batch size and optimization protocol, so it would no longer reproduce this experiment.

Train both variants

python -m pip install 'huggingface-hub==0.36.2'

hf download jiamingshan/AHA-L2A-Qwen3-1.7B-repro \
  --local-dir AHA-L2A-Qwen3-1.7B-repro

cd AHA-L2A-Qwen3-1.7B-repro
bash recipe/scripts/reproduce.sh

The host-side entry point builds the pinned Docker environment, verifies file hashes and dataset sizes, runs ten implementation tests, and then executes hot start, Stage 1, and Stage 2 for both variants. Do not run the Python training programs directly in the host environment.

The selected checkpoints are:

outputs/aha/stage2/checkpoint-25
outputs/l2a_style/stage2/checkpoint-25

Logs are written to outputs/aha/logs/ and outputs/l2a_style/logs/. The recovery stage continues through step 75 for diagnostics, but step 25 is the predeclared selected checkpoint. The launcher is restart-safe at completed checkpoint boundaries.

Exact training protocol

Both arms start from the tuned-vanilla checkpoint at repository root. Dynamic gate weights are zero and gate bias is initialized to logit(0.9), so the initial hard route is full attention.

StageDataLength / batchStepsTrainableLRObjectiveSeed
Hot starttuned vanilla—0none—90% full gate initialization—
1. Gate distillationbundled 1,024-row AM-distilled long mix8,192 / 1300 (0.293 epoch)native gate rows only3e-5hidden-state distillation + 0.1 × mean(gate_soft), CE=042
2. Grouped-LR recoverysame rows8,192 / 175; select step 25gate + backbone, embedding/LM head frozengate 3e-6, backbone 3e-7CE 1.0 + attention distill 0.5 + regularizer 0.0147

Both arms use 64 sink + 256 recent local attention. The Stage-2 train threshold is 0.58. The effective sparsity denominator is always token × KV-head × layer, including after broadcasting the shared token gate.

Machine-readable details are in recipe/protocol.json. Every checkpoint receives a training manifest containing the resolved granularity, native gate parameter count, data path, learning rates, threshold, seed, and source checkpoint.

Strict evaluation

After training:

bash recipe/scripts/evaluate.sh

This evaluates aligned tuned vanilla, AHA, and L2A-style checkpoints on:

  • local RULER 13-config set × 20 samples;
  • BabiLong qa1–qa5 × 50;
  • HELMET-ICL 5 configs × 50;
  • MRCR 2/4/8-needle × 10.

It scans inference thresholds 0.45, 0.50, 0.525, 0.55, 0.575, 0.60, 0.625, 0.65. Prefill and decode both use sparse routing. Full-decode fallback, force-full heads, head protection, and prefill-tail fallback are disabled.

The summarizer emits per-sample logs, per-config CSV, total JSON/CSV, prompt/target hash audits, and quality–sparsity plots under outputs/summary/. The headline point is the highest measured effective sparsity whose macro score is at least 95% of tuned vanilla on every suite. If no threshold passes, the output explicitly reports that no passing point was found.

The local RULER 13-config set is not claimed to be the complete upstream RULER suite. Quality–sparsity measurements are not latency measurements; this package makes no speedup claim.

Integrity and environment

The Docker image starts from pytorch/pytorch:2.9.1-cuda12.8-cudnn9-runtime. Exact Python dependencies are pinned in recipe/requirements.txt.

Before training, the launcher automatically:

  1. verifies SHA-256 for the starting weights, training Arrow file, frozen evaluation inputs, and core training sources;
  2. checks that the bundled dataset has exactly 1,024 rows;
  3. checks the 250 HELMET and 30 MRCR frozen rows;
  4. runs ten tiny-config tests covering router shapes, broadcast, full/local parity, regularizer equality, gate-only updates, true 10× grouped LR, save/load, embedded modeling code, one-step training, and native/effective sparsity accounting.

The source implementation corresponds to Git commit b47a549 on codex/l2a-router-granularity. File hashes are recorded in recipe/manifest.json.

Data and model note

The starting weights are derived from Qwen/Qwen3-1.7B. The bundled training and evaluation snapshots are provided to freeze the exact experimental rows. Users remain responsible for complying with the terms of the respective upstream model and datasets.

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

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

GPU в ailist

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

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

Подбираем GPU…

Класс архитектуры
Qwen3ForCausalLM
Ревизия весов
627d2a4

0 моделей