Commit Graph
44 Commits
Author SHA1 Message Date
ruv ecb0c0bfa6 fix(ruflo-mods): reject a legacy or unknown-mode policy projection as unreadable; report shows the mode (ADR-450 T10), 0.3.12
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 05:44:23 -04:00
ruv ffe15550de Merge origin/main into loop/readme-options
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 05:02:29 -04:00
ruv 981757f12d docs(ruflo-mods): README rows cite the live options run and the source of the 76% figure
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 04:55:43 -04:00
ruv 5f717842b4 docs(ruflo-mods): complete the option table, one row per userConfig key, with a smoke guard (0.3.11)
Adds the missing toolHints, agentTrim and agentTrimKeep rows, evidence pointers, drops the stale console 'pending' line, and adds smoke step 13. 0.3.11 chosen because loop/probe-label (0.3.10) is not merged yet.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 04:47:20 -04:00
ruv ff66586247 fix(ruflo-mods): print the probe label once in the /ruflo-mods report (0.3.10)
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 04:41:04 -04:00
ruv f32b1f6db6 Merge origin/main into loop/adr451-compact
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 04:20:15 -04:00
ruv e1589e5d86 feat(ruflo-mods): compactCarry option carries swarm and claims state through compaction (ADR-451 item 7, 0.3.9)
session.compact appends one bounded (600 char) block of validated words and ids to the
compaction instructions: live swarm id/topology/agent count, open claim ids with status,
last route agent, budget and policy words. Default off, framed as data, screened for
secret shapes and injection phrases, skipped for subagent compactions, fails open.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 04:11:43 -04:00
ruv 349f7245be feat(ruflo-mods): sessionRollup ledger, one bounded counters record per session (ADR-451 item 6), 0.3.8
Default off. Counters and fixed-vocabulary fields only, capped at 50 records /
512 bytes each / 32 KB, pruned on write; corrupt ledger reads as empty; shown as
a sessions: line in /ruflo-mods. Observability only, fails open.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 03:45:51 -04:00
ruv 477622b97d chore(ruflo-mods): 0.3.7 for the capability probe (0.3.6 went to the wording fix)
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 03:22:31 -04:00
ruv 11e5c89e78 Merge remote-tracking branch 'origin/main' into loop/adr451-probe 2026-10-05 03:20:48 -04:00
ruv 32b6c33008 feat(ruflo-mods): capabilityProbe option records engine version and events fired (default off), ADR-451 item 5; 0.3.6
Observability only: one pass-through hook on every event counts which of the
events the mod registered fired; /ruflo-mods gains a bounded probe line and
the heartbeat lists the engine version and registered events. Never denies,
rewrites or delays; fails open.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 03:13:05 -04:00
ruv 8e87229606 fix(ruflo-mods): correct the agentTrim wording after the live measurement (0.3.6)
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 02:58:58 -04:00
ruv 6029b0aa2c chore(mods): drop provably unused hasSecret/tidy, swarm PLUGIN_NAME, ruos parseProbe; fix guidance screen header
Review 2026-10 #13. Patch bumps: ruflo-mods 0.3.5, ruflo-swarm 0.3.3, ruflo-ruos 0.1.1.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 02:28:30 -04:00
ruv c259ce9575 fix(ruflo-mods): keep guidance observations independent of route ownership (the e2e contract); keep rung and dropped-id fixes
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 02:09:19 -04:00
ruv 576672ea44 fix(ruflo-mods): 0.3.4 budget rung once per session, no guidance observations without route ownership, report dropped tool ids
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 01:46:59 -04:00
ruv cd01a4aea3 feat(ruflo-mods): deliveryScreen option hooks session.receive/send (default off), ADR-451 item 3; 0.3.3
Drops peer/relay deliveries with injection phrasing and refuses outgoing
messages carrying a secret shape or SSN. In-process, tighten-only, fail
open; the person's own Remote Control prompts are never screened.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 01:13:51 -04:00
ruv ebe2f82146 ruflo-mods 0.3.2: live validation of toolHints/agentTrim/status, correct the agentTrim option text
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-05 00:25:30 -04:00
ruv 33a60c715f feat(ruflo-mods): agentTrim option hooks agent.offer (default off), ADR-451 item 2; 0.3.1
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-04 23:28:44 -04:00
ruv a0ef670ed9 test(ruflo-mods): allow-comment the deliberate standalone-prefix tool name in describe.test.ts (fleet MCP namespace audit)
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-04 21:51:20 -04:00
ruv 549f66b0dc chore(ruflo-mods): 0.3.0 (toolHints option)
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-04 21:38:27 -04:00
ruv a6486f371f feat(ruflo-mods): toolHints option hooks tool.describe (default off); ADR-451 mod capability roadmap and API coverage table
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-04 21:24:14 -04:00
rUv 090c88cf2a Merge pull request #3703 from ruvnet/fix/3698-plugin-beta-feedback
fix: address Ruflo mod and console beta feedback
2026-10-04 14:06:12 -07:00
rUv 1b62011183 fix(guidance): close source identity, offline export and serialization edge cases 2026-10-04 13:43:46 -07:00
rUv 668f99dc33 fix: address Ruflo mod and console beta feedback (#3698) 2026-10-04 13:25:23 -07:00
rUv 745503c3e5 fix(mods): constrain observation identifiers to compiler rule IDs
Prevent credential-shaped arbitrary identifiers from entering the metadata queue.
2026-10-04 13:22:30 -07:00
rUv 9161994613 test(mods): verify configured native guidance and provenance recovery
Add reproducible legacy engine fixture, typed candidate records, corrupt queue recovery, and displayed version attribution.
2026-10-04 13:19:09 -07:00
rUv 22b6447a92 test(mods): use native test plugin block registration 2026-10-04 13:15:30 -07:00
rUv e999b0625c fix(mods): compose guidance inside native event handlers
Respect one handler per event, preserve defaults, and exercise real CLI command handlers.
2026-10-04 13:14:20 -07:00
rUv b6731e4234 feat(mods): add versioned advisory guidance and observation review
Refs #3701; ADR-447. Candidate observations never train or promote.
2026-10-04 13:11:03 -07:00
ruv d9a6258895 chore: bump ruflo-console 0.28.0, ruflo-goals 0.3.0, ruflo-mods 0.1.1; baseline research.test.ts
Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-04 00:28:33 -04:00
ruv e41c055a5b feat(ruflo-mods): guard the first web fetch of a research run (ADR-440)
tool.check asks once, per fresh run marker, before the first WebFetch or
WebSearch; allow->ask only, never loosens, no-op for other tools and at
the cost HARD_STOP. Tests run with claude plugin test.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-04 00:19:21 -04:00
ruv 5194355c2a feat(ruflo-console): keep every command (ADR-406), headless views, ADR-406 catalog and missions
- /ruflo-console is registered again and is the same command as /ruflo;
  ruflo-mods and ruflo-swarm answer mods / swarm <sub> on both. /ruflo-mods
  and /ruflo-swarm-* stay registered for good (ADR-406: nothing removed,
  renamed or reassigned); descriptions and READMEs say 'same as', not
  'deprecated'
- without a pane (claude -p), /ruflo <view> answers the view as text; dump
  waits (bounded, 20 s) for the view's CLI probes, joining any already running
- an inline pane given fewer rows than it asked for goes compact: controls
  under the tabs, no title strip, the view scrolls below
- /ruflo commands [word]: browses the ADR-406 command catalog copied into
  catalog/ (parity spec on its digest); built-in mod list as fallback
- Missions view (m): the ADR-406 mission observation, read-only; task status
  shown as recorded, evidence as verified, session-bound said plainly
- ruflo-mods docs: ruflo-console@ruflo in the modTrustAllow example
- e2e: /ruflo-console alias, headless /ruflo <view>, dump waits for probes,
  a 100-column inline run

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 23:33:06 -04:00
ruv 0150757686 Merge origin/main into feat/ruflo-console-mod
Resolves plugins/ruflo-mods/README.md: main's install and dogfooding docs,
with /ruflo mods as the command and /ruflo-mods as its deprecated alias.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 23:21:57 -04:00
ruv 67206969b9 feat(mods): uninstall what ruflo installed, --source local (directory marketplace), exact disclosure
- mods uninstall runs `claude plugin uninstall <id> --scope <scope>` for
  exactly the plugins ruflo installed (absent before, enabled by ruflo;
  recorded as claudeInstalled in install.json), then removes exactly the
  settings keys it added. A plugin installed before is never uninstalled.
- mods install --source local [--marketplace-path <dir>]: declares the
  ruflo marketplace as a directory source (a ruflo checkout), adds it, and
  installs nothing, so the plugins load live from the working tree.
  Verified on 2.1.287 in an isolated config: loads with no install record,
  and an edit shows on the next run. Doctor reports the source type and
  warns when the project's declared source differs from the known one.
- The repair honours the marketplace the settings file declares.
- Init output, README and ADR state exactly what loads: ruflo-swarm's
  commands/skills/agents without function hooks, its host-command mod with
  them; the first trusted start clones github.com/ruvnet/ruflo; headless -p
  on a fresh config loads nothing; refuse-risky + modTrustAllow as opt-in
  hardening (modTrust stays observe). Claude Code's re-serialization of
  settings.json is reported, never fought.
- e2e: live load is `claude -p "/ruflo-mods"` behind RUFLO_E2E_LIVE=1 with
  CLAUDE_CODE_OAUTH_TOKEN or ANTHROPIC_API_KEY; no credential file copied,
  nothing printed; adds the --source local and uninstall scenarios.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 22:31:28 -04:00
ruv b84cd3b777 feat(ruflo-console): auto-open only in a ruflo project, remember a person's close, every action argv tested
- autoOpen is gated on a ruflo project; Esc or the pane's mark persists
  isClosedByPerson so a dismissed cockpit stays shut next session
- tests/actions.test.ts: each confirm-gated palette action asks, runs nothing
  until yes, then exactly its fixed argv (13 actions)
- radar axis words, handoff arrows name the target agent, gantt now marker
- READMEs: /ruflo swarm and /ruflo mods, old names deprecated for one release;
  ruflo-swarm panel now defaults to command

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 22:26:03 -04:00
ruv cbbabb8339 feat(ruflo-console): one /ruflo command, auto-start, diagrams, palette and management views
- /ruflo is the single command for every ruflo mod: views, palette, run/yes/no,
  agent drill-down, help; /ruflo mods is answered by ruflo-mods and /ruflo swarm
  <pane|status|topology|claims|consensus> by ruflo-swarm (both hook the same
  command; the old /ruflo-mods and /ruflo-swarm-* stay as deprecated aliases)
- auto-start: panel auto opens the cockpit at session start where it docks,
  never taking the keys; the band says /ruflo to open otherwise. ruflo-swarm's
  own pane now defaults to panel command so two panes do not open
- diagrams (Raster, one pure function per diagram shared by paint and blit):
  topology with event pulses and a leader heartbeat, claims lanes with TTL
  rings and handoff arrows, federation map by trust, plugin health matrix,
  learning curve draw-in and RETRIEVE→JUDGE→DISTILL→CONSOLIDATE pipeline,
  MetaHarness radar and audit trend, cost gauge and burn, agent timeline
- management: command palette (fuzzy, text entries), confirm-gated actions
  through fixed argv, agent drill-down with logs, approvals queue (votes,
  stealable claims, refused mods, policy denies, budget), event stream with
  filter, health alerts with the fix named
- tests: 28 kit tests, 28 vitest specs; 100-agent frame 0.25 ms median

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 22:15:40 -04:00
ruv dcceb32585 feat(mods): default-on in ruflo init, init upgrade --mods, three mod plugins (ADR-404 amendment 1)
- ruflo init enables the mods by default (--no-mods opts out) in the
  committed .claude/settings.json: enabledPlugins for MOD_PLUGINS
  (ruflo-mods, ruflo-swarm, ruflo-console), extraKnownMarketplaces.ruflo and
  CLAUDE_CODE_ENABLE_FUNCTION_HOOKS=1, then refreshes the marketplace and
  `claude plugin install`s each plugin at project scope (--no-plugin-install
  skips; skipped under VITEST/CI; manual commands printed on failure).
- ruflo init upgrade --mods applies the same merge + install to an existing
  project; --add-missing and --settings imply it. Never clobbers: only absent
  keys are added (a plugin set to false stays false and is never installed,
  since `claude plugin install` would flip it), each addition is reported.
- MOD_PLUGINS is the one list; `required: false` marks a plugin not yet in
  the marketplace (ruflo-console): reported as pending, never a failure.
- Install record v2 per settings file; v1 (3.50.0) records are read; mods
  uninstall reverses exactly what was added in every file.
- Detection corrected from live evidence: an interactive trusted session
  loads plugins straight from the marketplace clone with no install record,
  so the clone decides. A stale clone (the field report, reproduced live:
  "Unknown command: /ruflo-mods") fails doctor; no clone yet is a warning.
- scripts/e2e-mods-init.sh: built CLI + real claude, isolated HOME and
  CLAUDE_CONFIG_DIR per scenario; E2E_LIVE=1 adds a live tmux session.
- ADR-404 Amendment 1, with where the "safe default" argument stops
  (ruflo-swarm's commands/skills load regardless; modTrust stays observe).

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 22:05:16 -04:00
ruv 6b8558ad99 fix(mods): install the ruflo-mods plugin, and fail doctor when Claude Code cannot resolve it
`ruflo mods install` only wrote enabledPlugins + extraKnownMarketplaces. With a
local clone of the ruflo marketplace older than ruflo-mods (seen live at
3.38.21), Claude Code skipped the enabled plugin silently and /ruflo-mods was
an unknown command, while `mods status` and `mods doctor` reported all fine.

- Detect (read-only, respects CLAUDE_CONFIG_DIR): two new findings once the
  plugin is enabled. `ruflo marketplace` checks the clone named by
  known_marketplaces.json for plugins/ruflo-mods/.claude-plugin/plugin.json;
  `ruflo-mods installed` checks installed_plugins.json for a user-scope entry
  or a local/project entry for this project whose cache dir exists. Not
  installed = FAIL; a stale clone FAILs only while nothing is installed (a
  cached install still loads). Each failure carries the exact commands.
- Repair on install: when a runnable claude is on PATH, run
  `claude plugin marketplace update ruflo` (or `marketplace add ruvnet/ruflo
  --scope <scope>` when unknown, so user settings are not edited), then
  `claude plugin install ruflo-mods@ruflo --scope <scope>` in the project dir.
  execFile with fixed argv, no shell, no -y, 150s/60s timeouts; re-reads
  Claude Code's records afterwards. --no-plugin-install skips it; --dry-run
  prints the commands; on failure the manual commands are printed and the
  exit is non-zero only with --strict.
- Status: "enabled in settings" is now distinct from installed/resolvable;
  `mods status` exits 0, `mods doctor` and `doctor --component mods` fail.
- README: install steps and the stale-clone failure mode.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 21:13:43 -04:00
ruv 969dcb2125 fix(mods): CI — keep metaharness last in doctor help; RUFLO_MODS_OWNS escape hatch; self-contained plugin tsconfigs
- doctor --component help lists 'mods' before 'metaharness': the
  ruflo-metaharness smoke step 17h greps 'metaharness)' (smoke-all,
  smoke-without-metaharness).
- audit-env-var-precedence: RUFLO_MODS_OWNS is the ADR-404 handshake set
  by the running mod, read by hook scripts with no CLI-flag surface
  (Plugin package install-safety job).
- plugins/ruflo-mods and the mod template tsconfigs no longer extend the
  gitignored .claude-plugin/types/tsconfig.json: vite/esbuild loads the
  nearest tsconfig for every transformed module, so in CI (types absent)
  root vitest failed to transform the six mods suites that import plugin
  code (TSCONFIG_ERROR: Tsconfig not found). typeRoots points at the
  generated folder instead; tsc still checks against it where present.

Verified: ruflo-metaharness smoke 125/125; env-var audit clean; root vitest
on the mods suites 99/99 with the generated types moved aside (as in CI);
tsc clean for mod and template; kit 16/16 + 1/1; validate passes.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 19:01:00 -04:00
ruv a0c4f99c2e fix(mods): trust gate allow-list by provenance, no name-keyed self-exemption; fs.write is risky; strip CSI/OSC from segments
A module's name is its manifest's own word: a Claude-written mod calling
itself 'ruflo-mods' walked past the gate under refuse-risky. The gate now
has no self-exemption (a module only judges those admitted after it) and
modTrustAllow matches the loader-keyed provenance (name@marketplace).
fs.write joins the risky calls (any path: settings/hooks persistence).
Segments lose ANSI CSI/OSC sequences, not just their ESC byte.

Kit 16/16 on 2.1.287 (inline provenance is <name>@claude-plugin-test);
vitest 99/99.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 18:22:57 -04:00
ruv f0a5d66c56 docs(adr): ADR-404 — 2.1.287 facts, $.ruflo contract, trust gate, live evidence, scaffold
Correction: 2.1.282 needs CLAUDE_CODE_ENABLE_FUNCTION_HOOKS=1 (live: 'not
turned on' without it); the earlier 'loads unset' observation was on the
already-upgraded 2.1.287 binary. 2.1.287 loads by default; on both the
server-side rollout switch can hold mods off.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 18:19:29 -04:00
ruv 8a1e11f3bd feat(mods): $.ruflo noun, status segments, mod trust gate, refusal-tolerant $ (ADR-404)
- engine.create adds a flat $.ruflo noun (types/index.d.ts, plugin.json
  "types"): segment({id,text}), lastRoute(), snapshot(). Other mods (ruOS,
  ruflo-ruos) contribute status segments instead of drawing a second bar.
  Segments are untrusted: id token, control/bidi stripped, 48 chars, max 8,
  sorted by id. One drawer for the status line, from the $ beneath.
- plugin.register trust gate: names what a later-registering user-tier mod
  can do (process.run, http.fetch, env.set; tool.check, tool.call, *,
  classic.*, plugin.register, prompt.compose), from the host scan.
  userConfig modTrust: observe (default) | refuse-risky | off, plus
  modTrustAllow. Under refuse-risky a gate failure refuses.
- every ui.status/log/toast call tolerates refusal (admins can withhold $)
- tsconfig extends the types Claude Code >= 2.1.287 writes on load
- kit tests: 15/15 on Claude Code 2.1.287, incl. two tighten-only tool.check
  mods composing, trust refusal at load, budget ladder with options
- vitest: 95/95 (noun/segment and trust suites added)
- CI ratchet baseline: the four engine-kit files (claude-code/testing is not
  resolvable by root vitest), as #3605/#3607 do

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 18:09:25 -04:00
ruv 24c9c4a8d8 fix(mods): handshake in the generated helper; ENOENT-only missing; doctor reports the rollout switch (ADR-404)
- generateHookHandler() carries the same RUFLO_MODS_OWNS handshake, so a
  helper written by the refresh fallback still hands route/post-edit over
- isMissing matches ENOENT only: a misread error must fail the guard
  closed, never read as 'no policy'
- doctor: the server-side rollout switch decides whether the mod loads
  (observed live: loads with the enable variable unset while served on, not
  with it set while served off); the variable is reported, never sufficient
- bin-level tests for init --mods, doctor --component mods, mods status
- ADR: live-run evidence, final counts; README: where options are read

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 17:58:22 -04:00
ruv d48897fb34 feat(mods): ruflo-mods plugin — ruflo as a Claude Code mod (ADR-404)
An opt-in hooks module (Claude Code function hooks, early access) with
in-process equivalents of the classic per-event hooks:

- prompt.submit: router.cjs routing + ranked-memory context, text identical
  to hook-handler.cjs route; #3567 no-match semantics
- tool.check: tighten-only (stricter of chain and ruflo), pre-bash list and
  the claude-code.* rules of ruflo policy; fails closed by one step
- tool.call/turn.complete/session.end: edit records in recordEdit's format
- session.measure/agent.spawn: cost-tracker budget ladder (opt-in)
- session.start: ownership handshake (RUFLO_MODS_OWNS), /ruflo-mods

Owns route/post-edit only where the classic hook-handler hands them over.
Kit tests (claude plugin test, 7/7 in the real engine), static security
smoke (9/9), marketplace entry.

Co-Authored-By: RuFlo <ruv@ruv.net>
2026-10-01 17:51:02 -04:00