jfl 0.4.4 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/context-hub.d.ts +1 -0
- package/dist/commands/context-hub.d.ts.map +1 -1
- package/dist/commands/context-hub.js +1064 -41
- package/dist/commands/context-hub.js.map +1 -1
- package/dist/commands/eval.d.ts +1 -1
- package/dist/commands/eval.d.ts.map +1 -1
- package/dist/commands/eval.js +192 -1
- package/dist/commands/eval.js.map +1 -1
- package/dist/commands/findings.d.ts +6 -0
- package/dist/commands/findings.d.ts.map +1 -0
- package/dist/commands/findings.js +203 -0
- package/dist/commands/findings.js.map +1 -0
- package/dist/commands/hud.d.ts.map +1 -1
- package/dist/commands/hud.js +47 -9
- package/dist/commands/hud.js.map +1 -1
- package/dist/commands/ide.d.ts +27 -0
- package/dist/commands/ide.d.ts.map +1 -0
- package/dist/commands/ide.js +546 -0
- package/dist/commands/ide.js.map +1 -0
- package/dist/commands/onboard.d.ts.map +1 -1
- package/dist/commands/onboard.js +212 -2
- package/dist/commands/onboard.js.map +1 -1
- package/dist/commands/openclaw.d.ts +3 -0
- package/dist/commands/openclaw.d.ts.map +1 -1
- package/dist/commands/openclaw.js +76 -2
- package/dist/commands/openclaw.js.map +1 -1
- package/dist/commands/peter.d.ts +3 -0
- package/dist/commands/peter.d.ts.map +1 -1
- package/dist/commands/peter.js +1168 -58
- package/dist/commands/peter.js.map +1 -1
- package/dist/commands/pi-fleet.d.ts +18 -0
- package/dist/commands/pi-fleet.d.ts.map +1 -0
- package/dist/commands/pi-fleet.js +382 -0
- package/dist/commands/pi-fleet.js.map +1 -0
- package/dist/commands/pi.d.ts.map +1 -1
- package/dist/commands/pi.js +18 -3
- package/dist/commands/pi.js.map +1 -1
- package/dist/commands/scope.d.ts.map +1 -1
- package/dist/commands/scope.js +90 -1
- package/dist/commands/scope.js.map +1 -1
- package/dist/commands/services.d.ts.map +1 -1
- package/dist/commands/services.js +18 -0
- package/dist/commands/services.js.map +1 -1
- package/dist/commands/setup.d.ts +12 -0
- package/dist/commands/setup.d.ts.map +1 -0
- package/dist/commands/setup.js +322 -0
- package/dist/commands/setup.js.map +1 -0
- package/dist/commands/status.d.ts.map +1 -1
- package/dist/commands/status.js +22 -4
- package/dist/commands/status.js.map +1 -1
- package/dist/commands/train.d.ts +33 -0
- package/dist/commands/train.d.ts.map +1 -0
- package/dist/commands/train.js +510 -0
- package/dist/commands/train.js.map +1 -0
- package/dist/commands/verify.d.ts +14 -0
- package/dist/commands/verify.d.ts.map +1 -0
- package/dist/commands/verify.js +276 -0
- package/dist/commands/verify.js.map +1 -0
- package/dist/commands/viz.d.ts.map +1 -1
- package/dist/commands/viz.js +417 -0
- package/dist/commands/viz.js.map +1 -1
- package/dist/dashboard-static/assets/index-CW9ZxqX8.css +1 -0
- package/dist/dashboard-static/assets/index-DNN__p4K.js +121 -0
- package/dist/dashboard-static/index.html +2 -2
- package/dist/index.js +324 -64
- package/dist/index.js.map +1 -1
- package/dist/lib/agent-config.d.ts +52 -0
- package/dist/lib/agent-config.d.ts.map +1 -0
- package/dist/lib/agent-config.js +231 -0
- package/dist/lib/agent-config.js.map +1 -0
- package/dist/lib/agent-generator.d.ts +10 -0
- package/dist/lib/agent-generator.d.ts.map +1 -1
- package/dist/lib/agent-generator.js +64 -10
- package/dist/lib/agent-generator.js.map +1 -1
- package/dist/lib/agent-session.d.ts +104 -0
- package/dist/lib/agent-session.d.ts.map +1 -0
- package/dist/lib/agent-session.js +635 -0
- package/dist/lib/agent-session.js.map +1 -0
- package/dist/lib/eval-snapshot.d.ts +47 -0
- package/dist/lib/eval-snapshot.d.ts.map +1 -0
- package/dist/lib/eval-snapshot.js +315 -0
- package/dist/lib/eval-snapshot.js.map +1 -0
- package/dist/lib/eval-store.d.ts +5 -0
- package/dist/lib/eval-store.d.ts.map +1 -1
- package/dist/lib/eval-store.js +33 -3
- package/dist/lib/eval-store.js.map +1 -1
- package/dist/lib/findings-engine.d.ts +51 -0
- package/dist/lib/findings-engine.d.ts.map +1 -0
- package/dist/lib/findings-engine.js +338 -0
- package/dist/lib/findings-engine.js.map +1 -0
- package/dist/lib/flow-engine.d.ts +8 -0
- package/dist/lib/flow-engine.d.ts.map +1 -1
- package/dist/lib/flow-engine.js +84 -2
- package/dist/lib/flow-engine.js.map +1 -1
- package/dist/lib/hub-client.d.ts +1 -0
- package/dist/lib/hub-client.d.ts.map +1 -1
- package/dist/lib/hub-client.js +33 -6
- package/dist/lib/hub-client.js.map +1 -1
- package/dist/lib/ide-panes.d.ts +58 -0
- package/dist/lib/ide-panes.d.ts.map +1 -0
- package/dist/lib/ide-panes.js +508 -0
- package/dist/lib/ide-panes.js.map +1 -0
- package/dist/lib/memory-db.js +4 -4
- package/dist/lib/memory-db.js.map +1 -1
- package/dist/lib/memory-indexer.d.ts.map +1 -1
- package/dist/lib/memory-indexer.js +3 -0
- package/dist/lib/memory-indexer.js.map +1 -1
- package/dist/lib/memory-search.d.ts +148 -4
- package/dist/lib/memory-search.d.ts.map +1 -1
- package/dist/lib/memory-search.js +496 -58
- package/dist/lib/memory-search.js.map +1 -1
- package/dist/lib/meta-orchestrator.d.ts +104 -0
- package/dist/lib/meta-orchestrator.d.ts.map +1 -0
- package/dist/lib/meta-orchestrator.js +373 -0
- package/dist/lib/meta-orchestrator.js.map +1 -0
- package/dist/lib/peer-agent-generator.d.ts.map +1 -1
- package/dist/lib/peer-agent-generator.js +43 -19
- package/dist/lib/peer-agent-generator.js.map +1 -1
- package/dist/lib/pi-sky/bridge.d.ts +55 -0
- package/dist/lib/pi-sky/bridge.d.ts.map +1 -0
- package/dist/lib/pi-sky/bridge.js +264 -0
- package/dist/lib/pi-sky/bridge.js.map +1 -0
- package/dist/lib/pi-sky/cost-monitor.d.ts +21 -0
- package/dist/lib/pi-sky/cost-monitor.d.ts.map +1 -0
- package/dist/lib/pi-sky/cost-monitor.js +126 -0
- package/dist/lib/pi-sky/cost-monitor.js.map +1 -0
- package/dist/lib/pi-sky/eval-sweep.d.ts +27 -0
- package/dist/lib/pi-sky/eval-sweep.d.ts.map +1 -0
- package/dist/lib/pi-sky/eval-sweep.js +141 -0
- package/dist/lib/pi-sky/eval-sweep.js.map +1 -0
- package/dist/lib/pi-sky/event-router.d.ts +32 -0
- package/dist/lib/pi-sky/event-router.d.ts.map +1 -0
- package/dist/lib/pi-sky/event-router.js +176 -0
- package/dist/lib/pi-sky/event-router.js.map +1 -0
- package/dist/lib/pi-sky/experiment.d.ts +9 -0
- package/dist/lib/pi-sky/experiment.d.ts.map +1 -0
- package/dist/lib/pi-sky/experiment.js +83 -0
- package/dist/lib/pi-sky/experiment.js.map +1 -0
- package/dist/lib/pi-sky/index.d.ts +16 -0
- package/dist/lib/pi-sky/index.d.ts.map +1 -0
- package/dist/lib/pi-sky/index.js +16 -0
- package/dist/lib/pi-sky/index.js.map +1 -0
- package/dist/lib/pi-sky/stratus-gate.d.ts +28 -0
- package/dist/lib/pi-sky/stratus-gate.d.ts.map +1 -0
- package/dist/lib/pi-sky/stratus-gate.js +61 -0
- package/dist/lib/pi-sky/stratus-gate.js.map +1 -0
- package/dist/lib/pi-sky/swarm.d.ts +28 -0
- package/dist/lib/pi-sky/swarm.d.ts.map +1 -0
- package/dist/lib/pi-sky/swarm.js +208 -0
- package/dist/lib/pi-sky/swarm.js.map +1 -0
- package/dist/lib/pi-sky/types.d.ts +139 -0
- package/dist/lib/pi-sky/types.d.ts.map +1 -0
- package/dist/lib/pi-sky/types.js +2 -0
- package/dist/lib/pi-sky/types.js.map +1 -0
- package/dist/lib/pi-sky/voice-bridge.d.ts +20 -0
- package/dist/lib/pi-sky/voice-bridge.d.ts.map +1 -0
- package/dist/lib/pi-sky/voice-bridge.js +91 -0
- package/dist/lib/pi-sky/voice-bridge.js.map +1 -0
- package/dist/lib/policy-head.d.ts +40 -0
- package/dist/lib/policy-head.d.ts.map +1 -0
- package/dist/lib/policy-head.js +234 -0
- package/dist/lib/policy-head.js.map +1 -0
- package/dist/lib/predictor.d.ts +10 -0
- package/dist/lib/predictor.d.ts.map +1 -1
- package/dist/lib/predictor.js +46 -7
- package/dist/lib/predictor.js.map +1 -1
- package/dist/lib/replay-buffer.d.ts +93 -0
- package/dist/lib/replay-buffer.d.ts.map +1 -0
- package/dist/lib/replay-buffer.js +302 -0
- package/dist/lib/replay-buffer.js.map +1 -0
- package/dist/lib/sentinel-rl.d.ts +97 -0
- package/dist/lib/sentinel-rl.d.ts.map +1 -0
- package/dist/lib/sentinel-rl.js +430 -0
- package/dist/lib/sentinel-rl.js.map +1 -0
- package/dist/lib/session-lock.d.ts +61 -0
- package/dist/lib/session-lock.d.ts.map +1 -0
- package/dist/lib/session-lock.js +438 -0
- package/dist/lib/session-lock.js.map +1 -0
- package/dist/lib/setup/agent-generator.d.ts +18 -0
- package/dist/lib/setup/agent-generator.d.ts.map +1 -0
- package/dist/lib/setup/agent-generator.js +114 -0
- package/dist/lib/setup/agent-generator.js.map +1 -0
- package/dist/lib/setup/context-analyzer.d.ts +16 -0
- package/dist/lib/setup/context-analyzer.d.ts.map +1 -0
- package/dist/lib/setup/context-analyzer.js +112 -0
- package/dist/lib/setup/context-analyzer.js.map +1 -0
- package/dist/lib/setup/doc-auditor.d.ts +54 -0
- package/dist/lib/setup/doc-auditor.d.ts.map +1 -0
- package/dist/lib/setup/doc-auditor.js +629 -0
- package/dist/lib/setup/doc-auditor.js.map +1 -0
- package/dist/lib/setup/domain-generator.d.ts +7 -0
- package/dist/lib/setup/domain-generator.d.ts.map +1 -0
- package/dist/lib/setup/domain-generator.js +58 -0
- package/dist/lib/setup/domain-generator.js.map +1 -0
- package/dist/lib/setup/smart-eval-generator.d.ts +38 -0
- package/dist/lib/setup/smart-eval-generator.d.ts.map +1 -0
- package/dist/lib/setup/smart-eval-generator.js +378 -0
- package/dist/lib/setup/smart-eval-generator.js.map +1 -0
- package/dist/lib/setup/smart-recommender.d.ts +63 -0
- package/dist/lib/setup/smart-recommender.d.ts.map +1 -0
- package/dist/lib/setup/smart-recommender.js +329 -0
- package/dist/lib/setup/smart-recommender.js.map +1 -0
- package/dist/lib/setup/spec-generator.d.ts +63 -0
- package/dist/lib/setup/spec-generator.d.ts.map +1 -0
- package/dist/lib/setup/spec-generator.js +310 -0
- package/dist/lib/setup/spec-generator.js.map +1 -0
- package/dist/lib/setup/violation-agent-generator.d.ts +32 -0
- package/dist/lib/setup/violation-agent-generator.d.ts.map +1 -0
- package/dist/lib/setup/violation-agent-generator.js +255 -0
- package/dist/lib/setup/violation-agent-generator.js.map +1 -0
- package/dist/lib/stratus-client.d.ts +1 -0
- package/dist/lib/stratus-client.d.ts.map +1 -1
- package/dist/lib/stratus-client.js +24 -2
- package/dist/lib/stratus-client.js.map +1 -1
- package/dist/lib/telemetry-agent-v2.d.ts +128 -0
- package/dist/lib/telemetry-agent-v2.d.ts.map +1 -0
- package/dist/lib/telemetry-agent-v2.js +1042 -0
- package/dist/lib/telemetry-agent-v2.js.map +1 -0
- package/dist/lib/telemetry-agent.d.ts.map +1 -1
- package/dist/lib/telemetry-agent.js +27 -6
- package/dist/lib/telemetry-agent.js.map +1 -1
- package/dist/lib/telemetry-digest.d.ts.map +1 -1
- package/dist/lib/telemetry-digest.js +27 -5
- package/dist/lib/telemetry-digest.js.map +1 -1
- package/dist/lib/telemetry.d.ts.map +1 -1
- package/dist/lib/telemetry.js +29 -4
- package/dist/lib/telemetry.js.map +1 -1
- package/dist/lib/text-preprocessing.d.ts +83 -0
- package/dist/lib/text-preprocessing.d.ts.map +1 -0
- package/dist/lib/text-preprocessing.js +261 -0
- package/dist/lib/text-preprocessing.js.map +1 -0
- package/dist/lib/training-buffer.d.ts +86 -0
- package/dist/lib/training-buffer.d.ts.map +1 -0
- package/dist/lib/training-buffer.js +139 -0
- package/dist/lib/training-buffer.js.map +1 -0
- package/dist/lib/tuple-miner.d.ts +30 -0
- package/dist/lib/tuple-miner.d.ts.map +1 -0
- package/dist/lib/tuple-miner.js +427 -0
- package/dist/lib/tuple-miner.js.map +1 -0
- package/dist/lib/vm-backend.d.ts +72 -0
- package/dist/lib/vm-backend.d.ts.map +1 -0
- package/dist/lib/vm-backend.js +175 -0
- package/dist/lib/vm-backend.js.map +1 -0
- package/dist/lib/workspace/backend.d.ts +53 -0
- package/dist/lib/workspace/backend.d.ts.map +1 -0
- package/dist/lib/workspace/backend.js +37 -0
- package/dist/lib/workspace/backend.js.map +1 -0
- package/dist/lib/workspace/cmux-adapter.d.ts +46 -0
- package/dist/lib/workspace/cmux-adapter.d.ts.map +1 -0
- package/dist/lib/workspace/cmux-adapter.js +261 -0
- package/dist/lib/workspace/cmux-adapter.js.map +1 -0
- package/dist/lib/workspace/data-pipeline.d.ts +35 -0
- package/dist/lib/workspace/data-pipeline.d.ts.map +1 -0
- package/dist/lib/workspace/data-pipeline.js +463 -0
- package/dist/lib/workspace/data-pipeline.js.map +1 -0
- package/dist/lib/workspace/engine.d.ts +64 -0
- package/dist/lib/workspace/engine.d.ts.map +1 -0
- package/dist/lib/workspace/engine.js +397 -0
- package/dist/lib/workspace/engine.js.map +1 -0
- package/dist/lib/workspace/notifications.d.ts +14 -0
- package/dist/lib/workspace/notifications.d.ts.map +1 -0
- package/dist/lib/workspace/notifications.js +41 -0
- package/dist/lib/workspace/notifications.js.map +1 -0
- package/dist/lib/workspace/surface-registry.d.ts +49 -0
- package/dist/lib/workspace/surface-registry.d.ts.map +1 -0
- package/dist/lib/workspace/surface-registry.js +217 -0
- package/dist/lib/workspace/surface-registry.js.map +1 -0
- package/dist/lib/workspace/surface-type.d.ts +153 -0
- package/dist/lib/workspace/surface-type.d.ts.map +1 -0
- package/dist/lib/workspace/surface-type.js +9 -0
- package/dist/lib/workspace/surface-type.js.map +1 -0
- package/dist/lib/workspace/surfaces/agent-overview.d.ts +16 -0
- package/dist/lib/workspace/surfaces/agent-overview.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/agent-overview.js +116 -0
- package/dist/lib/workspace/surfaces/agent-overview.js.map +1 -0
- package/dist/lib/workspace/surfaces/agent.d.ts +16 -0
- package/dist/lib/workspace/surfaces/agent.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/agent.js +112 -0
- package/dist/lib/workspace/surfaces/agent.js.map +1 -0
- package/dist/lib/workspace/surfaces/claude.d.ts +15 -0
- package/dist/lib/workspace/surfaces/claude.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/claude.js +23 -0
- package/dist/lib/workspace/surfaces/claude.js.map +1 -0
- package/dist/lib/workspace/surfaces/dashboard.d.ts +21 -0
- package/dist/lib/workspace/surfaces/dashboard.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/dashboard.js +32 -0
- package/dist/lib/workspace/surfaces/dashboard.js.map +1 -0
- package/dist/lib/workspace/surfaces/eval.d.ts +15 -0
- package/dist/lib/workspace/surfaces/eval.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/eval.js +42 -0
- package/dist/lib/workspace/surfaces/eval.js.map +1 -0
- package/dist/lib/workspace/surfaces/event-stream.d.ts +16 -0
- package/dist/lib/workspace/surfaces/event-stream.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/event-stream.js +40 -0
- package/dist/lib/workspace/surfaces/event-stream.js.map +1 -0
- package/dist/lib/workspace/surfaces/flow.d.ts +16 -0
- package/dist/lib/workspace/surfaces/flow.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/flow.js +49 -0
- package/dist/lib/workspace/surfaces/flow.js.map +1 -0
- package/dist/lib/workspace/surfaces/index.d.ts +16 -0
- package/dist/lib/workspace/surfaces/index.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/index.js +16 -0
- package/dist/lib/workspace/surfaces/index.js.map +1 -0
- package/dist/lib/workspace/surfaces/portfolio.d.ts +16 -0
- package/dist/lib/workspace/surfaces/portfolio.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/portfolio.js +102 -0
- package/dist/lib/workspace/surfaces/portfolio.js.map +1 -0
- package/dist/lib/workspace/surfaces/service.d.ts +16 -0
- package/dist/lib/workspace/surfaces/service.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/service.js +45 -0
- package/dist/lib/workspace/surfaces/service.js.map +1 -0
- package/dist/lib/workspace/surfaces/shell.d.ts +15 -0
- package/dist/lib/workspace/surfaces/shell.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/shell.js +19 -0
- package/dist/lib/workspace/surfaces/shell.js.map +1 -0
- package/dist/lib/workspace/surfaces/telemetry.d.ts +16 -0
- package/dist/lib/workspace/surfaces/telemetry.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/telemetry.js +48 -0
- package/dist/lib/workspace/surfaces/telemetry.js.map +1 -0
- package/dist/lib/workspace/surfaces/topology.d.ts +15 -0
- package/dist/lib/workspace/surfaces/topology.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/topology.js +19 -0
- package/dist/lib/workspace/surfaces/topology.js.map +1 -0
- package/dist/lib/workspace/surfaces/training.d.ts +16 -0
- package/dist/lib/workspace/surfaces/training.d.ts.map +1 -0
- package/dist/lib/workspace/surfaces/training.js +22 -0
- package/dist/lib/workspace/surfaces/training.js.map +1 -0
- package/dist/lib/workspace/tmux-adapter.d.ts +27 -0
- package/dist/lib/workspace/tmux-adapter.d.ts.map +1 -0
- package/dist/lib/workspace/tmux-adapter.js +106 -0
- package/dist/lib/workspace/tmux-adapter.js.map +1 -0
- package/dist/mcp/context-hub-mcp.js +7 -24
- package/dist/mcp/context-hub-mcp.js.map +1 -1
- package/dist/types/flows.d.ts +2 -0
- package/dist/types/flows.d.ts.map +1 -1
- package/dist/types/ide.d.ts +49 -0
- package/dist/types/ide.d.ts.map +1 -0
- package/dist/types/ide.js +5 -0
- package/dist/types/ide.js.map +1 -0
- package/dist/types/platform-digest.d.ts +228 -0
- package/dist/types/platform-digest.d.ts.map +1 -0
- package/dist/types/platform-digest.js +5 -0
- package/dist/types/platform-digest.js.map +1 -0
- package/dist/types/telemetry-digest.d.ts +2 -0
- package/dist/types/telemetry-digest.d.ts.map +1 -1
- package/dist/utils/ensure-project.d.ts +1 -0
- package/dist/utils/ensure-project.d.ts.map +1 -1
- package/dist/utils/ensure-project.js +19 -7
- package/dist/utils/ensure-project.js.map +1 -1
- package/dist/utils/jfl-config.d.ts +1 -0
- package/dist/utils/jfl-config.d.ts.map +1 -1
- package/dist/utils/jfl-config.js +19 -1
- package/dist/utils/jfl-config.js.map +1 -1
- package/dist/utils/jfl-paths.d.ts +5 -0
- package/dist/utils/jfl-paths.d.ts.map +1 -1
- package/dist/utils/jfl-paths.js +25 -3
- package/dist/utils/jfl-paths.js.map +1 -1
- package/package.json +3 -2
- package/packages/pi/AGENTS.md +112 -0
- package/packages/pi/extensions/agent-grid.ts +191 -0
- package/packages/pi/extensions/agent-names.ts +178 -0
- package/packages/pi/extensions/autoresearch.ts +427 -0
- package/packages/pi/extensions/bookmarks.ts +85 -0
- package/packages/pi/extensions/context.ts +184 -0
- package/packages/pi/extensions/crm-tool.ts +61 -0
- package/packages/pi/extensions/eval-tool.ts +224 -0
- package/packages/pi/extensions/eval.ts +60 -0
- package/packages/pi/extensions/footer.ts +239 -0
- package/packages/pi/extensions/hub-resolver.ts +63 -0
- package/packages/pi/extensions/hud-tool.ts +145 -0
- package/packages/pi/extensions/index.ts +405 -0
- package/packages/pi/extensions/journal.ts +224 -0
- package/packages/pi/extensions/map-bridge.ts +178 -0
- package/packages/pi/extensions/memory-tool.ts +73 -0
- package/packages/pi/extensions/notifications.ts +73 -0
- package/packages/pi/extensions/peter-parker.ts +202 -0
- package/packages/pi/extensions/policy-head-tool.ts +276 -0
- package/packages/pi/extensions/portfolio-bridge.ts +90 -0
- package/packages/pi/extensions/session.ts +142 -0
- package/packages/pi/extensions/shortcuts.ts +259 -0
- package/packages/pi/extensions/stratus-bridge.ts +115 -0
- package/packages/pi/extensions/synopsis-tool.ts +83 -0
- package/packages/pi/extensions/tool-renderers.ts +353 -0
- package/packages/pi/extensions/training-buffer-tool.ts +368 -0
- package/packages/pi/extensions/types.ts +163 -0
- package/packages/pi/package-lock.json +346 -0
- package/packages/pi/package.json +44 -0
- package/packages/pi/skills/agent-browser/SKILL.md +116 -0
- package/packages/pi/skills/brand-architect/SKILL.md +240 -0
- package/packages/pi/skills/brand-architect/config.yaml +137 -0
- package/packages/pi/skills/campaign-hud/config.yaml +112 -0
- package/packages/pi/skills/content-creator/SKILL.md +294 -0
- package/packages/pi/skills/context/SKILL.md +65 -0
- package/packages/pi/skills/debug/MULTI_AGENT.md +360 -0
- package/packages/pi/skills/debug/SKILL.md +554 -0
- package/packages/pi/skills/end/SKILL.md +1782 -0
- package/packages/pi/skills/eval/SKILL.md +75 -0
- package/packages/pi/skills/fly-deploy/SKILL.md +676 -0
- package/packages/pi/skills/founder-video/SKILL.md +467 -0
- package/packages/pi/skills/hud/SKILL.md +160 -0
- package/packages/pi/skills/orchestrate/SKILL.md +74 -0
- package/packages/pi/skills/pi-agents/SKILL.md +78 -0
- package/packages/pi/skills/react-best-practices/AGENTS.md +2249 -0
- package/packages/pi/skills/react-best-practices/README.md +123 -0
- package/packages/pi/skills/react-best-practices/SKILL.md +125 -0
- package/packages/pi/skills/react-best-practices/metadata.json +15 -0
- package/packages/pi/skills/react-best-practices/rules/_sections.md +46 -0
- package/packages/pi/skills/react-best-practices/rules/_template.md +28 -0
- package/packages/pi/skills/react-best-practices/rules/advanced-event-handler-refs.md +55 -0
- package/packages/pi/skills/react-best-practices/rules/advanced-use-latest.md +49 -0
- package/packages/pi/skills/react-best-practices/rules/async-api-routes.md +38 -0
- package/packages/pi/skills/react-best-practices/rules/async-defer-await.md +80 -0
- package/packages/pi/skills/react-best-practices/rules/async-dependencies.md +36 -0
- package/packages/pi/skills/react-best-practices/rules/async-parallel.md +28 -0
- package/packages/pi/skills/react-best-practices/rules/async-suspense-boundaries.md +99 -0
- package/packages/pi/skills/react-best-practices/rules/bundle-barrel-imports.md +59 -0
- package/packages/pi/skills/react-best-practices/rules/bundle-conditional.md +31 -0
- package/packages/pi/skills/react-best-practices/rules/bundle-defer-third-party.md +49 -0
- package/packages/pi/skills/react-best-practices/rules/bundle-dynamic-imports.md +35 -0
- package/packages/pi/skills/react-best-practices/rules/bundle-preload.md +50 -0
- package/packages/pi/skills/react-best-practices/rules/client-event-listeners.md +74 -0
- package/packages/pi/skills/react-best-practices/rules/client-swr-dedup.md +56 -0
- package/packages/pi/skills/react-best-practices/rules/js-batch-dom-css.md +82 -0
- package/packages/pi/skills/react-best-practices/rules/js-cache-function-results.md +80 -0
- package/packages/pi/skills/react-best-practices/rules/js-cache-property-access.md +28 -0
- package/packages/pi/skills/react-best-practices/rules/js-cache-storage.md +70 -0
- package/packages/pi/skills/react-best-practices/rules/js-combine-iterations.md +32 -0
- package/packages/pi/skills/react-best-practices/rules/js-early-exit.md +50 -0
- package/packages/pi/skills/react-best-practices/rules/js-hoist-regexp.md +45 -0
- package/packages/pi/skills/react-best-practices/rules/js-index-maps.md +37 -0
- package/packages/pi/skills/react-best-practices/rules/js-length-check-first.md +49 -0
- package/packages/pi/skills/react-best-practices/rules/js-min-max-loop.md +82 -0
- package/packages/pi/skills/react-best-practices/rules/js-set-map-lookups.md +24 -0
- package/packages/pi/skills/react-best-practices/rules/js-tosorted-immutable.md +57 -0
- package/packages/pi/skills/react-best-practices/rules/rendering-activity.md +26 -0
- package/packages/pi/skills/react-best-practices/rules/rendering-animate-svg-wrapper.md +47 -0
- package/packages/pi/skills/react-best-practices/rules/rendering-conditional-render.md +40 -0
- package/packages/pi/skills/react-best-practices/rules/rendering-content-visibility.md +38 -0
- package/packages/pi/skills/react-best-practices/rules/rendering-hoist-jsx.md +46 -0
- package/packages/pi/skills/react-best-practices/rules/rendering-hydration-no-flicker.md +82 -0
- package/packages/pi/skills/react-best-practices/rules/rendering-svg-precision.md +28 -0
- package/packages/pi/skills/react-best-practices/rules/rerender-defer-reads.md +39 -0
- package/packages/pi/skills/react-best-practices/rules/rerender-dependencies.md +45 -0
- package/packages/pi/skills/react-best-practices/rules/rerender-derived-state.md +29 -0
- package/packages/pi/skills/react-best-practices/rules/rerender-functional-setstate.md +74 -0
- package/packages/pi/skills/react-best-practices/rules/rerender-lazy-state-init.md +58 -0
- package/packages/pi/skills/react-best-practices/rules/rerender-memo.md +44 -0
- package/packages/pi/skills/react-best-practices/rules/rerender-transitions.md +40 -0
- package/packages/pi/skills/react-best-practices/rules/server-after-nonblocking.md +73 -0
- package/packages/pi/skills/react-best-practices/rules/server-cache-lru.md +41 -0
- package/packages/pi/skills/react-best-practices/rules/server-cache-react.md +26 -0
- package/packages/pi/skills/react-best-practices/rules/server-parallel-fetching.md +79 -0
- package/packages/pi/skills/react-best-practices/rules/server-serialization.md +38 -0
- package/packages/pi/skills/remotion-best-practices/SKILL.md +43 -0
- package/packages/pi/skills/remotion-best-practices/rules/3d.md +86 -0
- package/packages/pi/skills/remotion-best-practices/rules/animations.md +29 -0
- package/packages/pi/skills/remotion-best-practices/rules/assets/charts-bar-chart.tsx +173 -0
- package/packages/pi/skills/remotion-best-practices/rules/assets/text-animations-typewriter.tsx +100 -0
- package/packages/pi/skills/remotion-best-practices/rules/assets/text-animations-word-highlight.tsx +108 -0
- package/packages/pi/skills/remotion-best-practices/rules/assets.md +78 -0
- package/packages/pi/skills/remotion-best-practices/rules/audio.md +172 -0
- package/packages/pi/skills/remotion-best-practices/rules/calculate-metadata.md +104 -0
- package/packages/pi/skills/remotion-best-practices/rules/can-decode.md +75 -0
- package/packages/pi/skills/remotion-best-practices/rules/charts.md +58 -0
- package/packages/pi/skills/remotion-best-practices/rules/compositions.md +146 -0
- package/packages/pi/skills/remotion-best-practices/rules/display-captions.md +126 -0
- package/packages/pi/skills/remotion-best-practices/rules/extract-frames.md +229 -0
- package/packages/pi/skills/remotion-best-practices/rules/fonts.md +152 -0
- package/packages/pi/skills/remotion-best-practices/rules/get-audio-duration.md +58 -0
- package/packages/pi/skills/remotion-best-practices/rules/get-video-dimensions.md +68 -0
- package/packages/pi/skills/remotion-best-practices/rules/get-video-duration.md +58 -0
- package/packages/pi/skills/remotion-best-practices/rules/gifs.md +138 -0
- package/packages/pi/skills/remotion-best-practices/rules/images.md +130 -0
- package/packages/pi/skills/remotion-best-practices/rules/import-srt-captions.md +67 -0
- package/packages/pi/skills/remotion-best-practices/rules/lottie.md +68 -0
- package/packages/pi/skills/remotion-best-practices/rules/measuring-dom-nodes.md +35 -0
- package/packages/pi/skills/remotion-best-practices/rules/measuring-text.md +143 -0
- package/packages/pi/skills/remotion-best-practices/rules/sequencing.md +106 -0
- package/packages/pi/skills/remotion-best-practices/rules/tailwind.md +11 -0
- package/packages/pi/skills/remotion-best-practices/rules/text-animations.md +20 -0
- package/packages/pi/skills/remotion-best-practices/rules/timing.md +179 -0
- package/packages/pi/skills/remotion-best-practices/rules/transcribe-captions.md +19 -0
- package/packages/pi/skills/remotion-best-practices/rules/transitions.md +122 -0
- package/packages/pi/skills/remotion-best-practices/rules/trimming.md +53 -0
- package/packages/pi/skills/remotion-best-practices/rules/videos.md +171 -0
- package/packages/pi/skills/search/SKILL.md +220 -0
- package/packages/pi/skills/spec/SKILL.md +377 -0
- package/packages/pi/skills/startup/SKILL.md +315 -0
- package/packages/pi/skills/web-architect/SKILL.md +309 -0
- package/packages/pi/skills/x-algorithm/SKILL.md +305 -0
- package/packages/pi/teams/dev-team.yaml +63 -0
- package/packages/pi/teams/gtm-team.yaml +79 -0
- package/packages/pi/themes/jfl.theme.json +76 -0
- package/packages/pi/tsconfig.json +21 -0
- package/scripts/collect-tuples.sh +124 -0
- package/scripts/destroy-fleet.sh +37 -0
- package/scripts/jfl-ide.sh +48 -0
- package/scripts/session/session-cleanup.sh +4 -11
- package/scripts/session/session-init.sh +6 -0
- package/scripts/session/session-sync.sh +25 -0
- package/scripts/setup-branch-protection.sh +106 -0
- package/scripts/spawn-fleet.sh +144 -0
- package/scripts/train/requirements.txt +5 -0
- package/scripts/train/train-policy-head.py +477 -0
- package/scripts/train/v2/dataset.py +81 -0
- package/scripts/train/v2/domain.json +18 -0
- package/scripts/train/v2/eval.py +196 -0
- package/scripts/train/v2/generate_data.py +219 -0
- package/scripts/train/v2/infer.py +188 -0
- package/scripts/train/v2/model.py +112 -0
- package/scripts/train/v2/precompute.py +132 -0
- package/scripts/train/v2/train.py +302 -0
- package/scripts/train/v2/transform_buffer.py +227 -0
- package/scripts/train/v2/validate_data.py +115 -0
- package/scripts/train-policy-head.py +434 -0
- package/scripts/vm-swarm/README.md +301 -0
- package/scripts/vm-swarm/collect-tuples.sh +331 -0
- package/scripts/vm-swarm/create-base-template.sh +339 -0
- package/scripts/vm-swarm/kill-fleet.sh +204 -0
- package/scripts/vm-swarm/monitor-fleet.sh +346 -0
- package/scripts/vm-swarm/spawn-fleet.sh +304 -0
- package/template/.claude/settings.json +2 -15
- package/template/.github/workflows/jfl-eval.yml +6 -1
- package/template/.github/workflows/jfl-review.yml +4 -0
- package/template/scripts/session/session-cleanup.sh +2 -11
- package/template/scripts/session/session-end-hub.sh +72 -0
- package/template/scripts/session/session-end.sh +69 -6
- package/template/scripts/session/session-init.sh +55 -30
- package/template/scripts/session/session-lock.sh +464 -0
- package/template/scripts/session/session-start-hub.sh +105 -0
- package/template/templates/service-agent/workflows/jfl-eval.yml +19 -0
- package/dist/dashboard-static/assets/index-B6kRK9Rq.js +0 -116
- package/dist/dashboard-static/assets/index-BpdKJPLu.css +0 -1
package/dist/index.js
CHANGED
|
@@ -12,47 +12,30 @@ import { readFileSync } from "fs";
|
|
|
12
12
|
import { join } from "path";
|
|
13
13
|
import * as path from "path";
|
|
14
14
|
import { fileURLToPath } from "url";
|
|
15
|
-
|
|
16
|
-
import
|
|
17
|
-
import { initCommand } from "./commands/init.js";
|
|
18
|
-
import { repairCommand } from "./commands/repair.js";
|
|
19
|
-
import { validateSettingsCommand } from "./commands/validate-settings.js";
|
|
20
|
-
import { loginCommand, logout } from "./commands/login.js";
|
|
21
|
-
import { statusCommand } from "./commands/status.js";
|
|
22
|
-
import { deployCommand } from "./commands/deploy.js";
|
|
23
|
-
import { agentsCommand } from "./commands/agents.js";
|
|
24
|
-
import { hudCommand } from "./commands/hud.js";
|
|
25
|
-
import { sessionCommand } from "./commands/session.js";
|
|
26
|
-
import { feedbackCommand } from "./commands/feedback.js";
|
|
27
|
-
import { updateCommand } from "./commands/update.js";
|
|
28
|
-
import { contextHubCommand } from "./commands/context-hub.js";
|
|
29
|
-
import { hooksCommand } from "./commands/hooks.js";
|
|
30
|
-
import { flowsCommand } from "./commands/flows.js";
|
|
31
|
-
import { scopeCommand } from "./commands/scope.js";
|
|
32
|
-
import { voiceCommand } from "./commands/voice.js";
|
|
33
|
-
import { synopsisCommand } from "./commands/synopsis.js";
|
|
34
|
-
import { onboardCommand } from "./commands/onboard.js";
|
|
35
|
-
import { profileCommand } from "./commands/profile.js";
|
|
36
|
-
import { migrateServices } from "./commands/migrate-services.js";
|
|
37
|
-
import { memoryInitCommand, memoryStatusCommand, memorySearchCommand, memoryIndexCommand } from "./commands/memory.js";
|
|
38
|
-
import { listSkillsCommand, installSkillCommand, removeSkillCommand, updateSkillsCommand, searchSkillsCommand, } from "./commands/skills.js";
|
|
39
|
-
import { ralphCommand, showRalphHelp } from "./commands/ralph.js";
|
|
40
|
-
import { peterCommand } from "./commands/peter.js";
|
|
41
|
-
import { clawdbotSetupCommand, clawdbotStatusCommand } from "./commands/clawdbot.js";
|
|
42
|
-
import { showDayPassStatus, hasWallet, getWalletAddress, } from "./utils/auth-guard.js";
|
|
43
|
-
import { checkAndMigrate } from "./utils/jfl-migration.js";
|
|
15
|
+
// Lazy imports - only load when needed to reduce startup latency
|
|
16
|
+
// All commands use dynamic import() to defer loading until invoked
|
|
44
17
|
import { JFL_PATHS } from "./utils/jfl-paths.js";
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
18
|
+
// Telemetry loaded lazily on first track() call
|
|
19
|
+
let _telemetry;
|
|
20
|
+
async function getTelemetry() {
|
|
21
|
+
if (!_telemetry) {
|
|
22
|
+
const mod = await import("./lib/telemetry.js");
|
|
23
|
+
_telemetry = mod.telemetry;
|
|
24
|
+
}
|
|
25
|
+
return _telemetry;
|
|
26
|
+
}
|
|
27
|
+
// Migration check runs in background, doesn't block startup
|
|
28
|
+
import("./utils/jfl-migration.js").then(mod => mod.checkAndMigrate({ silent: true })).catch(() => { });
|
|
48
29
|
const program = new Command();
|
|
49
|
-
// Telemetry hooks — auto-track all commands
|
|
30
|
+
// Telemetry hooks — auto-track all commands (lazy load telemetry)
|
|
50
31
|
program.hook('preAction', (_thisCommand, actionCommand) => {
|
|
51
32
|
;
|
|
52
33
|
actionCommand.__telemetryStart = Date.now();
|
|
53
34
|
});
|
|
54
|
-
program.hook('postAction', (_thisCommand, actionCommand) => {
|
|
35
|
+
program.hook('postAction', async (_thisCommand, actionCommand) => {
|
|
55
36
|
const start = actionCommand.__telemetryStart;
|
|
37
|
+
// Lazy load telemetry only when actually tracking
|
|
38
|
+
const telemetry = await getTelemetry();
|
|
56
39
|
telemetry.track({
|
|
57
40
|
category: 'command',
|
|
58
41
|
event: `command:${actionCommand.name()}`,
|
|
@@ -62,11 +45,11 @@ program.hook('postAction', (_thisCommand, actionCommand) => {
|
|
|
62
45
|
});
|
|
63
46
|
});
|
|
64
47
|
const HELP_GROUPS = {
|
|
65
|
-
"Getting Started": ["init", "status", "hud", "doctor"],
|
|
48
|
+
"Getting Started": ["init", "status", "hud", "ide", "doctor"],
|
|
66
49
|
"Daily Use": ["synopsis", "ask", "improve", "events", "voice"],
|
|
67
|
-
"Management": ["services", "portfolio", "flows", "hooks", "scope", "memory", "eval", "viz", "telemetry", "context-hub", "skills", "ci"],
|
|
50
|
+
"Management": ["services", "portfolio", "flows", "hooks", "scope", "memory", "eval", "findings", "viz", "telemetry", "context-hub", "skills", "ci"],
|
|
68
51
|
"Platform": ["login", "deploy", "wallet", "preferences"],
|
|
69
|
-
"Advanced": ["peter", "orchestrate", "openclaw", "ralph", "agent"],
|
|
52
|
+
"Advanced": ["peter", "orchestrate", "openclaw", "ralph", "agent", "train", "setup"],
|
|
70
53
|
};
|
|
71
54
|
const HIDDEN_COMMANDS = new Set([
|
|
72
55
|
"repair", "validate-settings", "test", "brand", "content", "feedback",
|
|
@@ -158,9 +141,11 @@ program
|
|
|
158
141
|
.action(async (options) => {
|
|
159
142
|
// Always update on session start (unless --no-update flag)
|
|
160
143
|
if (options.update !== false) {
|
|
144
|
+
const { updateCommand } = await import("./commands/update.js");
|
|
161
145
|
await updateCommand({ autoUpdate: true });
|
|
162
146
|
console.log(); // Add spacing before session starts
|
|
163
147
|
}
|
|
148
|
+
const { sessionCommand } = await import("./commands/session.js");
|
|
164
149
|
await sessionCommand({});
|
|
165
150
|
});
|
|
166
151
|
// ============================================================================
|
|
@@ -170,26 +155,55 @@ program
|
|
|
170
155
|
.command("init")
|
|
171
156
|
.description("Initialize a new JFL project")
|
|
172
157
|
.option("-n, --name <name>", "Project name")
|
|
173
|
-
.action(
|
|
158
|
+
.action(async (options) => {
|
|
159
|
+
const { initCommand } = await import("./commands/init.js");
|
|
160
|
+
await initCommand(options);
|
|
161
|
+
});
|
|
174
162
|
program
|
|
175
163
|
.command("repair")
|
|
176
164
|
.description("Repair a JFL project missing .jfl directory")
|
|
177
|
-
.action(
|
|
165
|
+
.action(async () => {
|
|
166
|
+
const { repairCommand } = await import("./commands/repair.js");
|
|
167
|
+
await repairCommand();
|
|
168
|
+
});
|
|
178
169
|
program
|
|
179
170
|
.command("validate-settings")
|
|
180
171
|
.description("Validate and repair .claude/settings.json")
|
|
181
172
|
.option("--fix", "Attempt to auto-repair common issues")
|
|
182
173
|
.option("--json", "Output in JSON format")
|
|
183
|
-
.action(
|
|
174
|
+
.action(async (options) => {
|
|
175
|
+
const { validateSettingsCommand } = await import("./commands/validate-settings.js");
|
|
176
|
+
await validateSettingsCommand(options);
|
|
177
|
+
});
|
|
184
178
|
program
|
|
185
179
|
.command("hud")
|
|
186
180
|
.description("Show campaign dashboard")
|
|
187
181
|
.option("-c, --compact", "Show compact one-line status")
|
|
188
|
-
.action(
|
|
182
|
+
.action(async (options) => {
|
|
183
|
+
const { hudCommand } = await import("./commands/hud.js");
|
|
184
|
+
await hudCommand(options);
|
|
185
|
+
});
|
|
189
186
|
program
|
|
190
187
|
.command("status")
|
|
191
188
|
.description("Show project status")
|
|
192
|
-
.action(
|
|
189
|
+
.action(async () => {
|
|
190
|
+
const { statusCommand } = await import("./commands/status.js");
|
|
191
|
+
await statusCommand();
|
|
192
|
+
});
|
|
193
|
+
// IDE workspace command — uses dynamic imports to avoid linter stripping
|
|
194
|
+
const ide = program.command("ide").description("Terminal workspace — cmux/tmux with live sidebar data and notifications");
|
|
195
|
+
ide.command("launch", { isDefault: true }).description("Launch workspace (default)").option("--json", "Output as JSON").action(async (options) => { const m = await import("./commands/ide.js"); await m.ideLaunchCommand(options); });
|
|
196
|
+
ide.command("add").description("Add a surface to the workspace").argument("[name]", "Surface name (agent, built-in type, or service)").option("--row <n>", "Row index (0-based)").option("--position <n>", "Position within row (0-based)").option("--title <title>", "Custom surface title").option("--cmd <command>", "Custom surface command").action(async (name, options) => { const m = await import("./commands/ide.js"); await m.ideAddCommand(name, options); });
|
|
197
|
+
ide.command("remove").description("Remove a surface from the workspace").argument("<name>", "Surface name or title to remove").action(async (name) => { const m = await import("./commands/ide.js"); await m.ideRemoveCommand(name); });
|
|
198
|
+
ide.command("available").description("List available surface types, agents, and services").action(async () => { const m = await import("./commands/ide.js"); await m.ideAvailableCommand(); });
|
|
199
|
+
ide.command("status").description("Show current workspace layout and session state").option("--json", "Output as JSON").action(async (options) => { const m = await import("./commands/ide.js"); await m.ideStatusCommand(options); });
|
|
200
|
+
ide.command("surfaces").description("List active surfaces with live sidebar data").option("--json", "Output as JSON").action(async (options) => { const m = await import("./commands/ide.js"); await m.ideSurfacesCommand(options); });
|
|
201
|
+
ide.command("stop").description("Stop the running workspace session").action(async () => { const m = await import("./commands/ide.js"); await m.ideStopCommand(); });
|
|
202
|
+
ide.command("restart").description("Restart the workspace session").action(async () => { const m = await import("./commands/ide.js"); await m.ideRestartCommand(); });
|
|
203
|
+
ide.command("reset").description("Reset workspace to welcome state").action(async () => { const m = await import("./commands/ide.js"); await m.ideResetCommand(); });
|
|
204
|
+
ide.command("open").description("Open a child project/service in the workspace").argument("<name>", "Service or product name to open").action(async (name) => { const m = await import("./commands/ide.js"); await m.ideOpenCommand(name); });
|
|
205
|
+
ide.command("up").description("Navigate to parent project (portfolio or GTM)").action(async () => { const m = await import("./commands/ide.js"); await m.ideUpCommand(); });
|
|
206
|
+
ide.command("config").description("View or set IDE configuration").argument("[key]", "Config key (e.g., primary, backend)").argument("[value]", "Config value").action(async (key, value) => { const m = await import("./commands/ide.js"); await m.ideConfigCommand(key, value); });
|
|
193
207
|
program
|
|
194
208
|
.command("context-hub")
|
|
195
209
|
.description("Manage Context Hub daemon (unified context for AI agents)")
|
|
@@ -199,12 +213,15 @@ program
|
|
|
199
213
|
.option("-q, --quiet", "Suppress output (for daemon use)")
|
|
200
214
|
.option("--clean", "Remove stale entries (for doctor)")
|
|
201
215
|
.option("--purge", "Also delete token file (for stop)")
|
|
216
|
+
.option("--project-root <path>", "Override project root directory")
|
|
202
217
|
.allowUnknownOption()
|
|
203
218
|
.action(async (action, options) => {
|
|
219
|
+
const { contextHubCommand } = await import("./commands/context-hub.js");
|
|
204
220
|
await contextHubCommand(action, {
|
|
205
221
|
port: options.port ? parseInt(options.port, 10) : undefined,
|
|
206
222
|
global: options.global || false,
|
|
207
223
|
quiet: options.quiet || false,
|
|
224
|
+
projectRoot: options.projectRoot,
|
|
208
225
|
});
|
|
209
226
|
});
|
|
210
227
|
program
|
|
@@ -212,6 +229,7 @@ program
|
|
|
212
229
|
.description("Manage Claude Code HTTP hooks for Context Hub")
|
|
213
230
|
.argument("[action]", "init, status, remove")
|
|
214
231
|
.action(async (action) => {
|
|
232
|
+
const { hooksCommand } = await import("./commands/hooks.js");
|
|
215
233
|
await hooksCommand(action);
|
|
216
234
|
});
|
|
217
235
|
program
|
|
@@ -222,6 +240,7 @@ program
|
|
|
222
240
|
.option("--flow <name>", "Filter approvals to a specific flow")
|
|
223
241
|
.option("--all", "Approve all pending gated executions")
|
|
224
242
|
.action(async (action, name, options) => {
|
|
243
|
+
const { flowsCommand } = await import("./commands/flows.js");
|
|
225
244
|
await flowsCommand(action, name, options);
|
|
226
245
|
});
|
|
227
246
|
program
|
|
@@ -230,6 +249,7 @@ program
|
|
|
230
249
|
.argument("[action]", "list, set, test, viz")
|
|
231
250
|
.argument("[args...]", "Arguments for the action")
|
|
232
251
|
.action(async (action, args) => {
|
|
252
|
+
const { scopeCommand } = await import("./commands/scope.js");
|
|
233
253
|
await scopeCommand(action, ...args);
|
|
234
254
|
});
|
|
235
255
|
program
|
|
@@ -238,6 +258,7 @@ program
|
|
|
238
258
|
.argument("[hours]", "Hours to look back (default: 24)", "24")
|
|
239
259
|
.argument("[author]", "Filter by author name")
|
|
240
260
|
.action(async (hours, author) => {
|
|
261
|
+
const { synopsisCommand } = await import("./commands/synopsis.js");
|
|
241
262
|
await synopsisCommand(hours, author);
|
|
242
263
|
});
|
|
243
264
|
program
|
|
@@ -332,6 +353,7 @@ program
|
|
|
332
353
|
.option("-d, --description <desc>", "Override service description")
|
|
333
354
|
.option("--skip-git", "Skip git clone (treat URL as local path)")
|
|
334
355
|
.action(async (pathOrUrl, options) => {
|
|
356
|
+
const { onboardCommand } = await import("./commands/onboard.js");
|
|
335
357
|
await onboardCommand(pathOrUrl, options);
|
|
336
358
|
});
|
|
337
359
|
program
|
|
@@ -414,6 +436,7 @@ program
|
|
|
414
436
|
.argument("[action]", "show, edit, export, import, generate")
|
|
415
437
|
.option("-f, --file <path>", "File path for export/import/generate output")
|
|
416
438
|
.action(async (action, options) => {
|
|
439
|
+
const { profileCommand } = await import("./commands/profile.js");
|
|
417
440
|
await profileCommand(action, options);
|
|
418
441
|
});
|
|
419
442
|
program
|
|
@@ -421,6 +444,7 @@ program
|
|
|
421
444
|
.description("Migrate services from references/ to service manager")
|
|
422
445
|
.argument("[gtm-path]", "Path to GTM project (default: current directory)")
|
|
423
446
|
.action(async (gtmPath) => {
|
|
447
|
+
const { migrateServices } = await import("./commands/migrate-services.js");
|
|
424
448
|
await migrateServices(gtmPath);
|
|
425
449
|
});
|
|
426
450
|
// ============================================================================
|
|
@@ -435,11 +459,15 @@ program
|
|
|
435
459
|
.option("--team", "Use Team plan ($199/mo)")
|
|
436
460
|
.option("--free", "Stay on trial")
|
|
437
461
|
.option("--force", "Force re-authentication")
|
|
438
|
-
.action(
|
|
462
|
+
.action(async (options) => {
|
|
463
|
+
const { loginCommand } = await import("./commands/login.js");
|
|
464
|
+
await loginCommand(options);
|
|
465
|
+
});
|
|
439
466
|
program
|
|
440
467
|
.command("logout")
|
|
441
468
|
.description("Logout from JFL platform")
|
|
442
|
-
.action(() => {
|
|
469
|
+
.action(async () => {
|
|
470
|
+
const { logout } = await import("./commands/login.js");
|
|
443
471
|
logout();
|
|
444
472
|
console.log(chalk.green("Logged out successfully."));
|
|
445
473
|
});
|
|
@@ -451,7 +479,7 @@ program
|
|
|
451
479
|
.option("--telemetry", "Enable anonymous telemetry")
|
|
452
480
|
.option("--show", "Show current preferences")
|
|
453
481
|
.action(async (options) => {
|
|
454
|
-
const { getConfigValue, deleteConfigKey
|
|
482
|
+
const { getConfigValue, deleteConfigKey } = await import("./utils/jfl-config.js");
|
|
455
483
|
if (options.clearAi) {
|
|
456
484
|
deleteConfigKey("aiCLI");
|
|
457
485
|
console.log(chalk.green("\n✓ Cleared AI CLI preference"));
|
|
@@ -459,18 +487,21 @@ program
|
|
|
459
487
|
return;
|
|
460
488
|
}
|
|
461
489
|
if (options.telemetry === false) {
|
|
490
|
+
const telemetry = await getTelemetry();
|
|
462
491
|
telemetry.disable();
|
|
463
492
|
console.log(chalk.green("\n✓ Telemetry disabled"));
|
|
464
493
|
console.log(chalk.gray(" No data will be collected\n"));
|
|
465
494
|
return;
|
|
466
495
|
}
|
|
467
496
|
if (options.telemetry === true) {
|
|
497
|
+
const telemetry = await getTelemetry();
|
|
468
498
|
telemetry.enable();
|
|
469
499
|
console.log(chalk.green("\n✓ Telemetry enabled"));
|
|
470
500
|
console.log(chalk.gray(" Anonymous usage data helps improve JFL\n"));
|
|
471
501
|
return;
|
|
472
502
|
}
|
|
473
503
|
if (options.show || (!options.clearAi && options.telemetry === undefined)) {
|
|
504
|
+
const telemetry = await getTelemetry();
|
|
474
505
|
console.log(chalk.bold("\n JFL Preferences\n"));
|
|
475
506
|
console.log(chalk.gray(" AI CLI:") + " " + (getConfigValue("aiCLI") || chalk.gray("none")));
|
|
476
507
|
console.log(chalk.gray(" Projects tracked:") + " " + ((getConfigValue("projects") || []).length));
|
|
@@ -484,7 +515,8 @@ program
|
|
|
484
515
|
program
|
|
485
516
|
.command("wallet")
|
|
486
517
|
.description("Show wallet and day pass status")
|
|
487
|
-
.action(() => {
|
|
518
|
+
.action(async () => {
|
|
519
|
+
const { showDayPassStatus, hasWallet, getWalletAddress } = await import("./utils/auth-guard.js");
|
|
488
520
|
const address = getWalletAddress();
|
|
489
521
|
if (!address) {
|
|
490
522
|
console.log(chalk.yellow("\n⚠️ No wallet configured"));
|
|
@@ -508,25 +540,37 @@ program
|
|
|
508
540
|
.command("deploy")
|
|
509
541
|
.description("Deploy project to JFL platform")
|
|
510
542
|
.option("-f, --force", "Force deploy even if no changes")
|
|
511
|
-
.action(
|
|
543
|
+
.action(async (options) => {
|
|
544
|
+
const { deployCommand } = await import("./commands/deploy.js");
|
|
545
|
+
await deployCommand(options);
|
|
546
|
+
});
|
|
512
547
|
program
|
|
513
548
|
.command("agents")
|
|
514
549
|
.description("Manage parallel agents")
|
|
515
550
|
.argument("[action]", "Action: list, create, start, stop, destroy")
|
|
516
551
|
.option("-n, --name <name>", "Agent name")
|
|
517
552
|
.option("-t, --task <task>", "Task for agent")
|
|
518
|
-
.action(
|
|
553
|
+
.action(async (action, options) => {
|
|
554
|
+
const { agentsCommand } = await import("./commands/agents.js");
|
|
555
|
+
await agentsCommand(action, options);
|
|
556
|
+
});
|
|
519
557
|
program
|
|
520
558
|
.command("feedback")
|
|
521
559
|
.description("Rate your JFL session")
|
|
522
560
|
.argument("[action]", "view or sync")
|
|
523
|
-
.action(
|
|
561
|
+
.action(async (action) => {
|
|
562
|
+
const { feedbackCommand } = await import("./commands/feedback.js");
|
|
563
|
+
await feedbackCommand(action);
|
|
564
|
+
});
|
|
524
565
|
program
|
|
525
566
|
.command("update")
|
|
526
567
|
.description("Pull latest JFL product updates")
|
|
527
568
|
.option("--dry", "Show what would be updated without making changes")
|
|
528
569
|
.option("--auto", "Auto mode: check once per 24h, skip if recently updated")
|
|
529
|
-
.action((options) =>
|
|
570
|
+
.action(async (options) => {
|
|
571
|
+
const { updateCommand } = await import("./commands/update.js");
|
|
572
|
+
await updateCommand({ dry: options.dry, autoUpdate: options.auto });
|
|
573
|
+
});
|
|
530
574
|
// ============================================================================
|
|
531
575
|
// SKILL MANAGEMENT (work offline)
|
|
532
576
|
// ============================================================================
|
|
@@ -537,28 +581,43 @@ skills
|
|
|
537
581
|
.option("-a, --available", "Show all available skills")
|
|
538
582
|
.option("-c, --category <category>", "Filter by category (core or catalog)")
|
|
539
583
|
.option("-t, --tag <tag>", "Filter by tag")
|
|
540
|
-
.action(
|
|
584
|
+
.action(async (options) => {
|
|
585
|
+
const { listSkillsCommand } = await import("./commands/skills.js");
|
|
586
|
+
await listSkillsCommand(options);
|
|
587
|
+
});
|
|
541
588
|
skills
|
|
542
589
|
.command("install")
|
|
543
590
|
.description("Install skill(s)")
|
|
544
591
|
.argument("<skills...>", "Skill name(s) to install")
|
|
545
|
-
.action(
|
|
592
|
+
.action(async (skills) => {
|
|
593
|
+
const { installSkillCommand } = await import("./commands/skills.js");
|
|
594
|
+
await installSkillCommand(skills);
|
|
595
|
+
});
|
|
546
596
|
skills
|
|
547
597
|
.command("remove")
|
|
548
598
|
.description("Remove skill(s)")
|
|
549
599
|
.argument("<skills...>", "Skill name(s) to remove")
|
|
550
|
-
.action(
|
|
600
|
+
.action(async (skills) => {
|
|
601
|
+
const { removeSkillCommand } = await import("./commands/skills.js");
|
|
602
|
+
await removeSkillCommand(skills);
|
|
603
|
+
});
|
|
551
604
|
skills
|
|
552
605
|
.command("update")
|
|
553
606
|
.description("Update installed skill(s)")
|
|
554
607
|
.argument("[skill]", "Skill name to update (omit to update all)")
|
|
555
608
|
.option("--dry", "Show what would be updated without making changes")
|
|
556
|
-
.action((skill, options) =>
|
|
609
|
+
.action(async (skill, options) => {
|
|
610
|
+
const { updateSkillsCommand } = await import("./commands/skills.js");
|
|
611
|
+
await updateSkillsCommand({ ...options, skillName: skill });
|
|
612
|
+
});
|
|
557
613
|
skills
|
|
558
614
|
.command("search")
|
|
559
615
|
.description("Search for skills")
|
|
560
616
|
.argument("<query>", "Search query")
|
|
561
|
-
.action(
|
|
617
|
+
.action(async (query) => {
|
|
618
|
+
const { searchSkillsCommand } = await import("./commands/skills.js");
|
|
619
|
+
await searchSkillsCommand(query);
|
|
620
|
+
});
|
|
562
621
|
// ============================================================================
|
|
563
622
|
// VOICE INPUT (work offline)
|
|
564
623
|
// ============================================================================
|
|
@@ -570,12 +629,14 @@ voice
|
|
|
570
629
|
.argument("[name]", "Model name (tiny, base, small, etc.)")
|
|
571
630
|
.option("-f, --force", "Force re-download")
|
|
572
631
|
.action(async (action, name, options) => {
|
|
632
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
573
633
|
await voiceCommand("model", action, name, options);
|
|
574
634
|
});
|
|
575
635
|
voice
|
|
576
636
|
.command("devices")
|
|
577
637
|
.description("List audio input devices")
|
|
578
638
|
.action(async () => {
|
|
639
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
579
640
|
await voiceCommand("devices");
|
|
580
641
|
});
|
|
581
642
|
voice
|
|
@@ -583,6 +644,7 @@ voice
|
|
|
583
644
|
.description("Test voice input (record 3s and transcribe)")
|
|
584
645
|
.option("-d, --device <id>", "Device ID to use")
|
|
585
646
|
.action(async (options) => {
|
|
647
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
586
648
|
await voiceCommand("test", undefined, undefined, {
|
|
587
649
|
device: options.device,
|
|
588
650
|
});
|
|
@@ -593,6 +655,7 @@ voice
|
|
|
593
655
|
.option("-d, --device <id>", "Device ID to use")
|
|
594
656
|
.option("-t, --duration <seconds>", "Recording duration in seconds", "5")
|
|
595
657
|
.action(async (options) => {
|
|
658
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
596
659
|
await voiceCommand("recording", undefined, undefined, {
|
|
597
660
|
device: options.device,
|
|
598
661
|
duration: parseInt(options.duration, 10),
|
|
@@ -602,6 +665,7 @@ voice
|
|
|
602
665
|
.command("setup")
|
|
603
666
|
.description("First-time setup wizard for voice input")
|
|
604
667
|
.action(async () => {
|
|
668
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
605
669
|
await voiceCommand("setup");
|
|
606
670
|
});
|
|
607
671
|
voice
|
|
@@ -609,6 +673,7 @@ voice
|
|
|
609
673
|
.description("Record voice with VAD (same as running jfl voice)")
|
|
610
674
|
.option("-d, --device <id>", "Device ID to use")
|
|
611
675
|
.action(async (options) => {
|
|
676
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
612
677
|
await voiceCommand("record", undefined, undefined, {
|
|
613
678
|
device: options.device,
|
|
614
679
|
});
|
|
@@ -617,6 +682,7 @@ voice
|
|
|
617
682
|
.command("help")
|
|
618
683
|
.description("Show voice command help")
|
|
619
684
|
.action(async () => {
|
|
685
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
620
686
|
await voiceCommand("help");
|
|
621
687
|
});
|
|
622
688
|
voice
|
|
@@ -625,6 +691,7 @@ voice
|
|
|
625
691
|
.option("-d, --device <id>", "Device ID to use")
|
|
626
692
|
.option("-m, --mode <mode>", "Hotkey mode: auto, tap, or hold (default: auto)")
|
|
627
693
|
.action(async (options) => {
|
|
694
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
628
695
|
await voiceCommand("hotkey", undefined, undefined, {
|
|
629
696
|
device: options.device,
|
|
630
697
|
mode: options.mode,
|
|
@@ -639,6 +706,7 @@ daemon
|
|
|
639
706
|
.description("Start hotkey listener in background")
|
|
640
707
|
.option("-m, --mode <mode>", "Hotkey mode: auto, tap, or hold (default: auto)")
|
|
641
708
|
.action(async (options) => {
|
|
709
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
642
710
|
await voiceCommand("daemon", "start", undefined, {
|
|
643
711
|
mode: options.mode,
|
|
644
712
|
});
|
|
@@ -647,22 +715,26 @@ daemon
|
|
|
647
715
|
.command("stop")
|
|
648
716
|
.description("Stop the background daemon")
|
|
649
717
|
.action(async () => {
|
|
718
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
650
719
|
await voiceCommand("daemon", "stop");
|
|
651
720
|
});
|
|
652
721
|
daemon
|
|
653
722
|
.command("status")
|
|
654
723
|
.description("Show daemon status and uptime")
|
|
655
724
|
.action(async () => {
|
|
725
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
656
726
|
await voiceCommand("daemon", "status");
|
|
657
727
|
});
|
|
658
728
|
// Default daemon action (show status)
|
|
659
729
|
daemon.action(async () => {
|
|
730
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
660
731
|
await voiceCommand("daemon", "status");
|
|
661
732
|
});
|
|
662
733
|
// Running `jfl voice` without subcommand starts recording with VAD
|
|
663
734
|
voice
|
|
664
735
|
.option("-d, --device <id>", "Device ID to use")
|
|
665
736
|
.action(async (options) => {
|
|
737
|
+
const { voiceCommand } = await import("./commands/voice.js");
|
|
666
738
|
await voiceCommand(undefined, undefined, undefined, {
|
|
667
739
|
device: options.device,
|
|
668
740
|
});
|
|
@@ -674,23 +746,35 @@ const memory = program.command("memory").description("Memory system management")
|
|
|
674
746
|
memory
|
|
675
747
|
.command("init")
|
|
676
748
|
.description("Initialize memory database")
|
|
677
|
-
.action(
|
|
749
|
+
.action(async () => {
|
|
750
|
+
const { memoryInitCommand } = await import("./commands/memory.js");
|
|
751
|
+
await memoryInitCommand();
|
|
752
|
+
});
|
|
678
753
|
memory
|
|
679
754
|
.command("status")
|
|
680
755
|
.description("Show memory statistics")
|
|
681
|
-
.action(
|
|
756
|
+
.action(async () => {
|
|
757
|
+
const { memoryStatusCommand } = await import("./commands/memory.js");
|
|
758
|
+
await memoryStatusCommand();
|
|
759
|
+
});
|
|
682
760
|
memory
|
|
683
761
|
.command("search")
|
|
684
762
|
.description("Search memories")
|
|
685
763
|
.argument("<query>", "Search query")
|
|
686
764
|
.option("-t, --type <type>", "Filter by type (feature, fix, decision, etc.)")
|
|
687
765
|
.option("-n, --max <n>", "Maximum results", "10")
|
|
688
|
-
.action(
|
|
766
|
+
.action(async (query, options) => {
|
|
767
|
+
const { memorySearchCommand } = await import("./commands/memory.js");
|
|
768
|
+
await memorySearchCommand(query, options);
|
|
769
|
+
});
|
|
689
770
|
memory
|
|
690
771
|
.command("index")
|
|
691
772
|
.description("Reindex journal entries")
|
|
692
773
|
.option("-f, --force", "Force full reindex")
|
|
693
|
-
.action(
|
|
774
|
+
.action(async (options) => {
|
|
775
|
+
const { memoryIndexCommand } = await import("./commands/memory.js");
|
|
776
|
+
await memoryIndexCommand(options);
|
|
777
|
+
});
|
|
694
778
|
// Alias: jfl ask <question> → jfl memory search <question>
|
|
695
779
|
program
|
|
696
780
|
.command("ask")
|
|
@@ -699,6 +783,7 @@ program
|
|
|
699
783
|
.option("-t, --type <type>", "Filter by type (feature, fix, decision, etc.)")
|
|
700
784
|
.option("-n, --max <n>", "Maximum results", "5")
|
|
701
785
|
.action(async (question, options) => {
|
|
786
|
+
const { memorySearchCommand } = await import("./commands/memory.js");
|
|
702
787
|
await memorySearchCommand(question, options);
|
|
703
788
|
});
|
|
704
789
|
// ============================================================================
|
|
@@ -733,6 +818,7 @@ program
|
|
|
733
818
|
.option("-h, --help", "Show ralph-tui help")
|
|
734
819
|
.allowUnknownOption()
|
|
735
820
|
.action(async (args, options) => {
|
|
821
|
+
const { ralphCommand, showRalphHelp } = await import("./commands/ralph.js");
|
|
736
822
|
if (options.help || args.length === 0) {
|
|
737
823
|
showRalphHelp();
|
|
738
824
|
return;
|
|
@@ -750,14 +836,20 @@ program
|
|
|
750
836
|
program
|
|
751
837
|
.command("peter")
|
|
752
838
|
.description("Peter Parker - model-routed agent orchestrator")
|
|
753
|
-
.argument("[action]", "setup, run, pr, experiment, autoresearch, status, or dashboard")
|
|
839
|
+
.argument("[action]", "setup, run, pr, experiment, autoresearch, status, agent, or dashboard")
|
|
840
|
+
.argument("[name]", "Agent name (for agent subcommand)")
|
|
754
841
|
.option("--cost", "Cost-optimized model routing (haiku-heavy)")
|
|
755
842
|
.option("--balanced", "Balanced model routing (default)")
|
|
756
843
|
.option("--quality", "Quality-first model routing (opus-heavy)")
|
|
757
844
|
.option("-t, --task <task>", "Task to run (for run action)")
|
|
758
845
|
.option("-r, --rounds <n>", "Number of autoresearch rounds (default: 5)")
|
|
759
846
|
.option("--mode <mode>", "Experiment mode: default or autoresearch")
|
|
760
|
-
.
|
|
847
|
+
.option("--budget <amount>", "Cost budget in USD (Pi runtime: auto-downgrades model when exceeded)")
|
|
848
|
+
.option("--pi", "Force Pi runtime (default: auto-detect based on 'pi' command availability)")
|
|
849
|
+
.action(async (action, name, options) => {
|
|
850
|
+
const { peterCommand } = await import("./commands/peter.js");
|
|
851
|
+
if (name)
|
|
852
|
+
options.name = name;
|
|
761
853
|
await peterCommand(action, options);
|
|
762
854
|
});
|
|
763
855
|
// ============================================================================
|
|
@@ -785,13 +877,22 @@ const clawdbot = program.command("clawdbot").description("Manage JFL plugin for
|
|
|
785
877
|
clawdbot
|
|
786
878
|
.command("setup")
|
|
787
879
|
.description("Install JFL plugin into Clawdbot and configure it")
|
|
788
|
-
.action(
|
|
880
|
+
.action(async () => {
|
|
881
|
+
const { clawdbotSetupCommand } = await import("./commands/clawdbot.js");
|
|
882
|
+
await clawdbotSetupCommand();
|
|
883
|
+
});
|
|
789
884
|
clawdbot
|
|
790
885
|
.command("status")
|
|
791
886
|
.description("Show JFL Clawdbot plugin installation status")
|
|
792
|
-
.action(
|
|
887
|
+
.action(async () => {
|
|
888
|
+
const { clawdbotStatusCommand } = await import("./commands/clawdbot.js");
|
|
889
|
+
await clawdbotStatusCommand();
|
|
890
|
+
});
|
|
793
891
|
// Default action: show status
|
|
794
|
-
clawdbot.action(
|
|
892
|
+
clawdbot.action(async () => {
|
|
893
|
+
const { clawdbotStatusCommand } = await import("./commands/clawdbot.js");
|
|
894
|
+
await clawdbotStatusCommand();
|
|
895
|
+
});
|
|
795
896
|
// ============================================================================
|
|
796
897
|
// OPENCLAW (runtime-agnostic agent protocol)
|
|
797
898
|
// ============================================================================
|
|
@@ -901,6 +1002,14 @@ openclaw
|
|
|
901
1002
|
const { tagCommand } = await import("./commands/openclaw.js");
|
|
902
1003
|
await tagCommand(service, message, options);
|
|
903
1004
|
});
|
|
1005
|
+
openclaw
|
|
1006
|
+
.command("install-skill")
|
|
1007
|
+
.description("Install jfl-gtm skill into OpenClaw (~/.openclaw/skills/)")
|
|
1008
|
+
.option("--dir <path>", "Custom install directory")
|
|
1009
|
+
.action(async (options) => {
|
|
1010
|
+
const { installSkillCommand } = await import("./commands/openclaw.js");
|
|
1011
|
+
await installSkillCommand(options);
|
|
1012
|
+
});
|
|
904
1013
|
// ============================================================================
|
|
905
1014
|
// CI WORKFLOWS
|
|
906
1015
|
// ============================================================================
|
|
@@ -922,20 +1031,25 @@ registerEvalCommand(program);
|
|
|
922
1031
|
registerPredictCommand(program);
|
|
923
1032
|
registerPortfolioCommand(program);
|
|
924
1033
|
registerVizCommand(program);
|
|
1034
|
+
registerFindingsCommand(program);
|
|
1035
|
+
registerVerifyCommand(program);
|
|
925
1036
|
// ============================================================================
|
|
926
1037
|
// TELEMETRY
|
|
927
1038
|
// ============================================================================
|
|
928
1039
|
const telemetryCmd = program.command("telemetry").description("Manage anonymous usage telemetry");
|
|
929
1040
|
import { registerDigestCommand } from "./commands/digest.js";
|
|
930
1041
|
import { registerEvalCommand } from "./commands/eval.js";
|
|
1042
|
+
import { registerFindingsCommand } from "./commands/findings.js";
|
|
931
1043
|
import { registerPortfolioCommand } from "./commands/portfolio.js";
|
|
932
1044
|
import { registerPredictCommand } from "./commands/predict.js";
|
|
933
1045
|
import { registerVizCommand } from "./commands/viz.js";
|
|
1046
|
+
import { registerVerifyCommand } from "./commands/verify.js";
|
|
934
1047
|
registerDigestCommand(telemetryCmd);
|
|
935
1048
|
telemetryCmd
|
|
936
1049
|
.command("status")
|
|
937
1050
|
.description("Show telemetry status")
|
|
938
1051
|
.action(async () => {
|
|
1052
|
+
const telemetry = await getTelemetry();
|
|
939
1053
|
const enabled = telemetry.isEnabled();
|
|
940
1054
|
const installId = telemetry.getInstallId();
|
|
941
1055
|
const queueSize = telemetry.getQueueSize();
|
|
@@ -954,6 +1068,7 @@ telemetryCmd
|
|
|
954
1068
|
.command("show")
|
|
955
1069
|
.description("Show recent telemetry events from spillover queue")
|
|
956
1070
|
.action(async () => {
|
|
1071
|
+
const telemetry = await getTelemetry();
|
|
957
1072
|
const spillover = telemetry.getSpilloverEvents();
|
|
958
1073
|
if (spillover.length === 0) {
|
|
959
1074
|
console.log(chalk.gray("\n No events in spillover queue.\n"));
|
|
@@ -970,6 +1085,7 @@ telemetryCmd
|
|
|
970
1085
|
.command("reset")
|
|
971
1086
|
.description("Reset install ID (generates new anonymous ID)")
|
|
972
1087
|
.action(async () => {
|
|
1088
|
+
const telemetry = await getTelemetry();
|
|
973
1089
|
telemetry.resetInstallId();
|
|
974
1090
|
console.log(chalk.green("\n Install ID reset. New ID: ") + chalk.cyan(telemetry.getInstallId()) + "\n");
|
|
975
1091
|
});
|
|
@@ -985,6 +1101,7 @@ telemetryCmd
|
|
|
985
1101
|
.option("--error-code <code>", "Error code")
|
|
986
1102
|
.allowUnknownOption()
|
|
987
1103
|
.action(async (options) => {
|
|
1104
|
+
const telemetry = await getTelemetry();
|
|
988
1105
|
telemetry.track({
|
|
989
1106
|
category: options.category,
|
|
990
1107
|
event: options.event,
|
|
@@ -999,6 +1116,7 @@ telemetryCmd
|
|
|
999
1116
|
// Default telemetry action
|
|
1000
1117
|
telemetryCmd.action(async () => {
|
|
1001
1118
|
// Show status by default
|
|
1119
|
+
const telemetry = await getTelemetry();
|
|
1002
1120
|
const enabled = telemetry.isEnabled();
|
|
1003
1121
|
const installId = telemetry.getInstallId();
|
|
1004
1122
|
console.log(chalk.bold("\n Telemetry Status\n"));
|
|
@@ -1034,9 +1152,83 @@ program
|
|
|
1034
1152
|
.description("Check project health and auto-repair")
|
|
1035
1153
|
.option("--fix", "Auto-repair fixable issues")
|
|
1036
1154
|
.action(async (options) => {
|
|
1155
|
+
const { doctorCommand } = await import("./commands/doctor.js");
|
|
1037
1156
|
await doctorCommand({ fix: options.fix });
|
|
1038
1157
|
});
|
|
1039
1158
|
// ============================================================================
|
|
1159
|
+
// TRAIN (policy head training pipeline)
|
|
1160
|
+
// ============================================================================
|
|
1161
|
+
const train = program.command("train").description("Policy head training pipeline");
|
|
1162
|
+
train
|
|
1163
|
+
.command("policy-head")
|
|
1164
|
+
.description("Train policy head (v2 transformer by default, --v1 for legacy MLP)")
|
|
1165
|
+
.option("-f, --force", "Train even if threshold not met")
|
|
1166
|
+
.option("--v1", "Use v1 MLP trainer instead of v2 transformer")
|
|
1167
|
+
.option("--epochs <n>", "Max training epochs")
|
|
1168
|
+
.option("--lr <rate>", "Learning rate")
|
|
1169
|
+
.option("--batch-size <n>", "Batch size")
|
|
1170
|
+
.option("--min-entries <n>", "Minimum entries required")
|
|
1171
|
+
.option("-o, --output <path>", "Output path for weights (v1 only)")
|
|
1172
|
+
.option("-a, --agent <name>", "Filter training data to specific agent")
|
|
1173
|
+
.action(async (options) => {
|
|
1174
|
+
const { trainPolicyHead } = await import("./commands/train.js");
|
|
1175
|
+
await trainPolicyHead(options);
|
|
1176
|
+
});
|
|
1177
|
+
train
|
|
1178
|
+
.command("transform")
|
|
1179
|
+
.description("Transform training buffer to v2 format (current_state, goal, correct_tool)")
|
|
1180
|
+
.option("--all", "Include entries where improved=false")
|
|
1181
|
+
.action(async (options) => {
|
|
1182
|
+
const { trainTransform } = await import("./commands/train.js");
|
|
1183
|
+
await trainTransform(options);
|
|
1184
|
+
});
|
|
1185
|
+
train
|
|
1186
|
+
.command("generate")
|
|
1187
|
+
.description("Generate synthetic training data for v2 policy head")
|
|
1188
|
+
.option("--goals-per-tool <n>", "Goals to generate per tool (default: 50)")
|
|
1189
|
+
.option("--states-per-goal <n>", "States to generate per goal (default: 2)")
|
|
1190
|
+
.action(async (options) => {
|
|
1191
|
+
const { trainGenerate } = await import("./commands/train.js");
|
|
1192
|
+
await trainGenerate(options);
|
|
1193
|
+
});
|
|
1194
|
+
train
|
|
1195
|
+
.command("eval")
|
|
1196
|
+
.description("Evaluate v2 policy head — per-tool accuracy report")
|
|
1197
|
+
.option("--split <name>", "Which split to evaluate: train/val/test (default: test)")
|
|
1198
|
+
.action(async (options) => {
|
|
1199
|
+
const { trainEval } = await import("./commands/train.js");
|
|
1200
|
+
await trainEval(options);
|
|
1201
|
+
});
|
|
1202
|
+
train
|
|
1203
|
+
.command("status")
|
|
1204
|
+
.description("Show training data stats, model info, and threshold")
|
|
1205
|
+
.action(async () => {
|
|
1206
|
+
const { trainStatus } = await import("./commands/train.js");
|
|
1207
|
+
await trainStatus();
|
|
1208
|
+
});
|
|
1209
|
+
train
|
|
1210
|
+
.command("export")
|
|
1211
|
+
.description("Export training data for external tools")
|
|
1212
|
+
.option("--format <fmt>", "Export format: jsonl or csv (default: jsonl)")
|
|
1213
|
+
.action(async (options) => {
|
|
1214
|
+
const { trainExport } = await import("./commands/train.js");
|
|
1215
|
+
await trainExport(options);
|
|
1216
|
+
});
|
|
1217
|
+
train
|
|
1218
|
+
.command("check")
|
|
1219
|
+
.description("Check if training threshold is met")
|
|
1220
|
+
.option("-q, --quiet", "Quiet mode — exit code only")
|
|
1221
|
+
.action(async (options) => {
|
|
1222
|
+
const { trainThresholdCheck } = await import("./commands/train.js");
|
|
1223
|
+
const ready = await trainThresholdCheck(options);
|
|
1224
|
+
if (!ready)
|
|
1225
|
+
process.exitCode = 1;
|
|
1226
|
+
});
|
|
1227
|
+
train.action(async () => {
|
|
1228
|
+
const { trainStatus } = await import("./commands/train.js");
|
|
1229
|
+
await trainStatus();
|
|
1230
|
+
});
|
|
1231
|
+
// ============================================================================
|
|
1040
1232
|
// AGENT (narrowly-scoped agent scaffolding)
|
|
1041
1233
|
// ============================================================================
|
|
1042
1234
|
const agent = program.command("agent").description("Manage narrowly-scoped agents");
|
|
@@ -1046,12 +1238,14 @@ agent
|
|
|
1046
1238
|
.argument("<name>", "Agent name (lowercase, hyphens allowed)")
|
|
1047
1239
|
.option("-d, --description <desc>", "Agent description")
|
|
1048
1240
|
.action(async (name, options) => {
|
|
1241
|
+
const { agentCommand } = await import("./commands/agent.js");
|
|
1049
1242
|
await agentCommand("init", name, { description: options.description });
|
|
1050
1243
|
});
|
|
1051
1244
|
agent
|
|
1052
1245
|
.command("list")
|
|
1053
1246
|
.description("List registered agents")
|
|
1054
1247
|
.action(async () => {
|
|
1248
|
+
const { agentCommand } = await import("./commands/agent.js");
|
|
1055
1249
|
await agentCommand("list");
|
|
1056
1250
|
});
|
|
1057
1251
|
agent
|
|
@@ -1059,12 +1253,28 @@ agent
|
|
|
1059
1253
|
.description("Show agent health and config")
|
|
1060
1254
|
.argument("<name>", "Agent name")
|
|
1061
1255
|
.action(async (name) => {
|
|
1256
|
+
const { agentCommand } = await import("./commands/agent.js");
|
|
1062
1257
|
await agentCommand("status", name);
|
|
1063
1258
|
});
|
|
1064
1259
|
agent.action(async () => {
|
|
1260
|
+
const { agentCommand } = await import("./commands/agent.js");
|
|
1065
1261
|
await agentCommand();
|
|
1066
1262
|
});
|
|
1067
1263
|
// ============================================================================
|
|
1264
|
+
// SETUP (auto-configure RL agents from project context)
|
|
1265
|
+
// ============================================================================
|
|
1266
|
+
program
|
|
1267
|
+
.command("setup")
|
|
1268
|
+
.description("Auto-configure RL agents from project context")
|
|
1269
|
+
.option("--dry-run", "Show recommendations without writing files")
|
|
1270
|
+
.option("-f, --force", "Proceed even if readiness check fails")
|
|
1271
|
+
.option("--from-violations", "Generate agents from TLC invariant violations")
|
|
1272
|
+
.option("--smart", "Use Stratus reasoning for agent recommendations")
|
|
1273
|
+
.action(async (options) => {
|
|
1274
|
+
const { setupCommand } = await import("./commands/setup.js");
|
|
1275
|
+
await setupCommand(options);
|
|
1276
|
+
});
|
|
1277
|
+
// ============================================================================
|
|
1068
1278
|
// GTM COMMANDS
|
|
1069
1279
|
// ============================================================================
|
|
1070
1280
|
const gtm = program.command("gtm").description("GTM workspace management");
|
|
@@ -1101,6 +1311,56 @@ piAgents
|
|
|
1101
1311
|
await piAgentsRunCommand(options);
|
|
1102
1312
|
});
|
|
1103
1313
|
// ============================================================================
|
|
1314
|
+
const piFleet = piCmd.command("fleet").description("VM agent fleet — spawn, collect, destroy waves of autonomous agents");
|
|
1315
|
+
piFleet
|
|
1316
|
+
.command("setup")
|
|
1317
|
+
.description("Install VM backend, check boot arg, create base image")
|
|
1318
|
+
.option("--backend <name>", "VM backend: lume (default)", "lume")
|
|
1319
|
+
.option("--cpus <n>", "CPUs per VM", "4")
|
|
1320
|
+
.option("--memory <mb>", "Memory per VM in MB", "4096")
|
|
1321
|
+
.option("--skip-boot-arg", "Skip VM quota boot arg check")
|
|
1322
|
+
.action(async (options) => {
|
|
1323
|
+
const { fleetSetup } = await import("./commands/pi-fleet.js");
|
|
1324
|
+
await fleetSetup({ ...options, cpus: parseInt(options.cpus), memory: parseInt(options.memory) });
|
|
1325
|
+
});
|
|
1326
|
+
piFleet
|
|
1327
|
+
.command("spawn <count>")
|
|
1328
|
+
.description("Spawn N agent VMs for parallel autoresearch")
|
|
1329
|
+
.option("--rounds <n>", "Autoresearch rounds per agent", "5")
|
|
1330
|
+
.option("--repo <url>", "Target repo (defaults to git remote origin)")
|
|
1331
|
+
.action(async (count, options) => {
|
|
1332
|
+
const { fleetSpawn } = await import("./commands/pi-fleet.js");
|
|
1333
|
+
await fleetSpawn(parseInt(count), { ...options, rounds: parseInt(options.rounds) });
|
|
1334
|
+
});
|
|
1335
|
+
piFleet
|
|
1336
|
+
.command("status")
|
|
1337
|
+
.description("Show running agents, tuple counts, health")
|
|
1338
|
+
.action(async () => {
|
|
1339
|
+
const { fleetStatus } = await import("./commands/pi-fleet.js");
|
|
1340
|
+
await fleetStatus();
|
|
1341
|
+
});
|
|
1342
|
+
piFleet
|
|
1343
|
+
.command("collect [waveId]")
|
|
1344
|
+
.description("Pull tuples from agents, dedup, append to training buffer")
|
|
1345
|
+
.action(async (waveId) => {
|
|
1346
|
+
const { fleetCollect } = await import("./commands/pi-fleet.js");
|
|
1347
|
+
await fleetCollect(waveId);
|
|
1348
|
+
});
|
|
1349
|
+
piFleet
|
|
1350
|
+
.command("destroy [waveId]")
|
|
1351
|
+
.description("Tear down a wave of agent VMs")
|
|
1352
|
+
.action(async (waveId) => {
|
|
1353
|
+
const { fleetDestroy } = await import("./commands/pi-fleet.js");
|
|
1354
|
+
await fleetDestroy(waveId);
|
|
1355
|
+
});
|
|
1356
|
+
piFleet
|
|
1357
|
+
.command("logs <agent>")
|
|
1358
|
+
.description("Tail an agent's autoresearch log")
|
|
1359
|
+
.action(async (agent) => {
|
|
1360
|
+
const { fleetLogs } = await import("./commands/pi-fleet.js");
|
|
1361
|
+
await fleetLogs(agent);
|
|
1362
|
+
});
|
|
1363
|
+
// ============================================================================
|
|
1104
1364
|
// Parse and run
|
|
1105
1365
|
program.parse();
|
|
1106
1366
|
//# sourceMappingURL=index.js.map
|