@cleocode/core 2026.9.8 → 2026.9.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/audit/reconstruct.d.ts +13 -43
- package/dist/audit/reconstruct.d.ts.map +1 -1
- package/dist/audit/reconstruct.js +295 -290
- package/dist/audit/reconstruct.js.map +1 -1
- package/dist/bootstrap.d.ts.map +1 -1
- package/dist/bootstrap.js +8 -2
- package/dist/bootstrap.js.map +1 -1
- package/dist/dispatch/mutate-projection.d.ts.map +1 -1
- package/dist/dispatch/mutate-projection.js +12 -0
- package/dist/dispatch/mutate-projection.js.map +1 -1
- package/dist/dispatch/mvi-projection.d.ts +29 -6
- package/dist/dispatch/mvi-projection.d.ts.map +1 -1
- package/dist/dispatch/mvi-projection.js +109 -139
- package/dist/dispatch/mvi-projection.js.map +1 -1
- package/dist/docs/docs-read-model.d.ts +3 -2
- package/dist/docs/docs-read-model.d.ts.map +1 -1
- package/dist/docs/docs-read-model.js +4 -3
- package/dist/docs/docs-read-model.js.map +1 -1
- package/dist/docs/export-document.js +5100 -2297
- package/dist/docs/export-document.js.map +3 -3
- package/dist/docs/projection.d.ts +67 -0
- package/dist/docs/projection.d.ts.map +1 -0
- package/dist/docs/projection.js +370 -0
- package/dist/docs/projection.js.map +1 -0
- package/dist/doctor/acceptance-drift.d.ts +6 -2
- package/dist/doctor/acceptance-drift.d.ts.map +1 -1
- package/dist/doctor/acceptance-drift.js +43 -5
- package/dist/doctor/acceptance-drift.js.map +1 -1
- package/dist/doctor/knowledge-summary.d.ts +41 -0
- package/dist/doctor/knowledge-summary.d.ts.map +1 -0
- package/dist/doctor/knowledge-summary.js +81 -0
- package/dist/doctor/knowledge-summary.js.map +1 -0
- package/dist/doctor/knowledge.d.ts +192 -0
- package/dist/doctor/knowledge.d.ts.map +1 -0
- package/dist/doctor/knowledge.js +1864 -0
- package/dist/doctor/knowledge.js.map +1 -0
- package/dist/git/work-tree.d.ts +64 -0
- package/dist/git/work-tree.d.ts.map +1 -0
- package/dist/git/work-tree.js +111 -0
- package/dist/git/work-tree.js.map +1 -0
- package/dist/hooks/handlers/task-hooks.d.ts +8 -5
- package/dist/hooks/handlers/task-hooks.d.ts.map +1 -1
- package/dist/hooks/handlers/task-hooks.js +15 -60
- package/dist/hooks/handlers/task-hooks.js.map +1 -1
- package/dist/identity/cleo-identity.d.ts +13 -0
- package/dist/identity/cleo-identity.d.ts.map +1 -1
- package/dist/identity/cleo-identity.js +20 -6
- package/dist/identity/cleo-identity.js.map +1 -1
- package/dist/injection.d.ts.map +1 -1
- package/dist/injection.js +29 -13
- package/dist/injection.js.map +1 -1
- package/dist/internal.d.ts +2 -0
- package/dist/internal.d.ts.map +1 -1
- package/dist/internal.js +2 -0
- package/dist/internal.js.map +1 -1
- package/dist/lifecycle/verification/satisfies-validator.d.ts.map +1 -1
- package/dist/lifecycle/verification/satisfies-validator.js +124 -120
- package/dist/lifecycle/verification/satisfies-validator.js.map +1 -1
- package/dist/llm/plugin-facade.js +4018 -1726
- package/dist/llm/plugin-facade.js.map +3 -3
- package/dist/memory/brain-backfill.d.ts +27 -12
- package/dist/memory/brain-backfill.d.ts.map +1 -1
- package/dist/memory/brain-backfill.js +325 -134
- package/dist/memory/brain-backfill.js.map +1 -1
- package/dist/memory/brain-doctor.d.ts +21 -0
- package/dist/memory/brain-doctor.d.ts.map +1 -1
- package/dist/memory/brain-doctor.js +111 -53
- package/dist/memory/brain-doctor.js.map +1 -1
- package/dist/memory/brain-links.d.ts.map +1 -1
- package/dist/memory/brain-links.js +31 -4
- package/dist/memory/brain-links.js.map +1 -1
- package/dist/memory/brain-reasoning.d.ts.map +1 -1
- package/dist/memory/brain-reasoning.js +28 -2
- package/dist/memory/brain-reasoning.js.map +1 -1
- package/dist/memory/brain-reconciler.d.ts +14 -19
- package/dist/memory/brain-reconciler.d.ts.map +1 -1
- package/dist/memory/brain-reconciler.js +70 -97
- package/dist/memory/brain-reconciler.js.map +1 -1
- package/dist/memory/brain-search.d.ts +2 -0
- package/dist/memory/brain-search.d.ts.map +1 -1
- package/dist/memory/brain-search.js +59 -29
- package/dist/memory/brain-search.js.map +1 -1
- package/dist/memory/brain-similarity.d.ts.map +1 -1
- package/dist/memory/brain-similarity.js +5 -4
- package/dist/memory/brain-similarity.js.map +1 -1
- package/dist/memory/brain-stub-prune.d.ts +31 -9
- package/dist/memory/brain-stub-prune.d.ts.map +1 -1
- package/dist/memory/brain-stub-prune.js +65 -18
- package/dist/memory/brain-stub-prune.js.map +1 -1
- package/dist/memory/brain-writer-handlers.d.ts +10 -1
- package/dist/memory/brain-writer-handlers.d.ts.map +1 -1
- package/dist/memory/brain-writer-handlers.js +23 -3
- package/dist/memory/brain-writer-handlers.js.map +1 -1
- package/dist/memory/brain-writer-thread.d.ts +11 -1
- package/dist/memory/brain-writer-thread.d.ts.map +1 -1
- package/dist/memory/brain-writer-thread.js +87 -20
- package/dist/memory/brain-writer-thread.js.map +1 -1
- package/dist/memory/brain-writer-worker.js +8 -1
- package/dist/memory/brain-writer-worker.js.map +1 -1
- package/dist/memory/decision-cross-link.d.ts +39 -0
- package/dist/memory/decision-cross-link.d.ts.map +1 -1
- package/dist/memory/decision-cross-link.js +316 -0
- package/dist/memory/decision-cross-link.js.map +1 -1
- package/dist/memory/decisions.d.ts +4 -1
- package/dist/memory/decisions.d.ts.map +1 -1
- package/dist/memory/decisions.js +7 -24
- package/dist/memory/decisions.js.map +1 -1
- package/dist/memory/dispatch-trace.d.ts +12 -5
- package/dist/memory/dispatch-trace.d.ts.map +1 -1
- package/dist/memory/dispatch-trace.js +17 -7
- package/dist/memory/dispatch-trace.js.map +1 -1
- package/dist/memory/eligibility.d.ts +51 -0
- package/dist/memory/eligibility.d.ts.map +1 -0
- package/dist/memory/eligibility.js +77 -0
- package/dist/memory/eligibility.js.map +1 -0
- package/dist/memory/engine-compat.d.ts +2 -0
- package/dist/memory/engine-compat.d.ts.map +1 -1
- package/dist/memory/engine-compat.js +10 -0
- package/dist/memory/engine-compat.js.map +1 -1
- package/dist/memory/extraction-gate.d.ts +21 -7
- package/dist/memory/extraction-gate.d.ts.map +1 -1
- package/dist/memory/extraction-gate.js +178 -216
- package/dist/memory/extraction-gate.js.map +1 -1
- package/dist/memory/graph-auto-populate.d.ts +38 -5
- package/dist/memory/graph-auto-populate.d.ts.map +1 -1
- package/dist/memory/graph-auto-populate.js +182 -60
- package/dist/memory/graph-auto-populate.js.map +1 -1
- package/dist/memory/graph-memory-bridge.d.ts +14 -1
- package/dist/memory/graph-memory-bridge.d.ts.map +1 -1
- package/dist/memory/graph-memory-bridge.js +66 -28
- package/dist/memory/graph-memory-bridge.js.map +1 -1
- package/dist/memory/index.d.ts +1 -19
- package/dist/memory/index.d.ts.map +1 -1
- package/dist/memory/index.js +1 -50
- package/dist/memory/index.js.map +1 -1
- package/dist/memory/learnings.d.ts.map +1 -1
- package/dist/memory/learnings.js +2 -23
- package/dist/memory/learnings.js.map +1 -1
- package/dist/memory/manifest-filter.d.ts +21 -0
- package/dist/memory/manifest-filter.d.ts.map +1 -0
- package/dist/memory/manifest-filter.js +51 -0
- package/dist/memory/manifest-filter.js.map +1 -0
- package/dist/memory/manifest-ingestion.d.ts +28 -30
- package/dist/memory/manifest-ingestion.d.ts.map +1 -1
- package/dist/memory/manifest-ingestion.js +104 -235
- package/dist/memory/manifest-ingestion.js.map +1 -1
- package/dist/memory/observer-reflector.d.ts +2 -0
- package/dist/memory/observer-reflector.d.ts.map +1 -1
- package/dist/memory/observer-reflector.js +6 -49
- package/dist/memory/observer-reflector.js.map +1 -1
- package/dist/memory/patterns.d.ts +10 -0
- package/dist/memory/patterns.d.ts.map +1 -1
- package/dist/memory/patterns.js +25 -33
- package/dist/memory/patterns.js.map +1 -1
- package/dist/memory/pipeline-manifest-sqlite.d.ts +72 -9
- package/dist/memory/pipeline-manifest-sqlite.d.ts.map +1 -1
- package/dist/memory/pipeline-manifest-sqlite.js +508 -412
- package/dist/memory/pipeline-manifest-sqlite.js.map +1 -1
- package/dist/memory/retrieval/build-retrieval-bundle.d.ts.map +1 -1
- package/dist/memory/retrieval/build-retrieval-bundle.js +16 -15
- package/dist/memory/retrieval/build-retrieval-bundle.js.map +1 -1
- package/dist/memory/retrieval/fetch.d.ts +7 -0
- package/dist/memory/retrieval/fetch.d.ts.map +1 -1
- package/dist/memory/retrieval/fetch.js +14 -11
- package/dist/memory/retrieval/fetch.js.map +1 -1
- package/dist/memory/retrieval/observe.d.ts +7 -1
- package/dist/memory/retrieval/observe.d.ts.map +1 -1
- package/dist/memory/retrieval/observe.js +58 -4
- package/dist/memory/retrieval/observe.js.map +1 -1
- package/dist/memory/retrieval/search.d.ts +14 -1
- package/dist/memory/retrieval/search.d.ts.map +1 -1
- package/dist/memory/retrieval/search.js +133 -69
- package/dist/memory/retrieval/search.js.map +1 -1
- package/dist/memory/retrieval/telemetry.d.ts +31 -0
- package/dist/memory/retrieval/telemetry.d.ts.map +1 -0
- package/dist/memory/retrieval/telemetry.js +53 -0
- package/dist/memory/retrieval/telemetry.js.map +1 -0
- package/dist/nexus/analyze-orchestrator.d.ts +41 -9
- package/dist/nexus/analyze-orchestrator.d.ts.map +1 -1
- package/dist/nexus/analyze-orchestrator.js +257 -58
- package/dist/nexus/analyze-orchestrator.js.map +1 -1
- package/dist/nexus/api-contracts.d.ts +2 -6
- package/dist/nexus/api-contracts.d.ts.map +1 -1
- package/dist/nexus/api-contracts.js +11 -2
- package/dist/nexus/api-contracts.js.map +1 -1
- package/dist/nexus/context.d.ts.map +1 -1
- package/dist/nexus/context.js +14 -37
- package/dist/nexus/context.js.map +1 -1
- package/dist/nexus/diff.d.ts.map +1 -1
- package/dist/nexus/diff.js +2 -1
- package/dist/nexus/diff.js.map +1 -1
- package/dist/nexus/identity.d.ts +29 -3
- package/dist/nexus/identity.d.ts.map +1 -1
- package/dist/nexus/identity.js +63 -12
- package/dist/nexus/identity.js.map +1 -1
- package/dist/nexus/impact.d.ts +21 -19
- package/dist/nexus/impact.d.ts.map +1 -1
- package/dist/nexus/impact.js +96 -192
- package/dist/nexus/impact.js.map +1 -1
- package/dist/nexus/knowledge.d.ts +80 -0
- package/dist/nexus/knowledge.d.ts.map +1 -0
- package/dist/nexus/knowledge.js +786 -0
- package/dist/nexus/knowledge.js.map +1 -0
- package/dist/nexus/living-brain.d.ts +8 -5
- package/dist/nexus/living-brain.d.ts.map +1 -1
- package/dist/nexus/living-brain.js +252 -188
- package/dist/nexus/living-brain.js.map +1 -1
- package/dist/nexus/registry.d.ts +11 -2
- package/dist/nexus/registry.d.ts.map +1 -1
- package/dist/nexus/registry.js +144 -128
- package/dist/nexus/registry.js.map +1 -1
- package/dist/nexus/source-roots.d.ts +16 -0
- package/dist/nexus/source-roots.d.ts.map +1 -0
- package/dist/nexus/source-roots.js +174 -0
- package/dist/nexus/source-roots.js.map +1 -0
- package/dist/nexus/task-evidence.d.ts +22 -0
- package/dist/nexus/task-evidence.d.ts.map +1 -0
- package/dist/nexus/task-evidence.js +210 -0
- package/dist/nexus/task-evidence.js.map +1 -0
- package/dist/nexus/tasks-bridge.d.ts +14 -7
- package/dist/nexus/tasks-bridge.d.ts.map +1 -1
- package/dist/nexus/tasks-bridge.js +81 -40
- package/dist/nexus/tasks-bridge.js.map +1 -1
- package/dist/orchestrate/lifecycle-ops.d.ts.map +1 -1
- package/dist/orchestrate/lifecycle-ops.js +170 -120
- package/dist/orchestrate/lifecycle-ops.js.map +1 -1
- package/dist/orchestrate/query-ops.d.ts +6 -7
- package/dist/orchestrate/query-ops.d.ts.map +1 -1
- package/dist/orchestrate/query-ops.js +509 -532
- package/dist/orchestrate/query-ops.js.map +1 -1
- package/dist/orchestration/bootstrap.d.ts +15 -1
- package/dist/orchestration/bootstrap.d.ts.map +1 -1
- package/dist/orchestration/bootstrap.js +21 -10
- package/dist/orchestration/bootstrap.js.map +1 -1
- package/dist/orchestration/index.d.ts +35 -3
- package/dist/orchestration/index.d.ts.map +1 -1
- package/dist/orchestration/index.js +64 -35
- package/dist/orchestration/index.js.map +1 -1
- package/dist/orchestration/lead-rollup.d.ts +24 -1
- package/dist/orchestration/lead-rollup.d.ts.map +1 -1
- package/dist/orchestration/lead-rollup.js +31 -11
- package/dist/orchestration/lead-rollup.js.map +1 -1
- package/dist/orchestration/spawn-prompt.d.ts.map +1 -1
- package/dist/orchestration/spawn-prompt.js +16 -41
- package/dist/orchestration/spawn-prompt.js.map +1 -1
- package/dist/orchestration/unblock.d.ts +15 -1
- package/dist/orchestration/unblock.d.ts.map +1 -1
- package/dist/orchestration/unblock.js +23 -12
- package/dist/orchestration/unblock.js.map +1 -1
- package/dist/orchestration/validate-spawn.d.ts.map +1 -1
- package/dist/orchestration/validate-spawn.js +3 -3
- package/dist/orchestration/validate-spawn.js.map +1 -1
- package/dist/orchestration/waves.d.ts +29 -13
- package/dist/orchestration/waves.d.ts.map +1 -1
- package/dist/orchestration/waves.js +43 -55
- package/dist/orchestration/waves.js.map +1 -1
- package/dist/paths.d.ts +17 -163
- package/dist/paths.d.ts.map +1 -1
- package/dist/paths.js +145 -496
- package/dist/paths.js.map +1 -1
- package/dist/project-info.d.ts +2 -11
- package/dist/project-info.d.ts.map +1 -1
- package/dist/project-info.js +3 -31
- package/dist/project-info.js.map +1 -1
- package/dist/project-scope.d.ts +239 -0
- package/dist/project-scope.d.ts.map +1 -0
- package/dist/project-scope.js +473 -0
- package/dist/project-scope.js.map +1 -0
- package/dist/release/pr-evidence.d.ts +16 -3
- package/dist/release/pr-evidence.d.ts.map +1 -1
- package/dist/release/pr-evidence.js +53 -7
- package/dist/release/pr-evidence.js.map +1 -1
- package/dist/render/nexus/graph/index.d.ts.map +1 -1
- package/dist/render/nexus/graph/index.js +4 -2
- package/dist/render/nexus/graph/index.js.map +1 -1
- package/dist/render/orchestration/audit-reconstruct.d.ts +11 -0
- package/dist/render/orchestration/audit-reconstruct.d.ts.map +1 -1
- package/dist/render/orchestration/audit-reconstruct.js +21 -6
- package/dist/render/orchestration/audit-reconstruct.js.map +1 -1
- package/dist/render/tasks/show.js +2 -1
- package/dist/render/tasks/show.js.map +1 -1
- package/dist/resources/spawn-wrapper.d.ts +82 -14
- package/dist/resources/spawn-wrapper.d.ts.map +1 -1
- package/dist/resources/spawn-wrapper.js +585 -27
- package/dist/resources/spawn-wrapper.js.map +1 -1
- package/dist/selfimprove/fix-gen.js +4026 -1734
- package/dist/selfimprove/fix-gen.js.map +3 -3
- package/dist/sequence/index.d.ts.map +1 -1
- package/dist/sequence/index.js +76 -68
- package/dist/sequence/index.js.map +1 -1
- package/dist/session/canon-lint.d.ts +24 -3
- package/dist/session/canon-lint.d.ts.map +1 -1
- package/dist/session/canon-lint.js +72 -31
- package/dist/session/canon-lint.js.map +1 -1
- package/dist/session/engine-ops.d.ts +1 -4
- package/dist/session/engine-ops.d.ts.map +1 -1
- package/dist/session/engine-ops.js +6 -2
- package/dist/session/engine-ops.js.map +1 -1
- package/dist/sessions/briefing.d.ts +11 -1
- package/dist/sessions/briefing.d.ts.map +1 -1
- package/dist/sessions/briefing.js +76 -8
- package/dist/sessions/briefing.js.map +1 -1
- package/dist/sessions/handoff.d.ts +3 -1
- package/dist/sessions/handoff.d.ts.map +1 -1
- package/dist/sessions/handoff.js +2 -0
- package/dist/sessions/handoff.js.map +1 -1
- package/dist/shutdown-deadline.d.ts +24 -33
- package/dist/shutdown-deadline.d.ts.map +1 -1
- package/dist/shutdown-deadline.js +71 -14
- package/dist/shutdown-deadline.js.map +1 -1
- package/dist/shutdown.d.ts +21 -10
- package/dist/shutdown.d.ts.map +1 -1
- package/dist/shutdown.js +89 -42
- package/dist/shutdown.js.map +1 -1
- package/dist/skills/index.d.ts +1 -1
- package/dist/skills/index.d.ts.map +1 -1
- package/dist/skills/index.js +1 -1
- package/dist/skills/index.js.map +1 -1
- package/dist/skills/orchestrator/validator.d.ts +87 -20
- package/dist/skills/orchestrator/validator.d.ts.map +1 -1
- package/dist/skills/orchestrator/validator.js +330 -241
- package/dist/skills/orchestrator/validator.js.map +1 -1
- package/dist/store/agent-resolver.d.ts.map +1 -1
- package/dist/store/agent-resolver.js +16 -9
- package/dist/store/agent-resolver.js.map +1 -1
- package/dist/store/attachment-store.d.ts +4 -1
- package/dist/store/attachment-store.d.ts.map +1 -1
- package/dist/store/attachment-store.js +20 -3
- package/dist/store/attachment-store.js.map +1 -1
- package/dist/store/background-jobs.d.ts +426 -105
- package/dist/store/background-jobs.d.ts.map +1 -1
- package/dist/store/background-jobs.js +1208 -252
- package/dist/store/background-jobs.js.map +1 -1
- package/dist/store/background-ops.d.ts +145 -8
- package/dist/store/background-ops.d.ts.map +1 -1
- package/dist/store/background-ops.js +459 -15
- package/dist/store/background-ops.js.map +1 -1
- package/dist/store/backup-inspect.d.ts +48 -4
- package/dist/store/backup-inspect.d.ts.map +1 -1
- package/dist/store/backup-inspect.js +384 -4
- package/dist/store/backup-inspect.js.map +1 -1
- package/dist/store/converters.d.ts.map +1 -1
- package/dist/store/converters.js +19 -2
- package/dist/store/converters.js.map +1 -1
- package/dist/store/data-accessor.d.ts +9 -1
- package/dist/store/data-accessor.d.ts.map +1 -1
- package/dist/store/data-accessor.js +22 -5
- package/dist/store/data-accessor.js.map +1 -1
- package/dist/store/data-safety-central.d.ts.map +1 -1
- package/dist/store/data-safety-central.js +272 -232
- package/dist/store/data-safety-central.js.map +1 -1
- package/dist/store/db-helpers.d.ts +19 -3
- package/dist/store/db-helpers.d.ts.map +1 -1
- package/dist/store/db-helpers.js +42 -58
- package/dist/store/db-helpers.js.map +1 -1
- package/dist/store/dual-scope-db.d.ts +63 -4
- package/dist/store/dual-scope-db.d.ts.map +1 -1
- package/dist/store/dual-scope-db.js +166 -19
- package/dist/store/dual-scope-db.js.map +1 -1
- package/dist/store/exodus/archive.d.ts +21 -7
- package/dist/store/exodus/archive.d.ts.map +1 -1
- package/dist/store/exodus/archive.js +60 -18
- package/dist/store/exodus/archive.js.map +1 -1
- package/dist/store/exodus/migrate.d.ts.map +1 -1
- package/dist/store/exodus/migrate.js +27 -23
- package/dist/store/exodus/migrate.js.map +1 -1
- package/dist/store/exodus/on-open.d.ts +16 -27
- package/dist/store/exodus/on-open.d.ts.map +1 -1
- package/dist/store/exodus/on-open.js +121 -169
- package/dist/store/exodus/on-open.js.map +1 -1
- package/dist/store/exodus/recovery.d.ts +90 -0
- package/dist/store/exodus/recovery.d.ts.map +1 -0
- package/dist/store/exodus/recovery.js +434 -0
- package/dist/store/exodus/recovery.js.map +1 -0
- package/dist/store/exodus/types.d.ts +15 -0
- package/dist/store/exodus/types.d.ts.map +1 -1
- package/dist/store/memory-accessor.d.ts +52 -3
- package/dist/store/memory-accessor.d.ts.map +1 -1
- package/dist/store/memory-accessor.js +122 -7
- package/dist/store/memory-accessor.js.map +1 -1
- package/dist/store/nexus-sqlite.d.ts +24 -6
- package/dist/store/nexus-sqlite.d.ts.map +1 -1
- package/dist/store/nexus-sqlite.js +39 -20
- package/dist/store/nexus-sqlite.js.map +1 -1
- package/dist/store/ports/domain-binding.d.ts.map +1 -1
- package/dist/store/ports/domain-binding.js +27 -5
- package/dist/store/ports/domain-binding.js.map +1 -1
- package/dist/store/schema/background-jobs.d.ts +181 -2
- package/dist/store/schema/background-jobs.d.ts.map +1 -1
- package/dist/store/schema/background-jobs.js +27 -3
- package/dist/store/schema/background-jobs.js.map +1 -1
- package/dist/store/schema/cleo-global/skills.d.ts +2 -2
- package/dist/store/schema/cleo-project/lifecycle.d.ts +2 -2
- package/dist/store/schema/cleo-project/runtime.d.ts +1 -1
- package/dist/store/schema/cleo-project/tasks-core.d.ts +1 -1
- package/dist/store/schema/lifecycle.d.ts +2 -2
- package/dist/store/schema/skills-schema.d.ts +2 -2
- package/dist/store/schema/tasks.d.ts +1 -1
- package/dist/store/session-store.d.ts +3 -1
- package/dist/store/session-store.d.ts.map +1 -1
- package/dist/store/session-store.js +252 -207
- package/dist/store/session-store.js.map +1 -1
- package/dist/store/sqlite-data-accessor.d.ts +39 -4
- package/dist/store/sqlite-data-accessor.d.ts.map +1 -1
- package/dist/store/sqlite-data-accessor.js +689 -527
- package/dist/store/sqlite-data-accessor.js.map +1 -1
- package/dist/store/tasks-sqlite.d.ts +3 -1
- package/dist/store/tasks-sqlite.d.ts.map +1 -1
- package/dist/store/tasks-sqlite.js +309 -279
- package/dist/store/tasks-sqlite.js.map +1 -1
- package/dist/store/validation-schemas.d.ts +8 -8
- package/dist/store/writer-lease.d.ts +80 -8
- package/dist/store/writer-lease.d.ts.map +1 -1
- package/dist/store/writer-lease.js +503 -134
- package/dist/store/writer-lease.js.map +1 -1
- package/dist/system/audit.d.ts +2 -1
- package/dist/system/audit.d.ts.map +1 -1
- package/dist/system/audit.js +118 -71
- package/dist/system/audit.js.map +1 -1
- package/dist/system/backup.d.ts.map +1 -1
- package/dist/system/backup.js +5 -5
- package/dist/system/backup.js.map +1 -1
- package/dist/system/inject-generate.js +1 -1
- package/dist/task-work/index.d.ts +3 -0
- package/dist/task-work/index.d.ts.map +1 -1
- package/dist/task-work/index.js +34 -37
- package/dist/task-work/index.js.map +1 -1
- package/dist/tasks/ac-coverage-gate.d.ts.map +1 -1
- package/dist/tasks/ac-coverage-gate.js +4 -0
- package/dist/tasks/ac-coverage-gate.js.map +1 -1
- package/dist/tasks/ac-immutability.d.ts +7 -4
- package/dist/tasks/ac-immutability.d.ts.map +1 -1
- package/dist/tasks/ac-immutability.js +19 -17
- package/dist/tasks/ac-immutability.js.map +1 -1
- package/dist/tasks/ac-table.d.ts +5 -5
- package/dist/tasks/ac-table.d.ts.map +1 -1
- package/dist/tasks/ac-table.js +26 -12
- package/dist/tasks/ac-table.js.map +1 -1
- package/dist/tasks/acceptance-input.d.ts +52 -0
- package/dist/tasks/acceptance-input.d.ts.map +1 -0
- package/dist/tasks/acceptance-input.js +259 -0
- package/dist/tasks/acceptance-input.js.map +1 -0
- package/dist/tasks/add.d.ts +67 -29
- package/dist/tasks/add.d.ts.map +1 -1
- package/dist/tasks/add.js +255 -97
- package/dist/tasks/add.js.map +1 -1
- package/dist/tasks/complete.d.ts +16 -1
- package/dist/tasks/complete.d.ts.map +1 -1
- package/dist/tasks/complete.js +152 -55
- package/dist/tasks/complete.js.map +1 -1
- package/dist/tasks/decompose.d.ts +103 -0
- package/dist/tasks/decompose.d.ts.map +1 -0
- package/dist/tasks/decompose.js +224 -0
- package/dist/tasks/decompose.js.map +1 -0
- package/dist/tasks/delete.d.ts +5 -8
- package/dist/tasks/delete.d.ts.map +1 -1
- package/dist/tasks/delete.js +4 -3
- package/dist/tasks/delete.js.map +1 -1
- package/dist/tasks/dependency-check.d.ts +59 -0
- package/dist/tasks/dependency-check.d.ts.map +1 -1
- package/dist/tasks/dependency-check.js +73 -0
- package/dist/tasks/dependency-check.js.map +1 -1
- package/dist/tasks/deps-ready.d.ts +13 -1
- package/dist/tasks/deps-ready.d.ts.map +1 -1
- package/dist/tasks/deps-ready.js +16 -5
- package/dist/tasks/deps-ready.js.map +1 -1
- package/dist/tasks/engine-converters.d.ts +7 -0
- package/dist/tasks/engine-converters.d.ts.map +1 -1
- package/dist/tasks/engine-converters.js +8 -1
- package/dist/tasks/engine-converters.js.map +1 -1
- package/dist/tasks/evidence.d.ts +54 -26
- package/dist/tasks/evidence.d.ts.map +1 -1
- package/dist/tasks/evidence.js +292 -40
- package/dist/tasks/evidence.js.map +1 -1
- package/dist/tasks/find.d.ts +16 -12
- package/dist/tasks/find.d.ts.map +1 -1
- package/dist/tasks/find.js +107 -93
- package/dist/tasks/find.js.map +1 -1
- package/dist/tasks/gate-runner.d.ts +88 -14
- package/dist/tasks/gate-runner.d.ts.map +1 -1
- package/dist/tasks/gate-runner.js +596 -253
- package/dist/tasks/gate-runner.js.map +1 -1
- package/dist/tasks/hierarchy-policy.d.ts +8 -0
- package/dist/tasks/hierarchy-policy.d.ts.map +1 -1
- package/dist/tasks/hierarchy-policy.js +9 -2
- package/dist/tasks/hierarchy-policy.js.map +1 -1
- package/dist/tasks/hierarchy.d.ts +67 -1
- package/dist/tasks/hierarchy.d.ts.map +1 -1
- package/dist/tasks/hierarchy.js +81 -1
- package/dist/tasks/hierarchy.js.map +1 -1
- package/dist/tasks/index.d.ts +3 -0
- package/dist/tasks/index.d.ts.map +1 -1
- package/dist/tasks/index.js +3 -0
- package/dist/tasks/index.js.map +1 -1
- package/dist/tasks/infer-add-params.d.ts +1 -20
- package/dist/tasks/infer-add-params.d.ts.map +1 -1
- package/dist/tasks/infer-add-params.js +2 -203
- package/dist/tasks/infer-add-params.js.map +1 -1
- package/dist/tasks/list.d.ts +7 -2
- package/dist/tasks/list.d.ts.map +1 -1
- package/dist/tasks/list.js +24 -36
- package/dist/tasks/list.js.map +1 -1
- package/dist/tasks/ops.d.ts +6 -61
- package/dist/tasks/ops.d.ts.map +1 -1
- package/dist/tasks/ops.js +5 -53
- package/dist/tasks/ops.js.map +1 -1
- package/dist/tasks/plan.d.ts +15 -1
- package/dist/tasks/plan.d.ts.map +1 -1
- package/dist/tasks/plan.js +23 -25
- package/dist/tasks/plan.js.map +1 -1
- package/dist/tasks/population.d.ts +46 -0
- package/dist/tasks/population.d.ts.map +1 -0
- package/dist/tasks/population.js +88 -0
- package/dist/tasks/population.js.map +1 -0
- package/dist/tasks/reconcile-scope.d.ts +157 -0
- package/dist/tasks/reconcile-scope.d.ts.map +1 -0
- package/dist/tasks/reconcile-scope.js +242 -0
- package/dist/tasks/reconcile-scope.js.map +1 -0
- package/dist/tasks/req.d.ts +51 -12
- package/dist/tasks/req.d.ts.map +1 -1
- package/dist/tasks/req.js +125 -69
- package/dist/tasks/req.js.map +1 -1
- package/dist/tasks/session-scope.d.ts +6 -31
- package/dist/tasks/session-scope.d.ts.map +1 -1
- package/dist/tasks/session-scope.js +3 -17
- package/dist/tasks/session-scope.js.map +1 -1
- package/dist/tasks/severity-attestation.d.ts +39 -10
- package/dist/tasks/severity-attestation.d.ts.map +1 -1
- package/dist/tasks/severity-attestation.js +75 -36
- package/dist/tasks/severity-attestation.js.map +1 -1
- package/dist/tasks/task-next.d.ts +5 -0
- package/dist/tasks/task-next.d.ts.map +1 -1
- package/dist/tasks/task-next.js +10 -9
- package/dist/tasks/task-next.js.map +1 -1
- package/dist/tasks/task-reparent.d.ts.map +1 -1
- package/dist/tasks/task-reparent.js +3 -13
- package/dist/tasks/task-reparent.js.map +1 -1
- package/dist/tasks/update.d.ts +20 -43
- package/dist/tasks/update.d.ts.map +1 -1
- package/dist/tasks/update.js +64 -49
- package/dist/tasks/update.js.map +1 -1
- package/dist/validation/engine-ops.d.ts +17 -1
- package/dist/validation/engine-ops.d.ts.map +1 -1
- package/dist/validation/engine-ops.js +149 -11
- package/dist/validation/engine-ops.js.map +1 -1
- package/dist/workgraph/reparent-preflight.d.ts +1 -1
- package/dist/workgraph/reparent-preflight.d.ts.map +1 -1
- package/dist/workgraph/reparent-preflight.js +6 -1
- package/dist/workgraph/reparent-preflight.js.map +1 -1
- package/dist/workgraph/scaffold-apply.d.ts.map +1 -1
- package/dist/workgraph/scaffold-apply.js +81 -76
- package/dist/workgraph/scaffold-apply.js.map +1 -1
- package/dist/workgraph/structure-validation.d.ts +1 -1
- package/dist/workgraph/structure-validation.d.ts.map +1 -1
- package/dist/workgraph/structure-validation.js +6 -1
- package/dist/workgraph/structure-validation.js.map +1 -1
- package/migrations/drizzle-tasks/20260919180000_t12263-job-ownership-fences/migration.sql +34 -0
- package/migrations/drizzle-tasks/20260919184500_t12265-durable-pending-proposals/migration.sql +4 -0
- package/package.json +18 -13
- package/schemas/config.schema.json +2 -2
- package/templates/CLEO-INJECTION.md +103 -101
|
@@ -1,171 +1,492 @@
|
|
|
1
|
-
|
|
2
|
-
* Background Job Manager for Long-Running Operations
|
|
3
|
-
*
|
|
4
|
-
* Operations that may take >30s support async execution. This module
|
|
5
|
-
* provides a job manager backed by a SQLite DurableJobStore so that job
|
|
6
|
-
* state survives process restart. Any job recorded as `running` in the
|
|
7
|
-
* database at construction time is immediately transitioned to `orphaned`
|
|
8
|
-
* so that humans/agents can triage it — no silent retry.
|
|
9
|
-
*
|
|
10
|
-
* @remarks
|
|
11
|
-
* Relocated from `packages/cleo/src/dispatch/lib/background-jobs.ts` into
|
|
12
|
-
* `@cleocode/core/store` (R3-K1 · T11455 · SG-RUNTIME-UNIFICATION). This is
|
|
13
|
-
* Drizzle DB-access logic, so it belongs in `@cleocode/core` — the package that
|
|
14
|
-
* owns the consolidated SQLite schema, the single Drizzle instance, and the DB
|
|
15
|
-
* handle types. Hosting it here means there is exactly ONE `drizzle-orm`
|
|
16
|
-
* instance backing the query builders (no dual peer-hashed instance / `tsc -b`
|
|
17
|
-
* `SQL<unknown>` nominal mismatch). `@cleocode/runtime/gateway` imports the
|
|
18
|
-
* accessor from here and declares no `drizzle-orm` dependency of its own.
|
|
19
|
-
*
|
|
20
|
-
* @task T641
|
|
21
|
-
* @task T11455
|
|
22
|
-
*/
|
|
1
|
+
import type { AtomicJobBookkeeping, AtomicJobMutation, AtomicJobRetryBookkeeping, BackgroundJobCandidatePage, BackgroundJobExecutionContext, BackgroundJobFailureCode, BackgroundJobLease, BackgroundJobPageQuery, BackgroundJobStoreOptions, BackgroundJobSubmission, JobAttemptOutcome, JobFinalizationResult, OperationExecutionContext } from '@cleocode/contracts/jobs';
|
|
23
2
|
import type { NodeSQLiteDatabase } from './sqlite.js';
|
|
24
3
|
import { type BackgroundJobStatus } from './tasks-schema.js';
|
|
25
4
|
export type { BackgroundJobStatus };
|
|
26
|
-
/**
|
|
27
|
-
* Background job representation returned by public API methods.
|
|
28
|
-
*
|
|
29
|
-
* Timestamps are ISO-8601 strings so callers do not need to know that the
|
|
30
|
-
* database stores them as integer milliseconds.
|
|
31
|
-
*/
|
|
5
|
+
/** Inspectable durable job, including unresolved legacy scope and ownership. */
|
|
32
6
|
export interface BackgroundJob {
|
|
33
|
-
/** Unique job
|
|
7
|
+
/** Unique persisted job ID. */
|
|
34
8
|
id: string;
|
|
35
|
-
/**
|
|
9
|
+
/** Supported operation name. */
|
|
36
10
|
operation: string;
|
|
37
|
-
/**
|
|
11
|
+
/** Persisted lifecycle status; cancellation requests are separate. */
|
|
38
12
|
status: BackgroundJobStatus;
|
|
39
|
-
/** ISO-8601
|
|
13
|
+
/** ISO-8601 creation time. */
|
|
40
14
|
startedAt: string;
|
|
41
|
-
/** ISO-8601
|
|
15
|
+
/** ISO-8601 terminal time, if committed. */
|
|
42
16
|
completedAt?: string;
|
|
43
|
-
/**
|
|
17
|
+
/** Existing executor result surface. */
|
|
44
18
|
result?: unknown;
|
|
45
|
-
/**
|
|
19
|
+
/** Persisted executor error, when failed. */
|
|
46
20
|
error?: string;
|
|
47
|
-
/**
|
|
21
|
+
/** Last reported percentage. */
|
|
48
22
|
progress?: number;
|
|
49
|
-
/**
|
|
23
|
+
/** Actor display identity, distinct from the unique lease owner. */
|
|
50
24
|
claimedBy?: string;
|
|
25
|
+
/** Explicit project identity; null discloses unresolved legacy scope. */
|
|
26
|
+
projectId: string | null;
|
|
27
|
+
/** Unique owner of the current claim; null on legacy unowned rows. */
|
|
28
|
+
ownerId: string | null;
|
|
29
|
+
/** Current lease expiration in epoch milliseconds. */
|
|
30
|
+
leaseExpiresAt: number | null;
|
|
31
|
+
/** Last heartbeat in epoch milliseconds. */
|
|
32
|
+
heartbeatAt: number;
|
|
33
|
+
/** Monotonic claim fence. */
|
|
34
|
+
fencingEpoch: number;
|
|
35
|
+
/** Number of issued execution claims. */
|
|
36
|
+
attempts: number;
|
|
37
|
+
/** Persisted cancellation request; does not assert executor termination. */
|
|
38
|
+
cancellationRequestedAt: number | null;
|
|
39
|
+
/** Last fenced JSON checkpoint bytes. */
|
|
40
|
+
checkpointJson: string | null;
|
|
41
|
+
/** Last checkpoint timestamp in epoch milliseconds. */
|
|
42
|
+
checkpointAt: number | null;
|
|
43
|
+
/** Project/operation-scoped retry key. */
|
|
44
|
+
idempotencyKey: string | null;
|
|
45
|
+
/** SHA-256 of immutable proposal bytes. */
|
|
46
|
+
proposalHash: string | null;
|
|
47
|
+
/** Authentic immutable input bytes; null means the original payload is unavailable. */
|
|
48
|
+
proposalJson: string | null;
|
|
49
|
+
/** Ownership assessment at read time, independent of lifecycle status. */
|
|
50
|
+
ownership: 'current' | 'expired' | 'unclaimed' | 'legacy-unknown' | 'terminal';
|
|
51
|
+
/** Explicit diagnostic failure, when result decoding or local persistence failed. */
|
|
52
|
+
diagnosticError?: string;
|
|
51
53
|
}
|
|
52
|
-
/**
|
|
53
|
-
|
|
54
|
-
*/
|
|
55
|
-
export interface BackgroundJobManagerConfig {
|
|
56
|
-
/** Maximum number of concurrently *running* jobs. Default: 10. */
|
|
54
|
+
/** Configuration for the existing executor facade. */
|
|
55
|
+
export interface BackgroundJobManagerConfig extends BackgroundJobStoreOptions {
|
|
56
|
+
/** Maximum running jobs observed in this client's project scope. */
|
|
57
57
|
maxJobs?: number;
|
|
58
|
-
/**
|
|
58
|
+
/** Former retention window. @deprecated Job evidence is retained regardless of age. */
|
|
59
59
|
retentionMs?: number;
|
|
60
60
|
}
|
|
61
|
-
type TasksDb = NodeSQLiteDatabase;
|
|
62
61
|
/**
|
|
63
|
-
*
|
|
64
|
-
*
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
62
|
+
* Stable refusal of an unsafe ownership, retry, or transaction operation.
|
|
63
|
+
* @remarks A refusal preserves the current owner's work and reports no committed transition.
|
|
64
|
+
*/
|
|
65
|
+
export declare class BackgroundJobError extends Error {
|
|
66
|
+
/** Machine-readable refusal reason. */
|
|
67
|
+
readonly code: BackgroundJobFailureCode;
|
|
68
|
+
/**
|
|
69
|
+
* Construct an explicit job-store refusal.
|
|
70
|
+
* @param code - Stable failure category.
|
|
71
|
+
* @param message - Human-readable reason and required correction.
|
|
72
|
+
* @remarks This error never establishes successful job execution.
|
|
73
|
+
* @example
|
|
74
|
+
* ```ts
|
|
75
|
+
* throw new BackgroundJobError('E_JOB_LEASE_LOST', 'Reclaim expired work first');
|
|
76
|
+
* ```
|
|
77
|
+
*/
|
|
78
|
+
constructor(code: BackgroundJobFailureCode, message: string);
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Revalidate captured job ownership inside the domain's existing write transaction.
|
|
82
|
+
* @param db - The same transaction handle that will perform the domain mutation.
|
|
83
|
+
* @param execution - Captured lifetime and optional immutable job fence.
|
|
84
|
+
* @throws BackgroundJobError when ownership, scope, proposal, cancellation or file identity changed.
|
|
85
|
+
* @remarks This read does not start a transaction or authorize arbitrary work. Callers
|
|
86
|
+
* must own the surrounding write transaction and independently validate their domain
|
|
87
|
+
* preconditions. Keeping this check inside that transaction fences concurrent claims
|
|
88
|
+
* and permits domain mutations and receipts to compose in one atomic unit.
|
|
89
|
+
* @example
|
|
90
|
+
* ```ts
|
|
91
|
+
* db.transaction(tx => { assertOperationWriteFence(tx, execution); writePreparedRows(tx); });
|
|
92
|
+
* ```
|
|
93
|
+
*/
|
|
94
|
+
export declare function assertOperationWriteFence(db: Pick<NodeSQLiteDatabase, 'select'>, execution: OperationExecutionContext): void;
|
|
95
|
+
/**
|
|
96
|
+
* Drizzle-backed ownership of the established active job table.
|
|
97
|
+
* @remarks Sync methods refuse an already-owned native transaction before writing.
|
|
98
|
+
* No method infers a missing legacy lease to be expired. Rows are never age-pruned.
|
|
99
|
+
* @example
|
|
100
|
+
* ```ts
|
|
101
|
+
* const jobs = new DurableJobStore(db, { projectId: 'project-uuid' });
|
|
102
|
+
* const lease = jobs.insert('job-uuid', 'doctor.knowledge', Date.now());
|
|
103
|
+
* if (lease) jobs.complete(lease.jobId, { verified: true }, Date.now());
|
|
104
|
+
* ```
|
|
70
105
|
*/
|
|
71
106
|
export declare class DurableJobStore {
|
|
72
107
|
#private;
|
|
73
|
-
|
|
108
|
+
/** Positive lease duration used for claims and heartbeats. */
|
|
109
|
+
readonly leaseMs: number;
|
|
110
|
+
/**
|
|
111
|
+
* Open a client without changing persisted work.
|
|
112
|
+
* @param db - Existing canonical database handle; no new connection is opened.
|
|
113
|
+
* @param options - Explicit scope, actor, and lease duration.
|
|
114
|
+
* @remarks Unscoped legacy callers retain visible null project identity.
|
|
115
|
+
* @example
|
|
116
|
+
* ```ts
|
|
117
|
+
* const store = new DurableJobStore(db, { projectId: 'project-uuid', leaseMs: 30000 });
|
|
118
|
+
* ```
|
|
119
|
+
*/
|
|
120
|
+
constructor(db: NodeSQLiteDatabase, options?: BackgroundJobStoreOptions);
|
|
121
|
+
/**
|
|
122
|
+
* Create a leased job, or return the existing immutable scoped submission.
|
|
123
|
+
* @param id - Proposed UUID for a new job.
|
|
124
|
+
* @param operation - Supported operation identifier.
|
|
125
|
+
* @param now - Event timestamp in epoch milliseconds.
|
|
126
|
+
* @param submission - Optional scoped immutable retry contract.
|
|
127
|
+
* @param maxRunning - Optional running-job limit checked atomically with creation.
|
|
128
|
+
* @returns Grant for new work, or null when an identical submission already exists.
|
|
129
|
+
* @remarks A repeated submission never acquires ownership or re-executes by itself.
|
|
130
|
+
* @example
|
|
131
|
+
* ```ts
|
|
132
|
+
* const grant = store.insert(id, 'doctor.knowledge', Date.now(), submission);
|
|
133
|
+
* ```
|
|
134
|
+
*/
|
|
135
|
+
insert(id: string, operation: string, now: number, submission?: BackgroundJobSubmission, maxRunning?: number): BackgroundJobLease | null;
|
|
136
|
+
/**
|
|
137
|
+
* Find an existing immutable submission without claiming it.
|
|
138
|
+
* @param operation - Exact supported operation.
|
|
139
|
+
* @param submission - Project and retry identity.
|
|
140
|
+
* @returns Persisted job, or undefined.
|
|
141
|
+
* @remarks Input conflict validation is performed by insert before coalescing.
|
|
142
|
+
* @example
|
|
143
|
+
* ```ts
|
|
144
|
+
* const prior = store.findSubmission('doctor.knowledge', submission);
|
|
145
|
+
* ```
|
|
146
|
+
*/
|
|
147
|
+
findSubmission(operation: string, submission: BackgroundJobSubmission): BackgroundJob | undefined;
|
|
74
148
|
/**
|
|
75
|
-
*
|
|
76
|
-
*
|
|
77
|
-
* @param
|
|
78
|
-
* @param
|
|
79
|
-
* @param
|
|
149
|
+
* Persist authentic pending work without claiming or starting an executor.
|
|
150
|
+
* @param id - Proposed job identity; matching retries retain the original identity.
|
|
151
|
+
* @param operation - Exact operation whose supported inputs the domain service validates.
|
|
152
|
+
* @param now - Submission timestamp in epoch milliseconds.
|
|
153
|
+
* @param submission - Required project-scoped immutable serialized proposal.
|
|
154
|
+
* @param execution - Optional original invocation budget; omitted legacy callers retain existing behavior.
|
|
155
|
+
* @returns Persisted pending job, or unchanged prior matching submission.
|
|
156
|
+
* @remarks Input and its hash commit in one native transaction. Existing history
|
|
157
|
+
* without payload is retained, never reconstructed from a hash or overwritten.
|
|
158
|
+
* @example
|
|
159
|
+
* ```ts
|
|
160
|
+
* const pending = store.defer(id, 'docs.projection', Date.now(), submission);
|
|
161
|
+
* ```
|
|
80
162
|
*/
|
|
81
|
-
|
|
163
|
+
defer(id: string, operation: string, now: number, submission: BackgroundJobSubmission, execution?: OperationExecutionContext): BackgroundJob;
|
|
82
164
|
/**
|
|
83
|
-
*
|
|
165
|
+
* Read a job with scope and ownership disclosed.
|
|
166
|
+
* @param id - Job identity.
|
|
167
|
+
* @returns Job or undefined.
|
|
168
|
+
* @remarks A missing or expired lease is never represented as current ownership.
|
|
169
|
+
* @example
|
|
170
|
+
* ```ts
|
|
171
|
+
* const job = store.get(id);
|
|
172
|
+
* ```
|
|
84
173
|
*/
|
|
85
174
|
get(id: string): BackgroundJob | undefined;
|
|
86
175
|
/**
|
|
87
|
-
*
|
|
176
|
+
* List visible jobs.
|
|
177
|
+
* @param status - Optional lifecycle filter.
|
|
178
|
+
* @returns Matching scoped jobs.
|
|
179
|
+
* @remarks Project-scoped clients exclude other projects and unscoped legacy rows.
|
|
180
|
+
* @example
|
|
181
|
+
* ```ts
|
|
182
|
+
* const jobs = store.list('running');
|
|
183
|
+
* ```
|
|
88
184
|
*/
|
|
89
185
|
list(status?: string): BackgroundJob[];
|
|
90
186
|
/**
|
|
91
|
-
*
|
|
187
|
+
* Read a bounded candidate page without a runtime manager or ownership mutation.
|
|
188
|
+
* @param query - Exact operation, optional status, payload cap and bound cursor.
|
|
189
|
+
* @param execution - Original captured caller and deadline; never renewed by this read.
|
|
190
|
+
* @returns Candidate rows and a last-scanned cursor; the domain must validate principals.
|
|
191
|
+
* @throws BackgroundJobError for ambiguous scope, mismatched cursors, oversized rows or borrowed transactions.
|
|
192
|
+
* @remarks SQL limits candidates before payload materialization or JSON parsing. Mutable
|
|
193
|
+
* claimedBy is not used as principal authority. Existing transaction cleanup bounds lock waits;
|
|
194
|
+
* synchronous SQLite work is cooperative and cannot be preempted by a JavaScript timer.
|
|
195
|
+
* @example
|
|
196
|
+
* ```ts
|
|
197
|
+
* const page = store.listPage({ operation: 'doctor.knowledge', limit: 20 }, execution);
|
|
198
|
+
* ```
|
|
199
|
+
*/
|
|
200
|
+
listPage(query: BackgroundJobPageQuery, execution: OperationExecutionContext): BackgroundJobCandidatePage<BackgroundJob>;
|
|
201
|
+
/**
|
|
202
|
+
* Claim authentic unstarted work or reclaim an explicitly expired lease.
|
|
203
|
+
* @param id - Existing job identity.
|
|
204
|
+
* @param now - Claim timestamp.
|
|
205
|
+
* @param maxRunning - Optional capacity limit enforced atomically with the claim.
|
|
206
|
+
* @param execution - Optional original invocation budget; supplying it adds scoped cancellation and deadline checks.
|
|
207
|
+
* @returns New attempt's lease.
|
|
208
|
+
* @remarks Preserves checkpoint and cancellation request. Pending work must have
|
|
209
|
+
* authentic hash-matching inputs and no prior execution; ambiguous legacy rows refuse.
|
|
210
|
+
* @example
|
|
211
|
+
* ```ts
|
|
212
|
+
* const lease = store.claim(expiredJob.id, Date.now());
|
|
213
|
+
* ```
|
|
214
|
+
*/
|
|
215
|
+
claim(id: string, now: number, maxRunning?: number, execution?: OperationExecutionContext): BackgroundJobLease;
|
|
216
|
+
/**
|
|
217
|
+
* Start an explicit new attempt after retaining terminal or expired owned work atomically.
|
|
218
|
+
* @param id - Authentic failed, cancelled or explicitly expired owned job with the same immutable proposal.
|
|
219
|
+
* @param now - New attempt timestamp.
|
|
220
|
+
* @param execution - Fresh bounded invocation; expired contexts or old fences cannot be renewed.
|
|
221
|
+
* @param retainOutcome - Trusted synchronous core callback that rechecks domain preconditions,
|
|
222
|
+
* appends the complete previous row image, and verifies its receipt before returning.
|
|
223
|
+
* @param maxRunning - Optional capacity limit enforced inside the same transaction.
|
|
224
|
+
* @returns New owned lease, without reapplying any domain operation.
|
|
225
|
+
* @throws BackgroundJobError when scope, terminal status, authentic input, counters, or receipt is invalid.
|
|
226
|
+
* @remarks Complete jobs are never reopened. Expired running rows retain their authentic
|
|
227
|
+
* uncertain outcome; expiry does not invent failure. Explicit resume acknowledges a retained
|
|
228
|
+
* previous cancellation request and clears it only with the new claim. Callback failure, cancellation, or claim failure
|
|
229
|
+
* rolls back both historical bookkeeping and the new claim. The caller must independently
|
|
230
|
+
* preserve its append-only history in the same database; this is not an arbitrary callback sandbox.
|
|
231
|
+
* @example
|
|
232
|
+
* ```ts
|
|
233
|
+
* const lease = store.retryAtomically(id, Date.now(), context, retainPreviousAttempt);
|
|
234
|
+
* ```
|
|
235
|
+
*/
|
|
236
|
+
retryAtomically(id: string, now: number, execution: OperationExecutionContext, retainOutcome: AtomicJobRetryBookkeeping, maxRunning?: number): BackgroundJobLease;
|
|
237
|
+
/**
|
|
238
|
+
* Renew an owned lease and observe persisted cancellation.
|
|
239
|
+
* @param id - Owned job identity.
|
|
240
|
+
* @param now - Heartbeat timestamp.
|
|
241
|
+
* @returns Current job including cancellation request.
|
|
242
|
+
* @remarks Expired attempts cannot revive themselves through heartbeat.
|
|
243
|
+
* @example
|
|
244
|
+
* ```ts
|
|
245
|
+
* const job = store.heartbeat(id, Date.now());
|
|
246
|
+
* ```
|
|
247
|
+
*/
|
|
248
|
+
heartbeat(id: string, now: number): BackgroundJob;
|
|
249
|
+
/**
|
|
250
|
+
* Persist a checkpoint under the current attempt fence.
|
|
251
|
+
* @param id - Owned job identity.
|
|
252
|
+
* @param valueJson - Valid serialized checkpoint bytes.
|
|
253
|
+
* @param now - Checkpoint timestamp.
|
|
254
|
+
* @remarks Writes atomically with ownership verification; does not authorize domain writes.
|
|
255
|
+
* @example
|
|
256
|
+
* ```ts
|
|
257
|
+
* store.checkpoint(id, JSON.stringify({ nextFile: 8 }), Date.now());
|
|
258
|
+
* ```
|
|
259
|
+
*/
|
|
260
|
+
checkpoint(id: string, valueJson: string, now: number): void;
|
|
261
|
+
/**
|
|
262
|
+
* Request cancellation without claiming that execution has stopped.
|
|
263
|
+
* @param id - Visible job identity.
|
|
264
|
+
* @param now - Request timestamp.
|
|
265
|
+
* @param execution - Optional original invocation context; never renews its deadline.
|
|
266
|
+
* @returns Whether pending work was cancelled or running work has a persisted request.
|
|
267
|
+
* @remarks Terminal results are preserved when cancellation arrives after commit.
|
|
268
|
+
* @example
|
|
269
|
+
* ```ts
|
|
270
|
+
* const requested = store.requestCancel(id, Date.now());
|
|
271
|
+
* ```
|
|
272
|
+
*/
|
|
273
|
+
requestCancel(id: string, now: number, execution?: OperationExecutionContext): boolean;
|
|
274
|
+
/**
|
|
275
|
+
* Commit actual executor success under ownership.
|
|
276
|
+
* @param id - Job identity.
|
|
277
|
+
* @param result - Actual outcome.
|
|
278
|
+
* @param now - Completion timestamp.
|
|
279
|
+
* @remarks An earlier cancellation request does not erase work already committed.
|
|
280
|
+
* @example
|
|
281
|
+
* ```ts
|
|
282
|
+
* store.complete(id, { verified: true }, Date.now());
|
|
283
|
+
* ```
|
|
92
284
|
*/
|
|
93
285
|
complete(id: string, result: unknown, now: number): void;
|
|
94
286
|
/**
|
|
95
|
-
*
|
|
287
|
+
* Commit a synchronous domain mutation, its receipt and job completion atomically.
|
|
288
|
+
* @param execution - Captured context carrying this client's current claimed fence.
|
|
289
|
+
* @param mutation - Trusted synchronous domain operation returning JSON receipt bytes.
|
|
290
|
+
* @returns Exact receipt bytes committed with the domain changes and terminal job row.
|
|
291
|
+
* @throws BackgroundJobError when the transaction is borrowed, authority changed,
|
|
292
|
+
* cancellation was observed before commit, or receipt bytes are invalid.
|
|
293
|
+
* @remarks The store acquires its own write transaction; an ambient BEGIN confers
|
|
294
|
+
* no authority. Domain code must independently validate its proposal and operate
|
|
295
|
+
* only on the same SQLite database without transaction control or external effects.
|
|
296
|
+
* Guards are cooperative boundaries, not preemption. Cancellation observed after
|
|
297
|
+
* COMMIT cannot erase the committed result. Arbitrary async callbacks are unsupported.
|
|
298
|
+
* @example
|
|
299
|
+
* ```ts
|
|
300
|
+
* const receiptJson = store.completeAtomically(execution, () => applyPreparedRepair());
|
|
301
|
+
* ```
|
|
302
|
+
*/
|
|
303
|
+
completeAtomically(execution: OperationExecutionContext, mutation: AtomicJobMutation): string;
|
|
304
|
+
/**
|
|
305
|
+
* Finalize trusted receipt/event metadata and a failed or cancelled attempt atomically.
|
|
306
|
+
* @param execution - Original bounded attempt identity and current ownership fence.
|
|
307
|
+
* @param outcome - Sourced observed outcome; expiry alone cannot supply this fact.
|
|
308
|
+
* @param bookkeeping - Synchronous metadata-only service callback returning JSON receipt bytes.
|
|
309
|
+
* @returns Committed receipt or explicit pending finalization with actual elapsed time.
|
|
310
|
+
* @remarks Cancellation allows bookkeeping only; domain repair remains forbidden.
|
|
311
|
+
* An exhausted deadline never acquires a lock. Failed finalization preserves the
|
|
312
|
+
* lease/checkpoint for inspection and a later explicit recovery attempt. No budget
|
|
313
|
+
* is renewed, and synchronous SQLite completion is not preempted by a timer.
|
|
314
|
+
* @example
|
|
315
|
+
* ```ts
|
|
316
|
+
* const result = store.finalizeAtomically(context, outcome, () => appendAttemptReceipt());
|
|
317
|
+
* ```
|
|
318
|
+
*/
|
|
319
|
+
finalizeAtomically(execution: OperationExecutionContext, outcome: JobAttemptOutcome, bookkeeping: AtomicJobBookkeeping): JobFinalizationResult;
|
|
320
|
+
/**
|
|
321
|
+
* Commit actual executor failure under ownership.
|
|
322
|
+
* @param id - Job identity.
|
|
323
|
+
* @param error - Failure message.
|
|
324
|
+
* @param now - Failure timestamp.
|
|
325
|
+
* @remarks Stale owners cannot replace a newer attempt's outcome.
|
|
326
|
+
* @example
|
|
327
|
+
* ```ts
|
|
328
|
+
* store.fail(id, 'Verification failed', Date.now());
|
|
329
|
+
* ```
|
|
96
330
|
*/
|
|
97
331
|
fail(id: string, error: string, now: number): void;
|
|
98
332
|
/**
|
|
99
|
-
*
|
|
333
|
+
* Acknowledge an executor's cancellation.
|
|
334
|
+
* @param id - Owned job identity.
|
|
335
|
+
* @param now - Acknowledgement timestamp.
|
|
336
|
+
* @remarks Requires a persisted cancellation request and current ownership.
|
|
337
|
+
* @example
|
|
338
|
+
* ```ts
|
|
339
|
+
* store.cancel(id, Date.now());
|
|
340
|
+
* ```
|
|
100
341
|
*/
|
|
101
342
|
cancel(id: string, now: number): void;
|
|
102
343
|
/**
|
|
103
|
-
* Update
|
|
344
|
+
* Update an owned attempt's progress.
|
|
345
|
+
* @param id - Job identity.
|
|
346
|
+
* @param progress - Finite percentage, clamped to zero through one hundred.
|
|
347
|
+
* @param now - Observation timestamp.
|
|
348
|
+
* @remarks Progress does not renew an expired lease or overwrite another owner.
|
|
349
|
+
* @example
|
|
350
|
+
* ```ts
|
|
351
|
+
* store.progress(id, 50, Date.now());
|
|
352
|
+
* ```
|
|
104
353
|
*/
|
|
105
354
|
progress(id: string, progress: number, now: number): void;
|
|
106
355
|
/**
|
|
107
|
-
*
|
|
108
|
-
*
|
|
109
|
-
*
|
|
110
|
-
* @
|
|
356
|
+
* Retain historical job evidence regardless of age.
|
|
357
|
+
* @param _cutoffMs - Former deletion threshold, retained for API compatibility.
|
|
358
|
+
* @returns Zero; any future deletion requires explicit evidence-aware recovery policy.
|
|
359
|
+
* @remarks No automatic or age-only pruning is performed.
|
|
360
|
+
* @example
|
|
361
|
+
* ```ts
|
|
362
|
+
* const removed = store.purgeOlderThan(Date.now()); // 0
|
|
363
|
+
* ```
|
|
111
364
|
*/
|
|
112
|
-
purgeOlderThan(
|
|
365
|
+
purgeOlderThan(_cutoffMs: number): number;
|
|
113
366
|
}
|
|
114
367
|
/**
|
|
115
|
-
*
|
|
116
|
-
*
|
|
117
|
-
*
|
|
118
|
-
*
|
|
119
|
-
*
|
|
120
|
-
*
|
|
121
|
-
*
|
|
368
|
+
* Existing executor facade with persisted ownership and cooperative cancellation.
|
|
369
|
+
* @remarks Executors must use a separately authorized transactional service for
|
|
370
|
+
* domain changes and receipts; this class fences only job metadata/checkpoints.
|
|
371
|
+
* @example
|
|
372
|
+
* ```ts
|
|
373
|
+
* const manager = new BackgroundJobManager(db, { projectId: 'project-uuid' });
|
|
374
|
+
* const id = await manager.startJob('inspect', async ({ signal }) => ({ cancelled: signal.aborted }));
|
|
375
|
+
* ```
|
|
122
376
|
*/
|
|
123
377
|
export declare class BackgroundJobManager {
|
|
124
378
|
#private;
|
|
125
|
-
constructor(db: TasksDb, config?: BackgroundJobManagerConfig);
|
|
126
379
|
/**
|
|
127
|
-
*
|
|
128
|
-
*
|
|
129
|
-
* @param
|
|
130
|
-
* @
|
|
131
|
-
* @
|
|
132
|
-
*
|
|
380
|
+
* Open the existing facade.
|
|
381
|
+
* @param db - Canonical store.
|
|
382
|
+
* @param config - Scope and lease configuration.
|
|
383
|
+
* @remarks Construction does not orphan or execute persisted work.
|
|
384
|
+
* @example
|
|
385
|
+
* ```ts
|
|
386
|
+
* const manager = new BackgroundJobManager(db, { projectId: 'project-uuid' });
|
|
387
|
+
* ```
|
|
388
|
+
*/
|
|
389
|
+
constructor(db: NodeSQLiteDatabase, config?: BackgroundJobManagerConfig);
|
|
390
|
+
/**
|
|
391
|
+
* Start new work or coalesce an identical immutable submission.
|
|
392
|
+
* @param operation - Supported operation.
|
|
393
|
+
* @param executor - Existing executor, now given cancellation and checkpoint capabilities.
|
|
394
|
+
* @param submission - Optional scoped retry identity.
|
|
395
|
+
* @returns New or already persisted job identity.
|
|
396
|
+
* @remarks Repeated submissions never invoke a second executor.
|
|
397
|
+
* @example
|
|
398
|
+
* ```ts
|
|
399
|
+
* const id = await manager.startJob('inspect', async () => ({ verified: true }), submission);
|
|
400
|
+
* ```
|
|
401
|
+
*/
|
|
402
|
+
startJob(operation: string, executor: (context: BackgroundJobExecutionContext) => Promise<unknown>, submission?: BackgroundJobSubmission): Promise<string>;
|
|
403
|
+
/**
|
|
404
|
+
* Record optional work durably without scheduling an executor or model.
|
|
405
|
+
* @param operation - Supported action validated by the calling domain service.
|
|
406
|
+
* @param submission - Authentic scoped proposal bytes for explicit later resume.
|
|
407
|
+
* @returns Existing or newly persisted job identity.
|
|
408
|
+
* @remarks This does not establish completion of the optional projection or a
|
|
409
|
+
* domain repair receipt. Explicit resume must validate current prerequisites.
|
|
410
|
+
* @example
|
|
411
|
+
* ```ts
|
|
412
|
+
* const id = manager.deferJob('docs.projection', submission);
|
|
413
|
+
* ```
|
|
414
|
+
*/
|
|
415
|
+
deferJob(operation: string, submission: BackgroundJobSubmission): string;
|
|
416
|
+
/**
|
|
417
|
+
* Explicitly start pending work or resume expired ownership using the existing facade.
|
|
418
|
+
* @param id - Expired job identity.
|
|
419
|
+
* @param executor - Executor capable of resuming its persisted checkpoint.
|
|
420
|
+
* @returns Identity of the resumed job.
|
|
421
|
+
* @remarks The earlier owner is fenced before a replacement executor can run.
|
|
422
|
+
* @example
|
|
423
|
+
* ```ts
|
|
424
|
+
* await manager.resumeJob(id, async ({ checkpoint }) => { checkpoint('{}'); });
|
|
425
|
+
* ```
|
|
133
426
|
*/
|
|
134
|
-
|
|
427
|
+
resumeJob(id: string, executor: (context: BackgroundJobExecutionContext) => Promise<unknown>): Promise<string>;
|
|
135
428
|
/**
|
|
136
|
-
*
|
|
137
|
-
*
|
|
138
|
-
* @returns
|
|
429
|
+
* Read persisted state and local diagnostic failures.
|
|
430
|
+
* @param id - Job identity.
|
|
431
|
+
* @returns Job or undefined.
|
|
432
|
+
* @remarks Persistence errors are disclosed separately from a committed outcome.
|
|
433
|
+
* @example
|
|
434
|
+
* ```ts
|
|
435
|
+
* const job = manager.getJob(id);
|
|
436
|
+
* ```
|
|
139
437
|
*/
|
|
140
|
-
getJob(
|
|
438
|
+
getJob(id: string): BackgroundJob | undefined;
|
|
141
439
|
/**
|
|
142
|
-
* List
|
|
143
|
-
*
|
|
144
|
-
* @
|
|
145
|
-
* @
|
|
440
|
+
* List persisted scoped jobs.
|
|
441
|
+
* @param status - Optional lifecycle filter.
|
|
442
|
+
* @returns Matching jobs.
|
|
443
|
+
* @remarks Includes cancellation requests and local diagnostic failures.
|
|
444
|
+
* @example
|
|
445
|
+
* ```ts
|
|
446
|
+
* const jobs = manager.listJobs('running');
|
|
447
|
+
* ```
|
|
146
448
|
*/
|
|
147
449
|
listJobs(status?: string): BackgroundJob[];
|
|
148
450
|
/**
|
|
149
|
-
*
|
|
150
|
-
*
|
|
151
|
-
* @returns
|
|
451
|
+
* Request cancellation of visible running work.
|
|
452
|
+
* @param id - Job identity.
|
|
453
|
+
* @returns Whether the request was recorded, not proof of termination.
|
|
454
|
+
* @remarks Other owners observe the durable request on heartbeat.
|
|
455
|
+
* @example
|
|
456
|
+
* ```ts
|
|
457
|
+
* const requested = manager.cancelJob(id);
|
|
458
|
+
* ```
|
|
152
459
|
*/
|
|
153
|
-
cancelJob(
|
|
460
|
+
cancelJob(id: string): boolean;
|
|
154
461
|
/**
|
|
155
|
-
*
|
|
156
|
-
*
|
|
157
|
-
* @
|
|
462
|
+
* Report progress from an owned executor.
|
|
463
|
+
* @param id - Job identity.
|
|
464
|
+
* @param progress - Finite percentage.
|
|
465
|
+
* @returns Whether the job exists and is running.
|
|
466
|
+
* @remarks A visible job owned by another attempt is explicitly refused.
|
|
467
|
+
* @example
|
|
468
|
+
* ```ts
|
|
469
|
+
* manager.updateProgress(id, 50);
|
|
470
|
+
* ```
|
|
158
471
|
*/
|
|
159
|
-
updateProgress(
|
|
472
|
+
updateProgress(id: string, progress: number): boolean;
|
|
160
473
|
/**
|
|
161
|
-
*
|
|
162
|
-
*
|
|
163
|
-
* @
|
|
474
|
+
* Preserve historical evidence.
|
|
475
|
+
* @returns Zero rows removed.
|
|
476
|
+
* @remarks Age alone never authorizes deletion of job evidence.
|
|
477
|
+
* @example
|
|
478
|
+
* ```ts
|
|
479
|
+
* const removed = manager.cleanup(); // 0
|
|
480
|
+
* ```
|
|
164
481
|
*/
|
|
165
482
|
cleanup(): number;
|
|
166
483
|
/**
|
|
167
|
-
*
|
|
168
|
-
*
|
|
484
|
+
* Request cancellation only for this manager's executors and stop its timers.
|
|
485
|
+
* @remarks Does not claim non-cooperative executors stopped or alter another owner.
|
|
486
|
+
* @example
|
|
487
|
+
* ```ts
|
|
488
|
+
* manager.destroy(); // inspect persisted cancellation/completion separately
|
|
489
|
+
* ```
|
|
169
490
|
*/
|
|
170
491
|
destroy(): void;
|
|
171
492
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"background-jobs.d.ts","sourceRoot":"","sources":["../../src/store/background-jobs.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"background-jobs.d.ts","sourceRoot":"","sources":["../../src/store/background-jobs.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EACV,oBAAoB,EACpB,iBAAiB,EACjB,yBAAyB,EACzB,0BAA0B,EAC1B,6BAA6B,EAC7B,wBAAwB,EACxB,kBAAkB,EAClB,sBAAsB,EAEtB,yBAAyB,EACzB,uBAAuB,EACvB,iBAAiB,EACjB,qBAAqB,EACrB,yBAAyB,EAC1B,MAAM,0BAA0B,CAAC;AAElC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AACtD,OAAO,EAGL,KAAK,mBAAmB,EAEzB,MAAM,mBAAmB,CAAC;AAE3B,YAAY,EAAE,mBAAmB,EAAE,CAAC;AAEpC,gFAAgF;AAChF,MAAM,WAAW,aAAa;IAC5B,+BAA+B;IAC/B,EAAE,EAAE,MAAM,CAAC;IACX,gCAAgC;IAChC,SAAS,EAAE,MAAM,CAAC;IAClB,sEAAsE;IACtE,MAAM,EAAE,mBAAmB,CAAC;IAC5B,8BAA8B;IAC9B,SAAS,EAAE,MAAM,CAAC;IAClB,4CAA4C;IAC5C,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wCAAw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