@liangjie559567/ultrapower 6.0.0 → 7.0.2
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/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +1 -1
- package/LICENSE +21 -21
- package/README.md +2 -2
- package/agents/executor.md +10 -5
- package/bridge/codex-server.cjs +1 -1
- package/bridge/gemini-server.cjs +1 -1
- package/bridge/gyoshu_bridge.py +846 -846
- package/dist/agents/status.d.ts +28 -0
- package/dist/agents/status.d.ts.map +1 -0
- package/dist/agents/status.js +44 -0
- package/dist/agents/status.js.map +1 -0
- package/dist/cache/result-cache.d.ts +20 -0
- package/dist/cache/result-cache.d.ts.map +1 -0
- package/dist/cache/result-cache.js +64 -0
- package/dist/cache/result-cache.js.map +1 -0
- package/dist/cache/security.d.ts +21 -0
- package/dist/cache/security.d.ts.map +1 -0
- package/dist/cache/security.js +39 -0
- package/dist/cache/security.js.map +1 -0
- package/dist/cli/autocomplete.d.ts +25 -0
- package/dist/cli/autocomplete.d.ts.map +1 -0
- package/dist/cli/autocomplete.js +99 -0
- package/dist/cli/autocomplete.js.map +1 -0
- package/dist/cli/commands/agents.d.ts +2 -0
- package/dist/cli/commands/agents.d.ts.map +1 -1
- package/dist/cli/commands/agents.js +8 -0
- package/dist/cli/commands/agents.js.map +1 -1
- package/dist/cli/commands/backfill.d.ts +2 -0
- package/dist/cli/commands/backfill.d.ts.map +1 -1
- package/dist/cli/commands/backfill.js +13 -0
- package/dist/cli/commands/backfill.js.map +1 -1
- package/dist/cli/commands/cleanup.d.ts +2 -0
- package/dist/cli/commands/cleanup.d.ts.map +1 -1
- package/dist/cli/commands/cleanup.js +7 -0
- package/dist/cli/commands/cleanup.js.map +1 -1
- package/dist/cli/commands/config-notify-profile.d.ts +3 -0
- package/dist/cli/commands/config-notify-profile.d.ts.map +1 -0
- package/dist/cli/commands/config-notify-profile.js +58 -0
- package/dist/cli/commands/config-notify-profile.js.map +1 -0
- package/dist/cli/commands/config-stop-callback.d.ts +3 -0
- package/dist/cli/commands/config-stop-callback.d.ts.map +1 -0
- package/dist/cli/commands/config-stop-callback.js +97 -0
- package/dist/cli/commands/config-stop-callback.js.map +1 -0
- package/dist/cli/commands/config.d.ts +3 -0
- package/dist/cli/commands/config.d.ts.map +1 -0
- package/dist/cli/commands/config.js +10 -0
- package/dist/cli/commands/config.js.map +1 -0
- package/dist/cli/commands/cost.d.ts +2 -0
- package/dist/cli/commands/cost.d.ts.map +1 -1
- package/dist/cli/commands/cost.js +8 -0
- package/dist/cli/commands/cost.js.map +1 -1
- package/dist/cli/commands/dashboard.d.ts +3 -0
- package/dist/cli/commands/dashboard.d.ts.map +1 -0
- package/dist/cli/commands/dashboard.js +13 -0
- package/dist/cli/commands/dashboard.js.map +1 -0
- package/dist/cli/commands/doctor.d.ts +3 -0
- package/dist/cli/commands/doctor.d.ts.map +1 -0
- package/dist/cli/commands/doctor.js +11 -0
- package/dist/cli/commands/doctor.js.map +1 -0
- package/dist/cli/commands/export.d.ts +2 -0
- package/dist/cli/commands/export.d.ts.map +1 -1
- package/dist/cli/commands/export.js +10 -0
- package/dist/cli/commands/export.js.map +1 -1
- package/dist/cli/commands/info.d.ts +3 -0
- package/dist/cli/commands/info.d.ts.map +1 -0
- package/dist/cli/commands/info.js +10 -0
- package/dist/cli/commands/info.js.map +1 -0
- package/dist/cli/commands/init.d.ts +3 -0
- package/dist/cli/commands/init.d.ts.map +1 -0
- package/dist/cli/commands/init.js +10 -0
- package/dist/cli/commands/init.js.map +1 -0
- package/dist/cli/commands/interop.d.ts +3 -0
- package/dist/cli/commands/interop.d.ts.map +1 -0
- package/dist/cli/commands/interop.js +10 -0
- package/dist/cli/commands/interop.js.map +1 -0
- package/dist/cli/commands/launch.d.ts +3 -0
- package/dist/cli/commands/launch.d.ts.map +1 -0
- package/dist/cli/commands/launch.js +20 -0
- package/dist/cli/commands/launch.js.map +1 -0
- package/dist/cli/commands/perf-wrapper.d.ts +2 -0
- package/dist/cli/commands/perf-wrapper.d.ts.map +1 -0
- package/dist/cli/commands/perf-wrapper.js +4 -0
- package/dist/cli/commands/perf-wrapper.js.map +1 -0
- package/dist/cli/commands/registry.d.ts +9 -0
- package/dist/cli/commands/registry.d.ts.map +1 -0
- package/dist/cli/commands/registry.js +29 -0
- package/dist/cli/commands/registry.js.map +1 -0
- package/dist/cli/commands/sessions.d.ts +2 -0
- package/dist/cli/commands/sessions.d.ts.map +1 -1
- package/dist/cli/commands/sessions.js +8 -0
- package/dist/cli/commands/sessions.js.map +1 -1
- package/dist/cli/commands/setup.d.ts +3 -0
- package/dist/cli/commands/setup.d.ts.map +1 -0
- package/dist/cli/commands/setup.js +10 -0
- package/dist/cli/commands/setup.js.map +1 -0
- package/dist/cli/commands/stats.d.ts +2 -0
- package/dist/cli/commands/stats.d.ts.map +1 -1
- package/dist/cli/commands/stats.js +8 -0
- package/dist/cli/commands/stats.js.map +1 -1
- package/dist/cli/commands/teleport-wrapper.d.ts +3 -0
- package/dist/cli/commands/teleport-wrapper.d.ts.map +1 -0
- package/dist/cli/commands/teleport-wrapper.js +12 -0
- package/dist/cli/commands/teleport-wrapper.js.map +1 -0
- package/dist/cli/commands/test-prompt.d.ts +3 -0
- package/dist/cli/commands/test-prompt.d.ts.map +1 -0
- package/dist/cli/commands/test-prompt.js +11 -0
- package/dist/cli/commands/test-prompt.js.map +1 -0
- package/dist/cli/commands/tui.d.ts +3 -0
- package/dist/cli/commands/tui.d.ts.map +1 -0
- package/dist/cli/commands/tui.js +10 -0
- package/dist/cli/commands/tui.js.map +1 -0
- package/dist/cli/commands/tutorial.d.ts +8 -0
- package/dist/cli/commands/tutorial.d.ts.map +1 -0
- package/dist/cli/commands/tutorial.js +31 -0
- package/dist/cli/commands/tutorial.js.map +1 -0
- package/dist/cli/commands/update.d.ts +3 -0
- package/dist/cli/commands/update.d.ts.map +1 -0
- package/dist/cli/commands/update.js +10 -0
- package/dist/cli/commands/update.js.map +1 -0
- package/dist/cli/commands/version.d.ts +3 -0
- package/dist/cli/commands/version.d.ts.map +1 -0
- package/dist/cli/commands/version.js +10 -0
- package/dist/cli/commands/version.js.map +1 -0
- package/dist/cli/commands/wait-wrapper.d.ts +3 -0
- package/dist/cli/commands/wait-wrapper.d.ts.map +1 -0
- package/dist/cli/commands/wait-wrapper.js +12 -0
- package/dist/cli/commands/wait-wrapper.js.map +1 -0
- package/dist/cli/error-handler.d.ts +7 -0
- package/dist/cli/error-handler.d.ts.map +1 -0
- package/dist/cli/error-handler.js +30 -0
- package/dist/cli/error-handler.js.map +1 -0
- package/dist/cli/index.d.ts +1 -7
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +44 -1474
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/loader.d.ts +24 -0
- package/dist/cli/loader.d.ts.map +1 -0
- package/dist/cli/loader.js +27 -0
- package/dist/cli/loader.js.map +1 -0
- package/dist/cli/progress/agent-status.d.ts +22 -0
- package/dist/cli/progress/agent-status.d.ts.map +1 -0
- package/dist/cli/progress/agent-status.js +44 -0
- package/dist/cli/progress/agent-status.js.map +1 -0
- package/dist/cli/progress/examples.d.ts +7 -0
- package/dist/cli/progress/examples.d.ts.map +1 -0
- package/dist/cli/progress/examples.js +50 -0
- package/dist/cli/progress/examples.js.map +1 -0
- package/dist/cli/progress/index.d.ts +7 -0
- package/dist/cli/progress/index.d.ts.map +1 -0
- package/dist/cli/progress/index.js +7 -0
- package/dist/cli/progress/index.js.map +1 -0
- package/dist/cli/progress/progress-bar.d.ts +17 -0
- package/dist/cli/progress/progress-bar.d.ts.map +1 -0
- package/dist/cli/progress/progress-bar.js +28 -0
- package/dist/cli/progress/progress-bar.js.map +1 -0
- package/dist/cli/progress/spinner.d.ts +14 -0
- package/dist/cli/progress/spinner.d.ts.map +1 -0
- package/dist/cli/progress/spinner.js +34 -0
- package/dist/cli/progress/spinner.js.map +1 -0
- package/dist/cli/tutorial/index.d.ts +15 -0
- package/dist/cli/tutorial/index.d.ts.map +1 -0
- package/dist/cli/tutorial/index.js +89 -0
- package/dist/cli/tutorial/index.js.map +1 -0
- package/dist/cli/utils/config.d.ts +2 -0
- package/dist/cli/utils/config.d.ts.map +1 -0
- package/dist/cli/utils/config.js +4 -0
- package/dist/cli/utils/config.js.map +1 -0
- package/dist/cli/utils/dashboard.d.ts +2 -0
- package/dist/cli/utils/dashboard.d.ts.map +1 -0
- package/dist/cli/utils/dashboard.js +74 -0
- package/dist/cli/utils/dashboard.js.map +1 -0
- package/dist/cli/utils/info.d.ts +2 -0
- package/dist/cli/utils/info.d.ts.map +1 -0
- package/dist/cli/utils/info.js +4 -0
- package/dist/cli/utils/info.js.map +1 -0
- package/dist/cli/utils/init.d.ts +2 -0
- package/dist/cli/utils/init.d.ts.map +1 -0
- package/dist/cli/utils/init.js +4 -0
- package/dist/cli/utils/init.js.map +1 -0
- package/dist/cli/utils/interop.d.ts +2 -0
- package/dist/cli/utils/interop.d.ts.map +1 -0
- package/dist/cli/utils/interop.js +4 -0
- package/dist/cli/utils/interop.js.map +1 -0
- package/dist/cli/utils/setup.d.ts +2 -0
- package/dist/cli/utils/setup.d.ts.map +1 -0
- package/dist/cli/utils/setup.js +4 -0
- package/dist/cli/utils/setup.js.map +1 -0
- package/dist/cli/utils/test-prompt.d.ts +2 -0
- package/dist/cli/utils/test-prompt.d.ts.map +1 -0
- package/dist/cli/utils/test-prompt.js +4 -0
- package/dist/cli/utils/test-prompt.js.map +1 -0
- package/dist/cli/utils/update.d.ts +2 -0
- package/dist/cli/utils/update.d.ts.map +1 -0
- package/dist/cli/utils/update.js +4 -0
- package/dist/cli/utils/update.js.map +1 -0
- package/dist/cli/utils/version-info.d.ts +2 -0
- package/dist/cli/utils/version-info.d.ts.map +1 -0
- package/dist/cli/utils/version-info.js +4 -0
- package/dist/cli/utils/version-info.js.map +1 -0
- package/dist/errors/classifier.d.ts +10 -0
- package/dist/errors/classifier.d.ts.map +1 -0
- package/dist/errors/classifier.js +119 -0
- package/dist/errors/classifier.js.map +1 -0
- package/dist/errors/index.d.ts +7 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/index.js +7 -0
- package/dist/errors/index.js.map +1 -0
- package/dist/errors/spelling.d.ts +5 -0
- package/dist/errors/spelling.d.ts.map +1 -0
- package/dist/errors/spelling.js +36 -0
- package/dist/errors/spelling.js.map +1 -0
- package/dist/errors/types.d.ts +25 -0
- package/dist/errors/types.d.ts.map +1 -0
- package/dist/errors/types.js +13 -0
- package/dist/errors/types.js.map +1 -0
- package/dist/features/ccg/incremental-processor.d.ts +3 -3
- package/dist/features/ccg/incremental-processor.d.ts.map +1 -1
- package/dist/features/ccg/incremental-processor.js +7 -7
- package/dist/features/ccg/incremental-processor.js.map +1 -1
- package/dist/features/state-manager/index.d.ts +5 -0
- package/dist/features/state-manager/index.d.ts.map +1 -1
- package/dist/features/state-manager/index.js +7 -0
- package/dist/features/state-manager/index.js.map +1 -1
- package/dist/hooks/bridge-converter.d.ts +10 -0
- package/dist/hooks/bridge-converter.d.ts.map +1 -0
- package/dist/hooks/bridge-converter.js +43 -0
- package/dist/hooks/bridge-converter.js.map +1 -0
- package/dist/hooks/bridge.d.ts +2 -31
- package/dist/hooks/bridge.d.ts.map +1 -1
- package/dist/hooks/bridge.js +24 -1066
- package/dist/hooks/bridge.js.map +1 -1
- package/dist/hooks/cache.d.ts +2 -0
- package/dist/hooks/cache.d.ts.map +1 -0
- package/dist/hooks/cache.js +78 -0
- package/dist/hooks/cache.js.map +1 -0
- package/dist/hooks/handlers/autopilot.d.ts +3 -0
- package/dist/hooks/handlers/autopilot.d.ts.map +1 -0
- package/dist/hooks/handlers/autopilot.js +23 -0
- package/dist/hooks/handlers/autopilot.js.map +1 -0
- package/dist/hooks/handlers/index.d.ts +5 -0
- package/dist/hooks/handlers/index.d.ts.map +1 -0
- package/dist/hooks/handlers/index.js +18 -0
- package/dist/hooks/handlers/index.js.map +1 -0
- package/dist/hooks/handlers/keyword-detector.d.ts +3 -0
- package/dist/hooks/handlers/keyword-detector.d.ts.map +1 -0
- package/dist/hooks/handlers/keyword-detector.js +66 -0
- package/dist/hooks/handlers/keyword-detector.js.map +1 -0
- package/dist/hooks/handlers/persistent-mode.d.ts +3 -0
- package/dist/hooks/handlers/persistent-mode.d.ts.map +1 -0
- package/dist/hooks/handlers/persistent-mode.js +82 -0
- package/dist/hooks/handlers/persistent-mode.js.map +1 -0
- package/dist/hooks/handlers/post-tool-use.d.ts +3 -0
- package/dist/hooks/handlers/post-tool-use.d.ts.map +1 -0
- package/dist/hooks/handlers/post-tool-use.js +74 -0
- package/dist/hooks/handlers/post-tool-use.js.map +1 -0
- package/dist/hooks/handlers/pre-tool-use.d.ts +7 -0
- package/dist/hooks/handlers/pre-tool-use.d.ts.map +1 -0
- package/dist/hooks/handlers/pre-tool-use.js +120 -0
- package/dist/hooks/handlers/pre-tool-use.js.map +1 -0
- package/dist/hooks/handlers/ralph.d.ts +3 -0
- package/dist/hooks/handlers/ralph.d.ts.map +1 -0
- package/dist/hooks/handlers/ralph.js +53 -0
- package/dist/hooks/handlers/ralph.js.map +1 -0
- package/dist/hooks/handlers/route-map.d.ts +8 -0
- package/dist/hooks/handlers/route-map.d.ts.map +1 -0
- package/dist/hooks/handlers/route-map.js +64 -0
- package/dist/hooks/handlers/route-map.js.map +1 -0
- package/dist/hooks/handlers/session-start.d.ts +3 -0
- package/dist/hooks/handlers/session-start.d.ts.map +1 -0
- package/dist/hooks/handlers/session-start.js +186 -0
- package/dist/hooks/handlers/session-start.js.map +1 -0
- package/dist/hooks/handlers/stop-continuation.d.ts +3 -0
- package/dist/hooks/handlers/stop-continuation.d.ts.map +1 -0
- package/dist/hooks/handlers/stop-continuation.js +50 -0
- package/dist/hooks/handlers/stop-continuation.js.map +1 -0
- package/dist/hooks/team-state-reader.d.ts +24 -0
- package/dist/hooks/team-state-reader.d.ts.map +1 -0
- package/dist/hooks/team-state-reader.js +88 -0
- package/dist/hooks/team-state-reader.js.map +1 -0
- package/dist/hooks/validation.d.ts +5 -0
- package/dist/hooks/validation.d.ts.map +1 -0
- package/dist/hooks/validation.js +48 -0
- package/dist/hooks/validation.js.map +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/lib/unified-logger.d.ts +15 -0
- package/dist/lib/unified-logger.d.ts.map +1 -0
- package/dist/lib/unified-logger.js +23 -0
- package/dist/lib/unified-logger.js.map +1 -0
- package/dist/mcp/adapters/memory-adapter.d.ts +2 -2
- package/dist/mcp/adapters/state-adapter.d.ts +5 -5
- package/dist/mcp/adapters/trace-adapter.d.ts +3 -3
- package/dist/mcp/codex-server.d.ts.map +1 -1
- package/dist/mcp/codex-server.js +22 -27
- package/dist/mcp/codex-server.js.map +1 -1
- package/dist/mcp/config/schema.d.ts +6 -6
- package/dist/mcp/config-schema.d.ts +6 -6
- package/dist/mcp/gemini-server.d.ts.map +1 -1
- package/dist/mcp/gemini-server.js +21 -26
- package/dist/mcp/gemini-server.js.map +1 -1
- package/dist/mcp/logger.d.ts.map +1 -1
- package/dist/mcp/logger.js +3 -1
- package/dist/mcp/logger.js.map +1 -1
- package/dist/mcp/tool-types.d.ts +50 -0
- package/dist/mcp/tool-types.d.ts.map +1 -0
- package/dist/mcp/tool-types.js +6 -0
- package/dist/mcp/tool-types.js.map +1 -0
- package/dist/observability/masker.d.ts +3 -0
- package/dist/observability/masker.d.ts.map +1 -0
- package/dist/observability/masker.js +23 -0
- package/dist/observability/masker.js.map +1 -0
- package/dist/observability/monitor.d.ts +17 -0
- package/dist/observability/monitor.d.ts.map +1 -0
- package/dist/observability/monitor.js +30 -0
- package/dist/observability/monitor.js.map +1 -0
- package/dist/observability/tracer.d.ts +6 -0
- package/dist/observability/tracer.d.ts.map +1 -0
- package/dist/observability/tracer.js +36 -0
- package/dist/observability/tracer.js.map +1 -0
- package/dist/reliability/circuit-breaker.d.ts +24 -0
- package/dist/reliability/circuit-breaker.d.ts.map +1 -0
- package/dist/reliability/circuit-breaker.js +59 -0
- package/dist/reliability/circuit-breaker.js.map +1 -0
- package/dist/reliability/model-fallback.d.ts +21 -0
- package/dist/reliability/model-fallback.d.ts.map +1 -0
- package/dist/reliability/model-fallback.js +47 -0
- package/dist/reliability/model-fallback.js.map +1 -0
- package/dist/reliability/retry-classifier.d.ts +17 -0
- package/dist/reliability/retry-classifier.d.ts.map +1 -0
- package/dist/reliability/retry-classifier.js +59 -0
- package/dist/reliability/retry-classifier.js.map +1 -0
- package/dist/reliability/retry-manager.d.ts +20 -0
- package/dist/reliability/retry-manager.d.ts.map +1 -0
- package/dist/reliability/retry-manager.js +45 -0
- package/dist/reliability/retry-manager.js.map +1 -0
- package/dist/security/audit-logger.d.ts +21 -0
- package/dist/security/audit-logger.d.ts.map +1 -0
- package/dist/security/audit-logger.js +58 -0
- package/dist/security/audit-logger.js.map +1 -0
- package/dist/security/budget-controller.d.ts +23 -0
- package/dist/security/budget-controller.d.ts.map +1 -0
- package/dist/security/budget-controller.js +31 -0
- package/dist/security/budget-controller.js.map +1 -0
- package/dist/security/concurrency-control.d.ts +42 -0
- package/dist/security/concurrency-control.d.ts.map +1 -0
- package/dist/security/concurrency-control.js +87 -0
- package/dist/security/concurrency-control.js.map +1 -0
- package/dist/security/resource-guard.d.ts +25 -0
- package/dist/security/resource-guard.d.ts.map +1 -0
- package/dist/security/resource-guard.js +57 -0
- package/dist/security/resource-guard.js.map +1 -0
- package/dist/security/tenant-isolator.d.ts +27 -0
- package/dist/security/tenant-isolator.d.ts.map +1 -0
- package/dist/security/tenant-isolator.js +52 -0
- package/dist/security/tenant-isolator.js.map +1 -0
- package/dist/state/backup-manager.d.ts +56 -0
- package/dist/state/backup-manager.d.ts.map +1 -0
- package/dist/state/backup-manager.js +174 -0
- package/dist/state/backup-manager.js.map +1 -0
- package/dist/state/index.d.ts +26 -0
- package/dist/state/index.d.ts.map +1 -0
- package/dist/state/index.js +40 -0
- package/dist/state/index.js.map +1 -0
- package/dist/state/migration/index.d.ts +25 -0
- package/dist/state/migration/index.d.ts.map +1 -0
- package/dist/state/migration/index.js +61 -0
- package/dist/state/migration/index.js.map +1 -0
- package/dist/state/migration/integrity.d.ts +30 -0
- package/dist/state/migration/integrity.d.ts.map +1 -0
- package/dist/state/migration/integrity.js +109 -0
- package/dist/state/migration/integrity.js.map +1 -0
- package/dist/tools/python-repl/index.d.ts +2 -2
- package/dist/tools/python-repl/tool.d.ts +2 -2
- package/docs/CLAUDE.md +1 -1
- package/docs/INSTALL.md +2 -2
- package/docs/REFERENCE.md +1 -1
- package/docs/api/assets/highlight.css +85 -85
- package/docs/api/assets/style.css +1633 -1633
- package/docs/api/classes/ContextCollector.html +21 -21
- package/docs/api/functions/activateUltrawork.html +2 -2
- package/docs/api/functions/addCustomNote.html +5 -5
- package/docs/api/functions/addDirective.html +2 -2
- package/docs/api/functions/addManualEntry.html +2 -2
- package/docs/api/functions/addPattern.html +3 -3
- package/docs/api/functions/addWorker.html +2 -2
- package/docs/api/functions/addWorkingMemoryEntry.html +2 -2
- package/docs/api/functions/analyzeContextUsage.html +2 -2
- package/docs/api/functions/appendProgress.html +2 -2
- package/docs/api/functions/appendSessionId.html +2 -2
- package/docs/api/functions/applyCommentFilters.html +3 -3
- package/docs/api/functions/assignFileToWorker.html +2 -2
- package/docs/api/functions/backgroundUpdateCheck.html +2 -2
- package/docs/api/functions/buildAxiomBootContext.html +1 -1
- package/docs/api/functions/buildBoulderContinuation.html +2 -2
- package/docs/api/functions/buildDelegationTable.html +2 -2
- package/docs/api/functions/buildKeyTriggersSection.html +2 -2
- package/docs/api/functions/buildOrchestratorReminder.html +2 -2
- package/docs/api/functions/buildUseAvoidSection.html +2 -2
- package/docs/api/functions/buildVerificationReminder.html +2 -2
- package/docs/api/functions/canResumeAutopilot.html +10 -10
- package/docs/api/functions/canStartMode.html +5 -5
- package/docs/api/functions/cancelAutopilot.html +3 -3
- package/docs/api/functions/cancelUltraQA.html +2 -2
- package/docs/api/functions/checkBackgroundNotifications.html +2 -2
- package/docs/api/functions/checkBoulderContinuation.html +2 -2
- package/docs/api/functions/checkDuplicateTriggers.html +2 -2
- package/docs/api/functions/checkExpertGate.html +1 -1
- package/docs/api/functions/checkForComments.html +2 -2
- package/docs/api/functions/checkForUpdates.html +2 -2
- package/docs/api/functions/checkIncompleteTodos.html +13 -13
- package/docs/api/functions/checkPersistentModes.html +3 -3
- package/docs/api/functions/cleanupOrphanedState.html +2 -2
- package/docs/api/functions/cleanupStaleAgents.html +2 -2
- package/docs/api/functions/cleanupTransientState.html +2 -2
- package/docs/api/functions/clearAgentUsageState.html +1 -1
- package/docs/api/functions/clearAllModeStates.html +2 -2
- package/docs/api/functions/clearAutopilot.html +2 -2
- package/docs/api/functions/clearAutopilotState.html +2 -2
- package/docs/api/functions/clearBeadsContext.html +2 -2
- package/docs/api/functions/clearBoulderState.html +2 -2
- package/docs/api/functions/clearDetectionState.html +2 -2
- package/docs/api/functions/clearInjectedPaths.html +2 -2
- package/docs/api/functions/clearInjectedRules.html +2 -2
- package/docs/api/functions/clearLinkedUltraworkState.html +2 -2
- package/docs/api/functions/clearModeState.html +10 -10
- package/docs/api/functions/clearProjectMemorySession.html +4 -4
- package/docs/api/functions/clearRalphState.html +2 -2
- package/docs/api/functions/clearRapidFireDebounce.html +2 -2
- package/docs/api/functions/clearSkillSession.html +2 -2
- package/docs/api/functions/clearThinkModeState.html +2 -2
- package/docs/api/functions/clearTrackingState.html +2 -2
- package/docs/api/functions/clearUltraQAState.html +2 -2
- package/docs/api/functions/clearVerificationState.html +3 -3
- package/docs/api/functions/commandExists.html +2 -2
- package/docs/api/functions/compareVersions.html +3 -3
- package/docs/api/functions/completeUltraQA.html +2 -2
- package/docs/api/functions/completeUltrapilot.html +2 -2
- package/docs/api/functions/completeWorker.html +2 -2
- package/docs/api/functions/containsTokenLimitError.html +2 -2
- package/docs/api/functions/createAgentToolRestrictions.html +3 -3
- package/docs/api/functions/createAgentUsageReminderHook.html +1 -1
- package/docs/api/functions/createAutoSlashCommandHook.html +7 -7
- package/docs/api/functions/createBackgroundNotificationHook.html +7 -7
- package/docs/api/functions/createBackgroundTaskManager.html +2 -2
- package/docs/api/functions/createBoulderState.html +2 -2
- package/docs/api/functions/createCommentCheckerHook.html +6 -6
- package/docs/api/functions/createCompactCheckpoint.html +2 -2
- package/docs/api/functions/createContentHash.html +2 -2
- package/docs/api/functions/createContextInjectorHook.html +7 -7
- package/docs/api/functions/createDirectoryReadmeInjectorHook.html +9 -9
- package/docs/api/functions/createEmptyMessageSanitizerHook.html +6 -6
- package/docs/api/functions/createEnvContext.html +2 -2
- package/docs/api/functions/createHookOutput.html +4 -4
- package/docs/api/functions/createLearnedSkillsHook.html +6 -6
- package/docs/api/functions/createMagicKeywordProcessor.html +2 -2
- package/docs/api/functions/createModeMarker.html +6 -6
- package/docs/api/functions/createPrd.html +2 -2
- package/docs/api/functions/createPreemptiveCompactionHook.html +6 -6
- package/docs/api/functions/createRalphLoopHook.html +2 -2
- package/docs/api/functions/createRecoveryHook.html +7 -7
- package/docs/api/functions/createRulesInjectorHook.html +8 -8
- package/docs/api/functions/createSimplePrd.html +2 -2
- package/docs/api/functions/createSisyphusOrchestratorHook.html +7 -7
- package/docs/api/functions/createSisyphusSession.html +7 -7
- package/docs/api/functions/createThinkModeHook.html +7 -7
- package/docs/api/functions/createThinkingBlockValidatorHook.html +1 -1
- package/docs/api/functions/createTodoContinuationHook.html +2 -2
- package/docs/api/functions/createUltraworkStateHook.html +2 -2
- package/docs/api/functions/deactivateUltrawork.html +8 -8
- package/docs/api/functions/decayHotPaths.html +2 -2
- package/docs/api/functions/decomposeTask.html +11 -11
- package/docs/api/functions/deepMerge.html +2 -2
- package/docs/api/functions/detectArchitectApproval.html +2 -2
- package/docs/api/functions/detectArchitectRejection.html +2 -2
- package/docs/api/functions/detectContextLimitError.html +2 -2
- package/docs/api/functions/detectContextLimitErrorInText.html +2 -2
- package/docs/api/functions/detectDirectivesFromMessage.html +2 -2
- package/docs/api/functions/detectEditError.html +2 -2
- package/docs/api/functions/detectEditErrorInOutput.html +2 -2
- package/docs/api/functions/detectEditErrorInText.html +2 -2
- package/docs/api/functions/detectExtractableMoment.html +2 -2
- package/docs/api/functions/detectKeywordsWithType.html +11 -11
- package/docs/api/functions/detectMagicKeywords.html +2 -2
- package/docs/api/functions/detectProjectEnvironment.html +2 -2
- package/docs/api/functions/detectRecoverableError.html +3 -3
- package/docs/api/functions/detectSessionErrorType.html +2 -2
- package/docs/api/functions/detectSlashCommand.html +3 -3
- package/docs/api/functions/detectThinkKeyword.html +2 -2
- package/docs/api/functions/detectUltrathinkKeyword.html +2 -2
- package/docs/api/functions/discoverAllCommands.html +2 -2
- package/docs/api/functions/enablePrdMode.html +2 -2
- package/docs/api/functions/enhancePrompt.html +2 -2
- package/docs/api/functions/ensureAutopilotDir.html +2 -2
- package/docs/api/functions/ensureDirectoryStructure.html +2 -2
- package/docs/api/functions/ensureModeStateDir.html +2 -2
- package/docs/api/functions/ensureSkillsDir.html +2 -2
- package/docs/api/functions/estimateTokens.html +2 -2
- package/docs/api/functions/executeSlashCommand.html +2 -2
- package/docs/api/functions/expandCommand.html +8 -8
- package/docs/api/functions/expandCommandPrompt.html +6 -6
- package/docs/api/functions/expandCommands.html +2 -2
- package/docs/api/functions/exportSessionSummary.html +2 -2
- package/docs/api/functions/exportWisdomToNotepad.html +2 -2
- package/docs/api/functions/extractPromptText.html +11 -11
- package/docs/api/functions/extractSlashPromptText.html +2 -2
- package/docs/api/functions/extractThinkPromptText.html +2 -2
- package/docs/api/functions/failWorker.html +2 -2
- package/docs/api/functions/findCommand.html +2 -2
- package/docs/api/functions/findMatchingSkills.html +2 -2
- package/docs/api/functions/findPlannerPlans.html +3 -3
- package/docs/api/functions/findPrdPath.html +2 -2
- package/docs/api/functions/findPreviousThinkingContent.html +1 -1
- package/docs/api/functions/findProgressPath.html +2 -2
- package/docs/api/functions/findProjectRoot.html +3 -3
- package/docs/api/functions/findRecoveryEmptyMessages.html +2 -2
- package/docs/api/functions/findRecoveryOrphanThinking.html +2 -2
- package/docs/api/functions/findRecoveryThinkingBlocks.html +2 -2
- package/docs/api/functions/findRuleFiles.html +4 -4
- package/docs/api/functions/findSkillFiles.html +3 -3
- package/docs/api/functions/formatCancelMessage.html +2 -2
- package/docs/api/functions/formatCompactSummary.html +2 -2
- package/docs/api/functions/formatContextSummary.html +3 -3
- package/docs/api/functions/formatDirectivesForContext.html +2 -2
- package/docs/api/functions/formatFailureSummary.html +2 -2
- package/docs/api/functions/formatFile.html +2 -2
- package/docs/api/functions/formatFileChanges.html +2 -2
- package/docs/api/functions/formatFileList.html +2 -2
- package/docs/api/functions/formatFullContext.html +2 -2
- package/docs/api/functions/formatFullNotepad.html +2 -2
- package/docs/api/functions/formatLearningsForContext.html +2 -2
- package/docs/api/functions/formatNextStoryPrompt.html +2 -2
- package/docs/api/functions/formatNotepadContext.html +2 -2
- package/docs/api/functions/formatPatternsForContext.html +2 -2
- package/docs/api/functions/formatPrd.html +2 -2
- package/docs/api/functions/formatPrdStatus.html +2 -2
- package/docs/api/functions/formatPreCompactSummary.html +2 -2
- package/docs/api/functions/formatProgressForContext.html +2 -2
- package/docs/api/functions/formatProgressMessage.html +2 -2
- package/docs/api/functions/formatStory.html +2 -2
- package/docs/api/functions/formatSummary.html +2 -2
- package/docs/api/functions/formatUpdateNotification.html +2 -2
- package/docs/api/functions/formatValidationResults.html +2 -2
- package/docs/api/functions/generateExtractionPrompt.html +2 -2
- package/docs/api/functions/generateSkillFrontmatter.html +2 -2
- package/docs/api/functions/generateSummary.html +2 -2
- package/docs/api/functions/getActiveAgentCount.html +2 -2
- package/docs/api/functions/getActiveExclusiveMode.html +4 -4
- package/docs/api/functions/getActiveModes.html +2 -2
- package/docs/api/functions/getActivePlanPath.html +2 -2
- package/docs/api/functions/getAgentDefinitions.html +2 -2
- package/docs/api/functions/getAgentsByType.html +2 -2
- package/docs/api/functions/getAllCommands.html +2 -2
- package/docs/api/functions/getAllModeStatuses.html +5 -5
- package/docs/api/functions/getAllSkills.html +2 -2
- package/docs/api/functions/getArchitectRejectionContinuationPrompt.html +2 -2
- package/docs/api/functions/getArchitectVerificationPrompt.html +2 -2
- package/docs/api/functions/getAutoFormatMessage.html +2 -2
- package/docs/api/functions/getAutopilotStateAge.html +3 -3
- package/docs/api/functions/getAvailableAgents.html +2 -2
- package/docs/api/functions/getAxiomDir.html +1 -1
- package/docs/api/functions/getBackgroundTaskGuidance.html +4 -4
- package/docs/api/functions/getBeadsContextConfig.html +2 -2
- package/docs/api/functions/getBeadsInstructions.html +2 -2
- package/docs/api/functions/getBoulderFilePath.html +2 -2
- package/docs/api/functions/getCheckpointPath.html +2 -2
- package/docs/api/functions/getClaudeThinkingConfig.html +3 -3
- package/docs/api/functions/getCommand.html +2 -2
- package/docs/api/functions/getCommandsDir.html +2 -2
- package/docs/api/functions/getCompactionQueueDepth.html +3 -3
- package/docs/api/functions/getCompletedWorkers.html +2 -2
- package/docs/api/functions/getDefaultMcpServers.html +1 -1
- package/docs/api/functions/getDefaultModelForCategory.html +2 -2
- package/docs/api/functions/getDetectionStats.html +2 -2
- package/docs/api/functions/getDirectPlanningPrompt.html +3 -3
- package/docs/api/functions/getExecutionPrompt.html +2 -2
- package/docs/api/functions/getExpansionPrompt.html +3 -3
- package/docs/api/functions/getExpertGateMessage.html +1 -1
- package/docs/api/functions/getFailedWorkers.html +2 -2
- package/docs/api/functions/getFormatter.html +2 -2
- package/docs/api/functions/getGitDiffStats.html +2 -2
- package/docs/api/functions/getGlobalStateFilePath.html +4 -4
- package/docs/api/functions/getGoalCommand.html +2 -2
- package/docs/api/functions/getHighVariant.html +3 -3
- package/docs/api/functions/getInstallInfo.html +2 -2
- package/docs/api/functions/getInstalledVersion.html +2 -2
- package/docs/api/functions/getIssuesToFix.html +2 -2
- package/docs/api/functions/getLastDetection.html +2 -2
- package/docs/api/functions/getLearnerConfigValue.html +2 -2
- package/docs/api/functions/getLinter.html +2 -2
- package/docs/api/functions/getManualSection.html +2 -2
- package/docs/api/functions/getMemoryFilePaths.html +1 -1
- package/docs/api/functions/getModeMarkerFilePath.html +2 -2
- package/docs/api/functions/getModeStateFilePath.html +2 -2
- package/docs/api/functions/getNextStory.html +2 -2
- package/docs/api/functions/getNotepadPath.html +2 -2
- package/docs/api/functions/getNotepadStats.html +2 -2
- package/docs/api/functions/getOmcPrdPath.html +2 -2
- package/docs/api/functions/getOmcProgressPath.html +2 -2
- package/docs/api/functions/getOmcSystemPrompt.html +2 -2
- package/docs/api/functions/getOmcToolNames.html +3 -3
- package/docs/api/functions/getPatterns.html +2 -2
- package/docs/api/functions/getPhasePrompt.html +2 -2
- package/docs/api/functions/getPlanName.html +2 -2
- package/docs/api/functions/getPlanPath.html +2 -2
- package/docs/api/functions/getPlanProgress.html +2 -2
- package/docs/api/functions/getPlanSummaries.html +2 -2
- package/docs/api/functions/getPrdCompletionStatus.html +2 -2
- package/docs/api/functions/getPrdPath.html +2 -2
- package/docs/api/functions/getPrdStatus.html +2 -2
- package/docs/api/functions/getPreCommitReminderMessage.html +2 -2
- package/docs/api/functions/getPriorityContext.html +2 -2
- package/docs/api/functions/getProgressContext.html +2 -2
- package/docs/api/functions/getProgressPath.html +2 -2
- package/docs/api/functions/getPromotionCandidates.html +2 -2
- package/docs/api/functions/getQAPrompt.html +2 -2
- package/docs/api/functions/getRalphContext.html +3 -3
- package/docs/api/functions/getReadmesForPath.html +2 -2
- package/docs/api/functions/getRecentLearnings.html +2 -2
- package/docs/api/functions/getRulesForPath.html +2 -2
- package/docs/api/functions/getRunningAgents.html +2 -2
- package/docs/api/functions/getRunningWorkers.html +2 -2
- package/docs/api/functions/getSessionTokenEstimate.html +2 -2
- package/docs/api/functions/getSkillsDir.html +2 -2
- package/docs/api/functions/getSpecPath.html +2 -2
- package/docs/api/functions/getStaleAgents.html +2 -2
- package/docs/api/functions/getStateDir.html +2 -2
- package/docs/api/functions/getStory.html +2 -2
- package/docs/api/functions/getSubagentStateFilePath.html +2 -2
- package/docs/api/functions/getThinkModeState.html +2 -2
- package/docs/api/functions/getThinkingConfig.html +3 -3
- package/docs/api/functions/getTopHotPaths.html +2 -2
- package/docs/api/functions/getTrackingStats.html +2 -2
- package/docs/api/functions/getTransitionPrompt.html +2 -2
- package/docs/api/functions/getUltraworkPersistenceMessage.html +2 -2
- package/docs/api/functions/getValidationPrompt.html +2 -2
- package/docs/api/functions/getValidationSpawnPrompt.html +2 -2
- package/docs/api/functions/getValidationStats.html +1 -1
- package/docs/api/functions/getValidationStatus.html +2 -2
- package/docs/api/functions/getWorkingMemory.html +2 -2
- package/docs/api/functions/handleBackgroundEvent.html +3 -3
- package/docs/api/functions/handleContextWindowRecovery.html +2 -2
- package/docs/api/functions/handleEditErrorRecovery.html +2 -2
- package/docs/api/functions/handlePermissionRequest.html +2 -2
- package/docs/api/functions/handleRecovery.html +10 -10
- package/docs/api/functions/handleSessionEnd.html +2 -2
- package/docs/api/functions/handleSessionRecovery.html +2 -2
- package/docs/api/functions/handleSharedFiles.html +7 -7
- package/docs/api/functions/handleSubagentStart.html +2 -2
- package/docs/api/functions/handleSubagentStop.html +2 -2
- package/docs/api/functions/hasBoulder.html +2 -2
- package/docs/api/functions/hasContentParts.html +1 -1
- package/docs/api/functions/hasModeState.html +3 -3
- package/docs/api/functions/hasPrd.html +2 -2
- package/docs/api/functions/hasTextContent.html +2 -2
- package/docs/api/functions/hasValidContent.html +3 -3
- package/docs/api/functions/incrementAgentCount.html +2 -2
- package/docs/api/functions/incrementRalphIteration.html +2 -2
- package/docs/api/functions/incrementReinforcement.html +2 -2
- package/docs/api/functions/initAutopilot.html +2 -2
- package/docs/api/functions/initNotepad.html +2 -2
- package/docs/api/functions/initPrd.html +2 -2
- package/docs/api/functions/initProgress.html +2 -2
- package/docs/api/functions/initUltrapilot.html +2 -2
- package/docs/api/functions/injectContextIntoText.html +2 -2
- package/docs/api/functions/injectPendingContext.html +3 -3
- package/docs/api/functions/injectRecoveryTextPart.html +2 -2
- package/docs/api/functions/install.html +2 -2
- package/docs/api/functions/integrateResults.html +5 -5
- package/docs/api/functions/isActiveModeRunning.html +2 -2
- package/docs/api/functions/isAllowedPath.html +2 -2
- package/docs/api/functions/isAlreadyHighVariant.html +2 -2
- package/docs/api/functions/isAutopilotActive.html +2 -2
- package/docs/api/functions/isAxiomEnabled.html +1 -1
- package/docs/api/functions/isClaudeInstalled.html +3 -3
- package/docs/api/functions/isClaudeModel.html +2 -2
- package/docs/api/functions/isCompactionInProgress.html +3 -3
- package/docs/api/functions/isDuplicateByContentHash.html +2 -2
- package/docs/api/functions/isDuplicateByRealPath.html +2 -2
- package/docs/api/functions/isExcludedCommand.html +2 -2
- package/docs/api/functions/isExtendedThinkingModel.html +1 -1
- package/docs/api/functions/isFileOwnedByWorker.html +2 -2
- package/docs/api/functions/isFormatterAvailable.html +2 -2
- package/docs/api/functions/isGptModel.html +2 -2
- package/docs/api/functions/isInstalled.html +2 -2
- package/docs/api/functions/isLearnerEnabled.html +2 -2
- package/docs/api/functions/isModeActive.html +6 -6
- package/docs/api/functions/isNonInteractive.html +1 -1
- package/docs/api/functions/isRecoverableError.html +2 -2
- package/docs/api/functions/isSafeCommand.html +2 -2
- package/docs/api/functions/isSessionRecoverable.html +2 -2
- package/docs/api/functions/isSharedFile.html +2 -2
- package/docs/api/functions/isThinkModeActive.html +2 -2
- package/docs/api/functions/isToolPart.html +2 -2
- package/docs/api/functions/isUltraQAActive.html +1 -1
- package/docs/api/functions/isWriteEditTool.html +2 -2
- package/docs/api/functions/learnFromToolOutput.html +7 -7
- package/docs/api/functions/lintFile.html +2 -2
- package/docs/api/functions/listAvailableCommands.html +2 -2
- package/docs/api/functions/listCommands.html +2 -2
- package/docs/api/functions/listPromotableLearnings.html +2 -2
- package/docs/api/functions/loadAgentPrompt.html +7 -7
- package/docs/api/functions/loadAgentUsageState.html +1 -1
- package/docs/api/functions/loadAllSkills.html +3 -3
- package/docs/api/functions/loadConfig.html +2 -2
- package/docs/api/functions/loadInjectedPaths.html +2 -2
- package/docs/api/functions/loadInjectedRules.html +2 -2
- package/docs/api/functions/loadLearnerConfig.html +2 -2
- package/docs/api/functions/loadProjectMemory.html +3 -3
- package/docs/api/functions/loadSkillById.html +2 -2
- package/docs/api/functions/mapDirectoryStructure.html +2 -2
- package/docs/api/functions/markStoryComplete.html +2 -2
- package/docs/api/functions/markStoryIncomplete.html +2 -2
- package/docs/api/functions/mergeAgentConfig.html +2 -2
- package/docs/api/functions/parseAxiomState.html +1 -1
- package/docs/api/functions/parseContextLimitError.html +2 -2
- package/docs/api/functions/parseProgress.html +2 -2
- package/docs/api/functions/parseRuleFrontmatter.html +10 -10
- package/docs/api/functions/parseSkillFile.html +2 -2
- package/docs/api/functions/parseSlashCommand.html +2 -2
- package/docs/api/functions/parseTokenLimitError.html +2 -2
- package/docs/api/functions/performUpdate.html +2 -2
- package/docs/api/functions/prependRecoveryThinkingPart.html +2 -2
- package/docs/api/functions/prependThinkingBlock.html +1 -1
- package/docs/api/functions/processAxiomBoot.html +1 -1
- package/docs/api/functions/processAxiomGuards.html +1 -1
- package/docs/api/functions/processBackgroundNotification.html +2 -2
- package/docs/api/functions/processBackgroundNotificationHook.html +2 -2
- package/docs/api/functions/processEditOutput.html +2 -2
- package/docs/api/functions/processHook.html +3 -3
- package/docs/api/functions/processMessageForSkills.html +2 -2
- package/docs/api/functions/processOrchestratorPostTool.html +3 -3
- package/docs/api/functions/processOrchestratorPreTool.html +3 -3
- package/docs/api/functions/processPermissionRequest.html +2 -2
- package/docs/api/functions/processPreCompact.html +6 -6
- package/docs/api/functions/processProjectMemoryPreCompact.html +3 -3
- package/docs/api/functions/processResponseForDetection.html +3 -3
- package/docs/api/functions/processSessionEnd.html +2 -2
- package/docs/api/functions/processSetup.html +2 -2
- package/docs/api/functions/processSetupInit.html +2 -2
- package/docs/api/functions/processSetupMaintenance.html +2 -2
- package/docs/api/functions/processSlashCommand.html +2 -2
- package/docs/api/functions/processSubagentStart.html +2 -2
- package/docs/api/functions/processSubagentStop.html +2 -2
- package/docs/api/functions/processThinkMode.html +3 -3
- package/docs/api/functions/promoteLearning.html +2 -2
- package/docs/api/functions/pruneOldEntries.html +2 -2
- package/docs/api/functions/pruneOldStateFiles.html +2 -2
- package/docs/api/functions/readActiveContext.html +1 -1
- package/docs/api/functions/readAutopilotState.html +2 -2
- package/docs/api/functions/readBoulderState.html +2 -2
- package/docs/api/functions/readModeMarker.html +4 -4
- package/docs/api/functions/readNotepad.html +2 -2
- package/docs/api/functions/readPrd.html +2 -2
- package/docs/api/functions/readProgress.html +2 -2
- package/docs/api/functions/readProgressRaw.html +2 -2
- package/docs/api/functions/readProjectDecisions.html +1 -1
- package/docs/api/functions/readRalphState.html +2 -2
- package/docs/api/functions/readRecoveryMessages.html +2 -2
- package/docs/api/functions/readRecoveryParts.html +2 -2
- package/docs/api/functions/readTrackingState.html +3 -3
- package/docs/api/functions/readUltraQAState.html +2 -2
- package/docs/api/functions/readUltrapilotState.html +2 -2
- package/docs/api/functions/readUltraworkState.html +4 -4
- package/docs/api/functions/readUserPreferences.html +1 -1
- package/docs/api/functions/readVerificationState.html +3 -3
- package/docs/api/functions/recordArchitectFeedback.html +2 -2
- package/docs/api/functions/recordConflict.html +2 -2
- package/docs/api/functions/recordFailure.html +2 -2
- package/docs/api/functions/recordHookFire.html +2 -2
- package/docs/api/functions/recordHookResult.html +2 -2
- package/docs/api/functions/recordKeywordDetected.html +2 -2
- package/docs/api/functions/recordModeChange.html +2 -2
- package/docs/api/functions/recordPattern.html +2 -2
- package/docs/api/functions/recordSessionMetrics.html +2 -2
- package/docs/api/functions/recordSkillActivated.html +2 -2
- package/docs/api/functions/recordSkillInvoked.html +2 -2
- package/docs/api/functions/recordStoryProgress.html +2 -2
- package/docs/api/functions/recordValidationVerdict.html +2 -2
- package/docs/api/functions/registerBeadsContext.html +3 -3
- package/docs/api/functions/registerProjectMemoryContext.html +6 -6
- package/docs/api/functions/removeCodeBlocks.html +12 -12
- package/docs/api/functions/removeModeMarker.html +5 -5
- package/docs/api/functions/removeSlashCodeBlocks.html +2 -2
- package/docs/api/functions/removeThinkCodeBlocks.html +2 -2
- package/docs/api/functions/replaceRecoveryEmptyTextParts.html +2 -2
- package/docs/api/functions/rescanProjectEnvironment.html +4 -4
- package/docs/api/functions/resetSessionTokenEstimate.html +2 -2
- package/docs/api/functions/resumeAutopilot.html +2 -2
- package/docs/api/functions/runPreCommitChecks.html +2 -2
- package/docs/api/functions/runTests.html +2 -2
- package/docs/api/functions/runTypeCheck.html +2 -2
- package/docs/api/functions/sanitizeMessage.html +2 -2
- package/docs/api/functions/sanitizeMessages.html +2 -2
- package/docs/api/functions/saveAgentUsageState.html +1 -1
- package/docs/api/functions/saveInjectedPaths.html +2 -2
- package/docs/api/functions/saveInjectedRules.html +2 -2
- package/docs/api/functions/saveLearnerConfig.html +2 -2
- package/docs/api/functions/saveModeSummary.html +2 -2
- package/docs/api/functions/saveProjectMemory.html +3 -3
- package/docs/api/functions/saveVersionMetadata.html +2 -2
- package/docs/api/functions/setCurrentStory.html +2 -2
- package/docs/api/functions/setEnvironmentVariables.html +2 -2
- package/docs/api/functions/setLearnerConfigValue.html +2 -2
- package/docs/api/functions/setPriorityContext.html +2 -2
- package/docs/api/functions/shouldActivateThinkMode.html +3 -3
- package/docs/api/functions/shouldActivateUltrathink.html +2 -2
- package/docs/api/functions/shouldApplyRule.html +2 -2
- package/docs/api/functions/shouldCheckForUpdates.html +2 -2
- package/docs/api/functions/shouldCompleteByPrd.html +2 -2
- package/docs/api/functions/shouldPromptExtraction.html +2 -2
- package/docs/api/functions/shouldReinforceUltrawork.html +2 -2
- package/docs/api/functions/shouldRetryValidation.html +2 -2
- package/docs/api/functions/shouldRunInBackground.html +8 -8
- package/docs/api/functions/spawnWorkers.html +7 -7
- package/docs/api/functions/startUltraQA.html +3 -3
- package/docs/api/functions/startUltrapilot.html +7 -7
- package/docs/api/functions/startValidationRound.html +2 -2
- package/docs/api/functions/startVerification.html +2 -2
- package/docs/api/functions/startsWithThinkingBlock.html +1 -1
- package/docs/api/functions/stopUltraQA.html +2 -2
- package/docs/api/functions/stripRecoveryThinkingParts.html +2 -2
- package/docs/api/functions/toSdkMcpFormat.html +2 -2
- package/docs/api/functions/trackAccess.html +2 -2
- package/docs/api/functions/trackProgress.html +5 -5
- package/docs/api/functions/transitionPhase.html +2 -2
- package/docs/api/functions/transitionRalphToUltraQA.html +9 -9
- package/docs/api/functions/transitionToComplete.html +2 -2
- package/docs/api/functions/transitionToFailed.html +2 -2
- package/docs/api/functions/transitionUltraQAToValidation.html +2 -2
- package/docs/api/functions/updateDirectoryAccess.html +2 -2
- package/docs/api/functions/updateExecution.html +2 -2
- package/docs/api/functions/updateExpansion.html +2 -2
- package/docs/api/functions/updatePlanning.html +2 -2
- package/docs/api/functions/updateQA.html +2 -2
- package/docs/api/functions/updateValidation.html +2 -2
- package/docs/api/functions/updateWorkerState.html +2 -2
- package/docs/api/functions/validateAgentConfig.html +2 -2
- package/docs/api/functions/validateCommitMessage.html +2 -2
- package/docs/api/functions/validateConfigFiles.html +2 -2
- package/docs/api/functions/validateExtractionRequest.html +2 -2
- package/docs/api/functions/validateMessage.html +1 -1
- package/docs/api/functions/validateMessages.html +1 -1
- package/docs/api/functions/validateSkillMetadata.html +2 -2
- package/docs/api/functions/writeAutopilotState.html +2 -2
- package/docs/api/functions/writeBoulderState.html +2 -2
- package/docs/api/functions/writePrd.html +2 -2
- package/docs/api/functions/writeRalphState.html +2 -2
- package/docs/api/functions/writeSkill.html +2 -2
- package/docs/api/functions/writeTrackingState.html +5 -5
- package/docs/api/functions/writeUltraQAState.html +2 -2
- package/docs/api/functions/writeUltrapilotState.html +2 -2
- package/docs/api/functions/writeUltraworkState.html +2 -2
- package/docs/api/functions/writeVerificationState.html +2 -2
- package/docs/api/hierarchy.html +1 -1
- package/docs/api/index.html +843 -843
- package/docs/api/interfaces/AgentConfig.html +18 -18
- package/docs/api/interfaces/AgentOverrideConfig.html +10 -10
- package/docs/api/interfaces/AgentPromptMetadata.html +19 -19
- package/docs/api/interfaces/AgentState.html +5 -5
- package/docs/api/interfaces/AgentUsageState.html +8 -8
- package/docs/api/interfaces/AutoSlashCommandHookInput.html +5 -5
- package/docs/api/interfaces/AutoSlashCommandHookOutput.html +3 -3
- package/docs/api/interfaces/AutoSlashCommandResult.html +5 -5
- package/docs/api/interfaces/AutopilotConfig.html +26 -26
- package/docs/api/interfaces/AutopilotExecution.html +16 -16
- package/docs/api/interfaces/AutopilotExpansion.html +12 -12
- package/docs/api/interfaces/AutopilotPlanning.html +8 -8
- package/docs/api/interfaces/AutopilotQA.html +12 -12
- package/docs/api/interfaces/AutopilotResult.html +10 -10
- package/docs/api/interfaces/AutopilotState.html +36 -36
- package/docs/api/interfaces/AutopilotSummary.html +16 -16
- package/docs/api/interfaces/AutopilotValidation.html +10 -10
- package/docs/api/interfaces/AutopilotValidationResult.html +8 -8
- package/docs/api/interfaces/AvailableAgent.html +5 -5
- package/docs/api/interfaces/AxiomBootInput.html +3 -3
- package/docs/api/interfaces/AxiomBootOutput.html +4 -4
- package/docs/api/interfaces/AxiomGuardsInput.html +4 -4
- package/docs/api/interfaces/AxiomGuardsOutput.html +4 -4
- package/docs/api/interfaces/AxiomMemoryFiles.html +5 -5
- package/docs/api/interfaces/AxiomState.html +8 -8
- package/docs/api/interfaces/BackgroundNotificationHookConfig.html +11 -11
- package/docs/api/interfaces/BackgroundNotificationHookInput.html +8 -8
- package/docs/api/interfaces/BackgroundNotificationHookOutput.html +8 -8
- package/docs/api/interfaces/BackgroundTask.html +7 -7
- package/docs/api/interfaces/BackgroundTaskManager.html +26 -26
- package/docs/api/interfaces/BeadsContextConfig.html +4 -4
- package/docs/api/interfaces/BoulderState.html +12 -12
- package/docs/api/interfaces/BuildInfo.html +6 -6
- package/docs/api/interfaces/CanStartResult.html +4 -4
- package/docs/api/interfaces/CancelResult.html +4 -4
- package/docs/api/interfaces/ClaudeThinkingConfig.html +4 -4
- package/docs/api/interfaces/CodeConventions.html +5 -5
- package/docs/api/interfaces/CodebasePattern.html +5 -5
- package/docs/api/interfaces/CommandInfo.html +5 -5
- package/docs/api/interfaces/CommandMetadata.html +7 -7
- package/docs/api/interfaces/CommentCheckResult.html +10 -10
- package/docs/api/interfaces/CommentCheckerConfig.html +6 -6
- package/docs/api/interfaces/CommentInfo.html +14 -14
- package/docs/api/interfaces/CommentPendingCall.html +18 -18
- package/docs/api/interfaces/CommitConfig.html +9 -9
- package/docs/api/interfaces/CompactCheckpoint.html +7 -7
- package/docs/api/interfaces/ContextEntry.html +14 -14
- package/docs/api/interfaces/ContextUsageResult.html +12 -12
- package/docs/api/interfaces/CustomNote.html +5 -5
- package/docs/api/interfaces/DelegationDecision.html +7 -7
- package/docs/api/interfaces/DelegationRoute.html +7 -7
- package/docs/api/interfaces/DelegationRoutingConfig.html +5 -5
- package/docs/api/interfaces/DelegationTrigger.html +6 -6
- package/docs/api/interfaces/DetectedKeyword.html +13 -13
- package/docs/api/interfaces/DetectionConfig.html +8 -8
- package/docs/api/interfaces/DetectionResult.html +13 -13
- package/docs/api/interfaces/DirectoryInfo.html +7 -7
- package/docs/api/interfaces/EmptyMessageSanitizerConfig.html +6 -6
- package/docs/api/interfaces/EmptyMessageSanitizerInput.html +6 -6
- package/docs/api/interfaces/EmptyMessageSanitizerOutput.html +8 -8
- package/docs/api/interfaces/ExecuteResult.html +5 -5
- package/docs/api/interfaces/ExpandedCommand.html +4 -4
- package/docs/api/interfaces/ExternalModelPreference.html +4 -4
- package/docs/api/interfaces/ExternalModelsConfig.html +6 -6
- package/docs/api/interfaces/ExternalModelsDefaults.html +5 -5
- package/docs/api/interfaces/ExternalModelsFallbackPolicy.html +5 -5
- package/docs/api/interfaces/FileOwnership.html +8 -8
- package/docs/api/interfaces/FormatConfig.html +7 -7
- package/docs/api/interfaces/FrameworkDetection.html +4 -4
- package/docs/api/interfaces/FullAgentConfig.html +26 -26
- package/docs/api/interfaces/GateCheckResult.html +5 -5
- package/docs/api/interfaces/GitBranchPattern.html +3 -3
- package/docs/api/interfaces/HookContext.html +5 -5
- package/docs/api/interfaces/HookDefinition.html +5 -5
- package/docs/api/interfaces/HookInput.html +18 -18
- package/docs/api/interfaces/HookOutput.html +10 -10
- package/docs/api/interfaces/HookResult.html +4 -4
- package/docs/api/interfaces/HotPath.html +6 -6
- package/docs/api/interfaces/InjectedPathsData.html +9 -9
- package/docs/api/interfaces/InjectedRulesData.html +10 -10
- package/docs/api/interfaces/InjectedSkillsData.html +8 -8
- package/docs/api/interfaces/InjectionResult.html +8 -8
- package/docs/api/interfaces/InstallOptions.html +9 -9
- package/docs/api/interfaces/InstallResult.html +10 -10
- package/docs/api/interfaces/IntegrationResult.html +14 -14
- package/docs/api/interfaces/LanguageDetection.html +5 -5
- package/docs/api/interfaces/LearnedSkill.html +16 -16
- package/docs/api/interfaces/LearnerConfig.html +18 -18
- package/docs/api/interfaces/LintConfig.html +7 -7
- package/docs/api/interfaces/MagicKeyword.html +4 -4
- package/docs/api/interfaces/MatchResult.html +6 -6
- package/docs/api/interfaces/MessageContext.html +8 -8
- package/docs/api/interfaces/MessageInfo.html +9 -9
- package/docs/api/interfaces/MessagePart.html +15 -15
- package/docs/api/interfaces/MessageWithModel.html +3 -3
- package/docs/api/interfaces/MessageWithParts.html +6 -6
- package/docs/api/interfaces/MessagesTransformHook.html +3 -3
- package/docs/api/interfaces/MessagesTransformInput.html +3 -3
- package/docs/api/interfaces/MessagesTransformOutput.html +3 -3
- package/docs/api/interfaces/ModeConfig.html +13 -13
- package/docs/api/interfaces/ModeStatus.html +4 -4
- package/docs/api/interfaces/ModelRef.html +4 -4
- package/docs/api/interfaces/NonInteractiveEnvConfig.html +2 -2
- package/docs/api/interfaces/NotepadConfig.html +7 -7
- package/docs/api/interfaces/NotepadStats.html +11 -11
- package/docs/api/interfaces/NotificationCheckResult.html +8 -8
- package/docs/api/interfaces/OrchestratorToolInput.html +6 -6
- package/docs/api/interfaces/OrchestratorToolOutput.html +6 -6
- package/docs/api/interfaces/OutputPart.html +4 -4
- package/docs/api/interfaces/PRD.html +9 -9
- package/docs/api/interfaces/PRDStatus.html +13 -13
- package/docs/api/interfaces/ParsedSlashCommand.html +8 -8
- package/docs/api/interfaces/ParsedTokenLimitError.html +16 -16
- package/docs/api/interfaces/PendingContext.html +8 -8
- package/docs/api/interfaces/PermissionHookOutput.html +4 -4
- package/docs/api/interfaces/PermissionRequestInput.html +9 -9
- package/docs/api/interfaces/PersistentModeResult.html +9 -9
- package/docs/api/interfaces/PlanProgress.html +8 -8
- package/docs/api/interfaces/PlanSummary.html +10 -10
- package/docs/api/interfaces/PluginConfig.html +17 -17
- package/docs/api/interfaces/PreCommitResult.html +3 -3
- package/docs/api/interfaces/PreCompactHookOutput.html +4 -4
- package/docs/api/interfaces/PreCompactInput.html +8 -8
- package/docs/api/interfaces/PreemptiveCompactionConfig.html +14 -14
- package/docs/api/interfaces/PriorityContextResult.html +5 -5
- package/docs/api/interfaces/ProgressEntry.html +11 -11
- package/docs/api/interfaces/ProgressLog.html +7 -7
- package/docs/api/interfaces/ProjectMemory.html +14 -14
- package/docs/api/interfaces/ProjectStructure.html +5 -5
- package/docs/api/interfaces/PromotionCandidate.html +9 -9
- package/docs/api/interfaces/PruneResult.html +5 -5
- package/docs/api/interfaces/QualityValidation.html +10 -10
- package/docs/api/interfaces/RalphLoopHook.html +4 -4
- package/docs/api/interfaces/RalphLoopOptions.html +5 -5
- package/docs/api/interfaces/RalphLoopState.html +21 -21
- package/docs/api/interfaces/RecoveryConfig.html +16 -16
- package/docs/api/interfaces/RecoveryMessageData.html +4 -4
- package/docs/api/interfaces/RecoveryResult.html +10 -10
- package/docs/api/interfaces/RecoveryStoredMessageMeta.html +8 -8
- package/docs/api/interfaces/RecoveryStoredReasoningPart.html +7 -7
- package/docs/api/interfaces/RecoveryStoredTextPart.html +9 -9
- package/docs/api/interfaces/RecoveryStoredToolPart.html +9 -9
- package/docs/api/interfaces/RegisterContextOptions.html +12 -12
- package/docs/api/interfaces/ReleaseInfo.html +9 -9
- package/docs/api/interfaces/ResolveDelegationOptions.html +7 -7
- package/docs/api/interfaces/ResolveOptions.html +6 -6
- package/docs/api/interfaces/ResolvedModel.html +5 -5
- package/docs/api/interfaces/RetryState.html +6 -6
- package/docs/api/interfaces/RuleFileCandidate.html +12 -12
- package/docs/api/interfaces/RuleFrontmatterResult.html +6 -6
- package/docs/api/interfaces/RuleInfo.html +18 -18
- package/docs/api/interfaces/RuleMetadata.html +9 -9
- package/docs/api/interfaces/RuleToInject.html +10 -10
- package/docs/api/interfaces/SessionEndHookOutput.html +2 -2
- package/docs/api/interfaces/SessionEndInput.html +9 -9
- package/docs/api/interfaces/SessionMetrics.html +9 -9
- package/docs/api/interfaces/SessionState.html +5 -5
- package/docs/api/interfaces/SetupHookOutput.html +3 -3
- package/docs/api/interfaces/SetupInput.html +7 -7
- package/docs/api/interfaces/SetupResult.html +5 -5
- package/docs/api/interfaces/ShellHook.html +4 -4
- package/docs/api/interfaces/SisyphusOptions.html +14 -14
- package/docs/api/interfaces/SisyphusSession.html +16 -16
- package/docs/api/interfaces/SkillExtractionRequest.html +12 -12
- package/docs/api/interfaces/SkillFileCandidate.html +10 -10
- package/docs/api/interfaces/SkillHookContext.html +5 -5
- package/docs/api/interfaces/SkillMetadata.html +22 -22
- package/docs/api/interfaces/SkillParseResult.html +5 -5
- package/docs/api/interfaces/SubagentHookOutput.html +3 -3
- package/docs/api/interfaces/SubagentInfo.html +14 -14
- package/docs/api/interfaces/SubagentStartInput.html +10 -10
- package/docs/api/interfaces/SubagentStopInput.html +11 -11
- package/docs/api/interfaces/SubagentTrackingState.html +6 -6
- package/docs/api/interfaces/TaskExecutionDecision.html +10 -10
- package/docs/api/interfaces/TechStack.html +5 -5
- package/docs/api/interfaces/ThinkModeInput.html +4 -4
- package/docs/api/interfaces/ThinkModeState.html +12 -12
- package/docs/api/interfaces/ThinkingValidatorMessageInfo.html +6 -6
- package/docs/api/interfaces/ThinkingValidatorMessagePart.html +9 -9
- package/docs/api/interfaces/ThinkingValidatorMessageWithParts.html +4 -4
- package/docs/api/interfaces/TodoContinuationHook.html +2 -2
- package/docs/api/interfaces/TransitionResult.html +4 -4
- package/docs/api/interfaces/TruncateState.html +6 -6
- package/docs/api/interfaces/UltraQAOptions.html +5 -5
- package/docs/api/interfaces/UltraQAResult.html +9 -9
- package/docs/api/interfaces/UltraQAState.html +19 -19
- package/docs/api/interfaces/UltrapilotConfig.html +14 -14
- package/docs/api/interfaces/UltrapilotState.html +26 -26
- package/docs/api/interfaces/UltraworkState.html +17 -17
- package/docs/api/interfaces/UpdateCheckResult.html +7 -7
- package/docs/api/interfaces/UpdateResult.html +7 -7
- package/docs/api/interfaces/UserDirective.html +7 -7
- package/docs/api/interfaces/UserStory.html +15 -15
- package/docs/api/interfaces/ValidationCoordinatorResult.html +6 -6
- package/docs/api/interfaces/ValidationResult.html +10 -10
- package/docs/api/interfaces/VerificationState.html +17 -17
- package/docs/api/interfaces/VersionMetadata.html +12 -12
- package/docs/api/interfaces/WorkerState.html +24 -24
- package/docs/api/interfaces/WriteSkillResult.html +6 -6
- package/docs/api/modules.html +1 -1
- package/docs/api/types/AgentCategory.html +2 -2
- package/docs/api/types/AgentCost.html +3 -3
- package/docs/api/types/AgentFactory.html +2 -2
- package/docs/api/types/AgentOverrides.html +2 -2
- package/docs/api/types/AutopilotPhase.html +2 -2
- package/docs/api/types/AutopilotSignal.html +2 -2
- package/docs/api/types/CommandScope.html +2 -2
- package/docs/api/types/ContextPriority.html +3 -3
- package/docs/api/types/ContextSourceType.html +3 -3
- package/docs/api/types/DelegationProvider.html +2 -2
- package/docs/api/types/DelegationTool.html +2 -2
- package/docs/api/types/ExecutionMode.html +3 -3
- package/docs/api/types/ExternalModelProvider.html +2 -2
- package/docs/api/types/GateType.html +3 -3
- package/docs/api/types/InjectionStrategy.html +2 -2
- package/docs/api/types/KeywordType.html +10 -10
- package/docs/api/types/ModelType.html +2 -2
- package/docs/api/types/QAStatus.html +2 -2
- package/docs/api/types/RecoveryErrorType.html +2 -2
- package/docs/api/types/RecoveryStoredPart.html +2 -2
- package/docs/api/types/TaskTool.html +1 -1
- package/docs/api/types/ThinkingConfig.html +2 -2
- package/docs/api/types/UltraQAGoalType.html +1 -1
- package/docs/api/types/UserStoryInput.html +2 -2
- package/docs/api/types/ValidationVerdict.html +2 -2
- package/docs/api/types/ValidationVerdictType.html +2 -2
- package/docs/api/variables/AGENTS_DIR.html +1 -1
- package/docs/api/variables/AGENTS_FILENAME.html +2 -2
- package/docs/api/variables/AGENT_TOOLS.html +2 -2
- package/docs/api/variables/ALLOWED_PATH_PREFIX.html +2 -2
- package/docs/api/variables/ANALYST_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/ARCHITECT_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/AUTO_SLASH_COMMAND_HOOK_NAME.html +4 -4
- package/docs/api/variables/AUTO_SLASH_COMMAND_TAG_CLOSE.html +1 -1
- package/docs/api/variables/AUTO_SLASH_COMMAND_TAG_OPEN.html +2 -2
- package/docs/api/variables/BACKGROUND_NOTIFICATION_HOOK_NAME.html +2 -2
- package/docs/api/variables/BDD_KEYWORDS.html +2 -2
- package/docs/api/variables/BEADS_INSTRUCTIONS.html +1 -1
- package/docs/api/variables/BEADS_RUST_INSTRUCTIONS.html +1 -1
- package/docs/api/variables/BLOCKING_PATTERNS.html +3 -3
- package/docs/api/variables/BOULDER_CONTINUATION_PROMPT.html +2 -2
- package/docs/api/variables/BOULDER_DIR.html +2 -2
- package/docs/api/variables/BOULDER_FILE.html +2 -2
- package/docs/api/variables/BOULDER_STATE_PATH.html +2 -2
- package/docs/api/variables/CHARS_PER_TOKEN.html +2 -2
- package/docs/api/variables/CI_COMMANDS.html +2 -2
- package/docs/api/variables/CI_GATE_MESSAGE.html +1 -1
- package/docs/api/variables/CLAUDE_CONFIG_DIR.html +2 -2
- package/docs/api/variables/CLAUDE_DEFAULT_CONTEXT_LIMIT.html +2 -2
- package/docs/api/variables/COMMANDS_DIR.html +1 -1
- package/docs/api/variables/COMMENT_CHECKER_MESSAGE_HEADER.html +2 -2
- package/docs/api/variables/COMPACTION_COOLDOWN_MS.html +2 -2
- package/docs/api/variables/CONTENT_PART_TYPES.html +2 -2
- package/docs/api/variables/CONTEXT_CRITICAL_MESSAGE.html +2 -2
- package/docs/api/variables/CONTEXT_FILENAMES.html +2 -2
- package/docs/api/variables/CONTEXT_LIMIT_RECOVERY_MESSAGE.html +2 -2
- package/docs/api/variables/CONTEXT_LIMIT_SHORT_MESSAGE.html +2 -2
- package/docs/api/variables/CONTEXT_WARNING_MESSAGE.html +2 -2
- package/docs/api/variables/CRITICAL_THRESHOLD.html +2 -2
- package/docs/api/variables/CRITIC_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/DEFAULT_CONFIG.html +2 -2
- package/docs/api/variables/DEFAULT_MAX_BACKGROUND_TASKS.html +2 -2
- package/docs/api/variables/DEFAULT_THINKING_CONTENT.html +2 -2
- package/docs/api/variables/DIRECT_WORK_REMINDER.html +2 -2
- package/docs/api/variables/DOCUMENT_SPECIALIST_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/DOCUMENT_WRITER_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/EDIT_ERROR_PATTERNS.html +2 -2
- package/docs/api/variables/EDIT_ERROR_REMINDER.html +3 -3
- package/docs/api/variables/EMPTY_MESSAGE_SANITIZER_DEBUG_PREFIX.html +2 -2
- package/docs/api/variables/EMPTY_MESSAGE_SANITIZER_ERROR_PATTERNS.html +2 -2
- package/docs/api/variables/EMPTY_MESSAGE_SANITIZER_HOOK_NAME.html +2 -2
- package/docs/api/variables/ENTRY_SEPARATOR.html +1 -1
- package/docs/api/variables/EXCLUDED_COMMANDS.html +3 -3
- package/docs/api/variables/EXPERT_GATE_MESSAGE.html +1 -1
- package/docs/api/variables/EXPLORE_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/EXTENSION_TO_LANGUAGE.html +2 -2
- package/docs/api/variables/FEATURE_FLAG_KEY.html +2 -2
- package/docs/api/variables/FRONTEND_ENGINEER_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/GITHUB_API_URL.html +1 -1
- package/docs/api/variables/INSTALLER_CLAUDE_CONFIG_DIR.html +2 -2
- package/docs/api/variables/INSTALLER_VERSION.html +2 -2
- package/docs/api/variables/LINE_COMMENT_PATTERNS.html +2 -2
- package/docs/api/variables/LONG_RUNNING_PATTERNS.html +3 -3
- package/docs/api/variables/MANUAL_HEADER.html +1 -1
- package/docs/api/variables/MAX_SKILLS_PER_SESSION.html +2 -2
- package/docs/api/variables/MAX_SKILL_CONTENT_LENGTH.html +2 -2
- package/docs/api/variables/MAX_WARNINGS.html +2 -2
- package/docs/api/variables/MIN_QUALITY_SCORE.html +2 -2
- package/docs/api/variables/MODE_CONFIGS.html +4 -4
- package/docs/api/variables/MULTIMODAL_LOOKER_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/NON_EMPTY_CONTENT_RECOVERY_MESSAGE.html +2 -2
- package/docs/api/variables/NON_INTERACTIVE_ENV.html +1 -1
- package/docs/api/variables/NON_INTERACTIVE_ENV_HOOK_NAME.html +1 -1
- package/docs/api/variables/NOTEPAD_BASE_PATH.html +2 -2
- package/docs/api/variables/NOTEPAD_DEFAULT_CONFIG.html +1 -1
- package/docs/api/variables/NOTEPAD_DIR.html +2 -2
- package/docs/api/variables/NOTEPAD_FILENAME.html +1 -1
- package/docs/api/variables/OMC_ORCHESTRATOR_HOOK_NAME.html +4 -4
- package/docs/api/variables/ORCHESTRATOR_DELEGATION_REQUIRED.html +2 -2
- package/docs/api/variables/PATTERNS_HEADER.html +1 -1
- package/docs/api/variables/PLACEHOLDER_TEXT.html +3 -3
- package/docs/api/variables/PLANNER_PLANS_DIR.html +2 -2
- package/docs/api/variables/PLANNER_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/PLAN_EXTENSION.html +2 -2
- package/docs/api/variables/PRD_EXAMPLE_FILENAME.html +1 -1
- package/docs/api/variables/PRD_FILENAME.html +1 -1
- package/docs/api/variables/PREEMPTIVE_DEFAULT_THRESHOLD.html +2 -2
- package/docs/api/variables/PREVENTED_ERROR.html +2 -2
- package/docs/api/variables/PRIORITY_HEADER.html +1 -1
- package/docs/api/variables/PROGRESS_FILENAME.html +1 -1
- package/docs/api/variables/PROJECT_MARKERS.html +2 -2
- package/docs/api/variables/PROJECT_RULE_FILES.html +2 -2
- package/docs/api/variables/PROJECT_RULE_SUBDIRS.html +2 -2
- package/docs/api/variables/PROJECT_SKILLS_SUBDIR.html +2 -2
- package/docs/api/variables/RAPID_FIRE_DEBOUNCE_MS.html +7 -7
- package/docs/api/variables/README_FILENAME.html +2 -2
- package/docs/api/variables/README_INJECTOR_STORAGE.html +1 -1
- package/docs/api/variables/README_TRACKED_TOOLS.html +2 -2
- package/docs/api/variables/RECOVERY_FAILED_MESSAGE.html +2 -2
- package/docs/api/variables/RECOVERY_MESSAGES.html +2 -2
- package/docs/api/variables/RECOVERY_PLACEHOLDER_TEXT.html +2 -2
- package/docs/api/variables/REMINDER_MESSAGE.html +2 -2
- package/docs/api/variables/REPO_NAME.html +1 -1
- package/docs/api/variables/REPO_OWNER.html +2 -2
- package/docs/api/variables/RETRY_CONFIG.html +6 -6
- package/docs/api/variables/RULES_INJECTOR_STORAGE.html +1 -1
- package/docs/api/variables/RULE_EXTENSIONS.html +2 -2
- package/docs/api/variables/SHELL_COMMAND_PATTERNS.html +3 -3
- package/docs/api/variables/SINGLE_TASK_DIRECTIVE.html +2 -2
- package/docs/api/variables/SISYPHUS_JUNIOR_PROMPT_METADATA.html +1 -1
- package/docs/api/variables/SKILL_EXTENSION.html +2 -2
- package/docs/api/variables/SLASH_COMMAND_PATTERN.html +2 -2
- package/docs/api/variables/STALE_STATE_MAX_AGE_MS.html +2 -2
- package/docs/api/variables/SYNTHETIC_THINKING_ID_PREFIX.html +2 -2
- package/docs/api/variables/TARGET_TOOLS.html +2 -2
- package/docs/api/variables/THINKING_BLOCK_VALIDATOR_HOOK_NAME.html +2 -2
- package/docs/api/variables/THINKING_CONFIGS.html +2 -2
- package/docs/api/variables/THINKING_MODEL_PATTERNS.html +3 -3
- package/docs/api/variables/THINKING_PART_TYPES.html +2 -2
- package/docs/api/variables/TOKEN_LIMIT_KEYWORDS.html +2 -2
- package/docs/api/variables/TOKEN_LIMIT_PATTERNS.html +2 -2
- package/docs/api/variables/TOOL_PART_TYPES.html +2 -2
- package/docs/api/variables/TRACKED_TOOLS.html +2 -2
- package/docs/api/variables/TRUNCATE_CONFIG.html +6 -6
- package/docs/api/variables/TRUNCATION_APPLIED_MESSAGE.html +2 -2
- package/docs/api/variables/TYPE_CHECKER_PREFIXES.html +2 -2
- package/docs/api/variables/ULTRAPILOT_DEFAULT_CONFIG.html +2 -2
- package/docs/api/variables/USER_GATE_MESSAGE.html +1 -1
- package/docs/api/variables/USER_RULE_DIR.html +2 -2
- package/docs/api/variables/USER_SKILLS_DIR.html +2 -2
- package/docs/api/variables/VERIFICATION_REMINDER.html +2 -2
- package/docs/api/variables/VERSION_FILE.html +1 -1
- package/docs/api/variables/WORKING_MEMORY_HEADER.html +1 -1
- package/docs/api/variables/WRITE_EDIT_TOOLS.html +2 -2
- package/docs/api/variables/allCustomTools.html +3 -3
- package/docs/api/variables/analystAgent.html +1 -1
- package/docs/api/variables/architectAgent.html +1 -1
- package/docs/api/variables/astTools.html +2 -2
- package/docs/api/variables/contextCollector.html +2 -2
- package/docs/api/variables/criticAgent.html +1 -1
- package/docs/api/variables/designerAgent.html +1 -1
- package/docs/api/variables/executorAgent.html +1 -1
- package/docs/api/variables/exploreAgent.html +1 -1
- package/docs/api/variables/lspTools.html +2 -2
- package/docs/api/variables/nonInteractiveEnvHook.html +8 -8
- package/docs/api/variables/omcSystemPrompt.html +2 -2
- package/docs/api/variables/omcToolNames.html +3 -3
- package/docs/api/variables/omcToolsServer.html +4 -4
- package/docs/api/variables/plannerAgent.html +1 -1
- package/docs/api/variables/researcherAgent.html +1 -1
- package/docs/api/variables/visionAgent.html +1 -1
- package/docs/api/variables/writerAgent.html +1 -1
- package/docs/concepts/README.md +63 -0
- package/docs/concepts/agent-selection.md +83 -0
- package/docs/concepts/agents.md +63 -0
- package/docs/concepts/error-handling.md +121 -0
- package/docs/concepts/modes.md +70 -0
- package/docs/concepts/skills.md +68 -0
- package/docs/getting-started/concepts.md +127 -63
- package/docs/getting-started/quick-reference.md +135 -0
- package/docs/getting-started/quickstart.md +101 -17
- package/docs/quick-start.md +169 -0
- package/docs/reviews/autoresearch-integration/review_domain.md +295 -295
- package/docs/reviews/autoresearch-integration/review_product.md +287 -287
- package/docs/standards/README.md +1 -1
- package/docs/state-migration.md +98 -0
- package/docs/tasks/v7.0.1/sub_prds/T-001-test-optimization.md +66 -0
- package/hooks/run-hook.cmd +0 -0
- package/hooks/session-start +0 -0
- package/package.json +5 -1
- package/scripts/check-version-sync.mjs +33 -0
- package/scripts/fix-agent-headers.py +58 -58
- package/scripts/fix-blank-lines.py +19 -19
- package/scripts/fix-long-lines.py +41 -41
- package/scripts/migrate-console-to-logger.ts +91 -0
- package/scripts/persistent-mode.cjs +605 -605
- package/skills/release/SKILL.md +126 -0
- package/skills/systematic-debugging/find-polluter.sh +0 -0
- package/skills/writing-skills/graphviz-conventions.dot +171 -171
- package/skills/writing-skills/render-graphs.js +0 -0
- package/templates/axiom/scripts/Check-Memory.ps1 +68 -68
- package/templates/axiom/scripts/Poll-Memory.ps1 +36 -36
- package/templates/axiom/scripts/Watch-Memory.ps1 +149 -149
- package/templates/axiom/scripts/agent-runner.ps1 +101 -101
- package/templates/axiom/scripts/start-reviews.ps1 +19 -19
- package/templates/demo/README.md +39 -0
- package/templates/example-project/README.md +34 -0
- package/templates/example-project/dist/index.js +5 -0
- package/templates/example-project/package-lock.json +47 -0
- package/templates/example-project/package.json +13 -0
- package/templates/example-project/src/index.ts +5 -0
- package/templates/example-project/tsconfig.json +11 -0
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export interface RetryOptions {
|
|
2
|
+
maxRetries?: number;
|
|
3
|
+
baseDelay?: number;
|
|
4
|
+
operation?: string;
|
|
5
|
+
}
|
|
6
|
+
export interface RetryResult<T> {
|
|
7
|
+
success: boolean;
|
|
8
|
+
result?: T;
|
|
9
|
+
error?: Error;
|
|
10
|
+
attempts: number;
|
|
11
|
+
}
|
|
12
|
+
export declare class RetryManager {
|
|
13
|
+
private maxRetries;
|
|
14
|
+
private baseDelay;
|
|
15
|
+
private operation?;
|
|
16
|
+
constructor(options?: RetryOptions);
|
|
17
|
+
execute<T>(fn: () => Promise<T>): Promise<RetryResult<T>>;
|
|
18
|
+
private sleep;
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=retry-manager.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"retry-manager.d.ts","sourceRoot":"","sources":["../../src/reliability/retry-manager.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,YAAY;IAC3B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,WAAW,CAAC,CAAC;IAC5B,OAAO,EAAE,OAAO,CAAC;IACjB,MAAM,CAAC,EAAE,CAAC,CAAC;IACX,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,qBAAa,YAAY;IACvB,OAAO,CAAC,UAAU,CAAS;IAC3B,OAAO,CAAC,SAAS,CAAS;IAC1B,OAAO,CAAC,SAAS,CAAC,CAAS;gBAEf,OAAO,GAAE,YAAiB;IAMhC,OAAO,CAAC,CAAC,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC;IAgC/D,OAAO,CAAC,KAAK;CAGd"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { RetryClassifier } from './retry-classifier.js';
|
|
2
|
+
export class RetryManager {
|
|
3
|
+
maxRetries;
|
|
4
|
+
baseDelay;
|
|
5
|
+
operation;
|
|
6
|
+
constructor(options = {}) {
|
|
7
|
+
this.maxRetries = options.maxRetries ?? 3;
|
|
8
|
+
this.baseDelay = options.baseDelay ?? 1000;
|
|
9
|
+
this.operation = options.operation;
|
|
10
|
+
}
|
|
11
|
+
async execute(fn) {
|
|
12
|
+
if (this.operation && !RetryClassifier.isRetryable(this.operation)) {
|
|
13
|
+
try {
|
|
14
|
+
const result = await fn();
|
|
15
|
+
return { success: true, result, attempts: 1 };
|
|
16
|
+
}
|
|
17
|
+
catch (error) {
|
|
18
|
+
const err = error instanceof Error ? error : new Error(String(error));
|
|
19
|
+
return { success: false, error: err, attempts: 1 };
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
let lastError;
|
|
23
|
+
for (let attempt = 0; attempt <= this.maxRetries; attempt++) {
|
|
24
|
+
try {
|
|
25
|
+
const result = await fn();
|
|
26
|
+
console.log(`[RetryManager] Success on attempt ${attempt + 1}`);
|
|
27
|
+
return { success: true, result, attempts: attempt + 1 };
|
|
28
|
+
}
|
|
29
|
+
catch (error) {
|
|
30
|
+
lastError = error instanceof Error ? error : new Error(String(error));
|
|
31
|
+
console.log(`[RetryManager] Attempt ${attempt + 1} failed: ${lastError.message}`);
|
|
32
|
+
if (attempt < this.maxRetries) {
|
|
33
|
+
const delay = this.baseDelay * Math.pow(2, attempt);
|
|
34
|
+
console.log(`[RetryManager] Retrying in ${delay}ms...`);
|
|
35
|
+
await this.sleep(delay);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
return { success: false, error: lastError, attempts: this.maxRetries + 1 };
|
|
40
|
+
}
|
|
41
|
+
sleep(ms) {
|
|
42
|
+
return new Promise(resolve => setTimeout(resolve, ms));
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
//# sourceMappingURL=retry-manager.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"retry-manager.js","sourceRoot":"","sources":["../../src/reliability/retry-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAexD,MAAM,OAAO,YAAY;IACf,UAAU,CAAS;IACnB,SAAS,CAAS;IAClB,SAAS,CAAU;IAE3B,YAAY,UAAwB,EAAE;QACpC,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,IAAI,CAAC,CAAC;QAC1C,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,SAAS,IAAI,IAAI,CAAC;QAC3C,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,SAAS,CAAC;IACrC,CAAC;IAED,KAAK,CAAC,OAAO,CAAI,EAAoB;QACnC,IAAI,IAAI,CAAC,SAAS,IAAI,CAAC,eAAe,CAAC,WAAW,CAAC,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC;YACnE,IAAI,CAAC;gBACH,MAAM,MAAM,GAAG,MAAM,EAAE,EAAE,CAAC;gBAC1B,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC;YAChD,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,MAAM,GAAG,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;gBACtE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC;YACrD,CAAC;QACH,CAAC;QACD,IAAI,SAA4B,CAAC;QAEjC,KAAK,IAAI,OAAO,GAAG,CAAC,EAAE,OAAO,IAAI,IAAI,CAAC,UAAU,EAAE,OAAO,EAAE,EAAE,CAAC;YAC5D,IAAI,CAAC;gBACH,MAAM,MAAM,GAAG,MAAM,EAAE,EAAE,CAAC;gBAC1B,OAAO,CAAC,GAAG,CAAC,qCAAqC,OAAO,GAAG,CAAC,EAAE,CAAC,CAAC;gBAChE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,GAAG,CAAC,EAAE,CAAC;YAC1D,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,SAAS,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;gBACtE,OAAO,CAAC,GAAG,CAAC,0BAA0B,OAAO,GAAG,CAAC,YAAY,SAAS,CAAC,OAAO,EAAE,CAAC,CAAC;gBAElF,IAAI,OAAO,GAAG,IAAI,CAAC,UAAU,EAAE,CAAC;oBAC9B,MAAM,KAAK,GAAG,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC;oBACpD,OAAO,CAAC,GAAG,CAAC,8BAA8B,KAAK,OAAO,CAAC,CAAC;oBACxD,MAAM,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;gBAC1B,CAAC;YACH,CAAC;QACH,CAAC;QAED,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,IAAI,CAAC,UAAU,GAAG,CAAC,EAAE,CAAC;IAC7E,CAAC;IAEO,KAAK,CAAC,EAAU;QACtB,OAAO,IAAI,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,CAAC;IACzD,CAAC;CACF"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export interface AuditEvent {
|
|
2
|
+
timestamp: number;
|
|
3
|
+
userId: string;
|
|
4
|
+
action: string;
|
|
5
|
+
resource: string;
|
|
6
|
+
result: 'success' | 'failure';
|
|
7
|
+
previousHash?: string;
|
|
8
|
+
hash?: string;
|
|
9
|
+
}
|
|
10
|
+
export declare class AuditLogger {
|
|
11
|
+
private logPath;
|
|
12
|
+
private events;
|
|
13
|
+
constructor(logPath?: string);
|
|
14
|
+
log(event: Omit<AuditEvent, 'timestamp' | 'hash' | 'previousHash'>): void;
|
|
15
|
+
query(filters: Partial<Omit<AuditEvent, 'hash' | 'previousHash'>>): AuditEvent[];
|
|
16
|
+
verify(): boolean;
|
|
17
|
+
private computeHash;
|
|
18
|
+
private load;
|
|
19
|
+
private save;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=audit-logger.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audit-logger.d.ts","sourceRoot":"","sources":["../../src/security/audit-logger.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,UAAU;IACzB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,SAAS,GAAG,SAAS,CAAC;IAC9B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,qBAAa,WAAW;IACtB,OAAO,CAAC,OAAO,CAAS;IACxB,OAAO,CAAC,MAAM,CAAoB;gBAEtB,OAAO,GAAE,MAA+B;IAKpD,GAAG,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,EAAE,WAAW,GAAG,MAAM,GAAG,cAAc,CAAC,GAAG,IAAI;IAYzE,KAAK,CAAC,OAAO,EAAE,OAAO,CAAC,IAAI,CAAC,UAAU,EAAE,MAAM,GAAG,cAAc,CAAC,CAAC,GAAG,UAAU,EAAE;IAMhF,MAAM,IAAI,OAAO;IAUjB,OAAO,CAAC,WAAW;IAKnB,OAAO,CAAC,IAAI;IAQZ,OAAO,CAAC,IAAI;CAOb"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import crypto from 'crypto';
|
|
2
|
+
import fs from 'fs';
|
|
3
|
+
import path from 'path';
|
|
4
|
+
export class AuditLogger {
|
|
5
|
+
logPath;
|
|
6
|
+
events = [];
|
|
7
|
+
constructor(logPath = '.omc/logs/audit.json') {
|
|
8
|
+
this.logPath = path.resolve(logPath);
|
|
9
|
+
this.load();
|
|
10
|
+
}
|
|
11
|
+
log(event) {
|
|
12
|
+
const previousHash = this.events.length > 0 ? this.events[this.events.length - 1].hash : undefined;
|
|
13
|
+
const newEvent = {
|
|
14
|
+
...event,
|
|
15
|
+
timestamp: Date.now(),
|
|
16
|
+
previousHash,
|
|
17
|
+
};
|
|
18
|
+
newEvent.hash = this.computeHash(newEvent);
|
|
19
|
+
this.events.push(newEvent);
|
|
20
|
+
this.save();
|
|
21
|
+
}
|
|
22
|
+
query(filters) {
|
|
23
|
+
return this.events.filter(event => {
|
|
24
|
+
return Object.entries(filters).every(([key, value]) => event[key] === value);
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
verify() {
|
|
28
|
+
for (let i = 0; i < this.events.length; i++) {
|
|
29
|
+
const event = this.events[i];
|
|
30
|
+
const expectedHash = this.computeHash(event);
|
|
31
|
+
if (event.hash !== expectedHash)
|
|
32
|
+
return false;
|
|
33
|
+
if (i > 0 && event.previousHash !== this.events[i - 1].hash)
|
|
34
|
+
return false;
|
|
35
|
+
}
|
|
36
|
+
return true;
|
|
37
|
+
}
|
|
38
|
+
computeHash(event) {
|
|
39
|
+
const data = `${event.timestamp}:${event.userId}:${event.action}:${event.resource}:${event.result}:${event.previousHash || ''}`;
|
|
40
|
+
return crypto.createHash('sha256').update(data).digest('hex');
|
|
41
|
+
}
|
|
42
|
+
load() {
|
|
43
|
+
// eslint-disable-next-line no-restricted-syntax
|
|
44
|
+
if (fs.existsSync(this.logPath)) {
|
|
45
|
+
// eslint-disable-next-line no-restricted-syntax
|
|
46
|
+
this.events = JSON.parse(fs.readFileSync(this.logPath, 'utf-8'));
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
save() {
|
|
50
|
+
const dir = path.dirname(this.logPath);
|
|
51
|
+
// eslint-disable-next-line no-restricted-syntax
|
|
52
|
+
if (!fs.existsSync(dir))
|
|
53
|
+
fs.mkdirSync(dir, { recursive: true });
|
|
54
|
+
// eslint-disable-next-line no-restricted-syntax
|
|
55
|
+
fs.writeFileSync(this.logPath, JSON.stringify(this.events, null, 2));
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
//# sourceMappingURL=audit-logger.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audit-logger.js","sourceRoot":"","sources":["../../src/security/audit-logger.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* T-013: Budget Control
|
|
3
|
+
* - maxTokens/maxCost enforcement
|
|
4
|
+
* - Auto-stop on limit exceeded
|
|
5
|
+
*/
|
|
6
|
+
export interface BudgetConfig {
|
|
7
|
+
maxTokens?: number;
|
|
8
|
+
maxCost?: number;
|
|
9
|
+
}
|
|
10
|
+
export interface UsageStats {
|
|
11
|
+
tokens: number;
|
|
12
|
+
cost: number;
|
|
13
|
+
}
|
|
14
|
+
export declare class BudgetController {
|
|
15
|
+
private config;
|
|
16
|
+
private usage;
|
|
17
|
+
constructor(config: BudgetConfig);
|
|
18
|
+
track(tokens: number, cost: number): void;
|
|
19
|
+
check(): void;
|
|
20
|
+
getUsage(): UsageStats;
|
|
21
|
+
reset(): void;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=budget-controller.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"budget-controller.d.ts","sourceRoot":"","sources":["../../src/security/budget-controller.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,MAAM,WAAW,YAAY;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,UAAU;IACzB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;CACd;AAED,qBAAa,gBAAgB;IAGf,OAAO,CAAC,MAAM;IAF1B,OAAO,CAAC,KAAK,CAAsC;gBAE/B,MAAM,EAAE,YAAY;IAExC,KAAK,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI;IAKzC,KAAK,IAAI,IAAI;IASb,QAAQ,IAAI,UAAU;IAItB,KAAK,IAAI,IAAI;CAGd"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* T-013: Budget Control
|
|
3
|
+
* - maxTokens/maxCost enforcement
|
|
4
|
+
* - Auto-stop on limit exceeded
|
|
5
|
+
*/
|
|
6
|
+
export class BudgetController {
|
|
7
|
+
config;
|
|
8
|
+
usage = { tokens: 0, cost: 0 };
|
|
9
|
+
constructor(config) {
|
|
10
|
+
this.config = config;
|
|
11
|
+
}
|
|
12
|
+
track(tokens, cost) {
|
|
13
|
+
this.usage.tokens += tokens;
|
|
14
|
+
this.usage.cost += cost;
|
|
15
|
+
}
|
|
16
|
+
check() {
|
|
17
|
+
if (this.config.maxTokens && this.usage.tokens > this.config.maxTokens) {
|
|
18
|
+
throw new Error(`Token budget exceeded: ${this.usage.tokens}/${this.config.maxTokens}`);
|
|
19
|
+
}
|
|
20
|
+
if (this.config.maxCost && this.usage.cost > this.config.maxCost) {
|
|
21
|
+
throw new Error(`Cost budget exceeded: $${this.usage.cost.toFixed(2)}/$${this.config.maxCost.toFixed(2)}`);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
getUsage() {
|
|
25
|
+
return { ...this.usage };
|
|
26
|
+
}
|
|
27
|
+
reset() {
|
|
28
|
+
this.usage = { tokens: 0, cost: 0 };
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
//# sourceMappingURL=budget-controller.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"budget-controller.js","sourceRoot":"","sources":["../../src/security/budget-controller.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAYH,MAAM,OAAO,gBAAgB;IAGP;IAFZ,KAAK,GAAe,EAAE,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;IAEnD,YAAoB,MAAoB;QAApB,WAAM,GAAN,MAAM,CAAc;IAAG,CAAC;IAE5C,KAAK,CAAC,MAAc,EAAE,IAAY;QAChC,IAAI,CAAC,KAAK,CAAC,MAAM,IAAI,MAAM,CAAC;QAC5B,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,IAAI,CAAC;IAC1B,CAAC;IAED,KAAK;QACH,IAAI,IAAI,CAAC,MAAM,CAAC,SAAS,IAAI,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC,SAAS,EAAE,CAAC;YACvE,MAAM,IAAI,KAAK,CAAC,0BAA0B,IAAI,CAAC,KAAK,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM,CAAC,SAAS,EAAE,CAAC,CAAC;QAC1F,CAAC;QACD,IAAI,IAAI,CAAC,MAAM,CAAC,OAAO,IAAI,IAAI,CAAC,KAAK,CAAC,IAAI,GAAG,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC;YACjE,MAAM,IAAI,KAAK,CAAC,0BAA0B,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;QAC7G,CAAC;IACH,CAAC;IAED,QAAQ;QACN,OAAO,EAAE,GAAG,IAAI,CAAC,KAAK,EAAE,CAAC;IAC3B,CAAC;IAED,KAAK;QACH,IAAI,CAAC,KAAK,GAAG,EAAE,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;IACtC,CAAC;CACF"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* T-019: Concurrency Control Mechanism
|
|
3
|
+
* - Version checking
|
|
4
|
+
* - Conflict retry with exponential backoff
|
|
5
|
+
* - Deadlock detection
|
|
6
|
+
*/
|
|
7
|
+
export interface VersionedState {
|
|
8
|
+
version: number;
|
|
9
|
+
data: any;
|
|
10
|
+
timestamp: number;
|
|
11
|
+
}
|
|
12
|
+
export interface ConcurrencyConfig {
|
|
13
|
+
maxRetries?: number;
|
|
14
|
+
baseDelayMs?: number;
|
|
15
|
+
deadlockTimeoutMs?: number;
|
|
16
|
+
}
|
|
17
|
+
export declare class ConcurrencyControl {
|
|
18
|
+
private locks;
|
|
19
|
+
private config;
|
|
20
|
+
constructor(config?: ConcurrencyConfig);
|
|
21
|
+
/**
|
|
22
|
+
* Version check: ensure state hasn't changed
|
|
23
|
+
*/
|
|
24
|
+
checkVersion(current: number, expected: number): void;
|
|
25
|
+
/**
|
|
26
|
+
* Retry with exponential backoff on conflict
|
|
27
|
+
*/
|
|
28
|
+
retryOnConflict<T>(operation: () => Promise<T>, resourceId: string): Promise<T>;
|
|
29
|
+
/**
|
|
30
|
+
* Acquire lock with deadlock detection
|
|
31
|
+
*/
|
|
32
|
+
acquireLock(resourceId: string, holderId: string): Promise<void>;
|
|
33
|
+
/**
|
|
34
|
+
* Release lock
|
|
35
|
+
*/
|
|
36
|
+
releaseLock(resourceId: string, holderId: string): void;
|
|
37
|
+
/**
|
|
38
|
+
* Check for deadlocks
|
|
39
|
+
*/
|
|
40
|
+
detectDeadlocks(): string[];
|
|
41
|
+
}
|
|
42
|
+
//# sourceMappingURL=concurrency-control.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"concurrency-control.d.ts","sourceRoot":"","sources":["../../src/security/concurrency-control.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,GAAG,CAAC;IACV,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,iBAAiB;IAChC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAQD,qBAAa,kBAAkB;IAC7B,OAAO,CAAC,KAAK,CAA4D;IACzE,OAAO,CAAC,MAAM,CAA8B;gBAEhC,MAAM,GAAE,iBAAsB;IAI1C;;OAEG;IACH,YAAY,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI;IAMrD;;OAEG;IACG,eAAe,CAAC,CAAC,EACrB,SAAS,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,EAC3B,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC,CAAC,CAAC;IAsBb;;OAEG;IACG,WAAW,CAAC,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAiBtE;;OAEG;IACH,WAAW,CAAC,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI;IAQvD;;OAEG;IACH,eAAe,IAAI,MAAM,EAAE;CAY5B"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* T-019: Concurrency Control Mechanism
|
|
3
|
+
* - Version checking
|
|
4
|
+
* - Conflict retry with exponential backoff
|
|
5
|
+
* - Deadlock detection
|
|
6
|
+
*/
|
|
7
|
+
const DEFAULT_CONFIG = {
|
|
8
|
+
maxRetries: 3,
|
|
9
|
+
baseDelayMs: 100,
|
|
10
|
+
deadlockTimeoutMs: 30000,
|
|
11
|
+
};
|
|
12
|
+
export class ConcurrencyControl {
|
|
13
|
+
locks = new Map();
|
|
14
|
+
config;
|
|
15
|
+
constructor(config = {}) {
|
|
16
|
+
this.config = { ...DEFAULT_CONFIG, ...config };
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Version check: ensure state hasn't changed
|
|
20
|
+
*/
|
|
21
|
+
checkVersion(current, expected) {
|
|
22
|
+
if (current !== expected) {
|
|
23
|
+
throw new Error(`Version conflict: expected ${expected}, got ${current}`);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Retry with exponential backoff on conflict
|
|
28
|
+
*/
|
|
29
|
+
async retryOnConflict(operation, resourceId) {
|
|
30
|
+
let lastError;
|
|
31
|
+
for (let attempt = 0; attempt < this.config.maxRetries; attempt++) {
|
|
32
|
+
try {
|
|
33
|
+
return await operation();
|
|
34
|
+
}
|
|
35
|
+
catch (error) {
|
|
36
|
+
if (error instanceof Error && error.message.includes('Version conflict')) {
|
|
37
|
+
lastError = error;
|
|
38
|
+
const delay = this.config.baseDelayMs * Math.pow(2, attempt);
|
|
39
|
+
await new Promise(resolve => setTimeout(resolve, delay));
|
|
40
|
+
continue;
|
|
41
|
+
}
|
|
42
|
+
throw error;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
throw new Error(`Max retries (${this.config.maxRetries}) exceeded for ${resourceId}: ${lastError?.message}`);
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Acquire lock with deadlock detection
|
|
49
|
+
*/
|
|
50
|
+
async acquireLock(resourceId, holderId) {
|
|
51
|
+
const existing = this.locks.get(resourceId);
|
|
52
|
+
if (existing) {
|
|
53
|
+
const elapsed = Date.now() - existing.timestamp;
|
|
54
|
+
if (elapsed > this.config.deadlockTimeoutMs) {
|
|
55
|
+
// Deadlock detected, force release
|
|
56
|
+
this.locks.delete(resourceId);
|
|
57
|
+
}
|
|
58
|
+
else if (existing.holder !== holderId) {
|
|
59
|
+
throw new Error(`Resource ${resourceId} locked by ${existing.holder}`);
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
this.locks.set(resourceId, { holder: holderId, timestamp: Date.now() });
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* Release lock
|
|
66
|
+
*/
|
|
67
|
+
releaseLock(resourceId, holderId) {
|
|
68
|
+
const existing = this.locks.get(resourceId);
|
|
69
|
+
if (existing && existing.holder === holderId) {
|
|
70
|
+
this.locks.delete(resourceId);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Check for deadlocks
|
|
75
|
+
*/
|
|
76
|
+
detectDeadlocks() {
|
|
77
|
+
const deadlocked = [];
|
|
78
|
+
const now = Date.now();
|
|
79
|
+
for (const [resourceId, lock] of this.locks.entries()) {
|
|
80
|
+
if (now - lock.timestamp > this.config.deadlockTimeoutMs) {
|
|
81
|
+
deadlocked.push(resourceId);
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
return deadlocked;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
//# sourceMappingURL=concurrency-control.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"concurrency-control.js","sourceRoot":"","sources":["../../src/security/concurrency-control.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* T-020: Resource Exhaustion Protection
|
|
3
|
+
* - Rate limiting
|
|
4
|
+
* - Concurrency limiting
|
|
5
|
+
* - Disk quota checking
|
|
6
|
+
*/
|
|
7
|
+
export interface ResourceConfig {
|
|
8
|
+
rateLimit?: {
|
|
9
|
+
perSecond?: number;
|
|
10
|
+
perMinute?: number;
|
|
11
|
+
};
|
|
12
|
+
maxConcurrency?: number;
|
|
13
|
+
diskQuotaMB?: number;
|
|
14
|
+
}
|
|
15
|
+
export declare class ResourceGuard {
|
|
16
|
+
private config;
|
|
17
|
+
private rates;
|
|
18
|
+
private concurrency;
|
|
19
|
+
constructor(config: ResourceConfig);
|
|
20
|
+
checkRateLimit(userId: string, operation: string): void;
|
|
21
|
+
acquireConcurrencySlot(userId: string): void;
|
|
22
|
+
releaseConcurrencySlot(userId: string): void;
|
|
23
|
+
checkDiskQuota(userId: string, usedMB: number): void;
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=resource-guard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resource-guard.d.ts","sourceRoot":"","sources":["../../src/security/resource-guard.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,WAAW,cAAc;IAC7B,SAAS,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAC;QAAC,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IACvD,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAOD,qBAAa,aAAa;IAIZ,OAAO,CAAC,MAAM;IAH1B,OAAO,CAAC,KAAK,CAAiC;IAC9C,OAAO,CAAC,WAAW,CAA6B;gBAE5B,MAAM,EAAE,cAAc;IAE1C,cAAc,CAAC,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,IAAI;IA8BvD,sBAAsB,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI;IAU5C,sBAAsB,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI;IAK5C,cAAc,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI;CAKrD"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* T-020: Resource Exhaustion Protection
|
|
3
|
+
* - Rate limiting
|
|
4
|
+
* - Concurrency limiting
|
|
5
|
+
* - Disk quota checking
|
|
6
|
+
*/
|
|
7
|
+
export class ResourceGuard {
|
|
8
|
+
config;
|
|
9
|
+
rates = new Map();
|
|
10
|
+
concurrency = new Map();
|
|
11
|
+
constructor(config) {
|
|
12
|
+
this.config = config;
|
|
13
|
+
}
|
|
14
|
+
checkRateLimit(userId, operation) {
|
|
15
|
+
const key = `${userId}:${operation}`;
|
|
16
|
+
const now = Date.now();
|
|
17
|
+
const record = this.rates.get(key) || {
|
|
18
|
+
second: { count: 0, timestamp: now },
|
|
19
|
+
minute: { count: 0, timestamp: now },
|
|
20
|
+
};
|
|
21
|
+
// Reset counters if time window passed
|
|
22
|
+
if (now - record.second.timestamp >= 1000) {
|
|
23
|
+
record.second = { count: 0, timestamp: now };
|
|
24
|
+
}
|
|
25
|
+
if (now - record.minute.timestamp >= 60000) {
|
|
26
|
+
record.minute = { count: 0, timestamp: now };
|
|
27
|
+
}
|
|
28
|
+
// Check limits
|
|
29
|
+
if (this.config.rateLimit?.perSecond && record.second.count >= this.config.rateLimit.perSecond) {
|
|
30
|
+
throw new Error(`Rate limit exceeded: ${this.config.rateLimit.perSecond}/sec`);
|
|
31
|
+
}
|
|
32
|
+
if (this.config.rateLimit?.perMinute && record.minute.count >= this.config.rateLimit.perMinute) {
|
|
33
|
+
throw new Error(`Rate limit exceeded: ${this.config.rateLimit.perMinute}/min`);
|
|
34
|
+
}
|
|
35
|
+
// Increment counters
|
|
36
|
+
record.second.count++;
|
|
37
|
+
record.minute.count++;
|
|
38
|
+
this.rates.set(key, record);
|
|
39
|
+
}
|
|
40
|
+
acquireConcurrencySlot(userId) {
|
|
41
|
+
const current = this.concurrency.get(userId) || 0;
|
|
42
|
+
if (this.config.maxConcurrency && current >= this.config.maxConcurrency) {
|
|
43
|
+
throw new Error(`Concurrency limit exceeded: ${this.config.maxConcurrency}`);
|
|
44
|
+
}
|
|
45
|
+
this.concurrency.set(userId, current + 1);
|
|
46
|
+
}
|
|
47
|
+
releaseConcurrencySlot(userId) {
|
|
48
|
+
const current = this.concurrency.get(userId) || 0;
|
|
49
|
+
this.concurrency.set(userId, Math.max(0, current - 1));
|
|
50
|
+
}
|
|
51
|
+
checkDiskQuota(userId, usedMB) {
|
|
52
|
+
if (this.config.diskQuotaMB && usedMB > this.config.diskQuotaMB) {
|
|
53
|
+
throw new Error(`Disk quota exceeded: ${usedMB}MB/${this.config.diskQuotaMB}MB`);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=resource-guard.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resource-guard.js","sourceRoot":"","sources":["../../src/security/resource-guard.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* T-021: Multi-tenant Resource Isolation
|
|
3
|
+
* - ResourceQuota enforcement
|
|
4
|
+
* - Tenant isolation
|
|
5
|
+
* - Resource usage monitoring
|
|
6
|
+
*/
|
|
7
|
+
export interface ResourceQuota {
|
|
8
|
+
maxMemory: number;
|
|
9
|
+
maxCPU: number;
|
|
10
|
+
maxDisk: number;
|
|
11
|
+
}
|
|
12
|
+
export interface ResourceUsage {
|
|
13
|
+
memory: number;
|
|
14
|
+
cpu: number;
|
|
15
|
+
disk: number;
|
|
16
|
+
}
|
|
17
|
+
export declare class TenantIsolator {
|
|
18
|
+
private quotas;
|
|
19
|
+
private usage;
|
|
20
|
+
private guards;
|
|
21
|
+
private concurrency;
|
|
22
|
+
enforceQuota(userId: string, quota: ResourceQuota): void;
|
|
23
|
+
checkResourceUsage(userId: string): ResourceUsage;
|
|
24
|
+
isolateTenant(userId: string): void;
|
|
25
|
+
updateUsage(userId: string, usage: Partial<ResourceUsage>): void;
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=tenant-isolator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tenant-isolator.d.ts","sourceRoot":"","sources":["../../src/security/tenant-isolator.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAKH,MAAM,WAAW,aAAa;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,MAAM,CAAC;IACf,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;CACd;AAED,qBAAa,cAAc;IACzB,OAAO,CAAC,MAAM,CAAoC;IAClD,OAAO,CAAC,KAAK,CAAoC;IACjD,OAAO,CAAC,MAAM,CAAoC;IAClD,OAAO,CAAC,WAAW,CAA4B;IAE/C,YAAY,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,aAAa,GAAG,IAAI;IASxD,kBAAkB,CAAC,MAAM,EAAE,MAAM,GAAG,aAAa;IAwBjD,aAAa,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI;IAMnC,WAAW,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,GAAG,IAAI;CAIjE"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* T-021: Multi-tenant Resource Isolation
|
|
3
|
+
* - ResourceQuota enforcement
|
|
4
|
+
* - Tenant isolation
|
|
5
|
+
* - Resource usage monitoring
|
|
6
|
+
*/
|
|
7
|
+
import { ResourceGuard } from './resource-guard.js';
|
|
8
|
+
import { ConcurrencyControl } from './concurrency-control.js';
|
|
9
|
+
export class TenantIsolator {
|
|
10
|
+
quotas = new Map();
|
|
11
|
+
usage = new Map();
|
|
12
|
+
guards = new Map();
|
|
13
|
+
concurrency = new ConcurrencyControl();
|
|
14
|
+
enforceQuota(userId, quota) {
|
|
15
|
+
this.quotas.set(userId, quota);
|
|
16
|
+
this.guards.set(userId, new ResourceGuard({
|
|
17
|
+
maxConcurrency: 10,
|
|
18
|
+
diskQuotaMB: quota.maxDisk,
|
|
19
|
+
rateLimit: { perSecond: 100, perMinute: 1000 }
|
|
20
|
+
}));
|
|
21
|
+
}
|
|
22
|
+
checkResourceUsage(userId) {
|
|
23
|
+
const usage = this.usage.get(userId);
|
|
24
|
+
if (!usage) {
|
|
25
|
+
throw new Error(`No usage data for user ${userId}`);
|
|
26
|
+
}
|
|
27
|
+
const quota = this.quotas.get(userId);
|
|
28
|
+
if (!quota) {
|
|
29
|
+
throw new Error(`No quota set for user ${userId}`);
|
|
30
|
+
}
|
|
31
|
+
if (usage.memory > quota.maxMemory) {
|
|
32
|
+
throw new Error(`Memory quota exceeded: ${usage.memory}MB/${quota.maxMemory}MB`);
|
|
33
|
+
}
|
|
34
|
+
if (usage.cpu > quota.maxCPU) {
|
|
35
|
+
throw new Error(`CPU quota exceeded: ${usage.cpu}%/${quota.maxCPU}%`);
|
|
36
|
+
}
|
|
37
|
+
if (usage.disk > quota.maxDisk) {
|
|
38
|
+
throw new Error(`Disk quota exceeded: ${usage.disk}MB/${quota.maxDisk}MB`);
|
|
39
|
+
}
|
|
40
|
+
return usage;
|
|
41
|
+
}
|
|
42
|
+
isolateTenant(userId) {
|
|
43
|
+
if (!this.usage.has(userId)) {
|
|
44
|
+
this.usage.set(userId, { memory: 0, cpu: 0, disk: 0 });
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
updateUsage(userId, usage) {
|
|
48
|
+
const current = this.usage.get(userId) || { memory: 0, cpu: 0, disk: 0 };
|
|
49
|
+
this.usage.set(userId, { ...current, ...usage });
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=tenant-isolator.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tenant-isolator.js","sourceRoot":"","sources":["../../src/security/tenant-isolator.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,aAAa,EAAkB,MAAM,qBAAqB,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAc9D,MAAM,OAAO,cAAc;IACjB,MAAM,GAAG,IAAI,GAAG,EAAyB,CAAC;IAC1C,KAAK,GAAG,IAAI,GAAG,EAAyB,CAAC;IACzC,MAAM,GAAG,IAAI,GAAG,EAAyB,CAAC;IAC1C,WAAW,GAAG,IAAI,kBAAkB,EAAE,CAAC;IAE/C,YAAY,CAAC,MAAc,EAAE,KAAoB;QAC/C,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;QAC/B,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,EAAE,IAAI,aAAa,CAAC;YACxC,cAAc,EAAE,EAAE;YAClB,WAAW,EAAE,KAAK,CAAC,OAAO;YAC1B,SAAS,EAAE,EAAE,SAAS,EAAE,GAAG,EAAE,SAAS,EAAE,IAAI,EAAE;SAC/C,CAAC,CAAC,CAAC;IACN,CAAC;IAED,kBAAkB,CAAC,MAAc;QAC/B,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;QACrC,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,MAAM,IAAI,KAAK,CAAC,0BAA0B,MAAM,EAAE,CAAC,CAAC;QACtD,CAAC;QAED,MAAM,KAAK,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;QACtC,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,MAAM,IAAI,KAAK,CAAC,yBAAyB,MAAM,EAAE,CAAC,CAAC;QACrD,CAAC;QAED,IAAI,KAAK,CAAC,MAAM,GAAG,KAAK,CAAC,SAAS,EAAE,CAAC;YACnC,MAAM,IAAI,KAAK,CAAC,0BAA0B,KAAK,CAAC,MAAM,MAAM,KAAK,CAAC,SAAS,IAAI,CAAC,CAAC;QACnF,CAAC;QACD,IAAI,KAAK,CAAC,GAAG,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC;YAC7B,MAAM,IAAI,KAAK,CAAC,uBAAuB,KAAK,CAAC,GAAG,KAAK,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;QACxE,CAAC;QACD,IAAI,KAAK,CAAC,IAAI,GAAG,KAAK,CAAC,OAAO,EAAE,CAAC;YAC/B,MAAM,IAAI,KAAK,CAAC,wBAAwB,KAAK,CAAC,IAAI,MAAM,KAAK,CAAC,OAAO,IAAI,CAAC,CAAC;QAC7E,CAAC;QAED,OAAO,KAAK,CAAC;IACf,CAAC;IAED,aAAa,CAAC,MAAc;QAC1B,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC;YAC5B,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC;QACzD,CAAC;IACH,CAAC;IAED,WAAW,CAAC,MAAc,EAAE,KAA6B;QACvD,MAAM,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;QACzE,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,MAAM,EAAE,EAAE,GAAG,OAAO,EAAE,GAAG,KAAK,EAAE,CAAC,CAAC;IACnD,CAAC;CACF"}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 灾难恢复机制 - BackupManager
|
|
3
|
+
*
|
|
4
|
+
* 提供定期自动备份和 restore 命令
|
|
5
|
+
*/
|
|
6
|
+
import type { ValidMode } from '../lib/validateMode.js';
|
|
7
|
+
export interface BackupOptions {
|
|
8
|
+
directory: string;
|
|
9
|
+
maxBackups?: number;
|
|
10
|
+
backupInterval?: number;
|
|
11
|
+
}
|
|
12
|
+
export declare class BackupManager {
|
|
13
|
+
private directory;
|
|
14
|
+
private maxBackups;
|
|
15
|
+
private backupInterval;
|
|
16
|
+
private backupTimer?;
|
|
17
|
+
constructor(options: BackupOptions);
|
|
18
|
+
/**
|
|
19
|
+
* 获取备份目录路径
|
|
20
|
+
*/
|
|
21
|
+
private getBackupDir;
|
|
22
|
+
/**
|
|
23
|
+
* 确保备份目录存在
|
|
24
|
+
*/
|
|
25
|
+
private ensureBackupDir;
|
|
26
|
+
/**
|
|
27
|
+
* 获取状态文件路径
|
|
28
|
+
*/
|
|
29
|
+
private getStatePath;
|
|
30
|
+
/**
|
|
31
|
+
* 创建备份
|
|
32
|
+
*/
|
|
33
|
+
backup(mode: ValidMode, sessionId?: string): boolean;
|
|
34
|
+
/**
|
|
35
|
+
* 恢复备份
|
|
36
|
+
*/
|
|
37
|
+
restore(mode: ValidMode, timestamp?: string, sessionId?: string): boolean;
|
|
38
|
+
/**
|
|
39
|
+
* 清理旧备份
|
|
40
|
+
*/
|
|
41
|
+
private cleanOldBackups;
|
|
42
|
+
/**
|
|
43
|
+
* 列出所有备份
|
|
44
|
+
*/
|
|
45
|
+
listBackups(mode?: ValidMode, sessionId?: string): string[];
|
|
46
|
+
/**
|
|
47
|
+
* 启动自动备份
|
|
48
|
+
*/
|
|
49
|
+
startAutoBackup(modes: ValidMode[]): void;
|
|
50
|
+
/**
|
|
51
|
+
* 停止自动备份
|
|
52
|
+
*/
|
|
53
|
+
stopAutoBackup(): void;
|
|
54
|
+
}
|
|
55
|
+
export declare function createBackupManager(options: BackupOptions): BackupManager;
|
|
56
|
+
//# sourceMappingURL=backup-manager.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"backup-manager.d.ts","sourceRoot":"","sources":["../../src/state/backup-manager.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAGxD,MAAM,WAAW,aAAa;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,qBAAa,aAAa;IACxB,OAAO,CAAC,SAAS,CAAS;IAC1B,OAAO,CAAC,UAAU,CAAS;IAC3B,OAAO,CAAC,cAAc,CAAS;IAC/B,OAAO,CAAC,WAAW,CAAC,CAAiB;gBAEzB,OAAO,EAAE,aAAa;IAMlC;;OAEG;IACH,OAAO,CAAC,YAAY;IAIpB;;OAEG;IACH,OAAO,CAAC,eAAe;IAOvB;;OAEG;IACH,OAAO,CAAC,YAAY;IAQpB;;OAEG;IACH,MAAM,CAAC,IAAI,EAAE,SAAS,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,OAAO;IAsBpD;;OAEG;IACH,OAAO,CAAC,IAAI,EAAE,SAAS,EAAE,SAAS,CAAC,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,OAAO;IAuCzE;;OAEG;IACH,OAAO,CAAC,eAAe;IAuBvB;;OAEG;IACH,WAAW,CAAC,IAAI,CAAC,EAAE,SAAS,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE;IAoB3D;;OAEG;IACH,eAAe,CAAC,KAAK,EAAE,SAAS,EAAE,GAAG,IAAI;IAYzC;;OAEG;IACH,cAAc,IAAI,IAAI;CAMvB;AAED,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,aAAa,GAAG,aAAa,CAEzE"}
|