@mgamadeus/ddd-agents 0.11.12 → 0.12.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 (226) hide show
  1. package/README.md +138 -6
  2. package/boundary.json +5 -0
  3. package/dist/admin.js +13712 -0
  4. package/dist/admin.js.map +1 -0
  5. package/dist/chat.js +1627 -109
  6. package/dist/chat.js.map +1 -1
  7. package/dist/chunks/{AgentsConversationClientContext-C4T7g_Qk.js → AgentsConversationClientContext-B_UJSLXU.js} +2 -2
  8. package/dist/chunks/{AgentsConversationClientContext-C4T7g_Qk.js.map → AgentsConversationClientContext-B_UJSLXU.js.map} +1 -1
  9. package/dist/chunks/{ConversationMarkdown-D-aP3Ssl.js → ConversationMarkdown-DlvwT3Qk.js} +5 -4
  10. package/dist/chunks/{ConversationMarkdown-D-aP3Ssl.js.map → ConversationMarkdown-DlvwT3Qk.js.map} +1 -1
  11. package/dist/chunks/{ConversationMessageInputComposerWidgets-7HNAmZE1.js → ConversationMessageInputComposerWidgets-TchR1lPj.js} +6 -6
  12. package/dist/chunks/{ConversationMessageInputComposerWidgets-7HNAmZE1.js.map → ConversationMessageInputComposerWidgets-TchR1lPj.js.map} +1 -1
  13. package/dist/chunks/{VoiceBarsIcon-FhLAcgLG.js → VoiceBarsIcon-y3mgSqbn.js} +4 -4
  14. package/dist/chunks/{VoiceBarsIcon-FhLAcgLG.js.map → VoiceBarsIcon-y3mgSqbn.js.map} +1 -1
  15. package/dist/chunks/{WebSearchResultsConversationWidget-dEq19U7k.js → WebSearchResultsConversationWidget-l9Aek_lG.js} +3 -2
  16. package/dist/chunks/WebSearchResultsConversationWidget-l9Aek_lG.js.map +1 -0
  17. package/dist/chunks/agents-http-trace-mappers-LWNi-3a4.js +759 -0
  18. package/dist/chunks/agents-http-trace-mappers-LWNi-3a4.js.map +1 -0
  19. package/dist/chunks/{browser-request-interception-ydNOzeUL.js → browser-request-interception-D678IemW.js} +2 -2
  20. package/dist/chunks/{browser-request-interception-ydNOzeUL.js.map → browser-request-interception-D678IemW.js.map} +1 -1
  21. package/dist/chunks/{canvas-reducers-BInd3xNz.js → canvas-reducers-BYArW_Ji.js} +2 -2
  22. package/dist/chunks/{canvas-reducers-BInd3xNz.js.map → canvas-reducers-BYArW_Ji.js.map} +1 -1
  23. package/dist/chunks/{canvas-title-slot-context-BI1PLnPn.js → canvas-title-slot-context-BRGnFzYP.js} +3 -3
  24. package/dist/chunks/{canvas-title-slot-context-BI1PLnPn.js.map → canvas-title-slot-context-BRGnFzYP.js.map} +1 -1
  25. package/dist/chunks/{canvasBodies-CRVh8pCw.js → canvasBodies-BjXypuHf.js} +4 -4
  26. package/dist/chunks/{canvasBodies-CRVh8pCw.js.map → canvasBodies-BjXypuHf.js.map} +1 -1
  27. package/dist/chunks/{canvasStorage-Cr3omZeI.js → canvasStorage-DSspwRMg.js} +2 -2
  28. package/dist/chunks/{canvasStorage-Cr3omZeI.js.map → canvasStorage-DSspwRMg.js.map} +1 -1
  29. package/dist/chunks/content-from-unified-diff-CovnmG2Q.js +2927 -0
  30. package/dist/chunks/content-from-unified-diff-CovnmG2Q.js.map +1 -0
  31. package/dist/chunks/{contract-C18owGKs.js → contract-886XjdID.js} +2 -2
  32. package/dist/chunks/{contract-C18owGKs.js.map → contract-886XjdID.js.map} +1 -1
  33. package/dist/chunks/{conversation-CbWEHPbL.js → conversation-B7-evdj_.js} +4 -4
  34. package/dist/chunks/{conversation-CbWEHPbL.js.map → conversation-B7-evdj_.js.map} +1 -1
  35. package/dist/chunks/{icon-names-Di6c4zLo.js → icon-names-C5PeVvkJ.js} +32 -1
  36. package/dist/chunks/icon-names-C5PeVvkJ.js.map +1 -0
  37. package/dist/chunks/{link-navigation-DRHt6g7U.js → index-DZovGMpG.js} +65 -106
  38. package/dist/chunks/index-DZovGMpG.js.map +1 -0
  39. package/dist/chunks/link-navigation-a_sRfmsj.js +49 -0
  40. package/dist/chunks/link-navigation-a_sRfmsj.js.map +1 -0
  41. package/dist/chunks/{widget-name-resolver-Dq6Ejo7d.js → widget-name-resolver-DS3zH_5W.js} +5 -4
  42. package/dist/chunks/{widget-name-resolver-Dq6Ejo7d.js.map → widget-name-resolver-DS3zH_5W.js.map} +1 -1
  43. package/dist/chunks/{withPollingChangeSubscription-ClyOABgu.js → withPollingChangeSubscription-XvCpjGmd.js} +13 -2
  44. package/dist/chunks/{withPollingChangeSubscription-ClyOABgu.js.map → withPollingChangeSubscription-XvCpjGmd.js.map} +1 -1
  45. package/dist/client-testing.js +5 -5
  46. package/dist/client.js +50 -231
  47. package/dist/client.js.map +1 -1
  48. package/dist/contract.js +5 -5
  49. package/dist/files/i18n-keys.json +18091 -1287
  50. package/dist/files/widgets/DriveFilesConversationWidget/DriveFilesConversationWidget.md +3 -3
  51. package/dist/image-render.js +7 -7
  52. package/dist/index.js +62 -61
  53. package/dist/index.js.map +1 -1
  54. package/dist/kit.js +2 -2
  55. package/dist/preview.js +7 -7
  56. package/dist/provider.js +57 -56
  57. package/dist/provider.js.map +1 -1
  58. package/dist/renderer.js +15 -15
  59. package/dist/styles.css +2962 -15
  60. package/dist/types/admin/blocks/CodeBlock.d.ts +28 -0
  61. package/dist/types/admin/blocks/DetailModal.d.ts +34 -0
  62. package/dist/types/admin/blocks/Disclosure.d.ts +25 -0
  63. package/dist/types/admin/blocks/JsonTree.d.ts +18 -0
  64. package/dist/types/admin/blocks/LineDiffView.d.ts +18 -0
  65. package/dist/types/admin/blocks/ProportionBar.d.ts +43 -0
  66. package/dist/types/admin/blocks/TokenFigure.d.ts +14 -0
  67. package/dist/types/admin/blocks/json-tree.d.ts +40 -0
  68. package/dist/types/admin/blocks/line-diff.d.ts +46 -0
  69. package/dist/types/admin/blocks/proportion-bar.d.ts +34 -0
  70. package/dist/types/admin/blocks/series-fill-classes.d.ts +13 -0
  71. package/dist/types/admin/blocks/token-figure.d.ts +8 -0
  72. package/dist/types/admin/connections/AgentConnectionCard.d.ts +21 -0
  73. package/dist/types/admin/connections/AgentConnectionDriveRootSpaces.d.ts +25 -0
  74. package/dist/types/admin/connections/AgentConnectionDriveScopeDialog.d.ts +20 -0
  75. package/dist/types/admin/connections/AgentConnectionDriveSearchFilters.d.ts +34 -0
  76. package/dist/types/admin/connections/AgentConnectionDrivesDrawer.d.ts +39 -0
  77. package/dist/types/admin/connections/AgentConnectionLevelsDrawer.d.ts +27 -0
  78. package/dist/types/admin/connections/AgentConnectionSharingDialog.d.ts +12 -0
  79. package/dist/types/admin/connections/AgentConnectionsPanel.d.ts +97 -0
  80. package/dist/types/admin/connections/AgentConnectionsScreen.d.ts +18 -0
  81. package/dist/types/admin/connections/ConnectDialogs.d.ts +22 -0
  82. package/dist/types/admin/connections/agent-connection-drive-scope.d.ts +112 -0
  83. package/dist/types/admin/connections/agent-connection-drives.d.ts +107 -0
  84. package/dist/types/admin/connections/agent-connection-format.d.ts +82 -0
  85. package/dist/types/admin/connections/agent-connection-oauth.d.ts +122 -0
  86. package/dist/types/admin/connections/agent-connections-api.d.ts +420 -0
  87. package/dist/types/admin/connections/agent-connections-context.d.ts +60 -0
  88. package/dist/types/admin/connections/agent-connections-types.d.ts +447 -0
  89. package/dist/types/admin/connections/connection-logos.d.ts +53 -0
  90. package/dist/types/admin/connections/connection-parts.d.ts +84 -0
  91. package/dist/types/admin/connections/use-agent-connect.d.ts +25 -0
  92. package/dist/types/admin/context/CompactionThresholdBanner.d.ts +13 -0
  93. package/dist/types/admin/context/ContextCompositionPanel.d.ts +27 -0
  94. package/dist/types/admin/context/ContextSegmentList.d.ts +20 -0
  95. package/dist/types/admin/context/SentPayloadPanel.d.ts +37 -0
  96. package/dist/types/admin/context/agent-inspect-context-api.d.ts +53 -0
  97. package/dist/types/admin/context/agent-inspect-context-types.d.ts +98 -0
  98. package/dist/types/admin/context/context-composition-grouping.d.ts +78 -0
  99. package/dist/types/admin/context/context-segment-families.d.ts +18 -0
  100. package/dist/types/admin/context/context-segment-label-texts.d.ts +19 -0
  101. package/dist/types/admin/context/context-segment-labels.d.ts +18 -0
  102. package/dist/types/admin/control-panel/AgentControlPanelScreen.d.ts +71 -0
  103. package/dist/types/admin/control-panel/BudgetsTab.d.ts +13 -0
  104. package/dist/types/admin/control-panel/SettingsTab.d.ts +22 -0
  105. package/dist/types/admin/control-panel/SpacesTab.d.ts +24 -0
  106. package/dist/types/admin/control-panel/StatisticsTab.d.ts +26 -0
  107. package/dist/types/admin/control-panel/TimeSeriesChartCard.d.ts +37 -0
  108. package/dist/types/admin/control-panel/ToolResponseSamplesDrawer.d.ts +22 -0
  109. package/dist/types/admin/control-panel/agent-control-panel-api.d.ts +104 -0
  110. package/dist/types/admin/control-panel/agent-control-panel-types.d.ts +241 -0
  111. package/dist/types/admin/control-panel/budget-meters.d.ts +35 -0
  112. package/dist/types/admin/control-panel/control-panel-statistics.d.ts +49 -0
  113. package/dist/types/admin/control-panel/runtime-settings-form.d.ts +44 -0
  114. package/dist/types/admin/control-panel/time-series-chart.d.ts +54 -0
  115. package/dist/types/admin/conversations/AgentConversationDetailScreen.d.ts +128 -0
  116. package/dist/types/admin/conversations/AgentConversationsScreen.d.ts +60 -0
  117. package/dist/types/admin/conversations/ContextPanel.d.ts +9 -0
  118. package/dist/types/admin/conversations/ConversationActions.d.ts +32 -0
  119. package/dist/types/admin/conversations/ConversationTurns.d.ts +56 -0
  120. package/dist/types/admin/conversations/DebugSwitchBar.d.ts +23 -0
  121. package/dist/types/admin/conversations/DelegationPanel.d.ts +6 -0
  122. package/dist/types/admin/conversations/ModelContextDialog.d.ts +31 -0
  123. package/dist/types/admin/conversations/RequestCompositionRows.d.ts +14 -0
  124. package/dist/types/admin/conversations/RequestsPanel.d.ts +21 -0
  125. package/dist/types/admin/conversations/SandboxPanel.d.ts +42 -0
  126. package/dist/types/admin/conversations/StepDetailDialog.d.ts +19 -0
  127. package/dist/types/admin/conversations/agent-inspect-api.d.ts +259 -0
  128. package/dist/types/admin/conversations/agent-inspect-mappers.d.ts +23 -0
  129. package/dist/types/admin/conversations/agent-inspect-types.d.ts +517 -0
  130. package/dist/types/admin/conversations/conversation-list-export.d.ts +64 -0
  131. package/dist/types/admin/conversations/conversation-list-filters.d.ts +59 -0
  132. package/dist/types/admin/conversations/debug-switches.d.ts +27 -0
  133. package/dist/types/admin/conversations/delegation-swimlanes.d.ts +78 -0
  134. package/dist/types/admin/conversations/header-facts.d.ts +23 -0
  135. package/dist/types/admin/conversations/inspect-format.d.ts +44 -0
  136. package/dist/types/admin/conversations/inspect-parts.d.ts +42 -0
  137. package/dist/types/admin/conversations/inspect-scope.d.ts +92 -0
  138. package/dist/types/admin/conversations/model-call-rows.d.ts +78 -0
  139. package/dist/types/admin/conversations/step-descriptions.d.ts +43 -0
  140. package/dist/types/admin/conversations/touched-files-tree.d.ts +47 -0
  141. package/dist/types/admin/conversations/turn-paging.d.ts +56 -0
  142. package/dist/types/admin/conversations/turn-segments.d.ts +36 -0
  143. package/dist/types/admin/conversations/turn-timeline.d.ts +22 -0
  144. package/dist/types/admin/conversations/use-query-loader.d.ts +8 -0
  145. package/dist/types/admin/period/AdminPeriodControl.d.ts +15 -0
  146. package/dist/types/admin/period/admin-period.d.ts +51 -0
  147. package/dist/types/admin/quality/AgentQualityEvalRunScreen.d.ts +30 -0
  148. package/dist/types/admin/quality/AgentQualityScreen.d.ts +38 -0
  149. package/dist/types/admin/quality/SaveAsEvalCaseDialog.d.ts +27 -0
  150. package/dist/types/admin/quality/agent-quality-api.d.ts +86 -0
  151. package/dist/types/admin/quality/agent-quality-format.d.ts +52 -0
  152. package/dist/types/admin/quality/agent-quality-types.d.ts +161 -0
  153. package/dist/types/admin/schedules/AgentSchedulesPanel.d.ts +43 -0
  154. package/dist/types/admin/schedules/agent-schedules-api.d.ts +116 -0
  155. package/dist/types/admin/schedules/agent-schedules-format.d.ts +25 -0
  156. package/dist/types/admin/schedules/agent-schedules-types.d.ts +113 -0
  157. package/dist/types/admin/shared/AdminHrefLink.d.ts +13 -0
  158. package/dist/types/admin/skills/AgentSkillCatalogScreen.d.ts +51 -0
  159. package/dist/types/admin/skills/SharedBlocksPanel.d.ts +14 -0
  160. package/dist/types/admin/skills/SkillPurposesPanel.d.ts +16 -0
  161. package/dist/types/admin/skills/SkillTreeRowView.d.ts +31 -0
  162. package/dist/types/admin/skills/ToolSchemaDrawer.d.ts +21 -0
  163. package/dist/types/admin/skills/agent-skill-catalog-api.d.ts +89 -0
  164. package/dist/types/admin/skills/agent-skill-catalog-types.d.ts +223 -0
  165. package/dist/types/admin/skills/skill-catalog-colors.d.ts +10 -0
  166. package/dist/types/admin/skills/skill-catalog-tree.d.ts +159 -0
  167. package/dist/types/admin/skills/skill-purpose-texts.d.ts +11 -0
  168. package/dist/types/admin/wire/admin-wire.d.ts +21 -0
  169. package/dist/types/chat/controller/AgentChatController.d.ts +22 -0
  170. package/dist/types/chat/controller/turn-initiators.d.ts +21 -0
  171. package/dist/types/chat/trace/BackgroundTasksList.d.ts +35 -0
  172. package/dist/types/chat/trace/ChangeSetCard.d.ts +34 -0
  173. package/dist/types/chat/trace/ChangedFilesPane.d.ts +33 -0
  174. package/dist/types/chat/trace/ChangedRecordsList.d.ts +34 -0
  175. package/dist/types/chat/trace/ConsentRequestCard.d.ts +23 -0
  176. package/dist/types/chat/trace/ContextRing.d.ts +19 -0
  177. package/dist/types/chat/trace/ConversationChildTrace.d.ts +18 -0
  178. package/dist/types/chat/trace/ConversationTurnTrace.d.ts +48 -0
  179. package/dist/types/chat/trace/EntityChip.d.ts +23 -0
  180. package/dist/types/chat/trace/FileChangesSummary.d.ts +14 -0
  181. package/dist/types/chat/trace/FileEditBlock.d.ts +42 -0
  182. package/dist/types/chat/trace/LoadedSkillsDisclosure.d.ts +16 -0
  183. package/dist/types/chat/trace/QueuedMessageChip.d.ts +17 -0
  184. package/dist/types/chat/trace/RunStatusLine.d.ts +27 -0
  185. package/dist/types/chat/trace/StepKindDetails.d.ts +59 -0
  186. package/dist/types/chat/trace/SubAgentStepGroup.d.ts +53 -0
  187. package/dist/types/chat/trace/TaskPlanPane.d.ts +31 -0
  188. package/dist/types/chat/trace/TaskPlanRow.d.ts +28 -0
  189. package/dist/types/chat/trace/TerminalBlock.d.ts +16 -0
  190. package/dist/types/chat/trace/ThinkingBlock.d.ts +19 -0
  191. package/dist/types/chat/trace/ToolStepDetail.d.ts +49 -0
  192. package/dist/types/chat/trace/ToolStepGroup.d.ts +58 -0
  193. package/dist/types/chat/trace/ToolStepRow.d.ts +52 -0
  194. package/dist/types/chat/trace/TraceViewModeSwitch.d.ts +14 -0
  195. package/dist/types/chat/trace/TurnMetaLine.d.ts +27 -0
  196. package/dist/types/chat/trace/content-from-unified-diff.d.ts +25 -0
  197. package/dist/types/chat/trace/conversation-trace-loader.d.ts +133 -0
  198. package/dist/types/chat/trace/index.d.ts +34 -0
  199. package/dist/types/chat/trace/parse-unified-diff.d.ts +51 -0
  200. package/dist/types/chat/trace/task-plan-counts.d.ts +41 -0
  201. package/dist/types/chat/trace/trace-collect.d.ts +91 -0
  202. package/dist/types/chat/trace/trace-counts.d.ts +21 -0
  203. package/dist/types/chat/trace/trace-format.d.ts +73 -0
  204. package/dist/types/chat/trace/trace-labels.d.ts +60 -0
  205. package/dist/types/chat/trace/trace-parts.d.ts +63 -0
  206. package/dist/types/chat/trace/trace-step-focus.d.ts +12 -0
  207. package/dist/types/chat/trace/trace-types.d.ts +370 -0
  208. package/dist/types/chat/trace/use-conversation-trace.d.ts +47 -0
  209. package/dist/types/client/AgentsConversationClient.d.ts +20 -0
  210. package/dist/types/client/http/agents-http-trace-mappers.d.ts +31 -0
  211. package/dist/types/client/http/agents-http-trace-wire.d.ts +433 -0
  212. package/dist/types/contract/conversation-trace.d.ts +594 -0
  213. package/dist/types/entries/admin.d.ts +85 -0
  214. package/dist/types/entries/chat.d.ts +3 -1
  215. package/dist/types/entries/client.d.ts +2 -0
  216. package/dist/types/entries/contract.d.ts +1 -0
  217. package/dist/types/provider/components/icon-names.d.ts +4 -2
  218. package/dist/types/provider/components/types.d.ts +3 -1
  219. package/dist/types/widgets/DriveFilesConversationWidget/shared/drive-files.d.ts +1 -1
  220. package/dist/voice.js +3 -3
  221. package/dist/widgets.js +6 -6
  222. package/package.json +7 -3
  223. package/public-api.json +1036 -3
  224. package/dist/chunks/WebSearchResultsConversationWidget-dEq19U7k.js.map +0 -1
  225. package/dist/chunks/icon-names-Di6c4zLo.js.map +0 -1
  226. package/dist/chunks/link-navigation-DRHt6g7U.js.map +0 -1
@@ -0,0 +1,113 @@
1
+ import type { AdminWireChangeHistory, AdminWireSet } from "../wire/admin-wire";
2
+ /** `AIConversationScheduleStatus`. */
3
+ export type AgentScheduleStatus = "ACTIVE" | "PAUSED" | "EXPIRED" | "DONE" | "CANCELLED" | "ARCHIVED";
4
+ /** A schedule as stored (`AIConversationSchedule`), the fields the panel reads. */
5
+ export interface AgentSchedule {
6
+ id: number;
7
+ accountId?: number | null;
8
+ agentSpaceId?: number | null;
9
+ title?: string | null;
10
+ task?: string | null;
11
+ doneCriteria?: string | null;
12
+ /** The cron expression of a recurring schedule, in the schedule's time zone. */
13
+ schedule?: string | null;
14
+ /** The moment of a one-time task (UTC). */
15
+ oneTimeAt?: string | null;
16
+ status?: AgentScheduleStatus | string;
17
+ nextRunAt?: string | null;
18
+ lastFiredAt?: string | null;
19
+ iterationsUsed?: number | null;
20
+ maxIterations?: number | null;
21
+ ttlAt?: string | null;
22
+ failureStreak?: number | null;
23
+ lastFailedAt?: string | null;
24
+ stateReason?: string | null;
25
+ changeHistory?: AdminWireChangeHistory | null;
26
+ }
27
+ /** Where a schedule lives (`AgentSchedulePlace`): `ACCOUNT`, `SPACE`, or a kind the application names. */
28
+ export interface AgentSchedulePlace {
29
+ agentSpaceId?: number | null;
30
+ kind?: string;
31
+ recordId?: number | null;
32
+ name?: string | null;
33
+ }
34
+ /** The newest run of a schedule (`AIConversationScheduleNewestRun`). */
35
+ export interface AgentScheduleNewestRun {
36
+ scheduleId?: number;
37
+ conversationId: number;
38
+ runState?: string | null;
39
+ outcomeExcerpt?: string | null;
40
+ }
41
+ /** One schedule of the list (`AgentScheduleListItem`). */
42
+ export interface AgentScheduleListItem {
43
+ schedule: AgentSchedule;
44
+ place?: AgentSchedulePlace | null;
45
+ /** The account the schedule belongs to. */
46
+ ownerAccountId?: number | null;
47
+ /** How the application names that account; set in the list of every account's schedules only. */
48
+ ownerAccountLabel?: string | null;
49
+ /** The label for its owner: the title, else the start of the task. */
50
+ label?: string;
51
+ isOneTime?: boolean;
52
+ /** The IANA time zone the schedule fires in. */
53
+ timezone?: string;
54
+ canBePaused?: boolean;
55
+ canBeResumed?: boolean;
56
+ canRunNow?: boolean;
57
+ canBeEdited?: boolean;
58
+ newestRun?: AgentScheduleNewestRun | null;
59
+ }
60
+ /** Whose schedules a list holds: the signed-in account's, or every account's (an operator's view the server allows or refuses). */
61
+ export type AgentSchedulesScope = "own" | "all";
62
+ export interface AgentSchedulesArg {
63
+ placeKind?: string;
64
+ recordId?: number;
65
+ /** Omitted = `own`. */
66
+ scope?: AgentSchedulesScope;
67
+ }
68
+ /** `GET {prefix}/list`. */
69
+ export interface AgentSchedulesResponse {
70
+ /** The schedules (`AgentScheduleListItems`, an object set; read through `wireElementsOf`). */
71
+ items?: AdminWireSet<AgentScheduleListItem> | null;
72
+ /** The scope the server answered. */
73
+ scope?: AgentSchedulesScope | string;
74
+ }
75
+ /** One run of a schedule (`AIConversationScheduleRunSummary`). */
76
+ export interface AgentScheduleRun {
77
+ conversationId: number;
78
+ created?: string | null;
79
+ runState?: string;
80
+ title?: string | null;
81
+ outcome?: string | null;
82
+ costInUSD?: number;
83
+ }
84
+ export interface AgentScheduleRunsArg {
85
+ scheduleId: number;
86
+ limit?: number;
87
+ beforeConversationId?: number;
88
+ }
89
+ /** `GET {prefix}/{scheduleId}/runs`. */
90
+ export interface AgentScheduleRunsResponse {
91
+ /** The runs (`AIConversationScheduleRunSummaries`, an object set; read through `wireElementsOf`). */
92
+ runs?: AdminWireSet<AgentScheduleRun> | null;
93
+ }
94
+ export interface AgentScheduleIdArg {
95
+ scheduleId: number;
96
+ }
97
+ /** `POST {prefix}/{scheduleId}/update`: only what is sent is changed. */
98
+ export interface AgentScheduleUpdateArg {
99
+ scheduleId: number;
100
+ title?: string;
101
+ task?: string;
102
+ cronSchedule?: string;
103
+ /** The new moment of a one-time task that has not run, in the schedule's time zone (`YYYY-MM-DD HH:MM`). */
104
+ runAtLocalTime?: string;
105
+ }
106
+ /** The answer of every action on a schedule. */
107
+ export interface AgentScheduleActionResponse {
108
+ item?: AgentScheduleListItem | null;
109
+ /** What a delete did: `HARD_DELETE`, `ARCHIVE` or `KEEP_HISTORY`. */
110
+ actionTaken?: string | null;
111
+ /** The conversation of the run a "run now" started. */
112
+ runConversationId?: number | null;
113
+ }
@@ -0,0 +1,13 @@
1
+ import { type PageLinkComponent } from "@mgamadeus/ddd-admin-ui/primitives";
2
+ import type { ReactNode } from "react";
3
+ export interface AdminHrefLinkProps {
4
+ /** Where the link goes in the host; `null` / absent: the content is drawn as plain text. */
5
+ href?: string | null;
6
+ /** The host's router link; default the provider's, else a plain `<a>`. */
7
+ linkComponent?: PageLinkComponent;
8
+ children: ReactNode;
9
+ className?: string;
10
+ "aria-label"?: string;
11
+ }
12
+ /** A link into a host screen (a conversation, an account, a space), or its content as text when the host names no route. */
13
+ export declare const AdminHrefLink: ({ href, linkComponent, children, className, "aria-label": ariaLabel }: AdminHrefLinkProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,51 @@
1
+ import { type UrlStateAdapter } from "@mgamadeus/ddd-admin-ui/logic";
2
+ import { type ReactNode } from "react";
3
+ import type { AgentSkillCatalogApi } from "./agent-skill-catalog-api";
4
+ import type { AgentSkillCatalogNamespaceGroup } from "./agent-skill-catalog-types";
5
+ export interface AgentSkillCatalogScreenProps {
6
+ /** `createAgentSkillCatalogApi(…)` of the host. */
7
+ api: AgentSkillCatalogApi;
8
+ /** The page title; default "Agent skills". Already translated. */
9
+ title?: ReactNode;
10
+ /** The line under the title; default says what the token counts are. Already translated. */
11
+ description?: ReactNode;
12
+ headerActions?: ReactNode;
13
+ /** The tool whose drawer is open, when the host keeps it (the URL); with it pass `onSelectTool`. */
14
+ selectedToolName?: string | null;
15
+ /** Called with the tool to open, `null` to close. Without `selectedToolName` the screen keeps the tool itself. */
16
+ onSelectTool?: (toolName: string | null) => void;
17
+ /** Draws the markdown of a shared block; default the admin UI's markdown preview for texts of unknown origin. */
18
+ renderMarkdown?: (source: string) => ReactNode;
19
+ /**
20
+ * Where the section (`section`: the skills or the purposes), the period of the usage figures (`period`, `from`,
21
+ * `to`) and, unless `selectedToolName` is given, the open tool (`tool`) live: the host's URL adapter. Without one
22
+ * they live in component state.
23
+ */
24
+ urlStateAdapter?: UrlStateAdapter;
25
+ /**
26
+ * The host's words for a namespace group it configured (name, short and long description: its config is English);
27
+ * a field the host leaves out shows as the server sent it. Already translated.
28
+ */
29
+ describeSkillGroup?: (group: AgentSkillCatalogNamespaceGroup) => {
30
+ name?: string;
31
+ shortDescription?: string;
32
+ description?: string;
33
+ } | null;
34
+ /**
35
+ * The host's description of a purpose it registered (its purpose files are English, written for the model), for the
36
+ * purpose-bound skills and the purposes section; null or empty: the package's words for its own purposes, else the
37
+ * server's. Already translated.
38
+ */
39
+ describeSkillPurpose?: (purposeName: string) => string | null | undefined;
40
+ }
41
+ /** The sections of the screen. */
42
+ export type AgentSkillCatalogSection = "skills" | "purposes";
43
+ /** The URL keys of the screen: the section, the period of the usage figures and the open tool. */
44
+ export declare const AGENT_SKILL_CATALOG_URL_KEYS: readonly ["section", "period", "from", "to", "tool"];
45
+ /**
46
+ * The agent's skill catalog with what each part costs per turn: the totals (general, purpose-bound, all), the general
47
+ * skills by namespace group, the purpose-bound skills by purpose, every skill with its packages and tools, the tool's
48
+ * wire schema in a side sheet, and the blocks the system message carries once. Token counts are estimates of one
49
+ * tokenizer and marked `≈`. The search narrows skills, packages and tools by name and opens what it finds.
50
+ */
51
+ export declare const AgentSkillCatalogScreen: ({ api, title, description, headerActions, selectedToolName, onSelectTool, renderMarkdown, urlStateAdapter, describeSkillGroup, describeSkillPurpose, }: AgentSkillCatalogScreenProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,14 @@
1
+ import type { ReactNode } from "react";
2
+ import type { AgentSkillCatalogApi } from "./agent-skill-catalog-api";
3
+ export interface SharedBlocksPanelProps {
4
+ /** `createAgentSkillCatalogApi(…)` of the host. */
5
+ api: AgentSkillCatalogApi;
6
+ /** Draws a block's markdown; default the admin UI's markdown preview for texts of unknown origin. */
7
+ renderMarkdown?: (source: string) => ReactNode;
8
+ className?: string;
9
+ }
10
+ /**
11
+ * The blocks the system message carries once per turn whatever is loaded (the query-options grammar, the shared
12
+ * request parameters): title, tokens, and the markdown the agent reads on opening one.
13
+ */
14
+ export declare const SharedBlocksPanel: ({ api, renderMarkdown, className }: SharedBlocksPanelProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,16 @@
1
+ import type { AdminPeriod } from "../period/admin-period";
2
+ import type { AgentSkillCatalogApi } from "./agent-skill-catalog-api";
3
+ export interface SkillPurposesPanelProps {
4
+ api: Pick<AgentSkillCatalogApi, "useSkillPurposesQuery">;
5
+ /** The period the runs are counted over. */
6
+ period: Pick<AdminPeriod, "from" | "to">;
7
+ /** The host's description of a purpose it registered (its purpose files are English), already translated; null: the server's. */
8
+ describeSkillPurpose?: (purposeName: string) => string | null | undefined;
9
+ className?: string;
10
+ }
11
+ /**
12
+ * The registered conversation purposes: what each declares (its description, the skills it preloads, the skills it
13
+ * may load, whether the runs of a schedule may start with it) and how it was used in a period (runs started, and the
14
+ * share of them closed as completed).
15
+ */
16
+ export declare const SkillPurposesPanel: ({ api, period, describeSkillPurpose, className }: SkillPurposesPanelProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,31 @@
1
+ import { type FilteredSkillTreeRow } from "./skill-catalog-tree";
2
+ /**
3
+ * The columns of a skill line and of the lines inside it, so figures sit below each other: name, catalog line, total,
4
+ * the bar, tools. Below `md` the catalog line and the bar are left out.
5
+ */
6
+ export declare const SKILL_ROW_GRID_CLASS_NAME = "grid grid-cols-[minmax(0,1fr)_6rem_4.5rem] items-center gap-x-4 md:grid-cols-[minmax(0,1fr)_5.5rem_6.5rem_8rem_4.5rem]";
7
+ /** The same columns with one more at the end from `md`: how often the skill was loaded in a period. */
8
+ export declare const SKILL_ROW_WITH_LOADS_GRID_CLASS_NAME = "grid grid-cols-[minmax(0,1fr)_6rem_4.5rem] items-center gap-x-4 md:grid-cols-[minmax(0,1fr)_5.5rem_6.5rem_8rem_4.5rem_4.5rem]";
9
+ export interface SkillTreeRowViewProps {
10
+ row: FilteredSkillTreeRow;
11
+ /** The key prefix of the section the row sits in (a skill can sit in several sections). */
12
+ sectionKey: string;
13
+ /** The keys of the open skills (`<sectionKey>/<skill name>`). */
14
+ openSkillKeys: ReadonlySet<string>;
15
+ onToggleSkill: (skillKey: string) => void;
16
+ onSelectTool: (toolName: string, skillName: string, packageName: string) => void;
17
+ /** The tool whose drawer is open, marked in its line. */
18
+ selectedToolName?: string | null;
19
+ /**
20
+ * How often each skill was loaded in a period, by skill name: with it every skill line ends with its loads (0 for a
21
+ * skill the map does not name). Absent or `null`: no loads column.
22
+ */
23
+ loadCountBySkillName?: ReadonlyMap<string, number> | null;
24
+ }
25
+ /**
26
+ * One skill of the catalog as a line that opens: its name, what it adds to the catalog block, its own total, the split
27
+ * between instructions and tool definitions as a two-colour bar, its tool count; opened, its packages with their tools
28
+ * (each tool with a bar against the skill's heaviest tool and its tokens; a click opens the tool). The sub-skills of a
29
+ * root sit indented below it, each a line of its own: their tokens are counted beside the root's, never inside.
30
+ */
31
+ export declare const SkillTreeRowView: ({ row, sectionKey, openSkillKeys, onToggleSkill, onSelectTool, selectedToolName, loadCountBySkillName }: SkillTreeRowViewProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,21 @@
1
+ import type { AgentSkillCatalogApi } from "./agent-skill-catalog-api";
2
+ export interface ToolSchemaDrawerProps {
3
+ /** `createAgentSkillCatalogApi(…)` of the host. */
4
+ api: AgentSkillCatalogApi;
5
+ /** The tool shown; `null` closes the drawer. */
6
+ toolName: string | null;
7
+ onClose: () => void;
8
+ /** The skill the tool was opened from; default the skill the documentation names. */
9
+ skillName?: string;
10
+ /** The package the tool was opened from; default the package the documentation names. */
11
+ packageName?: string;
12
+ /** The other skills that expose the same tool. */
13
+ otherSkillNames?: readonly string[];
14
+ }
15
+ /**
16
+ * One tool of the skill catalog in a side sheet: the skill and package that expose it and what its wire schema costs
17
+ * per turn, the tokens of the schema by part (description, every parameter, the structural envelope, shared
18
+ * definitions) as a bar with a legend, the parameters as a table (name, type, required, tokens, description) and the
19
+ * schema exactly as the model receives it (tree, raw, copy).
20
+ */
21
+ export declare const ToolSchemaDrawer: ({ api, toolName, onClose, skillName, packageName, otherSkillNames }: ToolSchemaDrawerProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,89 @@
1
+ import { type ApiQueryHook, type InjectableBaseApi, type InjectedRequest, type StaticQueryFailure } from "@mgamadeus/ddd-admin-ui/logic/pure";
2
+ import type { AgentSkillCatalogResponse, AgentSkillLoadCountsResponse, AgentSkillPurposesResponse, AgentSkillSharedBlocksResponse, AgentSkillToolArg, AgentSkillToolDocumentationResponse, AgentSkillUsageArg } from "./agent-skill-catalog-types";
3
+ /** The cache tag type of the skill catalog reads (ids `CATALOG`, `TOOL`, `SHARED_BLOCKS`, `PURPOSES`, `LOAD_COUNTS`). */
4
+ export declare const AGENT_SKILL_CATALOG_TAG = "AdminUiAgentSkillCatalog";
5
+ /** The hooks `createAgentSkillCatalogApi` returns; `AgentSkillCatalogScreen` takes them as `api`. */
6
+ export interface AgentSkillCatalogApi {
7
+ /** `GET /skills`: totals, every skill with its packages and tools, the namespace and purpose groups. */
8
+ useSkillCatalogQuery: ApiQueryHook<void, AgentSkillCatalogResponse>;
9
+ /** `GET /tools/{toolName}`: one tool's wire schema and where its tokens sit. */
10
+ useSkillToolDocumentationQuery: ApiQueryHook<AgentSkillToolArg, AgentSkillToolDocumentationResponse>;
11
+ /** `GET /sharedBlocks`: the blocks the system prompt carries once per turn. */
12
+ useSkillSharedBlocksQuery: ApiQueryHook<void, AgentSkillSharedBlocksResponse>;
13
+ /** `GET /purposes?from&to`: the registered purposes with their run count and finish rate in a period. */
14
+ useSkillPurposesQuery: ApiQueryHook<AgentSkillUsageArg, AgentSkillPurposesResponse>;
15
+ /** `GET /skillLoadCounts?from&to`: how often the model asked for each skill in a period. */
16
+ useSkillLoadCountsQuery: ApiQueryHook<AgentSkillUsageArg, AgentSkillLoadCountsResponse>;
17
+ }
18
+ export interface CreateAgentSkillCatalogApiOptions {
19
+ /** The host's RTK Query api (`createApi` with the React hooks module). */
20
+ baseApi: InjectableBaseApi;
21
+ /** Where the host mounts the skill catalog routes, without a trailing slash (`/api/admin/ai/skillCatalog`). */
22
+ apiPrefix: string;
23
+ }
24
+ /** The request of every operation, on `apiPrefix`. Pure: no RTK runtime. */
25
+ export declare const buildAgentSkillCatalogRequests: (apiPrefix: string) => {
26
+ skills: () => InjectedRequest;
27
+ tool: ({ toolName }: AgentSkillToolArg) => InjectedRequest;
28
+ sharedBlocks: () => InjectedRequest;
29
+ purposes: (arg?: AgentSkillUsageArg) => InjectedRequest;
30
+ skillLoadCounts: (arg?: AgentSkillUsageArg) => InjectedRequest;
31
+ };
32
+ /** The operations as injected. */
33
+ export declare const agentSkillCatalogEndpointDefinitions: (apiPrefix: string) => {
34
+ readonly adminUiAgentSkillCatalog: {
35
+ readonly kind: "query";
36
+ readonly request: () => InjectedRequest;
37
+ readonly providesTags: readonly [{
38
+ readonly type: "AdminUiAgentSkillCatalog";
39
+ readonly id: "CATALOG";
40
+ }];
41
+ };
42
+ readonly adminUiAgentSkillToolDocumentation: {
43
+ readonly kind: "query";
44
+ readonly request: ({ toolName }: AgentSkillToolArg) => InjectedRequest;
45
+ readonly providesTags: readonly [{
46
+ readonly type: "AdminUiAgentSkillCatalog";
47
+ readonly id: "TOOL";
48
+ }];
49
+ };
50
+ readonly adminUiAgentSkillSharedBlocks: {
51
+ readonly kind: "query";
52
+ readonly request: () => InjectedRequest;
53
+ readonly providesTags: readonly [{
54
+ readonly type: "AdminUiAgentSkillCatalog";
55
+ readonly id: "SHARED_BLOCKS";
56
+ }];
57
+ };
58
+ readonly adminUiAgentSkillPurposes: {
59
+ readonly kind: "query";
60
+ readonly request: (arg?: AgentSkillUsageArg) => InjectedRequest;
61
+ readonly providesTags: readonly [{
62
+ readonly type: "AdminUiAgentSkillCatalog";
63
+ readonly id: "PURPOSES";
64
+ }];
65
+ };
66
+ readonly adminUiAgentSkillLoadCounts: {
67
+ readonly kind: "query";
68
+ readonly request: (arg?: AgentSkillUsageArg) => InjectedRequest;
69
+ readonly providesTags: readonly [{
70
+ readonly type: "AdminUiAgentSkillCatalog";
71
+ readonly id: "LOAD_COUNTS";
72
+ }];
73
+ };
74
+ };
75
+ /**
76
+ * Injects the skill catalog reads into the host's RTK Query api and returns their hooks. Call it once at module scope:
77
+ * `export const agentSkillCatalogApi = createAgentSkillCatalogApi({ baseApi: adminApi, apiPrefix: "/api/admin/ai/skillCatalog" });`
78
+ */
79
+ export declare const createAgentSkillCatalogApi: ({ baseApi, apiPrefix }: CreateAgentSkillCatalogApiOptions) => AgentSkillCatalogApi;
80
+ /** Fixed answers of a `createStaticAgentSkillCatalogApi`; a query without one stays loading. */
81
+ export interface StaticAgentSkillCatalogData {
82
+ skills?: () => AgentSkillCatalogResponse | StaticQueryFailure | undefined;
83
+ tool?: (arg: AgentSkillToolArg) => AgentSkillToolDocumentationResponse | StaticQueryFailure | undefined;
84
+ sharedBlocks?: () => AgentSkillSharedBlocksResponse | StaticQueryFailure | undefined;
85
+ purposes?: (arg: AgentSkillUsageArg) => AgentSkillPurposesResponse | StaticQueryFailure | undefined;
86
+ skillLoadCounts?: (arg: AgentSkillUsageArg) => AgentSkillLoadCountsResponse | StaticQueryFailure | undefined;
87
+ }
88
+ /** An `AgentSkillCatalogApi` answering fixed payloads, without a store or a request (previews, tests, reviews). */
89
+ export declare const createStaticAgentSkillCatalogApi: (data: StaticAgentSkillCatalogData) => AgentSkillCatalogApi;
@@ -0,0 +1,223 @@
1
+ import type { AdminWireSet } from "../wire/admin-wire";
2
+ /**
3
+ * Tokens by name as they arrive: a map (`{ query: 47, mode: 45 }`), an empty list for an empty map, or a list of
4
+ * `{ name, tokens }`. Read it through `normalizeSkillTokenEntries`.
5
+ */
6
+ export type AgentSkillTokenMap = Readonly<Record<string, number>> | readonly AgentSkillTokenEntry[] | readonly never[];
7
+ /** One named token count (a parameter or a shared definition of a tool). */
8
+ export interface AgentSkillTokenEntry {
9
+ name: string;
10
+ tokens: number;
11
+ }
12
+ /** Where a tool's wire-schema tokens sit (`AISkillCatalogToolComponents`). */
13
+ export interface AgentSkillCatalogToolComponents {
14
+ total?: number;
15
+ /** Tokens of the tool description. */
16
+ description?: number;
17
+ /** Tokens per input parameter. */
18
+ parameters?: AgentSkillTokenMap | null;
19
+ /** The same per parameter as a set of `{ name, tokens }` (`AISkillCatalogTokenCounts`); a plain list from an older backend. */
20
+ parameterTokens?: AdminWireSet<AgentSkillTokenEntry> | null;
21
+ /** Tokens per shared `$def`. */
22
+ defs?: AgentSkillTokenMap | null;
23
+ /** The same per shared `$def` as a set of `{ name, tokens }`; a plain list from an older backend. */
24
+ defTokens?: AdminWireSet<AgentSkillTokenEntry> | null;
25
+ /** Structural remainder (name, types, required, wrappers). */
26
+ envelope?: number;
27
+ }
28
+ /** One tool of a package (`AISkillCatalogTool`); `components` is null for a package whose reflection failed. */
29
+ export interface AgentSkillCatalogTool {
30
+ name: string;
31
+ tokens?: number;
32
+ components?: AgentSkillCatalogToolComponents | null;
33
+ }
34
+ /** One tool package of a skill (`AISkillCatalogPackage`). */
35
+ export interface AgentSkillCatalogPackage {
36
+ name: string;
37
+ total?: number;
38
+ toolCount?: number;
39
+ tools?: AgentSkillCatalogTool[] | null;
40
+ }
41
+ /** One skill (`AISkillCatalogEntry`). */
42
+ export interface AgentSkillCatalogEntry {
43
+ /** The dotted skill name. */
44
+ name: string;
45
+ /** Instruction tokens plus tool-definition tokens of this skill alone (sub-skills count separately). */
46
+ total?: number;
47
+ instructionTokens?: number;
48
+ toolDefTokens?: number;
49
+ toolCount?: number;
50
+ packages?: AgentSkillCatalogPackage[] | null;
51
+ /** True: offered only while one of its roots is loaded. */
52
+ isSubSkill?: boolean;
53
+ /** A root's sub-skills. */
54
+ subSkillNames?: string[] | null;
55
+ /** Tokens of the skill's line in the system prompt's catalog. */
56
+ catalogLineTokens?: number;
57
+ onlyUnderPurposeNames?: string[] | null;
58
+ notUnderPurposeNames?: string[] | null;
59
+ /** True: never offered in an open conversation, only under its purposes. */
60
+ isPurposeBound?: boolean;
61
+ offeredUnderPurposeNames?: string[] | null;
62
+ /** True: pinned into every conversation from its start (no catalog line, part of the base load). */
63
+ isBaseSkill?: boolean;
64
+ }
65
+ /** The figures every skill group carries (`AISkillCatalogSkillGroup`). */
66
+ export interface AgentSkillCatalogSkillGroup {
67
+ skillNames?: string[] | null;
68
+ rootSkillCount?: number;
69
+ subSkillCount?: number;
70
+ toolCount?: number;
71
+ catalogTokens?: number;
72
+ instructionTokens?: number;
73
+ uniqueToolDefTokens?: number;
74
+ sumOfSkillTotals?: number;
75
+ }
76
+ /** A namespace group of the general skills (`AISkillCatalogNamespaceGroup`). */
77
+ export interface AgentSkillCatalogNamespaceGroup extends AgentSkillCatalogSkillGroup {
78
+ name: string;
79
+ /** `domain`, `common`, `agent` or `ungrouped`. */
80
+ kind?: string;
81
+ shortDescription?: string;
82
+ description?: string;
83
+ isUngrouped?: boolean;
84
+ }
85
+ /** The purpose-bound skills of one conversation purpose (`AISkillCatalogPurposeGroup`). */
86
+ export interface AgentSkillCatalogPurposeGroup extends AgentSkillCatalogSkillGroup {
87
+ purposeName: string;
88
+ description?: string;
89
+ /** False: a skill names the purpose, but no purpose definition exists. */
90
+ isDefined?: boolean;
91
+ preloadSkillNames?: string[] | null;
92
+ allowedLoadSkillNames?: string[] | null;
93
+ }
94
+ /** The catalog-wide totals (`AISkillCatalogTotals`). */
95
+ export interface AgentSkillCatalogTotals {
96
+ skillCount?: number;
97
+ packageCount?: number;
98
+ uniquePackageCount?: number;
99
+ toolCount?: number;
100
+ uniqueToolCount?: number;
101
+ sumOfSkillTotals?: number;
102
+ instructionTokens?: number;
103
+ uniqueToolDefTokens?: number;
104
+ rootSkillCount?: number;
105
+ subSkillCount?: number;
106
+ rootCatalogTokens?: number;
107
+ generalRootSkillCount?: number;
108
+ generalSubSkillCount?: number;
109
+ generalToolCount?: number;
110
+ generalInstructionTokens?: number;
111
+ generalSumOfSkillTotals?: number;
112
+ purposeBoundRootSkillCount?: number;
113
+ purposeBoundSubSkillCount?: number;
114
+ purposeBoundToolCount?: number;
115
+ purposeBoundCatalogTokens?: number;
116
+ purposeBoundInstructionTokens?: number;
117
+ purposeBoundSumOfSkillTotals?: number;
118
+ purposeCount?: number;
119
+ /** Base skills: pinned into every conversation, not in `rootCatalogTokens`. */
120
+ baseSkillCount?: number;
121
+ baseToolCount?: number;
122
+ baseInstructionTokens?: number;
123
+ /** Instruction blocks + tool definitions of the base skills: part of every conversation's base load. */
124
+ baseSkillTokens?: number;
125
+ }
126
+ /** The whole skill catalog (`AISkillCatalog`). */
127
+ export interface AgentSkillCatalog {
128
+ totals?: AgentSkillCatalogTotals | null;
129
+ /** Every skill, general and purpose-bound, heaviest first. */
130
+ skills?: AgentSkillCatalogEntry[] | null;
131
+ purposeGroups?: AgentSkillCatalogPurposeGroup[] | null;
132
+ /** The general skills by namespace, in configuration order, an "Ungrouped" group last. */
133
+ namespaceGroups?: AgentSkillCatalogNamespaceGroup[] | null;
134
+ }
135
+ /** The documentation of one tool (`AISkillToolDocumentation`). */
136
+ export interface AgentSkillToolDocumentation {
137
+ name: string;
138
+ /** The skill that exposes the tool. */
139
+ skill?: string;
140
+ /** The package that provides it. */
141
+ package?: string;
142
+ /** Tokens of the tool's wire schema, paid every turn the tool is loaded. */
143
+ tokens?: number;
144
+ components?: AgentSkillCatalogToolComponents | null;
145
+ /** The tool schema as the model receives it (`{ type: "function", function: { name, description, parameters } }`). */
146
+ openAiToolSchema?: unknown;
147
+ }
148
+ /** One block the system prompt carries once per turn (`AISkillCatalogSharedBlock`). */
149
+ export interface AgentSkillCatalogSharedBlock {
150
+ key: string;
151
+ title?: string;
152
+ tokens?: number;
153
+ markdown?: string;
154
+ }
155
+ /** `GET {prefix}/skills`. */
156
+ export interface AgentSkillCatalogResponse {
157
+ catalog?: AgentSkillCatalog | null;
158
+ }
159
+ export interface AgentSkillToolArg {
160
+ toolName: string;
161
+ }
162
+ /** `GET {prefix}/tools/{toolName}`. */
163
+ export interface AgentSkillToolDocumentationResponse {
164
+ documentation?: AgentSkillToolDocumentation | null;
165
+ }
166
+ /** `GET {prefix}/sharedBlocks`: the blocks as a set (`blocks`) or as a plain list. */
167
+ export interface AgentSkillSharedBlocksResponse {
168
+ sharedBlocks?: {
169
+ blocks?: AgentSkillCatalogSharedBlock[] | null;
170
+ } | AgentSkillCatalogSharedBlock[] | null;
171
+ }
172
+ /** The period of a usage read of the skill catalog (purposes, skill loads): two inclusive days, `YYYY-MM-DD`. */
173
+ export interface AgentSkillUsageArg {
174
+ from?: string;
175
+ to?: string;
176
+ }
177
+ /** One registered purpose with its runs of a period (`AISkillCatalogPurposeUsage`). */
178
+ export interface AgentSkillPurposeUsage {
179
+ purposeName: string;
180
+ description?: string;
181
+ /** False: the name is registered, but no purpose definition loads for it. */
182
+ isDefined?: boolean;
183
+ preloadSkillNames?: string[] | null;
184
+ /** The purpose's load rail; empty = the full entitled catalog. */
185
+ allowedLoadSkillNames?: string[] | null;
186
+ /** Whether the runs of a schedule may start with this purpose. */
187
+ isScheduleRunPurpose?: boolean;
188
+ /** Root conversations started with the purpose in the period. */
189
+ runCount?: number;
190
+ /** Of them, the ones closed as completed. */
191
+ finishedRunCount?: number;
192
+ /** Finished runs per run, 0 to 1; null without a run. */
193
+ finishRate?: number | null;
194
+ }
195
+ /** `GET {prefix}/purposes`. */
196
+ export interface AgentSkillPurposesResponse {
197
+ rangeFrom?: string;
198
+ rangeTo?: string;
199
+ /** The purposes (`AISkillCatalogPurposeUsages`, an object set; read through `wireElementsOf`). */
200
+ purposes?: AdminWireSet<AgentSkillPurposeUsage> | null;
201
+ }
202
+ /** How often one skill was asked for through the skill-loading tool (`AISkillCatalogSkillLoadCount`). */
203
+ export interface AgentSkillLoadCount {
204
+ skillName: string;
205
+ loadCount?: number;
206
+ }
207
+ /** The loads of a period (`AISkillCatalogSkillLoadCounts`, an object set): the loads the model asked for, not the preloads. */
208
+ export interface AgentSkillLoadCounts {
209
+ /** The skills, the most loaded first. */
210
+ elements?: readonly AgentSkillLoadCount[] | null;
211
+ /** The calls of the skill-loading tool that were counted. */
212
+ countedCallCount?: number;
213
+ /** True: the period holds more calls than one read counts; the newest were counted. */
214
+ isTruncated?: boolean;
215
+ }
216
+ /** `GET {prefix}/skillLoadCounts`. */
217
+ export interface AgentSkillLoadCountsResponse {
218
+ rangeFrom?: string;
219
+ rangeTo?: string;
220
+ /** False: the generated tool columns of the message table are missing on this database. */
221
+ isLoadCountDataAvailable?: boolean;
222
+ loadCounts?: AgentSkillLoadCounts | null;
223
+ }
@@ -0,0 +1,10 @@
1
+ import type { SkillToolTokenPartKind } from "./skill-catalog-tree";
2
+ /** The fill of a skill's instruction tokens (the hue of the skills family of the context composition). */
3
+ export declare const SKILL_INSTRUCTIONS_FILL_CLASS_NAME: string;
4
+ /** The fill of tool-definition tokens (the neutral of the tool schemas of the context composition). */
5
+ export declare const SKILL_TOOL_DEFINITIONS_FILL_CLASS_NAME: string;
6
+ /**
7
+ * The fill of a part of a tool's wire schema: one hue per kind of part; parameters and definitions, of which a tool
8
+ * has many, take their hue's steps in turn (`positionInKind`, 0-based).
9
+ */
10
+ export declare const skillToolTokenPartFillClassNameOf: (kind: SkillToolTokenPartKind, positionInKind?: number) => string;