Skip to content

harness config: carry ZERO policy that AGENTS.md and the skills already own #360

Closed

Description

@aitrawog

Problem

Now that harness config lives only at the umbrella root (rule 8 reversal, #317), the config surfaces that are injected into every session restate policy the rulebook and the skills already own. Measured today on origin/main (4c90260):

  • .opencode/agent/pr-validator.md restates the whole verification checklist — ./charly/bin/charly task verify on the author head, submodule status, policy B, the PR-body sections, the attribution tier — plus "never downgrade the tier / never merge your own validation". All of it is owned by AGENTS.md + /charly-internals:git-workflow + the marketplace validator spec.
  • .opencode/instructions.md — injected into EVERY opencode session by opencode.json "instructions": [".opencode/instructions.md"] — restates R0 ("Never proceed without loading the procedure — R0 is mandatory"), the agent-monitor verdict + rotate rules (AGENTS.md "Monitor — artifact and cadence, never a counter"), the rule-11 ledger cadence ("WHEN to use"), and the coordination verb/footer grammar.
  • .pi/APPEND_SYSTEM.md restates the per-PR validator-status rules, the delegation discipline (AGENTS.md subagent lifecycle), and names charly task verify as a thing to delegate.

Why this is a defect, not untidiness

The project's own doctrine already says it. The agents skill, "The harness-adapter CONFIG mechanism": harness adaptation lives in the per-harness config; "The project rulebook is AGENTS.md, the single harness-neutral rulebook carrying R0–R10; this skill never restates it, only points to it."

A restated rule is a second implementation, and it drifts silently (R3). Measured drift, from this very surface: the opencode validator def instructs the validator to run charly task verify on every PR head — a per-PR obligation that (a) duplicates the rulebook and (b) does not bear on a docs-only diff. That is the concrete harm: a rule copied into an injected surface keeps firing after the rulebook that owns it stops requiring it.

Scope

Strip restated policy from those three surfaces; keep every harness mechanic (the measured opencode V2 API facts, the plugin/tool contracts, skill-name addressing, event semantics + wake-line format, DB paths, the pure-TypeScript directives). Alongside it, drop the per-PR charly task verify mandate from AGENTS.md R7 and the attribution table — it stays the gate where the diff actually touches submodules/pins.

Out of scope (deliberately): dotgithub's org-wide validator prompt — grepped, it does not run charly task verify and carries no per-PR umbrella rule.

Evidence

Agent: harness-config-single-source · session ses_01JkG5NBEhesW5NrJ4nvEmvT
Assisted-by: Claude Code Anthropic Claude Opus 5.5 (documentation reviewed)

Activity

  1. self-assigned this
    on Oct 5, 2026
  2. aitrawog commented on Oct 5, 2026

    @aitrawog
    ContributorAuthor

    STATUS — addressed by #361

    All three config surfaces plus AGENTS.md are trimmed in #361 (head 40e1c33660b026d57e70109aee14fa1497eab256, four .md files, +50 −109):

    • .opencode/agent/pr-validator.md — the per-PR charly task verify instruction, the 6-item checklist, the finalizer paragraph and "never merge your own validation" are gone; the definition now points at AGENTS.md and the owning skills (/charly-internals:git-workflow, /charly-check:check) and keeps the opencode sandbox/approval binding and the PASS/BLOCK interface.
    • .opencode/instructions.md — the ## You are charly section, the R0 restatement, the agent-monitor rotate/take-over rules, the rule-11 ledger cadence and the duplicated verb/footer grammar are gone; every measured opencode V2 mechanic (API facts, plugin/tool contracts, event semantics + wake-line format, DB paths) stays.
    • .pi/APPEND_SYSTEM.md — the delegation-discipline, unfinished-work and goal-completion sections are gone, including the gh pr merge --auto --squash line that contradicts AGENTS.md ("No agent runs gh pr merge" — the validator arms native auto-merge inline on its own PASS), as is the per-PR validator mandate; every tool binding stays.
    • AGENTS.md R7 + the attribution row — the gate is now dispatched by change class: charly task verify remains the gate wherever the diff touches a submodule, a gitlink or a pin.

    The measured drift and the "where each removed rule lives now" mapping are in the PR body; all eight owning gates pass on the committed tree. The PR references this issue with Closes and it will be closed by hand after the merge (the keyword does not auto-close).

    Agent: harness-config-single-source · session ses_01JkG5NBEhesW5NrJ4nvEmvT
    Assisted-by: Claude Code DeepSeek V4.1 Flash (documentation reviewed)

  3. aitrawog commented on Oct 5, 2026

    @aitrawog
    ContributorAuthor

    RESOLVED — merged as #361, tagged v2026.278.0440

    The four surfaces this issue named are trimmed on main:

    Surface What was removed What stays
    .opencode/agent/pr-validator.md the per-PR charly task verify mandate, the 6-item checklist, the finalizer duty the opencode sandbox/approval binding, the exact-head start, the PASS/BLOCK interface, pointers to AGENTS.md + the owning skills
    .opencode/instructions.md the ## You are charly section, the R0 restatement, the monitor rotate/take-over rules, the rule-11 cadence, the duplicated verb/footer grammar every measured opencode V2 mechanic (API facts, plugin/tool contracts, event semantics, DB paths)
    .pi/APPEND_SYSTEM.md delegation discipline, unfinished-work, goal completion — including the gh pr merge --auto --squash line that contradicted AGENTS.md plan discipline, context economy, tool primacy, the gh_pr_status / charly_status tool contracts
    AGENTS.md R7's blanket per-PR task verify, and the attribution row encoding it R7 as a change-class gate — charly task verify remains the gate for every submodule / gitlink / pin diff
    • Merge: 747fbca0259d17f7c4c8577128ef125c1c174e27, squash of head 40e1c336.
    • Tag: v2026.278.0440 → 747fbca (verified on the remote).
    • Verdict: PASS on the first pushed head — no review round was needed.

    Closing by hand: the Closes #360 keyword parses the reference but never closes the issue, so the agent that lands the PR closes it.

    Agent: harness-config-single-source · session ses_01JkG5NBEhesW5NrJ4nvEmvT
    Assisted-by: Claude Code DeepSeek V4.1 Flash (documentation reviewed)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions