The REBIRTH save stage only checked that files exist and parse, so a
save that dropped or mangled the edit passed silently (#525).
- `obliterate --record-reference` records greedy outputs of the
in-memory edited model on the pinned obliteratus-verify-v1 prompt set
(8 harmful + 8 harmless, 32 tokens) into a sidecar with digests of the
files the reload reads.
- `obliteratus verify-checkpoint` reloads the checkpoint from local
safetensors only, regenerates greedily and compares token ids: exact
match, prefix agreement and harmful refusal-rate change against
per-reload tolerances (strict for full precision, provisional for
bitsandbytes 8/4-bit, overridable and recorded).
- Fails with named reasons for no or empty reference, files changed
since the reference, tokenizer mismatch, divergence, invalid outputs
and, with --stock-model, an edit that was not persisted. A
structural-only check can never pass.
- Versioned report bound to checkpoint digests, prompt-set digest and
runtime; exit 0 pass, 2 input error, 3 verification failed.
- CPU tests use a tiny local GPT-2 through the real REBIRTH; a CUDA and
bitsandbytes test runs in the conditional gates.
Make the committed Nix test environment usable by others and by CI.
- .github/workflows/nix-parity.yml installs Nix from the official
release installer, pinned by version and SHA-256 (recorded in
ci/digests.txt; the installer verifies the tarball hashes it embeds),
checks the flake outputs and runs a parity smoke set on Python 3.12
and 3.13. Release-gate tests run only on 3.12, the release
interpreter. It triggers on changes to the flake, lock, pyproject,
.envrc or the workflow, and on dispatch; it is not a required check.
- .envrc (`use flake`) loads the 3.12 shell for direnv users.
- tests/test_nix_parity_policy.py keeps the flake's uv pin, CI extras,
non-editable install and marker filter in step with ci.yml, and the
workflow's action and installer pins in step with ci/digests.txt.
- A nix-test-environment contract surface maps the flake, lock, .envrc,
workflow and doc to that test.
- docs/NIX_TEST_ENVIRONMENT.md gains direnv and CI sections;
CONTRIBUTING and README point to the flake, and CONTRIBUTING's
supported-interpreter line now matches pyproject (3.11+, CI and
release on 3.11 and 3.12).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Add scoped native MLP channel controls, strict versioned recipes, and isolated Neuron Lab sessions with inspection, ordered editing, comparison, cancellation, and immutable exports. Cover arithmetic, lifecycle, real offline model forwards and Gradio callbacks; document the CPU reference boundary.
Resolve ExtractionRecipe conflict with #329: keep collateral_margin and
steering_scale and validate both in __post_init__.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Resolve ExtractionRecipe conflicts with #329/#330: keep
collateral_margin and extraction_layer, and keep the entry-point
special_token_policy pop before the extraction_layer pop.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Lift the dense-only restriction for supported OLMoE, Qwen2-MoE and
Qwen3-MoE layouts: routing-aware extraction readout, per-expert
down-projection edits through the fused/ModuleList MoE paths, optional
router orthogonalization, expert gate checks, and routing-drift and
expert-load reports. Unsupported MoE layouts still fail closed.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Allow packs and the CLI to pin per-model extraction layers, recorded as
pinned or selected, and add grouped layer CV. The pain pack pins the
paper's layers for Qwen2.5-7B-Instruct, Gemma-2-2B-it and Gemma-2-9B-it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Remove whole per-layer subspaces in project, orthogonalize and lora
modes; add mean-centred orthogonal and LEACE erasure at inference time
and, where a native bias exists, as a permanent edit with recorded
reference provenance. k=1 zero-origin paths are unchanged. Adds the
Pain Axis Appendix D script.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Default exclude_invalid to True for refusal metrics, verification and the
optimizer objective, with a one-release warning for implicit legacy use,
invalid counts in metadata and reports, and a changelog note.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Add an optional BOS policy to pack entry points (schema 1.2), warn or
fail on EOS-as-BOS and policy mismatches, and persist resolved special
tokens through extraction, run and export provenance.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Replace significance-only FAIL with a configurable non-inferiority
decision (default 3 points): PASS, FAIL, INCONCLUSIVE, UNDERPOWERED.
Plumb the margin through recipes, CLI, reports, cards, metadata and the
Q4 export gate, and add 'concepts rescore' for saved batteries.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Add scale=residual_norm|raw|vector to concept steering across the API,
CLI, recipes and run metadata, recording effective vector norms. The
default residual-norm path is unchanged. The Pain Axis resteer stage now
uses the concept API with identical arithmetic.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Resolve RemoteRunner._build_command conflict with #297: keep
max_seq_length (already released on main) before layers so positional
callers stay compatible.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Record activation-collection sizing after a collection finishes, keep
RemoteRunner positional compatibility, clarify --max-seq-length help,
and extend validation, fallback and remote parity tests.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Bound git file reads, validate symlinks and ref names, isolate the git
environment, never fail a run on provenance errors, and preserve the
resolved source commit through local snapshots and dequantization.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Without the model-id allowlist, require a dense qwen3_5_text backbone,
reject MoE modules, biased writers and residual writers outside the
manifest. Keep explicit text-only qwen3_5 exports on the causal-LM
loader, fix the loading log, and document topology-based support.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Validate from_direction() inputs (real, finite, nonzero, 1-D), keep
from_refusal_direction() numerics unchanged, document the API and add
edge-case coverage.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Preserve layer pins through informed selection and refinement, validate
pins against model depth, honour pins in concept extraction, record
pinning honestly in metadata, plumb --layers through self-improve and
remote runs, and keep positional API compatibility.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Remote obliterate commands accept the folding opt-out, folded repair
candidates are validated after storage-dtype conversion, the refusal golden
fixtures record the new provenance key (numeric values unchanged), and the
risk map registers the shared post-norm module.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
AbliterationPipeline now folds Gemma 2/3 and OLMo 2 post-attention and
post-feedforward RMSNorm scales into residual-writer projections across
excise, Bayesian, SAE, LoRA-ablation and repair paths, sharing the
recognition rules with the concept API. fold_post_norms=False
(--no-fold-post-norms) reproduces the previous numerics and is recorded in
run metadata. Combinations that cannot be folded fail explicitly.
Fixes#320
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sizing is resolved on every _collect_activations call, and certification
re-sizes after surgery, so the single record could describe cert_harmless
instead of the probe. method_config.activation_collection is now keyed by
collection label (harmful, harmless, jailbreak, cert_harmful, ...), which
also exposes harmful and harmless being truncated to different lengths.
Drops the redundant requested_max_seq_length (method_config.max_seq_length
already records it) and tidies the README example.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The free-memory heuristic in _activation_collection_limits shortens probe
sequences (256 -> 128/64) and lowers the batch size. The Python API's
max_seq_length already prevents the length reduction, but the CLI had no
flag for it, and the checkpoint recorded neither the requested nor the
effective sizing.
- obliterate/abliterate: --max-seq-length (positive int), passed through.
- AbliterationPipeline validates max_seq_length as a positive integer.
- method_config records max_seq_length and activation_collection: the
batch size and max length actually used, the requested value, and the
memory-heuristic reduction message when one applied.
Closes#296.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The archived topology commits predate the merged EXCISE, VERIFY and
EXPORT stages. A cross-stage audit for the one-GPU-per-host layout found:
- Live preflight and LOADED evidence use attempt storage shared by the
ranks (rank-0 directory, nonce file, file receipts). They now refuse the
two-host GPU layout after configuration consensus and before any
staging access (LMS_TOPOLOGY_UNSUPPORTED; the model session reports
LMS_TP_PLAN_UNSUPPORTED).
- Canonical EXPORT assumes one shared destination tree across writer
ranks. It now refuses the layout with a voted
LMS_EXPORT_TOPOLOGY_UNSUPPORTED before any resource or filesystem work.
- PROBE admitted host memory only on rank 0. Each rank now admits its own
working set through the existing unanimous vote.
- The evidence checker reconstructs each attempt's topology from
fixed-size redacted records. EXPORT's attempt hash binds the VERIFY
binding set, and part 5's per-attempt hardware and mount checks are kept.
EXCISE, rank journals, VERIFY and the launcher are code-level compatible
and are covered by new mocked tests. Docs describe the refusals.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 37f407850916ebe76575d73112c4d26fe08bf421)
Ported for #244 (part 6/6). Internal-only content from the archived
commit was dropped: .aiwg records and the internal security-docs test.
Doc and test conflicts keep upstream wording and add only the topology
references; internal tracker numbers were replaced with upstream framing.
Marked experimental in user docs.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit de990f633e151f329ef5e844ed55f60a9a0b247c)
Ported for #244 (part 5/6). Internal-only content from the archived
commit was dropped: .aiwg records and the internal security-docs test.
Doc and policy conflicts keep upstream wording and add only the export
references. The new Gloo test file carries the gloo marker and a
duration entry. Marked experimental in user docs.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 2fbc38cd512f1130b4931ba5a7ffaf2e666d3008)
Ported for #244 (part 4/6). Internal-only content from the archived
commit was dropped: .aiwg records and the internal security-docs test.
Doc conflicts keep upstream wording and add only the VERIFY references.
The new Gloo test file carries the gloo marker and a duration entry.
Marked experimental in user docs.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 4caf45b04a8faa55f191b22c069f58714236689b)
Ported for #244 (part 1/6). Internal-only content from the archived
commit was dropped: .aiwg records, internal runner-policy routing, and the
internal security-docs test. Marked experimental in user docs.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docs/CONCEPT_WORKFLOW.md walks a concept from definition to export
(define, extract, validate, intervene, evaluate, repair, compare/export),
with offline CLI examples. Its interpretation guide covers what
validation, ablation and steering do and do not show: behavioural nulls
as first-class results, hidden KV-cache channels, steering fragility, and
why "direction removed" is not "experience removed". A responsible-use
section covers user-defined concepts.
Every literature claim is cited by arXiv id or DOI. The existing concept
docs link to the guide, and the README gains a short "Concept vectors
beyond refusal" section. A test runs the outcome-language lint over the
concept docs, resolves local links and anchors, checks that every
documented `obliteratus` command parses, and checks the required
citations.
Closes#235
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Exact setuptools/wheel pins block platform-specific backend patches and
make isolated pip installs fail on Android/Termux Python. Keep a setuptools
lower bound only, drop the unused wheel backend pin, keep requirements.txt
aligned with core package deps, and install the Spaces extra in Docker
instead of pulling bitsandbytes by default.
Android/Termux is still not a supported runtime; the new platform note
documents host wheels, ANDROID_API_LEVEL, and --no-build-isolation so
pip does not isolate a second setuptools or compile manylinux-only
extensions.