Qwen3.5-0.8B astcss

Translates a developer's plain-English request into one astcss selector — a CSS-style query over an abstract syntax tree, executed by sitting_duck's ast_select.

methods of the Parser class   ->  .class#Parser .fn
functions that never raise    ->  .fn:not(:has(.throw))
calls to sleep                ->  .call#sleep
every with block              ->  with_statement

It needs the card

This model scores 0.0 % without its system prompt. It was trained with a per-language vocabulary card in the system position, and without one it answers as a chat model ("Here are the most effective ways to find…") rather than emitting a selector. Send the card for the language you are asking about; the cards are in the astcss-eval repo (train/cards/card_<lang>.md). Greedy decoding, thinking off, ~6 completion tokens per answer.

Scores

Execution match on 108 held-out pairs: a prediction counts only if running it returns exactly the same node set as the reference, on a real fixture, via the engine.

match T1 T2 T3 T4
this model 82.4 % 19/21 17/25 25/31 28/31
Qwen3.5-0.8B untuned, same card 26.9 % 10/21 12/25 5/31 2/31

For scale: at 1.6 GB it outscores several 9B–35B models prompted with the same card, and sits ~7 points below a LoRA-tuned 4B. It has not been trained on tier-5 selectors (call graph, scope, receivers) and scores ~31 % there.

Training

LoRA r=16, α=32, all-linear targets, 2 epochs, lr 2e-4, seed 18, float16 on one RTX 2080 Ti, then merged into the base. 820 execution-verified pairs across nine languages (Python, C, C++, Rust, Go, Java, JavaScript, SQL, Bash), capped at 8 per (request template, selector shape). Every training pair was executed against real code and kept only if its selector returned 1–50 nodes, every modifier changed the node set, its distractors returned different node sets, and no eval answer leaked in.

Build notes

  • Merged from the adapter with tune/merge_adapter.py, which verifies numerically that the LoRA deltas landed (186 targeted tensors at max|Δ| 4.6e-3) rather than trusting a silent merge, and the merged weights were re-scored at 82.4 % before upload.
  • Text-only build. Saved as Qwen3_5ForCausalLM; the base's vision tower (model.visual.*) and multi-token-prediction head (mtp.*) are not included. Use the base model if you need those.
  • Inherits the licence and terms of Qwen/Qwen3.5-0.8B.
Downloads last month
114
Safetensors
Model size
0.8B params
Tensor type
F16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for teaguesterling/qwen3.5-0.8b-astcss

Finetuned
(577)
this model