project-tiny-context-harness 0.8.16 → 0.11.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.md +119 -41
- package/assets/README.md +184 -55
- package/assets/README.zh-CN.md +114 -40
- package/assets/agents/AGENTS_CORE.md +2 -2
- package/assets/context_templates/context.toml +6 -1
- package/assets/context_templates/screen-contract.md +16 -0
- package/assets/runtime/windows-job-supervisor/formal_process_supervisor_native_helpers.cs +301 -0
- package/assets/runtime/windows-job-supervisor/formal_process_supervisor_native_run.cs +197 -0
- package/assets/runtime/windows-job-supervisor/formal_process_supervisor_native_types.cs +215 -0
- package/assets/runtime/windows-job-supervisor/windows_job_process_supervisor.ps1 +117 -0
- package/assets/skills/context_development_engineer/SKILL.md +16 -30
- package/assets/skills/context_development_engineer/references/engineering-design-reasoning.md +93 -0
- package/assets/skills/context_surface_contract/SKILL.md +13 -2
- package/assets/skills/context_uiux_design/SKILL.md +7 -3
- package/assets/skills/context_uiux_design/references/task-uiux-analysis.md +82 -0
- package/assets/skills/design-resource-authoring/SKILL.md +18 -9
- package/assets/skills/design-resource-authoring/references/authority-delta-assessment.md +52 -0
- package/assets/skills/design-resource-authoring/references/downstream-handoff.md +22 -6
- package/assets/skills/design-resource-authoring/references/formal-selected-web-app-handoff.md +26 -8
- package/assets/skills/design-resource-authoring/references/implementation-feasibility.md +111 -0
- package/assets/skills/design-resource-authoring/references/open-design-provider.md +45 -7
- package/assets/skills/design-resource-authoring/references/recovery-and-writeback.md +7 -1
- package/assets/skills/design-resource-authoring/references/resource-selection.md +115 -3
- package/assets/skills/design-system-authoring/SKILL.md +23 -17
- package/assets/skills/design-system-authoring/references/authority-adoption.md +19 -9
- package/assets/skills/design-system-authoring/references/open-design-design-system-provider.md +4 -0
- package/assets/skills/long-task-workflow/SKILL.md +6 -6
- package/assets/skills/long-task-workflow/references/authority-lifecycle.md +10 -4
- package/assets/skills/long-task-workflow/references/contract-authoring.md +5 -5
- package/assets/skills/long-task-workflow/references/evidence-design.md +14 -3
- package/assets/skills/long-task-workflow/references/source-authoring.md +11 -8
- package/assets/tools/context_rules.json +53 -0
- package/assets/tools/validate_context.py +302 -77
- package/dist/cli.js +2 -1
- package/dist/commands/context-create.d.ts +1 -0
- package/dist/commands/context-create.js +90 -0
- package/dist/commands/context-inspect.d.ts +1 -0
- package/dist/commands/context-inspect.js +98 -0
- package/dist/commands/context-move.d.ts +1 -0
- package/dist/commands/context-move.js +78 -0
- package/dist/commands/context-register.d.ts +1 -0
- package/dist/commands/context-register.js +110 -0
- package/dist/commands/context-transaction.d.ts +1 -0
- package/dist/commands/context-transaction.js +84 -0
- package/dist/commands/context.d.ts +1 -0
- package/dist/commands/context.js +36 -0
- package/dist/commands/design-authority-delta.d.ts +1 -0
- package/dist/commands/design-authority-delta.js +53 -0
- package/dist/commands/design-authority.d.ts +1 -0
- package/dist/commands/design-authority.js +104 -0
- package/dist/commands/design-resource.js +17 -3
- package/dist/commands/doctor.d.ts +1 -1
- package/dist/commands/doctor.js +61 -3
- package/dist/commands/index.js +19 -2
- package/dist/commands/long-task-authoring.js +20 -2
- package/dist/commands/long-task-workdir.d.ts +2 -0
- package/dist/commands/long-task-workdir.js +23 -0
- package/dist/commands/long-task.js +75 -6
- package/dist/commands/route.d.ts +15 -0
- package/dist/commands/route.js +142 -0
- package/dist/index.d.ts +3 -13
- package/dist/index.js +3 -12
- package/dist/lib/cli-exit.d.ts +14 -0
- package/dist/lib/cli-exit.js +19 -0
- package/dist/lib/context-catalog/catalog-default-footprint.d.ts +3 -0
- package/dist/lib/context-catalog/catalog-default-footprint.js +53 -0
- package/dist/lib/context-catalog/catalog-diagnostics.d.ts +9 -0
- package/dist/lib/context-catalog/catalog-diagnostics.js +34 -0
- package/dist/lib/context-catalog/catalog-discovery.d.ts +7 -0
- package/dist/lib/context-catalog/catalog-discovery.js +81 -0
- package/dist/lib/context-catalog/catalog-load.d.ts +8 -0
- package/dist/lib/context-catalog/catalog-load.js +187 -0
- package/dist/lib/context-catalog/catalog-path-validation.d.ts +7 -0
- package/dist/lib/context-catalog/catalog-path-validation.js +62 -0
- package/dist/lib/context-catalog/catalog-paths.d.ts +11 -0
- package/dist/lib/context-catalog/catalog-paths.js +41 -0
- package/dist/lib/context-catalog/catalog-portable-contract.d.ts +15 -0
- package/dist/lib/context-catalog/catalog-portable-contract.js +68 -0
- package/dist/lib/context-catalog/catalog-staged-path-safety.d.ts +1 -0
- package/dist/lib/context-catalog/catalog-staged-path-safety.js +36 -0
- package/dist/lib/context-catalog/catalog-types.d.ts +40 -0
- package/dist/lib/context-catalog/catalog-types.js +1 -0
- package/dist/lib/context-catalog/catalog-validation.d.ts +9 -0
- package/dist/lib/context-catalog/catalog-validation.js +148 -0
- package/dist/lib/context-create/context-create-path.d.ts +2 -0
- package/dist/lib/context-create/context-create-path.js +30 -0
- package/dist/lib/context-create/context-create-template.d.ts +2 -0
- package/dist/lib/context-create/context-create-template.js +95 -0
- package/dist/lib/context-create/context-create-types.d.ts +28 -0
- package/dist/lib/context-create/context-create-types.js +1 -0
- package/dist/lib/context-create/context-create-write.d.ts +1 -0
- package/dist/lib/context-create/context-create-write.js +85 -0
- package/dist/lib/context-create/context-create.d.ts +2 -0
- package/dist/lib/context-create/context-create.js +84 -0
- package/dist/lib/context-default-footprint.d.ts +2 -3
- package/dist/lib/context-default-footprint.js +49 -57
- package/dist/lib/context-doctor/context-doctor-types.d.ts +16 -0
- package/dist/lib/context-doctor/context-doctor-types.js +15 -0
- package/dist/lib/context-doctor/context-doctor.d.ts +2 -0
- package/dist/lib/context-doctor/context-doctor.js +130 -0
- package/dist/lib/context-graph-snapshot.d.ts +5 -0
- package/dist/lib/context-graph-snapshot.js +46 -25
- package/dist/lib/context-inspect/context-inspect-projection.d.ts +9 -0
- package/dist/lib/context-inspect/context-inspect-projection.js +49 -0
- package/dist/lib/context-inspect/context-inspect-render.d.ts +2 -0
- package/dist/lib/context-inspect/context-inspect-render.js +29 -0
- package/dist/lib/context-inspect/context-inspect-types.d.ts +43 -0
- package/dist/lib/context-inspect/context-inspect-types.js +1 -0
- package/dist/lib/context-inspect/context-inspect.d.ts +2 -0
- package/dist/lib/context-inspect/context-inspect.js +104 -0
- package/dist/lib/context-manifest-schema.d.ts +1 -1
- package/dist/lib/context-manifest-schema.js +4 -20
- package/dist/lib/context-markdown/context-markdown-analysis.d.ts +15 -0
- package/dist/lib/context-markdown/context-markdown-analysis.js +245 -0
- package/dist/lib/context-markdown/context-markdown-extract.d.ts +7 -0
- package/dist/lib/context-markdown/context-markdown-extract.js +114 -0
- package/dist/lib/context-markdown/context-markdown-types.d.ts +57 -0
- package/dist/lib/context-markdown/context-markdown-types.js +1 -0
- package/dist/lib/context-move/context-move-input.d.ts +8 -0
- package/dist/lib/context-move/context-move-input.js +17 -0
- package/dist/lib/context-move/context-move-literal-scan.d.ts +20 -0
- package/dist/lib/context-move/context-move-literal-scan.js +213 -0
- package/dist/lib/context-move/context-move-live-validation.d.ts +3 -0
- package/dist/lib/context-move/context-move-live-validation.js +56 -0
- package/dist/lib/context-move/context-move-markdown-plan.d.ts +22 -0
- package/dist/lib/context-move/context-move-markdown-plan.js +39 -0
- package/dist/lib/context-move/context-move-projection.d.ts +3 -0
- package/dist/lib/context-move/context-move-projection.js +11 -0
- package/dist/lib/context-move/context-move-reference-validation.d.ts +11 -0
- package/dist/lib/context-move/context-move-reference-validation.js +64 -0
- package/dist/lib/context-move/context-move-render.d.ts +2 -0
- package/dist/lib/context-move/context-move-render.js +24 -0
- package/dist/lib/context-move/context-move-support.d.ts +10 -0
- package/dist/lib/context-move/context-move-support.js +88 -0
- package/dist/lib/context-move/context-move-transaction-plan.d.ts +24 -0
- package/dist/lib/context-move/context-move-transaction-plan.js +108 -0
- package/dist/lib/context-move/context-move-types.d.ts +74 -0
- package/dist/lib/context-move/context-move-types.js +1 -0
- package/dist/lib/context-move/context-move.d.ts +8 -0
- package/dist/lib/context-move/context-move.js +180 -0
- package/dist/lib/context-mutation/manifest-lossless-patch.d.ts +28 -0
- package/dist/lib/context-mutation/manifest-lossless-patch.js +208 -0
- package/dist/lib/context-mutation/markdown-link-patch.d.ts +34 -0
- package/dist/lib/context-mutation/markdown-link-patch.js +143 -0
- package/dist/lib/context-mutation/markdown-link-spans.d.ts +10 -0
- package/dist/lib/context-mutation/markdown-link-spans.js +179 -0
- package/dist/lib/context-mutation/mutation-cas.d.ts +13 -0
- package/dist/lib/context-mutation/mutation-cas.js +365 -0
- package/dist/lib/context-mutation/mutation-command-support.d.ts +12 -0
- package/dist/lib/context-mutation/mutation-command-support.js +57 -0
- package/dist/lib/context-mutation/mutation-commit.d.ts +12 -0
- package/dist/lib/context-mutation/mutation-commit.js +89 -0
- package/dist/lib/context-mutation/mutation-directories.d.ts +5 -0
- package/dist/lib/context-mutation/mutation-directories.js +56 -0
- package/dist/lib/context-mutation/mutation-file-state.d.ts +14 -0
- package/dist/lib/context-mutation/mutation-file-state.js +137 -0
- package/dist/lib/context-mutation/mutation-journal-file-validation.d.ts +1 -0
- package/dist/lib/context-mutation/mutation-journal-file-validation.js +106 -0
- package/dist/lib/context-mutation/mutation-journal-io.d.ts +5 -0
- package/dist/lib/context-mutation/mutation-journal-io.js +55 -0
- package/dist/lib/context-mutation/mutation-journal-storage.d.ts +18 -0
- package/dist/lib/context-mutation/mutation-journal-storage.js +283 -0
- package/dist/lib/context-mutation/mutation-journal-validation-support.d.ts +16 -0
- package/dist/lib/context-mutation/mutation-journal-validation-support.js +140 -0
- package/dist/lib/context-mutation/mutation-journal-validation.d.ts +3 -0
- package/dist/lib/context-mutation/mutation-journal-validation.js +177 -0
- package/dist/lib/context-mutation/mutation-journal.d.ts +8 -0
- package/dist/lib/context-mutation/mutation-journal.js +111 -0
- package/dist/lib/context-mutation/mutation-live-validation.d.ts +3 -0
- package/dist/lib/context-mutation/mutation-live-validation.js +51 -0
- package/dist/lib/context-mutation/mutation-long-task-guard.d.ts +6 -0
- package/dist/lib/context-mutation/mutation-long-task-guard.js +57 -0
- package/dist/lib/context-mutation/mutation-recovery.d.ts +4 -0
- package/dist/lib/context-mutation/mutation-recovery.js +189 -0
- package/dist/lib/context-mutation/mutation-staged-fs.d.ts +5 -0
- package/dist/lib/context-mutation/mutation-staged-fs.js +56 -0
- package/dist/lib/context-mutation/mutation-types.d.ts +103 -0
- package/dist/lib/context-mutation/mutation-types.js +1 -0
- package/dist/lib/context-register/context-register-input.d.ts +11 -0
- package/dist/lib/context-register/context-register-input.js +43 -0
- package/dist/lib/context-register/context-register-render.d.ts +2 -0
- package/dist/lib/context-register/context-register-render.js +21 -0
- package/dist/lib/context-register/context-register-support.d.ts +6 -0
- package/dist/lib/context-register/context-register-support.js +46 -0
- package/dist/lib/context-register/context-register-types.d.ts +46 -0
- package/dist/lib/context-register/context-register-types.js +1 -0
- package/dist/lib/context-register/context-register.d.ts +8 -0
- package/dist/lib/context-register/context-register.js +155 -0
- package/dist/lib/context-router/context-route-budget.d.ts +15 -0
- package/dist/lib/context-router/context-route-budget.js +14 -0
- package/dist/lib/context-router/context-route-candidates.d.ts +15 -0
- package/dist/lib/context-router/context-route-candidates.js +112 -0
- package/dist/lib/context-router/context-route-order.d.ts +6 -0
- package/dist/lib/context-router/context-route-order.js +53 -0
- package/dist/lib/context-router/context-route-paths.d.ts +16 -0
- package/dist/lib/context-router/context-route-paths.js +109 -0
- package/dist/lib/context-router/context-route-render.d.ts +2 -0
- package/dist/lib/context-router/context-route-render.js +32 -0
- package/dist/lib/context-router/context-route-scan.d.ts +18 -0
- package/dist/lib/context-router/context-route-scan.js +156 -0
- package/dist/lib/context-router/context-route-selection.d.ts +16 -0
- package/dist/lib/context-router/context-route-selection.js +72 -0
- package/dist/lib/context-router/context-route-terms.d.ts +13 -0
- package/dist/lib/context-router/context-route-terms.js +202 -0
- package/dist/lib/context-router/context-route-types.d.ts +101 -0
- package/dist/lib/context-router/context-route-types.js +1 -0
- package/dist/lib/context-router/context-route.d.ts +2 -0
- package/dist/lib/context-router/context-route.js +127 -0
- package/dist/lib/context-units-migration.d.ts +13 -0
- package/dist/lib/context-units-migration.js +217 -0
- package/dist/lib/design-authority-binding.d.ts +7 -0
- package/dist/lib/design-authority-binding.js +96 -0
- package/dist/lib/design-authority-closure.d.ts +3 -0
- package/dist/lib/design-authority-closure.js +201 -0
- package/dist/lib/design-authority-delta-codec-primitives.d.ts +10 -0
- package/dist/lib/design-authority-delta-codec-primitives.js +58 -0
- package/dist/lib/design-authority-delta-codec.d.ts +2 -0
- package/dist/lib/design-authority-delta-codec.js +193 -0
- package/dist/lib/design-authority-delta-types.d.ts +65 -0
- package/dist/lib/design-authority-delta-types.js +6 -0
- package/dist/lib/design-authority-delta-validation.d.ts +2 -0
- package/dist/lib/design-authority-delta-validation.js +16 -0
- package/dist/lib/design-authority-digest.d.ts +8 -0
- package/dist/lib/design-authority-digest.js +36 -0
- package/dist/lib/design-authority-files.d.ts +9 -0
- package/dist/lib/design-authority-files.js +62 -0
- package/dist/lib/design-authority-format.d.ts +2 -0
- package/dist/lib/design-authority-format.js +93 -0
- package/dist/lib/design-authority-links.d.ts +10 -0
- package/dist/lib/design-authority-links.js +137 -0
- package/dist/lib/design-authority-manifest.d.ts +4 -0
- package/dist/lib/design-authority-manifest.js +144 -0
- package/dist/lib/design-authority-tokens.d.ts +9 -0
- package/dist/lib/design-authority-tokens.js +45 -0
- package/dist/lib/design-authority-types.d.ts +80 -0
- package/dist/lib/design-authority-types.js +23 -0
- package/dist/lib/design-md-tool-adapter.d.ts +9 -0
- package/dist/lib/design-md-tool-adapter.js +152 -0
- package/dist/lib/design-md-tool-normalization.d.ts +7 -0
- package/dist/lib/design-md-tool-normalization.js +78 -0
- package/dist/lib/design-md-tool-types.d.ts +99 -0
- package/dist/lib/design-md-tool-types.js +8 -0
- package/dist/lib/design-resource-handoff-bundle.js +5 -0
- package/dist/lib/design-resource-handoff-input-types.d.ts +1 -1
- package/dist/lib/design-resource-handoff-manifest-projection.js +4 -0
- package/dist/lib/design-resource-handoff-set-integrity.js +1 -0
- package/dist/lib/design-resource-handoff-shape.js +18 -2
- package/dist/lib/design-resource-handoff-types.d.ts +8 -0
- package/dist/lib/design-resource-handoff-validation.js +24 -0
- package/dist/lib/design-resource-implementation-feasibility-model.d.ts +35 -0
- package/dist/lib/design-resource-implementation-feasibility-model.js +62 -0
- package/dist/lib/design-resource-implementation-feasibility-shape-sections.d.ts +43 -0
- package/dist/lib/design-resource-implementation-feasibility-shape-sections.js +142 -0
- package/dist/lib/design-resource-implementation-feasibility-shape.d.ts +4 -0
- package/dist/lib/design-resource-implementation-feasibility-shape.js +154 -0
- package/dist/lib/design-resource-implementation-feasibility-source-decision-projection.d.ts +24 -0
- package/dist/lib/design-resource-implementation-feasibility-source-decision-projection.js +106 -0
- package/dist/lib/design-resource-implementation-feasibility-source-decision.d.ts +21 -0
- package/dist/lib/design-resource-implementation-feasibility-source-decision.js +75 -0
- package/dist/lib/design-resource-implementation-feasibility-types.d.ts +135 -0
- package/dist/lib/design-resource-implementation-feasibility-types.js +37 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-cells.d.ts +5 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-cells.js +125 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-document.d.ts +4 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-document.js +167 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-facts.d.ts +3 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-facts.js +76 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-realizations.d.ts +8 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-realizations.js +76 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-support.d.ts +10 -0
- package/dist/lib/design-resource-implementation-feasibility-validation-support.js +75 -0
- package/dist/lib/design-resource-implementation-feasibility-validation.d.ts +3 -0
- package/dist/lib/design-resource-implementation-feasibility-validation.js +138 -0
- package/dist/lib/design-resource-recovery-current.js +22 -0
- package/dist/lib/design-resource-recovery-shape.js +64 -7
- package/dist/lib/design-resource-recovery-types.d.ts +4 -1
- package/dist/lib/design-resource-symbolic-fact-shape.js +9 -1
- package/dist/lib/design-resource-symbolic-fact-types.d.ts +8 -0
- package/dist/lib/design-resource-symbolic-fact-validation.js +25 -0
- package/dist/lib/doctor.d.ts +2 -1
- package/dist/lib/doctor.js +29 -1
- package/dist/lib/fs.js +1 -1
- package/dist/lib/long-task-acceptance-reachability-claims.d.ts +2 -0
- package/dist/lib/long-task-acceptance-reachability-claims.js +279 -0
- package/dist/lib/long-task-acceptance-reachability-design.d.ts +2 -0
- package/dist/lib/long-task-acceptance-reachability-design.js +96 -0
- package/dist/lib/long-task-acceptance-reachability-external.d.ts +9 -0
- package/dist/lib/long-task-acceptance-reachability-external.js +123 -0
- package/dist/lib/long-task-acceptance-reachability-helpers.d.ts +64 -0
- package/dist/lib/long-task-acceptance-reachability-helpers.js +473 -0
- package/dist/lib/long-task-acceptance-reachability-semantic.d.ts +2 -0
- package/dist/lib/long-task-acceptance-reachability-semantic.js +122 -0
- package/dist/lib/long-task-acceptance-reachability-types.d.ts +91 -0
- package/dist/lib/long-task-acceptance-reachability-types.js +1 -0
- package/dist/lib/long-task-acceptance-reachability.d.ts +4 -0
- package/dist/lib/long-task-acceptance-reachability.js +115 -0
- package/dist/lib/long-task-activation-validation.d.ts +6 -0
- package/dist/lib/long-task-activation-validation.js +96 -23
- package/dist/lib/long-task-active-authority-lock-context.d.ts +4 -0
- package/dist/lib/long-task-active-authority-lock-context.js +29 -0
- package/dist/lib/long-task-applicability-identity.d.ts +25 -0
- package/dist/lib/long-task-applicability-identity.js +60 -0
- package/dist/lib/long-task-authoring-preflight-diagnostics.js +8 -0
- package/dist/lib/long-task-authoring-preflight-types.d.ts +2 -0
- package/dist/lib/long-task-authoring-preflight-types.js +9 -0
- package/dist/lib/long-task-authoring-preflight.js +18 -2
- package/dist/lib/long-task-authority-material-diff.js +4 -0
- package/dist/lib/long-task-authority-materials.js +19 -0
- package/dist/lib/long-task-authority-policy.d.ts +3 -0
- package/dist/lib/long-task-authority-policy.js +3 -0
- package/dist/lib/long-task-authority-revision-details.js +2 -1
- package/dist/lib/long-task-authority-types.d.ts +2 -0
- package/dist/lib/long-task-authority.js +2 -0
- package/dist/lib/long-task-check-runner.js +3 -296
- package/dist/lib/long-task-check-shape.js +6 -1
- package/dist/lib/long-task-claim-definitions.js +1 -3
- package/dist/lib/long-task-claim-semantic-proof-floor.d.ts +3 -0
- package/dist/lib/long-task-claim-semantic-proof-floor.js +78 -0
- package/dist/lib/long-task-claims.d.ts +0 -18
- package/dist/lib/long-task-claims.js +15 -14
- package/dist/lib/long-task-command-process.d.ts +9 -0
- package/dist/lib/long-task-command-process.js +178 -0
- package/dist/lib/long-task-compact-authoring.js +3 -0
- package/dist/lib/long-task-compact-projections.js +10 -0
- package/dist/lib/long-task-complete-delivery-evidence-types.d.ts +38 -0
- package/dist/lib/long-task-complete-delivery-evidence-types.js +1 -0
- package/dist/lib/long-task-completion-types.d.ts +109 -0
- package/dist/lib/long-task-completion-types.js +1 -0
- package/dist/lib/long-task-conformance-policy.d.ts +2 -1
- package/dist/lib/long-task-conformance-policy.js +11 -4
- package/dist/lib/long-task-context-authority-topology.js +6 -4
- package/dist/lib/long-task-contract-types.d.ts +52 -1
- package/dist/lib/long-task-counterfactual-sandbox.d.ts +7 -1
- package/dist/lib/long-task-counterfactual-sandbox.js +86 -6
- package/dist/lib/long-task-delivery-compiler-preflight.d.ts +24 -0
- package/dist/lib/long-task-delivery-compiler-preflight.js +32 -0
- package/dist/lib/long-task-delivery-compiler.d.ts +1 -0
- package/dist/lib/long-task-delivery-compiler.js +59 -44
- package/dist/lib/long-task-delivery-parser.d.ts +3 -0
- package/dist/lib/long-task-delivery-parser.js +26 -8
- package/dist/lib/long-task-delivery-types.d.ts +2 -0
- package/dist/lib/long-task-delivery-types.js +2 -0
- package/dist/lib/long-task-delivery-validation.d.ts +11 -3
- package/dist/lib/long-task-delivery-validation.js +23 -8
- package/dist/lib/long-task-design-feasibility-binding-owners.d.ts +6 -0
- package/dist/lib/long-task-design-feasibility-binding-owners.js +52 -0
- package/dist/lib/long-task-design-feasibility-binding.d.ts +14 -0
- package/dist/lib/long-task-design-feasibility-binding.js +114 -0
- package/dist/lib/long-task-design-feasibility-source-closure.d.ts +11 -0
- package/dist/lib/long-task-design-feasibility-source-closure.js +87 -0
- package/dist/lib/long-task-design-obligation.d.ts +50 -0
- package/dist/lib/long-task-design-obligation.js +99 -0
- package/dist/lib/long-task-design-resource-handoff.d.ts +5 -3
- package/dist/lib/long-task-design-resource-handoff.js +64 -4
- package/dist/lib/long-task-design-resource-method-binding.js +20 -2
- package/dist/lib/long-task-effective-external-takeover.d.ts +15 -0
- package/dist/lib/long-task-effective-external-takeover.js +109 -0
- package/dist/lib/long-task-effective-external-ui-takeover.d.ts +5 -0
- package/dist/lib/long-task-effective-external-ui-takeover.js +117 -0
- package/dist/lib/long-task-evidence-capability-codec.js +91 -0
- package/dist/lib/long-task-evidence-capability-runtime.js +62 -14
- package/dist/lib/long-task-evidence-capability-types.d.ts +3 -2
- package/dist/lib/long-task-evidence-v2.d.ts +6 -1
- package/dist/lib/long-task-evidence-v2.js +253 -170
- package/dist/lib/long-task-execution-observation.d.ts +7 -0
- package/dist/lib/long-task-execution-observation.js +21 -4
- package/dist/lib/long-task-expected-authority.d.ts +4 -0
- package/dist/lib/long-task-expected-authority.js +126 -0
- package/dist/lib/long-task-external-confirmation-artifacts.d.ts +9 -0
- package/dist/lib/long-task-external-confirmation-artifacts.js +138 -0
- package/dist/lib/long-task-external-confirmation-attestation.d.ts +20 -0
- package/dist/lib/long-task-external-confirmation-attestation.js +115 -0
- package/dist/lib/long-task-external-confirmation-challenge.d.ts +23 -0
- package/dist/lib/long-task-external-confirmation-challenge.js +164 -0
- package/dist/lib/long-task-external-confirmation-context.d.ts +14 -0
- package/dist/lib/long-task-external-confirmation-context.js +53 -0
- package/dist/lib/long-task-external-confirmation-evaluation.d.ts +11 -0
- package/dist/lib/long-task-external-confirmation-evaluation.js +454 -0
- package/dist/lib/long-task-external-confirmation-expected.d.ts +8 -0
- package/dist/lib/long-task-external-confirmation-expected.js +200 -0
- package/dist/lib/long-task-external-confirmation-identity.d.ts +10 -0
- package/dist/lib/long-task-external-confirmation-identity.js +77 -0
- package/dist/lib/long-task-external-confirmation-plan.d.ts +25 -0
- package/dist/lib/long-task-external-confirmation-plan.js +148 -0
- package/dist/lib/long-task-external-confirmation-preparation.d.ts +4 -0
- package/dist/lib/long-task-external-confirmation-preparation.js +100 -0
- package/dist/lib/long-task-external-confirmation-shape.d.ts +8 -0
- package/dist/lib/long-task-external-confirmation-shape.js +387 -0
- package/dist/lib/long-task-external-confirmation-state.d.ts +10 -0
- package/dist/lib/long-task-external-confirmation-state.js +109 -0
- package/dist/lib/long-task-external-confirmation-types.d.ts +195 -0
- package/dist/lib/long-task-external-confirmation-types.js +1 -0
- package/dist/lib/long-task-final-integrity.d.ts +2 -0
- package/dist/lib/long-task-final-integrity.js +21 -10
- package/dist/lib/long-task-final-v2.d.ts +7 -2
- package/dist/lib/long-task-final-v2.js +179 -55
- package/dist/lib/long-task-finalization-identity.d.ts +27 -0
- package/dist/lib/long-task-finalization-identity.js +58 -0
- package/dist/lib/long-task-finding-context.d.ts +1 -1
- package/dist/lib/long-task-finding-context.js +139 -13
- package/dist/lib/long-task-freshness.d.ts +27 -0
- package/dist/lib/long-task-freshness.js +129 -6
- package/dist/lib/long-task-git.js +3 -3
- package/dist/lib/long-task-material-input-closure.d.ts +3 -0
- package/dist/lib/long-task-material-input-closure.js +92 -0
- package/dist/lib/long-task-obligation-authority-resolution.d.ts +12 -0
- package/dist/lib/long-task-obligation-authority-resolution.js +57 -0
- package/dist/lib/long-task-obligation-semantic-identity.d.ts +16 -0
- package/dist/lib/long-task-obligation-semantic-identity.js +116 -0
- package/dist/lib/long-task-observation-authority.d.ts +11 -0
- package/dist/lib/long-task-observation-authority.js +137 -6
- package/dist/lib/long-task-process-table.d.ts +9 -0
- package/dist/lib/long-task-process-table.js +87 -0
- package/dist/lib/long-task-process-tree.d.ts +8 -0
- package/dist/lib/long-task-process-tree.js +108 -0
- package/dist/lib/long-task-proof-adequacy.d.ts +12 -0
- package/dist/lib/long-task-proof-adequacy.js +57 -0
- package/dist/lib/long-task-proof-capability-floor.d.ts +6 -0
- package/dist/lib/long-task-proof-capability-floor.js +137 -0
- package/dist/lib/long-task-protected-files.d.ts +1 -1
- package/dist/lib/long-task-protected-files.js +1 -1
- package/dist/lib/long-task-repair-frontier-checks.d.ts +8 -0
- package/dist/lib/long-task-repair-frontier-checks.js +93 -0
- package/dist/lib/long-task-repair-frontier-groups.d.ts +2 -0
- package/dist/lib/long-task-repair-frontier-groups.js +64 -0
- package/dist/lib/long-task-repair-frontier-utils.d.ts +6 -0
- package/dist/lib/long-task-repair-frontier-utils.js +27 -0
- package/dist/lib/long-task-repair-frontier.d.ts +14 -0
- package/dist/lib/long-task-repair-frontier.js +132 -0
- package/dist/lib/long-task-risk.d.ts +3 -2
- package/dist/lib/long-task-risk.js +73 -24
- package/dist/lib/long-task-root-shape.js +148 -8
- package/dist/lib/long-task-runner-freeze.d.ts +2 -1
- package/dist/lib/long-task-runner-freeze.js +23 -8
- package/dist/lib/long-task-runtime-types.d.ts +34 -40
- package/dist/lib/long-task-semantic-assurance-policy.js +2 -11
- package/dist/lib/long-task-semantic-contract-types.d.ts +2 -1
- package/dist/lib/long-task-semantic-drift-migration.js +48 -2
- package/dist/lib/long-task-semantic-fact-binding-types.d.ts +20 -0
- package/dist/lib/long-task-semantic-fact-closure.d.ts +5 -1
- package/dist/lib/long-task-semantic-fact-closure.js +33 -5
- package/dist/lib/long-task-semantic-fact-contract-closure.js +176 -1
- package/dist/lib/long-task-semantic-fact-contract-proofs.js +18 -1
- package/dist/lib/long-task-semantic-fact-input-closure.d.ts +16 -2
- package/dist/lib/long-task-semantic-fact-input-closure.js +138 -15
- package/dist/lib/long-task-semantic-fact-provenance-closure.js +1 -1
- package/dist/lib/long-task-semantic-fact-shape.d.ts +2 -1
- package/dist/lib/long-task-semantic-fact-shape.js +35 -1
- package/dist/lib/long-task-semantic-proof-adequacy.d.ts +2 -0
- package/dist/lib/long-task-semantic-proof-adequacy.js +19 -0
- package/dist/lib/long-task-semantic-proof-profile.d.ts +5 -0
- package/dist/lib/long-task-semantic-proof-profile.js +187 -0
- package/dist/lib/long-task-shape-primitives.d.ts +1 -1
- package/dist/lib/long-task-shape-primitives.js +5 -0
- package/dist/lib/long-task-source-anchors.d.ts +10 -0
- package/dist/lib/long-task-source-anchors.js +102 -0
- package/dist/lib/long-task-source-authority-types.d.ts +46 -0
- package/dist/lib/long-task-source-claim-validation.js +36 -0
- package/dist/lib/long-task-source-conservation-facts.d.ts +8 -0
- package/dist/lib/long-task-source-conservation-facts.js +57 -0
- package/dist/lib/long-task-source-conservation-types.d.ts +34 -0
- package/dist/lib/long-task-source-conservation-types.js +1 -0
- package/dist/lib/long-task-source-conservation.d.ts +7 -0
- package/dist/lib/long-task-source-conservation.js +110 -0
- package/dist/lib/long-task-source-fragments.d.ts +6 -0
- package/dist/lib/long-task-source-fragments.js +219 -0
- package/dist/lib/long-task-source-projection-resolution.d.ts +5 -0
- package/dist/lib/long-task-source-projection-resolution.js +57 -0
- package/dist/lib/long-task-source-projection-validation.d.ts +17 -0
- package/dist/lib/long-task-source-projection-validation.js +154 -0
- package/dist/lib/long-task-source-shape.js +14 -6
- package/dist/lib/long-task-source-supersession.d.ts +5 -0
- package/dist/lib/long-task-source-supersession.js +138 -0
- package/dist/lib/long-task-stage-policy.d.ts +7 -2
- package/dist/lib/long-task-stage-policy.js +67 -23
- package/dist/lib/long-task-state.d.ts +18 -4
- package/dist/lib/long-task-state.js +319 -33
- package/dist/lib/long-task-static-observation-freeze.js +4 -3
- package/dist/lib/long-task-status-projection.d.ts +3 -1
- package/dist/lib/long-task-status-projection.js +44 -13
- package/dist/lib/long-task-status-v2.d.ts +10 -6
- package/dist/lib/long-task-status-v2.js +70 -58
- package/dist/lib/long-task-target-policy.d.ts +8 -3
- package/dist/lib/long-task-target-policy.js +40 -9
- package/dist/lib/long-task-terminal-finalization.d.ts +12 -0
- package/dist/lib/long-task-terminal-finalization.js +190 -0
- package/dist/lib/long-task-ui-design-policy.js +15 -4
- package/dist/lib/long-task-ui-surface-policy.d.ts +2 -1
- package/dist/lib/long-task-ui-surface-policy.js +7 -4
- package/dist/lib/long-task-ui-surface-validation.d.ts +3 -1
- package/dist/lib/long-task-ui-surface-validation.js +2 -2
- package/dist/lib/long-task-verifier-counterfactuals.d.ts +11 -0
- package/dist/lib/long-task-verifier-counterfactuals.js +96 -0
- package/dist/lib/long-task-verifier-execution.d.ts +9 -0
- package/dist/lib/long-task-verifier-execution.js +67 -0
- package/dist/lib/long-task-verifier-identity.js +16 -5
- package/dist/lib/long-task-verifier-v2.js +52 -65
- package/dist/lib/long-task-windows-job-supervisor-helper.d.ts +1 -0
- package/dist/lib/long-task-windows-job-supervisor-helper.js +104 -0
- package/dist/lib/long-task-windows-job-supervisor-protocol.d.ts +28 -0
- package/dist/lib/long-task-windows-job-supervisor-protocol.js +124 -0
- package/dist/lib/long-task-windows-job-supervisor-result.d.ts +11 -0
- package/dist/lib/long-task-windows-job-supervisor-result.js +152 -0
- package/dist/lib/long-task-windows-job-supervisor.d.ts +2 -0
- package/dist/lib/long-task-windows-job-supervisor.js +126 -0
- package/dist/lib/long-task-workspace-scope.d.ts +1 -0
- package/dist/lib/long-task-workspace-scope.js +4 -1
- package/dist/lib/long-task-workspace.d.ts +1 -0
- package/dist/lib/long-task-workspace.js +10 -0
- package/dist/lib/migrations.js +43 -2
- package/dist/lib/repository-path-safety.d.ts +3 -0
- package/dist/lib/repository-path-safety.js +39 -3
- package/dist/lib/semantic-fact-input-shape.d.ts +7 -2
- package/dist/lib/semantic-fact-input-shape.js +25 -1
- package/dist/lib/semantic-fact-inventory-types.d.ts +8 -2
- package/dist/lib/semantic-fact-policy-census.d.ts +1 -1
- package/dist/lib/semantic-fact-policy-census.js +5 -2
- package/dist/lib/semantic-fact-policy.d.ts +1 -1
- package/dist/lib/semantic-fact-policy.js +2 -2
- package/dist/lib/semantic-fact-proof-shape.d.ts +1 -1
- package/dist/lib/semantic-fact-property-shape.d.ts +1 -1
- package/dist/lib/validators.d.ts +3 -0
- package/dist/lib/validators.js +45 -157
- package/dist/public-api-core.d.ts +12 -0
- package/dist/public-api-core.js +12 -0
- package/dist/public-api-long-task.d.ts +10 -0
- package/dist/public-api-long-task.js +10 -0
- package/dist/public-types.d.ts +6 -1
- package/dist/schemas/design-authority-delta-assessment-v1.schema.json +191 -0
- package/dist/schemas/long-task-delivery-v2/long-task-delivery-v2.schema.json +166 -2
- package/dist/schemas/long-task-external-confirmation-record-v1.schema.json +155 -0
- package/dist/schemas/long-task-external-confirmation-record-v2.schema.json +209 -0
- package/migrations/README.md +99 -0
- package/package.json +7 -5
- package/source-mappings.yaml +18 -0
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
using System;
|
|
2
|
+
using System.Runtime.InteropServices;
|
|
3
|
+
using System.Text;
|
|
4
|
+
|
|
5
|
+
public sealed class FormalProcessSupervisorResult
|
|
6
|
+
{
|
|
7
|
+
public string RequestId { get; set; }
|
|
8
|
+
public int ProcessId { get; set; }
|
|
9
|
+
public int ExitCode { get; set; }
|
|
10
|
+
public bool TimedOut { get; set; }
|
|
11
|
+
public bool OutputOverflow { get; set; }
|
|
12
|
+
public bool DescendantsCleaned { get; set; }
|
|
13
|
+
public long StdoutBytes { get; set; }
|
|
14
|
+
public long StderrBytes { get; set; }
|
|
15
|
+
public long StartedUnixMs { get; set; }
|
|
16
|
+
public long CompletedUnixMs { get; set; }
|
|
17
|
+
public string MonotonicStartedNs { get; set; }
|
|
18
|
+
public string MonotonicCompletedNs { get; set; }
|
|
19
|
+
public string MonotonicClockId { get; set; }
|
|
20
|
+
public string WallClockId { get; set; }
|
|
21
|
+
public long UserCpu100Ns { get; set; }
|
|
22
|
+
public long KernelCpu100Ns { get; set; }
|
|
23
|
+
public long TotalCpu100Ns { get; set; }
|
|
24
|
+
public uint TotalProcesses { get; set; }
|
|
25
|
+
public uint ActiveProcessesAtResult { get; set; }
|
|
26
|
+
public uint TotalTerminatedProcesses { get; set; }
|
|
27
|
+
public string AccountingSourceKind { get; set; }
|
|
28
|
+
public string Error { get; set; }
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
public static partial class FormalProcessSupervisor
|
|
32
|
+
{
|
|
33
|
+
private const uint CREATE_SUSPENDED = 0x00000004;
|
|
34
|
+
private const uint CREATE_NO_WINDOW = 0x08000000;
|
|
35
|
+
private const uint CREATE_UNICODE_ENVIRONMENT = 0x00000400;
|
|
36
|
+
private const uint STARTF_USESTDHANDLES = 0x00000100;
|
|
37
|
+
private const uint HANDLE_FLAG_INHERIT = 0x00000001;
|
|
38
|
+
private const uint JOB_OBJECT_LIMIT_KILL_ON_JOB_CLOSE = 0x00002000;
|
|
39
|
+
private const int JobObjectBasicAccountingInformation = 1;
|
|
40
|
+
private const int JobObjectExtendedLimitInformation = 9;
|
|
41
|
+
private const uint STILL_ACTIVE = 259;
|
|
42
|
+
private const int CleanupWaitMilliseconds = 5000;
|
|
43
|
+
|
|
44
|
+
[StructLayout(LayoutKind.Sequential)]
|
|
45
|
+
private struct SECURITY_ATTRIBUTES
|
|
46
|
+
{
|
|
47
|
+
public int nLength;
|
|
48
|
+
public IntPtr lpSecurityDescriptor;
|
|
49
|
+
[MarshalAs(UnmanagedType.Bool)] public bool bInheritHandle;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
|
|
53
|
+
private struct STARTUPINFO
|
|
54
|
+
{
|
|
55
|
+
public int cb;
|
|
56
|
+
public string lpReserved;
|
|
57
|
+
public string lpDesktop;
|
|
58
|
+
public string lpTitle;
|
|
59
|
+
public uint dwX;
|
|
60
|
+
public uint dwY;
|
|
61
|
+
public uint dwXSize;
|
|
62
|
+
public uint dwYSize;
|
|
63
|
+
public uint dwXCountChars;
|
|
64
|
+
public uint dwYCountChars;
|
|
65
|
+
public uint dwFillAttribute;
|
|
66
|
+
public uint dwFlags;
|
|
67
|
+
public short wShowWindow;
|
|
68
|
+
public short cbReserved2;
|
|
69
|
+
public IntPtr lpReserved2;
|
|
70
|
+
public IntPtr hStdInput;
|
|
71
|
+
public IntPtr hStdOutput;
|
|
72
|
+
public IntPtr hStdError;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
[StructLayout(LayoutKind.Sequential)]
|
|
76
|
+
private struct PROCESS_INFORMATION
|
|
77
|
+
{
|
|
78
|
+
public IntPtr hProcess;
|
|
79
|
+
public IntPtr hThread;
|
|
80
|
+
public uint dwProcessId;
|
|
81
|
+
public uint dwThreadId;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
[StructLayout(LayoutKind.Sequential)]
|
|
85
|
+
private struct JOBOBJECT_BASIC_LIMIT_INFORMATION
|
|
86
|
+
{
|
|
87
|
+
public long PerProcessUserTimeLimit;
|
|
88
|
+
public long PerJobUserTimeLimit;
|
|
89
|
+
public uint LimitFlags;
|
|
90
|
+
public UIntPtr MinimumWorkingSetSize;
|
|
91
|
+
public UIntPtr MaximumWorkingSetSize;
|
|
92
|
+
public uint ActiveProcessLimit;
|
|
93
|
+
public UIntPtr Affinity;
|
|
94
|
+
public uint PriorityClass;
|
|
95
|
+
public uint SchedulingClass;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
[StructLayout(LayoutKind.Sequential)]
|
|
99
|
+
private struct IO_COUNTERS
|
|
100
|
+
{
|
|
101
|
+
public ulong ReadOperationCount;
|
|
102
|
+
public ulong WriteOperationCount;
|
|
103
|
+
public ulong OtherOperationCount;
|
|
104
|
+
public ulong ReadTransferCount;
|
|
105
|
+
public ulong WriteTransferCount;
|
|
106
|
+
public ulong OtherTransferCount;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
[StructLayout(LayoutKind.Sequential)]
|
|
110
|
+
private struct JOBOBJECT_EXTENDED_LIMIT_INFORMATION
|
|
111
|
+
{
|
|
112
|
+
public JOBOBJECT_BASIC_LIMIT_INFORMATION BasicLimitInformation;
|
|
113
|
+
public IO_COUNTERS IoInfo;
|
|
114
|
+
public UIntPtr ProcessMemoryLimit;
|
|
115
|
+
public UIntPtr JobMemoryLimit;
|
|
116
|
+
public UIntPtr PeakProcessMemoryUsed;
|
|
117
|
+
public UIntPtr PeakJobMemoryUsed;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
[StructLayout(LayoutKind.Sequential)]
|
|
121
|
+
private struct JOBOBJECT_BASIC_ACCOUNTING_INFORMATION
|
|
122
|
+
{
|
|
123
|
+
public long TotalUserTime;
|
|
124
|
+
public long TotalKernelTime;
|
|
125
|
+
public long ThisPeriodTotalUserTime;
|
|
126
|
+
public long ThisPeriodTotalKernelTime;
|
|
127
|
+
public uint TotalPageFaultCount;
|
|
128
|
+
public uint TotalProcesses;
|
|
129
|
+
public uint ActiveProcesses;
|
|
130
|
+
public uint TotalTerminatedProcesses;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
private sealed class CaptureState
|
|
134
|
+
{
|
|
135
|
+
public long CombinedBytes;
|
|
136
|
+
public int Overflow;
|
|
137
|
+
public long Limit;
|
|
138
|
+
public IntPtr Job;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
[DllImport("kernel32.dll", CharSet = CharSet.Unicode, SetLastError = true)]
|
|
142
|
+
private static extern IntPtr CreateJobObject(IntPtr attributes, string name);
|
|
143
|
+
|
|
144
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
145
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
146
|
+
private static extern bool SetInformationJobObject(
|
|
147
|
+
IntPtr job,
|
|
148
|
+
int informationClass,
|
|
149
|
+
ref JOBOBJECT_EXTENDED_LIMIT_INFORMATION information,
|
|
150
|
+
uint informationLength);
|
|
151
|
+
|
|
152
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
153
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
154
|
+
private static extern bool QueryInformationJobObject(
|
|
155
|
+
IntPtr job,
|
|
156
|
+
int informationClass,
|
|
157
|
+
out JOBOBJECT_BASIC_ACCOUNTING_INFORMATION information,
|
|
158
|
+
uint informationLength,
|
|
159
|
+
IntPtr returnLength);
|
|
160
|
+
|
|
161
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
162
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
163
|
+
private static extern bool AssignProcessToJobObject(IntPtr job, IntPtr process);
|
|
164
|
+
|
|
165
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
166
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
167
|
+
private static extern bool TerminateJobObject(IntPtr job, uint exitCode);
|
|
168
|
+
|
|
169
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
170
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
171
|
+
private static extern bool CreatePipe(
|
|
172
|
+
out IntPtr readPipe,
|
|
173
|
+
out IntPtr writePipe,
|
|
174
|
+
ref SECURITY_ATTRIBUTES attributes,
|
|
175
|
+
uint size);
|
|
176
|
+
|
|
177
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
178
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
179
|
+
private static extern bool SetHandleInformation(
|
|
180
|
+
IntPtr handle,
|
|
181
|
+
uint mask,
|
|
182
|
+
uint flags);
|
|
183
|
+
|
|
184
|
+
[DllImport("kernel32.dll", CharSet = CharSet.Unicode, SetLastError = true)]
|
|
185
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
186
|
+
private static extern bool CreateProcessW(
|
|
187
|
+
string applicationName,
|
|
188
|
+
StringBuilder commandLine,
|
|
189
|
+
IntPtr processAttributes,
|
|
190
|
+
IntPtr threadAttributes,
|
|
191
|
+
[MarshalAs(UnmanagedType.Bool)] bool inheritHandles,
|
|
192
|
+
uint creationFlags,
|
|
193
|
+
IntPtr environment,
|
|
194
|
+
string currentDirectory,
|
|
195
|
+
ref STARTUPINFO startupInfo,
|
|
196
|
+
out PROCESS_INFORMATION processInformation);
|
|
197
|
+
|
|
198
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
199
|
+
private static extern uint ResumeThread(IntPtr thread);
|
|
200
|
+
|
|
201
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
202
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
203
|
+
private static extern bool GetExitCodeProcess(IntPtr process, out uint exitCode);
|
|
204
|
+
|
|
205
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
206
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
207
|
+
private static extern bool TerminateProcess(IntPtr process, uint exitCode);
|
|
208
|
+
|
|
209
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
210
|
+
private static extern uint WaitForSingleObject(IntPtr handle, uint milliseconds);
|
|
211
|
+
|
|
212
|
+
[DllImport("kernel32.dll", SetLastError = true)]
|
|
213
|
+
[return: MarshalAs(UnmanagedType.Bool)]
|
|
214
|
+
private static extern bool CloseHandle(IntPtr handle);
|
|
215
|
+
}
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
Set-StrictMode -Version Latest
|
|
2
|
+
$ErrorActionPreference = 'Stop'
|
|
3
|
+
|
|
4
|
+
$utf8 = New-Object System.Text.UTF8Encoding($false)
|
|
5
|
+
[Console]::InputEncoding = $utf8
|
|
6
|
+
[Console]::OutputEncoding = $utf8
|
|
7
|
+
|
|
8
|
+
if ([System.Environment]::OSVersion.Platform -ne [System.PlatformID]::Win32NT) {
|
|
9
|
+
throw 'formal_process_supervisor_platform_unsupported'
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
$nativeSources = @(
|
|
13
|
+
Join-Path $PSScriptRoot 'formal_process_supervisor_native_types.cs'
|
|
14
|
+
Join-Path $PSScriptRoot 'formal_process_supervisor_native_run.cs'
|
|
15
|
+
Join-Path $PSScriptRoot 'formal_process_supervisor_native_helpers.cs'
|
|
16
|
+
)
|
|
17
|
+
Add-Type -Path $nativeSources
|
|
18
|
+
|
|
19
|
+
function Get-ExactProperty {
|
|
20
|
+
param(
|
|
21
|
+
[Parameter(Mandatory = $true)] [object] $Object,
|
|
22
|
+
[Parameter(Mandatory = $true)] [string] $Name
|
|
23
|
+
)
|
|
24
|
+
$matches = @($Object.PSObject.Properties | Where-Object { $_.Name -ceq $Name })
|
|
25
|
+
if ($matches.Count -ne 1) { throw 'formal_process_supervisor_request_shape' }
|
|
26
|
+
return $matches[0]
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
while (($line = [Console]::In.ReadLine()) -ne $null) {
|
|
30
|
+
if ([string]::IsNullOrWhiteSpace($line)) { continue }
|
|
31
|
+
$request = $null
|
|
32
|
+
$requestId = $null
|
|
33
|
+
$requestStage = 'json'
|
|
34
|
+
try {
|
|
35
|
+
[FormalProcessSupervisor]::AssertUniqueJsonObjectKeys($line)
|
|
36
|
+
$request = $line | ConvertFrom-Json
|
|
37
|
+
if ($null -eq $request -or $request -is [System.Array] -or $request -is [string]) {
|
|
38
|
+
throw 'formal_process_supervisor_request_shape'
|
|
39
|
+
}
|
|
40
|
+
$expected = @('schema_version', 'request_id', 'executable', 'argv', 'cwd', 'stdout_path', 'stderr_path', 'timeout_ms', 'combined_output_limit_bytes', 'environment')
|
|
41
|
+
$actual = @($request.PSObject.Properties | ForEach-Object { $_.Name } | Sort-Object)
|
|
42
|
+
$requestStage = 'fields'
|
|
43
|
+
if (@(Compare-Object ($expected | Sort-Object) $actual -CaseSensitive).Count -ne 0) {
|
|
44
|
+
throw 'formal_process_supervisor_request_shape'
|
|
45
|
+
}
|
|
46
|
+
$requestStage = 'properties'
|
|
47
|
+
$schemaVersion = (Get-ExactProperty $request 'schema_version').Value
|
|
48
|
+
$requestId = (Get-ExactProperty $request 'request_id').Value
|
|
49
|
+
$executable = (Get-ExactProperty $request 'executable').Value
|
|
50
|
+
$argv = (Get-ExactProperty $request 'argv').Value
|
|
51
|
+
$cwd = (Get-ExactProperty $request 'cwd').Value
|
|
52
|
+
$stdoutPath = (Get-ExactProperty $request 'stdout_path').Value
|
|
53
|
+
$stderrPath = (Get-ExactProperty $request 'stderr_path').Value
|
|
54
|
+
$timeoutMs = (Get-ExactProperty $request 'timeout_ms').Value
|
|
55
|
+
$combinedOutputLimit = (Get-ExactProperty $request 'combined_output_limit_bytes').Value
|
|
56
|
+
$environmentObject = (Get-ExactProperty $request 'environment').Value
|
|
57
|
+
$requestStage = 'values'
|
|
58
|
+
if ($schemaVersion -isnot [string] -or $schemaVersion -cne 'formal-process-supervisor-request-v1' -or
|
|
59
|
+
$requestId -isnot [string] -or $executable -isnot [string] -or $cwd -isnot [string] -or
|
|
60
|
+
$stdoutPath -isnot [string] -or $stderrPath -isnot [string] -or
|
|
61
|
+
$argv -isnot [System.Array] -or
|
|
62
|
+
(($timeoutMs -isnot [int]) -and ($timeoutMs -isnot [long])) -or
|
|
63
|
+
(($combinedOutputLimit -isnot [int]) -and ($combinedOutputLimit -isnot [long])) -or
|
|
64
|
+
$null -eq $environmentObject -or $environmentObject -is [System.Array] -or $environmentObject -is [string]) {
|
|
65
|
+
throw 'formal_process_supervisor_request_shape'
|
|
66
|
+
}
|
|
67
|
+
foreach ($argument in $argv) {
|
|
68
|
+
if ($argument -isnot [string]) { throw 'formal_process_supervisor_request_shape' }
|
|
69
|
+
}
|
|
70
|
+
$requestStage = 'environment'
|
|
71
|
+
$seenEnvironment = @{}
|
|
72
|
+
$environment = @(
|
|
73
|
+
$environmentObject.PSObject.Properties |
|
|
74
|
+
Sort-Object Name |
|
|
75
|
+
ForEach-Object {
|
|
76
|
+
$environmentName = [string]$_.Name
|
|
77
|
+
if ($seenEnvironment.ContainsKey($environmentName)) {
|
|
78
|
+
throw ('formal_process_supervisor_request_shape:environment_duplicate:{0}' -f $environmentName)
|
|
79
|
+
}
|
|
80
|
+
if ([string]::IsNullOrEmpty($environmentName) -or
|
|
81
|
+
$environmentName.IndexOf([char]61) -ge 0 -or
|
|
82
|
+
$environmentName.IndexOf([char]0) -ge 0 -or
|
|
83
|
+
$environmentName.IndexOf([char]13) -ge 0 -or
|
|
84
|
+
$environmentName.IndexOf([char]10) -ge 0) {
|
|
85
|
+
throw ('formal_process_supervisor_request_shape:environment_name:{0}' -f $environmentName)
|
|
86
|
+
}
|
|
87
|
+
if ($_.Value -isnot [string]) {
|
|
88
|
+
throw ('formal_process_supervisor_request_shape:environment_value:{0}:{1}' -f $environmentName, $_.Value.GetType().FullName)
|
|
89
|
+
}
|
|
90
|
+
$seenEnvironment[$environmentName] = $true
|
|
91
|
+
'{0}={1}' -f $environmentName, $_.Value
|
|
92
|
+
}
|
|
93
|
+
)
|
|
94
|
+
$requestStage = 'native_run'
|
|
95
|
+
$result = [FormalProcessSupervisor]::Run(
|
|
96
|
+
[string]$requestId,
|
|
97
|
+
[string]$executable,
|
|
98
|
+
[string[]]$argv,
|
|
99
|
+
[string]$cwd,
|
|
100
|
+
[string]$stdoutPath,
|
|
101
|
+
[string]$stderrPath,
|
|
102
|
+
[int]$timeoutMs,
|
|
103
|
+
[long]$combinedOutputLimit,
|
|
104
|
+
[string[]]$environment
|
|
105
|
+
)
|
|
106
|
+
[Console]::Out.WriteLine(($result | ConvertTo-Json -Compress -Depth 8))
|
|
107
|
+
[Console]::Out.Flush()
|
|
108
|
+
}
|
|
109
|
+
catch {
|
|
110
|
+
$failure = [ordered]@{
|
|
111
|
+
RequestId = if ($requestId -is [string]) { [string]$requestId } else { $null }
|
|
112
|
+
Error = '{0}:{1}' -f $requestStage, [string]$_.Exception.Message
|
|
113
|
+
}
|
|
114
|
+
[Console]::Out.WriteLine(($failure | ConvertTo-Json -Compress))
|
|
115
|
+
[Console]::Out.Flush()
|
|
116
|
+
}
|
|
117
|
+
}
|
|
@@ -1,65 +1,51 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: context_development_engineer
|
|
3
|
-
description: Use when the user
|
|
3
|
+
description: Use when the user asks for an architecture or engineering design, technical design/plan, complex implementation design, high-level engineering assessment, 架构方案/工程设计/技术设计/复杂实现方案/系统拆分/工程取舍/架构审计, or when the actual task content materially requires owner/source-of-truth, API/schema/data/state/lifecycle, dependency, complex alternatives, concurrency/recovery, external-integration/shared-abstraction, performance, security, compatibility/migration, implementation tradeoff, or architecture-audit judgment. Do not trigger merely for routine coding, local bug fixes, small refactors, tests, documentation, styling, package/release work, generic requests to implement/build/change code, a generic implementation plan, role-only mentions, or mentions of multi-agent, subagent, or parallel work.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Context Development Engineer
|
|
7
7
|
|
|
8
8
|
## Scope
|
|
9
9
|
|
|
10
|
-
Add
|
|
10
|
+
Add engineering-design and architecture judgment to the default Workflow Contract. This Skill is not the default implementation workflow, a coding persona, planner, agent allocator or verification authority. Routine implementation continues under root `AGENTS.md`.
|
|
11
11
|
|
|
12
12
|
Project-specific engineering rules belong in `<harnessRoot>/skills/development_engineer/SKILL.md`; the repo-local Skill is more specific, while durable conclusions still belong in `project_context/**`.
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
With a valid Long-Task binding, `long-task-workflow` alone owns its lifecycle and Final Gate. This Skill contributes architecture judgment only and creates no second plan, stage, delegation policy/state or acceptance path.
|
|
15
|
+
|
|
16
|
+
## Progressive reasoning reference
|
|
17
|
+
|
|
18
|
+
Read [engineering-design-reasoning.md](references/engineering-design-reasoning.md) completely. Apply only the methods triggered by actual uncertainty and risk; this is not a checklist, artifact schema or required sequence. An explicit-owner task without material design uncertainty stays on the lightweight default path.
|
|
15
19
|
|
|
16
20
|
## Engineering-design workflow
|
|
17
21
|
|
|
18
|
-
1. Read
|
|
19
|
-
2. State the problem, success boundary and non-goals. Separate
|
|
22
|
+
1. Read required core/default and implicated-owner Context. Before `Context Delta`, run the default bounded high-signal Context search; widen only for discovered dependency or semantic ownership.
|
|
23
|
+
2. State the problem, success boundary and non-goals. Separate facts, constraints, assumptions and unknowns, and Source/Context requirements from current-code behavior.
|
|
20
24
|
3. Identify the existing source of truth and extension point, affected owners, dependency direction, public/internal interfaces, state and lifecycle, failure/recovery boundaries, compatibility constraints and project-native verification entries.
|
|
21
25
|
4. Compare the smallest material alternatives. Prefer the existing owner/facade/adapter when it carries the stable concept; introduce an abstraction only for an evidenced change axis or durable boundary with positive net value. When foundational machinery, a mature protocol/security boundary, a dependency/shared abstraction or a nearby extension point makes sourcing material, add the risk-triggered Build / Reuse / Buy judgment below.
|
|
22
|
-
5.
|
|
26
|
+
5. Before implementation edits, surface one externally observable, repository-bound `Architecture Deliberation`: selected design, rejected material alternatives, one plausible future-change challenge, touched technical debt and disposition, forbidden shortcuts, checks, and triggered quality attributes or preservation basis.
|
|
23
27
|
6. Decide exactly one `Context Delta: none|required`. Durable ownership, architecture, API/schema/data, state/recovery, dependency, compatibility, verification/deployment or rationale changes are `required` and update the smallest owning Context before code. A task-local design that preserves those facts is `none`.
|
|
24
|
-
7.
|
|
28
|
+
7. Implement under the current Goal and Workflow Contract. After current-candidate checks, include Engineering/Architecture Conformance in default Contract Conformance, then run the separate Context drift check. Add no gate or proof ledger.
|
|
25
29
|
|
|
26
30
|
## Architecture Deliberation content
|
|
27
31
|
|
|
28
|
-
Risk changes depth,
|
|
29
|
-
|
|
30
|
-
Cover what is material:
|
|
31
|
-
|
|
32
|
-
- controlling Context and current code symbol/path;
|
|
33
|
-
- owner and unique source of truth;
|
|
34
|
-
- allowed dependency direction and prohibited bypass;
|
|
35
|
-
- inputs/outputs, interface and state/persistence/lifecycle boundaries;
|
|
36
|
-
- failure, retry, timeout, cancellation, degradation, recovery and resource release;
|
|
37
|
-
- concurrency/consistency and security/privacy/safety boundaries when triggered;
|
|
38
|
-
- compatibility, migration and rollout when a public/schema/config/versioned boundary changes;
|
|
39
|
-
- selected design, material alternatives and why they lose;
|
|
40
|
-
- a realistic adjacent future change and where it lands without duplicate truth or reverse dependency;
|
|
41
|
-
- technical debt eliminated, isolated without worsening, or blocked pending a bounded project-owned exception with owner/reason/tracking/removal condition;
|
|
42
|
-
- project-owned type/lint/AST/dependency/contract/behavior/benchmark/probe checks.
|
|
32
|
+
Risk changes depth, not whether the checkpoint occurs. Name the controlling Context/code path, concrete owner and unique source of truth, extension point, dependency direction and prohibited bypass; API/schema/data inputs/outputs; interface, state and lifecycle boundaries; material failure/recovery/resource-release behavior; and triggered concurrency, security or compatibility boundaries. State the selected design, material alternatives, a realistic future-change landing without duplicate truth or reverse dependency, technical debt disposition or bounded project-owned exception, forbidden shortcuts, and project-owned type/lint/AST/dependency/contract/behavior/benchmark/probe checks.
|
|
43
33
|
|
|
44
|
-
|
|
34
|
+
Always judge correctness/invariants and maintainability/changeability. Activate reliability/resource lifecycle, concurrency/consistency, performance/capacity/cost, security/privacy/safety, compatibility/migration/rollout and operability/observability/testability only when material. A performance claim requires workload, metric, baseline/budget, environment, comparator/tolerance and project-owned measurement; static shape is not runtime proof.
|
|
45
35
|
|
|
46
36
|
Refresh the deliberation if scope, ownership, dependency direction, selected design, quality applicability or debt disposition materially changes.
|
|
47
37
|
|
|
48
38
|
### Risk-triggered Build / Reuse / Buy
|
|
49
39
|
|
|
50
|
-
|
|
40
|
+
Record an `allowed solution set`, `prohibited failure modes` and `required rationale/evidence`, not one required library or abstraction. Choices may include the owning service/facade/adapter, standard library, installed dependency, mature compatible external library, small bounded self-implementation or intentional non-abstraction.
|
|
51
41
|
|
|
52
|
-
Enumerate every materially supported member before selecting one; selection never removes another supported member from the allowed set. Judge the
|
|
42
|
+
Enumerate every materially supported member before selecting one; selection never removes another supported member from the allowed set. Judge the viable set, retain each unselected but legal member as an alternative, and prohibit only a choice which actually exhibits a prohibited failure mode. `block` needs no supported member or missing safety/compatibility evidence; `decision-required` needs a genuine user/product/external choice.
|
|
53
43
|
|
|
54
44
|
Reject duplicate owner-held rules, extension-point bypass, an unjustified heavy dependency, plainly incomplete reinvention of mature security-sensitive behavior, incompatible license/platform support, forced abstraction over structurally similar but semantically different code and a second source of truth for one stable rule. Do not add a mandatory open-source preference, DRY rule, generic quality score, artifact, stage or Gate. Conformance asks only whether the selected choice is in the allowed set, avoids prohibited failures and has risk-proportional current evidence.
|
|
55
45
|
|
|
56
46
|
## Boundary routing
|
|
57
47
|
|
|
58
|
-
|
|
59
|
-
- Durable main/drilldown/surface information/action/feedback responsibility belongs to `context_surface_contract`.
|
|
60
|
-
- Durable Design Authority, tokens, rationale, adopted target interpretation and UI Authority Closure belong to `context_uiux_design`.
|
|
61
|
-
- New design-resource generation/handoff belongs to `design-resource-authoring`.
|
|
62
|
-
- Exact non-UI semantic facts remain owned by Source/Context; exact selected UI values remain owned by selected-design closure. This Skill does not invent either.
|
|
48
|
+
Product goals and acceptance meaning belong to `context_product_plan`. Durable main/drilldown/surface information/action/feedback responsibility belongs to `context_surface_contract`. Durable Design Authority and UI Authority Closure belong to `context_uiux_design`. New design-resource generation/handoff belongs to `design-resource-authoring`. Exact non-UI semantic facts remain owned by Source/Context; exact selected UI values remain owned by selected-design closure.
|
|
63
49
|
|
|
64
50
|
For monorepos, distinguish expandable read scope from intended/supporting workspaces. Existing Context workspace mappings are semantic routing rather than edit authorization or read ACLs. Do not add workspace registries, topology scans or empty Context mirrors.
|
|
65
51
|
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# Engineering Design Reasoning
|
|
2
|
+
|
|
3
|
+
Use this reference only after `context_development_engineer` has been selected for material engineering-design or architecture judgment. It deepens the existing Architecture Deliberation; it does not create a design phase, plan artifact, evidence ledger, second workflow or acceptance carrier. Apply the smallest useful subset below and state when a method is not material.
|
|
4
|
+
|
|
5
|
+
## 1. Frame what is actually known
|
|
6
|
+
|
|
7
|
+
Separate four categories before choosing a design:
|
|
8
|
+
|
|
9
|
+
- **Facts:** user/Source/Context requirements, repository owners and extension points, observed code/test behavior and externally verified dependency facts.
|
|
10
|
+
- **Constraints:** compatibility, platform, policy, budget, rollout, security, data, lifecycle and scope boundaries that a legal solution must preserve.
|
|
11
|
+
- **Assumptions:** plausible but unproved premises currently needed to proceed. Name who can validate them and what changes if they are false.
|
|
12
|
+
- **Unknowns:** missing information that distinguishes alternatives, changes safety or makes an acceptance claim unsupported.
|
|
13
|
+
|
|
14
|
+
Current code is implementation evidence, not silent product or architecture authority. A genuine product, legal, security, commercial, safety or external choice remains `decision-required`; implementation-equivalent freedom belongs to the current Goal.
|
|
15
|
+
|
|
16
|
+
## 2. Identify drivers and path dependence
|
|
17
|
+
|
|
18
|
+
Name the few forces that materially shape the solution: owner/source-of-truth location, dependency direction, data/state boundaries, lifecycle and failure semantics, compatibility commitments, load/threat conditions and verification reachability. Distinguish an enduring invariant from historical path dependence such as an old API, migration window, installed dependency or deployment constraint. Preserve path dependence only while its reason still applies; do not mistake legacy shape for the desired architecture.
|
|
19
|
+
|
|
20
|
+
For each material driver, point to repository evidence or authoritative external evidence. If current dependency/library behavior matters and may have changed, use current primary documentation rather than memory.
|
|
21
|
+
|
|
22
|
+
## 3. Build the smallest material alternative set
|
|
23
|
+
|
|
24
|
+
Enumerate only alternatives that could plausibly change an owner, boundary, lifecycle, dependency, operational risk or future change cost. Include the current extension point or intentional non-abstraction when viable. When sourcing is material, express Build / Reuse / Buy as the existing allowed solution set, prohibited failure modes and required rationale/evidence.
|
|
25
|
+
|
|
26
|
+
Steelman every material alternative before rejecting it:
|
|
27
|
+
|
|
28
|
+
- where it fits the requirements well;
|
|
29
|
+
- its cleanest owner and dependency direction;
|
|
30
|
+
- the strongest reason a competent maintainer would select it; and
|
|
31
|
+
- the evidence or condition under which it would become preferable.
|
|
32
|
+
|
|
33
|
+
Do not manufacture alternatives for a local choice whose owner and semantics are already explicit. Do not relabel an unselected allowed option as a prohibited failure.
|
|
34
|
+
|
|
35
|
+
## 4. Use counterfactuals and failure paths
|
|
36
|
+
|
|
37
|
+
Challenge the leading design with at least one realistic adjacent change and one relevant failure:
|
|
38
|
+
|
|
39
|
+
- If the next client, provider, state, data volume, permission model or workflow variation arrives, which existing extension point absorbs it?
|
|
40
|
+
- If the selected dependency is unavailable, stale, slow, partial or incompatible, which failure is visible and where does recovery live?
|
|
41
|
+
- If the main assumption is false, which decision changes and which parts remain valid?
|
|
42
|
+
- What would make the rejected alternative win?
|
|
43
|
+
|
|
44
|
+
Trace only triggered retry, timeout, cancellation, idempotency, transaction, concurrency, consistency, degradation, recovery and resource-release semantics. A family that is not material gets a concise preservation basis rather than invented machinery.
|
|
45
|
+
|
|
46
|
+
## 5. Select risk-triggered methods
|
|
47
|
+
|
|
48
|
+
Choose methods for the actual uncertainty; never run all of them by default:
|
|
49
|
+
|
|
50
|
+
| Trigger | Useful method | Minimum output |
|
|
51
|
+
| --- | --- | --- |
|
|
52
|
+
| Unclear owner or dependency boundary | Repository owner/extension-point trace | One source of truth, legal dependency direction and prohibited bypass |
|
|
53
|
+
| API/schema/data/state change | Contract and state-transition analysis | Inputs/outputs/errors, invariants, ownership, compatibility and recovery |
|
|
54
|
+
| Shared mutable state or parallel execution | Interleaving/consistency analysis | Atomicity boundary, ordering, idempotency and failure recovery |
|
|
55
|
+
| External integration or mature protocol | Current primary-source and repository-fit research | Supported allowed set, compatibility/security/maintenance evidence |
|
|
56
|
+
| Material performance/capacity/cost risk | Complexity model plus project-owned measurement | Workload, metric, baseline/budget, environment and comparator/tolerance |
|
|
57
|
+
| Trust, permission or sensitive data boundary | Threat/abuse-path analysis | Assets, actors, trust crossings, prohibited failures and attributable checks |
|
|
58
|
+
| Public or versioned compatibility change | Migration/rollout analysis | Compatibility window, upgrade/rollback path and current-version evidence |
|
|
59
|
+
| High uncertainty that code can cheaply resolve | Minimum architecture experiment | Hypothesis, smallest observable probe, budget and exit condition |
|
|
60
|
+
|
|
61
|
+
Research or an experiment informs the decision but is not durable authority or product acceptance. Preserve only stable conclusions in their owning Context.
|
|
62
|
+
|
|
63
|
+
## 6. Design a minimum architecture experiment
|
|
64
|
+
|
|
65
|
+
Use an experiment only when a material unknown distinguishes legal alternatives and repository inspection or authoritative documentation cannot answer it cheaply. Define:
|
|
66
|
+
|
|
67
|
+
- the exact question and competing hypotheses;
|
|
68
|
+
- the smallest representative fixture or probe that can falsify the leading assumption;
|
|
69
|
+
- environment, inputs, metric/observation and comparator;
|
|
70
|
+
- time/resource budget and stop condition; and
|
|
71
|
+
- how each possible result changes the design.
|
|
72
|
+
|
|
73
|
+
Do not turn a spike into production by default. Representative input proves only its declared scope; it cannot establish an all-provider, all-interface, all-platform or full-population claim.
|
|
74
|
+
|
|
75
|
+
## 7. Project the decision into implementation
|
|
76
|
+
|
|
77
|
+
Before handoff to the current Goal, make the design concrete enough to implement without inventing a second architecture:
|
|
78
|
+
|
|
79
|
+
- owning modules, paths and symbols plus the existing extension point;
|
|
80
|
+
- public/internal interfaces, inputs, outputs and explicit error semantics;
|
|
81
|
+
- data and state owner, persistence boundary and invariants;
|
|
82
|
+
- runtime/resource lifecycle, initialization, cleanup, recovery and observability;
|
|
83
|
+
- dependency direction and forbidden shortcuts;
|
|
84
|
+
- compatibility/migration/rollout handling when applicable;
|
|
85
|
+
- the smallest complete implementation surface and any intentional non-goals;
|
|
86
|
+
- project-owned type/lint/AST/dependency/contract/behavior/benchmark/probe checks; and
|
|
87
|
+
- `Context Delta: none|required`, with the smallest durable owner updated before code when required.
|
|
88
|
+
|
|
89
|
+
## Architecture audit route
|
|
90
|
+
|
|
91
|
+
For an audit, compare the current implementation against controlling Source/Context and the concrete owner/boundary model above. Report wrong owner, duplicate truth, reversed dependency, extension-point bypass, silent failure, incomplete lifecycle/recovery, unsupported quality claim and new/worsened debt separately. Distinguish observed defects from assumptions and unverified risks. Do not implement repairs unless the request also authorizes change.
|
|
92
|
+
|
|
93
|
+
The final current-candidate Engineering/Architecture Conformance remains in the existing default Contract Conformance or, when validly active, the sole Long-Task Final Gate. This reference creates neither.
|
|
@@ -45,7 +45,7 @@ Use the narrowest mode that matches the request:
|
|
|
45
45
|
|
|
46
46
|
- Audit Mode: inspect whether existing surfaces have clear responsibility.
|
|
47
47
|
- Compile Mode: turn audit findings or user decisions into Context candidates.
|
|
48
|
-
- Apply Mode: write durable Context only when the user explicitly allows durable writes.
|
|
48
|
+
- Apply Mode: write durable Context only when the user explicitly allows durable writes, or when already-authorized product/UI implementation independently yields `Context Delta: required` in the current Goal.
|
|
49
49
|
- Conformance Mode: check implementation against an existing Product Surface Contract.
|
|
50
50
|
|
|
51
51
|
Do not run implementation, long validation, browser smoke, app smoke or CLI smoke unless the user explicitly asks for execution.
|
|
@@ -85,7 +85,7 @@ Do not assume business responsibilities from current code shape alone. Ask for c
|
|
|
85
85
|
|
|
86
86
|
## Apply Mode
|
|
87
87
|
|
|
88
|
-
Use only when the user explicitly allows durable writes.
|
|
88
|
+
Use only when the user explicitly allows durable writes, or when product/UI implementation is already authorized and the current Goal independently decides that durable Surface/Screen responsibility changed. Skill activation, analysis, audit, candidate comparison or resource generation alone never grants write authority.
|
|
89
89
|
|
|
90
90
|
Allowed writes:
|
|
91
91
|
|
|
@@ -126,7 +126,13 @@ For each touched surface, answer only what is relevant:
|
|
|
126
126
|
|
|
127
127
|
- What surface is being touched?
|
|
128
128
|
- What platform shape does it have?
|
|
129
|
+
- Which authoritative target-user and usage-context reference applies?
|
|
129
130
|
- What primary user question does it answer?
|
|
131
|
+
- What primary task outcome, primary work object and shortest task loop does it support?
|
|
132
|
+
- Which critical context must remain visible while the user acts?
|
|
133
|
+
- How are each material operation, affected object and feedback related?
|
|
134
|
+
- Does the task force repeated scrolling, navigation or context switching to make one judgment?
|
|
135
|
+
- Which client/host, input-method and size-class constraints change the interaction topology?
|
|
130
136
|
- What belongs on the main surface?
|
|
131
137
|
- What must move to drilldown, diagnostics, operations, evidence or technical detail?
|
|
132
138
|
- Which long-running or mutating actions require task id, progress, retry, import, recovery or history?
|
|
@@ -138,6 +144,7 @@ When screen depth is material, also answer only the applicable questions:
|
|
|
138
144
|
|
|
139
145
|
- What stable surface/route key, entry context, exit outcome, inherited state and committed state identify the screen?
|
|
140
146
|
- What is the semantic information order and which regions are fixed, scrolling or overlay-owned?
|
|
147
|
+
- Across supported size classes, which regions remain, reflow, collapse, become sheets/sidebars/modals or move to another surface, and how is the primary work object preserved?
|
|
141
148
|
- Which navigation, back/cancel, focus restoration, interruption and responsive/mode/state variants are durable?
|
|
142
149
|
- For each material stable control key, what are its region/location, type/label, user task, visibility/availability, trigger/input/validation/default, interaction/navigation, loading/empty/success/failure/recovery/permission/feedback and accessibility semantics?
|
|
143
150
|
- Which exact-target/constraint/inspiration IDs govern which declared conditions, and which verification path proves each independent claim?
|
|
@@ -158,6 +165,10 @@ For any task touching user-facing surfaces, information placement, forms, filter
|
|
|
158
165
|
- Surface Platform: `<web | mobile | desktop | game | cli-tui | extension | embedded | mixed>`
|
|
159
166
|
- Owning Product Domain: `<area / subdomain>`
|
|
160
167
|
- Primary User Question: `<one concrete user judgment>`
|
|
168
|
+
- Primary Task Outcome / Work Object / Loop: `<outcome; object; orient-act-feedback-finish loop>`
|
|
169
|
+
- Critical Context Kept Visible: `<context required while acting>`
|
|
170
|
+
- Operation–Object–Feedback: `<material relationship>`
|
|
171
|
+
- Client / Size-Class Topology: `<host/input constraints and region changes>`
|
|
161
172
|
- Main Surface Allows: `<durable visible information and actions>`
|
|
162
173
|
- Main Surface Forbids: `<backend fields, raw payloads, diagnostics, debug ids, fake states, etc.>`
|
|
163
174
|
- Drilldown Ownership: `<details / evidence / operations / diagnostics / technical details>`
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: context_uiux_design
|
|
3
|
-
description: Use when the user explicitly asks to establish, adopt or repair durable UI/UX Design Authority, DESIGN.md, design-system governance, visual tokens/rationale, adopted target interpretation, UI Authority Closure, selected-design alignment
|
|
3
|
+
description: Use when the user explicitly asks to establish, adopt or repair durable UI/UX Design Authority, DESIGN.md, design-system governance, visual tokens/rationale, adopted target interpretation, UI Authority Closure, selected-design alignment or durable visual standards; or when actual task content requires material UI/UX analysis or audit for a new page/flow/complex control, information hierarchy, fixed/scroll/overlay/sheet/sidebar/modal topology, map/canvas/editor work, primary task and feedback loop, client adaptation, navigation/recovery/states or accessibility in a Minimal Context Harness project. Do not trigger merely for product/surface responsibility, design-resource generation, ordinary local UI implementation, CSS/copy/icon/image fixes, local exact-target alignment, a single-control visual preview or an unselected visual exploration.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Context UI/UX Design
|
|
@@ -11,7 +11,11 @@ Own durable Design Authority only: root `DESIGN.md`, visual identity and exact-v
|
|
|
11
11
|
|
|
12
12
|
This Skill does not own product goals/business rules/acceptance (`context_product_plan`), information/action/feedback and main/drilldown responsibility (`context_surface_contract`), resource generation (`design-resource-authoring`), implementation, or acceptance. Route rather than duplicate those owners.
|
|
13
13
|
|
|
14
|
-
Project-specific UI/UX rules may live in `<harnessRoot>/skills/uiux_design/SKILL.md`; durable facts remain in `DESIGN.md` and owning `project_context/**`.
|
|
14
|
+
Project-specific UI/UX rules may live in `<harnessRoot>/skills/uiux_design/SKILL.md`; durable facts remain in `DESIGN.md` and owning `project_context/**`. When a valid Long-Task binding is active, `long-task-workflow` alone owns Source/Contract lifecycle, formal verification, Final Gate and completion. This Skill may contribute non-authoritative task-level UI/UX analysis and Design Authority closure, but creates no second plan, lifecycle, Authority, Gate or acceptance path.
|
|
15
|
+
|
|
16
|
+
## Task-level analysis adapter
|
|
17
|
+
|
|
18
|
+
For a material task-analysis trigger, read [task-uiux-analysis.md](references/task-uiux-analysis.md) completely and apply only the relevant methods. This adapter is non-authoritative: Product/Surface/Screen Source owns the user, page duty, primary task/work object, information/action/feedback and interaction-topology facts; this Skill still owns durable Design Authority only. The current Goal may compare and select implementation candidates under those constraints. A conflicting candidate cannot proceed to resource generation or implementation until the stale owner is authoritatively updated or a genuine decision is obtained.
|
|
15
19
|
|
|
16
20
|
## UI Authority Closure
|
|
17
21
|
|
|
@@ -23,7 +27,7 @@ Project-specific UI/UX rules may live in `<harnessRoot>/skills/uiux_design/SKILL
|
|
|
23
27
|
- screen/interaction targets are fully owned by the owning Screen Contract, with `DESIGN.md` keeping only the stable key and owner/anchor;
|
|
24
28
|
- the record preserves interpretation, selection basis, immutable path/URI and digest, applicable conditions and editable upstream owner/locator/update route.
|
|
25
29
|
5. Never overwrite an adopted baseline. Create a new immutable version/digest, review it deliberately and update the unique canonical record. An implementation render/diff is evidence and cannot become the target it claims to match.
|
|
26
|
-
6. Decide exactly one `Context Delta: none|required`. Durable visual-system, token, rationale, adopted interpretation, owner/anchor or verification-route change is `required`; ordinary UI/CSS fixes that preserve authority are `none`.
|
|
30
|
+
6. Decide exactly one `Context Delta: none|required`. Skill activation, analysis, audit or candidate comparison alone authorizes no durable write. Durable visual-system, token, rationale, adopted interpretation, owner/anchor or verification-route change is `required`; ordinary UI/CSS fixes that preserve authority are `none`. When product/UI implementation is already authorized and the current Goal independently finds a durable Surface/Screen change, update the smallest owning Surface Context before code or return `decision-required`.
|
|
27
31
|
7. Route unresolved surface placement to `context_surface_contract`; route any request to generate/iterate a wireframe, prototype, visual candidate, state study or handoff to `design-resource-authoring`. Do not invoke resource generation implicitly.
|
|
28
32
|
|
|
29
33
|
## Selected-design alignment
|