instar 1.3.225 → 1.3.227

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 (52) hide show
  1. package/dist/cli.js +10 -0
  2. package/dist/cli.js.map +1 -1
  3. package/dist/commands/devCiFailures.d.ts +39 -0
  4. package/dist/commands/devCiFailures.d.ts.map +1 -0
  5. package/dist/commands/devCiFailures.js +133 -0
  6. package/dist/commands/devCiFailures.js.map +1 -0
  7. package/dist/commands/server.d.ts.map +1 -1
  8. package/dist/commands/server.js +20 -1
  9. package/dist/commands/server.js.map +1 -1
  10. package/dist/config/ConfigDefaults.d.ts.map +1 -1
  11. package/dist/config/ConfigDefaults.js +11 -0
  12. package/dist/config/ConfigDefaults.js.map +1 -1
  13. package/dist/core/PostUpdateMigrator.d.ts.map +1 -1
  14. package/dist/core/PostUpdateMigrator.js +18 -0
  15. package/dist/core/PostUpdateMigrator.js.map +1 -1
  16. package/dist/core/StateManager.d.ts +22 -1
  17. package/dist/core/StateManager.d.ts.map +1 -1
  18. package/dist/core/StateManager.js +45 -6
  19. package/dist/core/StateManager.js.map +1 -1
  20. package/dist/core/types.d.ts +46 -0
  21. package/dist/core/types.d.ts.map +1 -1
  22. package/dist/core/types.js.map +1 -1
  23. package/dist/monitoring/BurnDetector.d.ts +11 -0
  24. package/dist/monitoring/BurnDetector.d.ts.map +1 -1
  25. package/dist/monitoring/BurnDetector.js +15 -3
  26. package/dist/monitoring/BurnDetector.js.map +1 -1
  27. package/dist/monitoring/SessionReaper.d.ts +74 -1
  28. package/dist/monitoring/SessionReaper.d.ts.map +1 -1
  29. package/dist/monitoring/SessionReaper.js +146 -6
  30. package/dist/monitoring/SessionReaper.js.map +1 -1
  31. package/dist/scaffold/templates.d.ts.map +1 -1
  32. package/dist/scaffold/templates.js +9 -0
  33. package/dist/scaffold/templates.js.map +1 -1
  34. package/dist/server/AgentServer.d.ts.map +1 -1
  35. package/dist/server/AgentServer.js +56 -25
  36. package/dist/server/AgentServer.js.map +1 -1
  37. package/package.json +1 -1
  38. package/scripts/generate-builtin-manifest.cjs +1 -0
  39. package/src/data/builtin-manifest.json +59 -51
  40. package/src/scaffold/templates.ts +9 -0
  41. package/upgrades/1.3.226.md +111 -0
  42. package/upgrades/1.3.227.md +109 -0
  43. package/upgrades/burn-detector-activity-gate.eli16.md +53 -0
  44. package/upgrades/dev-ci-failures-tool.eli16.md +21 -0
  45. package/upgrades/reaper-busy-orphan-detect.eli16.md +33 -0
  46. package/upgrades/reaper-cpu-aware-keep.eli16.md +30 -0
  47. package/upgrades/side-effects/burn-detector-activity-gate.md +110 -0
  48. package/upgrades/side-effects/dev-ci-failures-tool.md +54 -0
  49. package/upgrades/side-effects/reaper-busy-orphan-detect.md +85 -0
  50. package/upgrades/side-effects/reaper-cpu-aware-keep.md +90 -0
  51. package/upgrades/side-effects/statemanager-listsessions-cache.md +72 -0
  52. package/upgrades/statemanager-listsessions-cache.eli16.md +36 -0
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "$schema": "./builtin-manifest.schema.json",
3
3
  "schemaVersion": 1,
4
- "generatedAt": "2026-06-03T14:47:08.272Z",
5
- "instarVersion": "1.3.225",
6
- "entryCount": 196,
4
+ "generatedAt": "2026-06-03T21:22:48.492Z",
5
+ "instarVersion": "1.3.227",
6
+ "entryCount": 197,
7
7
  "entries": {
8
8
  "hook:session-start": {
9
9
  "id": "hook:session-start",
@@ -11,7 +11,7 @@
11
11
  "domain": "identity",
12
12
  "sourcePath": "src/core/PostUpdateMigrator.ts",
13
13
  "installedPath": ".instar/hooks/instar/session-start.sh",
14
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
14
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
15
15
  "since": "2025-01-01"
16
16
  },
17
17
  "hook:dangerous-command-guard": {
@@ -20,7 +20,7 @@
20
20
  "domain": "safety",
21
21
  "sourcePath": "src/core/PostUpdateMigrator.ts",
22
22
  "installedPath": ".instar/hooks/instar/dangerous-command-guard.sh",
23
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
23
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
24
24
  "since": "2025-01-01"
25
25
  },
26
26
  "hook:grounding-before-messaging": {
@@ -29,7 +29,7 @@
29
29
  "domain": "safety",
30
30
  "sourcePath": "src/core/PostUpdateMigrator.ts",
31
31
  "installedPath": ".instar/hooks/instar/grounding-before-messaging.sh",
32
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
32
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
33
33
  "since": "2025-01-01"
34
34
  },
35
35
  "hook:compaction-recovery": {
@@ -38,7 +38,7 @@
38
38
  "domain": "identity",
39
39
  "sourcePath": "src/core/PostUpdateMigrator.ts",
40
40
  "installedPath": ".instar/hooks/instar/compaction-recovery.sh",
41
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
41
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
42
42
  "since": "2025-01-01"
43
43
  },
44
44
  "hook:external-operation-gate": {
@@ -47,7 +47,7 @@
47
47
  "domain": "safety",
48
48
  "sourcePath": "src/core/PostUpdateMigrator.ts",
49
49
  "installedPath": ".instar/hooks/instar/external-operation-gate.js",
50
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
50
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
51
51
  "since": "2025-01-01"
52
52
  },
53
53
  "hook:deferral-detector": {
@@ -56,7 +56,7 @@
56
56
  "domain": "safety",
57
57
  "sourcePath": "src/core/PostUpdateMigrator.ts",
58
58
  "installedPath": ".instar/hooks/instar/deferral-detector.js",
59
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
59
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
60
60
  "since": "2025-01-01"
61
61
  },
62
62
  "hook:self-stop-guard": {
@@ -65,7 +65,7 @@
65
65
  "domain": "coherence",
66
66
  "sourcePath": "src/core/PostUpdateMigrator.ts",
67
67
  "installedPath": ".instar/hooks/instar/self-stop-guard.js",
68
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
68
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
69
69
  "since": "2025-01-01"
70
70
  },
71
71
  "hook:post-action-reflection": {
@@ -74,7 +74,7 @@
74
74
  "domain": "evolution",
75
75
  "sourcePath": "src/core/PostUpdateMigrator.ts",
76
76
  "installedPath": ".instar/hooks/instar/post-action-reflection.js",
77
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
77
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
78
78
  "since": "2025-01-01"
79
79
  },
80
80
  "hook:external-communication-guard": {
@@ -83,7 +83,7 @@
83
83
  "domain": "safety",
84
84
  "sourcePath": "src/core/PostUpdateMigrator.ts",
85
85
  "installedPath": ".instar/hooks/instar/external-communication-guard.js",
86
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
86
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
87
87
  "since": "2025-01-01"
88
88
  },
89
89
  "hook:scope-coherence-collector": {
@@ -92,7 +92,7 @@
92
92
  "domain": "coherence",
93
93
  "sourcePath": "src/core/PostUpdateMigrator.ts",
94
94
  "installedPath": ".instar/hooks/instar/scope-coherence-collector.js",
95
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
95
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
96
96
  "since": "2025-01-01"
97
97
  },
98
98
  "hook:scope-coherence-checkpoint": {
@@ -101,7 +101,7 @@
101
101
  "domain": "coherence",
102
102
  "sourcePath": "src/core/PostUpdateMigrator.ts",
103
103
  "installedPath": ".instar/hooks/instar/scope-coherence-checkpoint.js",
104
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
104
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
105
105
  "since": "2025-01-01"
106
106
  },
107
107
  "hook:free-text-guard": {
@@ -110,7 +110,7 @@
110
110
  "domain": "safety",
111
111
  "sourcePath": "src/core/PostUpdateMigrator.ts",
112
112
  "installedPath": ".instar/hooks/instar/free-text-guard.sh",
113
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
113
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
114
114
  "since": "2025-01-01"
115
115
  },
116
116
  "hook:claim-intercept": {
@@ -119,7 +119,7 @@
119
119
  "domain": "coherence",
120
120
  "sourcePath": "src/core/PostUpdateMigrator.ts",
121
121
  "installedPath": ".instar/hooks/instar/claim-intercept.js",
122
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
122
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
123
123
  "since": "2025-01-01"
124
124
  },
125
125
  "hook:claim-intercept-response": {
@@ -128,7 +128,7 @@
128
128
  "domain": "coherence",
129
129
  "sourcePath": "src/core/PostUpdateMigrator.ts",
130
130
  "installedPath": ".instar/hooks/instar/claim-intercept-response.js",
131
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
131
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
132
132
  "since": "2025-01-01"
133
133
  },
134
134
  "hook:stop-gate-router": {
@@ -137,7 +137,7 @@
137
137
  "domain": "safety",
138
138
  "sourcePath": "src/core/PostUpdateMigrator.ts",
139
139
  "installedPath": ".instar/hooks/instar/stop-gate-router.js",
140
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
140
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
141
141
  "since": "2025-01-01"
142
142
  },
143
143
  "hook:auto-approve-permissions": {
@@ -146,7 +146,7 @@
146
146
  "domain": "safety",
147
147
  "sourcePath": "src/core/PostUpdateMigrator.ts",
148
148
  "installedPath": ".instar/hooks/instar/auto-approve-permissions.js",
149
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
149
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
150
150
  "since": "2025-01-01"
151
151
  },
152
152
  "job:health-check": {
@@ -778,7 +778,7 @@
778
778
  "type": "cli-command",
779
779
  "domain": "setup",
780
780
  "sourcePath": "src/cli.ts",
781
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
781
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
782
782
  "since": "2025-01-01"
783
783
  },
784
784
  "cli:setup": {
@@ -786,7 +786,7 @@
786
786
  "type": "cli-command",
787
787
  "domain": "setup",
788
788
  "sourcePath": "src/cli.ts",
789
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
789
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
790
790
  "since": "2025-01-01"
791
791
  },
792
792
  "cli:add": {
@@ -794,7 +794,7 @@
794
794
  "type": "cli-command",
795
795
  "domain": "setup",
796
796
  "sourcePath": "src/cli.ts",
797
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
797
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
798
798
  "since": "2025-01-01"
799
799
  },
800
800
  "cli:backup": {
@@ -802,7 +802,7 @@
802
802
  "type": "cli-command",
803
803
  "domain": "operations",
804
804
  "sourcePath": "src/cli.ts",
805
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
805
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
806
806
  "since": "2025-01-01"
807
807
  },
808
808
  "cli:git": {
@@ -810,7 +810,7 @@
810
810
  "type": "cli-command",
811
811
  "domain": "coordination",
812
812
  "sourcePath": "src/cli.ts",
813
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
813
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
814
814
  "since": "2025-01-01"
815
815
  },
816
816
  "cli:memory": {
@@ -818,7 +818,7 @@
818
818
  "type": "cli-command",
819
819
  "domain": "memory",
820
820
  "sourcePath": "src/cli.ts",
821
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
821
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
822
822
  "since": "2025-01-01"
823
823
  },
824
824
  "cli:knowledge": {
@@ -826,7 +826,7 @@
826
826
  "type": "cli-command",
827
827
  "domain": "memory",
828
828
  "sourcePath": "src/cli.ts",
829
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
829
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
830
830
  "since": "2025-01-01"
831
831
  },
832
832
  "cli:semantic": {
@@ -834,7 +834,7 @@
834
834
  "type": "cli-command",
835
835
  "domain": "memory",
836
836
  "sourcePath": "src/cli.ts",
837
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
837
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
838
838
  "since": "2025-01-01"
839
839
  },
840
840
  "cli:intent": {
@@ -842,7 +842,7 @@
842
842
  "type": "cli-command",
843
843
  "domain": "intent",
844
844
  "sourcePath": "src/cli.ts",
845
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
845
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
846
846
  "since": "2025-01-01"
847
847
  },
848
848
  "cli:feedback": {
@@ -850,7 +850,7 @@
850
850
  "type": "cli-command",
851
851
  "domain": "feedback",
852
852
  "sourcePath": "src/cli.ts",
853
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
853
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
854
854
  "since": "2025-01-01"
855
855
  },
856
856
  "cli:server": {
@@ -858,7 +858,7 @@
858
858
  "type": "cli-command",
859
859
  "domain": "server",
860
860
  "sourcePath": "src/cli.ts",
861
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
861
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
862
862
  "since": "2025-01-01"
863
863
  },
864
864
  "cli:status": {
@@ -866,7 +866,7 @@
866
866
  "type": "cli-command",
867
867
  "domain": "monitoring",
868
868
  "sourcePath": "src/cli.ts",
869
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
869
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
870
870
  "since": "2025-01-01"
871
871
  },
872
872
  "cli:user": {
@@ -874,7 +874,7 @@
874
874
  "type": "cli-command",
875
875
  "domain": "users",
876
876
  "sourcePath": "src/cli.ts",
877
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
877
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
878
878
  "since": "2025-01-01"
879
879
  },
880
880
  "cli:relationship": {
@@ -882,7 +882,7 @@
882
882
  "type": "cli-command",
883
883
  "domain": "relationships",
884
884
  "sourcePath": "src/cli.ts",
885
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
885
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
886
886
  "since": "2025-01-01"
887
887
  },
888
888
  "cli:job": {
@@ -890,7 +890,7 @@
890
890
  "type": "cli-command",
891
891
  "domain": "scheduling",
892
892
  "sourcePath": "src/cli.ts",
893
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
893
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
894
894
  "since": "2025-01-01"
895
895
  },
896
896
  "cli:lifeline": {
@@ -898,7 +898,7 @@
898
898
  "type": "cli-command",
899
899
  "domain": "communication",
900
900
  "sourcePath": "src/cli.ts",
901
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
901
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
902
902
  "since": "2025-01-01"
903
903
  },
904
904
  "cli:list": {
@@ -906,7 +906,7 @@
906
906
  "type": "cli-command",
907
907
  "domain": "monitoring",
908
908
  "sourcePath": "src/cli.ts",
909
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
909
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
910
910
  "since": "2025-01-01"
911
911
  },
912
912
  "cli:autostart": {
@@ -914,7 +914,7 @@
914
914
  "type": "cli-command",
915
915
  "domain": "operations",
916
916
  "sourcePath": "src/cli.ts",
917
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
917
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
918
918
  "since": "2025-01-01"
919
919
  },
920
920
  "cli:migrate": {
@@ -922,7 +922,7 @@
922
922
  "type": "cli-command",
923
923
  "domain": "updates",
924
924
  "sourcePath": "src/cli.ts",
925
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
925
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
926
926
  "since": "2025-01-01"
927
927
  },
928
928
  "cli:machines": {
@@ -930,7 +930,7 @@
930
930
  "type": "cli-command",
931
931
  "domain": "coordination",
932
932
  "sourcePath": "src/cli.ts",
933
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
933
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
934
934
  "since": "2025-01-01"
935
935
  },
936
936
  "cli:whoami": {
@@ -938,7 +938,7 @@
938
938
  "type": "cli-command",
939
939
  "domain": "identity",
940
940
  "sourcePath": "src/cli.ts",
941
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
941
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
942
942
  "since": "2025-01-01"
943
943
  },
944
944
  "cli:pair": {
@@ -946,7 +946,7 @@
946
946
  "type": "cli-command",
947
947
  "domain": "coordination",
948
948
  "sourcePath": "src/cli.ts",
949
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
949
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
950
950
  "since": "2025-01-01"
951
951
  },
952
952
  "cli:join": {
@@ -954,7 +954,7 @@
954
954
  "type": "cli-command",
955
955
  "domain": "coordination",
956
956
  "sourcePath": "src/cli.ts",
957
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
957
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
958
958
  "since": "2025-01-01"
959
959
  },
960
960
  "cli:wakeup": {
@@ -962,7 +962,7 @@
962
962
  "type": "cli-command",
963
963
  "domain": "coordination",
964
964
  "sourcePath": "src/cli.ts",
965
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
965
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
966
966
  "since": "2025-01-01"
967
967
  },
968
968
  "cli:leave": {
@@ -970,7 +970,7 @@
970
970
  "type": "cli-command",
971
971
  "domain": "coordination",
972
972
  "sourcePath": "src/cli.ts",
973
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
973
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
974
974
  "since": "2025-01-01"
975
975
  },
976
976
  "cli:doctor": {
@@ -978,7 +978,7 @@
978
978
  "type": "cli-command",
979
979
  "domain": "monitoring",
980
980
  "sourcePath": "src/cli.ts",
981
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
981
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
982
982
  "since": "2025-01-01"
983
983
  },
984
984
  "cli:review": {
@@ -986,7 +986,7 @@
986
986
  "type": "cli-command",
987
987
  "domain": "monitoring",
988
988
  "sourcePath": "src/cli.ts",
989
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
989
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
990
990
  "since": "2025-01-01"
991
991
  },
992
992
  "cli:nuke": {
@@ -994,7 +994,7 @@
994
994
  "type": "cli-command",
995
995
  "domain": "operations",
996
996
  "sourcePath": "src/cli.ts",
997
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
997
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
998
998
  "since": "2025-01-01"
999
999
  },
1000
1000
  "cli:playbook": {
@@ -1002,7 +1002,7 @@
1002
1002
  "type": "cli-command",
1003
1003
  "domain": "context",
1004
1004
  "sourcePath": "src/cli.ts",
1005
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
1005
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
1006
1006
  "since": "2025-01-01"
1007
1007
  },
1008
1008
  "cli:dev-preflight": {
@@ -1010,7 +1010,15 @@
1010
1010
  "type": "cli-command",
1011
1011
  "domain": "development",
1012
1012
  "sourcePath": "src/cli.ts",
1013
- "contentHash": "1b2634f7e1f2a14c409625a87774b5d9fe06cf11b529d38d8b4489a76c6b6f4d",
1013
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
1014
+ "since": "2025-01-01"
1015
+ },
1016
+ "cli:dev-ci-failures": {
1017
+ "id": "cli:dev-ci-failures",
1018
+ "type": "cli-command",
1019
+ "domain": "development",
1020
+ "sourcePath": "src/cli.ts",
1021
+ "contentHash": "0dbe9408c77a7f88ef9978644cb9be45885c7a095ff8424361a1e9f7953cd099",
1014
1022
  "since": "2025-01-01"
1015
1023
  },
1016
1024
  "template:build-stop-hook.sh": {
@@ -1482,7 +1490,7 @@
1482
1490
  "type": "subsystem",
1483
1491
  "domain": "server",
1484
1492
  "sourcePath": "src/server/AgentServer.ts",
1485
- "contentHash": "d1851d4bb663dd524af17cf4c45e143bc441314bbe2b005c5ee1626019b92184",
1493
+ "contentHash": "e7cb9908ed4d4ff87da6b2398a2d1c472973085d8d55d71b5754ca13dd3f7835",
1486
1494
  "since": "2025-01-01"
1487
1495
  },
1488
1496
  "subsystem:session-manager": {
@@ -1514,7 +1522,7 @@
1514
1522
  "type": "subsystem",
1515
1523
  "domain": "updates",
1516
1524
  "sourcePath": "src/core/PostUpdateMigrator.ts",
1517
- "contentHash": "e0f9e7499c6ae8288ddda30d255c9f6a8b0692fde57da6eb798a8b38976b49b5",
1525
+ "contentHash": "ee2783d1b5cfa194f43e90b4a7fa0d9864e0d62b8c3f0634f79b45d0d2d4ff1c",
1518
1526
  "since": "2025-01-01"
1519
1527
  },
1520
1528
  "subsystem:scheduler": {
@@ -406,6 +406,8 @@ This routes feedback to the Instar maintainers automatically. Valid types: \`bug
406
406
 
407
407
  **SessionReaper** — Pressure-aware cleanup of idle-but-alive sessions (sessions parked at a ready prompt, doing nothing, holding resources). Distinct from the crash/zombie reapers: it only acts when the machine is under pressure, and it NEVER reaps a session that might be working — it requires positive proof a session is idle (turn complete + at a ready prompt + screen byte-static across several checks + no running process + no transcript growth), and KEEPs on any ambiguity. Ships OFF + dry-run by default (the only monitor that kills on a heuristic).
408
408
  - Pressure is **CPU-aware**: the tier is the WORST of memory (free %) and CPU (1-min load ÷ cores), so a CPU-bound box raises pressure even when free RAM is fine. Tune the CPU thresholds in \`.instar/config.json\` → \`{"monitoring": {"sessionReaper": {"cpuModerateLoadPerCore": 1.0, "cpuCriticalLoadPerCore": 1.5}}}\`.
409
+ - **CPU-aware active-process keep** (\`cpuAwareActiveProcessKeep\`, dark by default; dev agents enable it via \`developmentAgent\`): normally a session is KEPT if any non-baseline child process EXISTS. Under CPU pressure that's too coarse — a wedged or idle child (a hung MCP server, a stuck \`codex exec\` job) burns ~no CPU yet holds the idle session un-reapable forever, inflating host load. With this on, under pressure the existence-veto requires *positive CPU progress*; a CPU-flat child no longer blocks reaping (the reaper still falls through to its transcript-growth + positive-idle checks, which must clear, so a genuinely-working session is never reaped). Strict no-op off-pressure and whenever CPU can't be measured. Each time it relaxes the veto it writes a \`cpu-keep-tightened\` row to the decision audit. If a user asks "why did my idle session get reaped under load even though a process was still attached?" — that's this; read \`logs/reaper-audit.jsonl\`.
410
+ - **Busy-orphan detection** (\`busyOrphanDetection\`, OBSERVE-ONLY, dark by default; dev agents on): the inverse blind spot. CPU-progress is a proxy for "useful" — but a *useless* process that SPINS (a hot-loop, a wedged job burning CPU) looks "active" and would keep a session pinned. When an idle session (idle prompt + flat transcript) is held only by a child that's *burning* CPU across an extended dwell, the reaper records a \`busy-orphan-suspected\` audit row (and \`busy-orphan-cleared\` on recovery). It NEVER changes the keep/kill decision — it just makes the "useless-but-busy child pins an idle session" case measurable, so safe auto-reclaim can graduate later with data. Read \`logs/reaper-audit.jsonl\` (filter \`busy-orphan-suspected\`).
409
411
  - Why it matters: idle sessions pile up across agents until the machine starves (CPU *or* memory) and new sessions get "spawn denied" — silently breaking cross-agent messaging. This sweeps them, but only under real pressure.
410
412
  - See current state / why each session is kept or flagged: \`curl -H "Authorization: Bearer $AUTH" http://localhost:${port}/sessions/reaper\` (the \`pressure.inputs\` shows freePct, loadPerCore, and the memTier/cpuTier breakdown).
411
413
  - **Decision audit** — the "what is the reaper considering, and why did it keep/kill each session?" trail. Every keep/kill decision *change* (logged on transition, not every tick) + the reap-path events, each stamped with the pressure tier that drove it, land in \`logs/reaper-audit.jsonl\`. Read the tail: \`curl -H "Authorization: Bearer $AUTH" "http://localhost:${port}/sessions/reaper/audit?limit=50"\` → \`{ entries: [...] }\`. Read-only, silent (no notifications) — purely for inspection.
@@ -429,6 +431,11 @@ This routes feedback to the Instar maintainers automatically. Valid types: \`bug
429
431
  - Tune (rarely needed) in \`.instar/config.json\`: \`{"monitoring": {"sleepWake": {"maxLoadRatio": 1.5, "longSleepFloorSeconds": 300, "minWakeIntervalMs": 60000}}}\`. Defaults live in code, so the guard is active with no config.
430
432
  - Proactive: user reports "you keep restarting" / "your agent is overloaded" / "is it a memory problem?" → GET /monitoring/sleep-wake, then check \`uptime\` load average against core count; explain CPU oversubscription (load ≫ cores) vs. memory.
431
433
 
434
+ **Token-Burn Alerts** — The "an unknown component is using more than a quarter of the agent's token budget" heads-up. The BurnDetector watches per-component 24h token share and the 1h spend rate, and alerts when one component is *actively* burning. Two things to know when a user asks about the noise:
435
+ - An alert only fires for a component spending **right now** (last-1h tokens above \`absoluteShareActivityFloorTokens\`, default 0 = any positive current spend). A finished heavy session — high 24h share but zero current rate — is NOT a burn and is silenced; this is the activity gate that closed the "consumed 67% of 24h spend … Projected 0 tokens" re-alarm-for-a-full-day bug. Most context-cache usage spread across many warm sessions never trips it.
436
+ - Silence or tune it in \`.instar/config.json\` → \`monitoring.burnDetection\`: \`{"enabled": false}\` is the master off-switch; \`absoluteShareThreshold\` (default 0.25), \`absoluteShareActivityFloorTokens\`, \`alertTopicId\` (where alerts post), \`autoThrottle\` / \`autoThrottleOnUnknown\` tune behaviour without code changes. Absence preserves the shipped defaults.
437
+ - Proactive: user says "these token alerts are noisy" / "why am I getting this" / "turn them off" → explain the activity gate (it only flags live burns now), and offer the \`monitoring.burnDetection.enabled: false\` off-switch (restart sessions to apply per the section below). Note that \`unknown::<id>\` just means that spend wasn't attributed to a named component — it's not inherently a problem.
438
+
432
439
  **Multi-Session Autonomy** — I can run multiple autonomous jobs at once, one per topic (default cap 5, set \`autonomousSessions.maxConcurrent\` in config). Each topic's job is isolated, survives restarts, and is keyed on its topic.
433
440
  - What's running: \`curl -H "Authorization: Bearer $AUTH" http://localhost:${port}/autonomous/sessions\`
434
441
  - The cap + budget gate is checked automatically when a job starts (\`GET /autonomous/can-start\`); a start is refused when at the cap or under budget pressure.
@@ -746,6 +753,8 @@ This returns your full capability matrix: scripts, hooks, Telegram status, jobs,
746
753
 
747
754
  Instar contributors can run \`instar dev:preflight\` before opening PRs to run lint, CapabilityIndex discoverability checks, and an advisory new-route-prefix scan against the diff.
748
755
 
756
+ Run \`instar dev:ci-failures <pr>\` to print a red PR's exact failing tests (file:line + assertion) via the GitHub check-run annotations API — handy when \`gh run view --log\` returns nothing.
757
+
749
758
  **Critical rule**: If this CLAUDE.md says a feature is "for standalone agents" or "when configured" or uses any qualifier — do NOT conclude you lack the feature. Check \`/capabilities\` instead. Documentation describes features in general; the API tells you what's actually running for YOU right now. When they conflict, the API wins.
750
759
 
751
760
  ### Registry First, Explore Second
@@ -0,0 +1,111 @@
1
+ # Upgrade Guide — vNEXT
2
+
3
+ <!-- assembled-by: assemble-next-md -->
4
+ <!-- bump: minor -->
5
+
6
+ ## What Changed
7
+
8
+ Adds `instar dev:ci-failures <pr>` — a contributor/agent dev command that prints a
9
+ PR's **exact failing tests** (`file:line` + the assertion message) by reading the
10
+ GitHub **check-run annotations API**.
11
+
12
+ **Why this exists (a real friction → infrastructure).** In some environments
13
+ `gh run view --log` / `--log-failed` return zero bytes, which makes a red CI run
14
+ undiagnosable from the terminal — you can see *that* shards failed but not *which*
15
+ test. The check-run *annotations* endpoint
16
+ (`/repos/:owner/:repo/check-runs/:id/annotations`) still returns the failing
17
+ `path:line` + assertion even when the log endpoint is empty. This command wraps
18
+ that workaround so a contributor (or an autonomous agent shepherding its own PR)
19
+ gets the precise failure instantly instead of re-discovering the trick mid-run.
20
+
21
+ **What it does:** resolves the PR's head SHA → lists its FAILED check-runs →
22
+ prints each one's test-level failure annotations, de-duplicating the identical
23
+ failure that the node-20 / node-22 shard pair both report. It drops CI-runner
24
+ noise (the `.github/...` annotations and the generic `Process completed with exit
25
+ code N`). Read-only — it only calls `gh` GET endpoints; it never mutates anything.
26
+ Exit 0 even when failures are found (it's a diagnostic, not a gate); exit 1 only on
27
+ an operational error (PR unresolvable / API failure).
28
+
29
+ Pairs with `instar dev:preflight` (#716) as the contributor dev-loop toolkit.
30
+
31
+ The `SessionReaper` gains a host-load-gated tightening of its `active-process`
32
+ keep-guard, behind a new dark-by-default flag `cpuAwareActiveProcessKeep`.
33
+
34
+ **The problem.** The reaper keeps a session whenever any non-baseline child
35
+ process *exists* (`hasActiveProcesses`). That existence check can't tell a
36
+ *working* child from a *wedged/idle* one — a hung MCP server or a stuck
37
+ `codex exec --json` job keeps a live PID while burning ~no CPU. So an otherwise
38
+ idle, reapable session is held un-reapable forever, and under host load those
39
+ zombie-child sessions are exactly what inflates CPU/memory pressure and starves
40
+ new spawns.
41
+
42
+ **The fix.** When `cpuAwareActiveProcessKeep` is on *and* the box is under CPU
43
+ pressure, the `active-process` existence-veto additionally requires *positive CPU
44
+ progress*: the reaper samples the session's accumulated descendant CPU-seconds
45
+ across ticks, and if the delta is below an idle floor (`cpuActiveMinRatePerSec`,
46
+ default 0.02 = 2% of one core), the existence-veto is relaxed. It does **not**
47
+ kill on that alone — it *falls through* to the reaper's existing stateful checks
48
+ (transcript-growth + positive-idle), all of which must still clear, plus the
49
+ hysteresis + two-phase + per-hour budget, before anything is reaped.
50
+
51
+ **Conservative by construction:**
52
+ - A strict no-op at `normal` pressure (zero behavior change off-load).
53
+ - A no-op when CPU can't be sampled, on the first sighting (no delta yet), or if
54
+ accumulated CPU went backwards (pid reuse) — all resolve to KEEP.
55
+ - It tightens **only** the reaper's own decision. The shared `ReapGuard` /
56
+ `ReapAuthority` path (the veto that protects sessions from *other* killers,
57
+ e.g. `terminateSession`) is left completely untouched — zero blast radius
58
+ there.
59
+ - Every time it relaxes the veto it writes a `cpu-keep-tightened` row to the
60
+ decision audit (`logs/reaper-audit.jsonl`) — a behavior change to a kill path
61
+ is never silent.
62
+
63
+ Ships dark fleet-wide and live on development agents (the `developmentAgent`
64
+ gate), so it's dogfooded on a real loaded box before any wider rollout.
65
+
66
+ ## What to Tell Your User
67
+
68
+ Nothing required — it's a developer/agent tool for working **on** Instar. When a PR's
69
+ CI goes red, the new developer command prints the exact failing tests instead of
70
+ an unreadable log.
71
+
72
+ Nothing — the new under-load reaper refinement is **dark by default** (off everywhere
73
+ except development agents). It changes no user-visible behavior on a normal
74
+ install. If surfaced at all, surface it as **⚗️ Experimental**: it refines the
75
+ reaper's idle-detection under load and is still being validated on dev agents.
76
+
77
+ ## Summary of New Capabilities
78
+
79
+ - `instar dev:ci-failures <pr> [--repo owner/repo]` — print a PR's exact failing tests
80
+ (file:line + assertion) via the GitHub check-run annotations API. Read-only.
81
+
82
+ - `monitoring.sessionReaper.cpuAwareActiveProcessKeep` (boolean, default false;
83
+ `developmentAgent` agents default true) — under CPU pressure, require positive
84
+ descendant-CPU progress before an existing-but-idle child process keeps a
85
+ session un-reapable.
86
+ - `monitoring.sessionReaper.cpuActiveMinRatePerSec` (number, default 0.02) — the
87
+ CPU-seconds-per-wall-second idle floor below which descendant CPU counts as
88
+ "flat".
89
+ - A `cpu-keep-tightened` decision-audit event records each veto-relaxation.
90
+
91
+ ## Evidence
92
+
93
+ - Built from a recurring mid-run friction: `gh run view --log[-failed]` returned 0 bytes
94
+ on this environment across multiple PRs (#716/#717/#718); the annotations API was the
95
+ reliable path to the failing test+line.
96
+ - Tests: `tests/unit/devCiFailures.test.ts` — the pure `extractFailureLines` (keeps real
97
+ failures; drops warnings / `.github` / `Process completed` noise; truncates long
98
+ messages) + `runDevCiFailures` with injected `gh` deps (red PR → prints the test;
99
+ shard-pair dedup; green PR → "No failed checks"; unresolvable PR → exit 1; build/lint
100
+ failure with no test annotations → a helpful note).
101
+
102
+ - Root cause grounded at `ReapGuard.ts:139` (`hasActiveProcesses` is existence,
103
+ not CPU) — the same gap the #706 `descendantCpuSeconds` helper was built to
104
+ expose for the StaleSessionBackstop; this reuses it for the reaper.
105
+ - Tests: `tests/unit/session-reaper-cpu-aware-keep.test.ts` (12 tests, both sides
106
+ of every boundary — veto relaxed only when CPU-flat under pressure + still
107
+ protected by positive-idle / transcript-growth; never relaxed off-pressure,
108
+ flag-off, dep-absent, first-sample, or CPU-rising) + a wiring-integrity
109
+ assertion in `session-reaper-wiring.test.ts` (the `descendantCpuSeconds` dep
110
+ and the `developmentAgent` gate are actually wired, not dead). The 43 existing
111
+ reaper tests stay green (no behavior change off the new path).