openloops 0.1.39 → 0.2.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.
- package/README.md +40 -4
- package/dist/clients/index.d.ts +2 -2
- package/dist/clients/index.js +4 -4
- package/dist/clients/index.mjs +2 -2
- package/dist/clients/llm/index.d.ts +1 -0
- package/dist/{loops/plan-execute → clients/llm}/index.js +4 -4
- package/dist/clients/llm/index.mjs +1 -0
- package/dist/clients/{llm-client.d.ts → llm/llm-client.d.ts} +3 -14
- package/dist/clients/{llm-client.js → llm/llm-client.js} +14 -37
- package/dist/clients/{llm-client.mjs → llm/llm-client.mjs} +15 -38
- package/dist/clients/{llm-error.mjs → llm/llm-error.mjs} +1 -1
- package/dist/clients/{llm-types.d.ts → llm/llm-types.d.ts} +1 -1
- package/dist/clients/llm/model-resolution.d.ts +20 -0
- package/dist/clients/llm/model-resolution.js +83 -0
- package/dist/clients/llm/model-resolution.mjs +46 -0
- package/dist/clients/{pi-ai-adapter.mjs → llm/pi-ai-adapter.mjs} +1 -1
- package/dist/clients/serper/index.d.ts +1 -0
- package/dist/clients/serper/index.js +22 -0
- package/dist/clients/serper/index.mjs +1 -0
- package/dist/clients/{serper-client.js → serper/serper-client.js} +2 -2
- package/dist/clients/{serper-client.mjs → serper/serper-client.mjs} +3 -3
- package/dist/harness/agent-loop.d.ts +0 -1
- package/dist/harness/agent.d.ts +6 -1
- package/dist/harness/agent.js +21 -13
- package/dist/harness/agent.mjs +21 -13
- package/dist/harness/native-tools.d.ts +1 -1
- package/dist/{loops/shared → harness}/skills/approval-request.d.ts +1 -1
- package/dist/{loops/shared → harness}/skills/approval-request.js +1 -1
- package/dist/{loops/shared → harness}/skills/approval-request.mjs +2 -2
- package/dist/{loops/shared → harness}/skills/autonomous-answer.d.ts +1 -1
- package/dist/{loops/shared → harness}/skills/autonomous-answer.js +1 -1
- package/dist/{loops/shared → harness}/skills/autonomous-answer.mjs +2 -2
- package/dist/{loops/shared → harness}/skills/confirmation-gate.d.ts +1 -1
- package/dist/{loops/shared → harness}/skills/confirmation-gate.js +1 -1
- package/dist/{loops/shared → harness}/skills/confirmation-gate.mjs +2 -2
- package/dist/harness/skills/index.d.ts +4 -0
- package/dist/{loops/plan-execute → harness}/skills/index.js +8 -8
- package/dist/harness/skills/index.mjs +4 -0
- package/dist/{loops/shared → harness}/skills/mcp-change-review.d.ts +1 -1
- package/dist/{loops/shared → harness}/skills/mcp-change-review.js +1 -1
- package/dist/{loops/shared → harness}/skills/mcp-change-review.mjs +2 -2
- package/dist/harness/tool-catalog.d.ts +1 -1
- package/dist/loops/index.d.ts +0 -1
- package/dist/loops/index.js +0 -2
- package/dist/loops/index.mjs +0 -1
- package/dist/loops/shared/skills/index.d.ts +0 -4
- package/dist/loops/shared/skills/index.js +1 -9
- package/dist/loops/shared/skills/index.mjs +0 -4
- package/dist/services/chats/entities/chat.entity.d.ts +0 -5
- package/dist/services/chats/entities/chat.entity.js +0 -10
- package/dist/services/chats/entities/chat.entity.mjs +0 -10
- package/dist/services/llmcalls/module.d.ts +4 -2
- package/dist/services/llmcalls/module.js +13 -6
- package/dist/services/llmcalls/module.mjs +11 -5
- package/dist/services/llmcalls/use-cases/get-llm-usage-by-chat.use-case.d.ts +14 -0
- package/dist/services/llmcalls/use-cases/get-llm-usage-by-chat.use-case.js +62 -0
- package/dist/services/llmcalls/use-cases/get-llm-usage-by-chat.use-case.mjs +33 -0
- package/dist/services/llmcalls/use-cases/get-llm-usage-by-message.use-case.d.ts +14 -0
- package/dist/services/llmcalls/use-cases/{get-llm-usage.use-case.js → get-llm-usage-by-message.use-case.js} +18 -37
- package/dist/services/llmcalls/use-cases/get-llm-usage-by-message.use-case.mjs +33 -0
- package/dist/services/llmcalls/utils/usage-totals.d.ts +20 -0
- package/dist/services/llmcalls/utils/usage-totals.js +31 -0
- package/dist/services/llmcalls/utils/usage-totals.mjs +29 -0
- package/dist/services/tasks/entities/agent-task.entity.d.ts +2 -24
- package/dist/services/tasks/entities/agent-task.entity.js +2 -75
- package/dist/services/tasks/entities/agent-task.entity.mjs +2 -75
- package/dist/services/users/entities/user-default-model.d.ts +11 -0
- package/dist/services/users/entities/user-default-model.js +42 -0
- package/dist/services/users/entities/user-default-model.mjs +19 -0
- package/dist/services/users/entities/user-preferences.d.ts +4 -1
- package/dist/services/users/entities/user-preferences.js +8 -3
- package/dist/services/users/entities/user-preferences.mjs +8 -3
- package/dist/services/users/use-cases/create-user.use-case.js +3 -1
- package/dist/services/users/use-cases/create-user.use-case.mjs +3 -1
- package/dist/services/users/use-cases/update-user.use-case.js +4 -1
- package/dist/services/users/use-cases/update-user.use-case.mjs +4 -1
- package/dist/services/users/utils/default-model.d.ts +6 -0
- package/dist/services/users/utils/default-model.js +38 -0
- package/dist/services/users/utils/default-model.mjs +15 -0
- package/dist/skills/call-modes.d.ts +1 -1
- package/dist/skills/skill.d.ts +1 -1
- package/dist/skills/skill.js +1 -1
- package/dist/skills/skill.mjs +1 -1
- package/dist/tools/core/web-search/web-search.tool.js +1 -1
- package/dist/tools/core/web-search/web-search.tool.mjs +1 -1
- package/docs/README.md +1 -1
- package/docs/agent.md +4 -3
- package/docs/agentic-jobs.md +1 -1
- package/docs/assets/harness-car.svg +79 -0
- package/docs/chats.md +1 -1
- package/docs/configuration.md +18 -4
- package/docs/harness.md +12 -1
- package/docs/integration-guide.md +2 -2
- package/docs/llms.txt +1 -1
- package/docs/loops.md +4 -15
- package/docs/usage.md +19 -14
- package/docs/users.md +23 -0
- package/examples/run-agent/run-agent-with-fallback-model.ts +25 -0
- package/examples/usage/get-chat-usage.ts +8 -10
- package/examples/usage/get-message-usage.ts +5 -7
- package/examples/users/set-default-model.ts +36 -0
- package/package.json +1 -4
- package/dist/loops/plan-execute/index.d.ts +0 -1
- package/dist/loops/plan-execute/index.mjs +0 -1
- package/dist/loops/plan-execute/loop.d.ts +0 -26
- package/dist/loops/plan-execute/loop.js +0 -267
- package/dist/loops/plan-execute/loop.mjs +0 -249
- package/dist/loops/plan-execute/skills/action-planner.d.ts +0 -35
- package/dist/loops/plan-execute/skills/action-planner.js +0 -71
- package/dist/loops/plan-execute/skills/action-planner.mjs +0 -48
- package/dist/loops/plan-execute/skills/final-responder.d.ts +0 -7
- package/dist/loops/plan-execute/skills/final-responder.js +0 -58
- package/dist/loops/plan-execute/skills/final-responder.mjs +0 -35
- package/dist/loops/plan-execute/skills/index.d.ts +0 -4
- package/dist/loops/plan-execute/skills/index.mjs +0 -4
- package/dist/loops/plan-execute/skills/state-observer.d.ts +0 -10
- package/dist/loops/plan-execute/skills/state-observer.js +0 -61
- package/dist/loops/plan-execute/skills/state-observer.mjs +0 -38
- package/dist/loops/plan-execute/skills/strategy-engine.d.ts +0 -11
- package/dist/loops/plan-execute/skills/strategy-engine.js +0 -61
- package/dist/loops/plan-execute/skills/strategy-engine.mjs +0 -38
- package/dist/services/llmcalls/use-cases/get-llm-usage.use-case.d.ts +0 -24
- package/dist/services/llmcalls/use-cases/get-llm-usage.use-case.mjs +0 -51
- package/dist/skills/skill-runner.d.ts +0 -30
- package/dist/skills/skill-runner.js +0 -121
- package/dist/skills/skill-runner.mjs +0 -92
- /package/dist/clients/{llm-error.d.ts → llm/llm-error.d.ts} +0 -0
- /package/dist/clients/{llm-error.js → llm/llm-error.js} +0 -0
- /package/dist/clients/{llm-types.js → llm/llm-types.js} +0 -0
- /package/dist/clients/{llm-types.mjs → llm/llm-types.mjs} +0 -0
- /package/dist/clients/{pi-ai-adapter.d.ts → llm/pi-ai-adapter.d.ts} +0 -0
- /package/dist/clients/{pi-ai-adapter.js → llm/pi-ai-adapter.js} +0 -0
- /package/dist/clients/{serper-client.d.ts → serper/serper-client.d.ts} +0 -0
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 560 310" width="560" height="310" role="img" aria-labelledby="t d">
|
|
2
|
+
<title id="t">The openloops harness</title>
|
|
3
|
+
<desc id="d">A car made of an engine (the AI model), a chassis (the harness) and a body (the loop). The body changes while the engine and the chassis stay the same: a different body, a different agent.</desc>
|
|
4
|
+
<style>
|
|
5
|
+
.mono{font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace}
|
|
6
|
+
.body,.role{opacity:0;animation:cycle 12.8s infinite both;transform-box:fill-box}
|
|
7
|
+
.b0{opacity:1}
|
|
8
|
+
@keyframes cycle{0%{opacity:0;transform:translateY(-14px)}1.5%{opacity:1;transform:translateY(0)}23.5%{opacity:1;transform:translateY(0)}25%{opacity:0;transform:translateY(-10px)}100%{opacity:0}}
|
|
9
|
+
.spin{animation:spin 1.1s linear infinite;transform-origin:0 0}
|
|
10
|
+
@keyframes spin{to{transform:rotate(360deg)}}
|
|
11
|
+
.motor{animation:motor .8s ease-in-out infinite}
|
|
12
|
+
@keyframes motor{0%,100%{opacity:1}50%{opacity:.6}}
|
|
13
|
+
.node{animation:node 1.2s ease-in-out infinite}
|
|
14
|
+
@keyframes node{0%,100%{opacity:.35}50%{opacity:1}}
|
|
15
|
+
@media (prefers-reduced-motion:reduce){.body,.role,.spin,.motor,.node{animation:none}.node{opacity:1}}
|
|
16
|
+
</style>
|
|
17
|
+
<defs><pattern id="grid" width="20" height="20" patternUnits="userSpaceOnUse"><path d="M 20 0 L 0 0 0 20" fill="none" stroke="#ffffff" stroke-opacity="0.05"/></pattern></defs>
|
|
18
|
+
<rect x="0.5" y="0.5" width="559" height="309" rx="16" fill="#0d1016" stroke="#ffffff" stroke-opacity="0.12"/>
|
|
19
|
+
<rect x="1" y="1" width="558" height="308" rx="15" fill="url(#grid)"/>
|
|
20
|
+
<line x1="30" y1="218" x2="530" y2="218" stroke="#64748b" stroke-width="1" stroke-dasharray="6 8"/>
|
|
21
|
+
<g class="body b0" style="animation-delay:0s">
|
|
22
|
+
<path d="M 90 150 L 90 128 Q 90 118 104 116 L 190 110 L 225 82 Q 232 76 244 76 L 330 76 Q 342 76 350 84 L 378 110 L 462 118 Q 478 120 478 134 L 478 150 Z" fill="#cbd5e1" fill-opacity="0.04" stroke="#cbd5e1" stroke-width="1.75" stroke-linejoin="round"/>
|
|
23
|
+
<path d="M 232 84 L 292 84 L 292 108 L 205 108 Z M 300 84 L 336 84 L 366 108 L 300 108 Z" fill="#cbd5e1" fill-opacity="0.08" stroke="#cbd5e1" stroke-width="1" stroke-linejoin="round"/>
|
|
24
|
+
<line x1="290" y1="62" x2="290" y2="72" stroke="#64748b" stroke-width="1" stroke-dasharray="3 3"/>
|
|
25
|
+
<text class="mono" x="290" y="54" text-anchor="middle" font-size="11" letter-spacing="1.2" fill="#cbd5e1">BODY<tspan fill="#94a3b8"> (</tspan><tspan fill="#f8fafc">LOOP</tspan><tspan fill="#94a3b8">)</tspan></text>
|
|
26
|
+
</g>
|
|
27
|
+
<g class="body b1" style="animation-delay:3.2s">
|
|
28
|
+
<path d="M 90 150 L 90 132 Q 90 124 102 122 L 200 116 Q 240 84 290 84 L 330 84 Q 350 86 362 104 L 372 114 L 462 124 Q 480 128 480 138 L 480 150 Z" fill="#cbd5e1" fill-opacity="0.04" stroke="#cbd5e1" stroke-width="1.75" stroke-linejoin="round"/>
|
|
29
|
+
<path d="M 232 112 Q 258 92 290 92 L 330 92 Q 342 94 350 110 Z" fill="#cbd5e1" fill-opacity="0.08" stroke="#cbd5e1" stroke-width="1" stroke-linejoin="round"/>
|
|
30
|
+
<line x1="290" y1="62" x2="290" y2="80" stroke="#64748b" stroke-width="1" stroke-dasharray="3 3"/>
|
|
31
|
+
<text class="mono" x="290" y="54" text-anchor="middle" font-size="11" letter-spacing="1.2" fill="#cbd5e1">BODY<tspan fill="#94a3b8"> (</tspan><tspan fill="#f8fafc">LOOP</tspan><tspan fill="#94a3b8">)</tspan></text>
|
|
32
|
+
</g>
|
|
33
|
+
<g class="body b2" style="animation-delay:6.4s">
|
|
34
|
+
<path d="M 90 150 L 90 100 Q 90 84 106 84 L 340 84 Q 352 84 358 96 L 380 118 L 462 124 Q 478 126 478 140 L 478 150 Z" fill="#cbd5e1" fill-opacity="0.04" stroke="#cbd5e1" stroke-width="1.75" stroke-linejoin="round"/>
|
|
35
|
+
<path d="M 110 96 L 166 96 L 166 124 L 110 124 Z M 176 96 L 232 96 L 232 124 L 176 124 Z M 242 96 L 298 96 L 298 124 L 242 124 Z M 308 96 L 342 96 L 366 118 L 308 118 Z" fill="#cbd5e1" fill-opacity="0.08" stroke="#cbd5e1" stroke-width="1" stroke-linejoin="round"/>
|
|
36
|
+
<line x1="240" y1="62" x2="240" y2="80" stroke="#64748b" stroke-width="1" stroke-dasharray="3 3"/>
|
|
37
|
+
<text class="mono" x="240" y="54" text-anchor="middle" font-size="11" letter-spacing="1.2" fill="#cbd5e1">BODY<tspan fill="#94a3b8"> (</tspan><tspan fill="#f8fafc">LOOP</tspan><tspan fill="#94a3b8">)</tspan></text>
|
|
38
|
+
</g>
|
|
39
|
+
<g class="body b3" style="animation-delay:9.6s">
|
|
40
|
+
<path d="M 290 150 L 290 100 Q 292 84 308 82 L 352 82 Q 364 82 370 92 L 384 114 L 462 120 Q 478 122 478 136 L 478 150 Z M 90 150 L 90 110 L 100 110 L 104 140 L 270 140 L 274 110 L 284 110 L 284 150 Z" fill="#cbd5e1" fill-opacity="0.04" stroke="#cbd5e1" stroke-width="1.75" stroke-linejoin="round"/>
|
|
41
|
+
<path d="M 302 92 L 348 92 L 372 114 L 302 114 Z" fill="#cbd5e1" fill-opacity="0.08" stroke="#cbd5e1" stroke-width="1" stroke-linejoin="round"/>
|
|
42
|
+
<line x1="330" y1="62" x2="330" y2="78" stroke="#64748b" stroke-width="1" stroke-dasharray="3 3"/>
|
|
43
|
+
<text class="mono" x="330" y="54" text-anchor="middle" font-size="11" letter-spacing="1.2" fill="#cbd5e1">BODY<tspan fill="#94a3b8"> (</tspan><tspan fill="#f8fafc">LOOP</tspan><tspan fill="#94a3b8">)</tspan></text>
|
|
44
|
+
</g>
|
|
45
|
+
<g>
|
|
46
|
+
<rect class="motor" x="394" y="122" width="66" height="26" rx="4" fill="#ffffff" fill-opacity="0.06" stroke="#cbd5e1" stroke-width="1.5"/>
|
|
47
|
+
<line x1="410" y1="128" x2="410" y2="142" stroke="#cbd5e1" stroke-opacity="0.45" stroke-width="3" stroke-linecap="round"/>
|
|
48
|
+
<line x1="426" y1="128" x2="426" y2="142" stroke="#cbd5e1" stroke-opacity="0.45" stroke-width="3" stroke-linecap="round"/>
|
|
49
|
+
<line x1="442" y1="128" x2="442" y2="142" stroke="#cbd5e1" stroke-opacity="0.45" stroke-width="3" stroke-linecap="round"/>
|
|
50
|
+
<line x1="427" y1="108" x2="427" y2="120" stroke="#64748b" stroke-width="1" stroke-dasharray="3 3"/>
|
|
51
|
+
<text class="mono" x="445" y="100" text-anchor="middle" font-size="11" letter-spacing="1.2" fill="#cbd5e1">ENGINE<tspan fill="#94a3b8"> (</tspan><tspan fill="#f8fafc">AI MODEL</tspan><tspan fill="#94a3b8">)</tspan></text>
|
|
52
|
+
</g>
|
|
53
|
+
<g><rect x="80" y="150" width="400" height="18" rx="9" fill="#C06CF0" fill-opacity="0.2" stroke="#C06CF0" stroke-width="2"/>
|
|
54
|
+
<circle class="node" cx="170" cy="159" r="4" fill="#C06CF0" style="animation-delay:0s"/>
|
|
55
|
+
<circle class="node" cx="235" cy="159" r="4" fill="#C06CF0" style="animation-delay:0.25s"/>
|
|
56
|
+
<circle class="node" cx="300" cy="159" r="4" fill="#C06CF0" style="animation-delay:0.5s"/>
|
|
57
|
+
<circle class="node" cx="365" cy="159" r="4" fill="#C06CF0" style="animation-delay:0.75s"/>
|
|
58
|
+
<g transform="translate(150 190)"><circle r="28" fill="#0B0E14" stroke="#cbd5e1" stroke-width="2.5"/><g class="spin">
|
|
59
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(0)"/>
|
|
60
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(72)"/>
|
|
61
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(144)"/>
|
|
62
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(216)"/>
|
|
63
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(288)"/>
|
|
64
|
+
</g><circle r="8" fill="#0B0E14" stroke="#cbd5e1" stroke-width="1.5"/></g>
|
|
65
|
+
<g transform="translate(410 190)"><circle r="28" fill="#0B0E14" stroke="#cbd5e1" stroke-width="2.5"/><g class="spin">
|
|
66
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(0)"/>
|
|
67
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(72)"/>
|
|
68
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(144)"/>
|
|
69
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(216)"/>
|
|
70
|
+
<line x1="0" y1="-8" x2="0" y2="-20" stroke="#64748b" stroke-width="2" transform="rotate(288)"/>
|
|
71
|
+
</g><circle r="8" fill="#0B0E14" stroke="#cbd5e1" stroke-width="1.5"/></g>
|
|
72
|
+
<line x1="280" y1="172" x2="280" y2="232" stroke="#64748b" stroke-width="1" stroke-dasharray="3 3"/>
|
|
73
|
+
<text class="mono" x="280" y="248" text-anchor="middle" font-size="11" letter-spacing="1.2" font-weight="700" fill="#C06CF0">CHASSIS<tspan fill="#94a3b8"> (</tspan><tspan fill="#e9d5ff">HARNESS</tspan><tspan fill="#94a3b8">)</tspan></text></g>
|
|
74
|
+
<text class="mono role b0" x="280" y="278" text-anchor="middle" font-size="13" fill="#f8fafc" style="animation-delay:0s">Personal assistant</text>
|
|
75
|
+
<text class="mono role b1" x="280" y="278" text-anchor="middle" font-size="13" fill="#f8fafc" style="animation-delay:3.2s">Analyst</text>
|
|
76
|
+
<text class="mono role b2" x="280" y="278" text-anchor="middle" font-size="13" fill="#f8fafc" style="animation-delay:6.4s">Customer support</text>
|
|
77
|
+
<text class="mono role b3" x="280" y="278" text-anchor="middle" font-size="13" fill="#f8fafc" style="animation-delay:9.6s">Programmer</text>
|
|
78
|
+
<text class="mono" x="280" y="298" text-anchor="middle" font-size="11" fill="#94a3b8">Same engine. Same chassis. A different body, a different agent.</text>
|
|
79
|
+
</svg>
|
package/docs/chats.md
CHANGED
|
@@ -11,7 +11,7 @@ import { createChat, getChatById, listChatsByUser, updateChat, deleteChat } from
|
|
|
11
11
|
| Field | Meaning |
|
|
12
12
|
| --- | --- |
|
|
13
13
|
| `state` | `status`, detected `language`, `activeTaskId`, `currentActivity`, `lastError` and `stopRequested`. See [agent](agent.md#the-result) for the statuses. |
|
|
14
|
-
| `settings` | `modelProvider
|
|
14
|
+
| `settings` | `modelProvider` and `modelName` (the model the chat uses, saved on every run), `loopName`, `executionMode`, `notifyOnCompletion` and `isPrivateSession`. |
|
|
15
15
|
| `messages` | The conversation. Each message has `role` (`user` or `assistant`), `source`, `content`, `answerId` and `excludeFromContext`. |
|
|
16
16
|
|
|
17
17
|
Every assistant message of one answer shares an `answerId`. It is the id you pass as `messageId` to [usage](usage.md).
|
package/docs/configuration.md
CHANGED
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
| `SERPER_API_KEY` | for `webSearchTool` | See [tools](tools.md#built-in-tools). |
|
|
14
14
|
| `AGENTIC_JOBS_POLL_INTERVAL_MS` | no | How often the runner of [agentic jobs](agentic-jobs.md) checks what is due, in milliseconds. Defaults to `60000`. |
|
|
15
15
|
| `AGENTIC_JOBS_LEASE_MS` | no | How long a job stays locked while it runs, in milliseconds. Defaults to `600000`. |
|
|
16
|
+
| `LLM_FALLBACK_PROVIDER`, `LLM_FALLBACK_MODEL` | no | The model to use when nothing else chooses one, for the whole deployment. Set both or neither. See [Which model a chat uses](#which-model-a-chat-uses). |
|
|
16
17
|
| `LLM_CALL_TIMEOUT_MS` | no | Longest time to wait for one attempt of a model call, in milliseconds. Defaults to `60000`. See [Timeouts](#timeouts). |
|
|
17
18
|
| `MCP_TOOL_TIMEOUT_MS` | no | Longest time to wait for a tool of an MCP server, in milliseconds. Defaults to `60000`. See [Timeouts](#timeouts). |
|
|
18
19
|
| `SENTRY_DSN` | no | Errors are reported to Sentry when set, unless `IS_LOCAL` is `true` or `NODE_ENV` is `development`. |
|
|
@@ -21,9 +22,22 @@
|
|
|
21
22
|
|
|
22
23
|
Any value can be stored encrypted by prefixing it with `ENC:`. It is decrypted with `SECRET_MANAGER_KEY` when it is read.
|
|
23
24
|
|
|
24
|
-
##
|
|
25
|
+
## Which model a chat uses
|
|
25
26
|
|
|
26
|
-
|
|
27
|
+
Every time an agent runs, the model is the first one of this list that exists:
|
|
28
|
+
|
|
29
|
+
1. **The model sent in that run** (`modelProvider` and `modelName`, always together). It is saved in the chat as the last one used.
|
|
30
|
+
2. **The model saved in the chat.** If a run does not send one, the chat keeps using the last one that was sent, even if the user changed it between runs.
|
|
31
|
+
3. **The default model of the user** (`preferences.defaultModel`, see [users](users.md#default-model)). It is used when the chat has no model yet, and it is saved in the chat.
|
|
32
|
+
4. **The `fallbackModel` of the agent** (`new Agent({ fallbackModel: { provider, model } })`).
|
|
33
|
+
5. **The fallback of the backend**: the variables `LLM_FALLBACK_PROVIDER` and `LLM_FALLBACK_MODEL`, which must be set together.
|
|
34
|
+
6. **The fallback of the client**: `anthropic` with `claude-haiku-5-5`.
|
|
35
|
+
|
|
36
|
+
The model that is chosen is always saved in the chat, so changing the preference of a user or a fallback only affects the chats that start afterwards. Calls that are not made by an agent, such as the `call_ai` tool, use the default model of the user, then the fallback of the backend, then the one of the client.
|
|
37
|
+
|
|
38
|
+
### The fallback of the client
|
|
39
|
+
|
|
40
|
+
The last fallback is `anthropic` with `claude-haiku-5-5`, so `ANTHROPIC_API_KEY` is the only model key you need to start.
|
|
27
41
|
|
|
28
42
|
It was chosen with the project's own evals (the `evals/` folder of the repository, results of 2026-10-12), in the default `plain_chat` mode and next to `gpt-6-luna`, `gpt-4o-mini` and `gemini-2.5-flash`. The skill rows use the real prompt of the reasoning engine:
|
|
29
43
|
|
|
@@ -48,7 +62,7 @@ A value that is not a positive whole number is ignored and the default is used.
|
|
|
48
62
|
|
|
49
63
|
## Choosing the model
|
|
50
64
|
|
|
51
|
-
|
|
65
|
+
Choose the model of a chat when you run it:
|
|
52
66
|
|
|
53
67
|
```typescript
|
|
54
68
|
await agent.run({
|
|
@@ -58,7 +72,7 @@ await agent.run({
|
|
|
58
72
|
})
|
|
59
73
|
```
|
|
60
74
|
|
|
61
|
-
The choice is
|
|
75
|
+
The provider and the model go together: sending only one of them is an error. The choice is saved in the chat and used for its next runs until you send another one. Set the API key variable that the provider expects.
|
|
62
76
|
|
|
63
77
|
The model call goes through a single client that retries, cancels and repeats an attempt that does not answer in time, waits when the provider asks to slow down, drops a temperature setting the model rejects and turns provider errors into messages that are safe to show to the user.
|
|
64
78
|
|
package/docs/harness.md
CHANGED
|
@@ -1,6 +1,17 @@
|
|
|
1
1
|
# The harness
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
An agent is three things: a **model** that thinks, a **harness** that gives it hands, memory and rules, and a **loop** that decides what it is for. `openloops` is the harness, and it ships a loop. You can change the model or the loop and the harness stays the same.
|
|
4
|
+
|
|
5
|
+
The harness is everything between a loop and the outside world. A loop decides what to do. The harness makes sure it is done safely, remembers it and shows the result back to the model in a form it can use. You get all of this by using [`Agent`](agent.md) with any loop.
|
|
6
|
+
|
|
7
|
+
## The parts of the harness
|
|
8
|
+
|
|
9
|
+
| Part | What it does | Where it is explained |
|
|
10
|
+
| --- | --- | --- |
|
|
11
|
+
| **Transmission** | Takes the model to the outside world: the tools, found on demand and validated before they run. | [Tool pipeline](#tool-pipeline), [native tools](#native-tools), [tool discovery](#tool-discovery), [tools](tools.md), [MCP servers](mcp-servers.md) |
|
|
12
|
+
| **Brakes** | Stops the agent when it should stop: approvals, guardrails, timeouts and limits. | [Approvals](#approvals), [limits](#limits), [guardrails](guardrails.md), [timeouts](configuration.md#timeouts) |
|
|
13
|
+
| **Logbook** | Remembers and records: the workspace, the history of every task and the usage of every call. | [Workspace](#workspace), [observability](#observability), [chats](chats.md), [usage](usage.md) |
|
|
14
|
+
| **Steering** | Decides how the agent is driven: interactive or autonomous, scheduled, and with which model. | [Autonomous runs](#autonomous-runs), [language](#language), [the Agent](agent.md), [agentic jobs](agentic-jobs.md) |
|
|
4
15
|
|
|
5
16
|
## Tool pipeline
|
|
6
17
|
|
|
@@ -4,7 +4,7 @@ This page is for whoever builds the backend that uses `openloops`, a person or a
|
|
|
4
4
|
|
|
5
5
|
## What the package is, and what it is not
|
|
6
6
|
|
|
7
|
-
`openloops`
|
|
7
|
+
`openloops` is a harness for agents, and it gives you a set of use cases that read and write MongoDB. It does **not** include an HTTP server, routes, controllers, sessions or authorization. Your backend owns those, and calls `openloops` from its own handlers.
|
|
8
8
|
|
|
9
9
|
Requirements: Node 22 or newer and a MongoDB database. Install it with `npm install openloops` or `yarn add openloops`, set the environment variables of [configuration](configuration.md), and import from the subpaths (`openloops/core`, `openloops/mcps`, and so on).
|
|
10
10
|
|
|
@@ -40,7 +40,7 @@ Also note that `getChatById` returns `{}` in `data` when the chat does not exist
|
|
|
40
40
|
| Poll the state of a chat | `getChatById({ id, select: { state: 1 } })` |
|
|
41
41
|
| Manage MCP servers | `createMcpServer`, `listMcpServersByUser`, `getMcpServerById`, `updateMcpServer`, `deleteMcpServer`, `verifyMcpServerConnection` |
|
|
42
42
|
| Approve or block an MCP server from a screen | `decideMcpServerTrust` |
|
|
43
|
-
| Usage of a chat or an answer | `
|
|
43
|
+
| Usage of a chat or of an answer | `getLLMUsageByChat`, `getLLMUsageByMessage` |
|
|
44
44
|
| Usage statistics of a user | `getLLMUsageStats` |
|
|
45
45
|
| Create the schedule of an agent | `createAgenticJob`, `updateAgenticJob`, `listAgenticJobsByUser`, `getAgenticJobById`, `deleteAgenticJob`, `previewAgenticJobRuns` |
|
|
46
46
|
| History of scheduled runs | `listAgenticJobRunsByJob`, `listAgenticJobRunsByUser` |
|
package/docs/llms.txt
CHANGED
|
@@ -11,7 +11,7 @@ Start with the integration guide, then read only the pages you need. All pages a
|
|
|
11
11
|
|
|
12
12
|
## Run an agent
|
|
13
13
|
|
|
14
|
-
- [The Agent
|
|
14
|
+
- [The Agent](agent.md): options, running a turn, statuses, confirmations, autonomous mode
|
|
15
15
|
- [Configuration](configuration.md): environment variables, default model, timeouts
|
|
16
16
|
- [Chats](chats.md): the chat record, message source, listing and deleting
|
|
17
17
|
|
package/docs/loops.md
CHANGED
|
@@ -23,8 +23,6 @@ The loop works within a budget per task (20 reasoning turns and 40 tool calls) a
|
|
|
23
23
|
const agent = new Agent({ loop: new AgiLoop() })
|
|
24
24
|
```
|
|
25
25
|
|
|
26
|
-
`PlanExecuteLoop` (`openloops/loops`) is deprecated and will be removed. Do not build on it.
|
|
27
|
-
|
|
28
26
|
## The contract
|
|
29
27
|
|
|
30
28
|
```typescript
|
|
@@ -90,7 +88,7 @@ ctx.logger
|
|
|
90
88
|
|
|
91
89
|
## `Harness`
|
|
92
90
|
|
|
93
|
-
The second argument is the
|
|
91
|
+
The second argument is the services of the [harness](harness.md) that the loop can call:
|
|
94
92
|
|
|
95
93
|
| Member | What it does |
|
|
96
94
|
| --- | --- |
|
|
@@ -104,7 +102,6 @@ The second argument is the runtime services the loop can call:
|
|
|
104
102
|
| `runAction(action, opts)` | Runs an action through the tool pipeline. |
|
|
105
103
|
| `requiresApproval(action)` | Tells whether an action needs the user's confirmation before it can run. |
|
|
106
104
|
| `requestApproval(actions, { resumeAt })` | Asks the user to confirm and resumes at `resumeAt` once they answer. |
|
|
107
|
-
| `reopenTask(taskId)` | Continues a task that was already completed. |
|
|
108
105
|
| `workspace` | Saves and reads notes and large outputs of the task. |
|
|
109
106
|
|
|
110
107
|
Always go through `runAction`. It applies validation, grounding checks, duplicate protection, output offloading and the approval rules described in [harness](harness.md#tool-pipeline). Do not call `tool.run` yourself.
|
|
@@ -132,16 +129,8 @@ const result = await mySkill.run({ ...ctx.skillParams, contextInjection: { goal:
|
|
|
132
129
|
|
|
133
130
|
Every skill run is traced automatically. See [skills](skills.md).
|
|
134
131
|
|
|
135
|
-
##
|
|
136
|
-
|
|
137
|
-
`openloops/loops` also exports the skills that every loop can reuse:
|
|
132
|
+
## The shared skill
|
|
138
133
|
|
|
139
|
-
|
|
140
|
-
| --- | --- |
|
|
141
|
-
| `fastResponder` | Answers general conversation directly or says it cannot. |
|
|
142
|
-
| `approvalRequest` | Writes the question that asks the user to confirm pending actions. |
|
|
143
|
-
| `confirmationGate` | Reads the user's answer and decides confirmed, declined or unclear. |
|
|
144
|
-
| `mcpChangeReview` | Reviews what changed in an MCP server and writes the approval question. |
|
|
145
|
-
| `autonomousAnswer` | Answers a question of the model on behalf of an absent user, only from the context of the task. |
|
|
134
|
+
`openloops/loops` exports `fastResponder`, the skill that every loop can reuse as its first step: it answers general conversation directly, or says that it cannot and the loop continues with its reasoning.
|
|
146
135
|
|
|
147
|
-
|
|
136
|
+
The approvals and the answers of autonomous runs are written by skills that belong to the harness. They are internal, and you do not need to call them: `Agent` runs them for you when you use `harness.requestApproval` and `harness.answerQuestion`.
|
package/docs/usage.md
CHANGED
|
@@ -3,46 +3,51 @@
|
|
|
3
3
|
Every LLM call `openloops` makes, including every skill run and every reasoning step, is recorded automatically with the raw response of the provider. Tokens, cache usage, reasoning tokens and cost are all read from that stored response, so nothing has to be instrumented.
|
|
4
4
|
|
|
5
5
|
```typescript
|
|
6
|
-
import {
|
|
6
|
+
import { getLLMUsageByMessage, getLLMUsageByChat, getLLMUsageStats } from 'openloops/llmcalls'
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
There are
|
|
9
|
+
There are three functions:
|
|
10
10
|
|
|
11
|
-
- `
|
|
11
|
+
- `getLLMUsageByMessage` answers how much one answer of the agent used.
|
|
12
|
+
- `getLLMUsageByChat` answers how much a whole chat used.
|
|
12
13
|
- `getLLMUsageStats` answers how much a user used in a period, by model and over time.
|
|
13
14
|
|
|
14
|
-
## Usage of one
|
|
15
|
+
## Usage of one answer and of one chat
|
|
15
16
|
|
|
16
17
|
```typescript
|
|
17
|
-
const
|
|
18
|
-
|
|
18
|
+
const answer = await getLLMUsageByMessage({
|
|
19
|
+
messageId: assistantMessageId,
|
|
19
20
|
currentUser,
|
|
20
21
|
})
|
|
21
22
|
|
|
22
|
-
const
|
|
23
|
-
|
|
23
|
+
const chat = await getLLMUsageByChat({
|
|
24
|
+
chatId,
|
|
24
25
|
currentUser,
|
|
25
26
|
})
|
|
26
27
|
```
|
|
27
28
|
|
|
28
|
-
`messageId` is the `answerId` of the assistant message
|
|
29
|
+
`messageId` is the `answerId` of the assistant message, and everything the agent spent to produce that answer is added together. Both functions only count the calls of `currentUser`, and both return the same shape:
|
|
29
30
|
|
|
30
31
|
```typescript
|
|
31
|
-
result.data
|
|
32
|
-
// {
|
|
33
|
-
|
|
34
|
-
|
|
32
|
+
result.data.summary
|
|
33
|
+
// { calls, input, output, cacheRead, cacheWrite, reasoning, totalTokens, totalCost }
|
|
34
|
+
|
|
35
|
+
result.data.models
|
|
36
|
+
// [{ provider, model, calls, input, output, cacheRead, cacheWrite, reasoning, totalTokens, totalCost }]
|
|
35
37
|
```
|
|
36
38
|
|
|
39
|
+
`summary` is the total, and `models` has one entry for every provider and model that was used, with the same fields. A chat can use several models, because the user can change it between runs, so the detail by model tells how much each one cost. The answer of one message will usually have a single model. `summary` is always the sum of `models`, and `models` is sorted by tokens, highest first.
|
|
40
|
+
|
|
37
41
|
| Field | Meaning |
|
|
38
42
|
| --- | --- |
|
|
43
|
+
| `calls` | Number of calls to the model. |
|
|
39
44
|
| `input`, `output` | Tokens sent and generated. |
|
|
40
45
|
| `cacheRead`, `cacheWrite` | Tokens read from and written to the provider's prompt cache. |
|
|
41
46
|
| `reasoning` | Reasoning tokens, when the provider reports them. They are already inside `output`, so do not add them again. |
|
|
42
47
|
| `totalTokens` | Total tokens as the provider counts them. |
|
|
43
48
|
| `totalCost` | Cost in USD. |
|
|
44
49
|
|
|
45
|
-
When there are no matching calls, every field is `
|
|
50
|
+
When there are no matching calls, `summary` has every field in `0` and `models` is empty. A call that was stored without provider or model appears as `unknown`. `messageId` and `chatId` are required, and the call fails if they are missing or are not valid ids.
|
|
46
51
|
|
|
47
52
|
## Usage statistics of a user
|
|
48
53
|
|
package/docs/users.md
CHANGED
|
@@ -65,6 +65,29 @@ const result = await updateUser({
|
|
|
65
65
|
})
|
|
66
66
|
```
|
|
67
67
|
|
|
68
|
+
## Default model
|
|
69
|
+
|
|
70
|
+
A user can have a preferred model, which is used for the chats they start when no model is chosen in the run.
|
|
71
|
+
|
|
72
|
+
```typescript
|
|
73
|
+
await updateUser({
|
|
74
|
+
id: userId,
|
|
75
|
+
payload: {
|
|
76
|
+
preferences: {
|
|
77
|
+
defaultModel: { provider: 'anthropic', model: 'claude-haiku-5-5' },
|
|
78
|
+
},
|
|
79
|
+
},
|
|
80
|
+
currentUser,
|
|
81
|
+
})
|
|
82
|
+
|
|
83
|
+
await updateUser({ id: userId, payload: { preferences: { defaultModel: null } }, currentUser })
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
- The provider and the model are required together, and the model must exist in the catalog of providers. Otherwise the call fails with an error that says why.
|
|
87
|
+
- It does not change the other preferences of the user.
|
|
88
|
+
- Sending `null` removes it.
|
|
89
|
+
- It only applies to chats that start afterwards, because every chat saves the model it uses. See [configuration](configuration.md#which-model-a-chat-uses).
|
|
90
|
+
|
|
68
91
|
## Deleting a user
|
|
69
92
|
|
|
70
93
|
```typescript
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Agent } from 'openloops/core'
|
|
2
|
+
import { Logger } from 'openloops/common'
|
|
3
|
+
import { CurrentUser } from 'openloops/base'
|
|
4
|
+
import { AgiLoop } from 'openloops/loops'
|
|
5
|
+
|
|
6
|
+
async function runAgentWithFallbackModel () {
|
|
7
|
+
const logger = new Logger()
|
|
8
|
+
const currentUser = await CurrentUser.asyncFromDB('6ab56894eb20887d1ef7942c')
|
|
9
|
+
|
|
10
|
+
if (!currentUser) throw new Error('[Demo] current user is not defined')
|
|
11
|
+
|
|
12
|
+
const agent = new Agent({
|
|
13
|
+
loop: new AgiLoop(),
|
|
14
|
+
fallbackModel: { provider: 'anthropic', model: 'claude-haiku-5-5' },
|
|
15
|
+
})
|
|
16
|
+
|
|
17
|
+
const result = await agent.run({
|
|
18
|
+
input: { message: 'hi, how are you?' },
|
|
19
|
+
currentUser,
|
|
20
|
+
})
|
|
21
|
+
|
|
22
|
+
logger.info(result.data?.settings, '[Demo] The chat saved the model that it used')
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
runAgentWithFallbackModel()
|
|
@@ -1,22 +1,20 @@
|
|
|
1
1
|
import { Logger } from 'openloops/common'
|
|
2
2
|
import { CurrentUser } from 'openloops/base'
|
|
3
|
-
import {
|
|
3
|
+
import { getLLMUsageByChat } from 'openloops/llmcalls'
|
|
4
4
|
|
|
5
|
-
async function
|
|
5
|
+
async function getChatUsage () {
|
|
6
6
|
const logger = new Logger()
|
|
7
7
|
const currentUser = await CurrentUser.asyncFromDB('6ab56894eb20887d1ef7942c')
|
|
8
8
|
|
|
9
|
-
const result = await
|
|
10
|
-
|
|
11
|
-
sessionId: '6abc454162624f9e01929cd8' // chatId
|
|
12
|
-
},
|
|
9
|
+
const result = await getLLMUsageByChat({
|
|
10
|
+
chatId: '6abc454162624f9e01929cd8',
|
|
13
11
|
currentUser,
|
|
14
12
|
})
|
|
15
13
|
|
|
16
14
|
logger.info({
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
}, '[Demo] Chat
|
|
15
|
+
summary: result.data.summary,
|
|
16
|
+
models: result.data.models,
|
|
17
|
+
}, '[Demo] Chat usage')
|
|
20
18
|
}
|
|
21
19
|
|
|
22
|
-
|
|
20
|
+
getChatUsage()
|
|
@@ -1,21 +1,19 @@
|
|
|
1
1
|
import { Logger } from 'openloops/common'
|
|
2
2
|
import { CurrentUser } from 'openloops/base'
|
|
3
|
-
import {
|
|
3
|
+
import { getLLMUsageByMessage } from 'openloops/llmcalls'
|
|
4
4
|
|
|
5
5
|
async function getMessageUsage () {
|
|
6
6
|
const logger = new Logger()
|
|
7
7
|
const currentUser = await CurrentUser.asyncFromDB('6ab56894eb20887d1ef7942c')
|
|
8
8
|
|
|
9
|
-
const result = await
|
|
10
|
-
|
|
11
|
-
messageId: '6abc454162624f9e01929cd7' // id of assistant message/answer
|
|
12
|
-
},
|
|
9
|
+
const result = await getLLMUsageByMessage({
|
|
10
|
+
messageId: '6abc454162624f9e01929cd7',
|
|
13
11
|
currentUser,
|
|
14
12
|
})
|
|
15
13
|
|
|
16
14
|
logger.info({
|
|
17
|
-
|
|
18
|
-
|
|
15
|
+
summary: result.data.summary,
|
|
16
|
+
models: result.data.models,
|
|
19
17
|
}, '[Demo] Usage for assistant answer')
|
|
20
18
|
}
|
|
21
19
|
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { Logger } from 'openloops/common'
|
|
2
|
+
import { updateUser } from 'openloops/users'
|
|
3
|
+
import { CurrentUser } from 'openloops/base'
|
|
4
|
+
|
|
5
|
+
async function setDefaultModel () {
|
|
6
|
+
const logger = new Logger()
|
|
7
|
+
const currentUser = await CurrentUser.asyncFromDB('6ab56894eb20887d1ef7942c')
|
|
8
|
+
|
|
9
|
+
const result = await updateUser({
|
|
10
|
+
id: '6ab56894eb20887d1ef7942c',
|
|
11
|
+
payload: {
|
|
12
|
+
preferences: {
|
|
13
|
+
defaultModel: { provider: 'anthropic', model: 'claude-haiku-5-5' },
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
currentUser,
|
|
17
|
+
})
|
|
18
|
+
|
|
19
|
+
logger.info(result.data.preferences?.defaultModel, '[Demo] Default model:')
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
async function removeDefaultModel () {
|
|
23
|
+
const currentUser = await CurrentUser.asyncFromDB('6ab56894eb20887d1ef7942c')
|
|
24
|
+
|
|
25
|
+
await updateUser({
|
|
26
|
+
id: '6ab56894eb20887d1ef7942c',
|
|
27
|
+
payload: {
|
|
28
|
+
preferences: { defaultModel: null as any },
|
|
29
|
+
},
|
|
30
|
+
currentUser,
|
|
31
|
+
})
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
setDefaultModel()
|
|
35
|
+
|
|
36
|
+
// removeDefaultModel()
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "openloops",
|
|
3
|
-
"version": "0.1
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"description": "Framework to build AI Agents",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Jose Barcos",
|
|
@@ -104,13 +104,10 @@
|
|
|
104
104
|
"croner": "^10.0.1",
|
|
105
105
|
"cryptr": "^6.4.0",
|
|
106
106
|
"dotenv": "^18.0.3",
|
|
107
|
-
"html-to-text": "^10.0.1",
|
|
108
107
|
"iso-data": "^0.1.0",
|
|
109
108
|
"jsonwebtoken": "^9.0.3",
|
|
110
109
|
"langfuse": "^3.39.2",
|
|
111
110
|
"mongodb": "^7.6.0",
|
|
112
|
-
"openai": "^7.23.0",
|
|
113
|
-
"p-limit": "^7.3.3",
|
|
114
111
|
"pino": "^10.3.1",
|
|
115
112
|
"pino-pretty": "^13.1.3",
|
|
116
113
|
"reflect-metadata": "^0.2.2",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './loop';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./loop";
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { AgentLoop, Harness, RunContext } from '../../harness/index.js';
|
|
2
|
-
export declare class PlanExecuteLoop extends AgentLoop {
|
|
3
|
-
get initialNode(): (ctx: RunContext, harness: Harness) => Promise<void>;
|
|
4
|
-
get nodes(): {
|
|
5
|
-
fast_responder: (ctx: RunContext, harness: Harness) => Promise<void>;
|
|
6
|
-
strategy_engine: (ctx: RunContext, harness: Harness) => Promise<void>;
|
|
7
|
-
action_planner: (ctx: RunContext, harness: Harness) => Promise<void>;
|
|
8
|
-
execution_loop: (ctx: RunContext, harness: Harness) => Promise<void>;
|
|
9
|
-
state_observer: (ctx: RunContext, harness: Harness) => Promise<void>;
|
|
10
|
-
final_responder: (ctx: RunContext, harness: Harness) => Promise<void>;
|
|
11
|
-
};
|
|
12
|
-
get name(): string;
|
|
13
|
-
get version(): string;
|
|
14
|
-
get author(): {
|
|
15
|
-
name: string;
|
|
16
|
-
email: string;
|
|
17
|
-
website: string;
|
|
18
|
-
};
|
|
19
|
-
private stopTask;
|
|
20
|
-
private fastResponder;
|
|
21
|
-
private strategyEngine;
|
|
22
|
-
private actionPlanner;
|
|
23
|
-
private executionLoop;
|
|
24
|
-
private executionObserver;
|
|
25
|
-
private finalResponder;
|
|
26
|
-
}
|