@botpress/adk 1.19.0-beta.7 → 2.0.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (233) hide show
  1. package/dist/agent-init/agent-project-generator.d.ts +5 -1
  2. package/dist/agent-init/agent-project-generator.d.ts.map +1 -1
  3. package/dist/agent-project/agent-project.d.ts +3 -3
  4. package/dist/agent-project/agent-project.d.ts.map +1 -1
  5. package/dist/agent-project/agent-resolver.d.ts.map +1 -1
  6. package/dist/agent-project/config-writer.d.ts +1 -1
  7. package/dist/agent-project/config-writer.d.ts.map +1 -1
  8. package/dist/agent-project/dependencies-parser.d.ts.map +1 -1
  9. package/dist/agent-project/dependency-state-to-dependencies.d.ts +11 -0
  10. package/dist/agent-project/dependency-state-to-dependencies.d.ts.map +1 -0
  11. package/dist/agent-project/file-watcher.d.ts.map +1 -1
  12. package/dist/agent-project/types.d.ts +9 -4
  13. package/dist/agent-project/types.d.ts.map +1 -1
  14. package/dist/agent0/capabilities/commands/adk-build.md +6 -5
  15. package/dist/agent0/capabilities/commands/adk-debug.md +1 -1
  16. package/dist/agent0/capabilities/commands/adk-dev-console.md +1 -1
  17. package/dist/agent0/capabilities/commands/adk-document.md +10 -2
  18. package/dist/agent0/capabilities/commands/adk-eval.md +1 -1
  19. package/dist/agent0/capabilities/commands/adk-explain.md +2 -2
  20. package/dist/agent0/capabilities/commands/adk-init.md +2 -2
  21. package/dist/agent0/capabilities/commands/adk-ship.md +1 -1
  22. package/dist/agent0/capabilities/commands/adk-test.md +3 -3
  23. package/dist/agent0/capabilities/commands/adk-validate.md +3 -3
  24. package/dist/agent0/capabilities/skills/adk/SKILL.md +21 -21
  25. package/dist/agent0/capabilities/skills/adk/references/actions.md +245 -239
  26. package/dist/agent0/capabilities/skills/adk/references/advanced-patterns.md +185 -218
  27. package/dist/agent0/capabilities/skills/adk/references/agent-config.md +74 -71
  28. package/dist/agent0/capabilities/skills/adk/references/assets.md +45 -48
  29. package/dist/agent0/capabilities/skills/adk/references/autonomous-execution.md +40 -46
  30. package/dist/agent0/capabilities/skills/adk/references/cli.md +17 -7
  31. package/dist/agent0/capabilities/skills/adk/references/context-api.md +98 -94
  32. package/dist/agent0/capabilities/skills/adk/references/conversation-lifecycle.md +65 -62
  33. package/dist/agent0/capabilities/skills/adk/references/conversations.md +395 -385
  34. package/dist/agent0/capabilities/skills/adk/references/custom-components.md +1 -1
  35. package/dist/agent0/capabilities/skills/adk/references/desk.md +236 -234
  36. package/dist/agent0/capabilities/skills/adk/references/explain-config.md +54 -37
  37. package/dist/agent0/capabilities/skills/adk/references/files.md +301 -306
  38. package/dist/agent0/capabilities/skills/adk/references/integration-actions.md +211 -214
  39. package/dist/agent0/capabilities/skills/adk/references/integrations.md +33 -31
  40. package/dist/agent0/capabilities/skills/adk/references/interfaces.md +13 -12
  41. package/dist/agent0/capabilities/skills/adk/references/knowledge-bases.md +98 -111
  42. package/dist/agent0/capabilities/skills/adk/references/mcp-server.md +6 -0
  43. package/dist/agent0/capabilities/skills/adk/references/messages.md +280 -256
  44. package/dist/agent0/capabilities/skills/adk/references/model-configuration.md +52 -49
  45. package/dist/agent0/capabilities/skills/adk/references/patterns-mistakes.md +102 -101
  46. package/dist/agent0/capabilities/skills/adk/references/plugins.md +15 -15
  47. package/dist/agent0/capabilities/skills/adk/references/tables.md +204 -210
  48. package/dist/agent0/capabilities/skills/adk/references/tags.md +141 -143
  49. package/dist/agent0/capabilities/skills/adk/references/tools.md +191 -199
  50. package/dist/agent0/capabilities/skills/adk/references/triggers.md +331 -336
  51. package/dist/agent0/capabilities/skills/adk/references/workflow-steps.md +132 -96
  52. package/dist/agent0/capabilities/skills/adk/references/workflows.md +479 -464
  53. package/dist/agent0/capabilities/skills/adk/references/zai-agent-reference.md +127 -129
  54. package/dist/agent0/capabilities/skills/adk/references/zai-complete-guide.md +255 -276
  55. package/dist/agent0/capabilities/skills/adk-debugger/SKILL.md +21 -17
  56. package/dist/agent0/capabilities/skills/adk-debugger/references/common-failures.md +25 -25
  57. package/dist/agent0/capabilities/skills/adk-debugger/references/conversation-analysis.md +49 -41
  58. package/dist/agent0/capabilities/skills/adk-debugger/references/debug-workflow.md +20 -14
  59. package/dist/agent0/capabilities/skills/adk-debugger/references/llm-debugging.md +13 -13
  60. package/dist/agent0/capabilities/skills/adk-debugger/references/trace-summarization.md +18 -18
  61. package/dist/agent0/capabilities/skills/adk-debugger/references/traces-and-logs.md +67 -67
  62. package/dist/agent0/capabilities/skills/adk-dev-console/SKILL.md +36 -36
  63. package/dist/agent0/capabilities/skills/adk-dev-console/references/agent-steps.md +14 -6
  64. package/dist/agent0/capabilities/skills/adk-dev-console/references/multi-agent-dashboard.md +13 -13
  65. package/dist/agent0/capabilities/skills/adk-dev-console/references/pages.md +18 -0
  66. package/dist/agent0/capabilities/skills/adk-docs/SKILL.md +13 -13
  67. package/dist/agent0/capabilities/skills/adk-docs/references/doc-standards.md +15 -0
  68. package/dist/agent0/capabilities/skills/adk-evals/SKILL.md +29 -23
  69. package/dist/agent0/capabilities/skills/adk-evals/references/eval-format.md +31 -23
  70. package/dist/agent0/capabilities/skills/adk-evals/references/test-patterns.md +25 -36
  71. package/dist/agent0/capabilities/skills/adk-evals/references/testing-workflow.md +6 -4
  72. package/dist/agent0/config/schema.d.ts.map +1 -1
  73. package/dist/agent0/config/store.d.ts +8 -3
  74. package/dist/agent0/config/store.d.ts.map +1 -1
  75. package/dist/agent0/index.js +214 -59
  76. package/dist/agent0/index.js.map +17 -15
  77. package/dist/agent0/providers/catalog.d.ts.map +1 -1
  78. package/dist/agent0/providers/registry.d.ts.map +1 -1
  79. package/dist/agent0/providers/source.d.ts +8 -3
  80. package/dist/agent0/providers/source.d.ts.map +1 -1
  81. package/dist/agent0/runtime/client.d.ts +4 -3
  82. package/dist/agent0/runtime/client.d.ts.map +1 -1
  83. package/dist/agent0/runtime/engine.d.ts +7 -1
  84. package/dist/agent0/runtime/engine.d.ts.map +1 -1
  85. package/dist/agent0/runtime/manager.d.ts +2 -3
  86. package/dist/agent0/runtime/manager.d.ts.map +1 -1
  87. package/dist/agent0/runtime/process.d.ts +10 -0
  88. package/dist/agent0/runtime/process.d.ts.map +1 -1
  89. package/dist/assets/manager.d.ts +3 -0
  90. package/dist/assets/manager.d.ts.map +1 -1
  91. package/dist/auth/credentials.d.ts +1 -1
  92. package/dist/auth/credentials.d.ts.map +1 -1
  93. package/dist/auth/index.d.ts.map +1 -1
  94. package/dist/auth/service.d.ts.map +1 -1
  95. package/dist/bot-generator/generator.d.ts +22 -0
  96. package/dist/bot-generator/generator.d.ts.map +1 -1
  97. package/dist/bot-generator/integration-sync.d.ts +2 -0
  98. package/dist/bot-generator/integration-sync.d.ts.map +1 -1
  99. package/dist/bot-generator/interface-sync.d.ts +2 -0
  100. package/dist/bot-generator/interface-sync.d.ts.map +1 -1
  101. package/dist/bot-generator/plugin-sync.d.ts +2 -0
  102. package/dist/bot-generator/plugin-sync.d.ts.map +1 -1
  103. package/dist/cognitive/models.d.ts.map +1 -1
  104. package/dist/commands/base-command.d.ts +1 -0
  105. package/dist/commands/base-command.d.ts.map +1 -1
  106. package/dist/commands/bp-cli.d.ts.map +1 -1
  107. package/dist/commands/bp-cli.js +147 -0
  108. package/dist/commands/bp-cli.js.map +12 -0
  109. package/dist/commands/bp-dev-command.d.ts +3 -1
  110. package/dist/commands/bp-dev-command.d.ts.map +1 -1
  111. package/dist/commands/bp-dev-stderr.d.ts +9 -0
  112. package/dist/commands/bp-dev-stderr.d.ts.map +1 -1
  113. package/dist/commands/bp-dev-worker-env.d.ts +7 -0
  114. package/dist/commands/bp-dev-worker-env.d.ts.map +1 -0
  115. package/dist/commands/index.d.ts +1 -0
  116. package/dist/commands/index.d.ts.map +1 -1
  117. package/dist/config/manager.d.ts.map +1 -1
  118. package/dist/dependencies/catalog/catalog-service.d.ts +53 -0
  119. package/dist/dependencies/catalog/catalog-service.d.ts.map +1 -0
  120. package/dist/dependencies/catalog/client-factory.d.ts +33 -0
  121. package/dist/dependencies/catalog/client-factory.d.ts.map +1 -0
  122. package/dist/dependencies/catalog/integration-source.d.ts +34 -0
  123. package/dist/dependencies/catalog/integration-source.d.ts.map +1 -0
  124. package/dist/dependencies/catalog/interface-source.d.ts +23 -0
  125. package/dist/dependencies/catalog/interface-source.d.ts.map +1 -0
  126. package/dist/dependencies/catalog/plugin-source.d.ts +49 -0
  127. package/dist/dependencies/catalog/plugin-source.d.ts.map +1 -0
  128. package/dist/dependencies/catalog/resolution-cache.d.ts +76 -0
  129. package/dist/dependencies/catalog/resolution-cache.d.ts.map +1 -0
  130. package/dist/dependencies/dependency-manager.d.ts +31 -16
  131. package/dist/dependencies/dependency-manager.d.ts.map +1 -1
  132. package/dist/dependencies/errors.d.ts +9 -6
  133. package/dist/dependencies/errors.d.ts.map +1 -1
  134. package/dist/dependencies/index.d.ts +5 -4
  135. package/dist/dependencies/index.d.ts.map +1 -1
  136. package/dist/dependencies/index.js +2309 -1697
  137. package/dist/dependencies/index.js.map +41 -32
  138. package/dist/dependencies/legacy-lock-file.d.ts +15 -0
  139. package/dist/dependencies/legacy-lock-file.d.ts.map +1 -0
  140. package/dist/dependencies/migration.d.ts +19 -0
  141. package/dist/dependencies/migration.d.ts.map +1 -1
  142. package/dist/dependencies/resolvers/integration-resolver.d.ts +4 -3
  143. package/dist/dependencies/resolvers/integration-resolver.d.ts.map +1 -1
  144. package/dist/dependencies/resolvers/plugin-resolver.d.ts +4 -4
  145. package/dist/dependencies/resolvers/plugin-resolver.d.ts.map +1 -1
  146. package/dist/dependencies/snapshot-store.d.ts +59 -0
  147. package/dist/dependencies/snapshot-store.d.ts.map +1 -0
  148. package/dist/dependencies/status-resolver.d.ts +36 -0
  149. package/dist/dependencies/status-resolver.d.ts.map +1 -0
  150. package/dist/dependencies/status.d.ts +214 -0
  151. package/dist/dependencies/status.d.ts.map +1 -0
  152. package/dist/dependencies/types.d.ts +388 -37
  153. package/dist/dependencies/types.d.ts.map +1 -1
  154. package/dist/file-watcher/watcher.d.ts +21 -5
  155. package/dist/file-watcher/watcher.d.ts.map +1 -1
  156. package/dist/generators/action-types.d.ts.map +1 -1
  157. package/dist/generators/client-wrapper.d.ts.map +1 -1
  158. package/dist/index.d.ts +5 -5
  159. package/dist/index.d.ts.map +1 -1
  160. package/dist/index.js +3643 -2345
  161. package/dist/index.js.map +68 -58
  162. package/dist/integrations/config-utils.d.ts +11 -7
  163. package/dist/integrations/config-utils.d.ts.map +1 -1
  164. package/dist/integrations/hub-cache.d.ts +0 -58
  165. package/dist/integrations/hub-cache.d.ts.map +1 -1
  166. package/dist/integrations/index.d.ts +1 -3
  167. package/dist/integrations/index.d.ts.map +1 -1
  168. package/dist/integrations/manager.d.ts +19 -53
  169. package/dist/integrations/manager.d.ts.map +1 -1
  170. package/dist/interfaces/enhanced-cache.d.ts +7 -7
  171. package/dist/interfaces/enhanced-cache.d.ts.map +1 -1
  172. package/dist/interfaces/manager.d.ts +11 -17
  173. package/dist/interfaces/manager.d.ts.map +1 -1
  174. package/dist/interfaces/parser.d.ts.map +1 -1
  175. package/dist/knowledge/manager.d.ts +3 -0
  176. package/dist/knowledge/manager.d.ts.map +1 -1
  177. package/dist/plugins/index.d.ts +0 -1
  178. package/dist/plugins/index.d.ts.map +1 -1
  179. package/dist/plugins/manager.d.ts +16 -48
  180. package/dist/plugins/manager.d.ts.map +1 -1
  181. package/dist/preflight/checker.d.ts +6 -1
  182. package/dist/preflight/checker.d.ts.map +1 -1
  183. package/dist/preflight/dependency-gate.d.ts +37 -0
  184. package/dist/preflight/dependency-gate.d.ts.map +1 -0
  185. package/dist/preflight/index.d.ts +2 -1
  186. package/dist/preflight/index.d.ts.map +1 -1
  187. package/dist/preflight/types.d.ts +18 -0
  188. package/dist/preflight/types.d.ts.map +1 -1
  189. package/dist/runner/script-runner.d.ts.map +1 -1
  190. package/dist/secrets/manager.d.ts.map +1 -1
  191. package/dist/tables/table-manager.d.ts +3 -0
  192. package/dist/tables/table-manager.d.ts.map +1 -1
  193. package/dist/templates/README.md +23 -13
  194. package/dist/templates/blank/agent.config.ts +3 -3
  195. package/dist/templates/blank/src/triggers/index.ts +1 -1
  196. package/dist/templates/botpress-desk/evals/index.eval.ts +1 -1
  197. package/dist/templates/botpress-desk/src/triggers/index.ts +1 -1
  198. package/dist/templates/crm-enrichment/README.md +3 -3
  199. package/dist/templates/crm-enrichment/agent.config.ts +2 -2
  200. package/dist/templates/crm-enrichment/src/conversations/index.ts +1 -1
  201. package/dist/templates/hello-world/agent.config.ts +3 -3
  202. package/dist/templates/hello-world/src/triggers/index.ts +1 -1
  203. package/dist/templates/knowledge-assistant/src/triggers/index.ts +1 -1
  204. package/dist/templates/template.config.json +3 -3
  205. package/dist/test-utils/mock-module.d.ts +29 -0
  206. package/dist/test-utils/mock-module.d.ts.map +1 -0
  207. package/dist/utils/ids.d.ts +10 -0
  208. package/dist/utils/ids.d.ts.map +1 -1
  209. package/dist/utils/require-chat.d.ts.map +1 -1
  210. package/dist/utils/source-map-optimizer.d.ts +10 -11
  211. package/dist/utils/source-map-optimizer.d.ts.map +1 -1
  212. package/dist/workspace/workspace-cache.d.ts +2 -1
  213. package/dist/workspace/workspace-cache.d.ts.map +1 -1
  214. package/package.json +8 -4
  215. package/dist/agent-project/lock-to-dependencies.d.ts +0 -11
  216. package/dist/agent-project/lock-to-dependencies.d.ts.map +0 -1
  217. package/dist/dependencies/lock-file.d.ts +0 -15
  218. package/dist/dependencies/lock-file.d.ts.map +0 -1
  219. package/dist/integrations/enhanced-cache.d.ts +0 -53
  220. package/dist/integrations/enhanced-cache.d.ts.map +0 -1
  221. package/dist/plugins/enhanced-cache.d.ts +0 -53
  222. package/dist/plugins/enhanced-cache.d.ts.map +0 -1
  223. package/dist/templates/blank/package.json +0 -17
  224. package/dist/templates/blank/tsconfig.json +0 -25
  225. package/dist/templates/botpress-desk/package.json +0 -17
  226. package/dist/templates/crm-enrichment/package.json +0 -18
  227. package/dist/templates/crm-enrichment/tsconfig.json +0 -25
  228. package/dist/templates/hello-world/package.json +0 -18
  229. package/dist/templates/hello-world/tsconfig.json +0 -25
  230. package/dist/templates/knowledge-assistant/package.json +0 -18
  231. package/dist/templates/knowledge-assistant/tsconfig.json +0 -25
  232. package/dist/templates/slack-triage/package.json +0 -18
  233. package/dist/templates/slack-triage/tsconfig.json +0 -25
@@ -6,14 +6,14 @@ Traces and logs are the primary debugging interface for ADK agents. Every conver
6
6
 
7
7
  Most commands support `--format json` for structured output — **always use it** when consuming output programmatically. The exception is `adk dev`, which has no `--format` flag: use `adk dev --non-interactive` to get a structured NDJSON event stream instead.
8
8
 
9
- | Command | Purpose | Options / tokens |
10
- |---------|---------|-----------------|
11
- | `adk check --format json` | Offline project validation — catches config/schema issues before runtime | — |
12
- | `adk logs --format json` | Browse or stream log entries | `--follow`, `--summary`, level filters (`error`, `warning`) |
13
- | `adk traces --format json` | Query traces with span details — filter by workflow, action, trigger, conversation, error, time | `workflow=`, `action=`, `trigger=`, `conversation=`, `trace=`, `error`, `since=`, `until=`, `limit=`, `--follow`, `--include-llm` |
14
- | `adk workflows runs --format json` | List or inspect durable workflow runs by id, name, or status | `name=`, `status=`, `limit=`, `nextToken=`, `<wrkflow_id>` |
15
- | `adk chat --single "msg" --format json` | Send a test message and get structured response | `--conversation-id` |
16
- | `adk dev --non-interactive` | Start dev server with structured NDJSON event stream (no TUI) | — |
9
+ | Command | Purpose | Options / tokens |
10
+ | --------------------------------------- | ----------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
11
+ | `adk check --format json` | Offline project validation — catches config/schema issues before runtime | — |
12
+ | `adk logs --format json` | Browse or stream log entries | `--follow`, `--summary`, level filters (`error`, `warning`) |
13
+ | `adk traces --format json` | Query traces with span details — filter by workflow, action, trigger, conversation, error, time | `workflow=`, `action=`, `trigger=`, `conversation=`, `trace=`, `error`, `since=`, `until=`, `limit=`, `--follow`, `--include-llm` |
14
+ | `adk workflows runs --format json` | List or inspect durable workflow runs by id, name, or status | `name=`, `status=`, `limit=`, `nextToken=`, `<wrkflow_id>` |
15
+ | `adk chat --single "msg" --format json` | Send a test message and get structured response | `--conversation-id` |
16
+ | `adk dev --non-interactive` | Start dev server with structured NDJSON event stream (no TUI) | — |
17
17
 
18
18
  ## Querying Logs
19
19
 
@@ -64,12 +64,12 @@ A trace represents one unit of agent activity. Each trace contains:
64
64
 
65
65
  Spans are the atomic units inside a trace. Each span has a `type` field:
66
66
 
67
- | Span Type | Key Fields | What It Means |
68
- |-----------|-----------|---------------|
69
- | `tool_call` | `tool_name`, `input`, `output`, `success`, `error` | A tool was invoked. Check `success` to see if it worked. |
70
- | `code_execution_exception` | `message`, `stackTrace` | Code error in the LLMz sandbox. Read `stackTrace` to find the source. |
71
- | `think` | `content` | LLM reasoning step — shows why the model made a decision. |
72
- | `end` | — | Conversation turn completed. |
67
+ | Span Type | Key Fields | What It Means |
68
+ | -------------------------- | -------------------------------------------------- | --------------------------------------------------------------------- |
69
+ | `tool_call` | `tool_name`, `input`, `output`, `success`, `error` | A tool was invoked. Check `success` to see if it worked. |
70
+ | `code_execution_exception` | `message`, `stackTrace` | Code error in the LLMz sandbox. Read `stackTrace` to find the source. |
71
+ | `think` | `content` | LLM reasoning step — shows why the model made a decision. |
72
+ | `end` | — | Conversation turn completed. |
73
73
 
74
74
  ### Reading a Trace
75
75
 
@@ -103,101 +103,101 @@ For monitoring traces in code, use the `onTrace` hook in conversation handlers.
103
103
 
104
104
  ```typescript
105
105
  // src/conversations/extensions/logging.ts
106
- import { Autonomous } from "@botpress/runtime";
106
+ import { Autonomous } from '@botpress/runtime'
107
107
 
108
- export const onTraceLogging: Autonomous.Hooks["onTrace"] = ({ trace, iteration }) => {
109
- if (trace.type === "code_execution_exception") {
110
- console.error(`Code Execution Error: ${trace.message}`, trace.stackTrace);
108
+ export const onTraceLogging: Autonomous.Hooks['onTrace'] = ({ trace, iteration }) => {
109
+ if (trace.type === 'code_execution_exception') {
110
+ console.error(`Code Execution Error: ${trace.message}`, trace.stackTrace)
111
111
  }
112
112
 
113
- if (trace.type === "tool_call" && !trace.success) {
113
+ if (trace.type === 'tool_call' && !trace.success) {
114
114
  console.error(
115
115
  `Error during tool call to "${trace.tool_name}" with input "${JSON.stringify(trace.input)}":`,
116
116
  trace.error
117
- );
117
+ )
118
118
  }
119
- };
119
+ }
120
120
  ```
121
121
 
122
122
  ### Comprehensive Trace Logging
123
123
 
124
124
  ```typescript
125
- export const onTraceLogging: Autonomous.Hooks["onTrace"] = ({ trace, iteration }) => {
125
+ export const onTraceLogging: Autonomous.Hooks['onTrace'] = ({ trace, iteration }) => {
126
126
  switch (trace.type) {
127
- case "code_execution_exception":
128
- console.error(`[CODE ERROR] ${trace.message}`, trace.stackTrace);
129
- break;
130
- case "tool_call":
127
+ case 'code_execution_exception':
128
+ console.error(`[CODE ERROR] ${trace.message}`, trace.stackTrace)
129
+ break
130
+ case 'tool_call':
131
131
  if (trace.success) {
132
- console.log(`[TOOL SUCCESS] ${trace.tool_name}`, trace.output);
132
+ console.log(`[TOOL SUCCESS] ${trace.tool_name}`, trace.output)
133
133
  } else {
134
- console.error(`[TOOL ERROR] ${trace.tool_name}`, trace.error);
134
+ console.error(`[TOOL ERROR] ${trace.tool_name}`, trace.error)
135
135
  }
136
- break;
137
- case "think":
138
- console.debug(`[THINK] ${trace.content}`);
139
- break;
136
+ break
137
+ case 'think':
138
+ console.debug(`[THINK] ${trace.content}`)
139
+ break
140
140
  default:
141
- console.log(`[TRACE] ${trace.type}`, trace);
141
+ console.log(`[TRACE] ${trace.type}`, trace)
142
142
  }
143
- };
143
+ }
144
144
  ```
145
145
 
146
146
  ### Using in a Conversation
147
147
 
148
148
  ```typescript
149
- import { Conversation } from "@botpress/runtime";
150
- import { onTraceLogging } from "./extensions/logging";
149
+ import { Conversation } from '@botpress/runtime'
150
+ import { onTraceLogging } from './extensions/logging'
151
151
 
152
152
  export default new Conversation({
153
- channel: "*",
153
+ channel: '*',
154
154
  handler: async ({ execute }) => {
155
155
  await execute({
156
156
  instructions: `You are a helpful assistant...`,
157
157
  hooks: {
158
158
  onTrace: (props) => onTraceLogging!(props),
159
159
  },
160
- });
160
+ })
161
161
  },
162
- });
162
+ })
163
163
  ```
164
164
 
165
165
  ### Performance Monitoring
166
166
 
167
167
  ```typescript
168
168
  export const makePerformanceMonitor = () => {
169
- const startTime = Date.now();
170
- const toolStartTimes = new Map<string, number>();
171
- const toolMetrics = new Map<string, number[]>();
172
-
173
- const onBeforeTool: Autonomous.Hooks["onBeforeTool"] = async ({ tool }) => {
174
- toolStartTimes.set(tool.name, Date.now());
175
- };
176
-
177
- const onAfterTool: Autonomous.Hooks["onAfterTool"] = async ({ tool }) => {
178
- const start = toolStartTimes.get(tool.name);
179
- const duration = start ? Date.now() - start : 0;
180
- const metrics = toolMetrics.get(tool.name) || [];
181
- metrics.push(duration);
182
- toolMetrics.set(tool.name, metrics);
183
- console.log(`[PERF] ${tool.name}: ${duration}ms`);
184
- };
185
-
186
- const onTrace: Autonomous.Hooks["onTrace"] = ({ trace }) => {
187
- if (trace.type === "end") {
188
- console.log(`[PERF] Total conversation: ${Date.now() - startTime}ms`);
189
- console.log(`[PERF] Tool metrics:`, Object.fromEntries(toolMetrics));
169
+ const startTime = Date.now()
170
+ const toolStartTimes = new Map<string, number>()
171
+ const toolMetrics = new Map<string, number[]>()
172
+
173
+ const onBeforeTool: Autonomous.Hooks['onBeforeTool'] = async ({ tool }) => {
174
+ toolStartTimes.set(tool.name, Date.now())
175
+ }
176
+
177
+ const onAfterTool: Autonomous.Hooks['onAfterTool'] = async ({ tool }) => {
178
+ const start = toolStartTimes.get(tool.name)
179
+ const duration = start ? Date.now() - start : 0
180
+ const metrics = toolMetrics.get(tool.name) || []
181
+ metrics.push(duration)
182
+ toolMetrics.set(tool.name, metrics)
183
+ console.log(`[PERF] ${tool.name}: ${duration}ms`)
184
+ }
185
+
186
+ const onTrace: Autonomous.Hooks['onTrace'] = ({ trace }) => {
187
+ if (trace.type === 'end') {
188
+ console.log(`[PERF] Total conversation: ${Date.now() - startTime}ms`)
189
+ console.log(`[PERF] Tool metrics:`, Object.fromEntries(toolMetrics))
190
190
  }
191
- };
191
+ }
192
192
 
193
- return { onBeforeTool, onAfterTool, onTrace };
194
- };
193
+ return { onBeforeTool, onAfterTool, onTrace }
194
+ }
195
195
  ```
196
196
 
197
197
  ### Hook Reference
198
198
 
199
- | Hook | Parameters | When It Fires |
200
- |------|-----------|--------------|
199
+ | Hook | Parameters | When It Fires |
200
+ | -------------- | ---------------------------------------- | --------------------- |
201
201
  | `onBeforeTool` | `{ iteration, tool, input, controller }` | Before each tool call |
202
- | `onAfterTool` | `{ tool, output }` | After each tool call |
203
- | `onTrace` | `{ trace, iteration }` | On every trace event |
202
+ | `onAfterTool` | `{ tool, output }` | After each tool call |
203
+ | `onTrace` | `{ trace, iteration }` | On every trace event |
@@ -27,11 +27,11 @@ Activate when users ask about:
27
27
 
28
28
  ## Available Documentation
29
29
 
30
- | File | Contents |
31
- |------|----------|
32
- | `references/agent-steps.md` | Agent Steps visualization — turns, iterations, tools, messages, state mutations, cost tracking, status indicators |
33
- | `references/pages.md` | Every page/tab in the Dev Console — what it shows, key features, layout |
34
- | `references/component-registry.md` | Component Registry — installed vs registry tabs, component lifecycle, runtime registry internals, UI features |
30
+ | File | Contents |
31
+ | ------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
32
+ | `references/agent-steps.md` | Agent Steps visualization — turns, iterations, tools, messages, state mutations, cost tracking, status indicators |
33
+ | `references/pages.md` | Every page/tab in the Dev Console — what it shows, key features, layout |
34
+ | `references/component-registry.md` | Component Registry — installed vs registry tabs, component lifecycle, runtime registry internals, UI features |
35
35
  | `references/multi-agent-dashboard.md` | Multi-agent architecture, agent selector, console modes (local/cloud), dev/prod targets, CLI commands (`adk ps`, `adk kill`, `adk dashboard`, `adk status`) |
36
36
 
37
37
  ## How to Answer
@@ -47,15 +47,15 @@ Match depth to the question:
47
47
 
48
48
  ### Tab Groups
49
49
 
50
- | Group | Pages | Purpose |
51
- |-------|-------|---------|
52
- | **Chat** | Chat | Test the agent via webchat + see Agent Steps |
53
- | **Build** | Agent Map | Interactive agent architecture graph (experimental, feature-flagged behind `enable_agent_forge`) |
54
- | **Components** | Webchat Components, Actions, Workflows, Triggers | Browse component registry, test bot primitives |
55
- | **Test** | RAG Search, Evals | Test knowledge search and run automated evals |
56
- | **Data** | Knowledge, Tables, Files | Manage knowledge bases, tables, and files |
57
- | **Observe** | Conversations, Traces, Logs | View conversation history, execution traces, runtime logs |
58
- | **Config** | Settings, Integrations | Agent config, secrets, LLM settings, integration management |
50
+ | Group | Pages | Purpose |
51
+ | -------------- | ------------------------------------------------ | ------------------------------------------------------------------------------------------------ |
52
+ | **Chat** | Chat | Test the agent via webchat + see Agent Steps |
53
+ | **Build** | Agent Map | Interactive agent architecture graph (experimental, feature-flagged behind `enable_agent_forge`) |
54
+ | **Components** | Webchat Components, Actions, Workflows, Triggers | Browse component registry, test bot primitives |
55
+ | **Test** | RAG Search, Evals | Test knowledge search and run automated evals |
56
+ | **Data** | Knowledge, Tables, Files | Manage knowledge bases, tables, and files |
57
+ | **Observe** | Conversations, Traces, Logs | View conversation history, execution traces, runtime logs |
58
+ | **Config** | Settings, Integrations | Agent config, secrets, LLM settings, integration management |
59
59
 
60
60
  ### Multi-Agent Sidebar
61
61
 
@@ -84,28 +84,28 @@ The right panel of the Chat page shows **Agent Steps** — a real-time visualiza
84
84
 
85
85
  ### Key URLs
86
86
 
87
- | Path | Page |
88
- |------|------|
89
- | `/chat` | Chat + Agent Steps |
90
- | `/agent-map` | Agent Map — interactive architecture graph (experimental) |
91
- | `/components` | Component registry + installed components |
92
- | `/actions` | Actions browser |
93
- | `/workflows` | Workflows + run history |
94
- | `/search` | RAG search testing |
95
- | `/evals` | Eval definitions + runs |
96
- | `/knowledge` | Knowledge base management |
97
- | `/tables` | Table data management |
98
- | `/traces` | Full trace viewer |
99
- | `/conversations` | Conversation history |
100
- | `/logs` | Runtime logs |
101
- | `/settings` | Agent configuration |
102
- | `/integrations` | Integration management |
87
+ | Path | Page |
88
+ | ---------------- | --------------------------------------------------------- |
89
+ | `/chat` | Chat + Agent Steps |
90
+ | `/agent-map` | Agent Map — interactive architecture graph (experimental) |
91
+ | `/components` | Component registry + installed components |
92
+ | `/actions` | Actions browser |
93
+ | `/workflows` | Workflows + run history |
94
+ | `/search` | RAG search testing |
95
+ | `/evals` | Eval definitions + runs |
96
+ | `/knowledge` | Knowledge base management |
97
+ | `/tables` | Table data management |
98
+ | `/traces` | Full trace viewer |
99
+ | `/conversations` | Conversation history |
100
+ | `/logs` | Runtime logs |
101
+ | `/settings` | Agent configuration |
102
+ | `/integrations` | Integration management |
103
103
 
104
104
  ### Multi-Agent CLI Commands
105
105
 
106
- | Command | Purpose |
107
- |---------|---------|
108
- | `adk ps` | List running agents and processes with PIDs, ports, uptime (supports `--watch`) |
109
- | `adk dashboard` | Open the DevConsole in standalone mode (no agent required) |
110
- | `adk kill` | Stop agents or the entire DevConsole (`--all`, `--current`, `--pid`, or by name) |
111
- | `adk status` | Show project health and status info |
106
+ | Command | Purpose |
107
+ | --------------- | -------------------------------------------------------------------------------- |
108
+ | `adk ps` | List running agents and processes with PIDs, ports, uptime (supports `--watch`) |
109
+ | `adk dashboard` | Open the DevConsole in standalone mode (no agent required) |
110
+ | `adk kill` | Stop agents or the entire DevConsole (`--all`, `--current`, `--pid`, or by name) |
111
+ | `adk status` | Show project health and status info |
@@ -37,11 +37,13 @@ A **Turn** is one conversation exchange — from the user's input through the ag
37
37
  ### Steps (Autonomous Iterations)
38
38
 
39
39
  Each **Step** is one iteration of the autonomous agent loop. The agent:
40
+
40
41
  1. Receives context (conversation history, available tools)
41
42
  2. Makes an LLM call (the **cognitive request**)
42
43
  3. Decides what to do: call a tool, send a message, or stop
43
44
 
44
45
  Each step shows:
46
+
45
47
  - **Iteration number** (1, 2, 3...)
46
48
  - **Exit reason**: "continued" (more work to do), "tool_called", "message_sent", "errored"
47
49
  - **Cognitive request** metadata: model, input/output tokens, cost, duration
@@ -51,6 +53,7 @@ Each step shows:
51
53
  ### Tool Calls
52
54
 
53
55
  Displayed as **violet cards** (or green for `search_knowledge`). Each shows:
56
+
54
57
  - Tool name
55
58
  - Input (JSON)
56
59
  - Output (JSON or markdown for knowledge search results)
@@ -60,6 +63,7 @@ Displayed as **violet cards** (or green for `search_knowledge`). Each shows:
60
63
  ### Bot Messages
61
64
 
62
65
  Displayed as **blue cards**. Each shows:
66
+
63
67
  - Message content (markdown rendered)
64
68
  - Duration
65
69
  - Long messages are clamped at 300 characters — click to expand
@@ -67,6 +71,7 @@ Displayed as **blue cards**. Each shows:
67
71
  ### State Mutations
68
72
 
69
73
  Displayed as **teal cards**. Each shows:
74
+
70
75
  - State type (bot, user, conversation)
71
76
  - Two-column "Before" and "After" view
72
77
  - Only changed keys shown by default (toggle for full state)
@@ -75,22 +80,24 @@ Displayed as **teal cards**. Each shows:
75
80
  ### Trigger Handlers
76
81
 
77
82
  When a trigger fires instead of a conversation message, the turn shows an **amber card** with:
83
+
78
84
  - Trigger name
79
85
  - Event type that fired it
80
86
  - Same iteration/tool/message structure inside
81
87
 
82
88
  ## Status Indicators
83
89
 
84
- | Visual | Meaning |
85
- |--------|---------|
86
- | ✓ Green checkmark | Completed successfully |
87
- | ✗ Red X | Failed (error message in detail panel) |
88
- | ⟳ Blue spinner | Currently executing |
89
- | Shimmer text ("thinking...") | LLM is generating |
90
+ | Visual | Meaning |
91
+ | ---------------------------- | -------------------------------------- |
92
+ | ✓ Green checkmark | Completed successfully |
93
+ | ✗ Red X | Failed (error message in detail panel) |
94
+ | ⟳ Blue spinner | Currently executing |
95
+ | Shimmer text ("thinking...") | LLM is generating |
90
96
 
91
97
  ## AI Metrics
92
98
 
93
99
  Each iteration's cognitive request shows:
100
+
94
101
  - **Model**: e.g., "claude-3.5-sonnet"
95
102
  - **Input tokens**: count + cost
96
103
  - **Output tokens**: count + cost
@@ -109,6 +116,7 @@ Turn-level cost is the sum of all iteration costs.
109
116
  ## Real-Time Updates
110
117
 
111
118
  Agent Steps streams data via SSE (Server-Sent Events):
119
+
112
120
  - Running spans show a live timer
113
121
  - New spans animate in from the top
114
122
  - Auto-scrolls to bottom when new content arrives
@@ -8,11 +8,11 @@ Running `adk dev` in multiple project directories registers each agent with a si
8
8
 
9
9
  Each agent shows a status indicator:
10
10
 
11
- | Status | Meaning |
12
- |--------|---------|
11
+ | Status | Meaning |
12
+ | ---------- | ----------------------------------------- |
13
13
  | `starting` | Agent is initializing (building, syncing) |
14
- | `ready` | Agent is running and accepting requests |
15
- | `error` | Agent encountered a fatal error |
14
+ | `ready` | Agent is running and accepting requests |
15
+ | `error` | Agent encountered a fatal error |
16
16
 
17
17
  If all agents are stopped, the DevConsole exits automatically (unless started in standalone mode via `adk dashboard`).
18
18
 
@@ -30,10 +30,10 @@ The Dev Console supports two orthogonal concepts:
30
30
  - **Dev target** — uses the local project's dev bot ID and local backend. All pages available.
31
31
  - **Prod target** — uses the deployed prod bot data. Hides dev-only pages (Actions, Workflows, Triggers, Evals, Files, Conversations, Traces, Logs).
32
32
 
33
- | Console Mode | Dev Target | Prod Target |
34
- |-------------|------------|-------------|
35
- | Local | Local dev bot + all pages | Prod bot data + restricted pages |
36
- | Cloud | Not available | Prod bot data + restricted pages |
33
+ | Console Mode | Dev Target | Prod Target |
34
+ | ------------ | ------------------------- | -------------------------------- |
35
+ | Local | Local dev bot + all pages | Prod bot data + restricted pages |
36
+ | Cloud | Not available | Prod bot data + restricted pages |
37
37
 
38
38
  Prod views that need ADK source-shaped definitions (actions, workflows, triggers, tables, knowledge) read **deployed metadata** published by `adk deploy`, not local source files. This is true in both local-prod and cloud-prod modes.
39
39
 
@@ -58,12 +58,12 @@ Compact pill in the top navigation center: status dot + agent name + mode pill +
58
58
 
59
59
  See the [CLI Reference](../../adk/references/cli.md) for full options and examples.
60
60
 
61
- | Command | What it does |
62
- |---------|-------------|
63
- | `adk ps` | List running agents and processes |
61
+ | Command | What it does |
62
+ | --------------- | --------------------------------- |
63
+ | `adk ps` | List running agents and processes |
64
64
  | `adk dashboard` | Open Dev Console without an agent |
65
- | `adk kill` | Stop agents or the Dev Console |
66
- | `adk status` | Show project health info |
65
+ | `adk kill` | Stop agents or the Dev Console |
66
+ | `adk status` | Show project health info |
67
67
 
68
68
  ## Data Isolation
69
69
 
@@ -20,6 +20,7 @@ Real-time conversation interface for testing the agent.
20
20
  **Layout:** Webchat embed (left) + Agent Steps visualization (right)
21
21
 
22
22
  **Features:**
23
+
23
24
  - Webchat panel for sending messages to the agent
24
25
  - Agent Steps panel showing execution flow (see `agent-steps.md`)
25
26
  - Conversation picker dropdown (filters to webchat conversations)
@@ -35,6 +36,7 @@ Interactive bird's-eye visualization of the agent's architecture as a graph. Fea
35
36
  **Layout:** Full-screen React Flow canvas with auto-layout (elkjs) + detail panel
36
37
 
37
38
  **Features:**
39
+
38
40
  - Graph nodes for agent primitives: triggers, actions, workflows, autonomous handlers, knowledge bases, tables
39
41
  - Edges showing relationships between primitives
40
42
  - Auto-layout with elkjs; user can drag nodes (positions persist to localStorage per agent)
@@ -57,16 +59,19 @@ Browse the component registry and inspect components installed in the agent.
57
59
  **Tabs:**
58
60
 
59
61
  **Installed** — Components present in the agent's `src/components/` directory:
62
+
60
63
  - Masonry card layout with component preview (rendered in shadow DOM)
61
64
  - Click a card to open overlay with full details
62
65
  - Empty state: "No components installed yet" with guidance
63
66
 
64
67
  **Registry** — Available components from the external component registry:
68
+
65
69
  - Same masonry layout
66
70
  - Click a card to open overlay with installation instructions and metadata
67
71
  - Empty state: "Registry is empty"
68
72
 
69
73
  **Features:**
74
+
70
75
  - Live reload on component source changes
71
76
  - Preview rendering via shadow DOM isolation
72
77
  - Error states for load/fetch failures
@@ -81,6 +86,7 @@ Browse and test bot actions and integration actions.
81
86
  **Layout:** Sidebar (action list) + detail pane
82
87
 
83
88
  **Features:**
89
+
84
90
  - Bot custom actions with input/output schema visualization
85
91
  - Integration actions grouped by integration (icon, title, description)
86
92
  - "Invoke action" button opens a modal to test with live inputs
@@ -93,6 +99,7 @@ Browse workflows and view execution history.
93
99
  **Layout:** Sidebar (workflow list) + detail pane
94
100
 
95
101
  **Features:**
102
+
96
103
  - Workflow name, path, description, timeout badge
97
104
  - "Invoke workflow" button to trigger manually
98
105
  - Workflow definition schema
@@ -106,6 +113,7 @@ Browse event triggers defined in the agent.
106
113
  **Layout:** Sidebar (trigger list) + detail pane
107
114
 
108
115
  **Features:**
116
+
109
117
  - Trigger names and event types
110
118
  - Trigger metadata and status
111
119
 
@@ -120,6 +128,7 @@ Test knowledge base search interactively.
120
128
  **Layout:** Sidebar (KB filter + content tree) + search input + results area + detail drawer
121
129
 
122
130
  **Features:**
131
+
123
132
  - Dropdown to filter by specific knowledge base
124
133
  - Query input with advanced settings (result limit, context depth)
125
134
  - Search results as cards: relevance score, source file, text snippet
@@ -134,6 +143,7 @@ Run and inspect automated conversation tests.
134
143
  **Layout:** Sidebar (eval list) + detail pane
135
144
 
136
145
  **Features:**
146
+
137
147
  - Eval definitions with run history
138
148
  - Run status: pending, in-progress, completed
139
149
  - Per-turn assertion results with pass/fail badges
@@ -154,6 +164,7 @@ Manage knowledge bases and uploaded files.
154
164
  **Layout:** Sidebar (KB list) + toolbar + file grid
155
165
 
156
166
  **Features:**
167
+
157
168
  - Knowledge base list with icons and descriptions
158
169
  - File grid: name, size, upload date, status badge (synced/syncing/error/local)
159
170
  - Filter by name, source, status, date range
@@ -169,6 +180,7 @@ Manage agent data tables.
169
180
  **Layout:** Sidebar (table list) + toolbar + data grid + pagination
170
181
 
171
182
  **Features:**
183
+
172
184
  - Table definitions with row counts
173
185
  - Sortable, filterable data grid (100 rows/page)
174
186
  - Add/edit/delete rows
@@ -184,6 +196,7 @@ Browse agent files.
184
196
  **Layout:** Folder browser
185
197
 
186
198
  **Features:**
199
+
187
200
  - Folder tree: All Files, Knowledge Base, System, Webchat
188
201
  - File list with name, size, modification time
189
202
  - Copy file path button
@@ -201,6 +214,7 @@ View all conversations with the agent.
201
214
  **Layout:** Full-page table
202
215
 
203
216
  **Features:**
217
+
204
218
  - Table columns: ID, Integration → Channel, Created, Updated, Preview
205
219
  - Sortable columns
206
220
  - Real-time polling for new conversations
@@ -213,6 +227,7 @@ Deep execution trace inspection. More detailed than Agent Steps — shows the fu
213
227
  **Layout:** Full-page trace viewer
214
228
 
215
229
  **Features:**
230
+
216
231
  - Hierarchical span tree grouped by parent
217
232
  - Span detail panel: name, timing, status, full data payload
218
233
  - JSON and tree view of span data
@@ -228,6 +243,7 @@ Agent runtime logs.
228
243
  **Layout:** Full-page log viewer
229
244
 
230
245
  **Features:**
246
+
231
247
  - Real-time log stream (stdout, stderr, info)
232
248
  - Time range filters: 5m, 15m, 1h, 6h, all
233
249
  - Text search/filter
@@ -245,6 +261,7 @@ Agent runtime logs.
245
261
  Agent configuration management.
246
262
 
247
263
  **Sections (sidebar navigation):**
264
+
248
265
  1. **Overview** — Agent metadata: name, Bot ID, Workspace ID, file path, created/updated dates. Copy buttons for IDs.
249
266
  2. **Configuration Variables** (dev only) — Runtime config schema and values. Add/edit/delete variables.
250
267
  3. **Secrets** (dev only) — Secret schema and values. Add/edit/delete secrets.
@@ -255,6 +272,7 @@ Agent configuration management.
255
272
  Install, configure, and manage integrations.
256
273
 
257
274
  **Features:**
275
+
258
276
  - Integration Hub UI (Botpress component)
259
277
  - OAuth redirect handling
260
278
  - Integration name and alias resolution
@@ -22,19 +22,19 @@ Activate this skill when users:
22
22
 
23
23
  ## Available Documentation
24
24
 
25
- | File | Description |
26
- |------|-------------|
25
+ | File | Description |
26
+ | ------------------------------------------------------------ | ----------------------------------------------------------------- |
27
27
  | [references/doc-standards.md](./references/doc-standards.md) | Document types, templates, quality checklists, and health metrics |
28
28
 
29
29
  ## Available Commands
30
30
 
31
- | Command (and suggested subcommand) | Description |
32
- |---------|-------------|
33
- | `/adk-document create [topic]` | Create documentation for a feature in the user's bot |
34
- | `/adk-document review [doc-path]` | Review project docs for accuracy and completeness |
35
- | `/adk-document update [doc-path] [what-changed]` | Update project docs after code changes |
36
- | `/adk-document sync [optional-doc-path]` | Check if project docs are in sync with the bot's code |
37
- | `/adk-document search [search-term]` | Search project documentation for specific topics |
31
+ | Command (and suggested subcommand) | Description |
32
+ | ------------------------------------------------ | ----------------------------------------------------- |
33
+ | `/adk-document create [topic]` | Create documentation for a feature in the user's bot |
34
+ | `/adk-document review [doc-path]` | Review project docs for accuracy and completeness |
35
+ | `/adk-document update [doc-path] [what-changed]` | Update project docs after code changes |
36
+ | `/adk-document sync [optional-doc-path]` | Check if project docs are in sync with the bot's code |
37
+ | `/adk-document search [search-term]` | Search project documentation for specific topics |
38
38
 
39
39
  ## Shared Principles
40
40
 
@@ -94,16 +94,16 @@ Discover the user's project and the official ADK repo for examples:
94
94
 
95
95
  ```javascript
96
96
  // Find ADK projects in the workspace
97
- Glob({ pattern: "**/agent.config.ts" })
97
+ Glob({ pattern: '**/agent.config.ts' })
98
98
 
99
99
  // Find ADK runtime usage in the user's project
100
- Grep({ pattern: "from ['\"]@botpress/runtime", output_mode: "files_with_matches" })
100
+ Grep({ pattern: 'from [\'"]@botpress/runtime', output_mode: 'files_with_matches' })
101
101
 
102
102
  // Look for existing project documentation
103
- Glob({ pattern: "./{docs,guides}/**/*.md" })
103
+ Glob({ pattern: './{docs,guides}/**/*.md' })
104
104
 
105
105
  // Find official ADK examples if available locally
106
- Glob({ pattern: "**/adk/examples/**/*.ts" })
106
+ Glob({ pattern: '**/adk/examples/**/*.ts' })
107
107
  ```
108
108
 
109
109
  ## Cross-References