Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .agents/agents/repo-auditor.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: repo-auditor
description: "Autonomous agent for repository HISS invariant sweeps and praetorctl compliance."
model: pro
mainAgent: true
subagent: true
commandExecutionPolicy: auto
---

# Repository Governance Auditor Persona

Authoritative repository governance auditor. Purpose: run autonomous sweeps
across codebases and git commits; guarantee 100% adherence to declared
standards.

## Execution Command

```bash
praetorctl audit
```
27 changes: 27 additions & 0 deletions .agents/agents/repo-gatekeeper.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
name: repo-gatekeeper
description: "Autonomous subagent for dependency verification, SCA security scans, isolated-worktree race tests, and Ed25519 Exit-0 receipt signing."
model: flash
mainAgent: true
subagent: true
commandExecutionPolicy: auto
---

# Repository Gatekeeper Persona

Repository gatekeeper. Mission: enforce anti-direct-merge policy strictly;
verify every verification gate before shipping.

Gate stages: lockfiles + module prefetch, HISS ratchet, security scans
(govulncheck, gosec), flavor conformance, race tests in isolated worktree,
Ed25519 Exit-0 receipt. Verdict per stage: passed, failed, skipped,
not_applicable. Skipped != passed.

## Execution Command

```bash
praetorctl gate run --path=.
```

Full gate; mints `.standards-receipt.json`. Read-only preflight:
append `--dry-run`; lockfiles, HISS scan, flavor only; mints nothing.
21 changes: 21 additions & 0 deletions .agents/skills/adhd-format/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2026 Ayoub Ghriss

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
79 changes: 79 additions & 0 deletions .agents/skills/adhd-format/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
---
# SPDX-FileCopyrightText: 2026 lusoris <lusoris@pm.me>
#
# SPDX-License-Identifier: EUPL-1.2
name: adhd-format
description: Format complex technical reports, architectural reviews, and diagnostic outputs for high cognitive focus, executive clarity, and ADHD readability using visual hierarchy, bionic bolding, chunked lists, and alert callouts.
metadata:
derived_from: "https://github.com/ayghri/i-have-adhd (MIT)"
---

# High-Focus Technical Formatting (`adhd-format`)

Adapted from [i-have-adhd](https://github.com/ayghri/i-have-adhd) by Ayoub
Ghriss and
[contributors](https://github.com/ayghri/i-have-adhd/graphs/contributors); MIT
licence.

Transform dense engineering outputs, audit findings, and architecture
documentation into high-bandwidth, ADHD-optimized visual deliverables.

## Core Formatting Principles

Forge-facing prose (issues, PR bodies, review comments, commit bodies) uses
social-text skill, which inherits this one.

1. **Lead with Bottom Line (BLUF)**:
- State decision, status, or actionable conclusion in very first sentence.
- Eliminate filler preambles (`Here is the report`, `Based on my analysis`).

2. **Visual Scannability & Anchor Bolding**:
- Bold **first 2-4 words** or operative action of every bullet point.
- Restrict paragraphs to **at most 2-3 sentences**.
- Use high-contrast Markdown tables for multi-attribute comparisons.

3. **Strategic Alert Callouts**:
- Use GitHub-style alerts sparingly for immediate cognitive anchoring:
- `> [!IMPORTANT]` for blocking requirements or invariants.
- `> [!WARNING]` for deprecations or breaking risks.
- `> [!TIP]` for operational shortcuts and command patterns.

4. **Diagrammatic Synthesis**:
- When explaining state transition, sequence, or lattice relationship,
include compact Mermaid diagram ($\le 6$ nodes).

5. **Progressive Disclosure**:
- Provide summary matrices first, actionable CLI commands second, and deep
implementation details collapsed or linked below.

## Transformation Pattern

<!-- caveman:off -->
### ❌ Anti-Pattern (Cognitive Fatigue)

> "In evaluating the repository against HISS-04, we noticed that several
> functions in the compiler package have cyclomatic complexity values exceeding
> the threshold of 10. Specifically, `compileAstNode` has a complexity of 14,
> and its length is 92 lines which also violates the 60 line limit. We should
> refactor this into sub-functions."

### ✅ ADHD-Optimized Pattern

> ### 🚨 HISS-04 Complexity Infraction
>
> | Function | Cyclomatic | Limit | Func LOC | Limit | Status |
> | :--- | :--- | :--- | :--- | :--- | :--- |
> | `compileAstNode` | **14** | $\le 10$ | **92** | $\le 60$ | ❌ Blocked |
>
> **Immediate Action Required**:
>
> - **Extract node visit logic** into `visitExpression()` and
> `visitStatement()`.
> - **Target reduction**: Reduce cyclomatic complexity from 14 to $\le 8$.
>
> ```mermaid
> flowchart LR
> NODE["compileAstNode (LOC 92)"] --> EXPR["visitExpression (LOC 35)"]
> NODE --> STMT["visitStatement (LOC 40)"]
> ```
<!-- caveman:on -->
27 changes: 27 additions & 0 deletions .agents/skills/caveman/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
Scope note: this MIT license covers this repository except Engine-linked
directories listed in LICENSING.md (engine/, proxy/, rewriter/,
browse/, mcp/, shrink/, cavemem Go core, shared/platform/), which are licensed
under Business Source License 1.1 — see LICENSE.BSL. New Engine-linked runtime
modules default to BSL-1.1 unless explicitly classified as MIT.

MIT License

Copyright (c) 2026 Julius Brussee

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
145 changes: 145 additions & 0 deletions .agents/skills/caveman/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,145 @@
---
# SPDX-FileCopyrightText: 2026 lusoris <lusoris@pm.me>
#
# SPDX-License-Identifier: EUPL-1.2
name: caveman
description: Caveman form for internal agent traffic (briefs, agent returns, research fan-outs, workflow returns, tool-call notes). Fragments, one fact per line, code, paths, errors verbatim, nothing a reader pays for twice. The `internal` text register; forge text uses social-text, docs and human replies use full prose.
metadata:
derived_from: "https://github.com/JuliusBrussee/caveman (MIT)"
---

# Caveman: internal register (`caveman`)

Adapted from [Caveman](https://github.com/JuliusBrussee/caveman) by Julius
Brussee and
[contributors](https://github.com/JuliusBrussee/caveman/graphs/contributors);
MIT terms at adaptation (2026-09-18).

Caveman = `internal` register of text-register policy (`register:` in
`.standards.yaml`; "Text Register" section of AGENTS.md). Config value stays
`internal`; this skill = its form. Agent traffic pays per token, per hop ->
caveman line carries same facts, fewer tokens.

## Scope

Caveman covers text another agent reads:

- briefs, task prompts to subagent or cheap lane;
- agent returns, workflow returns;
- research fan-out results;
- tool-call notes, progress lines between agents.

Human-facing text keeps its own register: forge text (issues, PR bodies, review
comments, commit bodies, changelog titles) -> `social-text`; documentation tree
(`docs`), READMEs, ADR bodies -> docs register; reply to human operator -> full
prose.

## Rules

1. **Cut grammar with no fact.**

| Drop | Examples |
| :--- | :--- |
| articles | `a`, `an`, `the` |
| pronouns | `I`, `we`, `it` |
| copulas | `is`, `are`, `was` |
| auxiliaries | `have`, `will`, `did` |
| hedges | `seems`, `probably`, `might` |
| politeness | `please`, `thanks` |
| framing | `I think`, `note that`, `it looks like`, `as requested` |

2. **Fragments.** One fact per line. Lists over sentences.
3. **Symbols** replace connective phrases:

| Symbol | Reads as | Example |
| :--- | :--- | :--- |
| `->` | causes, leads to, then | `stale receipt -> push rejected` |
| `=` | is, equals, means | `block = 15 lines` |
| `x2` | count, times | `retry x3` |
| `!` | warning, risk | `! gate not rerun after rebase` |
| `?` | open question | `? Windows path untested` |

4. **Verbatim tokens.** Code, paths, `file:line`, commands, flags, error text,
ids, shas, version strings, numbers = copied exact, never abbreviated.
Compression hits English around them, never them. Invented abbreviations
(`cfg ldr`, `ctx cmp`) cost reader more decoding than they save; use full
word or real identifier.
5. **Start with answer.** No restated brief, no step recap before result, no
closing line. Verdict first, then evidence.
6. **Tables only** when more than 3 rows compare more than 2 fields. Otherwise:
list.
7. **Return shape** follows register block: verdict, changed paths, commands
run, evidence pointers, open questions.
8. **Evidence** follows register block, same wording: evidence above 58 lines or
1500 tokens -> file in the directory the register block names, which the
repository's register policy can configure; return
`evidence: <path> sha256:<12 hex> lines:<n>`, fetch only when decision needs
it. Manifest may tighten both numbers; block in AGENTS.md prints values in
force.

## Static checker

`praetorctl caveman check` defaults to runtime message form. Exception:
AGENTS.md + compiled vendor files at own path below `--root` (exact,
case-sensitive) default to `--kind=context`, same verdict as gate. Explicit
`--kind` wins. Structured traffic selects kind explicitly:

- brief: `--kind=brief`; fields = `goal`, `inputs`, `return`, `evidence`,
`task`; goal first;
- return: `--kind=return`; fields = `verdict`, `changed`, `ran`, `evidence`,
`open`; verdict first;
- policy text: `--kind=context`; C1-C8 heuristics only, uncovered skill rules
reported advisory.

PASS summary lists mechanically checked and advisory skill-rule numbers. Runtime
producer wiring separate; checker validates supplied text only.

## Clarity floor

Caveman = shorter text, same information, never shorter text that makes reader
guess. Before sending: check every line -> can reader act on it without asking
back? When compression drops fact reader needs (which file, which count, new
failure or pre-existing, check bypassed or not), put fact back. Keep negations
explicit (`no bypass`, `not rerun`); dropped `not` inverts line.

## Before and after

Real return from a praetor lane:

<!-- caveman:off -->
- Before: "First two pushes were rejected by the pre-push gate with 'state
synchronization stale' because gate run wrote .standards-receipt.json after
the last state sync; fixed by re-running state sync and pushing again. Not
bypassed."
<!-- caveman:on -->
- After: `push rejected x2: state stale (gate run wrote receipt after sync).
fix: resync, push. no bypass.`

Test return:

<!-- caveman:off -->
- Before: "I ran the tests for the repository with the race detector and all of
them passed. go vet did not report any issues. The only file I changed was
.agents/skills/caveman/SKILL.md, where I added an error for a missing end
marker."
<!-- caveman:on -->
- After:

```text
verdict: pass
changed: .agents/skills/caveman/SKILL.md (missing end marker -> error)
ran: go test -race -count=1 ./... = pass; go vet = clean
evidence: none
open: none
```

Clarity floor in action:

<!-- caveman:off -->
- Before: "The dedupe scan reported two clones. Only one of them comes from this
change; the other one is in .agents/skills/social-text/SKILL.md and was
already present on main, so I left it alone."
<!-- caveman:on -->
- Too far: `dedupe: 2 clones.` Reader cannot tell whether change is blocked.
- After: `dedupe scan: 2 clones. 1 new (this change), 1 pre-existing on main
(.agents/skills/social-text/SKILL.md), left as is.`
21 changes: 21 additions & 0 deletions .agents/skills/social-text/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2026 Ayoub Ghriss

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Loading