Source-grounded passage humanizer

This checkpoint uses Qwen3-4B-Instruct-2507 with Unsloth's NF4 quantization. The writer takes one prose passage, decides whether it needs a repair, and selects the span to edit. A source-derived brief records the genre, purpose, takeaway, and relationships the edit should preserve. The writer proposes a replacement within that span and compares the result against the original for changes in meaning.

The published weights are the unadapted model from upstream revision 7744afa8566e264af1a92a806d8d9aae00cc7c78. The editing behavior is provided by the prompts, schemas and span renderer in writer.py. base-lock.json identifies the exact files for restoring the weights and tokenizer. Quantized checkpoint ยท Original Qwen model

Use

From a complete downloaded snapshot, use Python 3.11+ with PyTorch, Transformers, Accelerate, bitsandbytes, lm-format-enforcer and a CUDA GPU supporting native BF16. Supply UTF-8 JSON with an original field on standard input.

printf '%s\n' '{"original":"The two copies was legible."}' | python writer.py run

KEEP retains a passage the planner judged sound. UNCHANGED records a proposal that reproduced the source verbatim. REJECTED records a candidate that failed the meaning check. REVIEW returns both original and candidate for independent review. The full experiment also applies surface and logical-operator checks, bidirectional entailment and an independent repair judge before delivering an edit. This portable entry point stops at the candidate stage. Truncated or malformed generations raise an error.

For a review service, the standard-library messages command exposes the exact messages for each stage. plan and brief take the original passage. replace also takes a validated EDIT plan and an optional brief. semantic takes the original and the candidate. Schema-bearing stages return their JSON schema with the prompt.

printf '%s\n' '{"original":"The two copies was legible."}' | python writer.py messages plan

Measured limitations

On nine synthetic development passages, the guarded pipeline delivered the original passage for all nine. It preserved all three deliberately structured passages and completed zero of five required repairs. Missed edits included actor attribution, ordering an exception before a general instruction, and subjectโ€“verb agreement. No distinct delivered rewrites were available to measure author style. Larger or different passages require separate evaluation.

The checkpoint's upstream Apache 2.0 license is included in LICENSE.

Downloads last month
132
Safetensors
Model size
4B params
Tensor type
BF16
ยท
U8
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for kalcy0n/rewriter