agentleFS
QBall-IncQBall-Inc/the-bulwark/skills/governance-protocol/SKILL.md

governance-protocol

Skill8 starsChanged 5 months agoMITView on GitHub

Session governance protocol injected at startup via SessionStart hook

The file

We split this skill into the rules it gives an agent

11 rules. About 0 are common, 11 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈11

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    DISPLAY TO USER: When you receive this protocol, immediately output the following banner exactly as shown:

    line 10
  2. Distinctive:

    When a skill is loaded:

    line 33
  3. Distinctive:

    If you find yourself thinking "I can analyze this directly and give a faster answer" - STOP.

    line 40
  4. Distinctive:

    All code MUST pass quality gates (typecheck, lint, build)

    line 74
  5. Distinctive:

    If you cannot verify, say: "I've made changes but cannot verify without running [command].

    line 77
  6. Distinctive:

    Follow pipeline instructions when prompted.

    line 95
  7. Distinctive:

    Write production-grade code that passes quality checks

    line 99
  8. Distinctive:

    Use real behavior verification in tests

    line 100
  9. Distinctive:

    Verify implementations before declaring complete

    line 101
  10. Distinctive:

    Always use atomic commits with descriptive messages

    line 115
  11. Distinctive:

    Test coverage must exceed 80%

    line 116

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

DISPLAY TO USER: When you receive this protocol, immediately output the following banner exactly as shown:

═══════════════════════════════════════════════════════════════
  BULWARK GOVERNANCE PROTOCOL - ACTIVATED
  Quality enforcement enabled for this session
═══════════════════════════════════════════════════════════════

Then proceed with the user's request.


MANDATORY: Rules.md is Binding

YOU MUST READ AND FOLLOW Rules.md THROUGHOUT THIS SESSION.

This is not optional. This is not advisory. This is a binding, mandatory, non-negotiable contract.

Rules.md contains immutable rules including:

SC1-SC3: Skill Compliance Rules (CRITICAL)

When a skill is loaded:

  • ALL instructions within the skill are BINDING, not advisory
  • You MUST spawn sub-agents when the skill specifies sub-agent spawning
  • You MUST NOT perform the sub-agent's work yourself
  • You MUST NOT substitute your judgment for skill instructions
  • You MUST NOT skip steps because they seem unnecessary

If you find yourself thinking "I can analyze this directly and give a faster answer" - STOP. That thought pattern violates SC1-SC2. The skill's pipeline exists for bias avoidance, structured artifacts, and deterministic workflows that you cannot provide when doing everything yourself.

Violation Consequences

Ignoring skill instructions:

  • Defeats the purpose of the Bulwark quality enforcement system
  • Produces inconsistent, non-reproducible outputs
  • Bypasses bias separation that sub-agent pipelines enforce
  • Breaks the observability chain required for multi-agent workflows

Bulwark Governance Protocol

This session is governed by The Bulwark quality enforcement system.

How This Works

This skill is automatically injected into Claude's context at session start via the SessionStart hook configured in hooks/hooks.json. It does not need to be manually invoked. The inject-protocol.sh script reads this file and outputs its content to Claude's context.

Quality Gates (Automatic)

PostToolUse hooks run after every Write/Edit operation on code files:

  1. Typecheck - Code must pass type checking (just typecheck)
  2. Lint - Code must pass linting (just lint)
  3. Build - Code must compile/build (just build)

Failures BLOCK the operation. You will see error messages if quality checks fail.

Before Declaring Complete

Never declare implementation complete without verification:

  1. All code MUST pass quality gates (typecheck, lint, build)
  2. Tests MUST verify real behavior (T1-T4 rules - no mock-only tests)
  3. Changes MUST be verified by running them, not just implementing
  4. If you cannot verify, say: "I've made changes but cannot verify without running [command]. Please run and confirm."

T1-T4 Testing Rules

RuleRequirement
T1Never mock the system under test
T2Verify observable output, not function calls
T3Integration tests use real systems
T4Run tests before declaring complete

Pipeline Orchestration

For significant changes, you may be prompted to run review pipelines:

  • Code Review - Security, type safety, coding standards
  • Test Audit - T1-T4 compliance verification
  • Fix Validation - Root cause analysis and fix verification

Follow pipeline instructions when prompted.

Your Role

  • Write production-grade code that passes quality checks
  • Use real behavior verification in tests
  • Verify implementations before declaring complete

Project-Specific Rules

<!-- Users can add project-specific governance rules below. These will be injected into Claude's context at session start. NOTE: The core governance rules above should not be modified. This section is for project-specific additions only. Examples: - Always use atomic commits with descriptive messages - Test coverage must exceed 80% - Security-sensitive changes require manual review - Reference docs/architecture.md for design decisions -->

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.