@awak-app/simy-cli 0.6.23 → 0.6.26

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.
Files changed (64) hide show
  1. package/README.md +53 -0
  2. package/package.json +3 -3
  3. package/src/cli-contract.js +9 -1
  4. package/src/codex-plugins/simy/hooks/acceptance-policy.mjs +5 -0
  5. package/src/codex-plugins/simy/hooks/delivery-loop.mjs +533 -74
  6. package/src/codex-plugins/simy/hooks/purpose-cycle.mjs +63 -0
  7. package/src/codex-plugins/simy/hooks/purpose-evidence.mjs +154 -0
  8. package/src/codex-plugins/simy/hooks/purpose-rule-policy.mjs +34 -0
  9. package/src/codex-plugins/simy/hooks/purpose-rule-review.mjs +65 -0
  10. package/src/codex-plugins/simy/hooks/purpose-search.mjs +123 -0
  11. package/src/codex-plugins/simy/hooks/purpose-workspace.mjs +97 -0
  12. package/src/codex-plugins/simy/skills/delivery-loop/SKILL.md +19 -5
  13. package/src/codex-plugins/simy/skills/sqm-loop/SKILL.md +19 -4
  14. package/src/delivery-hooks/command.js +48 -0
  15. package/src/delivery-hooks/consistency-monitor.js +126 -0
  16. package/src/delivery-hooks/desktop-runtime.js +70 -0
  17. package/src/delivery-hooks/desktop.js +13 -3
  18. package/src/delivery-hooks/legacy-hook-routing.js +61 -0
  19. package/src/delivery-hooks/local-runtime.js +123 -0
  20. package/src/delivery-hooks/local-supervisor.js +25 -0
  21. package/src/delivery-hooks/runtime-watchdog.js +101 -0
  22. package/src/delivery-hooks/supervisor.js +90 -22
  23. package/src/desktop-host.js +24 -1
  24. package/src/durable-local-task-worker.js +57 -12
  25. package/src/fp-narrative-image.js +180 -0
  26. package/src/index.js +1 -1
  27. package/src/local-task.js +1 -0
  28. package/src/orchestrator/audit.js +1 -1
  29. package/src/orchestrator/charter-repair.js +93 -0
  30. package/src/orchestrator/charter-validation.js +14 -6
  31. package/src/orchestrator/checklist-continuation.js +1 -1
  32. package/src/orchestrator/contract.js +1 -3
  33. package/src/orchestrator/delivery/WORKFLOW.md +33 -60
  34. package/src/orchestrator/delivery/controls/harness-controls.json +1326 -0
  35. package/src/orchestrator/delivery/references/delivery-levels.md +17 -44
  36. package/src/orchestrator/delivery/references/pr-closure.md +2 -3
  37. package/src/orchestrator/delivery/references/state-and-receipts.md +14 -5
  38. package/src/orchestrator/delivery/references/ux-specification.md +1 -2
  39. package/src/orchestrator/delivery-level.js +4 -5
  40. package/src/orchestrator/independent-audit.js +9 -5
  41. package/src/orchestrator/instruction.js +1 -0
  42. package/src/orchestrator/loop.js +55 -18
  43. package/src/orchestrator/risk.js +1 -1
  44. package/src/orchestrator/ux-specification.js +2 -2
  45. package/src/runner.js +4 -0
  46. package/src/session-supervision/analysis-manager.js +2 -2
  47. package/src/session-supervision/automatic-continuation.js +6 -5
  48. package/src/session-supervision/autonomous-upgrade.js +55 -0
  49. package/src/session-supervision/codex-app-server.js +200 -24
  50. package/src/session-supervision/consistency-auditor.js +113 -0
  51. package/src/session-supervision/index.js +38 -11
  52. package/src/session-supervision/purpose-candidate.js +44 -0
  53. package/src/session-supervision/purpose-instruction.js +47 -0
  54. package/src/session-supervision/purpose-observer.js +172 -0
  55. package/src/session-supervision/purpose-recovery.js +264 -0
  56. package/src/session-supervision/purpose-verification.js +154 -0
  57. package/src/sqm/agent-skill.js +6 -3
  58. package/src/sqm/artifact-paths.js +39 -0
  59. package/src/sqm/claude-plugin.js +7 -0
  60. package/src/sqm/command.js +95 -27
  61. package/src/sqm/history-store.js +3 -3
  62. package/src/sqm/repository.js +19 -5
  63. package/src/sqm/workflow-update.js +14 -0
  64. package/src/workflow-reporting.js +2 -0
package/README.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # SIMY CLI
2
2
 
3
+ ローカルDelivery Loopの0.6.24候補を版固定で実行するには、[ローカル候補版のインストール・実行](docs/local-delivery-runtime.md)を参照してください。
4
+
3
5
  Local execution agent for SIMY Local Tasks and Agentic Loop runs.
4
6
 
5
7
  Action candidate search runs once for each authenticated live conversation context,
@@ -927,6 +929,19 @@ To-Be and PR reviews, plus explicitly opted-in SQM before and after PR creation.
927
929
  The [workflow reference](src/orchestrator/delivery/references/shared-system-specifications.md)
928
930
  explains baseline updates, historical regression coverage and evidence limits.
929
931
 
932
+ ## Purpose-driven automatic continuation
933
+
934
+ The desktop **Continue automatically / 自動で続ける** switch enables purpose-driven
935
+ search: hypotheses, research, experiments, minimal implementation and independent
936
+ outcome review. Failed methods trigger replanning; review findings return to repair.
937
+ Independent authorized work can continue while a controller-tracked operation waits.
938
+ The existing Codex auto-continue switch enables read-only diagnosis for uncertain or
939
+ information-waiting conversations, then assessed work. No default time/turn cap is
940
+ added; explicitly enrolled purpose budgets and user stops are preserved. Native
941
+ provider approval waits still require the original provider boundary to settle.
942
+ Workflow rules are reassessed throughout. Turning the switch off pauses work.
943
+ Actual permissions, user stops and total budgets remain enforced. See the
944
+ [contract and limitations](docs/purpose-driven-continuation.md).
930
945
 
931
946
  ### Desktop SQM history
932
947
 
@@ -1009,3 +1024,41 @@ Scope mismatch diagnostics identify the changed account, organization, device
1009
1024
  or Web host and tell the caller to restore the original identity. Launch and
1010
1025
  recovery operations do not switch identity automatically. The private
1011
1026
  `/v1/connection` endpoint rejects browser requests and never returns tokens.
1027
+
1028
+ 自律判断の改定方針と人間判断候補の一覧: [AI判断を基本にする改定](docs/ai-decision-policy.md)。LLMの文脈理解・推論・調査を基本にし、HC-01〜HC-102を判断の批判視点として適用します。
1029
+
1030
+ ### Local autonomous recovery (0.6.25)
1031
+
1032
+ `simy delivery runtime install` pins a hash-verified snapshot. `runtime desktop-install`
1033
+ prepares a separately signed **SIMY Local** app from the installed native app; the
1034
+ public application and installer selection remain unchanged. After the previous
1035
+ app has finished its normal quit, `runtime desktop-activate` launches that candidate.
1036
+ `runtime watchdog-install` installs a per-user macOS observer that may relaunch only
1037
+ that explicitly activated candidate when no live desktop owns the state directory.
1038
+ A live unknown/mismatched owner is preserved and reported. `runtime doctor` reports
1039
+ expected versus observed host identity, the all-state consistency monitor, and
1040
+ remaining task findings. `runtime legacy-hooks` routes only the exact shipped
1041
+ 0.6.23/0.6.24 Codex hook entrypoints to the verified pin, retaining originals;
1042
+ customized hooks and trust settings remain unchanged. `runtime workflows` refreshes
1043
+ existing provider workflows without enabling them.
1044
+
1045
+ For existing opted-in Codex tasks, the controller verifies original session, cwd,
1046
+ model, provider link and consent epoch before an idempotent policy migration.
1047
+ Frozen goal, criteria, grants, budgets and failure history are retained. Observable
1048
+ legacy manual criteria receive a separate independent verification route; explicit
1049
+ human/customer acceptance remains manual. Known system no-progress pauses queue
1050
+ read-only diagnosis before any replay. OFF, archive, explicit pause/stop, rejection,
1051
+ unknown effects and original budgets remain boundaries.
1052
+
1053
+ The consistency monitor scans every managed state separately from the execution
1054
+ queue. Its independent AI reads original user instructions/corrections and primary
1055
+ evidence in a distinct read-only Codex context. Durable findings/outbox receipts,
1056
+ retry backoff, separate lease, measured token usage and failed/stale heartbeats are
1057
+ recorded; an audit receipt does not complete a task. SQM evidence stays bound to its
1058
+ repository/commit/diff scope and does not prove the whole user outcome. Git output
1059
+ no longer uses a 10 MiB `execFile` buffer; the full diff is still retained in memory.
1060
+
1061
+ Codex cold recovery and independent audit are supported. Claude retains its
1062
+ original live-hook boundary; cold recovery and detached independent audit are not
1063
+ implemented in this release and are exposed as a capability gap. Neither an
1064
+ unverified original model nor a different provider is substituted automatically.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@awak-app/simy-cli",
3
- "version": "0.6.23",
3
+ "version": "0.6.26",
4
4
  "description": "Local SIMY executor for non-coding Local Tasks and Agentic Loop runs.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -12,7 +12,7 @@
12
12
  ],
13
13
  "scripts": {
14
14
  "start": "node ./src/index.js",
15
- "test": "node --test",
15
+ "test": "node --test --test-concurrency=2",
16
16
  "test:e2e:console": "node ./scripts/console-e2e.js",
17
17
  "test:e2e:work-activity": "node ./scripts/work-activity-e2e.js",
18
18
  "test:e2e:sqm-complete-loop": "node ./scripts/sqm-complete-loop-e2e.js",
@@ -38,7 +38,7 @@
38
38
  "test:e2e:console:real-provider": "node ./scripts/real-provider-console-e2e.js",
39
39
  "test:e2e:console:fullstack": "node ./scripts/fullstack-cli-smoke.js",
40
40
  "check": "npm run check:auto-update && node --check ./src/desktop-executor.js && node --check ./src/local-task.js && node --check ./scripts/desktop-executor-e2e.js && node --check ./scripts/pre-guardrail-e2e.js && node --check ./scripts/fixtures/fake-desktop-provider.js && npm run check:syntax && npm run check:session-supervision-syntax && npm run check:real-provider-syntax && npm test && npm run check:package",
41
- "check:session-supervision-syntax": "node --check ./src/session-supervision/index.js && node --check ./src/session-supervision/discovery-window.js && node --check ./src/session-supervision/codex-app-server.js && node --check ./src/session-supervision/claude-sessions.js && node --check ./src/session-supervision/original-session-target.js && node --check ./src/session-supervision/action-association.js && node --check ./src/session-supervision/action-association-host.js && node --check ./src/session-supervision/action-association-api.js && node --check ./src/session-supervision/association-store.js && node --check ./src/session-supervision/action-deadline.js && node --check ./src/session-supervision/action-deadline-store.js && node --check ./src/codex-plugins/simy/hooks/action-association.mjs",
41
+ "check:session-supervision-syntax": "node --check ./src/session-supervision/index.js && node --check ./src/session-supervision/discovery-window.js && node --check ./src/session-supervision/codex-app-server.js && node --check ./src/session-supervision/claude-sessions.js && node --check ./src/session-supervision/original-session-target.js && node --check ./src/session-supervision/action-association.js && node --check ./src/session-supervision/action-association-host.js && node --check ./src/session-supervision/action-association-api.js && node --check ./src/session-supervision/association-store.js && node --check ./src/session-supervision/action-deadline.js && node --check ./src/session-supervision/action-deadline-store.js && node --check ./src/codex-plugins/simy/hooks/action-association.mjs && node --check ./src/session-supervision/purpose-instruction.js && node --check ./src/session-supervision/purpose-recovery.js && node --check ./src/session-supervision/purpose-candidate.js && node --check ./src/codex-plugins/simy/hooks/purpose-cycle.mjs && node --check ./src/codex-plugins/simy/hooks/purpose-rule-review.mjs && node --check ./src/codex-plugins/simy/hooks/purpose-search.mjs && node --check ./src/codex-plugins/simy/hooks/purpose-evidence.mjs && node --check ./src/session-supervision/purpose-observer.js && node --check ./src/session-supervision/purpose-verification.js && node --check ./src/codex-plugins/simy/hooks/purpose-workspace.mjs && node --check ./scripts/purpose-search-live-e2e.js",
42
42
  "check:auto-update": "node --check ./src/auto-update.js && node --check ./scripts/auto-update-e2e.js && npm run check:sqm",
43
43
  "check:workflow-observation-sender": "node --check ./src/workflow-observation-sender.js",
44
44
  "check:sqm": "node --check ./src/sqm/canonical.js && node --check ./src/sqm/validation.js && node --check ./src/sqm/reliability.js && node --check ./src/sqm/repository.js && node --check ./src/sqm/checkers.js && node --check ./src/sqm/bundle-store.js && node --check ./src/sqm/proof.js && node --check ./src/sqm/evidence-client.js && node --check ./src/sqm/session.js && node --check ./src/sqm/index.js && node --check ./src/sqm/command.js && node --check ./src/sqm/agent-skill.js && node --check ./src/sqm/workflow-onboarding.js && node --check ./src/sqm/workflow-update.js && node --check ./src/sqm/history-store.js && node --check ./src/sqm/review-worker.js && node --check ./scripts/sqm-complete-loop-e2e.js && node --check ./scripts/sqm-local-review-e2e.js",
@@ -13,9 +13,16 @@ import {
13
13
  } from "./durable-local-task-steps-contract.js";
14
14
  import { buildExecutionCapabilityContract } from "./execution-capability-contract.js";
15
15
 
16
- export const CLI_VERSION = "0.6.23";
16
+ export const CLI_VERSION = "0.6.26";
17
17
  export const CLI_API_CONTRACT_VERSION = 10;
18
18
 
19
+ export function narrativeImageCapabilityMetadata() {
20
+ return {
21
+ schema_version: "fp_narrative_image.v1",
22
+ receipt_schema_version: "fp_native_image_receipt.v1",
23
+ };
24
+ }
25
+
19
26
  export function withCliContract(
20
27
  capabilities = {},
21
28
  installMode = null,
@@ -25,6 +32,7 @@ export function withCliContract(
25
32
  ...capabilities,
26
33
  cli_version: CLI_VERSION,
27
34
  api_contract_version: CLI_API_CONTRACT_VERSION,
35
+ fp_narrative_image: narrativeImageCapabilityMetadata(),
28
36
  local_task_file_capabilities: localTaskFileCapabilityMetadata(),
29
37
  local_task_scenario_packs: localTaskScenarioPackMetadata(),
30
38
  bounded_local_task_subtasks:
@@ -0,0 +1,5 @@
1
+ // Frozen manual acceptance is an explicit enrollment boundary. Its description
2
+ // or an old auto-continue switch cannot authorize a different verifier.
3
+ export function effectiveAcceptanceCriteria(managed) {
4
+ return managed?.acceptanceCriteria || [];
5
+ }