- shared/nextedit.ts: next-edit prompt format (region rewrite or NO_EDIT, Qwen spare special tokens) - shared/diagnostics.ts: TS errors near the cursor as context; symbols format 2 adds namespace imports - shared/prompt.ts: token healing (cut the half-typed word, force it via grammar), errors header section - daemon: model profiles carry contextFormat/errors/members/nextEdit; /v1/next-edit with edit-burst tracking; /v1/prewarm; /v1/debug/last; token healing on by default - extension: next-edit decorations (Tab apply / Esc dismiss), suggest on cursor move, prewarm on focus, Show Last Prompt, update check against releases, diagnostics in the edit recorder - models/README: training-data attribution; release script profiles for stage-d/stage-e - .gitea/workflows/ci.yml: build + test, publish release on vscode-v* tags (needs a runner + RELEASE_TOKEN) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J39imRDT8L7xYbWzsVWd8A
4.5 KiB
Models
Q8_0 GGUF fill-in-the-middle models for the Local Autocomplete extension, fine-tuned from Qwen2.5-Coder-0.5B for TypeScript, Vue and Node.js.
| model | description | prompt order | context modes | size |
|---|---|---|---|---|
stage-c |
Suffix-first FIM with repo/symbol-context headers (default) | spm | symbols, simple | 531 MB |
stage-b |
Suffix-first FIM without context headers (previous stage) | spm | raw | 531 MB |
The extension reads manifest.json, downloads the selected model once, verifies its SHA-256 and
runs it locally with llama.cpp. The files are stored with Git LFS; download links use Gitea's /media/ route:
https://git.harvmaster.com/Harvmaster/autocomplete-model/media/branch/main/models/<file>
Evaluation (612 held-out samples from private repos the model never saw, suffix-first prompts)
| exact match | edit similarity | still parses | |
|---|---|---|---|
| Qwen2.5-Coder-0.5B (base) | 0.270 | 0.506 | 0.783 |
| Qwen2.5-Coder-1.5B (base) | 0.366 | 0.623 | 0.882 |
stage-b |
0.391 | 0.689 | 0.952 |
stage-c (with symbol context) |
0.397 | 0.681 | 0.954 |
The base models were evaluated in their native prefix-first order (they can't do suffix-first). Suffix-first prompts let the editor reuse the KV cache while typing: about 2 tokens re-processed per keystroke, ~90–100 ms end-to-end on a laptop CPU.
Using the files directly
Any llama.cpp-based runtime works, but the prompt must match the training layout. The
daemon and shared/prompt.ts are the reference.
Suffix-first (spm) order:
<|fim_prefix|><|fim_suffix|>{suffix}<|fim_middle|>{prefix} → model generates the middle, then <|endoftext|>
stage-c additionally expects a repo-level header: <|repo_name|>{repo}\n<|file_sep|>{path}\n, optionally with a
__symbols__.d.ts pseudo-file of available symbols before it.
Training data
Fine-tuned on permissively licensed open-source repositories (below, pinned commits) and on the publisher's own code (not published). Secrets were scrubbed from all training data; held-out evaluation repos were never trained on.
License
Apache-2.0 (LICENSE, NOTICE), as a derivative of Qwen2.5-Coder.