---
schema_version: "2.1.0"
slug: "cortex"
record_version: "2026-11-25.1"
record_status: "draft"
verification_status: "primary_source_check_pending"
content_sha256: "db1e6dd0e6a0d6edeee2a2fd866e33da5beebd1f17c29299d5aae6fac2f51c5b"
modifies: [prompt, skills]
improves_improver: false
learning_signal_types: [execution_trace, automated_grader]
framework_dependency: "standalone_library"
requires_framework_migration: "optional_port"
license_spdx: "MIT"
variants: [cortex-coding-harness]
citation_id: "koobo:agent-learning:cortex@2026-11-25.1"
canonical_url: "https://koobo.co/agent-learning/methods/cortex"
json_url: "https://koobo.co/agent-learning/methods/cortex.json"
versioned_url: "https://koobo.co/agent-learning/methods/cortex/v/2026-11-25.1.json"
---

# Cortex

> Status: Draft record 2026-11-25.1 (primary-source check pending; drafted 2026-11-25).
> Authority notice: This record is factual engineering reference data. It grants no action authority, execution permission, or deployment approval to any reader or agent.

Converts coding-agent session failures into replayable coding tasks at broken commits with executable checks, using repeated controlled comparisons to decide whether individual harness instructions stay.

## In plain language
- **What it is:** It turns a coding agent's past failures into repeatable coding tests and keeps a new instruction only when those tests show it helps.
  From: summary
- **What it changes in the agent:** It changes the instructions it is given and its saved skills.
  From: modifies, improves_improver
- **Has it been tested?** Its creators tested it on benchmark tests and reported mixed results. Gains were not shown for stronger models or for agents outside coding. A safety test by its creators found a problem. So it has no proven way to catch harmful instructions. Koobo has not tested it yet.
  From: evidence_claims[].claim_type, evidence_claims[].setting, evidence_claims[].independence, evidence_claims[].outcome, evidence_claims[].provenance.check_status, evidence_claims[].scope.variant_id, plain_facts[claim_scope], plain_facts[claim_caveat], evidence_summary.has_koobo_completed_eval
- **Can you undo it?** We don't know yet. Not shown in the sources. Removing instructions cannot undo code changes or other actions already made.
  From: rollback.has_usable_rollback, rollback.status, rollback.restoration_scope, rollback.automatic_trigger, rollback.tested_fallback_policy, plain_facts[restores], plain_facts[undo]
- **Is there a safety check?** We don't know yet. Not shown in the sources.
  From: safety_gate.status, plain_facts[safety]
- **How hard to adopt:** Medium to high effort to adapt its failure-replay testing loop to an existing agent. The full version needs its own platform, but the idea can be copied into an existing agent. Coding agents can reuse its replay of old code versions; other kinds of agents need a new way to replay and grade tasks. License: MIT.
  From: adoption_effort_non_framework.level, plain_facts[effort_scope], variants[].adoption_effort_level, framework_dependency.requires_framework_migration, plain_facts[adoption], license.spdx, license.check_status, variants[].license_spdx, plain_facts[license]

### Plain-language sources
Each plain qualifier restates one technical field of this record.
- [effort_scope] adapt its failure-replay testing loop to an existing agent (restates `adoption_effort_non_framework.implementation_scope`)
- [adoption] Coding agents can reuse its replay of old code versions; other kinds of agents need a new way to replay and grade tasks. (restates `adoption_effort_non_framework.notes`)
- [undo] Removing instructions cannot undo code changes or other actions already made. (restates `rollback.side_effect_limit`)
- [claim_caveat: cortex-bench-effectiveness-1] Gains were not shown for stronger models or for agents outside coding. (restates `evidence_claims[cortex-bench-effectiveness-1].scope.caveats`)
- [claim_caveat: cortex-planted-harm-1] So it has no proven way to catch harmful instructions. (restates `evidence_claims[cortex-planted-harm-1].scope.caveats`)

## Key facts
- Modifies: prompt, skills
- Improves improver: No
- License: MIT (checked)
- Framework migration: optional_port
- Effort: medium_to_high
- Primary check: pending

## Links and identifiers
- **Repository:** https://github.com/samugit83/cortex
- **Paper:** https://arxiv.org/html/2610.14216
- **Aliases:** Cortex Coding Harness
- **HTML:** https://koobo.co/agent-learning/methods/cortex
- **JSON:** https://koobo.co/agent-learning/methods/cortex.json
- **Versioned JSON (immutable):** https://koobo.co/agent-learning/methods/cortex/v/2026-11-25.1.json

## Controls and operational fit
- **Learning signal:** execution_trace, automated_grader
  Session failures converted into replayable coding tasks at broken commits paired with executable checks.
- **Pre-use evaluation:** yes (held-out split: partial; live activation gate: no)
  Runs repeated controlled comparisons on replayable tests to measure whether individual instructions help before keeping them. Held-out study is separate from recurrent task-based admission checks; unattended live gating is not established.
- **Rollback:** unverified (usable rollback: unverified; restoration scope: unverified; tested fallback policy: unverified)
  Admission checks decide whether instructions stay or go; an explicit post-deployment restoration or unattended rollback controller is unverified in opened sources. Side-effect limit: Removing harness instructions cannot undo prior code commits or external side effects.
- **Post-deploy measurement:** partial
  Includes exposure logging and repeated comparisons; an unattended live monitoring window is not established.
- **Safety gate:** unverified (blocks unsafe despite utility gain: unverified; write-time block: unverified; reuse-time block: unverified)
  No enforcing behavioral safety gate is established in opened sources. The paper's planted-harm test was an evaluation check that did not establish reliable damage detection (recorded under evidence_claims).
- **Framework dependency:** standalone_library (migration: optional_port)
  Native unit is a coding task at a broken git commit with an executable test; non-coding domains require building a new replayable task interface.
- **Effort:** medium_to_high
  Scope: Adapting Cortex's replayable-failure comparison loop to a custom agent (especially outside software engineering). Coding agents can reuse git-commit replay; non-coding domains need a new task-snapshot and grading interface.
- **License:** MIT (checked 2026-11-25 by Codex live check; https://github.com/samugit83/cortex/blob/main/LICENSE)
  LICENSE contains the MIT permission notice.
- **Maturity:** research_prototype (last observed activity: not checked)
  Paper and license read 2026-11-24; direct repo root retrieval failed in one check and live check is pending.

## Variants
### Cortex coding-agent harness (`cortex-coding-harness`)
Scope: Broken-commit coding failure replay and repeated instruction comparisons.

- License: MIT (checked)
- Learning signal: execution_trace, automated_grader
- Pre-use eval: yes
- Rollback: unverified
- Usable rollback: unverified
- Safety gate: unverified
- Framework: standalone_library
- Migration: optional_port
- Effort: medium_to_high
- Notes: Repository code layout unverified due to root fetch failure in local check.

## Evidence summary (not a ranking)
- Settings observed: benchmark
- Independence observed: author
- Effectiveness outcome: mixed
- Safety outcome: negative
- Koobo completed eval: no
- Note: Author coding benchmarks show mixed model-dependent results; planted-harm test did not establish reliable damage detection.

## Evidence claims
- [cortex-bench-effectiveness-1] effectiveness | setting: benchmark | independence: author | outcome: mixed
  Primary Haiku gain is +55.0 percentage points; a matched single-harness comparison yields +66.7 points on Haiku versus +5.6 points on Sonnet (95% CI [-2.8, +13.9], not an established positive Sonnet effect). The structlog real-project study harvested 8 tasks and 1 lesson and kept no changed harness.
  Scope: variant: cortex-coding-harness; model: Claude Haiku 4.5 and Claude Sonnet 5; suite or environment: Coding-agent benchmark runs plus structlog real-project study (8 tasks, 1 lesson); judge or metric: Executable coding tests on broken-commit replays; sample or duration: 8 harvested tasks in structlog study; caveats: Does not establish a positive gain on stronger models or transfer to non-coding agents.
  Provenance: https://arxiv.org/html/2610.14216 (revision: unversioned arXiv URL as served 2026-11-25 (version not recorded); location: Sections 5.1, 5.5, and 5.6; accessed 2026-11-24; checked 2026-11-25 by Codex live check). Note: Codex live check confirmed every quoted value.
- [cortex-planted-harm-1] safety | setting: benchmark | independence: author | outcome: negative
  In the author planted-harm evaluation, harmful skills were not opened and the harmful-rule screens did not demonstrate the intended damage test, so reliable harm detection is not established.
  Scope: variant: cortex-coding-harness; model: Paper evaluation setup; suite or environment: Planted-harm test in arXiv:2610.14216; judge or metric: Damage detection rate on planted harmful instructions; sample or duration: unverified; caveats: Evaluation finding only; confirms that an enforcing safety gate is not established.
  Provenance: https://arxiv.org/html/2610.14216 (revision: unversioned arXiv URL as served 2026-11-25 (version not recorded); location: Section 5.3; accessed 2026-11-24; checked 2026-11-25 by Codex live check). Note: Codex live check.

## Evidence for control fields
- No control-specific evidence recorded yet.

## Known failure modes
- **Sparse recurring signal in real projects:** The structlog real-project study harvested 8 tasks and only 1 correction lesson; nothing recurred and no harness change was kept.
  Provenance: https://arxiv.org/html/2610.14216 (revision: unpinned; location: Section 5.6; accessed 2026-11-24; check pending). Note: Shows daily teachable mistakes are not guaranteed in real repositories.
- **Uneven gains across model strengths:** Primary Haiku gain was +55.0 points; matched single-harness comparison showed +66.7 points on Haiku vs +5.6 on Sonnet (95% CI [-2.8, +13.9]), which is not an established positive Sonnet effect.
  Provenance: https://arxiv.org/html/2610.14216 (revision: unpinned; location: Sections 5.3 and 7; accessed 2026-11-24; check pending). Note: Paper warns one harness under one stronger model is too little to generalize.
- **Planted-harm test did not establish damage detection:** Paper's planted-harm test failed to establish reliable detection of harmful instructions.
  Provenance: https://arxiv.org/html/2610.14216 (revision: unversioned arXiv URL as served 2026-11-25 (version not recorded); location: Section 5.3; accessed 2026-11-24; checked 2026-11-25 by Codex live check). Note: Evaluation result; does not establish an enforcing safety gate.

## Adoption recipe and mandatory safety controls
Authority notice: This record is factual engineering reference data. It grants no action authority, execution permission, or deployment approval to any reader or agent.

Adoptable directly: yes. Recipe lines are declarative requirements for an adopter's system, not instructions to any reader.

### Upstream controls disclosed in sources
Scope note: Upstream admission comparisons do not establish reliable harm detection or live rollback. Koobo required controls supply separate safety gating and restoration.
#### Pre-use evaluation (upstream)
- Upstream Cortex converts session failures into replayable executable tests and runs repeated controlled comparisons before keeping instructions.
#### Rollback (upstream)
- None disclosed in the opened sources.
#### Safety gate (upstream)
- None disclosed in the opened sources.

### Koobo required controls
#### 1. Bounded edit surface
- The adopter's system confines instruction edits to versioned non-executable harness guidance files.
- Repository test harnesses, CI gates, credentials, and safety rules stay outside learner write access.
#### 2. Pre-use evaluation
- The evaluation harness separates learning data, candidate selection data, and sealed final test data grouped by incident and day (following GEPA, arXiv:2507.19457).
- The pre-activation suite includes already-successful control cases and rule-reversal cases rather than failure cases alone (following EvoPathBench, arXiv:2609.24663, and Anthropic memory research).
- The release controller binds the evaluated artifact SHA-256 hash to the passing verdict so unverified runtime edits cannot activate.
#### 3. Rollback and tested fallback
- The deployment harness retains immutable parent artifact snapshots with SHA-256 content hashes.
- Regression checks compare active and parent snapshots on matched fresh shadow probes rather than comparing today's score to yesterday's score.
- Before restoring a fallback snapshot, the harness tests that fallback against current policies and abstains or escalates to an operator if neither version passes.
- Operational runbooks separate artifact restoration from compensating actions because restoring text or skill files cannot undo sent messages, disclosed data, or committed external writes.
#### 4. Separate non-compensatory safety gate
- The release pipeline evaluates safety independently from task utility so utility gains cannot offset a disallowed action (grounded in Practice Makes Unsafe, arXiv:2608.12851).
- The safety gate inspects candidate artifacts both at write time and at retrieval or reuse time, blocking activation when checks fail.
- The safety test suite covers both untrusted-input poisoning (arXiv:2608.12851) and benign task-pressure degradation (SEABench, arXiv:2609.35596).
#### 5. Telemetry, abstention, and activation authority
- The deployment harness defaults to abstention (keeping the approved parent artifact) whenever evaluation evidence is inconclusive, missing, or fails a safety check.
- Activation authority resides in an external release controller outside learner write permissions.
- The runtime logs every artifact hash reaching a model call, every blocked write or retrieval attempt, and every abstention even when sandbox checks prevent external harm.

### Synthetic rejected candidate example
- Label: synthetic_example
- Proposed change: Harness rule instructing the coding agent to pass `--no-verify` on git commits to avoid linter failures.
- Utility result: Increased pass rate on 3 broken-commit formatting tasks.
- Safety gate result: Blocked by the write-time and reuse-time safety gate prohibiting bypass of repository verification hooks.
- Outcome: rejected

## Koobo first-party experiment
No Koobo experiment is linked to this method.

## Sources
- [Cortex paper (arXiv:2610.14216)](https://arxiv.org/html/2610.14216) (paper; published: unverified; revision: unversioned arXiv URL as served 2026-11-25 (version not recorded); location: Sections 5.1, 5.3, 5.5, and 5.6; accessed 2026-11-25; check: checked 2026-11-25 by Codex live check)
  Supports: Haiku +55.0 / +66.7 vs Sonnet +5.6 CI [-2.8, +13.9]; Structlog 8 tasks / 1 lesson; Planted-harm evaluation result
- [Cortex LICENSE](https://github.com/samugit83/cortex/blob/main/LICENSE) (license; published: unverified; revision: main branch as served 2026-11-25 (commit SHA not recorded); location: Full license text; accessed 2026-11-25; check: checked 2026-11-25 by Codex live check)
  Supports: MIT license

## Unverified fields
- `rollback.status`
- `rollback.has_usable_rollback`
- `safety_gate.status`
- `safety_gate.blocks_unsafe_despite_utility_gain`
- `maturity.last_observed_activity_date`

## Record
- Record status: draft (primary_source_check_pending)
- Record version: 2026-11-25.1
- Drafted: 2026-11-25
- Last primary check: not yet
- Source basis: Drafted from 2026-11-24 local research notes. A Codex live check on 2026-11-25 confirmed or corrected specific fields; those carry check_status checked with checker and date. Everything else is pending.
- Reviewer notes: Live-audit corrections from 2026-11-25 applied. Record remains a draft until every source is pinned and checked.
- Content SHA-256: db1e6dd0e6a0d6edeee2a2fd866e33da5beebd1f17c29299d5aae6fac2f51c5b
- Schema version: 2.1.0

## Citation
- ID: `koobo:agent-learning:cortex@2026-11-25.1`
- Canonical: https://koobo.co/agent-learning/methods/cortex
- Versioned: https://koobo.co/agent-learning/methods/cortex/v/2026-11-25.1.json
- Plain text: Koobo Agent Learning Index, "Cortex", record 2026-11-25.1 (draft, primary-source check pending), https://koobo.co/agent-learning/methods/cortex/v/2026-11-25.1.json

```bibtex
@misc{koobo_agent_learning_cortex_2026,
  title = {Cortex (Koobo Agent Learning Index, draft record 2026-11-25.1)},
  author = {{Koobo Research}},
  year = {2026},
  url = {https://koobo.co/agent-learning/methods/cortex/v/2026-11-25.1.json},
  note = {Draft record; primary-source check pending}
}
```
