Skip to content

Proposal: A8 ALIGNMENT LOOP operational-variant addendum + B9 fold-by-default policy + Shepherd selection-rule (narrowed per adversarial review) #6

@danielmeppiel

Description

@danielmeppiel

Proposal: A8 ALIGNMENT LOOP addendum (operational variant) + B9 fold-by-default arbitration policy + SKILL.md selection rule for Shepherd composition recipe

TL;DR

A multi-month real run of the batch-bug-shepherd skill in microsoft/apm (10 issues triaged, 7 PRs shepherded twice, wave-1 advisory then wave-2 fold-loop, all 7 converged to ship_now / ready-to-merge) surfaced a shape that did NOT have a clean name in assets/architectural-patterns.md. An initial proposal (full text in references/ if linked) asked for a new Tier-3 entry Operational Convergence Loop as sibling of A8 ALIGNMENT LOOP. Three independent adversarial subagents reviewed that proposal against the genesis catalogue, the apm-handbook ch18 rosetta stone, and ch19 anti-patterns. Convergent verdict: the standalone OCL entry does not survive review. Two of three reviewers (genesis-rigor-lens and handbook-rosetta-lens) classified it as a parameter on A8, not a topology change; the third (dark-factory-lens) was scope-orthogonal but flagged anti-pattern import risk.

Narrowed proposal that DOES survive review:

  1. Add an A8 ALIGNMENT LOOP "Operational variant" addendum (~15-25 lines under the existing A8 entry) clarifying that A8's stop predicate has two well-defined kinds: creative (steward judgement) and operational (deterministic-predicate conjunction with single arbiter verdict).
  2. Add fold-by-default as a NAMED ARBITRATION POLICY under B9 GOAL STEWARD in assets/design-patterns.md (it is data + decision-rule, not topology).
  3. Add a one-row entry to SKILL.md L430-444 Default pattern selection: long-running batch with per-item operational fixpoint -> A3 + A5 + B1 + A8(stop_kind: operational), see batch-bug-shepherd as canonical composition recipe. This is the "Shepherd" composition.
  4. Rename the A8 catalogue-at-a-glance row from ALIGNMENT LOOP to ALIGNMENT LOOP (creative or operational).
  5. Add three NAMED ANTI-PATTERNS to A8's operational-variant addendum: UNBOUNDED FAN-OUT (capacity assumption), FOLD-EVERYTHING-LOOP / convergence theater (no fold-rate ceiling), and FLAKY-PREDICATE OSCILLATION (deterministic stop on non-deterministic CI / lint signal).

Net catalogue growth: zero new architectural-pattern entries; one A8 addendum; one B9 named policy; one selection-rule row.

Why this shape (genesis-rigor reviewer's load-bearing finding)

The original proposal's PART 3 itself conceded structural reducibility: shepherd = A3 ORCHESTRATOR-SAGA (macro) + A5 WAVE EXECUTION (phase-to-phase) + B1 FAN-OUT + SYNTHESIZER (intra-wave) + a per-item inner loop that LOOKS like A8 ALIGNMENT LOOP but is not. The claimed irreducibility rested on two pieces: (a) the stop-condition shape (deterministic-conjunction vs. creative judgement) and (b) the fold-vs-defer rubric.

(a) is a parameter on A8's stop function, not a topology change. Substitute the steward arbitration in A8 (B9 verdict surface) with CI_green AND lint_silent AND zero_foldable AND CEO_ship_now: same loop, same persistence, same cap. (b) is policy data, not structure; the rubric in fold-vs-defer-rubric.md is a decision tree a B9 steward consults -- it has no structural footprint.

Promoting a parameter or a policy to a standalone pattern violates the catalogue's own parsimony doctrine (SKILL.md L430-444: prefer the pattern that minimizes context degradation per thread; every entry earns its slot). The addendum + named-policy + selection-rule path captures both insights with no catalogue surface-area growth.

Proposed A8 addendum (draft text for review)

### A8.1 - Operational variant

A8 ALIGNMENT LOOP's body and persistence are stop-function-agnostic. Two
stop-function kinds are documented and field-stable:

- A8-creative: stop predicate is a steward judgement ("GO" vs "REFINE")
  evaluated against the persisted goal artifact. Reference deployment:
  examples/01-readme-iteration.md. Stop signal is qualitative.

- A8-operational: stop predicate is the conjunction of N deterministic
  system predicates AND a single arbiter verdict from B9 GOAL STEWARD.
  Reference deployment: microsoft/apm batch-bug-shepherd skill (the
  per-item convergence body); the conjunction is
  `CI_green AND lint_silent AND zero_foldable AND CEO_ship_now`.
  Stop signal is quantitative + one bounded arbitration.

Both kinds inherit A8's bounded-rounds invariant (typically 2-4 max), the
goal-persisted artifact, and the human-checkpoint escape. They differ
only in the type signature of the stop predicate.

Anti-patterns this variant must defend against (additive to A8's named
anti-patterns):

- UNBOUNDED FAN-OUT: asserting subagent capacity is unlimited and never
  budget-checking. The realization shepherd uses dispatches up to
  4 outer * 3 CI * 2 Copilot iterations per item; on batches of N items
  that is up to 24N convergence dispatches. Always pair with an explicit
  per-sweep concurrency ceiling.

- FOLD-EVERYTHING-LOOP / convergence theater: the fold-by-default
  arbitration policy (B9.X) absorbs panel followups by default; without
  an absolute fold-count ceiling per item OR a fold-rate ceiling per
  iteration, the loop folds until the outer cap fires and returns
  `advisory-with-deferred` indistinguishable from no progress. Always
  pair with an explicit fold budget.

- FLAKY-PREDICATE OSCILLATION: deterministic stop predicates on
  non-deterministic signals (flaky CI, network-dependent lint) oscillate
  the loop between green and amber with no committed progress. A8-creative
  absorbs noise into "GO with caveats"; A8-operational cannot. Always
  pair the operational stop with a per-predicate retry-and-quarantine
  policy.

Proposed B9 named policy (draft text for review)

### B9.X - fold-by-default arbitration policy

A B9 GOAL STEWARD's verdict surface includes a decision tree for routing
followup items between absorb-now (fold) and queue-later (defer). The
fold-by-default policy is the convention used by batch-bug-shepherd
operational-variant A8 loops:

- Default: fold every steward followup into the current iteration unless
  it crosses the stated scope boundary of the work artifact.
- Defer only on written `scope_boundary_crossed` justification visible
  in the artifact.
- Fold budget: hard cap on absolute fold count per item (default: 12)
  AND on fold-rate per iteration (default: 6).

Inverts the conventional triage default (queue-later) on the basis that
subagent dispatch cost is approximately zero relative to the cost of
leaving items in an advisory backlog. Calibrated for cases where
shipping items dominates queueing recommendations. NOT calibrated for
cases where the cost of expanding scope mid-loop exceeds the cost of
the open queue (e.g., release-train work, regulated change control).

Proposed SKILL.md selection-rule addition

- Long-running batch with per-item operational fixpoint
  -> A3 ORCHESTRATOR-SAGA (macro) + A5 WAVE EXECUTION (phase shape)
     + B1 FAN-OUT (intra-wave) + A8-operational (per-item inner loop)
     + B9 fold-by-default arbitration (steward policy).
  Canonical composition recipe: "Shepherd". Reference: microsoft/apm
  batch-bug-shepherd skill.

Architecture diagram (the composition this proposal names)

flowchart TD
    Orchestrator["A3 ORCHESTRATOR-SAGA<br/>(persisted plan.md<br/>+ per-phase reload)"]
    Wave["A5 WAVE EXECUTION<br/>(scope -> triage -> alignment<br/>-> xref -> shepherd/fix<br/>-> completion -> report)"]
    Fanout["B1 FAN-OUT<br/>(intra-wave parallel<br/>subagents per item)"]
    Inner["A8-operational<br/>(per-item inner loop)"]
    Stop["Stop predicate<br/>CI_green AND lint_silent<br/>AND zero_foldable<br/>AND CEO_ship_now"]
    Policy["B9 fold-by-default<br/>arbitration policy<br/>(absorb unless scope-crossed)"]
    Cap["Bounded caps<br/>4 outer x 3 CI x 2 Copilot<br/>+ per-sweep capacity budget"]

    Orchestrator --> Wave
    Wave --> Fanout
    Fanout --> Inner
    Inner --> Stop
    Inner --> Policy
    Inner --> Cap
    Stop -.escape on conjunction.-> Wave
    Cap -.escape on cap.-> Wave

    classDef existing fill:#d4edda,stroke:#155724
    classDef new fill:#fff3cd,stroke:#856404
    class Orchestrator,Wave,Fanout,Inner existing
    class Stop,Policy,Cap new
Loading

Green = already in catalogue. Yellow = the addendum + policy + selection rule this proposal adds.

A8 stop-function variants (the categorical claim this proposal makes)

flowchart LR
    A8["A8 ALIGNMENT LOOP<br/>(body + persistence<br/>+ bounded rounds<br/>+ steward escape)"]
    Creative["A8-creative<br/>stop = steward judgement<br/>signal type: qualitative"]
    Operational["A8-operational<br/>stop = N deterministic predicates<br/>AND 1 arbiter verdict<br/>signal type: quantitative + bounded"]

    A8 -->|stop_kind = creative| Creative
    A8 -->|stop_kind = operational| Operational

    Creative --> EX1["e.g. README iteration<br/>examples/01"]
    Operational --> EX2["e.g. batch-bug-shepherd<br/>per-item convergence body"]
Loading

Anti-patterns the addendum must explicitly name

flowchart TD
    Op["A8-operational"] --> UF["UNBOUNDED FAN-OUT<br/>(capacity assumption,<br/>no concurrency budget)"]
    Op --> FE["FOLD-EVERYTHING-LOOP<br/>(no absolute fold cap,<br/>convergence theater)"]
    Op --> FP["FLAKY-PREDICATE OSCILLATION<br/>(deterministic stop on<br/>non-deterministic signal)"]

    UF --> UFR["Mitigation:<br/>per-sweep concurrency ceiling"]
    FE --> FER["Mitigation:<br/>absolute fold-count cap +<br/>fold-rate cap per iteration"]
    FP --> FPR["Mitigation:<br/>per-predicate retry-and-quarantine"]

    classDef anti fill:#f8d7da,stroke:#721c24
    classDef mit fill:#d1ecf1,stroke:#0c5460
    class UF,FE,FP anti
    class UFR,FER,FPR mit
Loading

Adversarial review evidence (the basis for narrowing the original proposal)

Three independent adversarial subagents (genesis-rigor, handbook-rosetta, dark-factory-generality lenses) reviewed the original "OCL standalone entry" proposal. Convergent verdict across two of three: standalone OCL violates catalogue parsimony (parameter promoted to pattern), violates topology-axis naming convention (use-case adjective in topology catalogue), and conflates realization-evidence (BBS evals) with pattern-evidence (which would require N >= 2 independent realizations on independent stop-predicate sets).

Convergent verdict across all three on the narrowed path: an A8 addendum + B9 named policy + SKILL.md selection-rule row captures both the structural insight (stop-function generalization) and the policy insight (fold-by-default arbitration) at zero catalogue surface-area cost, with anti-patterns named explicitly.

Full adversarial reviews available on request.

Acceptance criteria

  • A8 entry in assets/architectural-patterns.md gains an A8.1 "Operational variant" subsection (draft text above).
  • A8 catalogue-at-a-glance table row retitled ALIGNMENT LOOP (creative or operational).
  • B9 entry in assets/design-patterns.md gains a B9.X "fold-by-default arbitration policy" subsection (draft text above).
  • SKILL.md Default pattern selection (L430-444) gains the long-running-batch composition row.
  • Three named anti-patterns (UNBOUNDED FAN-OUT, FOLD-EVERYTHING-LOOP, FLAKY-PREDICATE OSCILLATION) carry their explicit mitigations.
  • No new top-level architectural-pattern entry is added.
  • No reference to dark software factory or any non-structural framing appears in the addendum text; the case stands on structural merit alone.

Evidence base

  • Realization: microsoft/apm .agents/skills/batch-bug-shepherd/ post-refactor on PR #1518.
  • Empirical run: wave-1-vs-wave-2 on 6 PRs (microsoft/apm #1472, #1486, #1512, #1513, #1514, #1515, #1516), all converged to ship_now. N=6, one repo, one operator: sufficient for an A8 addendum (which inherits A8's existing evidence base); explicitly INSUFFICIENT for a standalone pattern entry.
  • Backfilled evals on the realization: PR #1518 commit c8ddee45.
  • Adversarial review traces preserved offline; can be appended on request.

Out of scope for this issue

  • Adding a standalone Operational Convergence Loop entry. Withdrawn per adversarial review.
  • Any claim about dark software factory thresholds. Reframed separately as a distance-map artifact, not a catalogue contribution.
  • Cross-archetype generality claims (shepherd-for-greenfield, shepherd-for-legacy-modernization). Treated as research questions until convergence evidence exists.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions