onadit 0.0.1 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.dev.md +124 -0
- package/README.md +194 -2
- package/dist/src/auth/keychain.d.ts +42 -0
- package/dist/src/auth/keychain.d.ts.map +1 -0
- package/dist/src/auth/keychain.js +177 -0
- package/dist/src/auth/keychain.js.map +1 -0
- package/dist/src/auth/middleware.d.ts +21 -0
- package/dist/src/auth/middleware.d.ts.map +1 -0
- package/dist/src/auth/middleware.js +93 -0
- package/dist/src/auth/middleware.js.map +1 -0
- package/dist/src/auth/rate-limit.d.ts +16 -0
- package/dist/src/auth/rate-limit.d.ts.map +1 -0
- package/dist/src/auth/rate-limit.js +38 -0
- package/dist/src/auth/rate-limit.js.map +1 -0
- package/dist/src/auth/rotation.d.ts +67 -0
- package/dist/src/auth/rotation.d.ts.map +1 -0
- package/dist/src/auth/rotation.js +190 -0
- package/dist/src/auth/rotation.js.map +1 -0
- package/dist/src/backfill/project-context-batch-constructor.d.ts +127 -0
- package/dist/src/backfill/project-context-batch-constructor.d.ts.map +1 -0
- package/dist/src/backfill/project-context-batch-constructor.js +210 -0
- package/dist/src/backfill/project-context-batch-constructor.js.map +1 -0
- package/dist/src/capture/assistant-text-lookup.d.ts +31 -0
- package/dist/src/capture/assistant-text-lookup.d.ts.map +1 -0
- package/dist/src/capture/assistant-text-lookup.js +222 -0
- package/dist/src/capture/assistant-text-lookup.js.map +1 -0
- package/dist/src/capture/auto-capture.d.ts +322 -0
- package/dist/src/capture/auto-capture.d.ts.map +1 -0
- package/dist/src/capture/auto-capture.js +1167 -0
- package/dist/src/capture/auto-capture.js.map +1 -0
- package/dist/src/capture/auto-repair.d.ts +125 -0
- package/dist/src/capture/auto-repair.d.ts.map +1 -0
- package/dist/src/capture/auto-repair.js +280 -0
- package/dist/src/capture/auto-repair.js.map +1 -0
- package/dist/src/capture/batch-budget.d.ts +90 -0
- package/dist/src/capture/batch-budget.d.ts.map +1 -0
- package/dist/src/capture/batch-budget.js +148 -0
- package/dist/src/capture/batch-budget.js.map +1 -0
- package/dist/src/capture/claude-cli-triage-provider.d.ts +28 -0
- package/dist/src/capture/claude-cli-triage-provider.d.ts.map +1 -0
- package/dist/src/capture/claude-cli-triage-provider.js +101 -0
- package/dist/src/capture/claude-cli-triage-provider.js.map +1 -0
- package/dist/src/capture/codex-cli-triage-provider.d.ts +17 -0
- package/dist/src/capture/codex-cli-triage-provider.d.ts.map +1 -0
- package/dist/src/capture/codex-cli-triage-provider.js +91 -0
- package/dist/src/capture/codex-cli-triage-provider.js.map +1 -0
- package/dist/src/capture/cursor-capture.d.ts +89 -0
- package/dist/src/capture/cursor-capture.d.ts.map +1 -0
- package/dist/src/capture/cursor-capture.js +121 -0
- package/dist/src/capture/cursor-capture.js.map +1 -0
- package/dist/src/capture/observability.d.ts +131 -0
- package/dist/src/capture/observability.d.ts.map +1 -0
- package/dist/src/capture/observability.js +181 -0
- package/dist/src/capture/observability.js.map +1 -0
- package/dist/src/capture/openai-triage-provider.d.ts +92 -0
- package/dist/src/capture/openai-triage-provider.d.ts.map +1 -0
- package/dist/src/capture/openai-triage-provider.js +267 -0
- package/dist/src/capture/openai-triage-provider.js.map +1 -0
- package/dist/src/capture/recover-quarantine.d.ts +273 -0
- package/dist/src/capture/recover-quarantine.d.ts.map +1 -0
- package/dist/src/capture/recover-quarantine.js +581 -0
- package/dist/src/capture/recover-quarantine.js.map +1 -0
- package/dist/src/capture/review-queue-index.d.ts +51 -0
- package/dist/src/capture/review-queue-index.d.ts.map +1 -0
- package/dist/src/capture/review-queue-index.js +204 -0
- package/dist/src/capture/review-queue-index.js.map +1 -0
- package/dist/src/capture/review-queue.d.ts +47 -0
- package/dist/src/capture/review-queue.d.ts.map +1 -0
- package/dist/src/capture/review-queue.js +116 -0
- package/dist/src/capture/review-queue.js.map +1 -0
- package/dist/src/capture/sources.d.ts +53 -0
- package/dist/src/capture/sources.d.ts.map +1 -0
- package/dist/src/capture/sources.js +55 -0
- package/dist/src/capture/sources.js.map +1 -0
- package/dist/src/capture/stored-statements.d.ts +9 -0
- package/dist/src/capture/stored-statements.d.ts.map +1 -0
- package/dist/src/capture/stored-statements.js +63 -0
- package/dist/src/capture/stored-statements.js.map +1 -0
- package/dist/src/capture/triage-classification.d.ts +92 -0
- package/dist/src/capture/triage-classification.d.ts.map +1 -0
- package/dist/src/capture/triage-classification.js +94 -0
- package/dist/src/capture/triage-classification.js.map +1 -0
- package/dist/src/capture/triage-lane.d.ts +39 -0
- package/dist/src/capture/triage-lane.d.ts.map +1 -0
- package/dist/src/capture/triage-lane.js +217 -0
- package/dist/src/capture/triage-lane.js.map +1 -0
- package/dist/src/capture/triage-provider-factory.d.ts +36 -0
- package/dist/src/capture/triage-provider-factory.d.ts.map +1 -0
- package/dist/src/capture/triage-provider-factory.js +55 -0
- package/dist/src/capture/triage-provider-factory.js.map +1 -0
- package/dist/src/capture/triage-provider.d.ts +82 -0
- package/dist/src/capture/triage-provider.d.ts.map +1 -0
- package/dist/src/capture/triage-provider.js +126 -0
- package/dist/src/capture/triage-provider.js.map +1 -0
- package/dist/src/capture/triage.d.ts +30 -0
- package/dist/src/capture/triage.d.ts.map +1 -0
- package/dist/src/capture/triage.js +50 -0
- package/dist/src/capture/triage.js.map +1 -0
- package/dist/src/capture/user-statements-recheck.d.ts +22 -0
- package/dist/src/capture/user-statements-recheck.d.ts.map +1 -0
- package/dist/src/capture/user-statements-recheck.js +181 -0
- package/dist/src/capture/user-statements-recheck.js.map +1 -0
- package/dist/src/capture/user-statements.d.ts +84 -0
- package/dist/src/capture/user-statements.d.ts.map +1 -0
- package/dist/src/capture/user-statements.js +617 -0
- package/dist/src/capture/user-statements.js.map +1 -0
- package/dist/src/cli/agent-homes.d.ts +15 -0
- package/dist/src/cli/agent-homes.d.ts.map +1 -0
- package/dist/src/cli/agent-homes.js +45 -0
- package/dist/src/cli/agent-homes.js.map +1 -0
- package/dist/src/cli/commands/backfill.d.ts +3 -0
- package/dist/src/cli/commands/backfill.d.ts.map +1 -0
- package/dist/src/cli/commands/backfill.js +1379 -0
- package/dist/src/cli/commands/backfill.js.map +1 -0
- package/dist/src/cli/commands/brief.d.ts +12 -0
- package/dist/src/cli/commands/brief.d.ts.map +1 -0
- package/dist/src/cli/commands/brief.js +131 -0
- package/dist/src/cli/commands/brief.js.map +1 -0
- package/dist/src/cli/commands/bulk-ingest.d.ts +3 -0
- package/dist/src/cli/commands/bulk-ingest.d.ts.map +1 -0
- package/dist/src/cli/commands/bulk-ingest.js +126 -0
- package/dist/src/cli/commands/bulk-ingest.js.map +1 -0
- package/dist/src/cli/commands/capture-recover.d.ts +40 -0
- package/dist/src/cli/commands/capture-recover.d.ts.map +1 -0
- package/dist/src/cli/commands/capture-recover.js +194 -0
- package/dist/src/cli/commands/capture-recover.js.map +1 -0
- package/dist/src/cli/commands/capture.d.ts +12 -0
- package/dist/src/cli/commands/capture.d.ts.map +1 -0
- package/dist/src/cli/commands/capture.js +304 -0
- package/dist/src/cli/commands/capture.js.map +1 -0
- package/dist/src/cli/commands/chunk-backfill.d.ts +13 -0
- package/dist/src/cli/commands/chunk-backfill.d.ts.map +1 -0
- package/dist/src/cli/commands/chunk-backfill.js +157 -0
- package/dist/src/cli/commands/chunk-backfill.js.map +1 -0
- package/dist/src/cli/commands/compact.d.ts +3 -0
- package/dist/src/cli/commands/compact.d.ts.map +1 -0
- package/dist/src/cli/commands/compact.js +70 -0
- package/dist/src/cli/commands/compact.js.map +1 -0
- package/dist/src/cli/commands/cursor-probe.d.ts +20 -0
- package/dist/src/cli/commands/cursor-probe.d.ts.map +1 -0
- package/dist/src/cli/commands/cursor-probe.js +162 -0
- package/dist/src/cli/commands/cursor-probe.js.map +1 -0
- package/dist/src/cli/commands/doctor.d.ts +6 -0
- package/dist/src/cli/commands/doctor.d.ts.map +1 -0
- package/dist/src/cli/commands/doctor.js +259 -0
- package/dist/src/cli/commands/doctor.js.map +1 -0
- package/dist/src/cli/commands/feedback.d.ts +34 -0
- package/dist/src/cli/commands/feedback.d.ts.map +1 -0
- package/dist/src/cli/commands/feedback.js +214 -0
- package/dist/src/cli/commands/feedback.js.map +1 -0
- package/dist/src/cli/commands/hooks-install.d.ts +66 -0
- package/dist/src/cli/commands/hooks-install.d.ts.map +1 -0
- package/dist/src/cli/commands/hooks-install.js +228 -0
- package/dist/src/cli/commands/hooks-install.js.map +1 -0
- package/dist/src/cli/commands/import.d.ts +19 -0
- package/dist/src/cli/commands/import.d.ts.map +1 -0
- package/dist/src/cli/commands/import.js +258 -0
- package/dist/src/cli/commands/import.js.map +1 -0
- package/dist/src/cli/commands/ingest.d.ts +3 -0
- package/dist/src/cli/commands/ingest.d.ts.map +1 -0
- package/dist/src/cli/commands/ingest.js +80 -0
- package/dist/src/cli/commands/ingest.js.map +1 -0
- package/dist/src/cli/commands/mcp-install.d.ts +65 -0
- package/dist/src/cli/commands/mcp-install.d.ts.map +1 -0
- package/dist/src/cli/commands/mcp-install.js +306 -0
- package/dist/src/cli/commands/mcp-install.js.map +1 -0
- package/dist/src/cli/commands/menubar.d.ts +127 -0
- package/dist/src/cli/commands/menubar.d.ts.map +1 -0
- package/dist/src/cli/commands/menubar.js +585 -0
- package/dist/src/cli/commands/menubar.js.map +1 -0
- package/dist/src/cli/commands/onboard-first-run.d.ts +5 -0
- package/dist/src/cli/commands/onboard-first-run.d.ts.map +1 -0
- package/dist/src/cli/commands/onboard-first-run.js +156 -0
- package/dist/src/cli/commands/onboard-first-run.js.map +1 -0
- package/dist/src/cli/commands/onboard.d.ts +336 -0
- package/dist/src/cli/commands/onboard.d.ts.map +1 -0
- package/dist/src/cli/commands/onboard.js +1873 -0
- package/dist/src/cli/commands/onboard.js.map +1 -0
- package/dist/src/cli/commands/rebuild.d.ts +12 -0
- package/dist/src/cli/commands/rebuild.d.ts.map +1 -0
- package/dist/src/cli/commands/rebuild.js +167 -0
- package/dist/src/cli/commands/rebuild.js.map +1 -0
- package/dist/src/cli/commands/reconcile.d.ts +3 -0
- package/dist/src/cli/commands/reconcile.d.ts.map +1 -0
- package/dist/src/cli/commands/reconcile.js +68 -0
- package/dist/src/cli/commands/reconcile.js.map +1 -0
- package/dist/src/cli/commands/reindex.d.ts +3 -0
- package/dist/src/cli/commands/reindex.d.ts.map +1 -0
- package/dist/src/cli/commands/reindex.js +66 -0
- package/dist/src/cli/commands/reindex.js.map +1 -0
- package/dist/src/cli/commands/review.d.ts +13 -0
- package/dist/src/cli/commands/review.d.ts.map +1 -0
- package/dist/src/cli/commands/review.js +401 -0
- package/dist/src/cli/commands/review.js.map +1 -0
- package/dist/src/cli/commands/save.d.ts +3 -0
- package/dist/src/cli/commands/save.d.ts.map +1 -0
- package/dist/src/cli/commands/save.js +111 -0
- package/dist/src/cli/commands/save.js.map +1 -0
- package/dist/src/cli/commands/search.d.ts +37 -0
- package/dist/src/cli/commands/search.d.ts.map +1 -0
- package/dist/src/cli/commands/search.js +118 -0
- package/dist/src/cli/commands/search.js.map +1 -0
- package/dist/src/cli/commands/setup.d.ts +30 -0
- package/dist/src/cli/commands/setup.d.ts.map +1 -0
- package/dist/src/cli/commands/setup.js +122 -0
- package/dist/src/cli/commands/setup.js.map +1 -0
- package/dist/src/cli/commands/stats.d.ts +3 -0
- package/dist/src/cli/commands/stats.d.ts.map +1 -0
- package/dist/src/cli/commands/stats.js +42 -0
- package/dist/src/cli/commands/stats.js.map +1 -0
- package/dist/src/cli/commands/status.d.ts +17 -0
- package/dist/src/cli/commands/status.d.ts.map +1 -0
- package/dist/src/cli/commands/status.js +206 -0
- package/dist/src/cli/commands/status.js.map +1 -0
- package/dist/src/cli/commands/token-issue.d.ts +3 -0
- package/dist/src/cli/commands/token-issue.d.ts.map +1 -0
- package/dist/src/cli/commands/token-issue.js +33 -0
- package/dist/src/cli/commands/token-issue.js.map +1 -0
- package/dist/src/cli/commands/triage.d.ts +3 -0
- package/dist/src/cli/commands/triage.d.ts.map +1 -0
- package/dist/src/cli/commands/triage.js +127 -0
- package/dist/src/cli/commands/triage.js.map +1 -0
- package/dist/src/cli/commands/uninstall.d.ts +85 -0
- package/dist/src/cli/commands/uninstall.d.ts.map +1 -0
- package/dist/src/cli/commands/uninstall.js +512 -0
- package/dist/src/cli/commands/uninstall.js.map +1 -0
- package/dist/src/cli/commands/update.d.ts +105 -0
- package/dist/src/cli/commands/update.d.ts.map +1 -0
- package/dist/src/cli/commands/update.js +559 -0
- package/dist/src/cli/commands/update.js.map +1 -0
- package/dist/src/cli/default-config-path.d.ts +15 -0
- package/dist/src/cli/default-config-path.d.ts.map +1 -0
- package/dist/src/cli/default-config-path.js +28 -0
- package/dist/src/cli/default-config-path.js.map +1 -0
- package/dist/src/cli/feedback/feedback-config.d.ts +67 -0
- package/dist/src/cli/feedback/feedback-config.d.ts.map +1 -0
- package/dist/src/cli/feedback/feedback-config.js +169 -0
- package/dist/src/cli/feedback/feedback-config.js.map +1 -0
- package/dist/src/cli/feedback/feedback-history.d.ts +11 -0
- package/dist/src/cli/feedback/feedback-history.d.ts.map +1 -0
- package/dist/src/cli/feedback/feedback-history.js +145 -0
- package/dist/src/cli/feedback/feedback-history.js.map +1 -0
- package/dist/src/cli/feedback/feedback-payload.d.ts +74 -0
- package/dist/src/cli/feedback/feedback-payload.d.ts.map +1 -0
- package/dist/src/cli/feedback/feedback-payload.js +10 -0
- package/dist/src/cli/feedback/feedback-payload.js.map +1 -0
- package/dist/src/cli/feedback/feedback-relay.d.ts +15 -0
- package/dist/src/cli/feedback/feedback-relay.d.ts.map +1 -0
- package/dist/src/cli/feedback/feedback-relay.js +47 -0
- package/dist/src/cli/feedback/feedback-relay.js.map +1 -0
- package/dist/src/cli/feedback/feedback-status.d.ts +11 -0
- package/dist/src/cli/feedback/feedback-status.d.ts.map +1 -0
- package/dist/src/cli/feedback/feedback-status.js +122 -0
- package/dist/src/cli/feedback/feedback-status.js.map +1 -0
- package/dist/src/cli/feedback/invite.d.ts +17 -0
- package/dist/src/cli/feedback/invite.d.ts.map +1 -0
- package/dist/src/cli/feedback/invite.js +73 -0
- package/dist/src/cli/feedback/invite.js.map +1 -0
- package/dist/src/cli/feedback/relay-secret-store.d.ts +32 -0
- package/dist/src/cli/feedback/relay-secret-store.d.ts.map +1 -0
- package/dist/src/cli/feedback/relay-secret-store.js +137 -0
- package/dist/src/cli/feedback/relay-secret-store.js.map +1 -0
- package/dist/src/cli/hooks-writers/claude-code-policy-script.d.ts +35 -0
- package/dist/src/cli/hooks-writers/claude-code-policy-script.d.ts.map +1 -0
- package/dist/src/cli/hooks-writers/claude-code-policy-script.js +122 -0
- package/dist/src/cli/hooks-writers/claude-code-policy-script.js.map +1 -0
- package/dist/src/cli/hooks-writers/claude-code.d.ts +63 -0
- package/dist/src/cli/hooks-writers/claude-code.d.ts.map +1 -0
- package/dist/src/cli/hooks-writers/claude-code.js +289 -0
- package/dist/src/cli/hooks-writers/claude-code.js.map +1 -0
- package/dist/src/cli/hooks-writers/codex.d.ts +16 -0
- package/dist/src/cli/hooks-writers/codex.d.ts.map +1 -0
- package/dist/src/cli/hooks-writers/codex.js +17 -0
- package/dist/src/cli/hooks-writers/codex.js.map +1 -0
- package/dist/src/cli/hooks-writers/errors.d.ts +16 -0
- package/dist/src/cli/hooks-writers/errors.d.ts.map +1 -0
- package/dist/src/cli/hooks-writers/errors.js +24 -0
- package/dist/src/cli/hooks-writers/errors.js.map +1 -0
- package/dist/src/cli/hooks-writers/index.d.ts +23 -0
- package/dist/src/cli/hooks-writers/index.d.ts.map +1 -0
- package/dist/src/cli/hooks-writers/index.js +34 -0
- package/dist/src/cli/hooks-writers/index.js.map +1 -0
- package/dist/src/cli/hooks-writers/state.d.ts +43 -0
- package/dist/src/cli/hooks-writers/state.d.ts.map +1 -0
- package/dist/src/cli/hooks-writers/state.js +225 -0
- package/dist/src/cli/hooks-writers/state.js.map +1 -0
- package/dist/src/cli/hooks-writers/types.d.ts +28 -0
- package/dist/src/cli/hooks-writers/types.d.ts.map +1 -0
- package/dist/src/cli/hooks-writers/types.js +8 -0
- package/dist/src/cli/hooks-writers/types.js.map +1 -0
- package/dist/src/cli/http-client.d.ts +128 -0
- package/dist/src/cli/http-client.d.ts.map +1 -0
- package/dist/src/cli/http-client.js +401 -0
- package/dist/src/cli/http-client.js.map +1 -0
- package/dist/src/cli/index.d.ts +4 -0
- package/dist/src/cli/index.d.ts.map +1 -0
- package/dist/src/cli/index.js +99 -0
- package/dist/src/cli/index.js.map +1 -0
- package/dist/src/cli/job-poller.d.ts +13 -0
- package/dist/src/cli/job-poller.d.ts.map +1 -0
- package/dist/src/cli/job-poller.js +29 -0
- package/dist/src/cli/job-poller.js.map +1 -0
- package/dist/src/cli/mcp-config-writers/codex-toml.d.ts +20 -0
- package/dist/src/cli/mcp-config-writers/codex-toml.d.ts.map +1 -0
- package/dist/src/cli/mcp-config-writers/codex-toml.js +918 -0
- package/dist/src/cli/mcp-config-writers/codex-toml.js.map +1 -0
- package/dist/src/cli/mcp-config-writers/earlier-name-restrictions.d.ts +11 -0
- package/dist/src/cli/mcp-config-writers/earlier-name-restrictions.d.ts.map +1 -0
- package/dist/src/cli/mcp-config-writers/earlier-name-restrictions.js +152 -0
- package/dist/src/cli/mcp-config-writers/earlier-name-restrictions.js.map +1 -0
- package/dist/src/cli/mcp-config-writers/errors.d.ts +17 -0
- package/dist/src/cli/mcp-config-writers/errors.d.ts.map +1 -0
- package/dist/src/cli/mcp-config-writers/errors.js +13 -0
- package/dist/src/cli/mcp-config-writers/errors.js.map +1 -0
- package/dist/src/cli/mcp-config-writers/index.d.ts +28 -0
- package/dist/src/cli/mcp-config-writers/index.d.ts.map +1 -0
- package/dist/src/cli/mcp-config-writers/index.js +70 -0
- package/dist/src/cli/mcp-config-writers/index.js.map +1 -0
- package/dist/src/cli/mcp-config-writers/json-config.d.ts +20 -0
- package/dist/src/cli/mcp-config-writers/json-config.d.ts.map +1 -0
- package/dist/src/cli/mcp-config-writers/json-config.js +301 -0
- package/dist/src/cli/mcp-config-writers/json-config.js.map +1 -0
- package/dist/src/cli/mcp-config-writers/left-in-folder.d.ts +18 -0
- package/dist/src/cli/mcp-config-writers/left-in-folder.d.ts.map +1 -0
- package/dist/src/cli/mcp-config-writers/left-in-folder.js +140 -0
- package/dist/src/cli/mcp-config-writers/left-in-folder.js.map +1 -0
- package/dist/src/cli/mcp-config-writers/redact.d.ts +28 -0
- package/dist/src/cli/mcp-config-writers/redact.d.ts.map +1 -0
- package/dist/src/cli/mcp-config-writers/redact.js +48 -0
- package/dist/src/cli/mcp-config-writers/redact.js.map +1 -0
- package/dist/src/cli/mcp-config-writers/types.d.ts +46 -0
- package/dist/src/cli/mcp-config-writers/types.d.ts.map +1 -0
- package/dist/src/cli/mcp-config-writers/types.js +5 -0
- package/dist/src/cli/mcp-config-writers/types.js.map +1 -0
- package/dist/src/cli/output.d.ts +8 -0
- package/dist/src/cli/output.d.ts.map +1 -0
- package/dist/src/cli/output.js +34 -0
- package/dist/src/cli/output.js.map +1 -0
- package/dist/src/cli/postinstall-menubar.d.ts +38 -0
- package/dist/src/cli/postinstall-menubar.d.ts.map +1 -0
- package/dist/src/cli/postinstall-menubar.js +139 -0
- package/dist/src/cli/postinstall-menubar.js.map +1 -0
- package/dist/src/cli/status/friend-header.d.ts +61 -0
- package/dist/src/cli/status/friend-header.d.ts.map +1 -0
- package/dist/src/cli/status/friend-header.js +727 -0
- package/dist/src/cli/status/friend-header.js.map +1 -0
- package/dist/src/cli/status/local-signals.d.ts +89 -0
- package/dist/src/cli/status/local-signals.d.ts.map +1 -0
- package/dist/src/cli/status/local-signals.js +194 -0
- package/dist/src/cli/status/local-signals.js.map +1 -0
- package/dist/src/cli/token.d.ts +37 -0
- package/dist/src/cli/token.d.ts.map +1 -0
- package/dist/src/cli/token.js +105 -0
- package/dist/src/cli/token.js.map +1 -0
- package/dist/src/cli/ui.d.ts +47 -0
- package/dist/src/cli/ui.d.ts.map +1 -0
- package/dist/src/cli/ui.js +166 -0
- package/dist/src/cli/ui.js.map +1 -0
- package/dist/src/cli/uninstall/mcp-uninstall.d.ts +33 -0
- package/dist/src/cli/uninstall/mcp-uninstall.d.ts.map +1 -0
- package/dist/src/cli/uninstall/mcp-uninstall.js +116 -0
- package/dist/src/cli/uninstall/mcp-uninstall.js.map +1 -0
- package/dist/src/config/loader.d.ts +9 -0
- package/dist/src/config/loader.d.ts.map +1 -0
- package/dist/src/config/loader.js +73 -0
- package/dist/src/config/loader.js.map +1 -0
- package/dist/src/config/schema.d.ts +956 -0
- package/dist/src/config/schema.d.ts.map +1 -0
- package/dist/src/config/schema.js +339 -0
- package/dist/src/config/schema.js.map +1 -0
- package/dist/src/diagnostics/claude-preflight.d.ts +35 -0
- package/dist/src/diagnostics/claude-preflight.d.ts.map +1 -0
- package/dist/src/diagnostics/claude-preflight.js +90 -0
- package/dist/src/diagnostics/claude-preflight.js.map +1 -0
- package/dist/src/diagnostics/codex-preflight.d.ts +43 -0
- package/dist/src/diagnostics/codex-preflight.d.ts.map +1 -0
- package/dist/src/diagnostics/codex-preflight.js +128 -0
- package/dist/src/diagnostics/codex-preflight.js.map +1 -0
- package/dist/src/diagnostics/doctor.d.ts +125 -0
- package/dist/src/diagnostics/doctor.d.ts.map +1 -0
- package/dist/src/diagnostics/doctor.js +450 -0
- package/dist/src/diagnostics/doctor.js.map +1 -0
- package/dist/src/diagnostics/install-layout.d.ts +40 -0
- package/dist/src/diagnostics/install-layout.d.ts.map +1 -0
- package/dist/src/diagnostics/install-layout.js +55 -0
- package/dist/src/diagnostics/install-layout.js.map +1 -0
- package/dist/src/diagnostics/memory-coverage.d.ts +54 -0
- package/dist/src/diagnostics/memory-coverage.d.ts.map +1 -0
- package/dist/src/diagnostics/memory-coverage.js +272 -0
- package/dist/src/diagnostics/memory-coverage.js.map +1 -0
- package/dist/src/diagnostics/notify.d.ts +107 -0
- package/dist/src/diagnostics/notify.d.ts.map +1 -0
- package/dist/src/diagnostics/notify.js +217 -0
- package/dist/src/diagnostics/notify.js.map +1 -0
- package/dist/src/diagnostics/repair-prompt.d.ts +49 -0
- package/dist/src/diagnostics/repair-prompt.d.ts.map +1 -0
- package/dist/src/diagnostics/repair-prompt.js +223 -0
- package/dist/src/diagnostics/repair-prompt.js.map +1 -0
- package/dist/src/ingestion/bulk-ingest.d.ts +11 -0
- package/dist/src/ingestion/bulk-ingest.d.ts.map +1 -0
- package/dist/src/ingestion/bulk-ingest.js +11 -0
- package/dist/src/ingestion/bulk-ingest.js.map +1 -0
- package/dist/src/ingestion/chunk-meta.d.ts +85 -0
- package/dist/src/ingestion/chunk-meta.d.ts.map +1 -0
- package/dist/src/ingestion/chunk-meta.js +167 -0
- package/dist/src/ingestion/chunk-meta.js.map +1 -0
- package/dist/src/ingestion/chunk-text.d.ts +39 -0
- package/dist/src/ingestion/chunk-text.d.ts.map +1 -0
- package/dist/src/ingestion/chunk-text.js +114 -0
- package/dist/src/ingestion/chunk-text.js.map +1 -0
- package/dist/src/ingestion/cursor/cursor-store.d.ts +177 -0
- package/dist/src/ingestion/cursor/cursor-store.d.ts.map +1 -0
- package/dist/src/ingestion/cursor/cursor-store.js +242 -0
- package/dist/src/ingestion/cursor/cursor-store.js.map +1 -0
- package/dist/src/ingestion/cursor/enrich-roots.d.ts +16 -0
- package/dist/src/ingestion/cursor/enrich-roots.d.ts.map +1 -0
- package/dist/src/ingestion/cursor/enrich-roots.js +22 -0
- package/dist/src/ingestion/cursor/enrich-roots.js.map +1 -0
- package/dist/src/ingestion/cursor/vscdb-reader.d.ts +32 -0
- package/dist/src/ingestion/cursor/vscdb-reader.d.ts.map +1 -0
- package/dist/src/ingestion/cursor/vscdb-reader.js +113 -0
- package/dist/src/ingestion/cursor/vscdb-reader.js.map +1 -0
- package/dist/src/ingestion/cursor/workspace-root.d.ts +96 -0
- package/dist/src/ingestion/cursor/workspace-root.d.ts.map +1 -0
- package/dist/src/ingestion/cursor/workspace-root.js +187 -0
- package/dist/src/ingestion/cursor/workspace-root.js.map +1 -0
- package/dist/src/ingestion/extractor.d.ts +16 -0
- package/dist/src/ingestion/extractor.d.ts.map +1 -0
- package/dist/src/ingestion/extractor.js +85 -0
- package/dist/src/ingestion/extractor.js.map +1 -0
- package/dist/src/ingestion/extractors/docx.d.ts +3 -0
- package/dist/src/ingestion/extractors/docx.d.ts.map +1 -0
- package/dist/src/ingestion/extractors/docx.js +20 -0
- package/dist/src/ingestion/extractors/docx.js.map +1 -0
- package/dist/src/ingestion/extractors/pdf.d.ts +3 -0
- package/dist/src/ingestion/extractors/pdf.d.ts.map +1 -0
- package/dist/src/ingestion/extractors/pdf.js +32 -0
- package/dist/src/ingestion/extractors/pdf.js.map +1 -0
- package/dist/src/ingestion/historical-campaign.d.ts +340 -0
- package/dist/src/ingestion/historical-campaign.d.ts.map +1 -0
- package/dist/src/ingestion/historical-campaign.js +1010 -0
- package/dist/src/ingestion/historical-campaign.js.map +1 -0
- package/dist/src/ingestion/ignored-paths.d.ts +20 -0
- package/dist/src/ingestion/ignored-paths.d.ts.map +1 -0
- package/dist/src/ingestion/ignored-paths.js +45 -0
- package/dist/src/ingestion/ignored-paths.js.map +1 -0
- package/dist/src/ingestion/inbox-core/conversation-fingerprint.d.ts +2 -0
- package/dist/src/ingestion/inbox-core/conversation-fingerprint.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-core/conversation-fingerprint.js +27 -0
- package/dist/src/ingestion/inbox-core/conversation-fingerprint.js.map +1 -0
- package/dist/src/ingestion/inbox-core/conversation-key.d.ts +2 -0
- package/dist/src/ingestion/inbox-core/conversation-key.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-core/conversation-key.js +31 -0
- package/dist/src/ingestion/inbox-core/conversation-key.js.map +1 -0
- package/dist/src/ingestion/inbox-core/extensions.d.ts +3 -0
- package/dist/src/ingestion/inbox-core/extensions.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-core/extensions.js +16 -0
- package/dist/src/ingestion/inbox-core/extensions.js.map +1 -0
- package/dist/src/ingestion/inbox-core/idempotency.d.ts +2 -0
- package/dist/src/ingestion/inbox-core/idempotency.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-core/idempotency.js +22 -0
- package/dist/src/ingestion/inbox-core/idempotency.js.map +1 -0
- package/dist/src/ingestion/inbox-core/index.d.ts +20 -0
- package/dist/src/ingestion/inbox-core/index.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-core/index.js +20 -0
- package/dist/src/ingestion/inbox-core/index.js.map +1 -0
- package/dist/src/ingestion/inbox-core/source-detection.d.ts +2 -0
- package/dist/src/ingestion/inbox-core/source-detection.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-core/source-detection.js +23 -0
- package/dist/src/ingestion/inbox-core/source-detection.js.map +1 -0
- package/dist/src/ingestion/inbox-core/source-sniffer.d.ts +11 -0
- package/dist/src/ingestion/inbox-core/source-sniffer.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-core/source-sniffer.js +69 -0
- package/dist/src/ingestion/inbox-core/source-sniffer.js.map +1 -0
- package/dist/src/ingestion/inbox-core/zip-sniffer.d.ts +70 -0
- package/dist/src/ingestion/inbox-core/zip-sniffer.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-core/zip-sniffer.js +161 -0
- package/dist/src/ingestion/inbox-core/zip-sniffer.js.map +1 -0
- package/dist/src/ingestion/inbox-watcher.d.ts +12 -0
- package/dist/src/ingestion/inbox-watcher.d.ts.map +1 -0
- package/dist/src/ingestion/inbox-watcher.js +83 -0
- package/dist/src/ingestion/inbox-watcher.js.map +1 -0
- package/dist/src/ingestion/indexer.d.ts +39 -0
- package/dist/src/ingestion/indexer.d.ts.map +1 -0
- package/dist/src/ingestion/indexer.js +111 -0
- package/dist/src/ingestion/indexer.js.map +1 -0
- package/dist/src/ingestion/metadata-extraction.d.ts +56 -0
- package/dist/src/ingestion/metadata-extraction.d.ts.map +1 -0
- package/dist/src/ingestion/metadata-extraction.js +151 -0
- package/dist/src/ingestion/metadata-extraction.js.map +1 -0
- package/dist/src/ingestion/parsers/chatgpt-web.d.ts +29 -0
- package/dist/src/ingestion/parsers/chatgpt-web.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/chatgpt-web.js +100 -0
- package/dist/src/ingestion/parsers/chatgpt-web.js.map +1 -0
- package/dist/src/ingestion/parsers/claude-code-jsonl.d.ts +26 -0
- package/dist/src/ingestion/parsers/claude-code-jsonl.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/claude-code-jsonl.js +125 -0
- package/dist/src/ingestion/parsers/claude-code-jsonl.js.map +1 -0
- package/dist/src/ingestion/parsers/claude-desktop-sessions.d.ts +17 -0
- package/dist/src/ingestion/parsers/claude-desktop-sessions.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/claude-desktop-sessions.js +112 -0
- package/dist/src/ingestion/parsers/claude-desktop-sessions.js.map +1 -0
- package/dist/src/ingestion/parsers/claude-web.d.ts +24 -0
- package/dist/src/ingestion/parsers/claude-web.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/claude-web.js +75 -0
- package/dist/src/ingestion/parsers/claude-web.js.map +1 -0
- package/dist/src/ingestion/parsers/codex-jsonl.d.ts +18 -0
- package/dist/src/ingestion/parsers/codex-jsonl.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/codex-jsonl.js +150 -0
- package/dist/src/ingestion/parsers/codex-jsonl.js.map +1 -0
- package/dist/src/ingestion/parsers/gemini-web.d.ts +16 -0
- package/dist/src/ingestion/parsers/gemini-web.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/gemini-web.js +170 -0
- package/dist/src/ingestion/parsers/gemini-web.js.map +1 -0
- package/dist/src/ingestion/parsers/grok-cli.d.ts +19 -0
- package/dist/src/ingestion/parsers/grok-cli.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/grok-cli.js +126 -0
- package/dist/src/ingestion/parsers/grok-cli.js.map +1 -0
- package/dist/src/ingestion/parsers/grok-web.d.ts +40 -0
- package/dist/src/ingestion/parsers/grok-web.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/grok-web.js +67 -0
- package/dist/src/ingestion/parsers/grok-web.js.map +1 -0
- package/dist/src/ingestion/parsers/turns.d.ts +36 -0
- package/dist/src/ingestion/parsers/turns.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/turns.js +25 -0
- package/dist/src/ingestion/parsers/turns.js.map +1 -0
- package/dist/src/ingestion/parsers/types.d.ts +47 -0
- package/dist/src/ingestion/parsers/types.d.ts.map +1 -0
- package/dist/src/ingestion/parsers/types.js +26 -0
- package/dist/src/ingestion/parsers/types.js.map +1 -0
- package/dist/src/ingestion/report-cards.d.ts +75 -0
- package/dist/src/ingestion/report-cards.d.ts.map +1 -0
- package/dist/src/ingestion/report-cards.js +224 -0
- package/dist/src/ingestion/report-cards.js.map +1 -0
- package/dist/src/ingestion/scanner.d.ts +48 -0
- package/dist/src/ingestion/scanner.d.ts.map +1 -0
- package/dist/src/ingestion/scanner.js +131 -0
- package/dist/src/ingestion/scanner.js.map +1 -0
- package/dist/src/ingestion/skip-quarantine.d.ts +10 -0
- package/dist/src/ingestion/skip-quarantine.d.ts.map +1 -0
- package/dist/src/ingestion/skip-quarantine.js +35 -0
- package/dist/src/ingestion/skip-quarantine.js.map +1 -0
- package/dist/src/ingestion/staging.d.ts +109 -0
- package/dist/src/ingestion/staging.d.ts.map +1 -0
- package/dist/src/ingestion/staging.js +411 -0
- package/dist/src/ingestion/staging.js.map +1 -0
- package/dist/src/ingestion/watcher.d.ts +65 -0
- package/dist/src/ingestion/watcher.d.ts.map +1 -0
- package/dist/src/ingestion/watcher.js +182 -0
- package/dist/src/ingestion/watcher.js.map +1 -0
- package/dist/src/jobs/codex-override-handler.d.ts +3 -0
- package/dist/src/jobs/codex-override-handler.d.ts.map +1 -0
- package/dist/src/jobs/codex-override-handler.js +16 -0
- package/dist/src/jobs/codex-override-handler.js.map +1 -0
- package/dist/src/jobs/handlers/compact.d.ts +30 -0
- package/dist/src/jobs/handlers/compact.d.ts.map +1 -0
- package/dist/src/jobs/handlers/compact.js +360 -0
- package/dist/src/jobs/handlers/compact.js.map +1 -0
- package/dist/src/jobs/handlers/dedupe-conversations.d.ts +134 -0
- package/dist/src/jobs/handlers/dedupe-conversations.d.ts.map +1 -0
- package/dist/src/jobs/handlers/dedupe-conversations.js +371 -0
- package/dist/src/jobs/handlers/dedupe-conversations.js.map +1 -0
- package/dist/src/jobs/handlers/ingest.d.ts +13 -0
- package/dist/src/jobs/handlers/ingest.d.ts.map +1 -0
- package/dist/src/jobs/handlers/ingest.js +557 -0
- package/dist/src/jobs/handlers/ingest.js.map +1 -0
- package/dist/src/jobs/handlers/optimize.d.ts +11 -0
- package/dist/src/jobs/handlers/optimize.d.ts.map +1 -0
- package/dist/src/jobs/handlers/optimize.js +12 -0
- package/dist/src/jobs/handlers/optimize.js.map +1 -0
- package/dist/src/jobs/handlers/reconcile.d.ts +57 -0
- package/dist/src/jobs/handlers/reconcile.d.ts.map +1 -0
- package/dist/src/jobs/handlers/reconcile.js +685 -0
- package/dist/src/jobs/handlers/reconcile.js.map +1 -0
- package/dist/src/jobs/handlers/reindex.d.ts +38 -0
- package/dist/src/jobs/handlers/reindex.d.ts.map +1 -0
- package/dist/src/jobs/handlers/reindex.js +63 -0
- package/dist/src/jobs/handlers/reindex.js.map +1 -0
- package/dist/src/jobs/handlers/save.d.ts +10 -0
- package/dist/src/jobs/handlers/save.d.ts.map +1 -0
- package/dist/src/jobs/handlers/save.js +316 -0
- package/dist/src/jobs/handlers/save.js.map +1 -0
- package/dist/src/jobs/handlers/triage.d.ts +47 -0
- package/dist/src/jobs/handlers/triage.d.ts.map +1 -0
- package/dist/src/jobs/handlers/triage.js +95 -0
- package/dist/src/jobs/handlers/triage.js.map +1 -0
- package/dist/src/jobs/maintenance-scheduler.d.ts +30 -0
- package/dist/src/jobs/maintenance-scheduler.d.ts.map +1 -0
- package/dist/src/jobs/maintenance-scheduler.js +41 -0
- package/dist/src/jobs/maintenance-scheduler.js.map +1 -0
- package/dist/src/jobs/queue.d.ts +157 -0
- package/dist/src/jobs/queue.d.ts.map +1 -0
- package/dist/src/jobs/queue.js +759 -0
- package/dist/src/jobs/queue.js.map +1 -0
- package/dist/src/jobs/types.d.ts +53 -0
- package/dist/src/jobs/types.d.ts.map +1 -0
- package/dist/src/jobs/types.js +33 -0
- package/dist/src/jobs/types.js.map +1 -0
- package/dist/src/jobs/worker-entry.d.ts +10 -0
- package/dist/src/jobs/worker-entry.d.ts.map +1 -0
- package/dist/src/jobs/worker-entry.js +252 -0
- package/dist/src/jobs/worker-entry.js.map +1 -0
- package/dist/src/jobs/worker-process.d.ts +67 -0
- package/dist/src/jobs/worker-process.d.ts.map +1 -0
- package/dist/src/jobs/worker-process.js +227 -0
- package/dist/src/jobs/worker-process.js.map +1 -0
- package/dist/src/jobs/worker.d.ts +11 -0
- package/dist/src/jobs/worker.d.ts.map +1 -0
- package/dist/src/jobs/worker.js +14 -0
- package/dist/src/jobs/worker.js.map +1 -0
- package/dist/src/main.d.ts +2 -0
- package/dist/src/main.d.ts.map +1 -0
- package/dist/src/main.js +683 -0
- package/dist/src/main.js.map +1 -0
- package/dist/src/mcp/capture-diagnostics.d.ts +51 -0
- package/dist/src/mcp/capture-diagnostics.d.ts.map +1 -0
- package/dist/src/mcp/capture-diagnostics.js +127 -0
- package/dist/src/mcp/capture-diagnostics.js.map +1 -0
- package/dist/src/mcp/errors.d.ts +8 -0
- package/dist/src/mcp/errors.d.ts.map +1 -0
- package/dist/src/mcp/errors.js +69 -0
- package/dist/src/mcp/errors.js.map +1 -0
- package/dist/src/mcp/memory-diagnostics.d.ts +6 -0
- package/dist/src/mcp/memory-diagnostics.d.ts.map +1 -0
- package/dist/src/mcp/memory-diagnostics.js +51 -0
- package/dist/src/mcp/memory-diagnostics.js.map +1 -0
- package/dist/src/mcp/names.d.ts +48 -0
- package/dist/src/mcp/names.d.ts.map +1 -0
- package/dist/src/mcp/names.js +77 -0
- package/dist/src/mcp/names.js.map +1 -0
- package/dist/src/mcp/server.d.ts +19 -0
- package/dist/src/mcp/server.d.ts.map +1 -0
- package/dist/src/mcp/server.js +184 -0
- package/dist/src/mcp/server.js.map +1 -0
- package/dist/src/mcp/stdio.d.ts +2 -0
- package/dist/src/mcp/stdio.d.ts.map +1 -0
- package/dist/src/mcp/stdio.js +8 -0
- package/dist/src/mcp/stdio.js.map +1 -0
- package/dist/src/mcp/tools/context-pack.d.ts +35 -0
- package/dist/src/mcp/tools/context-pack.d.ts.map +1 -0
- package/dist/src/mcp/tools/context-pack.js +279 -0
- package/dist/src/mcp/tools/context-pack.js.map +1 -0
- package/dist/src/mcp/tools/conversations-search.d.ts +38 -0
- package/dist/src/mcp/tools/conversations-search.d.ts.map +1 -0
- package/dist/src/mcp/tools/conversations-search.js +79 -0
- package/dist/src/mcp/tools/conversations-search.js.map +1 -0
- package/dist/src/mcp/tools/evidence-feedback.d.ts +60 -0
- package/dist/src/mcp/tools/evidence-feedback.d.ts.map +1 -0
- package/dist/src/mcp/tools/evidence-feedback.js +62 -0
- package/dist/src/mcp/tools/evidence-feedback.js.map +1 -0
- package/dist/src/mcp/tools/log-outcome.d.ts +72 -0
- package/dist/src/mcp/tools/log-outcome.d.ts.map +1 -0
- package/dist/src/mcp/tools/log-outcome.js +59 -0
- package/dist/src/mcp/tools/log-outcome.js.map +1 -0
- package/dist/src/mcp/tools/open-evidence.d.ts +37 -0
- package/dist/src/mcp/tools/open-evidence.d.ts.map +1 -0
- package/dist/src/mcp/tools/open-evidence.js +72 -0
- package/dist/src/mcp/tools/open-evidence.js.map +1 -0
- package/dist/src/mcp/tools/save.d.ts +37 -0
- package/dist/src/mcp/tools/save.d.ts.map +1 -0
- package/dist/src/mcp/tools/save.js +65 -0
- package/dist/src/mcp/tools/save.js.map +1 -0
- package/dist/src/mcp/tools/search.d.ts +37 -0
- package/dist/src/mcp/tools/search.d.ts.map +1 -0
- package/dist/src/mcp/tools/search.js +95 -0
- package/dist/src/mcp/tools/search.js.map +1 -0
- package/dist/src/mcp/tools/status.d.ts +31 -0
- package/dist/src/mcp/tools/status.d.ts.map +1 -0
- package/dist/src/mcp/tools/status.js +63 -0
- package/dist/src/mcp/tools/status.js.map +1 -0
- package/dist/src/observability/coverage.d.ts +100 -0
- package/dist/src/observability/coverage.d.ts.map +1 -0
- package/dist/src/observability/coverage.js +178 -0
- package/dist/src/observability/coverage.js.map +1 -0
- package/dist/src/observability/embedding-events.d.ts +52 -0
- package/dist/src/observability/embedding-events.d.ts.map +1 -0
- package/dist/src/observability/embedding-events.js +149 -0
- package/dist/src/observability/embedding-events.js.map +1 -0
- package/dist/src/observability/index-events.d.ts +70 -0
- package/dist/src/observability/index-events.d.ts.map +1 -0
- package/dist/src/observability/index-events.js +148 -0
- package/dist/src/observability/index-events.js.map +1 -0
- package/dist/src/observability/onboarding-metric.d.ts +131 -0
- package/dist/src/observability/onboarding-metric.d.ts.map +1 -0
- package/dist/src/observability/onboarding-metric.js +352 -0
- package/dist/src/observability/onboarding-metric.js.map +1 -0
- package/dist/src/observability/retrieval-feedback.d.ts +82 -0
- package/dist/src/observability/retrieval-feedback.d.ts.map +1 -0
- package/dist/src/observability/retrieval-feedback.js +231 -0
- package/dist/src/observability/retrieval-feedback.js.map +1 -0
- package/dist/src/observability/rift-context.d.ts +53 -0
- package/dist/src/observability/rift-context.d.ts.map +1 -0
- package/dist/src/observability/rift-context.js +141 -0
- package/dist/src/observability/rift-context.js.map +1 -0
- package/dist/src/observability/staleness.d.ts +43 -0
- package/dist/src/observability/staleness.d.ts.map +1 -0
- package/dist/src/observability/staleness.js +74 -0
- package/dist/src/observability/staleness.js.map +1 -0
- package/dist/src/observability/tool-usage-stats.d.ts +139 -0
- package/dist/src/observability/tool-usage-stats.d.ts.map +1 -0
- package/dist/src/observability/tool-usage-stats.js +245 -0
- package/dist/src/observability/tool-usage-stats.js.map +1 -0
- package/dist/src/observability/tool-usage.d.ts +231 -0
- package/dist/src/observability/tool-usage.d.ts.map +1 -0
- package/dist/src/observability/tool-usage.js +489 -0
- package/dist/src/observability/tool-usage.js.map +1 -0
- package/dist/src/observability/version-check.d.ts +75 -0
- package/dist/src/observability/version-check.d.ts.map +1 -0
- package/dist/src/observability/version-check.js +198 -0
- package/dist/src/observability/version-check.js.map +1 -0
- package/dist/src/onboarding/capture-switch.d.ts +20 -0
- package/dist/src/onboarding/capture-switch.d.ts.map +1 -0
- package/dist/src/onboarding/capture-switch.js +52 -0
- package/dist/src/onboarding/capture-switch.js.map +1 -0
- package/dist/src/onboarding/daemon-control.d.ts +33 -0
- package/dist/src/onboarding/daemon-control.d.ts.map +1 -0
- package/dist/src/onboarding/daemon-control.js +92 -0
- package/dist/src/onboarding/daemon-control.js.map +1 -0
- package/dist/src/onboarding/env-file.d.ts +18 -0
- package/dist/src/onboarding/env-file.d.ts.map +1 -0
- package/dist/src/onboarding/env-file.js +89 -0
- package/dist/src/onboarding/env-file.js.map +1 -0
- package/dist/src/onboarding/search-by-meaning.d.ts +35 -0
- package/dist/src/onboarding/search-by-meaning.d.ts.map +1 -0
- package/dist/src/onboarding/search-by-meaning.js +163 -0
- package/dist/src/onboarding/search-by-meaning.js.map +1 -0
- package/dist/src/onboarding/setup-page.d.ts +7 -0
- package/dist/src/onboarding/setup-page.d.ts.map +1 -0
- package/dist/src/onboarding/setup-page.js +823 -0
- package/dist/src/onboarding/setup-page.js.map +1 -0
- package/dist/src/onboarding/setup-session.d.ts +22 -0
- package/dist/src/onboarding/setup-session.d.ts.map +1 -0
- package/dist/src/onboarding/setup-session.js +80 -0
- package/dist/src/onboarding/setup-session.js.map +1 -0
- package/dist/src/onboarding/setup-state.d.ts +117 -0
- package/dist/src/onboarding/setup-state.d.ts.map +1 -0
- package/dist/src/onboarding/setup-state.js +267 -0
- package/dist/src/onboarding/setup-state.js.map +1 -0
- package/dist/src/onboarding/voyage-validate.d.ts +22 -0
- package/dist/src/onboarding/voyage-validate.d.ts.map +1 -0
- package/dist/src/onboarding/voyage-validate.js +96 -0
- package/dist/src/onboarding/voyage-validate.js.map +1 -0
- package/dist/src/providers/anthropic-digest.d.ts +23 -0
- package/dist/src/providers/anthropic-digest.d.ts.map +1 -0
- package/dist/src/providers/anthropic-digest.js +91 -0
- package/dist/src/providers/anthropic-digest.js.map +1 -0
- package/dist/src/providers/basic-metadata-extraction.d.ts +60 -0
- package/dist/src/providers/basic-metadata-extraction.d.ts.map +1 -0
- package/dist/src/providers/basic-metadata-extraction.js +114 -0
- package/dist/src/providers/basic-metadata-extraction.js.map +1 -0
- package/dist/src/providers/claude-cli-metadata-extraction.d.ts +47 -0
- package/dist/src/providers/claude-cli-metadata-extraction.d.ts.map +1 -0
- package/dist/src/providers/claude-cli-metadata-extraction.js +130 -0
- package/dist/src/providers/claude-cli-metadata-extraction.js.map +1 -0
- package/dist/src/providers/claude-cli-runner.d.ts +92 -0
- package/dist/src/providers/claude-cli-runner.d.ts.map +1 -0
- package/dist/src/providers/claude-cli-runner.js +598 -0
- package/dist/src/providers/claude-cli-runner.js.map +1 -0
- package/dist/src/providers/claude-input-limit.d.ts +32 -0
- package/dist/src/providers/claude-input-limit.d.ts.map +1 -0
- package/dist/src/providers/claude-input-limit.js +32 -0
- package/dist/src/providers/claude-input-limit.js.map +1 -0
- package/dist/src/providers/codex-cli-digest.d.ts +12 -0
- package/dist/src/providers/codex-cli-digest.d.ts.map +1 -0
- package/dist/src/providers/codex-cli-digest.js +70 -0
- package/dist/src/providers/codex-cli-digest.js.map +1 -0
- package/dist/src/providers/codex-cli-metadata-extraction.d.ts +15 -0
- package/dist/src/providers/codex-cli-metadata-extraction.d.ts.map +1 -0
- package/dist/src/providers/codex-cli-metadata-extraction.js +78 -0
- package/dist/src/providers/codex-cli-metadata-extraction.js.map +1 -0
- package/dist/src/providers/codex-cli-model.d.ts +110 -0
- package/dist/src/providers/codex-cli-model.d.ts.map +1 -0
- package/dist/src/providers/codex-cli-model.js +338 -0
- package/dist/src/providers/codex-cli-model.js.map +1 -0
- package/dist/src/providers/codex-cli-runner.d.ts +70 -0
- package/dist/src/providers/codex-cli-runner.d.ts.map +1 -0
- package/dist/src/providers/codex-cli-runner.js +745 -0
- package/dist/src/providers/codex-cli-runner.js.map +1 -0
- package/dist/src/providers/codex-input-limit.d.ts +43 -0
- package/dist/src/providers/codex-input-limit.d.ts.map +1 -0
- package/dist/src/providers/codex-input-limit.js +70 -0
- package/dist/src/providers/codex-input-limit.js.map +1 -0
- package/dist/src/providers/conversation-generation.d.ts +21 -0
- package/dist/src/providers/conversation-generation.d.ts.map +1 -0
- package/dist/src/providers/conversation-generation.js +132 -0
- package/dist/src/providers/conversation-generation.js.map +1 -0
- package/dist/src/providers/ollama-embed.d.ts +23 -0
- package/dist/src/providers/ollama-embed.d.ts.map +1 -0
- package/dist/src/providers/ollama-embed.js +137 -0
- package/dist/src/providers/ollama-embed.js.map +1 -0
- package/dist/src/providers/ollama.d.ts +42 -0
- package/dist/src/providers/ollama.d.ts.map +1 -0
- package/dist/src/providers/ollama.js +169 -0
- package/dist/src/providers/ollama.js.map +1 -0
- package/dist/src/providers/openai-metadata-extraction.d.ts +120 -0
- package/dist/src/providers/openai-metadata-extraction.d.ts.map +1 -0
- package/dist/src/providers/openai-metadata-extraction.js +225 -0
- package/dist/src/providers/openai-metadata-extraction.js.map +1 -0
- package/dist/src/providers/operator-overrides.d.ts +24 -0
- package/dist/src/providers/operator-overrides.d.ts.map +1 -0
- package/dist/src/providers/operator-overrides.js +84 -0
- package/dist/src/providers/operator-overrides.js.map +1 -0
- package/dist/src/providers/placeholder-embed.d.ts +56 -0
- package/dist/src/providers/placeholder-embed.d.ts.map +1 -0
- package/dist/src/providers/placeholder-embed.js +64 -0
- package/dist/src/providers/placeholder-embed.js.map +1 -0
- package/dist/src/providers/shared-request.d.ts +22 -0
- package/dist/src/providers/shared-request.d.ts.map +1 -0
- package/dist/src/providers/shared-request.js +63 -0
- package/dist/src/providers/shared-request.js.map +1 -0
- package/dist/src/providers/stub.d.ts +19 -0
- package/dist/src/providers/stub.d.ts.map +1 -0
- package/dist/src/providers/stub.js +74 -0
- package/dist/src/providers/stub.js.map +1 -0
- package/dist/src/providers/types.d.ts +100 -0
- package/dist/src/providers/types.d.ts.map +1 -0
- package/dist/src/providers/types.js +63 -0
- package/dist/src/providers/types.js.map +1 -0
- package/dist/src/providers/voyage.d.ts +55 -0
- package/dist/src/providers/voyage.d.ts.map +1 -0
- package/dist/src/providers/voyage.js +179 -0
- package/dist/src/providers/voyage.js.map +1 -0
- package/dist/src/retrieval/brief.d.ts +26 -0
- package/dist/src/retrieval/brief.d.ts.map +1 -0
- package/dist/src/retrieval/brief.js +268 -0
- package/dist/src/retrieval/brief.js.map +1 -0
- package/dist/src/retrieval/canonical-files.d.ts +79 -0
- package/dist/src/retrieval/canonical-files.d.ts.map +1 -0
- package/dist/src/retrieval/canonical-files.js +432 -0
- package/dist/src/retrieval/canonical-files.js.map +1 -0
- package/dist/src/retrieval/compact.d.ts +306 -0
- package/dist/src/retrieval/compact.d.ts.map +1 -0
- package/dist/src/retrieval/compact.js +810 -0
- package/dist/src/retrieval/compact.js.map +1 -0
- package/dist/src/retrieval/context-pack.d.ts +344 -0
- package/dist/src/retrieval/context-pack.d.ts.map +1 -0
- package/dist/src/retrieval/context-pack.js +1483 -0
- package/dist/src/retrieval/context-pack.js.map +1 -0
- package/dist/src/retrieval/conversation-dedup.d.ts +54 -0
- package/dist/src/retrieval/conversation-dedup.d.ts.map +1 -0
- package/dist/src/retrieval/conversation-dedup.js +162 -0
- package/dist/src/retrieval/conversation-dedup.js.map +1 -0
- package/dist/src/retrieval/current-truth.d.ts +360 -0
- package/dist/src/retrieval/current-truth.d.ts.map +1 -0
- package/dist/src/retrieval/current-truth.js +766 -0
- package/dist/src/retrieval/current-truth.js.map +1 -0
- package/dist/src/retrieval/cwd.d.ts +25 -0
- package/dist/src/retrieval/cwd.d.ts.map +1 -0
- package/dist/src/retrieval/cwd.js +48 -0
- package/dist/src/retrieval/cwd.js.map +1 -0
- package/dist/src/retrieval/degraded.d.ts +20 -0
- package/dist/src/retrieval/degraded.d.ts.map +1 -0
- package/dist/src/retrieval/degraded.js +43 -0
- package/dist/src/retrieval/degraded.js.map +1 -0
- package/dist/src/retrieval/evidence-key.d.ts +48 -0
- package/dist/src/retrieval/evidence-key.d.ts.map +1 -0
- package/dist/src/retrieval/evidence-key.js +131 -0
- package/dist/src/retrieval/evidence-key.js.map +1 -0
- package/dist/src/retrieval/feedback-ranking.d.ts +49 -0
- package/dist/src/retrieval/feedback-ranking.d.ts.map +1 -0
- package/dist/src/retrieval/feedback-ranking.js +138 -0
- package/dist/src/retrieval/feedback-ranking.js.map +1 -0
- package/dist/src/retrieval/git-state.d.ts +62 -0
- package/dist/src/retrieval/git-state.d.ts.map +1 -0
- package/dist/src/retrieval/git-state.js +192 -0
- package/dist/src/retrieval/git-state.js.map +1 -0
- package/dist/src/retrieval/group-by-parent.d.ts +38 -0
- package/dist/src/retrieval/group-by-parent.d.ts.map +1 -0
- package/dist/src/retrieval/group-by-parent.js +40 -0
- package/dist/src/retrieval/group-by-parent.js.map +1 -0
- package/dist/src/retrieval/hybrid.d.ts +75 -0
- package/dist/src/retrieval/hybrid.d.ts.map +1 -0
- package/dist/src/retrieval/hybrid.js +151 -0
- package/dist/src/retrieval/hybrid.js.map +1 -0
- package/dist/src/retrieval/lexical.d.ts +33 -0
- package/dist/src/retrieval/lexical.d.ts.map +1 -0
- package/dist/src/retrieval/lexical.js +379 -0
- package/dist/src/retrieval/lexical.js.map +1 -0
- package/dist/src/retrieval/locator-boost.d.ts +37 -0
- package/dist/src/retrieval/locator-boost.d.ts.map +1 -0
- package/dist/src/retrieval/locator-boost.js +129 -0
- package/dist/src/retrieval/locator-boost.js.map +1 -0
- package/dist/src/retrieval/passages.d.ts +24 -0
- package/dist/src/retrieval/passages.d.ts.map +1 -0
- package/dist/src/retrieval/passages.js +160 -0
- package/dist/src/retrieval/passages.js.map +1 -0
- package/dist/src/retrieval/post-filter.d.ts +32 -0
- package/dist/src/retrieval/post-filter.d.ts.map +1 -0
- package/dist/src/retrieval/post-filter.js +57 -0
- package/dist/src/retrieval/post-filter.js.map +1 -0
- package/dist/src/retrieval/project-index.d.ts +71 -0
- package/dist/src/retrieval/project-index.d.ts.map +1 -0
- package/dist/src/retrieval/project-index.js +348 -0
- package/dist/src/retrieval/project-index.js.map +1 -0
- package/dist/src/retrieval/recall-hint.d.ts +22 -0
- package/dist/src/retrieval/recall-hint.d.ts.map +1 -0
- package/dist/src/retrieval/recall-hint.js +33 -0
- package/dist/src/retrieval/recall-hint.js.map +1 -0
- package/dist/src/retrieval/receipt.d.ts +57 -0
- package/dist/src/retrieval/receipt.d.ts.map +1 -0
- package/dist/src/retrieval/receipt.js +122 -0
- package/dist/src/retrieval/receipt.js.map +1 -0
- package/dist/src/retrieval/report-demotion.d.ts +46 -0
- package/dist/src/retrieval/report-demotion.d.ts.map +1 -0
- package/dist/src/retrieval/report-demotion.js +169 -0
- package/dist/src/retrieval/report-demotion.js.map +1 -0
- package/dist/src/retrieval/reranker.d.ts +119 -0
- package/dist/src/retrieval/reranker.d.ts.map +1 -0
- package/dist/src/retrieval/reranker.js +220 -0
- package/dist/src/retrieval/reranker.js.map +1 -0
- package/dist/src/retrieval/stitch-chunks.d.ts +76 -0
- package/dist/src/retrieval/stitch-chunks.d.ts.map +1 -0
- package/dist/src/retrieval/stitch-chunks.js +113 -0
- package/dist/src/retrieval/stitch-chunks.js.map +1 -0
- package/dist/src/retrieval/vector.d.ts +71 -0
- package/dist/src/retrieval/vector.d.ts.map +1 -0
- package/dist/src/retrieval/vector.js +147 -0
- package/dist/src/retrieval/vector.js.map +1 -0
- package/dist/src/runtime/legacy-migration.d.ts +27 -0
- package/dist/src/runtime/legacy-migration.d.ts.map +1 -0
- package/dist/src/runtime/legacy-migration.js +140 -0
- package/dist/src/runtime/legacy-migration.js.map +1 -0
- package/dist/src/runtime/legacy-name-guard.d.ts +35 -0
- package/dist/src/runtime/legacy-name-guard.d.ts.map +1 -0
- package/dist/src/runtime/legacy-name-guard.js +58 -0
- package/dist/src/runtime/legacy-name-guard.js.map +1 -0
- package/dist/src/runtime/rift-env.d.ts +14 -0
- package/dist/src/runtime/rift-env.d.ts.map +1 -0
- package/dist/src/runtime/rift-env.js +79 -0
- package/dist/src/runtime/rift-env.js.map +1 -0
- package/dist/src/runtime/voyage-key-source.d.ts +46 -0
- package/dist/src/runtime/voyage-key-source.d.ts.map +1 -0
- package/dist/src/runtime/voyage-key-source.js +97 -0
- package/dist/src/runtime/voyage-key-source.js.map +1 -0
- package/dist/src/runtime/watcher-startup.d.ts +2 -0
- package/dist/src/runtime/watcher-startup.d.ts.map +1 -0
- package/dist/src/runtime/watcher-startup.js +4 -0
- package/dist/src/runtime/watcher-startup.js.map +1 -0
- package/dist/src/security/archive.d.ts +23 -0
- package/dist/src/security/archive.d.ts.map +1 -0
- package/dist/src/security/archive.js +163 -0
- package/dist/src/security/archive.js.map +1 -0
- package/dist/src/security/paths.d.ts +21 -0
- package/dist/src/security/paths.d.ts.map +1 -0
- package/dist/src/security/paths.js +67 -0
- package/dist/src/security/paths.js.map +1 -0
- package/dist/src/server/app.d.ts +29 -0
- package/dist/src/server/app.d.ts.map +1 -0
- package/dist/src/server/app.js +356 -0
- package/dist/src/server/app.js.map +1 -0
- package/dist/src/server/build-info.d.ts +8 -0
- package/dist/src/server/build-info.d.ts.map +1 -0
- package/dist/src/server/build-info.js +61 -0
- package/dist/src/server/build-info.js.map +1 -0
- package/dist/src/server/lifecycle.d.ts +30 -0
- package/dist/src/server/lifecycle.d.ts.map +1 -0
- package/dist/src/server/lifecycle.js +59 -0
- package/dist/src/server/lifecycle.js.map +1 -0
- package/dist/src/server/middleware/multipart.d.ts +51 -0
- package/dist/src/server/middleware/multipart.d.ts.map +1 -0
- package/dist/src/server/middleware/multipart.js +86 -0
- package/dist/src/server/middleware/multipart.js.map +1 -0
- package/dist/src/server/routes/compact.d.ts +37 -0
- package/dist/src/server/routes/compact.d.ts.map +1 -0
- package/dist/src/server/routes/compact.js +80 -0
- package/dist/src/server/routes/compact.js.map +1 -0
- package/dist/src/server/routes/context.d.ts +12 -0
- package/dist/src/server/routes/context.d.ts.map +1 -0
- package/dist/src/server/routes/context.js +73 -0
- package/dist/src/server/routes/context.js.map +1 -0
- package/dist/src/server/routes/conversations-search.d.ts +4 -0
- package/dist/src/server/routes/conversations-search.d.ts.map +1 -0
- package/dist/src/server/routes/conversations-search.js +287 -0
- package/dist/src/server/routes/conversations-search.js.map +1 -0
- package/dist/src/server/routes/enqueue.d.ts +11 -0
- package/dist/src/server/routes/enqueue.d.ts.map +1 -0
- package/dist/src/server/routes/enqueue.js +17 -0
- package/dist/src/server/routes/enqueue.js.map +1 -0
- package/dist/src/server/routes/friend-status.d.ts +481 -0
- package/dist/src/server/routes/friend-status.d.ts.map +1 -0
- package/dist/src/server/routes/friend-status.js +675 -0
- package/dist/src/server/routes/friend-status.js.map +1 -0
- package/dist/src/server/routes/ingest.d.ts +15 -0
- package/dist/src/server/routes/ingest.d.ts.map +1 -0
- package/dist/src/server/routes/ingest.js +142 -0
- package/dist/src/server/routes/ingest.js.map +1 -0
- package/dist/src/server/routes/jobs.d.ts +10 -0
- package/dist/src/server/routes/jobs.d.ts.map +1 -0
- package/dist/src/server/routes/jobs.js +29 -0
- package/dist/src/server/routes/jobs.js.map +1 -0
- package/dist/src/server/routes/mcp-usage.d.ts +17 -0
- package/dist/src/server/routes/mcp-usage.d.ts.map +1 -0
- package/dist/src/server/routes/mcp-usage.js +17 -0
- package/dist/src/server/routes/mcp-usage.js.map +1 -0
- package/dist/src/server/routes/reconcile.d.ts +4 -0
- package/dist/src/server/routes/reconcile.d.ts.map +1 -0
- package/dist/src/server/routes/reconcile.js +62 -0
- package/dist/src/server/routes/reconcile.js.map +1 -0
- package/dist/src/server/routes/reindex.d.ts +4 -0
- package/dist/src/server/routes/reindex.d.ts.map +1 -0
- package/dist/src/server/routes/reindex.js +77 -0
- package/dist/src/server/routes/reindex.js.map +1 -0
- package/dist/src/server/routes/retrieval-feedback.d.ts +3 -0
- package/dist/src/server/routes/retrieval-feedback.d.ts.map +1 -0
- package/dist/src/server/routes/retrieval-feedback.js +290 -0
- package/dist/src/server/routes/retrieval-feedback.js.map +1 -0
- package/dist/src/server/routes/save.d.ts +52 -0
- package/dist/src/server/routes/save.d.ts.map +1 -0
- package/dist/src/server/routes/save.js +127 -0
- package/dist/src/server/routes/save.js.map +1 -0
- package/dist/src/server/routes/search.d.ts +5 -0
- package/dist/src/server/routes/search.d.ts.map +1 -0
- package/dist/src/server/routes/search.js +689 -0
- package/dist/src/server/routes/search.js.map +1 -0
- package/dist/src/server/routes/setup.d.ts +46 -0
- package/dist/src/server/routes/setup.d.ts.map +1 -0
- package/dist/src/server/routes/setup.js +322 -0
- package/dist/src/server/routes/setup.js.map +1 -0
- package/dist/src/server/routes/stats.d.ts +10 -0
- package/dist/src/server/routes/stats.d.ts.map +1 -0
- package/dist/src/server/routes/stats.js +15 -0
- package/dist/src/server/routes/stats.js.map +1 -0
- package/dist/src/server/routes/status.d.ts +20 -0
- package/dist/src/server/routes/status.d.ts.map +1 -0
- package/dist/src/server/routes/status.js +31 -0
- package/dist/src/server/routes/status.js.map +1 -0
- package/dist/src/server/routes/triage.d.ts +4 -0
- package/dist/src/server/routes/triage.d.ts.map +1 -0
- package/dist/src/server/routes/triage.js +97 -0
- package/dist/src/server/routes/triage.js.map +1 -0
- package/dist/src/server/save-quality.d.ts +21 -0
- package/dist/src/server/save-quality.d.ts.map +1 -0
- package/dist/src/server/save-quality.js +51 -0
- package/dist/src/server/save-quality.js.map +1 -0
- package/dist/src/server/serving-marker.d.ts +85 -0
- package/dist/src/server/serving-marker.d.ts.map +1 -0
- package/dist/src/server/serving-marker.js +226 -0
- package/dist/src/server/serving-marker.js.map +1 -0
- package/dist/src/storage/atomic.d.ts +8 -0
- package/dist/src/storage/atomic.d.ts.map +1 -0
- package/dist/src/storage/atomic.js +22 -0
- package/dist/src/storage/atomic.js.map +1 -0
- package/dist/src/storage/chunk-backfill.d.ts +39 -0
- package/dist/src/storage/chunk-backfill.d.ts.map +1 -0
- package/dist/src/storage/chunk-backfill.js +295 -0
- package/dist/src/storage/chunk-backfill.js.map +1 -0
- package/dist/src/storage/db.d.ts +15 -0
- package/dist/src/storage/db.d.ts.map +1 -0
- package/dist/src/storage/db.js +47 -0
- package/dist/src/storage/db.js.map +1 -0
- package/dist/src/storage/filter.d.ts +42 -0
- package/dist/src/storage/filter.d.ts.map +1 -0
- package/dist/src/storage/filter.js +70 -0
- package/dist/src/storage/filter.js.map +1 -0
- package/dist/src/storage/fts.d.ts +47 -0
- package/dist/src/storage/fts.d.ts.map +1 -0
- package/dist/src/storage/fts.js +86 -0
- package/dist/src/storage/fts.js.map +1 -0
- package/dist/src/storage/integrity.d.ts +11 -0
- package/dist/src/storage/integrity.d.ts.map +1 -0
- package/dist/src/storage/integrity.js +66 -0
- package/dist/src/storage/integrity.js.map +1 -0
- package/dist/src/storage/maintenance.d.ts +27 -0
- package/dist/src/storage/maintenance.d.ts.map +1 -0
- package/dist/src/storage/maintenance.js +66 -0
- package/dist/src/storage/maintenance.js.map +1 -0
- package/dist/src/storage/rebuild.d.ts +71 -0
- package/dist/src/storage/rebuild.d.ts.map +1 -0
- package/dist/src/storage/rebuild.js +605 -0
- package/dist/src/storage/rebuild.js.map +1 -0
- package/dist/src/storage/report-card-backfill.d.ts +20 -0
- package/dist/src/storage/report-card-backfill.d.ts.map +1 -0
- package/dist/src/storage/report-card-backfill.js +114 -0
- package/dist/src/storage/report-card-backfill.js.map +1 -0
- package/dist/src/storage/shadow-swap.d.ts +20 -0
- package/dist/src/storage/shadow-swap.d.ts.map +1 -0
- package/dist/src/storage/shadow-swap.js +163 -0
- package/dist/src/storage/shadow-swap.js.map +1 -0
- package/dist/src/storage/tables.d.ts +147 -0
- package/dist/src/storage/tables.d.ts.map +1 -0
- package/dist/src/storage/tables.js +290 -0
- package/dist/src/storage/tables.js.map +1 -0
- package/operator/swiftbar/render-menu.py +475 -0
- package/operator/swiftbar/rift.10s.sh +201 -0
- package/package.json +57 -3
|
@@ -0,0 +1,675 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GET /status/friend — structured payload for the `onadit status` header.
|
|
3
|
+
*
|
|
4
|
+
* The existing `/status` route returns the capability-map markdown and
|
|
5
|
+
* stays untouched (it's part of the MCP-tool contract). This route
|
|
6
|
+
* collects only the signals a friend-readable header needs:
|
|
7
|
+
* - build + daemon: from getBuildInfo() + uptime + config.server.port +
|
|
8
|
+
* env(VOYAGE_API_KEY) presence
|
|
9
|
+
* - voyage: optional `project_label` from config + real last successful
|
|
10
|
+
* embedding timestamp from `data/observability/embedding-events.jsonl`
|
|
11
|
+
* filtered to ingest pipelines (search-time embedding calls are
|
|
12
|
+
* intentionally excluded so a user search cannot mask an ingest
|
|
13
|
+
* outage), plus the most recent error in the last 24h with a short
|
|
14
|
+
* reason class
|
|
15
|
+
* - codex: latest auto-capture-runs.jsonl row's preflight_ok + ts
|
|
16
|
+
* - capture: latest auto-capture-runs.jsonl row's totals
|
|
17
|
+
* - feedback: relay enabled flag from feedback-config.json
|
|
18
|
+
*
|
|
19
|
+
* Friend's username and key bytes never appear in the payload.
|
|
20
|
+
* `daemon.data_dir` is the one exception: operators need it to confirm
|
|
21
|
+
* which data root the daemon is actually reading (the launchd config in
|
|
22
|
+
* Application Support can redirect to a repo-local data dir, and
|
|
23
|
+
* inspecting the wrong one produces stale-state false alarms). The
|
|
24
|
+
* /status/friend route is auth-gated, so this only reaches callers who
|
|
25
|
+
* already have the daemon token.
|
|
26
|
+
* MCP-client presence detection is intentionally CLI-side (the friend's
|
|
27
|
+
* client config files are local, and the renderer needs to print client
|
|
28
|
+
* names anyway).
|
|
29
|
+
*/
|
|
30
|
+
import fs from "node:fs";
|
|
31
|
+
import os from "node:os";
|
|
32
|
+
import path from "node:path";
|
|
33
|
+
import { getBuildInfo } from "../build-info.js";
|
|
34
|
+
import { autoCaptureRunFailed, readAutoCaptureRunSummary, } from "../../capture/observability.js";
|
|
35
|
+
import { classifyParkedOversizedSessions } from "../../capture/auto-repair.js";
|
|
36
|
+
import { cursorStoreAvailable } from "../../capture/cursor-capture.js";
|
|
37
|
+
import { CLAUDE_DESKTOP_CAPTURE_SOURCE, CURSOR_CAPTURE_SOURCE, } from "../../capture/sources.js";
|
|
38
|
+
import { loadFeedbackConfig } from "../../cli/feedback/feedback-config.js";
|
|
39
|
+
import { installedAsPreviousPackage, selfUpdateSupported } from "../../diagnostics/install-layout.js";
|
|
40
|
+
import { classifyCodexPreflightError, extractCodexModelFromError, summarizeCodexPreflightClass, } from "../../diagnostics/codex-preflight.js";
|
|
41
|
+
import { classifyClaudePreflightError, summarizeClaudePreflightClass, } from "../../diagnostics/claude-preflight.js";
|
|
42
|
+
import { sanitizeProjectLabel } from "../../runtime/legacy-name-guard.js";
|
|
43
|
+
import { readCodexModelSwitch, } from "../../providers/codex-cli-model.js";
|
|
44
|
+
import { readEmbeddingEvents, } from "../../observability/embedding-events.js";
|
|
45
|
+
import { readIndexEvents, } from "../../observability/index-events.js";
|
|
46
|
+
import { compareBetaVersions, readVersionCheck, } from "../../observability/version-check.js";
|
|
47
|
+
import { buildMemoryCoverageDiagnostics, } from "../../diagnostics/memory-coverage.js";
|
|
48
|
+
import { computeOnboardingState, isUsefulStateReached, readOnboardingMetric, stampUsefulStateIfReady, } from "../../observability/onboarding-metric.js";
|
|
49
|
+
import { getCapabilityCounts } from "../../observability/rift-context.js";
|
|
50
|
+
const VOYAGE_ERROR_LOOKBACK_MS = 24 * 60 * 60 * 1000;
|
|
51
|
+
const INDEX_ERROR_LOOKBACK_MS = 24 * 60 * 60 * 1000;
|
|
52
|
+
const INBOX_ERROR_LOOKBACK_MS = 24 * 60 * 60 * 1000;
|
|
53
|
+
const INBOX_IDEMPOTENCY_PREFIX = "inbox:";
|
|
54
|
+
const CLAUDE_DESKTOP_SESSIONS_DIR = path.join("Library", "Application Support", "Claude", "local-agent-mode-sessions");
|
|
55
|
+
/**
|
|
56
|
+
* Cheap presence probe for Claude Desktop agent/Cowork sessions. This only
|
|
57
|
+
* checks that the store directory exists and can be listed; transcript parsing
|
|
58
|
+
* remains in the capture pipeline.
|
|
59
|
+
*/
|
|
60
|
+
export function claudeDesktopSessionStoreAvailable(homeDir = os.homedir()) {
|
|
61
|
+
const root = path.join(homeDir, CLAUDE_DESKTOP_SESSIONS_DIR);
|
|
62
|
+
try {
|
|
63
|
+
const stat = fs.statSync(root);
|
|
64
|
+
if (!stat.isDirectory())
|
|
65
|
+
return false;
|
|
66
|
+
fs.readdirSync(root);
|
|
67
|
+
return true;
|
|
68
|
+
}
|
|
69
|
+
catch {
|
|
70
|
+
return false;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Legacy-row fallback ONLY: infer which worker a preflight ran from the recorded
|
|
75
|
+
* error, for rows written before `preflight_worker` was persisted. Newer rows
|
|
76
|
+
* never reach here — `codexBlock` prefers the persisted worker.
|
|
77
|
+
*
|
|
78
|
+
* We override the configured worker to `claude` ONLY when the text carries a
|
|
79
|
+
* Onadit-generated Claude SIGNATURE — phrasing the CLAUDE RUNNER emits about itself
|
|
80
|
+
* and Codex never does: `Claude CLI` / `Claude Code CLI` / `RIFT_CLAUDE_CLI_PATH`
|
|
81
|
+
* / `--safe-mode` (a Claude-only flag). A bare `claude` word match is unsafe: a
|
|
82
|
+
* Codex preflight error can quote project paths, model names, or MCP noise
|
|
83
|
+
* containing "claude" and would then render Claude repair copy for a Codex
|
|
84
|
+
* failure — violating the "Codex output unchanged" bar. We deliberately do NOT
|
|
85
|
+
* treat a `claude_code` provider token as a signature: that token also appears in
|
|
86
|
+
* Codex's OWN "switch to the Claude worker (provider = claude_code)" remedy text,
|
|
87
|
+
* so it marks a Codex failure, not a Claude one. The kept signatures are
|
|
88
|
+
* Claude-runner-exclusive, so their presence is authoritative even when the same
|
|
89
|
+
* message also mentions Codex (e.g. the runner's "No compatible Claude Code CLI …
|
|
90
|
+
* use the Codex worker" aggregate names both). Absent a Claude signature we defer
|
|
91
|
+
* to the configured worker, the best signal for a pre-persistence row.
|
|
92
|
+
*/
|
|
93
|
+
function detectPreflightWorker(error, configured) {
|
|
94
|
+
const text = (error ?? "").toLowerCase();
|
|
95
|
+
const claudeSignature = /claude code cli|claude cli|rift_claude_cli_path|--safe-mode/.test(text);
|
|
96
|
+
if (claudeSignature)
|
|
97
|
+
return "claude";
|
|
98
|
+
return configured;
|
|
99
|
+
}
|
|
100
|
+
/**
|
|
101
|
+
* Build the preflight block, classifying the last failure into a leak-free,
|
|
102
|
+
* honest, WORKER-SPECIFIC diagnosis. Codex output is unchanged; a `claude_code`
|
|
103
|
+
* triage worker gets Claude classes + Claude summaries. On success (or no run)
|
|
104
|
+
* the failure fields are null but the worker is still reported from config.
|
|
105
|
+
*/
|
|
106
|
+
function codexBlock(last, configuredWorker) {
|
|
107
|
+
if (!last || last.preflight_ok) {
|
|
108
|
+
return {
|
|
109
|
+
last_preflight_at: last?.timestamp ?? null,
|
|
110
|
+
last_preflight_ok: last ? last.preflight_ok : null,
|
|
111
|
+
// A healthy run reports the worker it actually ran when recorded; only
|
|
112
|
+
// fall back to the configured worker when there's no run or it predates
|
|
113
|
+
// the persisted field.
|
|
114
|
+
last_preflight_worker: last?.preflight_worker ?? configuredWorker,
|
|
115
|
+
last_preflight_error_class: null,
|
|
116
|
+
last_preflight_model: null,
|
|
117
|
+
last_preflight_error_summary: null,
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
// Prefer the worker PERSISTED on the run that actually failed. Only fall back
|
|
121
|
+
// to inferring it (error text, then current config) for legacy rows written
|
|
122
|
+
// before the worker was recorded — that heuristic can otherwise misattribute a
|
|
123
|
+
// failure if `capture.triage.provider` was flipped after the run, or if the
|
|
124
|
+
// error text happens to mention the other worker.
|
|
125
|
+
const worker = last.preflight_worker ??
|
|
126
|
+
detectPreflightWorker(last.preflight_error, configuredWorker);
|
|
127
|
+
if (worker === "claude") {
|
|
128
|
+
const errorClass = classifyClaudePreflightError(last.preflight_error);
|
|
129
|
+
return {
|
|
130
|
+
last_preflight_at: last.timestamp,
|
|
131
|
+
last_preflight_ok: false,
|
|
132
|
+
last_preflight_worker: "claude",
|
|
133
|
+
last_preflight_error_class: errorClass,
|
|
134
|
+
last_preflight_model: null,
|
|
135
|
+
last_preflight_error_summary: summarizeClaudePreflightClass(errorClass),
|
|
136
|
+
};
|
|
137
|
+
}
|
|
138
|
+
const errorClass = classifyCodexPreflightError(last.preflight_error);
|
|
139
|
+
const model = extractCodexModelFromError(last.preflight_error);
|
|
140
|
+
return {
|
|
141
|
+
last_preflight_at: last.timestamp,
|
|
142
|
+
last_preflight_ok: false,
|
|
143
|
+
last_preflight_worker: "codex",
|
|
144
|
+
last_preflight_error_class: errorClass,
|
|
145
|
+
last_preflight_model: model,
|
|
146
|
+
last_preflight_error_summary: summarizeCodexPreflightClass(errorClass, model),
|
|
147
|
+
};
|
|
148
|
+
}
|
|
149
|
+
export function buildFriendStatusPayload(deps, opts = {}) {
|
|
150
|
+
const build = getBuildInfo();
|
|
151
|
+
const voyageKey = process.env["VOYAGE_API_KEY"];
|
|
152
|
+
const voyageKeyPresent = typeof voyageKey === "string" && voyageKey.length > 0;
|
|
153
|
+
const dataDir = deps.config.data_paths.data_dir;
|
|
154
|
+
let summary;
|
|
155
|
+
try {
|
|
156
|
+
summary = readAutoCaptureRunSummary(dataDir, deps.config.capture.sources);
|
|
157
|
+
}
|
|
158
|
+
catch {
|
|
159
|
+
summary = {
|
|
160
|
+
last_run: null,
|
|
161
|
+
last_daemon_run: null,
|
|
162
|
+
last_success_by_source: {},
|
|
163
|
+
last_cursor_discovery: null,
|
|
164
|
+
last_claude_desktop_discovery: null,
|
|
165
|
+
};
|
|
166
|
+
}
|
|
167
|
+
const last = summary.last_run;
|
|
168
|
+
const lastDaemon = summary.last_daemon_run;
|
|
169
|
+
let captureTotals = { saved: 0, review: 0, quarantined: 0 };
|
|
170
|
+
if (last) {
|
|
171
|
+
for (const counts of Object.values(last.counts_by_source)) {
|
|
172
|
+
if (!counts)
|
|
173
|
+
continue;
|
|
174
|
+
captureTotals.saved += counts.saved;
|
|
175
|
+
captureTotals.review += counts.review;
|
|
176
|
+
captureTotals.quarantined += counts.quarantined ?? 0;
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
let parkedClassification = { parked: 0, repairing: 0, failed: 0 };
|
|
180
|
+
try {
|
|
181
|
+
parkedClassification = classifyParkedOversizedSessions({ dataDir });
|
|
182
|
+
}
|
|
183
|
+
catch {
|
|
184
|
+
parkedClassification = { parked: 0, repairing: 0, failed: 0 };
|
|
185
|
+
}
|
|
186
|
+
const voyageHealth = computeVoyageHealth(dataDir, Date.now());
|
|
187
|
+
const indexHealth = computeIndexHealth(dataDir, Date.now());
|
|
188
|
+
const inboxHealth = computeInboxHealth(deps.jobQueue, Date.now());
|
|
189
|
+
// `enabled` covers both opt-in shapes (contact email and/or operator
|
|
190
|
+
// relay), so a relay is "on" only when an endpoint URL also exists —
|
|
191
|
+
// otherwise an email-only opt-in would falsely read as a Clem-side relay.
|
|
192
|
+
let relayEnabled = false;
|
|
193
|
+
let contactOptedIn = false;
|
|
194
|
+
try {
|
|
195
|
+
const fb = loadFeedbackConfig(dataDir);
|
|
196
|
+
relayEnabled = fb.enabled === true && typeof fb.url === "string" && fb.url.length > 0;
|
|
197
|
+
contactOptedIn = fb.enabled === true && typeof fb.email === "string" && fb.email.length > 0;
|
|
198
|
+
}
|
|
199
|
+
catch {
|
|
200
|
+
relayEnabled = false;
|
|
201
|
+
contactOptedIn = false;
|
|
202
|
+
}
|
|
203
|
+
return {
|
|
204
|
+
build,
|
|
205
|
+
daemon: {
|
|
206
|
+
uptime_seconds: Math.floor((Date.now() - deps.startTime) / 1000),
|
|
207
|
+
port: deps.config.server.port,
|
|
208
|
+
voyage_key_present: voyageKeyPresent,
|
|
209
|
+
capture_enabled: deps.config.capture.enabled === true,
|
|
210
|
+
data_dir: dataDir,
|
|
211
|
+
config_path: deps.configPath ?? null,
|
|
212
|
+
},
|
|
213
|
+
voyage: {
|
|
214
|
+
project_label: sanitizeProjectLabel(deps.config.voyage?.project_label),
|
|
215
|
+
last_embed_at: voyageHealth.last_embed_at,
|
|
216
|
+
last_error_at: voyageHealth.last_error_at,
|
|
217
|
+
last_error_reason: voyageHealth.last_error_reason,
|
|
218
|
+
},
|
|
219
|
+
index: {
|
|
220
|
+
last_update_at: indexHealth.last_update_at,
|
|
221
|
+
last_error_at: indexHealth.last_error_at,
|
|
222
|
+
last_error_reason: indexHealth.last_error_reason,
|
|
223
|
+
},
|
|
224
|
+
inbox: inboxHealth,
|
|
225
|
+
codex: {
|
|
226
|
+
...codexBlock(last, deps.config.capture.triage?.provider === "claude_code"
|
|
227
|
+
? "claude"
|
|
228
|
+
: "codex"),
|
|
229
|
+
model_switch: readCodexModelSwitch(dataDir),
|
|
230
|
+
},
|
|
231
|
+
capture: {
|
|
232
|
+
last_run_at: last?.timestamp ?? null,
|
|
233
|
+
last_run_ok: last ? last.run_ok : null,
|
|
234
|
+
last_run_trigger: last ? (last.trigger ?? "daemon") : null,
|
|
235
|
+
last_saved: captureTotals.saved,
|
|
236
|
+
last_review: captureTotals.review,
|
|
237
|
+
last_errors: last?.errors.length ?? 0,
|
|
238
|
+
last_quarantined: captureTotals.quarantined,
|
|
239
|
+
oversized_parked: parkedClassification.parked,
|
|
240
|
+
oversized_repairing: parkedClassification.repairing,
|
|
241
|
+
oversized_repair_failed: parkedClassification.failed,
|
|
242
|
+
next_run_at: computeNextCaptureRunAt({
|
|
243
|
+
captureEnabled: deps.config.capture.enabled,
|
|
244
|
+
intervalSeconds: deps.config.capture.interval_seconds,
|
|
245
|
+
startTime: deps.startTime,
|
|
246
|
+
now: Date.now(),
|
|
247
|
+
}),
|
|
248
|
+
last_daemon_run_at: lastDaemon?.timestamp ?? null,
|
|
249
|
+
last_daemon_failed: lastDaemon ? autoCaptureRunFailed(lastDaemon) : null,
|
|
250
|
+
cursor: {
|
|
251
|
+
scheduled: deps.config.capture.sources.includes(CURSOR_CAPTURE_SOURCE),
|
|
252
|
+
available: cursorStoreAvailable(),
|
|
253
|
+
...(summary.last_cursor_discovery
|
|
254
|
+
? { last_discovery_ok: summary.last_cursor_discovery.ok }
|
|
255
|
+
: {}),
|
|
256
|
+
},
|
|
257
|
+
grok_cli: { scheduled: deps.config.capture.sources.includes("grok_cli") },
|
|
258
|
+
claude_desktop: {
|
|
259
|
+
scheduled: deps.config.capture.sources.includes(CLAUDE_DESKTOP_CAPTURE_SOURCE),
|
|
260
|
+
available: claudeDesktopSessionStoreAvailable(),
|
|
261
|
+
...(summary.last_claude_desktop_discovery
|
|
262
|
+
? { last_discovery_ok: summary.last_claude_desktop_discovery.ok }
|
|
263
|
+
: {}),
|
|
264
|
+
},
|
|
265
|
+
},
|
|
266
|
+
feedback: { relay_enabled: relayEnabled, contact_opted_in: contactOptedIn },
|
|
267
|
+
// `process.argv[1]` is the daemon's own running entrypoint — the
|
|
268
|
+
// authoritative signal for whether this install is the packaged (.pkg)
|
|
269
|
+
// bundle `onadit update` cannot upgrade. More direct than re-reading the
|
|
270
|
+
// launchd plist: it is literally the code path the daemon loaded.
|
|
271
|
+
update: computeUpdateProjection(dataDir, build.version, selfUpdateSupported(process.argv[1] ?? null), installedAsPreviousPackage(build.name)),
|
|
272
|
+
onboarding: projectOnboardingState(dataDir),
|
|
273
|
+
memory: buildMemoryCoverageDiagnostics({
|
|
274
|
+
config: deps.config,
|
|
275
|
+
counts: opts.capabilityCounts ?? null,
|
|
276
|
+
voyageKeyPresent,
|
|
277
|
+
compactAvailable: deps.jobQueue?.hasHandler("compact") === true,
|
|
278
|
+
}),
|
|
279
|
+
};
|
|
280
|
+
}
|
|
281
|
+
/**
|
|
282
|
+
* Read the persisted metric and return its projection. Pure read — start
|
|
283
|
+
* stamping happens in the async `stampOnboardingStartIfReady` helper so
|
|
284
|
+
* the sync builder (and its test surface) stay sync. The route awaits
|
|
285
|
+
* the stamper before calling `buildFriendStatusPayload`, so a freshly
|
|
286
|
+
* stamped start is visible in the same response.
|
|
287
|
+
*
|
|
288
|
+
* Exported for tests.
|
|
289
|
+
*/
|
|
290
|
+
export function projectOnboardingState(dataDir) {
|
|
291
|
+
const metric = readOnboardingMetric(dataDir);
|
|
292
|
+
const projection = computeOnboardingState(metric);
|
|
293
|
+
if (projection.state === "hidden") {
|
|
294
|
+
return {
|
|
295
|
+
state: "hidden",
|
|
296
|
+
install_id: metric.install_id,
|
|
297
|
+
useful_state_reached_at: null,
|
|
298
|
+
first_useful_recall_at: null,
|
|
299
|
+
first_useful_recall_tool: null,
|
|
300
|
+
duration_seconds: null,
|
|
301
|
+
};
|
|
302
|
+
}
|
|
303
|
+
if (projection.state === "pending") {
|
|
304
|
+
return {
|
|
305
|
+
state: "pending",
|
|
306
|
+
install_id: metric.install_id,
|
|
307
|
+
useful_state_reached_at: projection.useful_state_reached_at,
|
|
308
|
+
first_useful_recall_at: null,
|
|
309
|
+
first_useful_recall_tool: null,
|
|
310
|
+
duration_seconds: null,
|
|
311
|
+
};
|
|
312
|
+
}
|
|
313
|
+
return {
|
|
314
|
+
state: "completed",
|
|
315
|
+
install_id: metric.install_id,
|
|
316
|
+
useful_state_reached_at: projection.useful_state_reached_at,
|
|
317
|
+
first_useful_recall_at: projection.first_useful_recall_at,
|
|
318
|
+
first_useful_recall_tool: projection.first_useful_recall_tool,
|
|
319
|
+
duration_seconds: projection.duration_seconds,
|
|
320
|
+
};
|
|
321
|
+
}
|
|
322
|
+
/**
|
|
323
|
+
* Async readiness evaluation + write-once start stamping. Pulled out of
|
|
324
|
+
* `buildFriendStatusPayload` so the sync builder stays sync; the route
|
|
325
|
+
* awaits this before assembling the payload, so a stamp written here
|
|
326
|
+
* is visible in the same response.
|
|
327
|
+
*
|
|
328
|
+
* Readiness signals for v1:
|
|
329
|
+
* - daemon healthy: trivially true (this code is running inside the
|
|
330
|
+
* daemon process that is serving the request).
|
|
331
|
+
* - Voyage key valid: VOYAGE_API_KEY env present AND at least one
|
|
332
|
+
* successful Voyage embedding has been recorded on the ingest lane
|
|
333
|
+
* (a real round-trip with this key, not just "env var is set").
|
|
334
|
+
* - indexed count >= 1: `getCapabilityCounts()` reports at least one
|
|
335
|
+
* conversations_hot/cold or structured_docs row. Digest count is
|
|
336
|
+
* intentionally excluded — the bar is "conversations + structured
|
|
337
|
+
* docs" per the v1 spec.
|
|
338
|
+
*
|
|
339
|
+
* Never throws. A capability-counts failure (LanceDB not initialised,
|
|
340
|
+
* IO error) is treated as "not ready" rather than a 500, so a partial
|
|
341
|
+
* daemon never surfaces a misleading start timestamp.
|
|
342
|
+
*
|
|
343
|
+
* Exported for tests.
|
|
344
|
+
*/
|
|
345
|
+
export async function stampOnboardingStartIfReady(dataDir, opts = {}) {
|
|
346
|
+
const voyageKey = process.env["VOYAGE_API_KEY"];
|
|
347
|
+
const voyageKeyPresent = typeof voyageKey === "string" && voyageKey.length > 0;
|
|
348
|
+
const voyageHealth = opts.voyageHealth ?? computeVoyageHealth(dataDir, opts.now ?? Date.now());
|
|
349
|
+
const voyageKeyValid = voyageKeyPresent && voyageHealth.last_embed_at !== null;
|
|
350
|
+
// No-key installs are a first-class useful state: keyword (lexical) search is
|
|
351
|
+
// fully on without a Voyage key. We treat "no key present" as intentional
|
|
352
|
+
// lexical mode. A key that's present but not yet round-tripped (valid=false)
|
|
353
|
+
// is a setup-in-progress, NOT lexical mode — so it counts as neither and
|
|
354
|
+
// does not stamp useful, preserving the "env present but never embedded →
|
|
355
|
+
// not useful" contract.
|
|
356
|
+
const lexicalModeAvailable = !voyageKeyPresent;
|
|
357
|
+
let indexedCount = 0;
|
|
358
|
+
if (opts.capabilityCounts) {
|
|
359
|
+
indexedCount =
|
|
360
|
+
opts.capabilityCounts.structured_docs +
|
|
361
|
+
opts.capabilityCounts.conversations_hot +
|
|
362
|
+
opts.capabilityCounts.conversations_cold;
|
|
363
|
+
}
|
|
364
|
+
else {
|
|
365
|
+
try {
|
|
366
|
+
const counts = await getCapabilityCounts();
|
|
367
|
+
indexedCount =
|
|
368
|
+
counts.structured_docs +
|
|
369
|
+
counts.conversations_hot +
|
|
370
|
+
counts.conversations_cold;
|
|
371
|
+
}
|
|
372
|
+
catch {
|
|
373
|
+
indexedCount = 0;
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
const ready = isUsefulStateReached({
|
|
377
|
+
daemonHealthy: true,
|
|
378
|
+
voyageKeyValid,
|
|
379
|
+
lexicalModeAvailable,
|
|
380
|
+
indexedCount,
|
|
381
|
+
});
|
|
382
|
+
stampUsefulStateIfReady(dataDir, {
|
|
383
|
+
ready,
|
|
384
|
+
now: new Date(opts.now ?? Date.now()).toISOString(),
|
|
385
|
+
});
|
|
386
|
+
}
|
|
387
|
+
/**
|
|
388
|
+
* Project the version-check snapshot to the three fields the renderer
|
|
389
|
+
* needs. A missing snapshot, a failed probe, or an up-to-date install
|
|
390
|
+
* all return `available: false` — the renderer prints nothing in those
|
|
391
|
+
* cases, so an unreachable npm registry can never make Onadit look broken.
|
|
392
|
+
*
|
|
393
|
+
* Exported for tests.
|
|
394
|
+
*/
|
|
395
|
+
export function computeUpdateProjection(dataDir, installedVersion, selfUpdate = true, reinstallNeeded = false) {
|
|
396
|
+
const reinstall = reinstallNeeded ? { reinstall_needed: true } : {};
|
|
397
|
+
const snapshot = readVersionCheck(dataDir);
|
|
398
|
+
if (!snapshot || snapshot.latest_beta === null) {
|
|
399
|
+
return {
|
|
400
|
+
available: false,
|
|
401
|
+
installed: installedVersion,
|
|
402
|
+
latest_beta: snapshot?.latest_beta ?? null,
|
|
403
|
+
checked_at: snapshot?.checked_at ?? null,
|
|
404
|
+
self_update_supported: selfUpdate,
|
|
405
|
+
...reinstall,
|
|
406
|
+
};
|
|
407
|
+
}
|
|
408
|
+
// Use the installedVersion from the live build, not the snapshot, so a
|
|
409
|
+
// post-update daemon restart immediately reports `available: false`
|
|
410
|
+
// even before the next probe writes a fresh snapshot.
|
|
411
|
+
const available = compareBetaVersions(installedVersion, snapshot.latest_beta) < 0;
|
|
412
|
+
return {
|
|
413
|
+
available,
|
|
414
|
+
installed: installedVersion,
|
|
415
|
+
latest_beta: snapshot.latest_beta,
|
|
416
|
+
checked_at: snapshot.checked_at,
|
|
417
|
+
self_update_supported: selfUpdate,
|
|
418
|
+
...reinstall,
|
|
419
|
+
};
|
|
420
|
+
}
|
|
421
|
+
/**
|
|
422
|
+
* Compute the next auto-capture tick.
|
|
423
|
+
*
|
|
424
|
+
* The daemon registers `setInterval(runCapture, intervalMs)` at startup
|
|
425
|
+
* (`src/main.ts`), so ticks land at `startTime + N * intervalMs` for
|
|
426
|
+
* N ≥ 1 (N = 0 is the eager startup call). We deliberately anchor to
|
|
427
|
+
* `startTime` rather than `last_run_at` because:
|
|
428
|
+
* - `setInterval` does, so this matches what will actually fire.
|
|
429
|
+
* - `last_run_at` lags by hundreds of ms (save-job wait), and could
|
|
430
|
+
* be stale from a prior daemon process for the first interval after
|
|
431
|
+
* a restart.
|
|
432
|
+
*
|
|
433
|
+
* Returns null when auto-capture is disabled in config.
|
|
434
|
+
*
|
|
435
|
+
* Exported for tests.
|
|
436
|
+
*/
|
|
437
|
+
export function computeNextCaptureRunAt(opts) {
|
|
438
|
+
if (!opts.captureEnabled)
|
|
439
|
+
return null;
|
|
440
|
+
if (opts.intervalSeconds <= 0)
|
|
441
|
+
return null;
|
|
442
|
+
const intervalMs = opts.intervalSeconds * 1000;
|
|
443
|
+
const elapsed = Math.max(0, opts.now - opts.startTime);
|
|
444
|
+
const ticksElapsed = Math.floor(elapsed / intervalMs);
|
|
445
|
+
return new Date(opts.startTime + (ticksElapsed + 1) * intervalMs).toISOString();
|
|
446
|
+
}
|
|
447
|
+
/**
|
|
448
|
+
* Reduce the embedding-events lane to the three voyage health fields the
|
|
449
|
+
* friend-status route needs.
|
|
450
|
+
*
|
|
451
|
+
* Exported for tests so we can verify the pipeline-filter and 24h-window
|
|
452
|
+
* logic without booting Fastify or stubbing the route layer.
|
|
453
|
+
*/
|
|
454
|
+
export function computeVoyageHealth(dataDir, now) {
|
|
455
|
+
let events;
|
|
456
|
+
try {
|
|
457
|
+
events = readEmbeddingEvents(dataDir);
|
|
458
|
+
}
|
|
459
|
+
catch {
|
|
460
|
+
events = [];
|
|
461
|
+
}
|
|
462
|
+
let lastSuccessTs = null;
|
|
463
|
+
let lastErrorTs = null;
|
|
464
|
+
let lastErrorReason = null;
|
|
465
|
+
const errorCutoff = now - VOYAGE_ERROR_LOOKBACK_MS;
|
|
466
|
+
for (const event of events) {
|
|
467
|
+
// The `voyage.*` projection must reflect Voyage health only. The lane
|
|
468
|
+
// itself is provider-agnostic so a future Ollama-only install reuses
|
|
469
|
+
// the same writer, but on a mixed cloud+local install an Ollama
|
|
470
|
+
// success would otherwise refresh `voyage.last_embed_at` and mask a
|
|
471
|
+
// Voyage outage. Filter at projection time, not write time.
|
|
472
|
+
if (event.provider !== "voyage")
|
|
473
|
+
continue;
|
|
474
|
+
if (event.outcome === "success") {
|
|
475
|
+
if (!lastSuccessTs || event.ts > lastSuccessTs) {
|
|
476
|
+
lastSuccessTs = event.ts;
|
|
477
|
+
}
|
|
478
|
+
continue;
|
|
479
|
+
}
|
|
480
|
+
// outcome === "error"
|
|
481
|
+
const eventTime = Date.parse(event.ts);
|
|
482
|
+
if (Number.isNaN(eventTime) || eventTime < errorCutoff)
|
|
483
|
+
continue;
|
|
484
|
+
if (!lastErrorTs || event.ts > lastErrorTs) {
|
|
485
|
+
lastErrorTs = event.ts;
|
|
486
|
+
lastErrorReason = event.error_class ?? "unknown";
|
|
487
|
+
}
|
|
488
|
+
}
|
|
489
|
+
return {
|
|
490
|
+
last_embed_at: lastSuccessTs,
|
|
491
|
+
last_error_at: lastErrorTs,
|
|
492
|
+
last_error_reason: lastErrorReason,
|
|
493
|
+
};
|
|
494
|
+
}
|
|
495
|
+
/**
|
|
496
|
+
* Reduce the index-events lane to the three index health fields the
|
|
497
|
+
* friend-status route needs. Provider-agnostic and table-agnostic: an
|
|
498
|
+
* embed can succeed but the subsequent `table.add(...)` can fail, and
|
|
499
|
+
* `index.*` is what makes that visible. No 24h filter on `last_update_at`
|
|
500
|
+
* (a daemon that has not indexed in 7 days should still surface the
|
|
501
|
+
* stale timestamp); errors are filtered to the 24h window so old
|
|
502
|
+
* resolved incidents don't sit on the dashboard forever.
|
|
503
|
+
*/
|
|
504
|
+
export function computeIndexHealth(dataDir, now) {
|
|
505
|
+
let events;
|
|
506
|
+
try {
|
|
507
|
+
events = readIndexEvents(dataDir);
|
|
508
|
+
}
|
|
509
|
+
catch {
|
|
510
|
+
events = [];
|
|
511
|
+
}
|
|
512
|
+
let lastSuccessTs = null;
|
|
513
|
+
let lastErrorTs = null;
|
|
514
|
+
let lastErrorReason = null;
|
|
515
|
+
const errorCutoff = now - INDEX_ERROR_LOOKBACK_MS;
|
|
516
|
+
for (const event of events) {
|
|
517
|
+
if (event.outcome === "success") {
|
|
518
|
+
// Shadow-phase successes do NOT credit `last_update_at`: a row
|
|
519
|
+
// written to a shadow table is "prepared", not "searchable",
|
|
520
|
+
// until `commitAllSwaps` runs. If the swap rolls back, those
|
|
521
|
+
// rows stay invisible — so claiming a fresh index from them
|
|
522
|
+
// would lie. The post-commit "live" event is what credits the
|
|
523
|
+
// real update timestamp.
|
|
524
|
+
const phase = event.phase ?? "live";
|
|
525
|
+
if (phase !== "live")
|
|
526
|
+
continue;
|
|
527
|
+
if (!lastSuccessTs || event.ts > lastSuccessTs) {
|
|
528
|
+
lastSuccessTs = event.ts;
|
|
529
|
+
}
|
|
530
|
+
continue;
|
|
531
|
+
}
|
|
532
|
+
// Errors at any phase (including shadow) count toward
|
|
533
|
+
// `last_error_at` — a per-row LanceDB write failure during shadow
|
|
534
|
+
// population is a real failure regardless of the eventual swap.
|
|
535
|
+
const eventTime = Date.parse(event.ts);
|
|
536
|
+
if (Number.isNaN(eventTime) || eventTime < errorCutoff)
|
|
537
|
+
continue;
|
|
538
|
+
if (!lastErrorTs || event.ts > lastErrorTs) {
|
|
539
|
+
lastErrorTs = event.ts;
|
|
540
|
+
lastErrorReason = event.error_class ?? "unknown";
|
|
541
|
+
}
|
|
542
|
+
}
|
|
543
|
+
return {
|
|
544
|
+
last_update_at: lastSuccessTs,
|
|
545
|
+
last_error_at: lastErrorTs,
|
|
546
|
+
last_error_reason: lastErrorReason,
|
|
547
|
+
};
|
|
548
|
+
}
|
|
549
|
+
/**
|
|
550
|
+
* Reduce the inbox-keyed job set to the four fields the friend-status
|
|
551
|
+
* route needs. Pure over the queue's snapshot (no I/O), so tests can
|
|
552
|
+
* pass an in-memory `JobQueue` without booting Fastify.
|
|
553
|
+
*
|
|
554
|
+
* When the queue isn't wired up (deps.jobQueue undefined), this
|
|
555
|
+
* returns the empty / idle shape — the renderer treats it the same
|
|
556
|
+
* as "nothing dropped yet."
|
|
557
|
+
*
|
|
558
|
+
* Exported for tests.
|
|
559
|
+
*/
|
|
560
|
+
export function computeInboxHealth(queue, now) {
|
|
561
|
+
if (!queue) {
|
|
562
|
+
return {
|
|
563
|
+
last_import_at: null,
|
|
564
|
+
last_error_at: null,
|
|
565
|
+
last_error_reason: null,
|
|
566
|
+
pending: 0,
|
|
567
|
+
};
|
|
568
|
+
}
|
|
569
|
+
const jobs = queue.listByIdempotencyPrefix(INBOX_IDEMPOTENCY_PREFIX);
|
|
570
|
+
let lastImportTs = null;
|
|
571
|
+
let lastErrorTs = null;
|
|
572
|
+
let lastErrorReason = null;
|
|
573
|
+
let pending = 0;
|
|
574
|
+
const errorCutoff = now - INBOX_ERROR_LOOKBACK_MS;
|
|
575
|
+
for (const job of jobs) {
|
|
576
|
+
// Skip superseded jobs — the queue chains a retry by setting
|
|
577
|
+
// `retried_by` on the failed/completed parent and creating a fresh
|
|
578
|
+
// job with the same idempotency key. Counting both would let a
|
|
579
|
+
// long-resolved failure keep the "Inbox import errors" hint live
|
|
580
|
+
// for 24h after the retry already succeeded; the leaf is the only
|
|
581
|
+
// entry that reflects current state. (Same invariant the queue
|
|
582
|
+
// itself enforces in `findByIdempotencyKey`.)
|
|
583
|
+
if (job.retried_by !== undefined)
|
|
584
|
+
continue;
|
|
585
|
+
if (job.status === "queued" || job.status === "running") {
|
|
586
|
+
pending++;
|
|
587
|
+
continue;
|
|
588
|
+
}
|
|
589
|
+
if (job.status === "completed") {
|
|
590
|
+
if (!lastImportTs || job.updated_at > lastImportTs) {
|
|
591
|
+
lastImportTs = job.updated_at;
|
|
592
|
+
}
|
|
593
|
+
continue;
|
|
594
|
+
}
|
|
595
|
+
if (job.status === "failed") {
|
|
596
|
+
const eventTime = Date.parse(job.updated_at);
|
|
597
|
+
if (Number.isNaN(eventTime) || eventTime < errorCutoff)
|
|
598
|
+
continue;
|
|
599
|
+
if (!lastErrorTs || job.updated_at > lastErrorTs) {
|
|
600
|
+
lastErrorTs = job.updated_at;
|
|
601
|
+
lastErrorReason = classifyJobError(job);
|
|
602
|
+
}
|
|
603
|
+
}
|
|
604
|
+
// cancelled / interrupted: ignore — neither a successful import
|
|
605
|
+
// nor a real error the user can act on. A retry will be either
|
|
606
|
+
// queued (counted as pending) or completed/failed (counted above).
|
|
607
|
+
}
|
|
608
|
+
return {
|
|
609
|
+
last_import_at: lastImportTs,
|
|
610
|
+
last_error_at: lastErrorTs,
|
|
611
|
+
last_error_reason: lastErrorReason,
|
|
612
|
+
pending,
|
|
613
|
+
};
|
|
614
|
+
}
|
|
615
|
+
/**
|
|
616
|
+
* Best-effort short label for a failed inbox job's error. The queue
|
|
617
|
+
* stores the raw error message (`job.error`); we collapse it into a
|
|
618
|
+
* compact class keyword by substring match against the parser errors
|
|
619
|
+
* we know about, then fall back to a truncated form of the original
|
|
620
|
+
* message. Lower-cased for stability under capitalization drift.
|
|
621
|
+
*
|
|
622
|
+
* Exported for tests.
|
|
623
|
+
*/
|
|
624
|
+
export function classifyJobError(job) {
|
|
625
|
+
const raw = (job.error ?? "").trim();
|
|
626
|
+
if (!raw)
|
|
627
|
+
return "unknown";
|
|
628
|
+
const lower = raw.toLowerCase();
|
|
629
|
+
if (lower.includes("zip slip") || lower.includes("path traversal")) {
|
|
630
|
+
return "unsafe_archive";
|
|
631
|
+
}
|
|
632
|
+
if (lower.includes("too large") || lower.includes("max size")) {
|
|
633
|
+
return "size_limit";
|
|
634
|
+
}
|
|
635
|
+
if (lower.includes("unsupported source"))
|
|
636
|
+
return "unsupported_source";
|
|
637
|
+
if (lower.includes("no conversations"))
|
|
638
|
+
return "empty_export";
|
|
639
|
+
if (lower.includes("invalid json") || lower.includes("unexpected token")) {
|
|
640
|
+
return "invalid_json";
|
|
641
|
+
}
|
|
642
|
+
// ADM-ZIP throws strings like "ADM-ZIP: Invalid or unsupported zip
|
|
643
|
+
// format" when adm-zip can't open the archive at all (corrupt header,
|
|
644
|
+
// truncated CD). Distinct from `unsafe_archive` (security-blocked) —
|
|
645
|
+
// this is "the ZIP itself is broken before we can even look inside."
|
|
646
|
+
if (lower.includes("adm-zip") || lower.includes("invalid or unsupported zip")) {
|
|
647
|
+
return "invalid_archive";
|
|
648
|
+
}
|
|
649
|
+
if (lower.includes("parser"))
|
|
650
|
+
return "parser_error";
|
|
651
|
+
// Fallback: first ≤40 chars of the raw message, single-lined.
|
|
652
|
+
const snippet = raw.replace(/\s+/g, " ").slice(0, 40);
|
|
653
|
+
return snippet || "unknown";
|
|
654
|
+
}
|
|
655
|
+
export function registerFriendStatusRoute(server, deps) {
|
|
656
|
+
server.get("/status/friend", async (_request, reply) => {
|
|
657
|
+
let capabilityCounts = null;
|
|
658
|
+
try {
|
|
659
|
+
capabilityCounts = await getCapabilityCounts();
|
|
660
|
+
}
|
|
661
|
+
catch {
|
|
662
|
+
capabilityCounts = null;
|
|
663
|
+
}
|
|
664
|
+
// Stamp `useful_state_reached_at` lazily on read. The metric file
|
|
665
|
+
// lives in the shared data dir, so the MCP-side end stamper sees
|
|
666
|
+
// the same value on the next retrieval. Reuse the count snapshot
|
|
667
|
+
// computed for memory diagnostics so status polling does not count
|
|
668
|
+
// LanceDB tables twice.
|
|
669
|
+
await stampOnboardingStartIfReady(deps.config.data_paths.data_dir, {
|
|
670
|
+
capabilityCounts,
|
|
671
|
+
});
|
|
672
|
+
return reply.send(buildFriendStatusPayload(deps, { capabilityCounts }));
|
|
673
|
+
});
|
|
674
|
+
}
|
|
675
|
+
//# sourceMappingURL=friend-status.js.map
|