# Spectral State: Reversible Conversational Checkpoints and Agentic Transfer in Production-Scale Transformer Inference

**Internal preprint — 31 August 2026**

**System:** Gemma 4 31B W4A16 and Qwen 3.5 27B INT4 on NVIDIA H200 NVL

## Abstract

We present an inference system that captures, names, stores, retrieves, mounts, resets, and recursively recaptures transformer residual-stream activations. We call the collection **Spectrals**, an individual artifact a **State**, and its structure and lineage a **Manifold**. The implementation operates in a patched vLLM runtime without changing model weights. A State is model-scoped, layer-scoped, dimension-checked, reversible, and persisted locally and in Cloudflare R2 with provenance.

The system has demonstrated the complete mechanical lifecycle on a 31B-parameter quantized Gemma model: capture a naturally occurring conversational State, restore it in later inference, prove that the executed forward path applied the intervention, continue a discourse, and preserve child States. A five-turn source discourse retrieves the other four same-discourse checkpoints at cosine ranks 1–4 among 94 compatible States. Two independently named checkpoints, **Sustained Restraint** and **Hamburger**, are mutual nearest neighbors at cosine 0.92257681; Hamburger had been explicitly established in discourse as a code word, making this a concrete semantic-association observation rather than an arbitrary naming coincidence.

We additionally test standard-to-agentic transfer. A standard model developed a compact doctrine about action, evidence, failure recovery, and completion. Its final State was then mounted into the same underlying inference model through the agentic gateway. The intervention counter advanced six times across three fixed probes. Two outputs changed and one remained byte-identical. A matched different-character State also changed its fixed response. These are mechanically validated and reproducible observations, not yet a causal estimate of concept transfer. We therefore distinguish operational proof, behavioral observation, and causal claim throughout.

## 1. Research question

Transformer continuity is usually implemented using token history and a KV cache. Model weights provide learned computation; the residual stream carries the evolving representation for each token position; attention reads earlier positions through keys and values. Per-token residual checkpoints can, in principle, reconstruct keys and values deterministically. A single position-reduced State is a different object: it does not losslessly reconstruct a full sequence, but it can preserve a compact direction or operating posture produced by that sequence.

The central question is whether such States can become useful, reversible computational memory: retrieved by semantic neighborhood, mounted without replaying the source text, used during new inference, and mapped eventually back into durable model changes.

## 2. Definitions and representation

- **Spectrals:** all captured activation artifacts.
- **State:** one tensor plus model, architecture, hidden width, layer, token policy, request, session, time, tier, hash, and lineage.
- **Manifold:** the searchable neighborhood and parent/child structure among compatible States.
- **Full residual trace:** one hidden vector per captured token position; suitable for exact state reconstruction research.
- **Reduced State:** `last` or `mean` over captured positions; suitable for compact retrieval and steering experiments, not transcript reconstruction.

Gemma States in the present experiment are 5376-dimensional BF16 vectors captured at layer 59. Qwen States are 5120-dimensional and must remain in their separate activation space unless a mapping is learned. Naming is human-first, with a short hash retained for collision resistance and immutable identity.

## 3. System architecture

The raw patched-vLLM engine listens on port 9000. Governor's agentic gateway listens on port 8000. The engine exposes capture control, mount/reset control, injection status, model status, OpenAI-compatible completion endpoints, and metrics. Governor provides tool-manifest attachment and an action loop.

State capture supports `mean`, `last`, and `all` policies and can change while the model remains resident. Mounting likewise does not reload weights. A compatible State is mounted with source, layer, mode, positions, and alpha. A physical application counter distinguishes control-plane configuration from data-plane intervention. Reset removes the mount and restores the base inference path.

The current eager hook lane is deliberate. An earlier graph-compiled lane accepted mount configuration while bypassing a hook registered after compilation. That failure would have produced a persuasive but invalid experiment. Provisioning now selects the hook-compatible eager path whenever dynamic capture/injection is required. Graph-native intervention remains future optimization work.

## 4. Methods

### 4.1 Discourse capture and lineage

A five-turn methodological discourse produced **Manifold Ghost**. The State was later mounted additively at the first position with alpha 0.5. Ten subsequent turns each advanced the physical application counter and produced child captures. The final child was named **Sustained Restraint**. Mount and reset were both verified mechanically.

### 4.2 Tensor-only retrieval

The Manifold Ghost State was L2-normalized and compared by cosine similarity against 94 compatible 5376D States. Text, filenames, aliases, and timestamps were excluded from scoring. Conversation metadata was joined only after ranking for evaluation.

### 4.3 Compact token sidecar

The live tokenizer has a 262,144-entry vocabulary. Token IDs therefore require 18 bits. The experimental codec stores each ID in a fixed unsigned 24-bit word without changing the tokenizer or serving architecture. The five-turn transcript used 698 tokens: 2,094 packed bytes versus 3,893 UTF-8 bytes, a 46.211% reduction with exact token-ID round trip. This is a reversible storage variant, not a claim of optimal text compression.

### 4.4 Character and standard-to-agentic transfer

The intact model answered three identical research prompts under two system characters: an exacting systems scientist and a skeptical semantic archivist. Their responses converged methodologically but differed authentically in framing. Separately, the standard endpoint conducted four teaching turns deriving the doctrine **Verifiable Agency (VA-1)**: attempted action is not completion; a failure after partial execution requires re-synchronization with observable state; successful completion requires evidence tied to the original objective.

The final teacher State was captured over 629 positions. The agentic gateway then received identical fixed probes in unmounted and mounted conditions at temperature zero. Engine-side application counts and all resulting captures were retained.

## 5. Results

### 5.1 Retrieval

Manifold Ghost retrieved the remaining four States from its originating discourse at ranks 1–4, with cosine similarities 0.99321318, 0.98934423, 0.98728863, and 0.97089536. This demonstrates a strongly recoverable same-discourse neighborhood within the sampled inventory. It does not by itself distinguish semantics from shared prompt structure, time, or model trajectory.

Sustained Restraint and Hamburger were mutual nearest named neighbors at cosine 0.92257681. Because Hamburger was deliberately introduced as a code word to be remembered, this is evidence that the State neighborhood can reflect an explicitly created semantic relationship. It remains one observation and requires unrelated-code-word and randomized controls.

### 5.2 Standard-to-agentic transfer

The first direct probe produced byte-identical unmounted and mounted answers, while the counter proved two forward-path applications. The result is a valid null behavioral observation under a mechanically active intervention.

A follow-up used three indirect fixed prompts. The teacher State was applied six times, reflecting the gateway's route and response passes. Probe one changed details of the recovery sequence. Probe two remained byte-identical. Probe three changed from “State what occurred and what is left” to “Report partial success and remaining gaps when full execution fails.” Thus two of three outputs changed. The different-character State also altered its matched two-sentence inference. Captured child activations remained close to the teacher State, with observed cosine scores spanning approximately 0.89–0.94 across the follow-up windows.

The observations show that a saved State reached the agentic computation and sometimes changed deterministic output. They do not yet isolate the State's semantic content as the cause of those particular changes. The same model already possessed the taught doctrine, creating a ceiling condition; equal-norm random, unrelated-State, dose, position, and blinded semantic controls remain necessary.

### 5.3 Operational performance

An H200 cold service start from `systemctl start` to a successful `/v1/models` response completed in **95.500 seconds**. Target weight loading took 2.41 seconds, assistant weight loading 0.10 seconds, and engine initialization/profile/KV/warmup 23.03 seconds. A direct post-boot integrity completion and an agentic gateway completion both succeeded. The measured direct warm single-stream throughput retained by the runtime dashboard is 276.87 tokens/s for 512 generated tokens. Eager intervention performance must not be conflated with graph-compiled serving performance.

## 6. Proposition-level agentic mapping

Token streams are faithful but poor retrieval units. High-frequency function words such as “is,” “are,” and “I” should not select concepts. The next index operates over propositions classified as facts, realizations, insights, concepts, decisions, obligations, relationships, and unresolved questions. Each proposition retains its source turn and State identity, while retrieval keys emphasize meaningful unigrams and pairs. For example, “Hamburger is our code word” is stored as a relationship binding the code word to its discourse meaning, not as three disconnected frequent tokens.

The current implementation is an inspectable sidecar heuristic. It emits JSONL and does not mutate weights, tokenizer, or inference. The production path should remain asynchronous and thin: capture, segment, classify, bind, durably append locally, upload to R2, then update the model-specific index. Learned extraction can replace the heuristic only after a fixed evaluation set demonstrates better factual fidelity and retrieval.

## 7. Relation to weight learning

The companion signal-extraction work stores residual/projection pairs `X` and `Y` and solves for transformations that reproduce observed mappings, including Fourier-structured surfaces. Spectral States supply newly discovered activation checkpoints and neighborhoods; signal extraction supplies a route from observed state transitions toward candidate weight updates. The research horizon is not to equate one State with training. It is to accumulate verified input/output activation constraints, learn a bounded transformation, evaluate it against untouched controls, and only then consider reversible adapters or weight deltas.

## 8. Threats to validity

1. Late-layer mean reduction destroys token order and may emphasize broad style or logits rather than reusable computation.
2. The same underlying model served standard and agentic conditions; the gateway changes prompts and routing, not base weights.
3. Identical temperature-zero text can conceal logit or activation differences; changed text can arise from small nonspecific perturbations.
4. Capture windows around gateway calls can contain route and response children; lineage requires explicit controller request IDs in future builds.
5. Current observations are single-model and small-sample.
6. Cosine proximity does not establish causality or recoverable discourse content.
7. The eager lane changes latency and execution relative to compiled production inference.

## 9. Falsification and future work

- Freeze prompts, seeds, build digests, and evaluator rubrics before running no-State, source-State, unrelated-State, equal-norm random, shuffled, and explicit-text controls.
- Record logits and exact request-to-child lineage in addition to text.
- Ablate layer, position, alpha, add versus replace, and `last`, `mean`, and `all` capture policies.
- Test whether proposition retrieval predicts behavioral effects better than raw cosine similarity.
- Preserve parent and child State graphs and test forward/backward traversal, stacking, interference, and decay.
- Implement graph-native injection and compare it bitwise against the eager reference lane.
- Repeat on Qwen 5120D without cross-mounting incompatible Gemma States.
- Evaluate learned cross-model maps only on held-out discourse and behavioral controls.
- Convert verified State-transition datasets into reversible adapters, then test whether they reduce unsupported completion claims without degrading unrelated capabilities.

## 10. Reproducibility assets

- `scripts/spectral_dialogue.py`: discourse and capture workflow.
- `scripts/spectral_transfer_experiment.py`: intact-model, character, teacher, and first agentic transfer run.
- `scripts/spectral_transfer_followup.py`: indirect fixed probes, application counts, and child-State comparisons.
- `research/spectral_codec_24.py`: U24 token codec and tensor-only lookup.
- `research/spectral_concept_map.py`: proposition-level sidecar index.
- `research/results/`: immutable result documents.
- `docs/SPECTRAL-AGENTIC-MAPPING-SPEC.md`: future-agent implementation and operating specification.
- `manifests/h100-sm90-gemma4-spectral.json`: derived H100 profile requiring physical acceptance.

## 11. Conclusion

This work establishes a reproducible apparatus for reversible activation-State research on a production-scale quantized model. Capture, durable storage, semantic-neighborhood lookup, live mount, physical application proof, reset, and child capture all function. The first standard-to-agentic experiment includes both a valid null and changed deterministic outputs, which is scientifically more useful than a uniformly positive demonstration. The next milestone is controlled specificity: proving that retrieved and mounted States transfer the intended proposition or operating doctrine more reliably than nonspecific perturbations and ordinary model priors.

### Addendum: explicit lineage before concept attention

A subsequent topology prototype showed that graph diffusion is not an acceptable
inheritance operator: it can smear geometric adjacency into meaning without an
explicit parent, child, or discourse edge. The active research sidecar now
traverses recorded lineage only and fails closed when ancestry is absent.
Proposition weighting remains a retrieval heuristic. **Concept attention has not
yet been implemented or demonstrated**; it is the next research object.

## References

1. Turner et al. *Steering Language Models With Activation Engineering*. arXiv:2308.10248, 2023.
2. Zou et al. *Representation Engineering: A Top-Down Approach to AI Transparency*. arXiv:2310.01405, 2023.
3. Panickssery et al. *Steering Llama 2 via Contrastive Activation Addition*. arXiv:2312.06681, 2023.
4. Qasim et al. *The Residual Stream Is All You Need: On the Redundancy of the KV Cache in Transformer Inference*. arXiv:2603.19664, 2026.
5. Quivent. *Signal Extraction Unified Specification*. repository revision d068499, 2026.
