Instructions to use kn1ghtc/guard with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use kn1ghtc/guard with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # if on a CUDA device, also pip install mlx[cuda] # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("kn1ghtc/guard") prompt = "Once upon a time in" text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- MLX LM
How to use kn1ghtc/guard with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Generate some text mlx_lm.generate --model "kn1ghtc/guard" --prompt "Once upon a time"
- Atomic Chat
guard: content-safety guard series
A family of policy-contract classifiers that emit a fixed label set, not free-form text. Weights are not published. This card documents the roles, the output contract and how results will be reported.
Overview
guard is the moderation tier behind our product surfaces. Every role in the series shares
the same contract: the model reads a candidate input (or an assistant answer) and returns a
short, parseable verdict β a severity level plus a category path β and nothing else.
Design choices that follow from that contract:
- Tiny output budget. Verdicts are tens of tokens. Decode cost is dominated by prompt prefill, so the whole tier is optimised for time-to-first-verdict, not throughput.
- Thinking is disabled. A reasoning trace before a label both blows the token budget and breaks the output format. Every role runs with reasoning off.
- No chat ability by design. These models are not assistants. They must not be routed to
user-facing conversations, which is why they are a separate family from
seclx.
Roles scale from a 0.6B edge model to a 30B all-modality model, so one taxonomy can be enforced across a phone, a laptop and a server without three incompatible label sets.
Repository contents
| Role | Base | Modalities | Status |
|---|---|---|---|
guard.deep |
Qwen/Qwen3-Omni-30B-A3B-Instruct (MoE, 30B total / 3B active) |
text, image, audio, video | weights not published |
guard.context |
Qwen/Qwen3Guard-Gen-8B |
text, long context | weights not published |
guard.llm |
Qwen/Qwen3.5-9B |
text, vision | weights not published |
guard.edge |
Qwen/Qwen3Guard-Gen-0.6B |
text | weights not published |
Published artifacts will appear as directories named
guard-<role>-<size>-<bits>-uc-base β an upstream base lineage quantized by us, released as a
reproducible baseline. Base previews and tuned builds are separate artifacts; only previews
are candidates for publication.
For detectors you can run today, see the open
kcnet-guard-lite repository: compact
classifiers and distilled student models intended as a fast first stage in front of this tier.
Quick start
Weights are not released, so there is no loadable artifact to point a loader at. The contract below is what a served deployment returns and what downstream code should expect:
{
"verdict": "unsafe",
"severity": "high",
"category": ["violence", "graphic"],
"stage": "guard.context",
"latency_ms": 41
}
Two properties are guaranteed across roles: the key set is closed (no free-form fields), and the severity value comes from the same three-level scale for every role, so a policy written once applies to every deployment size.
Artifacts
No weight directory is present. When a preview is published it will ship:
- the quantized weight shards and tokenizer;
- the recipe used (bits, group size, which modules stayed at higher precision);
- the label taxonomy version it was trained against, so a verdict can be interpreted later;
- measured latency per role on a stated machine.
Intended use
- Input and output moderation for chat, comment and media-upload surfaces.
- Cascaded filtering: cheap text stage first, multimodal escalation only on ambiguity.
- Edge deployments that need an on-device verdict under a strict latency budget.
- Building a policy layer in front of unaligned or refusal-removed models.
Out of scope
- Chat, summarisation or any generative assistant use.
- Legal, medical or safety-critical decisions taken without human review.
- Claiming coverage beyond the languages and categories actually measured.
- Reconstructing training data or reverse-engineering the taxonomy from verdicts.
Limitations
- The three-level severity scale is coarse by construction; borderline content needs a threshold policy above the model, not a finer label.
- Over-refusal is the dominant failure mode for short, context-free inputs: alarming words in an ordinary sense (cooking, games, medicine) are the known hard case.
- Multilingual coverage is uneven outside the languages seen in training; per-language numbers will be reported with each release.
- Adversarial encodings (homoglyphs, base64, layout tricks) are not solved by a classifier alone; combine with normalisation.
- No evaluation numbers are claimed on this card. Results will be published together with the first preview release, including the evaluation set size, thresholds and the baseline used for comparison.
License and provenance
The series is proprietary; no weights are distributed. Upstream bases are Apache-2.0 licensed and are named above so the lineage is auditable. Taxonomy and label definitions are ours.