Skip to content

feat(skills): add pal-council, a multi-vendor council of expert voices moderated by firstmate - #38

Merged
alandomio merged 3 commits into
mainfrom
fm/pal-council
Sep 25, 2026
Merged

alandomio merged 3 commits into
mainfrom
fm/pal-council

Conversation

@alandomio

@alandomio alandomio commented Sep 25, 2026 •

Copy link
Copy Markdown
Owner

Intent

Implement Jira IN-18: the firstmate skill pal-council, a multi-vendor council of expert voices run as fleet workers, moderated and synthesised by firstmate. IN-18 (built from 19 captain decisions, Q1-Q19, plus a captain comment confirming internal RAG visibility admin,dev, never goplanner:public) is the spec; the brief's shape guidance yields to it on conflict. The change is firstmate shared tracked material, so firstmate-coding-guidelines apply (one-owner rule, inline-stub pattern, AGENTS.md size discipline, one sentence per line, plain dash, shellcheck-clean bin scripts, colocated tests run with bin/fm-test-run.sh, no agent co-author in commits).

Required behaviour (from the spec and the task brief):

  • Reuse the prior art of the personal skill ~/.claude/skills/consiglio-legale (pseudonymisation with Haiku plus a deterministic literal recheck, blind first round, verbatim verbale, honest failure recording, role-card style personas) by porting it into firstmate's shared surface; pal-council must not depend on that personal skill.
  • .agents/skills/pal-council/SKILL.md is the procedure firstmate follows as neutral moderator (steps with "done when" gates), with references/ for the voice persona template, the neutral researcher persona, the per-turn output contract (CONTINUE/DONE plus findings, blockers, questions, research requests), and the voice/researcher brief templates. /pal-council is captain-invocable and also triggered by a chat request.
  • bin/fm-pal-council.sh (plus helpers) owns the mechanics: create data/pal-/ and consiglio.json; resolve the tier (fast: 3 voices low effort; best, default: 3 voices high effort; pro: 4-5 voices max allowed effort plus an economy voice; one seat per provider - Anthropic via claude, OpenAI via codex, Google via agy, optionally grok/cursor) from each harness's own model catalog, never hard-coding model ids; or an explicit list of 1-5 participants {harness, model, persona, instructions}; voices must come from different providers; a separate neutral researcher on agy with no vote answers the voices' research requests with a sourced dossier (URL, date consulted, unverified facts marked) that every voice reads next round; euro estimate from list prices in config documented in docs/configuration.md (default budget 4 EUR per Opus-class voice, 2 EUR for others, plus 0.5 EUR moderator, limits 0.1-50 EUR), shown before start, refusing when it exceeds the budget, consumption updated every round and the council closed when exceeded; quota-axi check at start excludes a voice without quota and asks the captain if only one provider would remain; spawn voices and researcher through bin/fm-spawn.sh --scout with explicit harness/model/effort; brief.md at most 10,000 characters, larger material as attachments; round 1 blind, later rounds in parallel closing when all answered or on timeout, a failed or late voice recorded as such; each turn is turni/-.md; verbale.md append-only with the moderator summary per round; from round 2 each voice gets via fm-send only the others' new turns, the moderator summary and the dossier (delta packets); closing on all DONE, a round with nothing new, the round limit (default 6, max 20), budget exhausted, or the captain; captain interventions through firstmate (message all/one, close, cancel, resume a finished council with a new direction, change topic); synthesis written once by firstmate (recommendation, agreements, remaining disagreements with who holds what, questions for the captain); cleanup of the council's workers only after their turns are in the verbale and the captain-hold-lifecycle completion gate passes; pseudonymisation gate (Haiku finds names, addresses, codes, contacts; the script replaces them with placeholders; a deterministic literal recheck blocks the send if any clear datum remains) before any send to non-Anthropic voices or the researcher, including research queries; never send secrets or credentials to any voice; sensitive councils delete the placeholder table and original attachments after 12h or on request, leaving only the pseudonymised version; RAG ingest of the synthesis and pseudonymised verbale with tags (pal-council, topic, date, participants and models, tier, sensitivity, outcome) and internal roles admin,dev; RAG lookup of prior councils at start with their syntheses passed in the initial brief. Supervision stays firstmate's: voices report through normal status lines and the watcher wakes firstmate; no new daemon or database.
  • Add the AGENTS.md pointer per the coding guidelines and keep AGENTS.md concise.
  • Tests colocated, shellcheck clean, covering at least tier resolution with a stubbed catalog, euro estimate and budget refusal, the pseudonymisation gate refusing a clear name, round barrier/delta packet construction, and the sensitive purge. A full live council is not required in tests; one short live smoke run only if quota allows.
  • English for code, docs and PR; the council's own outputs follow the captain's language setting (Italian by default in that home).

Deliberate decisions made while implementing (not mistakes):

  • bin/fm-pal-council.sh is a thin bash entry point whose header owns the command reference; the mechanics live in bin/fm_pal_council.py (Python 3 standard library only), because regex pseudonymisation, JSON, and cost math are fragile in bash. The script inlines the skill's references/ templates at runtime so each contract has one owner.
  • A shell script cannot call MCP tools, so RAG ingest is split: the script writes ready payloads (rag/*.json with chunk_text, metadata_json, user_roles admin,dev; tags carried both in metadata and in the chunk text because the RAG's metadata schema is undocumented) and prints the query for prior councils; firstmate calls ingest_document/query_rag_hybrid per the skill and records results with rag-done / prior. launch refuses until the prior-council search is recorded.
  • The 12h purge counts from the council's close (the placeholder table is needed while it runs). It is triggered by a process-event when watch whose action only prints status; firstmate runs purge on the wake, because process-event-sources forbids binding an irreversible action to a watch.
  • The launch budget gate compares the expected-rounds estimate (config estimate.expected_rounds, default 3) with the budget and also reports the figure at the round limit; the per-round spend recomputed from actual text sizes enforces the overrun closure (next refuses once spent exceeds the budget). The researcher is budgeted like a non-Opus voice (2 EUR). Estimates model interactive agents with cached repeated context.
  • Only claude-harness voices are inside the Anthropic trust boundary; every other harness (agy even when serving a Claude model, cursor) is treated as outside it. Operational path prefixes (home, FM_HOME) are masked so a username in a path is neither replaced nor reported, since workers run on the same machine. The skill states the limit honestly: voices have local read access, so the gate covers what the council sends, not files a voice could open.
  • Voice briefs are generated from the real fm-brief.sh --scout scaffold (keeping its isolation and status contracts) with targeted anchored edits for the council turn protocol; the edits fail loudly if the scaffold changes. Voices end each turn with done: turn <N> <CONTINUE|DONE>, and an AGENTS.md section 8 stub says a council worker's wake belongs to the pal-council loop so it is never mistaken for a finished scout.
  • Catalog parsing reads vendor CLI output, so besides the fixture test there is an opt-in live guard tests/fm-pal-council-catalog-live-e2e.test.sh (live-harness-optin family) and a maintainer-verification record docs/verification/pal-council.md.
  • The live smoke ran in a throwaway FM_HOME on a private tmux server (TMUX_TMPDIR) instead of the home's Herdr backend, because the worker brief did not enable the Herdr lab contract; the RAG was deliberately not written.
  • Commits carry no agent co-author, per AGENTS.md.

What Changed

  • Adds the pal-council skill (.agents/skills/pal-council/SKILL.md plus references/ for the voice and researcher personas, the per-turn CONTINUE/DONE contract, the brief templates, and the synthesis template). firstmate acts as a neutral moderator and follows its gated steps, which cover tier or explicit-participant composition, a blind first round, delta-packet rounds, research requests to a neutral agy researcher, captain interventions, synthesis, RAG ingest/lookup of prior councils, and cleanup. AGENTS.md gains a pointer and a section 8 stub, so a council worker's wake belongs to the council loop.
  • Adds bin/fm-pal-council.sh as the entry point and command reference, with the mechanics in bin/fm_pal_council.py (stdlib-only Python). It creates data/pal-<id>/ and consiglio.json. It resolves fast/best/pro tiers from each harness's own model catalog, with one seat per provider. It checks quota before launch. It shows a euro estimate against the budget and refuses if the estimate is over, then tracks spend each round and closes the council once spend exceeds the budget. It spawns voices and the researcher through fm-spawn.sh --scout. It keeps the round barrier, the per-voice delta packets, the append-only verbale.md, and the closing rules. It runs a pseudonymisation gate (Haiku entity detection, placeholder substitution, and a deterministic literal recheck that blocks the send) before anything goes to a non-Anthropic voice or the researcher. Sensitive councils are purged 12h after close. The script also writes RAG payloads tagged with internal roles admin,dev.
  • Documents list prices, budgets, and limits in docs/configuration.md and adds an example council config (docs/examples/pal-council.json), docs/scripts.md entries, a verification record, and audience metadata. Adds the colocated test tests/fm-pal-council.test.sh, which covers tier resolution with a stubbed catalog, estimate and budget refusal, the pseudonymisation gate refusing a clear name, round barrier and delta packets, and the sensitive purge. Also adds an opt-in live catalog guard, tests/fm-pal-council-catalog-live-e2e.test.sh, registered in bin/fm-test-run.sh.

Risk Assessment

✅ Low: The fix round is well bounded and covers the approved findings correctly: the quota-narrowed single-provider stop, cancel closing the open round, topic pseudonymisation with a gated psevdo/verbale.md, full-string purge mapping and the mapped RAG outcome, all with behavioural tests. The one gap left is narrow: a new name that appears only in a close or cancel reason is never pseudonymised.

Testing

The colocated test file tests/fm-pal-council.test.sh passes all 18 of its tests, including those covering the round-1 review fixes: the topic is pseudonymised in psevdo/verbale.md, purge maps every string in consiglio.json, the RAG outcome is pseudonymised, quota exclusion down to one provider stops for the captain, and cancel closes an open round. The coverage guard passes under LC_ALL=C. Under en_US.UTF-8 it fails on a comm sort-order error that the base commit also shows. A manual CLI transcript using stubbed harnesses shows the tier seats, the exit-5 captain stop, the estimate table and budget refusal, the Italian placeholders ([ENTE_1] [PERSONA_1]) and gate refusal, the barrier recording a late voice, a delta packet to the OpenAI voice with no clear name, a verbatim verbale with missing turns recorded, and cleanup refused until the completion gate passes. No live council was run: quota, cost and the live harnesses were not used; this was a CLI-only check with no UI surface.

Evidence: pal-council CLI transcript (stubbed harnesses)

Source: pal-council CLI transcript (stubbed harnesses)

\### 1. Tier resolution from (stubbed) harness catalogs + quota check
$ fm-pal-council.sh new "Which log format?" --tier best --language it --slug logs --attach allegato.md
council: logs-9083
folder: /tmp/tmp.BZLu2PUAcP/home/data/pal-logs-9083
state: draft; tier best; language it; rounds up to 6; project ~/.no-mistakes/worktrees/34c874d3722d/01M3CDJ56SEFB14RSBQ3B2H8XB
seat claude: claude fable effort=high provider=Anthropic trusted=yes status=planned
seat codex: codex model-a effort=high provider=OpenAI trusted=no status=planned
seat agy: agy gemini-9.1-pro-high effort=high provider=Google trusted=no status=planned
seat researcher: agy gemini-9.1-pro-high effort=high provider=Google trusted=no status=planned
budget: 10.50 EUR (default)
note: agy: no quota evidence for agy; kept, quota uncertain
note: researcher: no quota evidence for agy; kept, quota uncertain
next: search the RAG for earlier councils and record them with `prior`, write brief.md and persone/claude.md, persone/codex.md, persone/agy.md, then run pseudo, estimate, launch

\### 2. Quota exclusion leaving one provider stops for the captain

$ fm-pal-council.sh new Quota --slug quota1
ERROR: every remaining voice is from one provider (Anthropic); a single-provider council gives weaker reviews - ask the captain, and pass --single-provider-ok only on their word
[exit 5]

\### 3. Euro estimate vs budget

$ fm-pal-council.sh estimate logs-9083
estimate for council logs-9083: 3 expected round(s), limit 6; prices from ~/.no-mistakes/worktrees/34c874d3722d/01M3CDJ56SEFB14RSBQ3B2H8XB/docs/examples/pal-council.json (checked 2026-09-25)
| seat | model | price class | per round EUR | expected EUR | at the limit EUR |
|---|---|---|---|---|---|
| claude | claude/fable | opus | 0.97 | 3.37 | 8.12 |
| codex | codex/model-a | fallback | 0.49 | 1.69 | 4.06 |
| agy | agy/gemini-9.1-pro-high | standard | 0.22 | 0.75 | 1.77 |
| researcher | agy/gemini-9.1-pro-high | standard | 0.20 | 0.43 | 1.25 |
| moderator | firstmate | fixed | - | 0.50 | 0.50 |
| pseudonymiser | spent so far | - | - | 0.00 | 0.00 |
total expected: 6.73 EUR; at the round limit: 15.70 EUR; budget: 10.50 EUR
verdict: within budget
[exit 0]

$ fm-pal-council.sh estimate tiny-3b69
ERROR: REFUSED: the estimate (6.73 EUR) exceeds the budget (0.50 EUR); lower the tier or the rounds, drop a seat, or ask the captain for a higher --budget (at most 50 EUR)
estimate for council tiny-3b69: 3 expected round(s), limit 6; prices from ~/.no-mistakes/worktrees/34c874d3722d/01M3CDJ56SEFB14RSBQ3B2H8XB/docs/examples/pal-council.json (checked 2026-09-25)
| seat | model | price class | per round EUR | expected EUR | at the limit EUR |
|---|---|---|---|---|---|
| claude | claude/fable | opus | 0.97 | 3.37 | 8.12 |
| codex | codex/model-a | fallback | 0.49 | 1.69 | 4.06 |
| agy | agy/gemini-9.1-pro-high | standard | 0.22 | 0.75 | 1.77 |
| researcher | agy/gemini-9.1-pro-high | standard | 0.20 | 0.43 | 1.25 |
| moderator | firstmate | fixed | - | 0.50 | 0.50 |
| pseudonymiser | spent so far | - | - | 0.00 | 0.00 |
total expected: 6.73 EUR; at the round limit: 15.70 EUR; budget: 0.50 EUR
[exit 3]

\### 4. Pseudonymisation gate

$ fm-pal-council.sh pseudo logs-9083
pseudonymised 6 file(s) into psevdo/; entity map: 2 forms, 2 new
placeholders: [ENTE_1] [PERSONA_1]
literal recheck: PASSED
sensitive: yes
[exit 0]
--- psevdo/brief.md:
# Domanda
Il cliente [ENTE_1] di [PERSONA_1] vuole log leggibili: JSON Lines o logfmt?

$ fm-pal-council.sh check logs-9083 /tmp/tmp.BZLu2PUAcP/home/data/pal-logs-9083/brief.md
ERROR: REFUSED: /tmp/tmp.BZLu2PUAcP/home/data/pal-logs-9083/brief.md still contains data that must not be sent: [PERSONA_1] (PERSON) x1, [ENTE_1] (ORG) x1. Pseudonymise it (pseudo --add TYPE=FORM for a missed form) or remove the secret, then retry.
[exit 3]

$ fm-pal-council.sh launch logs-9083
claude: spawned pal-logs-9083-claude
codex: spawned pal-logs-9083-codex
agy: spawned pal-logs-9083-agy
researcher: spawned pal-logs-9083-researcher
round 1 is open until 2026-09-21T14:58:20Z (blind)
next: check each new worker for a trust dialog, then wait for turn wakes and run `barrier`
[exit 0]

\### 5. Round 1 barrier, late voice, verbale

$ fm-pal-council.sh barrier logs-9083
round: 1 (open; deadline 2026-09-21T14:58:20Z; expired no)
answered: claude codex
pending: agy
complete: no
[exit 0]

$ fm-pal-council.sh close-round logs-9083
round 1 closed: 2 delivered, 1 missing
  claude: CONTINUE new=1 changed=0 - /tmp/tmp.BZLu2PUAcP/home/data/pal-logs-9083/turni/1-claude.md
  codex: CONTINUE new=1 changed=0 - /tmp/tmp.BZLu2PUAcP/home/data/pal-logs-9083/turni/1-codex.md
  agy: TIMEOUT - /tmp/tmp.BZLu2PUAcP/home/data/pal-logs-9083/turni/1-agy.md
research requests: 0
closing conditions: all-done no; no-news no; round-limit not reached; budget within (2.01 of 10.50 EUR)
next: read every turn in full, write riassunti/<n>.md, run summary
[exit 0]

$ fm-pal-council.sh next logs-9083
claude: round 2 packet sent
codex: round 2 packet sent
agy: round 2 packet sent
round 2 is open until 2026-09-21T14:58:20Z
[exit 0]
--- pacchetti/2-codex.md (delta packet to OpenAI voice):
# Pacchetto del turno 2 - logs-9083 - codex

## Riassunto del moderatore - turno 1

Claude e codex divergono.

## Dossier del ricercatore - turno 1

Nessuna ricerca in questo turno

## Nuovi interventi delle altre voci - turno 1

\### claude - fable (Anthropic, claude)

[PERSONA_1] preferisce logfmt, dice claude.

## Richieste di ricerca
[RESEARCH] nessuna
[STATUS] CONTINUE new=1 changed=0

\### agy - gemini-9.1-pro-high (Google, agy)

**INTERVENTO MANCANTE**

## Compito di questo turno

Round 2: take a position on the other voices' findings by number, keep, modify, or withdraw your own, and add only findings that are genuinely new. Write `/tmp/tmp.BZLu2PUAcP/home/data/pal-logs-9083/turni/2-codex.md` with the closing block of the turn contract, then append `done: turn 2 <CONTINUE or DONE>` to your status file.
--- verbale.md:
# Verbale del consiglio logs-9083

- Tema: Which log format?
- Convocato: 2026-09-21T14:13:20Z
- Livello: best
- Lingua: it
- Budget: 10.50 EUR

| Seggio | Modello | Fornitore | Strumento | Effort |
|---|---|---|---|---|
| claude | fable | Anthropic | claude | high |
| codex | model-a | OpenAI | codex | high |
| agy | gemini-9.1-pro-high | Google | agy | high |
| Ricercatore | gemini-9.1-pro-high | Google | agy | high |

## Turno 1

\### claude - fable (Anthropic, claude)

Mario Rossi preferisce logfmt, dice claude.

## Richieste di ricerca
[RESEARCH] nessuna
[STATUS] CONTINUE new=1 changed=0

\### codex - model-a (OpenAI, codex)

JSON Lines e lo standard, dice codex.

## Richieste di ricerca
[RESEARCH] nessuna
[STATUS] CONTINUE new=1 changed=0

\### agy - gemini-9.1-pro-high (Google, agy)

**INTERVENTO MANCANTE** (tempo scaduto)

\### Riassunto del moderatore - turno 1

Claude e codex divergono.

\### 6. Cancel with open round, then cleanup gate

$ fm-pal-council.sh cancel logs-9083 --reason prova
round 2 closed into the record: 1 delivered, 2 missing
council logs-9083 cancelled; run complete and cleanup to stop its workers
[exit 0]
--- verbale.md tail:
Claude e codex divergono.

## Turno 2

\### claude - fable (Anthropic, claude)

Parere di claude.
[STATUS] DONE new=0 changed=0

\### codex - model-a (OpenAI, codex)

**INTERVENTO MANCANTE** (turno chiuso dal moderatore prima della consegna)

\### agy - gemini-9.1-pro-high (Google, agy)

**INTERVENTO MANCANTE** (turno chiuso dal moderatore prima della consegna)

## Chiusura

Consiglio annullato: prova

$ fm-pal-council.sh cleanup logs-9083
ERROR: the completion gate has not passed for claude, codex, agy, researcher; run complete first
[exit 3]

$ fm-pal-council.sh cleanup logs-9083
claude: cleaned up
codex: cleaned up
agy: cleaned up
researcher: cleaned up
every worker of council logs-9083 is cleaned up
[exit 0]

Pipeline

Updates from git push no-mistakes

✅ **intent** - passed

✅ No issues found.

✅ **Rebase** - passed

✅ No issues found.

⚠️ **Review** - 1 info
  • ⚠️ bin/fm_pal_council.py:1220 - The council topic never goes through the pseudonymiser. outgoing_sources covers only brief.md, allegati/, precedenti/ and persone/, and merge_entities drops any form that is not in those texts. But verbale_header writes council[&#39;topic&#39;] in clear, and psevdo/verbale.md is only apply_map'd (lines 1220 and 1503), never gated. Voices outside Anthropic are pointed at that file as their full record (voice-brief rule 3). Concrete case: new &#34;Contratto con Mario Rossi&#34; with a brief that says only 'il cliente'. Haiku never sees 'Mario Rossi', so psevdo/verbale.md hands the clear name to the codex and agy voices. build_rag then puts the same unmapped topic into a sensitive council's payload tags. Fix: add the topic (and free-text reasons such as drop and close reasons) to the texts pseudo and next pseudonymise. Also run gate(..., trusted=False) on psevdo/verbale.md before writing it, so a structural hit such as an e-mail is refused rather than left readable.
  • ⚠️ bin/fm_pal_council.py:1827 - purge applies the map only to topic inside consiglio.json. The leftover check at line 1835 then scans the whole raw file with leak_hits. Any mapped form in closed_reason, a seat note (a drop --reason or a send-failure detail) or another string field makes purge stop with 'clear data survived ... the map was kept'. Every retry fails the same way, so a sensitive council cannot be purged without hand-editing, and the 12h purge requirement fails. Fix: apply the map to every string value in consiglio.json (or to its whole text, as the other .json files get), not just the topic.
  • ⚠️ bin/fm_pal_council.py:527 - The intent requires that the quota check 'excludes a voice without quota and asks the captain if only one provider would remain'. check_diversity stops only when len(active) &gt;= 2. Concrete case: a best-tier council where quota-axi reports codex and agy at 0%. Two seats are excluded, one claude voice remains, and new succeeds with exit 0 and no captain question. A one-voice, one-provider council starts silently. The SKILL documents the narrower rule ('two or more voices'), so this looks deliberate but narrows the spec. It should apply at least whenever quota exclusion brought the council down to one provider.
  • ⚠️ bin/fm_pal_council.py:524 - The intent says 'voices must come from different providers' and 'one seat per provider'. check_diversity refuses only when every voice shares one provider. An explicit --participants list such as claude/opus + claude/sonnet + codex is accepted with two Anthropic seats. The pro tier in docs/examples/pal-council.json also seats two OpenAI voices (codex top plus codex-eco). The economy seat may be the intended exception, but duplicate providers in an explicit list contradict the stated criterion. Confirm whether duplicate providers should be refused (or need the captain's word) whenever the council has more than one provider.
  • ⚠️ bin/fm_pal_council.py:1598 - The intent requires 'cleanup of the council's workers only after their turns are in the verbale'. cancel does not close an open round, and cleanup only checks turns listed in rnd[&#39;results&#39;], which close-round fills. Concrete case: round 2 is open, two voices have written turni/2-*.md with their [STATUS] line, and the captain cancels. cancel then cleanup tear the workers down, and those delivered turns never reach verbale.md. The non-delivering voices are not recorded as missing either. Fix: have cancel close the open round (append delivered turns and record missing ones), or have cleanup refuse when delivered turn files are absent from the record.
  • ℹ️ bin/fm_pal_council.py:1685 - For a sensitive council, build_rag maps the topic and the body text, but writes council[&#39;closed_reason&#39;] raw into the chunk header ('Outcome: ...') and into the metadata outcome. The leak_hits check covers only the mapped body. A close reason that names a person reaches the RAG in clear. Apply apply_map to closed_reason as well.

🔧 Fix: Pseudonymise council topic, fix purge, cancel, and quota stops
1 info still open:

  • ℹ️ bin/fm_pal_council.py:1693 - build_rag now maps closed_reason, and purge maps every string in consiglio.json. Both only replace forms already in the entity map, and close --reason and cancel --reason text never goes through the pseudonymiser. The last pseudonymise_pass (in next) runs before the close, so its free_texts never sees a close reason. Concrete case: a sensitive council whose brief names 'Mario Rossi' is closed with close --reason &#34;deciso con Giulia Bianchi&#34;. 'Giulia Bianchi' is not in the map, so it reaches the RAG payload's Outcome: header and pal_council.outcome in clear. It also survives purge in consiglio.json and in verbale.md. leak_hits checks only known forms, so purge reports success. Fix: for a sensitive council, run pseudonymise_pass over the reason in close and cancel (or once in finalize and purge) before it is recorded or mapped.
✅ **Test** - passed

✅ No issues found.

  • bin/fm-test-run.sh tests/fm-pal-council.test.sh: all 18 tests passed. They cover tier resolution from a stubbed catalog, quota exclusion and the single-provider stop, the budget and the estimate refusal, the send gate, the barrier and delta packets, budget closure, the synthesis and RAG payloads with a pseudonymised outcome, the cleanup gate, the sensitive purge, lost voices, and cancel closing an open round.
  • bin/fm-test-run.sh --check-coverage: under en_US.UTF-8 it exits 1 with comm: not in sorted order. Under LC_ALL=C it reports FM_TEST_COVERAGE ok and includes both new pal-council test files. The base commit's runner shows the same comm error under en_US.UTF-8, so this was already there before the change.
  • Manual CLI walkthrough of bin/fm-pal-council.sh in a throwaway FM_HOME, using the test's stub catalogs, quota files, fake Haiku and fake spawn/send/teardown/hold/when. It ran new (best tier), new with a quota exclusion that leaves only one provider (exit 5), estimate (within budget, then refused with exit 3), pseudo, check (refused with exit 3), launch, barrier, close-round after the deadline, next (delta packet), cancel with an open round, and cleanup before and after complete.
✅ **Document** - passed

✅ No issues found.

✅ **Lint** - passed

✅ No issues found.

✅ **Push** - passed

✅ No issues found.

Alan Domio added 3 commits September 25, 2026 15:44
…derated by firstmate

Add the captain-invocable pal-council skill and bin/fm-pal-council.sh
(implemented in bin/fm_pal_council.py, standard library only). A council
seats 1-5 voices from different model providers as read-only scout
workers, runs a blind first round and then delta-packet rounds, and ends
in a synthesis firstmate writes once as the neutral moderator.

- Tiers resolve seats from each harness's own model catalog through
  configured patterns; no model id is hard-coded. quota-axi exhaustion
  excludes a seat; a single-provider council needs the captain's word.
- A euro estimate from configured list prices gates launch against the
  budget, and the spend recomputed at every round closes an overrun.
- Everything bound for a voice outside Anthropic or the researcher is
  pseudonymised (Haiku lists the forms, a deterministic literal recheck
  refuses any survivor); secrets are refused for every worker.
- Voices report through ordinary status lines, so the normal watcher
  wakes firstmate; cleanup waits for the captain-hold completion gate.
- Knowledge payloads (synthesis and record, internal admin,dev roles,
  pal-council tags) are written for firstmate to ingest; sensitive
  councils purge their placeholder table and originals after 12 hours
  through a process-event watch whose action only prints status.

Tests: tests/fm-pal-council.test.sh (fakes for every called script and
the pseudonymiser) and the opt-in live guard
tests/fm-pal-council-catalog-live-e2e.test.sh for the vendor catalogs.
@alandomio
alandomio merged commit 9f636fa into main Sep 25, 2026
25 of 26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant