Skip to content

model_specs: declare the ASR, forced-aligner and codec options the sessions read - #406

Closed
CryptVenture wants to merge 1 commit into
0xShug0:mainfrom
CryptVenture:pr/spec-asr-aligner-options
Closed

model_specs: declare the ASR, forced-aligner and codec options the sessions read#406
CryptVenture wants to merge 1 commit into
0xShug0:mainfrom
CryptVenture:pr/spec-asr-aligner-options

Conversation

@CryptVenture

Copy link
Copy Markdown
Contributor

Split out of #372 as requested. This PR declares options the ASR, forced-aligner and codec sessions already read; the description-only fixes, the VoxCPM1 defaults, the strict contract fixes and the MiniMax declarations are separate PRs.

Additive throughout: no existing declaration changes, so nothing that validated before fails now.

The changes

Spec Added Code that reads it
parakeet_tdt language, accepted and ignored language is part of the OpenAI-compatible transcription contract and every other strict ASR family declares it, so a per-model rejection was a protocol violation. Parakeet reads only keep_language_tags (src/community_models/parakeet_tdt/session.cpp:285-286), which the description now states
sense_asr "vad" in the audio_chunk_mode enum src/community_models/sense_asr/session.cpp:512-524 throws only for QuietEnergy and implements the Vad branch — the mode worked and could not be requested
qwen3_forced_aligner seven prefixed session options src/models/qwen3_forced_aligner/session.cpp: weight_type, thinker_weight_type, audio_encoder_weight_type, audio_encoder_graph_arena_mb, thinker_prefill_graph_arena_mb, thinker_decode_graph_arena_mb, thinker_weight_context_mb
miocodec six prefixed session options src/models/miocodec/session.cpp: weight_type, weight_context_mb, constant_context_mb, content_graph_arena_mb, global_graph_arena_mb, wave_graph_arena_mb
mms_forced_aligner description only for return_timestamps The option is never read, but the family validates strictly and the CLI's --words-out injects the key, so removing it would break forced alignment from the command line. It is now documented as accepted and ignored

Validation

Backend: Metal, Apple M4 Max, macOS 15. Parakeet-TDT (parakeet-tdt-0.6b-v3-q8_0.gguf) loaded with model_spec_override pointing at the repository spec, because default_contract_spec_path (src/framework/model_spec/package.cpp:504+) prefers the spec embedded in the GGUF over the on-disk one:

POST /v1/audio/transcriptions {"model":"pk","audio":"...wav","options":{"language":"en"}}

main's spec:      500  {"error":{"message":"unknown Parakeet TDT request option: language"}}
this branch:      200  {"text":"At 3:45 pm on 14 October 2025, I jogged past 12 St. Peter Street, ..."}

Worth noting for release planning: because published GGUFs embed their own contract, this declaration reaches users of existing packages only when those packages are regenerated. It is correct in the repository either way, and it is what a freshly converted package will carry.

python3 tools/check_loader_catalog_sync.py
# ok: runtime loaders, model_specs, and model_manager_v2 are in sync

audiocpp_model_manager list --repository-root .        # exit 0

Scope

Five spec files, +120/-2. The generated WebUI bundle is deliberately excluded — catalog.ts inlines model_specs/*.json at frontend build time and the bundle is not byte-reproducible, so regenerating it in every PR of this split would make the PRs conflict with each other. Happy to send one bundle-regeneration PR once the series lands.

…ssions read

Additive: every option below is already read by the session and was undeclared
or misdescribed, so a client had no supported way to send it.

  - parakeet_tdt.language: accepted and ignored. `language` is a field of the
    OpenAI-compatible transcription contract and every other strict ASR family
    declares it, so a per-model rejection was a protocol violation. Parakeet
    reads only keep_language_tags (parakeet_tdt/session.cpp:285-286), which the
    description now says.
  - sense_asr.audio_chunk_mode: "vad" added to the enum. The session throws
    only for QuietEnergy and implements the Vad branch (sense_asr/session.cpp:
    512-524), so the mode worked and could not be requested.
  - qwen3_forced_aligner: the seven prefixed session options its session reads
    (weight_type, thinker_weight_type, audio_encoder_weight_type,
    audio_encoder_graph_arena_mb, thinker_prefill_graph_arena_mb,
    thinker_decode_graph_arena_mb, thinker_weight_context_mb), per
    qwen3_forced_aligner/session.cpp.
  - miocodec: the six prefixed session options its session reads (weight_type,
    weight_context_mb, constant_context_mb, content_graph_arena_mb,
    global_graph_arena_mb, wave_graph_arena_mb), per miocodec/session.cpp.
  - mms_forced_aligner.return_timestamps: description only. The option is never
    read, but the family validates strictly and the CLI's --words-out injects
    the key, so removing it would break forced alignment from the command line.
    The description now says it is accepted and ignored.
@CryptVenture
CryptVenture force-pushed the pr/spec-asr-aligner-options branch from 20eb0d2 to 5240265 Compare September 3, 2026 00:26
@CryptVenture

Copy link
Copy Markdown
Contributor Author

Closing for now to stay inside the 3-concurrent-PR policy (see the discussion on #422). Nothing is wrong with the change and CI is green on it; I will reopen it as review slots free.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant