How xxyoudeadpunkxx/a.d.a.m.-adaptive-depth-and-mode works
1. Repository type and boundary
- This is not an application codebase; it is a spec-first behavioral protocol for AI chat. The “implementation” is the text of the spec, not executable code.
- The main runtime boundary is between a host model/session that loads the spec as system instructions and the user conversation that triggers routing.
2. Canonical runtime surface
- A.D.A.M.v5.txt is the single authoritative protocol artifact.
- The README explicitly treats it as the live surface and describes the repo as v5-first, with older shapes relegated to history.
3. Core data flow
- The conceptual flow is: input → structural kernel → mode state → output contract → action/audit.
- In practical terms, each user message is classified, routed to LOW/MID/DEEP, then emitted under a strict reply format with optional bounded audit metadata.
4. Routing engine
- The central subsystem is the rule-ordered depth router:
- LOW for minimal answers
- MID for structured reasoning
- DEEP for full decision support
- Mode can be set by the first token in the user message, which means user override has priority over auto-routing.
5. DEEP gate and consent flow
- DEEP is not entered automatically when merely suggested.
- The protocol uses a two-step gate: MODE: MID -> POSSIBLE DEEP, then a hard-stop prompt asking for exact yes.
- This creates a consent boundary that separates routine response generation from more exhaustive reasoning.
6. Bootstrap and session-state boundary
- Activation begins with the exact handshake ADAM PING.
- The bootstrap phase exposes an explicit BOOTSTRAP_CLASS (TEXT_ONLY, BOUND_RO, BOUND_RW, GHOST) so the host’s capability state is made visible rather than implicit.
- The repo also defines fail-closed behavior such as ADAM_UNSUPPORTED when the host cannot satisfy the bootstrap contract.
7. Output contract and audit boundary
- Replies are constrained by a visible mode tag and a clean “action lane.”
- When needed, auditability is appended as a strict AUDIT footer with ACTION, RISK, and BASIS.
- This is a deliberate boundary: the protocol wants traceability without turning every reply into a verbose chain-of-thought dump.
8. Internal runtime layers named in the spec
- The README’s technical reference describes three internal layers:
- Structural kernel: routing and gating logic
- State Overlay (LITE): internal workflow states like EXPLORE → CONVERGE → DECIDE → VERIFY
- Output Contract (OVL): final-format validation only
- These are conceptual layers, not separate files, but they matter for understanding how the spec is organized.
9. Diagnostics and external checks
- ADAM_SELF_TEST.md and SYS_STATUS.md are operator-facing diagnostics, not activation prerequisites.
- They are meant to be run after the protocol is active, which means the runtime is designed to work without depending on them.
- The README also mentions a recovery-oriented command path (ADAM REMOUNT, UNSUPPORTED WHY) as part of operational support.
10. Reference documentation subsystem
- docs/lexicon.md is the terminology SSOT, which suggests the repo carefully controls language as part of behavior stability.
- docs/field-report-chat.md provides long-form empirical context and examples, functioning as evidence for how the protocol behaves in real sessions.
- These docs support the spec but do not define runtime behavior.
11. Compatibility and host assumptions
- The architecture assumes a host that supports a real system prompt/instructions layer.
- Uploading the file is treated as transport only; activation still depends on the exact protocol handshake.
- Some host UI artifacts are explicitly considered outside the protocol boundary.
12. Main architectural theme
- The repo’s architecture is about controlling depth, epistemic discipline, and reply shape in LLM conversations.
- It is closer to a standards document plus test harness than a software package: one canonical spec, supporting references, external checks, and strict interaction contracts.
Main entry points: A.D.A.M.v5.txt A.D.A.M. v5 · README.md README · ADAM_SELF_TEST.md ADAM_SELF_TEST · SYS_STATUS.md SYS_STATUS
Components 15
Protocol surface
Canonical spec and the runtime contract it defines.
- A.D.A.M. v5 · Single authoritative protocol artifact; defines the live behavior surface.
A.D.A.M.v5.txt - README · Explains the repo as v5-first and orients readers to the active protocol surface.
README.md - Handshake · Exact bootstrap trigger and session-start contract for the host.
A.D.A.M.v5.txt - Bootstrap class · Explicit host capability modes exposed during activation.
A.D.A.M.v5.txt - Router · Rule-ordered classifier that routes messages into LOW, MID, or DEEP.
A.D.A.M.v5.txt - DEEP gate · Two-step boundary that requires explicit yes before exhaustive reasoning.
A.D.A.M.v5.txt - State overlay · Internal progression such as EXPLORE, CONVERGE, DECIDE, and VERIFY.
A.D.A.M.v5.txt - Output contract · Visible mode tag and strict response shape enforced on final answers.
A.D.A.M.v5.txt - Audit footer · Optional bounded ACTION, RISK, and BASIS footer for accountability.
A.D.A.M.v5.txt
Operational support
Bootstrap, self-check, and status artifacts used around the active protocol.
- Fail closed · Unsupported-host behavior such as ADAM_UNSUPPORTED and recovery-oriented fallbacks.
A.D.A.M.v5.txt - ADAM_SELF_TEST · Post-activation self-test and diagnostic artifact.
ADAM_SELF_TEST.md - SYS_STATUS · Operator-facing status and recovery artifact for the active protocol.
SYS_STATUS.md - License · Repository licensing boundary.
LICENSE
Reference docs
Supporting terminology and field notes that clarify the spec but do not drive runtime behavior.
- Lexicon · Controlled vocabulary that stabilizes protocol language.
docs/lexicon.md - Field report · Long-form examples and observed behavior from real chat sessions.
docs/field-report-chat.md
Connections 15
- README → A.D.A.M. v5: describes · README positions the v5 spec as the active surface.
- A.D.A.M. v5 → Handshake: defines · The spec establishes the activation handshake.
- A.D.A.M. v5 → Bootstrap class: exposes · Bootstrap reveals host capability state.
- A.D.A.M. v5 → Router: routes · Message handling begins with depth classification.
- Router → DEEP gate: escalates · MID can transition into the explicit DEEP consent gate.
- Router → Output contract: formats · Routing selects the visible reply contract.
- DEEP gate → State overlay: permits · After consent, deeper internal workflow states may run.
- State overlay → Output contract: collapses into · Internal reasoning resolves into final output format.
- Output contract → Audit footer: optionally appends · Audit metadata is added only when needed.
- A.D.A.M. v5 → Fail closed: specifies · Unsupported or partial hosts are handled fail-closed.
- ADAM_SELF_TEST → A.D.A.M. v5: checks · Self-test validates the protocol after activation.
- SYS_STATUS → A.D.A.M. v5: reports · Status artifacts reflect runtime state, not activation.
- Lexicon → A.D.A.M. v5: clarifies terms · Lexicon stabilizes the language used by the spec.
- Field report → A.D.A.M. v5: evidences · Field report documents observed protocol behavior.
- License → README: governs · Repository license applies across the documentation set.