You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(crux-b-02): GGUF→safetensors output-layout + metadata-translation + PEFT target-module classifier (3 of 4 FALSIFY at PARTIAL_ALGORITHM_LEVEL)
Three pure classifiers in crates/apr-cli/src/commands/gguf_to_safetensors.rs:
1. hf_required_files() + missing_hf_files(listing) — canonical trio
{model.safetensors, config.json, tokenizer.json} that a converted
directory must contain. Without these filenames, no downstream
HF byte-level load can begin.
2. translate_gguf_metadata(gguf_kv) -> HfLlamaConfig — pure mapping
from GGUF llama.* keys onto the HF config.json fields. Missing
keys return Err(MissingKey) rather than silently defaulting,
which would let from_pretrained succeed with the wrong layer
count and produce garbage.
3. peft_target_modules_resolve(tensor_names, target_modules) —
substring-match check that every PEFT target (q_proj, v_proj, ...)
resolves to at least one tensor. Mirrors PEFT's own name-matching
rule. Unresolved targets are flagged before the attach call.
Contract crux-B-02-v1.yaml v1.0.0-draft -> v1.1.0 (draft -> partial):
- FALSIFY-001 (required files present): PARTIAL_ALGORITHM_LEVEL (5 tests)
- FALSIFY-002 (dequant numerical bound): NOT_DISCHARGED (needs Q4_K_M harness)
- FALSIFY-003 (transformers loads output): PARTIAL_ALGORITHM_LEVEL (8 tests)
- FALSIFY-004 (PEFT LoRA attaches): PARTIAL_ALGORITHM_LEVEL (5 tests)
18 / 18 tests pass. pv validate: 0 errors, 0 warnings.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
0 commit comments