@humain/humain-code 0.3.8 → 0.4.1

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 (87) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/dist/bundle/agent-monitor.js +1 -1
  3. package/dist/bundle/chunks/bedrock-converse-stream.js +45 -39
  4. package/dist/bundle/chunks/{chunk-REZ7FW4X.js → chunk-2KKLZK2N.js} +1 -1
  5. package/dist/bundle/chunks/{chunk-3ZYKCI45.js → chunk-3ZI2TEVB.js} +1 -1
  6. package/dist/bundle/chunks/{chunk-WQN4VIAM.js → chunk-7LDXR4AN.js} +424 -378
  7. package/dist/bundle/chunks/{chunk-YEG6NREY.js → chunk-DUZY4PDA.js} +16 -16
  8. package/dist/bundle/chunks/{chunk-QJZ5QYKE.js → chunk-E22S6D55.js} +1 -1
  9. package/dist/bundle/chunks/{chunk-74L7EWMA.js → chunk-E7WGCXWK.js} +1 -1
  10. package/dist/bundle/chunks/{chunk-MNB52OYZ.js → chunk-ERT2BD7V.js} +36 -36
  11. package/dist/bundle/chunks/{chunk-2KVH67UZ.js → chunk-H5CZL7M5.js} +1 -1
  12. package/dist/bundle/chunks/{chunk-TEOX3AWC.js → chunk-ICLZNV4V.js} +2 -2
  13. package/dist/bundle/chunks/{chunk-VHVY22A2.js → chunk-JQZ7BIAI.js} +2 -13
  14. package/dist/bundle/chunks/{chunk-HL54JCNV.js → chunk-KMMH6Z2Y.js} +3 -3
  15. package/dist/bundle/chunks/{chunk-6HQRNHO7.js → chunk-N23FFKJU.js} +40 -25
  16. package/dist/bundle/chunks/{chunk-X5JUC5RE.js → chunk-OXJXKCLB.js} +1 -1
  17. package/dist/bundle/chunks/{chunk-QWB2GGVH.js → chunk-OYDXJK4L.js} +731 -736
  18. package/dist/bundle/chunks/{chunk-7CYWKPFS.js → chunk-UBQSONVR.js} +9 -8
  19. package/dist/bundle/chunks/{chunk-6MMGBL46.js → chunk-VZV7GLZT.js} +2 -2
  20. package/dist/bundle/chunks/{chunk-FF26YENK.js → chunk-W2QRCQBX.js} +4 -3
  21. package/dist/bundle/chunks/{cli-5NYUGRWC.js → cli-5YRA5PFB.js} +2 -2
  22. package/dist/bundle/chunks/{compat-UPJNJCGF.js → compat-GXD2ZGMZ.js} +1 -1
  23. package/dist/bundle/chunks/dist-IKSCGVMG.js +1953 -0
  24. package/dist/bundle/chunks/{easter-egg-3d-XUJ4HNAR.js → easter-egg-3d-ARXMB2RN.js} +1 -1
  25. package/dist/bundle/chunks/{esm-763X2IA7.js → esm-NCUV2DF7.js} +1 -1
  26. package/dist/bundle/chunks/{event-streams-4Q22QRY2.js → event-streams-CGCQQL5M.js} +1 -1
  27. package/dist/bundle/chunks/{execute-IAU7EI3P.js → execute-KEUC5IWA.js} +1 -1
  28. package/dist/bundle/chunks/{extract-QIC545HI.js → extract-WUAT5T4V.js} +4 -4
  29. package/dist/bundle/chunks/{google-generative-ai-ICWD4YIE.js → google-generative-ai-MDUVUFFQ.js} +1 -1
  30. package/dist/bundle/chunks/{google-vertex-XIACVW6H.js → google-vertex-UQGG6LEW.js} +1 -1
  31. package/dist/bundle/chunks/{host-QBIXSMNN.js → host-SPBJ4YAA.js} +1 -1
  32. package/dist/bundle/chunks/{node-W47VUEGE.js → node-XGNY74WT.js} +1 -1
  33. package/dist/bundle/chunks/{runtime-NBGMTCI6.js → runtime-HBWXEJT3.js} +1 -1
  34. package/dist/bundle/chunks/{virtual-modules-P2MH665T.js → virtual-modules-BYOLP3HY.js} +2 -2
  35. package/dist/bundle/cli-runtime.js +2 -2
  36. package/dist/bundle/flow/agents/.gitkeep +0 -0
  37. package/dist/bundle/flow/agents/orch-architect.md +33 -0
  38. package/dist/bundle/flow/agents/orch-implementation-fast.md +13 -0
  39. package/dist/bundle/flow/agents/orch-implementation-strong.md +28 -0
  40. package/dist/bundle/flow/agents/orch-qa-agent.md +29 -0
  41. package/dist/bundle/flow/agents/orch-scout.md +35 -0
  42. package/dist/bundle/flow/agents/orch-security-review.md +28 -0
  43. package/dist/bundle/flow/agents/orch-technical-lead.md +37 -0
  44. package/dist/bundle/flow/agents/orch-technical-review.md +28 -0
  45. package/dist/bundle/flow/agents/orch-worker.md +13 -0
  46. package/dist/bundle/flow/agents/orchestrator-lead.md +55 -0
  47. package/dist/bundle/flow/assets/.gitkeep +0 -0
  48. package/dist/bundle/flow/assets/contract.json +84 -0
  49. package/dist/bundle/flow/assets/forge-protocol-schema.sha256 +1 -0
  50. package/dist/bundle/flow/assets/method.json +193 -0
  51. package/dist/bundle/flow/assets/orchestrator-profiles.json +131 -0
  52. package/dist/bundle/flow/assets/profiles/anthropic.json +189 -0
  53. package/dist/bundle/flow/assets/profiles/openai.json +177 -0
  54. package/dist/bundle/flow/assets/profiles/oss-first.json +236 -0
  55. package/dist/bundle/flow/assets/profiles/premium.json +203 -0
  56. package/dist/bundle/flow/package.json +48 -0
  57. package/dist/bundle/index.js +5 -5
  58. package/dist/bundle/rpc-entry.js +2 -2
  59. package/dist/config.d.ts +12 -0
  60. package/dist/config.d.ts.map +1 -1
  61. package/dist/config.js +21 -0
  62. package/dist/config.js.map +1 -1
  63. package/dist/core/tools/subagent.d.ts +20 -0
  64. package/dist/core/tools/subagent.d.ts.map +1 -1
  65. package/dist/core/tools/subagent.js +124 -12
  66. package/dist/core/tools/subagent.js.map +1 -1
  67. package/dist/humain/flow-loader.d.ts +62 -0
  68. package/dist/humain/flow-loader.d.ts.map +1 -0
  69. package/dist/humain/flow-loader.js +291 -0
  70. package/dist/humain/flow-loader.js.map +1 -0
  71. package/dist/humain/index.d.ts.map +1 -1
  72. package/dist/humain/index.js +2 -0
  73. package/dist/humain/index.js.map +1 -1
  74. package/dist/humain/trace-capture/child-launch.d.ts +1 -0
  75. package/dist/humain/trace-capture/child-launch.d.ts.map +1 -1
  76. package/dist/humain/trace-capture/child-launch.js +2 -1
  77. package/dist/humain/trace-capture/child-launch.js.map +1 -1
  78. package/dist/modes/rpc/rpc-mode.d.ts.map +1 -1
  79. package/dist/modes/rpc/rpc-mode.js +136 -1
  80. package/dist/modes/rpc/rpc-mode.js.map +1 -1
  81. package/docs/docs.json +8 -0
  82. package/docs/environment-variables.md +1 -0
  83. package/docs/flow-profiles.md +173 -0
  84. package/docs/flow.md +112 -0
  85. package/docs/index.md +2 -0
  86. package/npm-shrinkwrap.json +6 -6
  87. package/package.json +6 -5
@@ -0,0 +1,177 @@
1
+ {
2
+ "schema": "humain-flow-profile",
3
+ "schemaVersion": 1,
4
+ "id": "openai",
5
+ "version": 1,
6
+ "digest": "7a95a6d1d7a8266bc82b6438422255433b736c3642c54abc51fc0440afd6ec3f",
7
+ "kind": "flow",
8
+ "label": "OpenAI",
9
+ "description": "OpenAI only: gpt-6-luna cheap, gpt-6.1-sol mid and premium (premium capabilities at high effort), astra frontier. Codex first, Bedrock fallback.",
10
+ "roles": {
11
+ "scout": {
12
+ "primary": {
13
+ "provider": "openai-codex",
14
+ "model": "gpt-6-luna"
15
+ },
16
+ "backups": [
17
+ {
18
+ "provider": "openai-codex",
19
+ "model": "gpt-6.1-sol"
20
+ },
21
+ {
22
+ "provider": "openai-codex",
23
+ "model": "gpt-6-astra"
24
+ }
25
+ ],
26
+ "effort": "medium"
27
+ },
28
+ "worker": {
29
+ "primary": {
30
+ "provider": "openai-codex",
31
+ "model": "gpt-6-luna"
32
+ },
33
+ "backups": [
34
+ {
35
+ "provider": "openai-codex",
36
+ "model": "gpt-6.1-sol"
37
+ },
38
+ {
39
+ "provider": "openai-codex",
40
+ "model": "gpt-6-astra"
41
+ }
42
+ ],
43
+ "effort": "medium"
44
+ },
45
+ "triage": {
46
+ "primary": {
47
+ "provider": "openai-codex",
48
+ "model": "gpt-6-luna"
49
+ },
50
+ "backups": [
51
+ {
52
+ "provider": "openai-codex",
53
+ "model": "gpt-6.1-sol"
54
+ },
55
+ {
56
+ "provider": "openai-codex",
57
+ "model": "gpt-6-astra"
58
+ }
59
+ ],
60
+ "effort": "medium"
61
+ },
62
+ "implementer": {
63
+ "primary": {
64
+ "provider": "openai-codex",
65
+ "model": "gpt-6.1-sol"
66
+ },
67
+ "backups": [
68
+ {
69
+ "provider": "openai-codex",
70
+ "model": "gpt-6-astra"
71
+ }
72
+ ],
73
+ "effort": "medium"
74
+ },
75
+ "lead": {
76
+ "primary": {
77
+ "provider": "openai-codex",
78
+ "model": "gpt-6.1-sol"
79
+ },
80
+ "backups": [
81
+ {
82
+ "provider": "openai-codex",
83
+ "model": "gpt-6-astra"
84
+ }
85
+ ],
86
+ "effort": "high"
87
+ },
88
+ "lead_large": {
89
+ "primary": {
90
+ "provider": "openai-codex",
91
+ "model": "gpt-6-astra"
92
+ },
93
+ "backups": [],
94
+ "effort": "medium"
95
+ },
96
+ "architect": {
97
+ "primary": {
98
+ "provider": "openai-codex",
99
+ "model": "gpt-6.1-sol"
100
+ },
101
+ "backups": [
102
+ {
103
+ "provider": "openai-codex",
104
+ "model": "gpt-6-astra"
105
+ }
106
+ ],
107
+ "effort": "high"
108
+ },
109
+ "reviewer": {
110
+ "primary": {
111
+ "provider": "openai-codex",
112
+ "model": "gpt-6.1-sol"
113
+ },
114
+ "backups": [
115
+ {
116
+ "provider": "openai-codex",
117
+ "model": "gpt-6-astra"
118
+ }
119
+ ],
120
+ "effort": "medium"
121
+ },
122
+ "security_reviewer": {
123
+ "primary": {
124
+ "provider": "openai-codex",
125
+ "model": "gpt-6.1-sol"
126
+ },
127
+ "backups": [
128
+ {
129
+ "provider": "openai-codex",
130
+ "model": "gpt-6-astra"
131
+ }
132
+ ],
133
+ "effort": "high"
134
+ },
135
+ "qa": {
136
+ "primary": {
137
+ "provider": "openai-codex",
138
+ "model": "gpt-6.1-sol"
139
+ },
140
+ "backups": [
141
+ {
142
+ "provider": "openai-codex",
143
+ "model": "gpt-6-astra"
144
+ }
145
+ ],
146
+ "effort": "medium"
147
+ }
148
+ },
149
+ "sizing": {
150
+ "classifierPolicyId": "unified-regex-v4",
151
+ "thresholds": {
152
+ "mediumAt": 3,
153
+ "largeAt": 8
154
+ },
155
+ "triageRole": "triage",
156
+ "maxEscalations": 1
157
+ },
158
+ "limits": {
159
+ "maxAgents": 12,
160
+ "maxConcurrent": 4,
161
+ "maxDepth": 3,
162
+ "maxRetries": 2,
163
+ "inactivityMs": 600000,
164
+ "ciWaitMs": 1800000
165
+ },
166
+ "spend": {
167
+ "runCapMicrousd": 50000000,
168
+ "warnAtPct": 80
169
+ },
170
+ "providers": {
171
+ "preference": [
172
+ "openai-codex",
173
+ "amazon-bedrock"
174
+ ]
175
+ },
176
+ "builtIn": true
177
+ }
@@ -0,0 +1,236 @@
1
+ {
2
+ "schema": "humain-flow-profile",
3
+ "schemaVersion": 1,
4
+ "id": "oss-first",
5
+ "version": 1,
6
+ "digest": "cc77fed370f78de3a1f73f6c677f42019630b2effcde68687690059d51041534",
7
+ "kind": "flow",
8
+ "label": "OSS first",
9
+ "description": "GLM 5.2 first, Kimi K3 and qualified Flash/Grok alternatives below frontier; retains guarded escalation and independent review. Grok is proprietary.",
10
+ "roles": {
11
+ "scout": {
12
+ "primary": {
13
+ "provider": "humain-node",
14
+ "model": "glm-5.2"
15
+ },
16
+ "backups": [
17
+ {
18
+ "provider": "humain-node",
19
+ "model": "kimi-k3"
20
+ },
21
+ {
22
+ "provider": "humain-node",
23
+ "model": "glm-5.3-flash"
24
+ },
25
+ {
26
+ "provider": "humain-node",
27
+ "model": "qwen3.8-flash-next"
28
+ },
29
+ {
30
+ "provider": "humain-node",
31
+ "model": "grok-4.7"
32
+ }
33
+ ],
34
+ "effort": "medium"
35
+ },
36
+ "worker": {
37
+ "primary": {
38
+ "provider": "humain-node",
39
+ "model": "glm-5.2"
40
+ },
41
+ "backups": [
42
+ {
43
+ "provider": "humain-node",
44
+ "model": "kimi-k3"
45
+ },
46
+ {
47
+ "provider": "humain-node",
48
+ "model": "glm-5.3-flash"
49
+ },
50
+ {
51
+ "provider": "humain-node",
52
+ "model": "qwen3.8-flash-next"
53
+ },
54
+ {
55
+ "provider": "humain-node",
56
+ "model": "grok-4.7"
57
+ }
58
+ ],
59
+ "effort": "medium"
60
+ },
61
+ "triage": {
62
+ "primary": {
63
+ "provider": "humain-node",
64
+ "model": "glm-5.2"
65
+ },
66
+ "backups": [
67
+ {
68
+ "provider": "humain-node",
69
+ "model": "kimi-k3"
70
+ },
71
+ {
72
+ "provider": "humain-node",
73
+ "model": "glm-5.3-flash"
74
+ },
75
+ {
76
+ "provider": "humain-node",
77
+ "model": "qwen3.8-flash-next"
78
+ },
79
+ {
80
+ "provider": "humain-node",
81
+ "model": "grok-4.7"
82
+ }
83
+ ],
84
+ "effort": "medium"
85
+ },
86
+ "implementer": {
87
+ "primary": {
88
+ "provider": "humain-node",
89
+ "model": "glm-5.2"
90
+ },
91
+ "backups": [
92
+ {
93
+ "provider": "humain-node",
94
+ "model": "kimi-k3"
95
+ },
96
+ {
97
+ "provider": "humain-node",
98
+ "model": "glm-5.3-flash"
99
+ },
100
+ {
101
+ "provider": "humain-node",
102
+ "model": "grok-4.7"
103
+ }
104
+ ],
105
+ "effort": "medium"
106
+ },
107
+ "lead": {
108
+ "primary": {
109
+ "provider": "humain-node",
110
+ "model": "glm-5.2"
111
+ },
112
+ "backups": [
113
+ {
114
+ "provider": "humain-node",
115
+ "model": "kimi-k3"
116
+ },
117
+ {
118
+ "provider": "humain-node",
119
+ "model": "grok-4.7"
120
+ }
121
+ ],
122
+ "effort": "medium"
123
+ },
124
+ "lead_large": {
125
+ "primary": {
126
+ "provider": "humain-node",
127
+ "model": "glm-5.2"
128
+ },
129
+ "backups": [],
130
+ "effort": "medium"
131
+ },
132
+ "architect": {
133
+ "primary": {
134
+ "provider": "humain-node",
135
+ "model": "glm-5.2"
136
+ },
137
+ "backups": [
138
+ {
139
+ "provider": "humain-node",
140
+ "model": "kimi-k3"
141
+ },
142
+ {
143
+ "provider": "humain-node",
144
+ "model": "grok-4.7"
145
+ }
146
+ ],
147
+ "effort": "medium"
148
+ },
149
+ "reviewer": {
150
+ "primary": {
151
+ "provider": "humain-node",
152
+ "model": "glm-5.2"
153
+ },
154
+ "backups": [
155
+ {
156
+ "provider": "humain-node",
157
+ "model": "kimi-k3"
158
+ },
159
+ {
160
+ "provider": "humain-node",
161
+ "model": "glm-5.3-flash"
162
+ },
163
+ {
164
+ "provider": "humain-node",
165
+ "model": "grok-4.7"
166
+ }
167
+ ],
168
+ "effort": "medium"
169
+ },
170
+ "security_reviewer": {
171
+ "primary": {
172
+ "provider": "humain-node",
173
+ "model": "glm-5.2"
174
+ },
175
+ "backups": [
176
+ {
177
+ "provider": "humain-node",
178
+ "model": "kimi-k3"
179
+ },
180
+ {
181
+ "provider": "humain-node",
182
+ "model": "grok-4.7"
183
+ }
184
+ ],
185
+ "effort": "medium"
186
+ },
187
+ "qa": {
188
+ "primary": {
189
+ "provider": "humain-node",
190
+ "model": "glm-5.2"
191
+ },
192
+ "backups": [
193
+ {
194
+ "provider": "humain-node",
195
+ "model": "kimi-k3"
196
+ },
197
+ {
198
+ "provider": "humain-node",
199
+ "model": "glm-5.3-flash"
200
+ },
201
+ {
202
+ "provider": "humain-node",
203
+ "model": "grok-4.7"
204
+ }
205
+ ],
206
+ "effort": "medium"
207
+ }
208
+ },
209
+ "sizing": {
210
+ "classifierPolicyId": "unified-regex-v4",
211
+ "thresholds": {
212
+ "mediumAt": 3,
213
+ "largeAt": 8
214
+ },
215
+ "triageRole": "triage",
216
+ "maxEscalations": 1
217
+ },
218
+ "limits": {
219
+ "maxAgents": 12,
220
+ "maxConcurrent": 4,
221
+ "maxDepth": 3,
222
+ "maxRetries": 2,
223
+ "inactivityMs": 600000,
224
+ "ciWaitMs": 1800000
225
+ },
226
+ "spend": {
227
+ "runCapMicrousd": 50000000,
228
+ "warnAtPct": 80
229
+ },
230
+ "providers": {
231
+ "preference": [
232
+ "humain-node"
233
+ ]
234
+ },
235
+ "builtIn": true
236
+ }
@@ -0,0 +1,203 @@
1
+ {
2
+ "schema": "humain-flow-profile",
3
+ "schemaVersion": 1,
4
+ "id": "premium",
5
+ "version": 1,
6
+ "digest": "fe2ec06366a216fb502234edacf7a05abc3a7aaa6dbe3aa445f7729b6e58d567",
7
+ "kind": "flow",
8
+ "label": "Premium",
9
+ "description": "Mixed vendor (default): gpt-6-luna scouts/workers, gpt-6.1-sol standard lead and reviews, Anthropic opus-5-5 large lead and architect, astra security review, Anthropic sonnet-5-5 QA, Anthropic fable-5-1 frontier.",
10
+ "roles": {
11
+ "scout": {
12
+ "primary": {
13
+ "provider": "openai-codex",
14
+ "model": "gpt-6-luna"
15
+ },
16
+ "backups": [
17
+ {
18
+ "provider": "humain-node",
19
+ "model": "qwen3.8-27b"
20
+ },
21
+ {
22
+ "provider": "openai-codex",
23
+ "model": "gpt-6.1-sol"
24
+ }
25
+ ],
26
+ "effort": "medium"
27
+ },
28
+ "worker": {
29
+ "primary": {
30
+ "provider": "openai-codex",
31
+ "model": "gpt-6-luna"
32
+ },
33
+ "backups": [
34
+ {
35
+ "provider": "humain-node",
36
+ "model": "qwen3.8-27b"
37
+ },
38
+ {
39
+ "provider": "openai-codex",
40
+ "model": "gpt-6.1-sol"
41
+ }
42
+ ],
43
+ "effort": "medium"
44
+ },
45
+ "triage": {
46
+ "primary": {
47
+ "provider": "openai-codex",
48
+ "model": "gpt-6-luna"
49
+ },
50
+ "backups": [
51
+ {
52
+ "provider": "humain-node",
53
+ "model": "qwen3.8-27b"
54
+ },
55
+ {
56
+ "provider": "openai-codex",
57
+ "model": "gpt-6.1-sol"
58
+ }
59
+ ],
60
+ "effort": "medium"
61
+ },
62
+ "implementer": {
63
+ "primary": {
64
+ "provider": "openai-codex",
65
+ "model": "gpt-6.1-sol"
66
+ },
67
+ "backups": [
68
+ {
69
+ "provider": "anthropic",
70
+ "model": "claude-opus-5-5"
71
+ }
72
+ ],
73
+ "effort": "medium"
74
+ },
75
+ "lead": {
76
+ "primary": {
77
+ "provider": "openai-codex",
78
+ "model": "gpt-6.1-sol"
79
+ },
80
+ "backups": [
81
+ {
82
+ "provider": "anthropic",
83
+ "model": "claude-fable-5-1"
84
+ },
85
+ {
86
+ "provider": "anthropic",
87
+ "model": "claude-opus-5-5"
88
+ }
89
+ ],
90
+ "effort": "medium"
91
+ },
92
+ "lead_large": {
93
+ "primary": {
94
+ "provider": "anthropic",
95
+ "model": "claude-opus-5-5"
96
+ },
97
+ "backups": [
98
+ {
99
+ "provider": "anthropic",
100
+ "model": "claude-fable-5-1"
101
+ }
102
+ ],
103
+ "effort": "medium"
104
+ },
105
+ "architect": {
106
+ "primary": {
107
+ "provider": "anthropic",
108
+ "model": "claude-opus-5-5"
109
+ },
110
+ "backups": [
111
+ {
112
+ "provider": "anthropic",
113
+ "model": "claude-fable-5-1"
114
+ },
115
+ {
116
+ "provider": "openai-codex",
117
+ "model": "gpt-6.1-sol"
118
+ }
119
+ ],
120
+ "effort": "medium"
121
+ },
122
+ "reviewer": {
123
+ "primary": {
124
+ "provider": "openai-codex",
125
+ "model": "gpt-6.1-sol"
126
+ },
127
+ "backups": [
128
+ {
129
+ "provider": "anthropic",
130
+ "model": "claude-sonnet-5"
131
+ },
132
+ {
133
+ "provider": "anthropic",
134
+ "model": "claude-opus-5-5"
135
+ }
136
+ ],
137
+ "effort": "medium"
138
+ },
139
+ "security_reviewer": {
140
+ "primary": {
141
+ "provider": "openai-codex",
142
+ "model": "gpt-6-astra"
143
+ },
144
+ "backups": [
145
+ {
146
+ "provider": "anthropic",
147
+ "model": "claude-fable-5-1"
148
+ },
149
+ {
150
+ "provider": "openai-codex",
151
+ "model": "gpt-6.1-sol"
152
+ }
153
+ ],
154
+ "effort": "medium"
155
+ },
156
+ "qa": {
157
+ "primary": {
158
+ "provider": "anthropic",
159
+ "model": "claude-sonnet-5-5"
160
+ },
161
+ "backups": [
162
+ {
163
+ "provider": "openai-codex",
164
+ "model": "gpt-6.1-sol"
165
+ },
166
+ {
167
+ "provider": "anthropic",
168
+ "model": "claude-opus-5-5"
169
+ }
170
+ ],
171
+ "effort": "medium"
172
+ }
173
+ },
174
+ "sizing": {
175
+ "classifierPolicyId": "unified-regex-v4",
176
+ "thresholds": {
177
+ "mediumAt": 3,
178
+ "largeAt": 8
179
+ },
180
+ "triageRole": "triage",
181
+ "maxEscalations": 1
182
+ },
183
+ "limits": {
184
+ "maxAgents": 12,
185
+ "maxConcurrent": 4,
186
+ "maxDepth": 3,
187
+ "maxRetries": 2,
188
+ "inactivityMs": 600000,
189
+ "ciWaitMs": 1800000
190
+ },
191
+ "spend": {
192
+ "runCapMicrousd": 50000000,
193
+ "warnAtPct": 80
194
+ },
195
+ "providers": {
196
+ "preference": [
197
+ "openai-codex",
198
+ "anthropic",
199
+ "amazon-bedrock"
200
+ ]
201
+ },
202
+ "builtIn": true
203
+ }
@@ -0,0 +1,48 @@
1
+ {
2
+ "name": "@humain/flow",
3
+ "version": "0.4.0-flow.0",
4
+ "private": true,
5
+ "description": "HUMAIN Flow orchestration runtime",
6
+ "type": "module",
7
+ "main": "./dist/index.js",
8
+ "types": "./dist/index.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "types": "./dist/index.d.ts",
12
+ "import": "./dist/index.js"
13
+ },
14
+ "./extension": {
15
+ "types": "./dist/extension.d.ts",
16
+ "import": "./dist/extension.js"
17
+ }
18
+ },
19
+ "files": [
20
+ "dist",
21
+ "agents",
22
+ "assets"
23
+ ],
24
+ "scripts": {
25
+ "clean": "shx rm -rf dist",
26
+ "build": "tsc -p tsconfig.build.json",
27
+ "test": "vitest --run"
28
+ },
29
+ "dependencies": {
30
+ "@earendil-works/pi-tui": "1.1.0",
31
+ "@humain/humain-code-contracts": "0.4.1",
32
+ "typebox": "1.3.35"
33
+ },
34
+ "devDependencies": {
35
+ "shx": "0.4.0",
36
+ "vitest": "5.0.3"
37
+ },
38
+ "author": "HUMAIN",
39
+ "license": "MIT",
40
+ "repository": {
41
+ "type": "git",
42
+ "url": "git+https://gitlab.humain.com/humain/data-and-ai-modeling/standard/agentic/humain-terminal.git",
43
+ "directory": "packages/flow"
44
+ },
45
+ "engines": {
46
+ "node": ">=22.22.2"
47
+ }
48
+ }
@@ -1,13 +1,13 @@
1
1
  import { createRequire as __piCreateRequire } from "node:module"; const require = __piCreateRequire(import.meta.url);
2
- import{ShowImagesSelectorComponent,ThemeSelectorComponent}from"./chunks/chunk-HL54JCNV.js";import{ACCOUNT_RETURN_COOLDOWN_MS,ACCOUNT_RETURN_MAX_COOLDOWN_MS,AgentExecInputError,AgentSession,AgentSessionRuntime,AssistantMessageComponent,BashExecutionComponent,BorderedLoader,BranchSummaryMessageComponent,CompactionSummaryMessageComponent,CredentialSynchronizationError,CustomEditor,CustomMessageComponent,DEFAULT_COMPACTION_SETTINGS,DefaultPackageManager,DefaultResourceLoader,DynamicBorder,ExtensionEditorComponent,
2
+ import{ShowImagesSelectorComponent,ThemeSelectorComponent}from"./chunks/chunk-KMMH6Z2Y.js";import{ACCOUNT_RETURN_COOLDOWN_MS,ACCOUNT_RETURN_MAX_COOLDOWN_MS,AgentExecInputError,AgentSession,AgentSessionRuntime,AssistantMessageComponent,BashExecutionComponent,BorderedLoader,BranchSummaryMessageComponent,CompactionSummaryMessageComponent,CredentialSynchronizationError,CustomEditor,CustomMessageComponent,DEFAULT_COMPACTION_SETTINGS,DefaultPackageManager,DefaultResourceLoader,DynamicBorder,ExtensionEditorComponent,
3
3
  ExtensionInputComponent,ExtensionRunner,ExtensionSelectorComponent,FooterComponent,InteractiveMode,LoginDialogComponent,ModelRegistry,ModelRuntime,ModelSelectorComponent,OAuthAccountPool,OAuthSelectorComponent,RpcClient,SessionSelectorComponent,SettingsManager,SettingsSelectorComponent,SkillInvocationMessageComponent,ThinkingSelectorComponent,ToolExecutionComponent,TreeSelectorComponent,UserMessageComponent,UserMessageSelectorComponent,VIRTUAL_MODEL_STATE_ENTRY,calculateContextTokens,collectEntriesForBranchSummary,
4
4
  compact,convertToPng,copyToClipboard,createAgentSession,createAgentSessionFromServices,createAgentSessionRuntime,createAgentSessionServices,createBashTool,createBashToolDefinition,createCodemodeExtension,createCodingTools,createEditTool,createEditToolDefinition,createEventBus,createExtensionRuntime,createFindTool,createFindToolDefinition,createGrepTool,createGrepToolDefinition,createLocalBashOperations,createLocalPowerShellOperations,createLsTool,createLsToolDefinition,createMcpExtension,createPiAgentExecutionHost,
5
5
  createPowerShellTool,createPowerShellToolDefinition,createReadOnlyTools,createReadTool,createReadToolDefinition,createSubagentTool,createSyntheticSourceInfo,createToolSearchExtension,createWriteTool,createWriteToolDefinition,defineTool,detectSupportedImageMimeTypeFromFile,discoverAgents,discoverAndLoadExtensions,estimateTokens,executeHumainAgentRequest,findCutPoint,findTurnStartIndex,formatSkillsForPrompt,generateBranchSummary,generateDiffString,generateSummary,generateSummaryWithUsage,generateUnifiedPatch,
6
6
  getFlowChildLaunchHost,getFlowControlHost,getFlowTraceProducer,getLastAssistantUsage,isBashToolResult,isEditToolResult,isFindToolResult,isGrepToolResult,isLsToolResult,isPowerShellToolResult,isReadToolResult,isToolCallEventType,isWriteToolResult,loadProjectContextFiles,loadSkills,loadSkillsFromDir,main,parseArgs,parseFrontmatter,parseSkillBlock,prepareBranchEntries,prepareChildLaunch,renderDiff,renderTaskWithContext,resolveCliModel,resolveModelScopeWithDiagnostics,runAgentExecMode,runPrintMode,runRpcMode,
7
- serializeConversation,shouldCompact,stripFrontmatter,withFileMutationQueue,wrapRegisteredTool,wrapRegisteredTools}from"./chunks/chunk-WQN4VIAM.js";import"./chunks/chunk-3ZYKCI45.js";import{ProjectTrustStore,hasTrustRequiringProjectResources}from"./chunks/chunk-2KVH67UZ.js";import"./chunks/chunk-7CYWKPFS.js";import{CURRENT_SESSION_VERSION,SessionManager,buildContextEntries,buildSessionContext,buildSessionProjection,convertToLlm,formatDimensionNote,getLatestCompactionEntry,migrateSessionEntries,parseSessionEntries,
8
- resizeImage,sessionEntryToContextMessages}from"./chunks/chunk-REZ7FW4X.js";import"./chunks/chunk-QWB2GGVH.js";import"./chunks/chunk-6MMGBL46.js";import{readStoredCredential}from"./chunks/chunk-VHVY22A2.js";import{DEFAULT_MAX_BYTES,DEFAULT_MAX_LINES,formatSize,getPowerShellConfig,getShellConfig,truncateHead,truncateLine,truncateTail,truncateToVisualLines}from"./chunks/chunk-X5JUC5RE.js";import{ArminComponent}from"./chunks/chunk-74L7EWMA.js";import{Theme,getLanguageFromPath,getMarkdownTheme,getSelectListTheme,
9
- getSettingsListTheme,highlightCode,initTheme,keyHint,keyText,rawKeyHint}from"./chunks/chunk-TEOX3AWC.js";import"./chunks/chunk-SCIGZFN5.js";import"./chunks/chunk-KQM7ZGL6.js";import"./chunks/chunk-CIA6V3BP.js";import"./chunks/chunk-XQZG5HPT.js";import"./chunks/chunk-FACBDLFU.js";import{HUMAIN_AGENT_EXECUTION_FAILURE_CODES,HUMAIN_AGENT_EXECUTION_SCHEMA_VERSION,HumainAgentArtifactSchema,HumainAgentExecutionClaimSchema,HumainAgentExecutionControlsSchema,HumainAgentExecutionOutcomeSchema,HumainAgentExecutionRequestSchema,
10
- HumainAgentExecutionResponseSchema,HumainAgentRouteRefSchema,HumainAgentUsageSchema,parseHumainAgentExecutionRequest,parseHumainAgentExecutionResponse}from"./chunks/chunk-6HQRNHO7.js";import{CONFIG_DIR_NAME,UPSTREAM_PI_VERSION,VERSION,getAgentDir,getDocsPath,getExamplesPath,getPackageDir,getReadmePath}from"./chunks/chunk-YEG6NREY.js";import"./chunks/chunk-BRXQUQSC.js";import"./chunks/chunk-PEZZKT73.js";import"./chunks/chunk-DBL35X7L.js";import"./chunks/chunk-4X774RBJ.js";import"./chunks/chunk-RTFCP3VQ.js";
7
+ serializeConversation,shouldCompact,stripFrontmatter,withFileMutationQueue,wrapRegisteredTool,wrapRegisteredTools}from"./chunks/chunk-7LDXR4AN.js";import"./chunks/chunk-3ZI2TEVB.js";import{ProjectTrustStore,hasTrustRequiringProjectResources}from"./chunks/chunk-H5CZL7M5.js";import"./chunks/chunk-UBQSONVR.js";import{CURRENT_SESSION_VERSION,SessionManager,buildContextEntries,buildSessionContext,buildSessionProjection,convertToLlm,formatDimensionNote,getLatestCompactionEntry,migrateSessionEntries,parseSessionEntries,
8
+ resizeImage,sessionEntryToContextMessages}from"./chunks/chunk-2KKLZK2N.js";import"./chunks/chunk-OYDXJK4L.js";import"./chunks/chunk-VZV7GLZT.js";import{readStoredCredential}from"./chunks/chunk-JQZ7BIAI.js";import{DEFAULT_MAX_BYTES,DEFAULT_MAX_LINES,formatSize,getPowerShellConfig,getShellConfig,truncateHead,truncateLine,truncateTail,truncateToVisualLines}from"./chunks/chunk-OXJXKCLB.js";import{ArminComponent}from"./chunks/chunk-E7WGCXWK.js";import{Theme,getLanguageFromPath,getMarkdownTheme,getSelectListTheme,
9
+ getSettingsListTheme,highlightCode,initTheme,keyHint,keyText,rawKeyHint}from"./chunks/chunk-ICLZNV4V.js";import"./chunks/chunk-SCIGZFN5.js";import"./chunks/chunk-KQM7ZGL6.js";import"./chunks/chunk-CIA6V3BP.js";import"./chunks/chunk-XQZG5HPT.js";import"./chunks/chunk-FACBDLFU.js";import{HUMAIN_AGENT_EXECUTION_FAILURE_CODES,HUMAIN_AGENT_EXECUTION_SCHEMA_VERSION,HumainAgentArtifactSchema,HumainAgentExecutionClaimSchema,HumainAgentExecutionControlsSchema,HumainAgentExecutionOutcomeSchema,HumainAgentExecutionRequestSchema,
10
+ HumainAgentExecutionResponseSchema,HumainAgentRouteRefSchema,HumainAgentUsageSchema,parseHumainAgentExecutionRequest,parseHumainAgentExecutionResponse}from"./chunks/chunk-N23FFKJU.js";import{CONFIG_DIR_NAME,UPSTREAM_PI_VERSION,VERSION,getAgentDir,getDocsPath,getExamplesPath,getPackageDir,getReadmePath}from"./chunks/chunk-DUZY4PDA.js";import"./chunks/chunk-BRXQUQSC.js";import"./chunks/chunk-PEZZKT73.js";import"./chunks/chunk-DBL35X7L.js";import"./chunks/chunk-4X774RBJ.js";import"./chunks/chunk-RTFCP3VQ.js";
11
11
  import"./chunks/chunk-YURQPD6Y.js";import"./chunks/chunk-AKA7HNO3.js";import"./chunks/chunk-QMUIATLD.js";import"./chunks/chunk-BHM75BJJ.js";import"./chunks/chunk-JXWJOIH4.js";export{ACCOUNT_RETURN_COOLDOWN_MS,ACCOUNT_RETURN_MAX_COOLDOWN_MS,AgentExecInputError,AgentSession,AgentSessionRuntime,ArminComponent,AssistantMessageComponent,BashExecutionComponent,BorderedLoader,BranchSummaryMessageComponent,CONFIG_DIR_NAME,CURRENT_SESSION_VERSION,CompactionSummaryMessageComponent,CredentialSynchronizationError,CustomEditor,CustomMessageComponent,DEFAULT_COMPACTION_SETTINGS,DEFAULT_MAX_BYTES,DEFAULT_MAX_LINES,DefaultPackageManager,DefaultResourceLoader,DynamicBorder,ExtensionEditorComponent,
12
12
  ExtensionInputComponent,ExtensionRunner,ExtensionSelectorComponent,FooterComponent,HUMAIN_AGENT_EXECUTION_FAILURE_CODES,HUMAIN_AGENT_EXECUTION_SCHEMA_VERSION,HumainAgentArtifactSchema,HumainAgentExecutionClaimSchema,HumainAgentExecutionControlsSchema,HumainAgentExecutionOutcomeSchema,HumainAgentExecutionRequestSchema,HumainAgentExecutionResponseSchema,HumainAgentRouteRefSchema,HumainAgentUsageSchema,InteractiveMode,LoginDialogComponent,ModelRegistry,ModelRuntime,ModelSelectorComponent,OAuthAccountPool,
13
13
  OAuthSelectorComponent,ProjectTrustStore,RpcClient,SessionManager,SessionSelectorComponent,SettingsManager,SettingsSelectorComponent,ShowImagesSelectorComponent,SkillInvocationMessageComponent,Theme,ThemeSelectorComponent,ThinkingSelectorComponent,ToolExecutionComponent,TreeSelectorComponent,UPSTREAM_PI_VERSION,UserMessageComponent,UserMessageSelectorComponent,VERSION,VIRTUAL_MODEL_STATE_ENTRY,buildContextEntries,buildSessionContext,buildSessionProjection,calculateContextTokens,collectEntriesForBranchSummary,