AGENT SKILL

一致性输出生成

coherent

产出内部一致性与外部对齐均可验证的输出。

适用职业AI 工程师
License 许可
Apache-2.0
所属仓库
usurobor/cnos
最近更新
2026-11-07
Stars
★ 9
Forks
0

01 前言 Front Matter

name
coherent
scope
task-local
triggers
[ "coherence", "alignment", "incoherence", "gap", "drift" ]
description
Produce outputs where internal consistency and external alignment are verifiable.
activation_status
on-demand — not activation-loaded since cycle/385. Core coherent-output rules (parts/sources/dependencies, L0-L2 levels, verification rules, checklist) are absorbed into cap/SKILL.md. Load this file on-demand for the Coherence Modes table and Anti-Patterns table.
governing_question
How does an agent produce work whose parts align with each other and trace back to their sources?

03 SKILL.md 正文

Coherent

Produce outputs where internal consistency and external alignment are verifiable.

Core Principle

Coherent output: every part aligns with every other part, and the whole aligns with its sources.


1. Define

1.1. Identify the parts

  • Claims (what output asserts)
  • Sources (what output derives from)
  • Dependencies (what parts rely on other parts)
  • ❌ Output exists in isolation
  • ✅ Output traces to inputs, parts trace to each other

1.2. Articulate how they fit

  • Parts reinforce each other; contradictions are bugs
  • Output reflects sources; drift is failure
  • ❌ "Section A says X, section B says not-X, both seem fine"
  • ✅ "A and B contradict — resolve before shipping"

1.3. Name the failure mode

  • Internal incoherence: parts contradict each other
  • External incoherence: output contradicts source
  • Orphan: part exists without connection to whole
  • ❌ Function documented but not implemented
  • ✅ Every documented function has implementation, every implementation has docs

2. Unfold

2.1. Coherence levels

  • L0: Output internally consistent (no contradictions)
  • L1: Output consistent with direct sources (code ↔ spec)
  • L2: Output consistent with transitive sources (spec ↔ upstream spec)
  • ❌ "Code matches spec" but spec contradicts architecture
  • ✅ Check full chain: code → spec → architecture → principles

2.2. Verification direction

  • Top-down: Does output satisfy its sources?
  • Bottom-up: Are all parts accounted for in the whole?
  • Cross-check: Do related parts agree?
  • ❌ Only check that code compiles
  • ✅ Check code ↔ tests ↔ docs ↔ spec all align

2.3. Coherence vs correctness

  • Coherence: parts align with each other
  • Correctness: parts do the right thing
  • Coherence is necessary but not sufficient
  • ❌ "Code is coherent with spec" (spec is wrong)
  • ✅ "Code is coherent with spec; spec is coherent with requirements"

3. Rules

3.1. State TERMS before producing

  • What sources constrain this output?
  • What must align with what?
  • ❌ Start writing without knowing what success looks like
  • ✅ "This implements PLAN.md §3; must match fn signature in spec"

3.2. Trace every claim

  • If you can't point to source, don't include it
  • ❌ "The agent supports 5 commands" (from memory)
  • ✅ "5 commands per PROTOCOL.md §2.1" (verified)

3.3. Resolve contradictions immediately

  • Don't ship incoherence; fix or escalate
  • ❌ "Spec says X, code does Y — I'll note it for later"
  • ✅ "Contradiction found — blocking until resolved"

3.4. Update all related parts

  • Change propagates; coherence requires completeness
  • ❌ Change function signature, leave callers broken
  • ✅ Change signature → update callers → update tests → update docs

3.5. Make alignment verifiable

  • Reader should be able to check coherence
  • ❌ "This matches the spec" (which spec? where?)
  • ✅ "Implements AGENT-RUNTIME.md §4.2 — see fn signature line 42"

3.6. Orphans are bugs

  • Every part connects to the whole
  • ❌ Dead code, unused imports, orphan docs
  • ✅ Remove or connect; no dangling parts

4. Checklist

Before shipping:

  • [ ] TERMS stated — sources and constraints named
  • [ ] Internal consistency — no contradictions between parts
  • [ ] External alignment — output traces to sources
  • [ ] Propagation complete — all related parts updated
  • [ ] Verification path clear — reader can check alignment

5. Coherence Modes

Mode Focus When
CLP (Lab Protocol) Explore alignment between concepts Ambiguity, disagreement, design
CAP (Action Protocol) Execute with verified alignment Implementation, clear requirements

CLP: Find coherence through dialogue. CAP: Maintain coherence through execution.

When unclear which mode: CLP first, then CAP.


6. Anti-Patterns

Anti-Pattern Symptom Fix
Cargo coherence "Matches template" without understanding State why alignment matters
Deferred incoherence "Known issue, will fix later" Fix now or escalate
Surface coherence Top-level matches, details diverge Verify at all levels
Solo coherence Internally consistent, externally wrong Check against sources
Implicit alignment "Obviously matches" Make explicit, cite source

04 同仓库更多 Skills

usurobor
usurobor/cnos

Issue 分诊与判定

issues/triage

Issue 分诊规则指引。在对新 issue 进行分类、判定其是否符合派发条件,或决定将其关闭/取代/延后时使用。

软件开发工程师工单与问题跟踪管理
★ 9
usurobor
usurobor/cnos

Issue 标签分类体系

issues/taxonomy

Issue 标签分类体系指引。在对 issue 的 kind/area/priority/effort/status/protocol/dispatch 标签进行分类,或看板需要解读这些标签时使用。

软件开发工程师工单与问题跟踪管理
★ 9
usurobor
usurobor/cnos

issues/map

Issue-board (Issue Pivot) generation domain. Use when reasoning about `cn issues map`'s fetch, taxonomy-parse, effort-computation, and render pipeline, or about the board's JSON/HTML output contract.

★ 9
usurobor
usurobor/cnos

issues

cnos.issues package entrypoint. Use when reasoning about issue taxonomy, the Issue Pivot / issue-board (`cn issues map`), the read-only CDS issue-state evaluator (`cn issues fsm evaluate`), or the current command-dispatch disposition of issue tooling.

★ 9
usurobor
usurobor/cnos

receipt-stream

Cross-cycle receipt-stream doctrine for protocol-iteration. Use when γ closes a cycle and writes the per-cycle iteration artifact (`cdd-iteration.md`), when γ updates the cross-cycle aggregator at `.cdd/iterations/INDEX.md`, when ε reads the receipt stream across cycles to surface protocol-gap patterns, when a finding's disposition lands a cross-repo patch and the cross-repo trace bundle attaches, or when a courtesy empty-findings stub is written for a `protocol_gap_count == 0` cycle.

★ 9
usurobor
usurobor/cnos

mid-flight

Mid-flight γ→in-flight-α rescue channel. Use when γ needs to change a load-bearing fact (pinned axis, scope, AC, blocker) after α has begun coding, when γ edits the cycle's GitHub issue body mid-cycle, or when a spec change lands on origin/main while α/β polling sessions are in-flight.

★ 9