Adaptive immune security architecture for netkingdom
Find a file
tegwick 97c7eea1da Align with Security Layer Model v0.7; review scope vs intent; open KG-WP-0003
The standard is accepted at v0.7 with a working companion. v0.7 wrote the
§3.4 agent-principal rules that v0.6 announced and never wrote — our
finding — and credits kings-guard for it. Our other two findings landed
too: the actuation row is no longer attributed to us, and §17 records
kings-guard as drafter of the emission-cadence declaration.

INTENT.md now carries the declaration in frontmatter (layer: Staff,
conformance_state: blocked-clean) as the companion asks, plus prose in
our own voice. Adopted: the four agent-principal rules; the evidence
doctrine and our obligations under it; containment reframed as proposal
throughout. Direction of Evolution stage 3 rewritten — it described
integrating with effectors to actuate, which §9.2 forbids — and stage 5
now carries the constraint that federated memory may not become a state
plane.

SCOPE.md gains evidence classification, the cadence draft, and
stream-completeness judgment as in-scope; actuation, standing
credentials, and becoming a state plane as explicitly out.

history/2026-08-29-layer-model-v0.7-scope-intent-review.md assesses the
adapted documents against the implementation. The finding: the documents
are now correct and the code has not caught up. Nine gaps, G1-G8 carried
by KG-WP-0003, G9 remaining as KG-IN-0002.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UEtvmYUBP2fDtirJGWn5MW

Assistant: claude-code
Assistant-Model: opus
Assistant-Process: 4014379@bnt-lap001
Assistant-Session: 4af9e20f-1768-4afc-951b-b507784e382b
2026-08-29 14:42:34 +02:00
.repo-manager Repoint at Security Layer Model v0.4; assess and report to gate-house 2026-08-29 02:41:43 +02:00
decisions chore(registrar): assign State Hub identifiers 2026-08-28 21:48:08 +02:00
docs Declare layer machine-readably (§11); adopt v0.6 corrections 2026-08-29 10:20:39 +02:00
history Align with Security Layer Model v0.7; review scope vs intent; open KG-WP-0003 2026-08-29 14:42:34 +02:00
intake Close absorbed qonto pilot intake 2026-07-24 00:34:52 +02:00
intakes repo.work.create_intake KG-IN-0003 2026-08-28 22:40:12 +02:00
scripts Declare layer machine-readably (§11); adopt v0.6 corrections 2026-08-29 10:20:39 +02:00
specs Declare layer machine-readably (§11); adopt v0.6 corrections 2026-08-29 10:20:39 +02:00
src/kings_guard Implement KG-WP-0002 posture pilot scaffold 2026-07-24 00:24:53 +02:00
tests Declare layer machine-readably (§11); adopt v0.6 corrections 2026-08-29 10:20:39 +02:00
workplans Align with Security Layer Model v0.7; review scope vs intent; open KG-WP-0003 2026-08-29 14:42:34 +02:00
.custodian-brief.md chore(consistency): sync task status from DB [auto] 2026-07-24 00:16:02 +02:00
.gitignore Implement KG-WP-0002 posture pilot scaffold 2026-07-24 00:24:53 +02:00
.repo-classification.yaml Register kings-guard with State Hub 2026-07-23 22:55:42 +02:00
AGENTS.md Assent to Staff placement; release control-plane vocabulary (KG-IN-0001) 2026-08-28 21:47:05 +02:00
INTENT.md Align with Security Layer Model v0.7; review scope vs intent; open KG-WP-0003 2026-08-29 14:42:34 +02:00
layer.yaml Align with Security Layer Model v0.7; review scope vs intent; open KG-WP-0003 2026-08-29 14:42:34 +02:00
LICENSE Adopt Target Revenue Source License V1C1 (org-wide preliminary rollout) 2026-07-30 00:28:01 +02:00
Makefile Declare layer machine-readably (§11); adopt v0.6 corrections 2026-08-29 10:20:39 +02:00
pyproject.toml Declare layer machine-readably (§11); adopt v0.6 corrections 2026-08-29 10:20:39 +02:00
README.md Assent to Staff placement; release control-plane vocabulary (KG-IN-0001) 2026-08-28 21:47:05 +02:00
SCOPE.md Align with Security Layer Model v0.7; review scope vs intent; open KG-WP-0003 2026-08-29 14:42:34 +02:00
WORK-RECORDS.md Refresh work-record index 2026-08-28 22:43:06 +02:00

kings-guard

Adaptive security contracts and posture-evaluation scaffold for NetKingdom's immune-architecture work.

Layer: Staff (NetKingdom Security Layer Model v0.1). kings-guard publishes posture and requests bounded response through engine APIs; it never touches Tooling directly and never renders an authorization decision.

Current slice

This repository now contains four aligned pieces:

  • INTENT.md / SCOPE.md for the repo's stable boundary
  • specs/NetKingdomImmuneArchitecture.md for the reference architecture
  • specs/ImmuneContracts.md for the first canonical contract layer
  • src/kings_guard/ plus tests/ for a minimal posture loop scaffold

The current implementation is intentionally narrow. It does not enforce anything. It provides:

  • typed contracts for security genome, phenotype, observation, posture, signal, effector request, and immune memory entry;
  • a minimal posture evaluator that turns a normalized observation into a posture assessment and bounded response hints;
  • a fixture-driven pilot based on qonto-assistant, chosen because it already exposes a security genome record, an audit stream, and a fast local loop.

Repo layout

  • specs/NetKingdomImmuneArchitecture.md
  • specs/ImmuneContracts.md
  • docs/AdjacentSystemBoundary.md
  • docs/pilots/QontoAssistantPosturePilot.md
  • src/kings_guard/
  • tests/
  • workplans/

Dev commands

# preferred, if make + pip are available
make install-dev
make test
make lint
make run-demo

# direct shell fallback used in minimal environments
python3 -m pytest -q
PYTHONPATH=src python3 -m kings_guard.main --pilot qonto-assistant