Add AGENTS.md — repo runbook for agents (pyfallow-specific brief) #32

Merged
pdurlej merged 7 commits from governance/agents-md-for-pyfallow into main 2026-05-05 12:18:06 +02:00
Collaborator

Per operator's voice 2026-05-05: agents need explicit boundaries to prevent the largest-noise antipattern ("agent zawsze będzie dążył do największego napierdalania, żeby pokazać jaki jest ważny"). Without a brief, codex / claude / glm default to over-elaboration. AGENTS.md sets firm boundaries.

What this PR adds

A single new file: AGENTS.md at repo root. Pattern adopted from pdurlej/platform/AGENTS.md (master spec, see platform issue #75 for global escalation).

Key sections:

  • What this repo is — pyfallow as bassist for the AI-agent band (per ADR 0007); harness, not agent (categorical distinction).
  • Current phase — post-Phase-A, dogfood window open, evidence-bounded (per ADR 0006 + 0008). Phase B/C tickets #4-#25 PAUSED until evidence threshold reached.
  • Identity-isolation — per-actor PAT, no pushing-as-operator antipattern (caught in PR #2 comment review 2026-05-04).
  • Mandatory non-author reviewer — ADR 0010 + branch protection enabled 2026-05-05. PR #30 was first PR governed by the new rule.
  • PR size classes — Small/Medium/Large/Batch with iteration caps (3 hard cap for Medium/Large) and review requirements.
  • Canary Context Pack — required for Medium/Large PRs; Owner Action Board required for owner-facing reports; model emotional signal note (≤280 chars) for hidden-signal channel.
  • What agents must NOT infer without runtime evidence — concrete list (fingerprint stability, classification semantics, test coverage, runner availability, PyPI state, MCP wire format).
  • Anti-patterns — largest-noise antipattern (operator's primary concern), producer-mode regression, manual-state-in-prose, calendar-first estimates, truncated digests, silently-fixing-drift, self-referential-ADRs without enforcement.
  • How to request more context — escalation chain (subsystem → ADRs → docs → runtime evidence → operator-with-proposed-default).
  • When in doubt — defaults — propose default + state consequence + create issue + mark evidence gap + move forward + don't make operator infer.

Why this matters specifically for pyfallow

Pyfallow is bassist (per ADR 0007 metaphor). Agents default to lead-vocal behavior (largest answer to demonstrate value). Pyfallow as a tool must be the OPPOSITE — disciplined background member, deterministic gate, no opinion-based blocking, no scope creep. AGENTS.md codifies the discipline as contributor contract.

Without this file, codex working on pyfallow tickets defaults to 'I'll fix this AND propose architectural improvements AND extend the test suite' — exactly the largest-noise pattern operator named in voice review.

Mandatory non-author reviewer (ADR 0010 self-test)

PR authored by claude. Cannot merge without:

  • ≥1 approved review from non-claude (codex's first review of governance PR for pyfallow — operator's default rotation)
  • Green CI matrix (CI / Python 3.11/3.12/3.13 (pull_request))
  • Up-to-date branch
  • Operator (pdurlej) clicks merge

Identity

Commit + PR authored as claude (claude@noreply.git.pdurlej.com) per identity-isolation. Operator co-authored via commit trailer (decisions are operator's; orchestrator only recorded).

— Claude Opus 4.7 (orchestrator), 2026-05-05 morning

Per operator's voice 2026-05-05: agents need explicit boundaries to prevent the largest-noise antipattern ("agent zawsze będzie dążył do największego napierdalania, żeby pokazać jaki jest ważny"). Without a brief, codex / claude / glm default to over-elaboration. AGENTS.md sets firm boundaries. ## What this PR adds A single new file: `AGENTS.md` at repo root. Pattern adopted from `pdurlej/platform/AGENTS.md` (master spec, see platform issue #75 for global escalation). Key sections: - **What this repo is** — pyfallow as bassist for the AI-agent band (per ADR 0007); harness, not agent (categorical distinction). - **Current phase** — post-Phase-A, dogfood window open, evidence-bounded (per ADR 0006 + 0008). Phase B/C tickets #4-#25 PAUSED until evidence threshold reached. - **Identity-isolation** — per-actor PAT, no pushing-as-operator antipattern (caught in PR #2 comment review 2026-05-04). - **Mandatory non-author reviewer** — ADR 0010 + branch protection enabled 2026-05-05. PR #30 was first PR governed by the new rule. - **PR size classes** — Small/Medium/Large/Batch with iteration caps (3 hard cap for Medium/Large) and review requirements. - **Canary Context Pack** — required for Medium/Large PRs; Owner Action Board required for owner-facing reports; model emotional signal note (≤280 chars) for hidden-signal channel. - **What agents must NOT infer without runtime evidence** — concrete list (fingerprint stability, classification semantics, test coverage, runner availability, PyPI state, MCP wire format). - **Anti-patterns** — largest-noise antipattern (operator's primary concern), producer-mode regression, manual-state-in-prose, calendar-first estimates, truncated digests, silently-fixing-drift, self-referential-ADRs without enforcement. - **How to request more context** — escalation chain (subsystem → ADRs → docs → runtime evidence → operator-with-proposed-default). - **When in doubt — defaults** — propose default + state consequence + create issue + mark evidence gap + move forward + don't make operator infer. ## Why this matters specifically for pyfallow Pyfallow is **bassist** (per ADR 0007 metaphor). Agents default to lead-vocal behavior (largest answer to demonstrate value). Pyfallow as a tool must be the OPPOSITE — disciplined background member, deterministic gate, no opinion-based blocking, no scope creep. AGENTS.md codifies the discipline as contributor contract. Without this file, codex working on pyfallow tickets defaults to 'I'll fix this AND propose architectural improvements AND extend the test suite' — exactly the largest-noise pattern operator named in voice review. ## Mandatory non-author reviewer (ADR 0010 self-test) PR authored by `claude`. Cannot merge without: - ≥1 approved review from non-`claude` (codex's first review of governance PR for pyfallow — operator's default rotation) - Green CI matrix (CI / Python 3.11/3.12/3.13 (pull_request)) - Up-to-date branch - Operator (`pdurlej`) clicks merge ## Identity Commit + PR authored as `claude` (claude@noreply.git.pdurlej.com) per identity-isolation. Operator co-authored via commit trailer (decisions are operator's; orchestrator only recorded). — Claude Opus 4.7 (orchestrator), 2026-05-05 morning
Add AGENTS.md — repo runbook for agents (pyfallow-specific)
All checks were successful
CI / Python 3.11 (push) Successful in 52s
CI / Python 3.12 (push) Successful in 55s
CI / Python 3.13 (push) Successful in 54s
CI / Python 3.11 (pull_request) Successful in 52s
CI / Python 3.12 (pull_request) Successful in 54s
CI / Python 3.13 (pull_request) Successful in 53s
a9bc562c1d
Per operator's voice 2026-05-05:

> "Trzeba zarówno kodeksowi, jak i Tobie przygotować jakiś taki brief,
> niech będzie na pyfallow w AGENTS.md, żeby agent mógł sobie
> przeczytać i zrozumieć, jaka jest rola. Bo agent zapytany o coś
> zawsze odpowie i zawsze będzie dążył do największego napierdalania
> i największej ilości tworzenia szumu, żeby pokazać jaki jest ważny.
> Trzeba dać bardzo ważne granice."

Translation: "Need to prepare a brief for both Codex and you (Claude),
let it be on pyfallow in AGENTS.md, so the agent can read and
understand its role. Because an agent asked about something will always
answer and always strive for the largest possible response and most
amount of noise, to show how important it is. Need to set very firm
boundaries."

Pattern adopted from `pdurlej/platform/AGENTS.md` (master spec for all
microprojects per platform issue #75). Pyfallow-specific adaptations:
the bassist metaphor (ADR 0007), the dogfood-window context, the
3+3 canary scaled to a smaller repo (still mandatory for
Medium/Large; Small PRs get 1 reviewer), the references to pyfallow's
own ADRs.

Sections covered:

- What this repo is (bassist for AI-agent band; harness, not agent)
- Current phase (post-Phase-A, dogfood window open, evidence-bounded)
- Identity-isolation (per platform AGENTS.md; same pattern: per-actor
  PAT, no pushing-as-operator)
- Mandatory non-author reviewer (ADR 0010, branch protection enforced)
- PR size classes (Small/Medium/Large/Batch) with iteration caps
- Canary Context Pack format (required for Medium/Large)
- Owner Action Board format (required for owner-facing reports)
- Model emotional signal note (≤280 char hidden-signal channel)
- What agents must NOT infer without runtime evidence (concrete list)
- Anti-patterns (largest-noise antipattern, calendar-first estimates,
  truncated digests, silently-fixing-drift, self-referential-ADRs)
- How to request more context (escalation chain)
- When in doubt — defaults

The "largest-noise antipattern" section is the most important
pyfallow-specific guidance. Operator framed it precisely: agents
default to over-elaboration to demonstrate value, but pyfallow as
"bassist" must do the OPPOSITE — be background, hold the rhythm,
let other voices shine. AGENTS.md codifies the discipline.

This commit is authored as `claude` (orchestrator) per identity-
isolation. Per ADR 0010, this PR will require non-author review
before merge — codex (or glm, or operator-as-merger-of-last-resort)
must approve.

Co-Authored-By: pdurlej <pdurlej@noreply.git.pdurlej.com>
codex requested changes 2026-05-05 08:52:23 +02:00
Dismissed
codex left a comment

request_changes.

CI is green and the governance direction is coherent, but AGENTS.md currently contains hard references to files that do not exist on the PR head branch. I verified these return 404 via the Forgejo contents API: decisions/0010-mandatory-non-author-reviewer.md, decisions/0011-forgejo-native-ci-pattern.md, docs/philosophy.md, docs/dogfood.md, and docs/dogfood-log-template.md.

Because this PR's purpose is to be the repo runbook agents read first, broken authoritative references are an objective blocker, not a style concern. Please either add/merge the referenced ADR/docs before this PR, or update AGENTS.md to point only at files that exist in this repository revision. After that, the PR should be approvable.

request_changes. CI is green and the governance direction is coherent, but AGENTS.md currently contains hard references to files that do not exist on the PR head branch. I verified these return 404 via the Forgejo contents API: `decisions/0010-mandatory-non-author-reviewer.md`, `decisions/0011-forgejo-native-ci-pattern.md`, `docs/philosophy.md`, `docs/dogfood.md`, and `docs/dogfood-log-template.md`. Because this PR's purpose is to be the repo runbook agents read first, broken authoritative references are an objective blocker, not a style concern. Please either add/merge the referenced ADR/docs before this PR, or update AGENTS.md to point only at files that exist in this repository revision. After that, the PR should be approvable.
Add philosophy, dogfood guide, and evidence-log template
All checks were successful
CI / Python 3.11 (push) Successful in 52s
CI / Python 3.12 (push) Successful in 56s
CI / Python 3.13 (push) Successful in 55s
CI / Python 3.11 (pull_request) Successful in 51s
CI / Python 3.12 (pull_request) Successful in 52s
CI / Python 3.13 (pull_request) Successful in 53s
4e06c4a3d1
Three governance documents articulating pyfallow's role as a
deterministic gate in the operator's multi-agent ecosystem,
written under operator direction (anti-AI-slop posture, dogfood
before Show HN strategic decision 2026-05-04).

docs/philosophy.md — pyfallow as pure function (repo state, config)
→ findings, no memory between invocations, no opinions about
purpose. Position in operator's stack alongside Iskra (relational),
platform.exe (deterministic infra gate), Codex (producer), 3+3
canary review (PR gate). Pyfallow is the deterministic code gate
counterpart to platform.exe's deterministic infra gate. Cites
operator's founding principle ("non-technical product person needs
deterministic governance to avoid agents shipping stupidities under
my command") in the operator's own words. Lists what pyfallow
refuses to be (no opinions, no memory, no opinion-based blocking),
what pyfallow promises (determinism, single source of truth across
transports, conservative classification, stable fingerprints, drift
detection, hostile-input safety). Agent and operator usage
protocols.

docs/dogfood.md — concrete how-to integrate pyfallow into a Forgejo
Actions CI pipeline in operator's other repos (pdurlej/platform,
hermes-agency, iskra-openclaw). Three-step minimal integration:
copy template, pin to TestPyPI alpha (0.3.0a2), configure
.pyfallow.toml for project. Operator decision tree for reading CI
comments. Downstream agent reading of pyfallow-report.json
artifact. Identity-isolation note per platform AGENTS.md (each
actor commits with own PAT, never pushes as operator). Sister
project pyfallow-mcp wiring for MCP-using agents. Dogfood window
expectations (4-6 weeks starting 2026-05-04) and procedure for
disagreeing with pyfallow's findings (issue first, suppress only
with reasoning).

docs/dogfood-log-template.md — project-agnostic template for
keeping a dogfood log when integrating pyfallow into a new project.
Categories ([TP] / [FP] / [FN] / [FRICTION] / [SURPRISE] / [WIN] /
[META]) and entry format. Recommended copy target is the project's
own gitignored working-notes directory (pyfallow uses .codex/
convention). Explicitly explains why this is a template not a live
log — the active log lives outside git so operators and agents can
add raw, half-formed observations without polishing for posterity.

These docs do not change pyfallow's runtime behavior. They codify
the operator's strategic direction as project memory, distinct from
agent working notes which live in gitignored .codex/.

Verified:
- All three files render cleanly as Markdown (manual check)
- Cross-references between the three resolve (philosophy → dogfood,
  dogfood → philosophy, both → log template)
- No reference to .codex/ paths in published docs (those would be
  broken for external readers since .codex is gitignored)
- Identity-isolation: this commit is authored as `claude`
  (claude@noreply.git.pdurlej.com) per platform AGENTS.md convention
Align dogfood docs with evidence-bounded ADR
Some checks failed
CI / Python 3.11 (pull_request) Waiting to run
CI / Python 3.12 (pull_request) Waiting to run
CI / Python 3.13 (pull_request) Waiting to run
CI / Python 3.11 (push) Successful in 52s
CI / Python 3.12 (push) Successful in 55s
CI / Python 3.13 (push) Has been cancelled
f76636fa89
Fixes PR #33 review blockers by removing stale calendar-bound dogfood language and replacing the missing docs/rules.md live link with future-work prose.

Verified: rg finds no remaining 4-6, 2026-06-15, or rules.md references in the three PR #33 docs. Verified: markdown links in docs/philosophy.md, docs/dogfood.md, and docs/dogfood-log-template.md resolve locally.
Merge remote-tracking branch 'origin/docs/dogfood-and-philosophy' into governance/agents-md-for-pyfallow
Some checks failed
CI / Python 3.12 (push) Waiting to run
CI / Python 3.13 (push) Waiting to run
CI / Python 3.11 (pull_request) Successful in 53s
CI / Python 3.12 (pull_request) Successful in 56s
CI / Python 3.13 (pull_request) Successful in 57s
CI / Python 3.11 (push) Has been cancelled
180b8e6e53
Sanitize dogfood docs for public release
All checks were successful
CI / Python 3.11 (push) Successful in 54s
CI / Python 3.12 (push) Successful in 57s
CI / Python 3.13 (push) Successful in 55s
CI / Python 3.11 (pull_request) Successful in 52s
CI / Python 3.12 (pull_request) Successful in 53s
CI / Python 3.13 (pull_request) Successful in 55s
87c5a4ebc8
Removes private operator repo names, internal infrastructure names, and credential-store specifics from the public dogfood/philosophy docs while preserving the governance intent.

Verified: no stale dogfood calendar references or missing docs/rules.md links remain. Verified: public docs no longer mention internal repo names, server names, Bitwarden/PAT details, or local working-note paths.
Sanitize governance docs for public release
Some checks are pending
CI / Python 3.11 (push) Waiting to run
CI / Python 3.12 (push) Waiting to run
CI / Python 3.13 (push) Waiting to run
CI / Python 3.11 (pull_request) Waiting to run
CI / Python 3.12 (pull_request) Waiting to run
CI / Python 3.13 (pull_request) Waiting to run
ee55bf24fd
Removes private operator repo names, internal infrastructure names, credential-store item details, and private Forgejo project URLs from public-facing governance docs and package metadata.

Verified: rg scan no longer finds private repo names, server names, Bitwarden references, personal emails, or git.pdurlej URLs in the tracked public docs/metadata, except the intended github.com/pdurlej/pyfallow public URLs.
codex approved these changes 2026-05-05 11:24:11 +02:00
Dismissed
codex left a comment

approve_merge.

Re-reviewed after branch refresh and public-safety sanitization. The missing-reference blocker is resolved by carrying current ADRs plus the dogfood/philosophy docs. The AGENTS/governance text now uses public-safe wording for identity isolation and infrastructure references, while preserving the repository runbook's operational value. Local evidence on the updated branch: python3 -m compileall -q src tests mcp/src mcp/tests passed, python3 -m pytest -q passed, and PYTHONPATH=src python3 -m pyfallow analyze --root . --fail-on warning --min-confidence medium returned 0 issues.

approve_merge. Re-reviewed after branch refresh and public-safety sanitization. The missing-reference blocker is resolved by carrying current ADRs plus the dogfood/philosophy docs. The AGENTS/governance text now uses public-safe wording for identity isolation and infrastructure references, while preserving the repository runbook's operational value. Local evidence on the updated branch: python3 -m compileall -q src tests mcp/src mcp/tests passed, python3 -m pytest -q passed, and PYTHONPATH=src python3 -m pyfallow analyze --root . --fail-on warning --min-confidence medium returned 0 issues.
Remove private host reference from CI ADR
All checks were successful
CI / Python 3.11 (push) Successful in 52s
CI / Python 3.12 (push) Successful in 56s
CI / Python 3.13 (push) Successful in 54s
CI / Python 3.11 (pull_request) Successful in 51s
CI / Python 3.12 (pull_request) Successful in 55s
CI / Python 3.13 (pull_request) Successful in 56s
851988c846
Replaces the concrete noreply host in ADR 0011 with generic Co-Authored-By wording so public docs do not expose private infrastructure naming.

Verified: privacy public-text scan no longer finds Bitwarden, private repo names, internal server names, git.pdurlej.com, or local /Users/pd paths.
codex dismissed codex's review 2026-05-05 11:24:46 +02:00
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

codex approved these changes 2026-05-05 11:25:15 +02:00
Dismissed
codex left a comment

approve_merge.

Re-approved after the final public-safety cleanup commit. The branch still passes local compileall, pytest, and pyfallow self-audit. The final privacy scan no longer finds Bitwarden, private repo names, internal server names, git.pdurlej.com, local /Users/pd paths, or obvious token/key patterns in the public tree.

approve_merge. Re-approved after the final public-safety cleanup commit. The branch still passes local compileall, pytest, and pyfallow self-audit. The final privacy scan no longer finds Bitwarden, private repo names, internal server names, git.pdurlej.com, local /Users/pd paths, or obvious token/key patterns in the public tree.
pdurlej scheduled this pull request to auto merge when all checks succeed 2026-05-05 11:29:42 +02:00
pdurlej approved these changes 2026-05-05 11:31:25 +02:00
pdurlej scheduled this pull request to auto merge when all checks succeed 2026-05-05 11:32:21 +02:00
pdurlej scheduled this pull request to auto merge when all checks succeed 2026-05-05 12:11:15 +02:00
Merge branch 'main' into governance/agents-md-for-pyfallow
All checks were successful
CI / Python 3.11 (push) Successful in 52s
CI / Python 3.12 (push) Successful in 53s
CI / Python 3.13 (push) Successful in 54s
CI / Python 3.11 (pull_request) Successful in 53s
CI / Python 3.12 (pull_request) Successful in 55s
CI / Python 3.13 (pull_request) Successful in 54s
4aa4370b1b
pdurlej scheduled this pull request to auto merge when all checks succeed 2026-05-05 12:13:03 +02:00
codex approved these changes 2026-05-05 12:14:17 +02:00
codex left a comment

approve_merge.

Re-approved after the branch was updated with main. Current head includes #33, prior AGENTS/governance sanitization, and the public-safety cleanup. Remaining gate is CI completion on the updated head.

approve_merge. Re-approved after the branch was updated with main. Current head includes #33, prior AGENTS/governance sanitization, and the public-safety cleanup. Remaining gate is CI completion on the updated head.
pdurlej referenced this pull request from a commit 2026-05-15 22:21:08 +02:00
Sign in to join this conversation.
No description provided.