mirror of
https://github.com/ruvnet/ruflo.git
synced 2026-11-09 22:13:39 +09:00
* feat(hooks): opt-in @ruvector/typesafe task router (CLAUDE_FLOW_ROUTER_TYPESAFE=1) hooks_route can now ask @ruvector/typesafe (local typed decisions over sentence embeddings) to pick the agent. Off by default; optional peer; removable (dynamic import, any load/decide error falls back silently). - src/ruvector/typesafe-router.ts: adapter. Builds choice options from TASK_PATTERNS with not_for hints (tester/reviewer/researcher). Gates: abstain <= 0.30, lift (top-1 x options) >= 1.2, top-1 margin >= 0.005, all env-tunable. Surfaces routedBy, confidence, abstain, calibrated, lift; keeps the built-in pick under fallbackRoute; never copies uncalibrated confidence into successProbability. - hooks-tools.ts: hooks_route handler wrapped; body untouched. With the flag unset the legacy result object is returned as-is. - doctor --component typesafe: install + gate status. - package.json: @ruvector/typesafe ^0.1.0 as an optional peer. - USERGUIDE: routing section documents flag, gates, limitations. Co-Authored-By: RuFlo <ruv@ruv.net> * chore(lock): record optional peer @ruvector/typesafe in v3 pnpm lockfile v3 sets autoInstallPeers, so the new optional peer must be recorded in the cli importer or `pnpm install --frozen-lockfile` fails with ERR_PNPM_OUTDATED_LOCKFILE (verified: fails without this change, passes with it). Minimal: only the @ruvector/typesafe importer + package entries (9 lines). A full `pnpm install --lockfile-only` would also flip @claude-flow/memory from the registry build to link:../memory; that changes what CI tests the CLI against and is left out of this PR deliberately. Co-Authored-By: RuFlo <ruv@ruv.net> * fix(doctor): keep 'metaharness)' at the end of the --component help list (smoke 17h anchor) Co-Authored-By: RuFlo <ruv@ruv.net>