@datalayer/agent-runtimes 0.0.9 → 0.0.11

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 (291) hide show
  1. package/README.md +2 -1
  2. package/lib/{examples/components → components}/AgentConfiguration.d.ts +54 -9
  3. package/lib/components/AgentConfiguration.js +585 -0
  4. package/lib/{examples/components → components}/FooterMetrics.d.ts +1 -2
  5. package/lib/{examples/components → components}/Header.d.ts +1 -6
  6. package/lib/{examples/components → components}/Header.js +5 -39
  7. package/lib/{examples/components → components}/HeaderControls.d.ts +1 -2
  8. package/lib/{examples/components → components}/HeaderControls.js +1 -1
  9. package/lib/{examples/components → components}/LexicalEditor.d.ts +2 -3
  10. package/lib/{examples/components → components}/LexicalEditor.js +2 -2
  11. package/lib/components/MainContent.d.ts +34 -0
  12. package/lib/{examples/components → components}/MainContent.js +18 -9
  13. package/lib/components/McpServerManager.d.ts +30 -0
  14. package/lib/components/McpServerManager.js +331 -0
  15. package/lib/{examples/components → components}/MockFileBrowser.d.ts +1 -2
  16. package/lib/{examples/components → components}/SessionTabs.d.ts +2 -3
  17. package/lib/{examples/components → components}/TimeTravel.d.ts +1 -2
  18. package/lib/components/chat/components/AgentDetails.d.ts +3 -1
  19. package/lib/components/chat/components/AgentDetails.js +472 -22
  20. package/lib/components/chat/components/Chat.d.ts +37 -3
  21. package/lib/components/chat/components/Chat.js +29 -10
  22. package/lib/components/chat/components/ChatFloating.d.ts +27 -2
  23. package/lib/components/chat/components/ChatFloating.js +17 -10
  24. package/lib/components/chat/components/ChatPopupStandalone.js +1 -1
  25. package/lib/components/chat/components/ChatSidebar.d.ts +1 -1
  26. package/lib/components/chat/components/ChatStandalone.d.ts +1 -1
  27. package/lib/components/chat/components/ChatStandalone.js +1 -1
  28. package/lib/components/chat/components/ContextDistribution.d.ts +70 -6
  29. package/lib/components/chat/components/ContextDistribution.js +13 -6
  30. package/lib/components/chat/components/ContextInspector.d.ts +81 -0
  31. package/lib/components/chat/components/ContextInspector.js +263 -0
  32. package/lib/components/chat/components/ContextPanel.d.ts +112 -0
  33. package/lib/components/chat/components/ContextPanel.js +368 -0
  34. package/lib/components/chat/components/base/ChatBase.d.ts +74 -19
  35. package/lib/components/chat/components/base/ChatBase.js +296 -37
  36. package/lib/components/chat/components/index.d.ts +3 -1
  37. package/lib/components/chat/components/index.js +2 -0
  38. package/lib/components/chat/extensions/ExtensionRegistry.d.ts +1 -1
  39. package/lib/components/chat/extensions/index.d.ts +1 -0
  40. package/lib/components/chat/index.d.ts +3 -3
  41. package/lib/components/chat/protocols/AGUIAdapter.js +24 -4
  42. package/lib/components/chat/protocols/VercelAIAdapter.js +35 -1
  43. package/lib/components/chat/store/chatStore.d.ts +2 -3
  44. package/lib/components/chat/store/conversationStore.d.ts +83 -0
  45. package/lib/components/chat/store/conversationStore.js +174 -0
  46. package/lib/components/chat/store/index.d.ts +2 -1
  47. package/lib/components/chat/store/index.js +1 -0
  48. package/lib/components/chat/types/inference.d.ts +17 -0
  49. package/lib/components/chat/types/protocol.d.ts +10 -0
  50. package/lib/components/index.d.ts +23 -0
  51. package/lib/components/index.js +11 -0
  52. package/lib/config/agents/code-ai/agents.d.ts +25 -0
  53. package/lib/config/agents/code-ai/agents.js +70 -0
  54. package/lib/config/agents/code-ai/index.d.ts +1 -0
  55. package/lib/config/agents/code-ai/index.js +5 -0
  56. package/lib/config/agents/codemode-paper/agents.d.ts +29 -0
  57. package/lib/config/agents/codemode-paper/agents.js +288 -0
  58. package/lib/config/agents/codemode-paper/index.d.ts +1 -0
  59. package/lib/config/agents/codemode-paper/index.js +5 -0
  60. package/lib/config/agents/datalayer-ai/agents.d.ts +29 -0
  61. package/lib/config/agents/datalayer-ai/agents.js +267 -0
  62. package/lib/config/agents/datalayer-ai/index.d.ts +1 -0
  63. package/lib/config/agents/datalayer-ai/index.js +5 -0
  64. package/lib/config/agents/index.d.ts +19 -0
  65. package/lib/config/agents/index.js +38 -0
  66. package/lib/config/envvars.d.ts +28 -0
  67. package/lib/config/envvars.js +115 -0
  68. package/lib/config/index.d.ts +5 -0
  69. package/lib/config/index.js +9 -0
  70. package/lib/config/mcpServers.d.ts +18 -0
  71. package/lib/config/mcpServers.js +153 -0
  72. package/lib/config/skills.d.ts +27 -0
  73. package/lib/config/skills.js +60 -0
  74. package/lib/{lib → config}/utils.d.ts +1 -1
  75. package/lib/{lib → config}/utils.js +2 -2
  76. package/lib/examples/AgentRuntimeLexical2Example.d.ts +1 -0
  77. package/lib/examples/AgentRuntimeLexical2Example.js +3 -2
  78. package/lib/examples/AgentRuntimeLexicalExample.d.ts +1 -0
  79. package/lib/examples/AgentRuntimeLexicalExample.js +5 -3
  80. package/lib/examples/AgentRuntimeLexicalSidebarExample.d.ts +1 -0
  81. package/lib/examples/AgentRuntimeLexicalSidebarExample.js +3 -3
  82. package/lib/examples/AgentRuntimeNotebookExample.js +1 -1
  83. package/lib/examples/AgentSpaceFormExample.d.ts +2 -2
  84. package/lib/examples/AgentSpaceFormExample.js +215 -35
  85. package/lib/examples/CopilotKitLexicalExample.d.ts +1 -0
  86. package/lib/examples/CopilotKitLexicalExample.js +3 -2
  87. package/lib/examples/index.d.ts +1 -0
  88. package/lib/examples/stores/notebooks/NotebookExample2.ipynb.json +43 -43
  89. package/lib/hooks/useAGUI.d.ts +1 -1
  90. package/lib/hooks/useAGUI.js +1 -1
  91. package/lib/identity/types.d.ts +1 -1
  92. package/lib/index.d.ts +2 -0
  93. package/lib/index.js +1 -0
  94. package/lib/runtime/index.d.ts +3 -0
  95. package/lib/runtime/runtimeStore.d.ts +3 -4
  96. package/lib/runtime/useAgentConnection.d.ts +2 -3
  97. package/lib/runtime/useAgentRuntime.d.ts +2 -3
  98. package/lib/stories/Cell.stories.js +1 -1
  99. package/lib/tools/adapters/agent-runtimes/notebookHooks.js +1 -0
  100. package/lib/tools/adapters/copilotkit/notebookHooks.js +1 -0
  101. package/lib/types.d.ts +158 -0
  102. package/package.json +5 -6
  103. package/scripts/apply-patches.sh +1 -1
  104. package/scripts/codegen/generate_agents.py +863 -0
  105. package/scripts/codegen/generate_envvars.py +302 -0
  106. package/scripts/codegen/generate_mcp_servers.py +436 -0
  107. package/scripts/codegen/generate_skills.py +334 -0
  108. package/scripts/download-ai-elements.py +35 -20
  109. package/scripts/sync-jupyter.sh +6 -0
  110. package/lib/components/ui/accordion.d.ts +0 -7
  111. package/lib/components/ui/accordion.js +0 -22
  112. package/lib/components/ui/alert-dialog.d.ts +0 -14
  113. package/lib/components/ui/alert-dialog.js +0 -43
  114. package/lib/components/ui/alert.d.ts +0 -9
  115. package/lib/components/ui/alert.js +0 -24
  116. package/lib/components/ui/aspect-ratio.d.ts +0 -3
  117. package/lib/components/ui/aspect-ratio.js +0 -11
  118. package/lib/components/ui/avatar.d.ts +0 -6
  119. package/lib/components/ui/avatar.js +0 -18
  120. package/lib/components/ui/badge.d.ts +0 -9
  121. package/lib/components/ui/badge.js +0 -22
  122. package/lib/components/ui/breadcrumb.d.ts +0 -11
  123. package/lib/components/ui/breadcrumb.js +0 -27
  124. package/lib/components/ui/button-group.d.ts +0 -11
  125. package/lib/components/ui/button-group.js +0 -31
  126. package/lib/components/ui/button.d.ts +0 -13
  127. package/lib/components/ui/button.js +0 -39
  128. package/lib/components/ui/calendar.d.ts +0 -8
  129. package/lib/components/ui/calendar.js +0 -80
  130. package/lib/components/ui/card.d.ts +0 -9
  131. package/lib/components/ui/card.js +0 -24
  132. package/lib/components/ui/carousel.d.ts +0 -19
  133. package/lib/components/ui/carousel.js +0 -95
  134. package/lib/components/ui/chart.d.ts +0 -53
  135. package/lib/components/ui/chart.js +0 -136
  136. package/lib/components/ui/checkbox.d.ts +0 -4
  137. package/lib/components/ui/checkbox.js +0 -13
  138. package/lib/components/ui/collapsible.d.ts +0 -5
  139. package/lib/components/ui/collapsible.js +0 -17
  140. package/lib/components/ui/command.d.ts +0 -18
  141. package/lib/components/ui/command.js +0 -38
  142. package/lib/components/ui/context-menu.d.ts +0 -25
  143. package/lib/components/ui/context-menu.js +0 -55
  144. package/lib/components/ui/dialog.d.ts +0 -15
  145. package/lib/components/ui/dialog.js +0 -40
  146. package/lib/components/ui/drawer.d.ts +0 -13
  147. package/lib/components/ui/drawer.js +0 -39
  148. package/lib/components/ui/dropdown-menu.d.ts +0 -25
  149. package/lib/components/ui/dropdown-menu.js +0 -55
  150. package/lib/components/ui/empty.d.ts +0 -11
  151. package/lib/components/ui/empty.js +0 -37
  152. package/lib/components/ui/field.d.ts +0 -24
  153. package/lib/components/ui/field.js +0 -80
  154. package/lib/components/ui/form.d.ts +0 -24
  155. package/lib/components/ui/form.js +0 -63
  156. package/lib/components/ui/hover-card.d.ts +0 -6
  157. package/lib/components/ui/hover-card.js +0 -18
  158. package/lib/components/ui/input-group.d.ts +0 -19
  159. package/lib/components/ui/input-group.js +0 -69
  160. package/lib/components/ui/input-otp.d.ts +0 -11
  161. package/lib/components/ui/input-otp.js +0 -25
  162. package/lib/components/ui/input.d.ts +0 -3
  163. package/lib/components/ui/input.js +0 -6
  164. package/lib/components/ui/item.d.ts +0 -23
  165. package/lib/components/ui/item.js +0 -66
  166. package/lib/components/ui/kbd.d.ts +0 -3
  167. package/lib/components/ui/kbd.js +0 -13
  168. package/lib/components/ui/label.d.ts +0 -4
  169. package/lib/components/ui/label.js +0 -12
  170. package/lib/components/ui/menubar.d.ts +0 -26
  171. package/lib/components/ui/menubar.js +0 -58
  172. package/lib/components/ui/navigation-menu.d.ts +0 -14
  173. package/lib/components/ui/navigation-menu.js +0 -31
  174. package/lib/components/ui/pagination.d.ts +0 -13
  175. package/lib/components/ui/pagination.js +0 -29
  176. package/lib/components/ui/popover.d.ts +0 -7
  177. package/lib/components/ui/popover.js +0 -21
  178. package/lib/components/ui/progress.d.ts +0 -4
  179. package/lib/components/ui/progress.js +0 -12
  180. package/lib/components/ui/radio-group.d.ts +0 -5
  181. package/lib/components/ui/radio-group.js +0 -16
  182. package/lib/components/ui/resizable.d.ts +0 -8
  183. package/lib/components/ui/resizable.js +0 -19
  184. package/lib/components/ui/scroll-area.d.ts +0 -5
  185. package/lib/components/ui/scroll-area.js +0 -17
  186. package/lib/components/ui/select.d.ts +0 -15
  187. package/lib/components/ui/select.js +0 -42
  188. package/lib/components/ui/separator.d.ts +0 -4
  189. package/lib/components/ui/separator.js +0 -12
  190. package/lib/components/ui/sheet.d.ts +0 -13
  191. package/lib/components/ui/sheet.js +0 -44
  192. package/lib/components/ui/sidebar.d.ts +0 -69
  193. package/lib/components/ui/sidebar.js +0 -216
  194. package/lib/components/ui/skeleton.d.ts +0 -2
  195. package/lib/components/ui/skeleton.js +0 -10
  196. package/lib/components/ui/slider.d.ts +0 -4
  197. package/lib/components/ui/slider.js +0 -18
  198. package/lib/components/ui/sonner.d.ts +0 -3
  199. package/lib/components/ui/sonner.js +0 -25
  200. package/lib/components/ui/spinner.d.ts +0 -2
  201. package/lib/components/ui/spinner.js +0 -11
  202. package/lib/components/ui/switch.d.ts +0 -4
  203. package/lib/components/ui/switch.js +0 -12
  204. package/lib/components/ui/table.d.ts +0 -10
  205. package/lib/components/ui/table.js +0 -32
  206. package/lib/components/ui/tabs.d.ts +0 -7
  207. package/lib/components/ui/tabs.js +0 -21
  208. package/lib/components/ui/textarea.d.ts +0 -3
  209. package/lib/components/ui/textarea.js +0 -6
  210. package/lib/components/ui/toast.d.ts +0 -15
  211. package/lib/components/ui/toast.js +0 -38
  212. package/lib/components/ui/toaster.d.ts +0 -1
  213. package/lib/components/ui/toaster.js +0 -14
  214. package/lib/components/ui/toggle-group.d.ts +0 -9
  215. package/lib/components/ui/toggle-group.js +0 -26
  216. package/lib/components/ui/toggle.d.ts +0 -9
  217. package/lib/components/ui/toggle.js +0 -30
  218. package/lib/components/ui/tooltip.d.ts +0 -7
  219. package/lib/components/ui/tooltip.js +0 -21
  220. package/lib/components/vercel-ai-elements/artifact.d.ts +0 -23
  221. package/lib/components/vercel-ai-elements/artifact.js +0 -24
  222. package/lib/components/vercel-ai-elements/code-block.d.ts +0 -17
  223. package/lib/components/vercel-ai-elements/code-block.js +0 -94
  224. package/lib/components/vercel-ai-elements/conversation.d.ts +0 -15
  225. package/lib/components/vercel-ai-elements/conversation.js +0 -21
  226. package/lib/components/vercel-ai-elements/loader.d.ts +0 -5
  227. package/lib/components/vercel-ai-elements/loader.js +0 -8
  228. package/lib/components/vercel-ai-elements/message.d.ts +0 -46
  229. package/lib/components/vercel-ai-elements/message.js +0 -109
  230. package/lib/components/vercel-ai-elements/model-selector.d.ts +0 -35
  231. package/lib/components/vercel-ai-elements/model-selector.js +0 -22
  232. package/lib/components/vercel-ai-elements/prompt-input.d.ts +0 -195
  233. package/lib/components/vercel-ai-elements/prompt-input.js +0 -589
  234. package/lib/components/vercel-ai-elements/reasoning.d.ts +0 -26
  235. package/lib/components/vercel-ai-elements/reasoning.js +0 -80
  236. package/lib/components/vercel-ai-elements/shimmer.d.ts +0 -9
  237. package/lib/components/vercel-ai-elements/shimmer.js +0 -22
  238. package/lib/components/vercel-ai-elements/sources.d.ts +0 -12
  239. package/lib/components/vercel-ai-elements/sources.js +0 -13
  240. package/lib/components/vercel-ai-elements/suggestion.d.ts +0 -10
  241. package/lib/components/vercel-ai-elements/suggestion.js +0 -16
  242. package/lib/components/vercel-ai-elements/tool.d.ts +0 -23
  243. package/lib/components/vercel-ai-elements/tool.js +0 -52
  244. package/lib/examples/components/AgentConfiguration.js +0 -382
  245. package/lib/examples/components/MainContent.d.ts +0 -19
  246. package/lib/examples/components/index.d.ts +0 -10
  247. package/lib/examples/components/index.js +0 -13
  248. package/lib/examples/vercel-ai-elements/VercelAiElementsShowcase.d.ts +0 -12
  249. package/lib/examples/vercel-ai-elements/VercelAiElementsShowcase.js +0 -69
  250. package/lib/examples/vercel-ai-elements/components/ArtifactShowcase.d.ts +0 -1
  251. package/lib/examples/vercel-ai-elements/components/ArtifactShowcase.js +0 -85
  252. package/lib/examples/vercel-ai-elements/components/CodeBlockShowcase.d.ts +0 -1
  253. package/lib/examples/vercel-ai-elements/components/CodeBlockShowcase.js +0 -62
  254. package/lib/examples/vercel-ai-elements/components/ConversationShowcase.d.ts +0 -1
  255. package/lib/examples/vercel-ai-elements/components/ConversationShowcase.js +0 -51
  256. package/lib/examples/vercel-ai-elements/components/LoaderShowcase.d.ts +0 -1
  257. package/lib/examples/vercel-ai-elements/components/LoaderShowcase.js +0 -9
  258. package/lib/examples/vercel-ai-elements/components/MessageShowcase.d.ts +0 -1
  259. package/lib/examples/vercel-ai-elements/components/MessageShowcase.js +0 -56
  260. package/lib/examples/vercel-ai-elements/components/ModelSelectorShowcase.d.ts +0 -1
  261. package/lib/examples/vercel-ai-elements/components/ModelSelectorShowcase.js +0 -50
  262. package/lib/examples/vercel-ai-elements/components/PromptInputShowcase.d.ts +0 -1
  263. package/lib/examples/vercel-ai-elements/components/PromptInputShowcase.js +0 -16
  264. package/lib/examples/vercel-ai-elements/components/ReasoningShowcase.d.ts +0 -1
  265. package/lib/examples/vercel-ai-elements/components/ReasoningShowcase.js +0 -72
  266. package/lib/examples/vercel-ai-elements/components/ShimmerShowcase.d.ts +0 -1
  267. package/lib/examples/vercel-ai-elements/components/ShimmerShowcase.js +0 -9
  268. package/lib/examples/vercel-ai-elements/components/SourcesShowcase.d.ts +0 -1
  269. package/lib/examples/vercel-ai-elements/components/SourcesShowcase.js +0 -43
  270. package/lib/examples/vercel-ai-elements/components/SuggestionShowcase.d.ts +0 -1
  271. package/lib/examples/vercel-ai-elements/components/SuggestionShowcase.js +0 -31
  272. package/lib/examples/vercel-ai-elements/components/ToolShowcase.d.ts +0 -1
  273. package/lib/examples/vercel-ai-elements/components/ToolShowcase.js +0 -54
  274. package/lib/examples/vercel-ai-elements/index.d.ts +0 -13
  275. package/lib/examples/vercel-ai-elements/index.js +0 -17
  276. package/lib/examples/vercel-ai-elements/main.d.ts +0 -1
  277. package/lib/examples/vercel-ai-elements/main.js +0 -9
  278. package/lib/examples/vercel-ai-elements/showcase.css +0 -128
  279. package/lib/hooks/useToast.d.ts +0 -44
  280. package/lib/hooks/useToast.js +0 -128
  281. package/patches/@datalayer+jupyter-lexical+1.0.8.patch +0 -11628
  282. package/patches/@datalayer+jupyter-react+2.0.2.patch +0 -5338
  283. package/style/showcase-vercel-ai.css +0 -137
  284. /package/lib/{examples/components → components}/FooterMetrics.js +0 -0
  285. /package/lib/{examples/components → components}/MockFileBrowser.js +0 -0
  286. /package/lib/{examples/components → components}/SessionTabs.js +0 -0
  287. /package/lib/{examples/components → components}/TimeTravel.js +0 -0
  288. /package/lib/{models → types}/AIAgent.d.ts +0 -0
  289. /package/lib/{models → types}/AIAgent.js +0 -0
  290. /package/lib/{models → types}/index.d.ts +0 -0
  291. /package/lib/{models → types}/index.js +0 -0
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Environment Variable Catalog
3
+ *
4
+ * Predefined environment variable specifications.
5
+ *
6
+ * This file is AUTO-GENERATED from YAML specifications.
7
+ * DO NOT EDIT MANUALLY - run 'make specs' to regenerate.
8
+ */
9
+ export interface EnvvarSpec {
10
+ id: string;
11
+ name: string;
12
+ description: string;
13
+ registrationUrl?: string;
14
+ tags: string[];
15
+ icon?: string;
16
+ emoji?: string;
17
+ }
18
+ export declare const ALPHAVANTAGE_API_KEY_SPEC: EnvvarSpec;
19
+ export declare const GITHUB_TOKEN_SPEC: EnvvarSpec;
20
+ export declare const GOOGLE_OAUTH_CLIENT_ID_SPEC: EnvvarSpec;
21
+ export declare const GOOGLE_OAUTH_CLIENT_SECRET_SPEC: EnvvarSpec;
22
+ export declare const KAGGLE_TOKEN_SPEC: EnvvarSpec;
23
+ export declare const SLACK_BOT_TOKEN_SPEC: EnvvarSpec;
24
+ export declare const SLACK_CHANNEL_IDS_SPEC: EnvvarSpec;
25
+ export declare const SLACK_TEAM_ID_SPEC: EnvvarSpec;
26
+ export declare const TAVILY_API_KEY_SPEC: EnvvarSpec;
27
+ export declare const ENVVAR_CATALOG: Record<string, EnvvarSpec>;
28
+ export declare function getEnvvarSpec(envvarId: string): EnvvarSpec;
@@ -0,0 +1,115 @@
1
+ /*
2
+ * Copyright (c) 2025-2026 Datalayer, Inc.
3
+ * Distributed under the terms of the Modified BSD License.
4
+ */
5
+ // ============================================================================
6
+ // Environment Variable Definitions
7
+ // ============================================================================
8
+ export const ALPHAVANTAGE_API_KEY_SPEC = {
9
+ id: 'ALPHAVANTAGE_API_KEY',
10
+ name: 'Alpha Vantage API Key',
11
+ description: 'API key for accessing Alpha Vantage financial market data and stock information. Provides real-time and historical stock prices, forex data, and cryptocurrency information.',
12
+ registrationUrl: 'https://www.alphavantage.co/support/#api-key',
13
+ tags: ['authentication', 'api-key', 'finance', 'stocks', 'market-data'],
14
+ icon: 'key',
15
+ emoji: '🔑',
16
+ };
17
+ export const GITHUB_TOKEN_SPEC = {
18
+ id: 'GITHUB_TOKEN',
19
+ name: 'GitHub Token',
20
+ description: 'GitHub API token for repository management and code operations. Required for GitHub MCP server and GitHub skill to interact with GitHub repositories programmatically.',
21
+ registrationUrl: 'https://github.com/settings/tokens',
22
+ tags: ['authentication', 'token', 'github', 'git', 'mcp-server', 'skill'],
23
+ icon: 'key',
24
+ emoji: '🔑',
25
+ };
26
+ export const GOOGLE_OAUTH_CLIENT_ID_SPEC = {
27
+ id: 'GOOGLE_OAUTH_CLIENT_ID',
28
+ name: 'Google OAuth Client ID',
29
+ description: 'OAuth 2.0 client ID for Google Workspace authentication. Required for Google Drive, Gmail, Calendar, and Docs integration through the Google Workspace MCP server.',
30
+ registrationUrl: 'https://console.cloud.google.com/apis/credentials',
31
+ tags: ['authentication', 'oauth', 'google', 'workspace', 'client-id'],
32
+ icon: 'key',
33
+ emoji: '🔑',
34
+ };
35
+ export const GOOGLE_OAUTH_CLIENT_SECRET_SPEC = {
36
+ id: 'GOOGLE_OAUTH_CLIENT_SECRET',
37
+ name: 'Google OAuth Client Secret',
38
+ description: 'OAuth 2.0 client secret for Google Workspace authentication. Used in conjunction with client ID for secure API access to Google services.',
39
+ registrationUrl: 'https://console.cloud.google.com/apis/credentials',
40
+ tags: [
41
+ 'authentication',
42
+ 'oauth',
43
+ 'google',
44
+ 'workspace',
45
+ 'client-secret',
46
+ 'security',
47
+ ],
48
+ icon: 'lock',
49
+ emoji: '🔒',
50
+ };
51
+ export const KAGGLE_TOKEN_SPEC = {
52
+ id: 'KAGGLE_TOKEN',
53
+ name: 'Kaggle API Token',
54
+ description: 'API token for accessing Kaggle datasets, competitions, notebooks, and models. Required for Kaggle MCP server authentication.',
55
+ registrationUrl: 'https://www.kaggle.com/settings/account',
56
+ tags: ['authentication', 'api-key', 'kaggle', 'data'],
57
+ icon: 'key',
58
+ emoji: '🔑',
59
+ };
60
+ export const SLACK_BOT_TOKEN_SPEC = {
61
+ id: 'SLACK_BOT_TOKEN',
62
+ name: 'Slack Bot Token',
63
+ description: 'OAuth token for Slack bot authentication. Required for Slack MCP server to send messages, manage channels, and interact with workspace members.',
64
+ registrationUrl: 'https://api.slack.com/apps',
65
+ tags: ['authentication', 'oauth', 'token', 'slack', 'messaging', 'bot'],
66
+ icon: 'key',
67
+ emoji: '🔑',
68
+ };
69
+ export const SLACK_CHANNEL_IDS_SPEC = {
70
+ id: 'SLACK_CHANNEL_IDS',
71
+ name: 'Slack Channel IDs',
72
+ description: 'Comma-separated list of Slack channel IDs that the bot is allowed to access. Restricts bot operations to specific channels for security and organization.',
73
+ tags: ['configuration', 'slack', 'channels', 'identifier'],
74
+ icon: 'hash',
75
+ emoji: undefined,
76
+ };
77
+ export const SLACK_TEAM_ID_SPEC = {
78
+ id: 'SLACK_TEAM_ID',
79
+ name: 'Slack Team ID',
80
+ description: 'Unique identifier for the Slack workspace (team). Required to specify which workspace the bot should connect to.',
81
+ registrationUrl: 'https://api.slack.com/apps',
82
+ tags: ['configuration', 'slack', 'workspace', 'identifier'],
83
+ icon: 'organization',
84
+ emoji: '🏢',
85
+ };
86
+ export const TAVILY_API_KEY_SPEC = {
87
+ id: 'TAVILY_API_KEY',
88
+ name: 'Tavily API Key',
89
+ description: 'API key for Tavily web search and research capabilities. Required for web crawling, content extraction, and search operations.',
90
+ registrationUrl: 'https://tavily.com/api-keys',
91
+ tags: ['authentication', 'api-key', 'search', 'web', 'research'],
92
+ icon: 'key',
93
+ emoji: '🔑',
94
+ };
95
+ // ============================================================================
96
+ // Environment Variable Catalog
97
+ // ============================================================================
98
+ export const ENVVAR_CATALOG = {
99
+ ALPHAVANTAGE_API_KEY: ALPHAVANTAGE_API_KEY_SPEC,
100
+ GITHUB_TOKEN: GITHUB_TOKEN_SPEC,
101
+ GOOGLE_OAUTH_CLIENT_ID: GOOGLE_OAUTH_CLIENT_ID_SPEC,
102
+ GOOGLE_OAUTH_CLIENT_SECRET: GOOGLE_OAUTH_CLIENT_SECRET_SPEC,
103
+ KAGGLE_TOKEN: KAGGLE_TOKEN_SPEC,
104
+ SLACK_BOT_TOKEN: SLACK_BOT_TOKEN_SPEC,
105
+ SLACK_CHANNEL_IDS: SLACK_CHANNEL_IDS_SPEC,
106
+ SLACK_TEAM_ID: SLACK_TEAM_ID_SPEC,
107
+ TAVILY_API_KEY: TAVILY_API_KEY_SPEC,
108
+ };
109
+ export function getEnvvarSpec(envvarId) {
110
+ const spec = ENVVAR_CATALOG[envvarId];
111
+ if (!spec) {
112
+ throw new Error(`Unknown environment variable: ${envvarId}`);
113
+ }
114
+ return spec;
115
+ }
@@ -0,0 +1,5 @@
1
+ export * from './envvars';
2
+ export * from './mcpServers';
3
+ export * from './agents';
4
+ export * from './skills';
5
+ export * from './utils';
@@ -0,0 +1,9 @@
1
+ /*
2
+ * Copyright (c) 2025-2026 Datalayer, Inc.
3
+ * Distributed under the terms of the Modified BSD License.
4
+ */
5
+ export * from './envvars';
6
+ export * from './mcpServers';
7
+ export * from './agents';
8
+ export * from './skills';
9
+ export * from './utils';
@@ -0,0 +1,18 @@
1
+ /**
2
+ * MCP Server Catalog
3
+ *
4
+ * Predefined MCP server configurations.
5
+ *
6
+ * This file is AUTO-GENERATED from YAML specifications.
7
+ * DO NOT EDIT MANUALLY - run 'make specs' to regenerate.
8
+ */
9
+ import type { MCPServer } from '../types';
10
+ export declare const ALPHAVANTAGE_MCP_SERVER: MCPServer;
11
+ export declare const CHART_MCP_SERVER: MCPServer;
12
+ export declare const FILESYSTEM_MCP_SERVER: MCPServer;
13
+ export declare const GITHUB_MCP_SERVER: MCPServer;
14
+ export declare const GOOGLE_WORKSPACE_MCP_SERVER: MCPServer;
15
+ export declare const KAGGLE_MCP_SERVER: MCPServer;
16
+ export declare const SLACK_MCP_SERVER: MCPServer;
17
+ export declare const TAVILY_MCP_SERVER: MCPServer;
18
+ export declare const MCP_SERVER_LIBRARY: Record<string, MCPServer>;
@@ -0,0 +1,153 @@
1
+ /*
2
+ * Copyright (c) 2025-2026 Datalayer, Inc.
3
+ * Distributed under the terms of the Modified BSD License.
4
+ */
5
+ // ============================================================================
6
+ // MCP Server Definitions
7
+ // ============================================================================
8
+ export const ALPHAVANTAGE_MCP_SERVER = {
9
+ id: 'alphavantage',
10
+ name: 'Alpha Vantage',
11
+ description: 'Financial market data and stock information',
12
+ icon: 'graph',
13
+ emoji: '💹',
14
+ url: '',
15
+ command: 'uvx',
16
+ args: ['av-mcp==0.2.1', '${ALPHAVANTAGE_API_KEY}'],
17
+ transport: 'stdio',
18
+ enabled: true,
19
+ isAvailable: false,
20
+ tools: [],
21
+ requiredEnvVars: ['ALPHAVANTAGE_API_KEY'],
22
+ };
23
+ export const CHART_MCP_SERVER = {
24
+ id: 'chart',
25
+ name: 'Chart Generator',
26
+ description: 'Generate charts and visualizations',
27
+ icon: 'graph',
28
+ emoji: '📊',
29
+ url: '',
30
+ command: 'npx',
31
+ args: ['-y', '@antv/mcp-server-chart'],
32
+ transport: 'stdio',
33
+ enabled: true,
34
+ isAvailable: false,
35
+ tools: [],
36
+ requiredEnvVars: [],
37
+ };
38
+ export const FILESYSTEM_MCP_SERVER = {
39
+ id: 'filesystem',
40
+ name: 'Filesystem',
41
+ description: 'Local filesystem read/write operations',
42
+ icon: 'file-directory',
43
+ emoji: '📁',
44
+ url: '',
45
+ command: 'npx',
46
+ args: ['-y', '@modelcontextprotocol/server-filesystem', '$TMPDIR'],
47
+ transport: 'stdio',
48
+ enabled: true,
49
+ isAvailable: false,
50
+ tools: [],
51
+ requiredEnvVars: [],
52
+ };
53
+ export const GITHUB_MCP_SERVER = {
54
+ id: 'github',
55
+ name: 'GitHub',
56
+ description: 'GitHub repository operations (issues, PRs, code search)',
57
+ icon: 'mark-github',
58
+ emoji: '🐙 - git - collaboration',
59
+ url: '',
60
+ command: 'docker',
61
+ args: [
62
+ 'run',
63
+ '-i',
64
+ '--rm',
65
+ '-e',
66
+ 'GITHUB_TOKEN',
67
+ 'ghcr.io/github/github-mcp-server',
68
+ ],
69
+ transport: 'stdio',
70
+ enabled: true,
71
+ isAvailable: false,
72
+ tools: [],
73
+ requiredEnvVars: ['GITHUB_TOKEN'],
74
+ };
75
+ export const GOOGLE_WORKSPACE_MCP_SERVER = {
76
+ id: 'google-workspace',
77
+ name: 'Google Workspace',
78
+ description: 'Google Drive, Gmail, Calendar, and Docs integration',
79
+ icon: 'mail',
80
+ emoji: '📧',
81
+ url: '',
82
+ command: 'uvx',
83
+ args: ['workspace-mcp'],
84
+ transport: 'stdio',
85
+ enabled: true,
86
+ isAvailable: false,
87
+ tools: [],
88
+ requiredEnvVars: ['GOOGLE_OAUTH_CLIENT_ID', 'GOOGLE_OAUTH_CLIENT_SECRET'],
89
+ };
90
+ export const KAGGLE_MCP_SERVER = {
91
+ id: 'kaggle',
92
+ name: 'Kaggle',
93
+ description: 'Kaggle datasets, models, competitions, and notebooks access',
94
+ icon: 'database',
95
+ emoji: '📊',
96
+ url: '',
97
+ command: 'npx',
98
+ args: [
99
+ '-y',
100
+ 'mcp-remote',
101
+ 'https://www.kaggle.com/mcp',
102
+ '--header',
103
+ 'Authorization: Bearer ${KAGGLE_TOKEN}',
104
+ ],
105
+ transport: 'stdio',
106
+ enabled: true,
107
+ isAvailable: false,
108
+ tools: [],
109
+ requiredEnvVars: ['KAGGLE_TOKEN'],
110
+ };
111
+ export const SLACK_MCP_SERVER = {
112
+ id: 'slack',
113
+ name: 'Slack',
114
+ description: 'Slack messaging and channel operations',
115
+ icon: 'comment-discussion',
116
+ emoji: '💬',
117
+ url: '',
118
+ command: 'npx',
119
+ args: ['-y', '@datalayer/slack-mcp-server'],
120
+ transport: 'stdio',
121
+ enabled: true,
122
+ isAvailable: false,
123
+ tools: [],
124
+ requiredEnvVars: ['SLACK_BOT_TOKEN', 'SLACK_TEAM_ID', 'SLACK_CHANNEL_IDS'],
125
+ };
126
+ export const TAVILY_MCP_SERVER = {
127
+ id: 'tavily',
128
+ name: 'Tavily Search',
129
+ description: 'Web search and research capabilities via Tavily API',
130
+ icon: 'search',
131
+ emoji: '🔍',
132
+ url: '',
133
+ command: 'npx',
134
+ args: ['-y', 'tavily-mcp'],
135
+ transport: 'stdio',
136
+ enabled: true,
137
+ isAvailable: false,
138
+ tools: [],
139
+ requiredEnvVars: ['TAVILY_API_KEY'],
140
+ };
141
+ // ============================================================================
142
+ // MCP Server Library
143
+ // ============================================================================
144
+ export const MCP_SERVER_LIBRARY = {
145
+ alphavantage: ALPHAVANTAGE_MCP_SERVER,
146
+ chart: CHART_MCP_SERVER,
147
+ filesystem: FILESYSTEM_MCP_SERVER,
148
+ github: GITHUB_MCP_SERVER,
149
+ 'google-workspace': GOOGLE_WORKSPACE_MCP_SERVER,
150
+ kaggle: KAGGLE_MCP_SERVER,
151
+ slack: SLACK_MCP_SERVER,
152
+ tavily: TAVILY_MCP_SERVER,
153
+ };
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Skill Catalog
3
+ *
4
+ * Predefined skill configurations.
5
+ *
6
+ * This file is AUTO-GENERATED from YAML specifications.
7
+ * DO NOT EDIT MANUALLY - run 'make specs' to regenerate.
8
+ */
9
+ export interface SkillSpec {
10
+ id: string;
11
+ name: string;
12
+ description: string;
13
+ module: string;
14
+ requiredEnvVars: string[];
15
+ optionalEnvVars: string[];
16
+ dependencies: string[];
17
+ tags: string[];
18
+ icon?: string;
19
+ emoji?: string;
20
+ enabled: boolean;
21
+ }
22
+ export declare const CRAWL_SKILL_SPEC: SkillSpec;
23
+ export declare const GITHUB_SKILL_SPEC: SkillSpec;
24
+ export declare const PDF_SKILL_SPEC: SkillSpec;
25
+ export declare const SKILL_CATALOG: Record<string, SkillSpec>;
26
+ export declare function getSkillSpecs(): SkillSpec[];
27
+ export declare function getSkillSpec(skillId: string): SkillSpec | undefined;
@@ -0,0 +1,60 @@
1
+ /*
2
+ * Copyright (c) 2025-2026 Datalayer, Inc.
3
+ * Distributed under the terms of the Modified BSD License.
4
+ */
5
+ // ============================================================================
6
+ // Skill Definitions
7
+ // ============================================================================
8
+ export const CRAWL_SKILL_SPEC = {
9
+ id: 'crawl',
10
+ name: 'Web Crawl Skill',
11
+ description: 'Web crawling and content extraction capabilities',
12
+ module: 'agent_skills.crawl',
13
+ requiredEnvVars: ['TAVILY_API_KEY'],
14
+ optionalEnvVars: [],
15
+ dependencies: ['requests>=2.31.0', 'beautifulsoup4>=4.12.0'],
16
+ tags: ['web', 'crawl', 'scraping'],
17
+ icon: 'globe',
18
+ emoji: '🌐',
19
+ enabled: true,
20
+ };
21
+ export const GITHUB_SKILL_SPEC = {
22
+ id: 'github',
23
+ name: 'GitHub Skill',
24
+ description: 'GitHub repository management and code operations',
25
+ module: 'agent_skills.github',
26
+ requiredEnvVars: ['GITHUB_TOKEN'],
27
+ optionalEnvVars: [],
28
+ dependencies: ['PyGithub>=2.1.0'],
29
+ tags: ['github', 'git', 'code'],
30
+ icon: 'mark-github',
31
+ emoji: '🐙',
32
+ enabled: true,
33
+ };
34
+ export const PDF_SKILL_SPEC = {
35
+ id: 'pdf',
36
+ name: 'PDF Processing Skill',
37
+ description: 'PDF document reading, parsing, and extraction',
38
+ module: 'agent_skills.pdf',
39
+ requiredEnvVars: [],
40
+ optionalEnvVars: [],
41
+ dependencies: ['PyPDF2>=3.0.0', 'pdfplumber>=0.10.0'],
42
+ tags: ['pdf', 'documents', 'extraction'],
43
+ icon: 'file',
44
+ emoji: '📄',
45
+ enabled: true,
46
+ };
47
+ // ============================================================================
48
+ // Skill Catalog
49
+ // ============================================================================
50
+ export const SKILL_CATALOG = {
51
+ crawl: CRAWL_SKILL_SPEC,
52
+ github: GITHUB_SKILL_SPEC,
53
+ pdf: PDF_SKILL_SPEC,
54
+ };
55
+ export function getSkillSpecs() {
56
+ return Object.values(SKILL_CATALOG);
57
+ }
58
+ export function getSkillSpec(skillId) {
59
+ return SKILL_CATALOG[skillId];
60
+ }
@@ -1,2 +1,2 @@
1
- import { type ClassValue } from "clsx";
1
+ import { type ClassValue } from 'clsx';
2
2
  export declare function cn(...inputs: ClassValue[]): string;
@@ -2,8 +2,8 @@
2
2
  * Copyright (c) 2025-2026 Datalayer, Inc.
3
3
  * Distributed under the terms of the Modified BSD License.
4
4
  */
5
- import clsx from "clsx";
6
- import { twMerge } from "tailwind-merge";
5
+ import clsx from 'clsx';
6
+ import { twMerge } from 'tailwind-merge';
7
7
  export function cn(...inputs) {
8
8
  return twMerge(clsx(inputs));
9
9
  }
@@ -27,6 +27,7 @@ import 'prismjs/components/prism-rust';
27
27
  import 'prismjs/components/prism-swift';
28
28
  import type { ServiceManager } from '@jupyterlab/services';
29
29
  import '@datalayer/jupyter-lexical/style/index.css';
30
+ import '@datalayer/jupyter-lexical/style/modal-overrides.css';
30
31
  import './lexical/lexical-theme.css';
31
32
  /**
32
33
  * Chat Lexical Example with Simple integration
@@ -48,12 +48,13 @@ import { LinkPlugin } from '@lexical/react/LexicalLinkPlugin';
48
48
  import { Box } from '@datalayer/primer-addons';
49
49
  import { Text } from '@primer/react';
50
50
  import { JupyterReactTheme, useJupyter } from '@datalayer/jupyter-react';
51
- import { ComponentPickerMenuPlugin, JupyterCellPlugin, JupyterInputOutputPlugin, DraggableBlockPlugin, ImagesPlugin, HorizontalRulePlugin, EquationsPlugin, YouTubePlugin, AutoLinkPlugin, AutoEmbedPlugin, FloatingTextFormatToolbarPlugin, CodeActionMenuPlugin, ListMaxIndentLevelPlugin, } from '@datalayer/jupyter-lexical';
51
+ import { ComponentPickerMenuPlugin, JupyterCellPlugin, JupyterInputOutputPlugin, DraggableBlockPlugin, ImagesPlugin, HorizontalRulePlugin, EquationsPlugin, YouTubePlugin, ExcalidrawPlugin, CollapsiblePlugin, AutoLinkPlugin, AutoEmbedPlugin, FloatingTextFormatToolbarPlugin, CodeActionMenuPlugin, ListMaxIndentLevelPlugin, TableCellResizerPlugin, TablePlugin, } from '@datalayer/jupyter-lexical';
52
52
  // Import Chat components
53
53
  import { ChatFloating, useChatStore, useFrontendTool, DatalayerInferenceProvider, } from '../components/chat';
54
54
  import { useLexicalToolActions, ActionRegistrar, } from '../tools/adapters/copilotkit/lexicalHooks';
55
55
  import { editorConfig } from './lexical/editorConfig';
56
56
  import '@datalayer/jupyter-lexical/style/index.css';
57
+ import '@datalayer/jupyter-lexical/style/modal-overrides.css';
57
58
  import './lexical/lexical-theme.css';
58
59
  // Fixed lexical document ID
59
60
  const LEXICAL_ID = 'chat-popup-lexical-example';
@@ -154,7 +155,7 @@ function LexicalEditor({ serviceManager: _serviceManager, }) {
154
155
  left: '24px',
155
156
  color: 'var(--fgColor-muted)',
156
157
  pointerEvents: 'none',
157
- }, children: "Start typing or click the chat button to open the AI assistant..." }), ErrorBoundary: LexicalErrorBoundary }), _jsx(HistoryPlugin, {}), _jsx(AutoFocusPlugin, {}), _jsx(OnChangePlugin, { onChange: onChange }), _jsx(MarkdownShortcutPlugin, { transformers: TRANSFORMERS }), _jsx(CodeHighlightingPlugin, {}), _jsx(ListPlugin, {}), _jsx(CheckListPlugin, {}), _jsx(LinkPlugin, {}), _jsx(JupyterCellPlugin, {}), _jsx(JupyterInputOutputPlugin, {}), _jsx(ImagesPlugin, {}), _jsx(HorizontalRulePlugin, {}), _jsx(EquationsPlugin, {}), _jsx(YouTubePlugin, {}), _jsx(AutoLinkPlugin, {}), _jsx(AutoEmbedPlugin, {}), _jsx(ListMaxIndentLevelPlugin, { maxDepth: 7 }), floatingAnchorElem && (_jsxs(_Fragment, { children: [_jsx(ComponentPickerMenuPlugin, {}), _jsx(DraggableBlockPlugin, { anchorElem: floatingAnchorElem }), _jsx(FloatingTextFormatToolbarPlugin, { anchorElem: floatingAnchorElem, setIsLinkEditMode: setIsLinkEditMode }), _jsx(CodeActionMenuPlugin, { anchorElem: floatingAnchorElem })] }))] }) }));
158
+ }, children: "Start typing or click the chat button to open the AI assistant..." }), ErrorBoundary: LexicalErrorBoundary }), _jsx(HistoryPlugin, {}), _jsx(AutoFocusPlugin, {}), _jsx(OnChangePlugin, { onChange: onChange }), _jsx(MarkdownShortcutPlugin, { transformers: TRANSFORMERS }), _jsx(CodeHighlightingPlugin, {}), _jsx(ListPlugin, {}), _jsx(CheckListPlugin, {}), _jsx(LinkPlugin, {}), _jsx(JupyterCellPlugin, {}), _jsx(JupyterInputOutputPlugin, {}), _jsx(ImagesPlugin, {}), _jsx(HorizontalRulePlugin, {}), _jsx(EquationsPlugin, {}), _jsx(YouTubePlugin, {}), _jsx(ExcalidrawPlugin, {}), _jsx(CollapsiblePlugin, {}), _jsx(AutoLinkPlugin, {}), _jsx(AutoEmbedPlugin, {}), _jsx(TablePlugin, {}), _jsx(TableCellResizerPlugin, {}), _jsx(ListMaxIndentLevelPlugin, { maxDepth: 7 }), floatingAnchorElem && (_jsxs(_Fragment, { children: [_jsx(ComponentPickerMenuPlugin, {}), _jsx(DraggableBlockPlugin, { anchorElem: floatingAnchorElem }), _jsx(FloatingTextFormatToolbarPlugin, { anchorElem: floatingAnchorElem, setIsLinkEditMode: setIsLinkEditMode }), _jsx(CodeActionMenuPlugin, { anchorElem: floatingAnchorElem })] }))] }) }));
158
159
  }
159
160
  export function ChatLexicalExampleInner({ serviceManager, }) {
160
161
  // Chat configuration - set up the inference provider in the store
@@ -25,6 +25,7 @@ import 'prismjs/components/prism-swift';
25
25
  import type { ServiceManager } from '@jupyterlab/services';
26
26
  import '@datalayer/jupyter-lexical/style/index.css';
27
27
  import './lexical/lexical-theme.css';
28
+ import '@datalayer/jupyter-lexical/style/modal-overrides.css';
28
29
  /**
29
30
  * Main Agent Runtime lexical example component
30
31
  */
@@ -45,7 +45,7 @@ import { CheckListPlugin } from '@lexical/react/LexicalCheckListPlugin';
45
45
  import { LinkPlugin } from '@lexical/react/LexicalLinkPlugin';
46
46
  import { Box } from '@datalayer/primer-addons';
47
47
  import { JupyterReactTheme, useJupyter } from '@datalayer/jupyter-react';
48
- import { ComponentPickerMenuPlugin, JupyterCellPlugin, JupyterInputOutputPlugin, DraggableBlockPlugin, ImagesPlugin, HorizontalRulePlugin, EquationsPlugin, YouTubePlugin, AutoLinkPlugin, AutoEmbedPlugin, LexicalConfigProvider, LexicalStatePlugin, CodeActionMenuPlugin, ListMaxIndentLevelPlugin, } from '@datalayer/jupyter-lexical';
48
+ import { ComponentPickerMenuPlugin, JupyterCellPlugin, JupyterInputOutputPlugin, DraggableBlockPlugin, ImagesPlugin, HorizontalRulePlugin, EquationsPlugin, YouTubePlugin, ExcalidrawPlugin, CollapsiblePlugin, AutoLinkPlugin, AutoEmbedPlugin, LexicalConfigProvider, LexicalStatePlugin, FloatingTextFormatToolbarPlugin, CodeActionMenuPlugin, ListMaxIndentLevelPlugin, TableCellResizerPlugin, TablePlugin, } from '@datalayer/jupyter-lexical';
49
49
  // Agent-runtimes imports
50
50
  import { ChatFloating } from '../components/chat';
51
51
  import { ChatInlinePlugin } from '../lexical/ChatInlinePlugin';
@@ -53,12 +53,13 @@ import { useLexicalTools } from '../tools/adapters/agent-runtimes/lexicalHooks';
53
53
  import { editorConfig } from './lexical/editorConfig';
54
54
  import '@datalayer/jupyter-lexical/style/index.css';
55
55
  import './lexical/lexical-theme.css';
56
+ import '@datalayer/jupyter-lexical/style/modal-overrides.css';
56
57
  // Fixed lexical document ID
57
58
  const LEXICAL_ID = 'agui-lexical-example';
58
59
  // Base URL for agent-runtimes server
59
60
  const BASE_URL = 'http://localhost:8765';
60
61
  const AGENT_ID = 'lexical-agent-runtime-example';
61
- // AG-UI endpoint for lexical operations
62
+ // AG-UI endpoint for lexical operations (trailing slash required for mounted Starlette apps)
62
63
  const AG_UI_ENDPOINT = `${BASE_URL}/api/v1/ag-ui/${AGENT_ID}/`;
63
64
  /**
64
65
  * Hook to ensure the demo-agent exists on the server.
@@ -185,6 +186,7 @@ function LexicalToolsPlugin({ onToolsReady, }) {
185
186
  }
186
187
  const LexicalUI = React.memo(function LexicalUI({ content = INITIAL_CONTENT, serviceManager, onToolsReady, }) {
187
188
  const [floatingAnchorElem, setFloatingAnchorElem] = useState(null);
189
+ const [_isLinkEditMode, setIsLinkEditMode] = useState(false);
188
190
  const onRef = (_floatingAnchorElem) => {
189
191
  if (_floatingAnchorElem !== null) {
190
192
  setFloatingAnchorElem(_floatingAnchorElem);
@@ -211,7 +213,7 @@ const LexicalUI = React.memo(function LexicalUI({ content = INITIAL_CONTENT, ser
211
213
  padding: 3,
212
214
  backgroundColor: 'canvas.default',
213
215
  minHeight: '600px',
214
- }, children: _jsxs(LexicalConfigProvider, { lexicalId: LEXICAL_ID, serviceManager: serviceManager, children: [_jsx(LexicalToolsPlugin, { onToolsReady: onToolsReady }), _jsx(LexicalComposer, { initialConfig: editorConfig, children: _jsxs("div", { className: "lexical-editor-inner", ref: onRef, children: [_jsx(LexicalStatePlugin, {}), _jsx(RichTextPlugin, { contentEditable: _jsx(ContentEditable, { className: "lexical-editor-content", "aria-label": "Lexical Editor" }), ErrorBoundary: LexicalErrorBoundary }), _jsx(OnChangePlugin, { onChange: handleChange }), _jsx(HistoryPlugin, {}), _jsx(AutoFocusPlugin, {}), _jsx(ListPlugin, {}), _jsx(CheckListPlugin, {}), _jsx(LinkPlugin, {}), _jsx(AutoLinkPlugin, {}), _jsx(ListMaxIndentLevelPlugin, { maxDepth: 7 }), _jsx(MarkdownShortcutPlugin, { transformers: TRANSFORMERS }), _jsx(LoadContentPlugin, { content: content }), _jsx(CodeHighlightPlugin, {}), _jsx(ImagesPlugin, { captionsEnabled: false }), _jsx(HorizontalRulePlugin, {}), _jsx(EquationsPlugin, {}), _jsx(YouTubePlugin, {}), _jsx(AutoEmbedPlugin, {}), _jsx(JupyterCellPlugin, {}), _jsx(JupyterReactTheme, { children: _jsx(SimpleKernelPluginsInner, {}) }), floatingAnchorElem && (_jsxs(_Fragment, { children: [_jsx(DraggableBlockPlugin, { anchorElem: floatingAnchorElem }), _jsx(CodeActionMenuPlugin, { anchorElem: floatingAnchorElem })] })), _jsx(ChatInlinePlugin, { protocol: {
216
+ }, children: _jsxs(LexicalConfigProvider, { lexicalId: LEXICAL_ID, serviceManager: serviceManager, children: [_jsx(LexicalToolsPlugin, { onToolsReady: onToolsReady }), _jsx(LexicalComposer, { initialConfig: editorConfig, children: _jsxs("div", { className: "lexical-editor-inner", ref: onRef, children: [_jsx(LexicalStatePlugin, {}), _jsx(RichTextPlugin, { contentEditable: _jsx(ContentEditable, { className: "lexical-editor-content", "aria-label": "Lexical Editor" }), ErrorBoundary: LexicalErrorBoundary }), _jsx(OnChangePlugin, { onChange: handleChange }), _jsx(HistoryPlugin, {}), _jsx(AutoFocusPlugin, {}), _jsx(ListPlugin, {}), _jsx(CheckListPlugin, {}), _jsx(LinkPlugin, {}), _jsx(AutoLinkPlugin, {}), _jsx(ListMaxIndentLevelPlugin, { maxDepth: 7 }), _jsx(MarkdownShortcutPlugin, { transformers: TRANSFORMERS }), _jsx(LoadContentPlugin, { content: content }), _jsx(CodeHighlightPlugin, {}), _jsx(ImagesPlugin, { captionsEnabled: false }), _jsx(HorizontalRulePlugin, {}), _jsx(EquationsPlugin, {}), _jsx(YouTubePlugin, {}), _jsx(ExcalidrawPlugin, {}), _jsx(CollapsiblePlugin, {}), _jsx(AutoEmbedPlugin, {}), _jsx(TablePlugin, {}), _jsx(TableCellResizerPlugin, {}), _jsx(JupyterCellPlugin, {}), _jsx(JupyterReactTheme, { children: _jsx(SimpleKernelPluginsInner, {}) }), floatingAnchorElem && (_jsxs(_Fragment, { children: [_jsx(DraggableBlockPlugin, { anchorElem: floatingAnchorElem }), _jsx(FloatingTextFormatToolbarPlugin, { anchorElem: floatingAnchorElem, setIsLinkEditMode: setIsLinkEditMode }), _jsx(CodeActionMenuPlugin, { anchorElem: floatingAnchorElem })] })), _jsx(ChatInlinePlugin, { protocol: {
215
217
  type: 'ag-ui',
216
218
  endpoint: AG_UI_ENDPOINT,
217
219
  } })] }) })] }) })] }));
@@ -26,6 +26,7 @@ import 'prismjs/components/prism-rust';
26
26
  import 'prismjs/components/prism-swift';
27
27
  import type { ServiceManager } from '@jupyterlab/services';
28
28
  import '@datalayer/jupyter-lexical/style/index.css';
29
+ import '@datalayer/jupyter-lexical/style/modal-overrides.css';
29
30
  import './lexical/lexical-theme.css';
30
31
  /**
31
32
  * Agent Runtime Lexical Sidebar Example with Simple integration
@@ -44,15 +44,15 @@ import { registerCodeHighlighting } from '@lexical/code';
44
44
  import { ListPlugin } from '@lexical/react/LexicalListPlugin';
45
45
  import { CheckListPlugin } from '@lexical/react/LexicalCheckListPlugin';
46
46
  import { LinkPlugin } from '@lexical/react/LexicalLinkPlugin';
47
- import { TablePlugin } from '@lexical/react/LexicalTablePlugin';
48
47
  import { Box } from '@datalayer/primer-addons';
49
48
  import { JupyterReactTheme, useJupyter } from '@datalayer/jupyter-react';
50
- import { ComponentPickerMenuPlugin, JupyterCellPlugin, JupyterInputOutputPlugin, DraggableBlockPlugin, ImagesPlugin, HorizontalRulePlugin, EquationsPlugin, YouTubePlugin, ExcalidrawPlugin, CollapsiblePlugin, AutoLinkPlugin, AutoEmbedPlugin, FloatingTextFormatToolbarPlugin, CodeActionMenuPlugin, ListMaxIndentLevelPlugin, LexicalConfigProvider, LexicalStatePlugin, } from '@datalayer/jupyter-lexical';
49
+ import { ComponentPickerMenuPlugin, JupyterCellPlugin, JupyterInputOutputPlugin, DraggableBlockPlugin, ImagesPlugin, HorizontalRulePlugin, EquationsPlugin, YouTubePlugin, ExcalidrawPlugin, CollapsiblePlugin, AutoLinkPlugin, AutoEmbedPlugin, FloatingTextFormatToolbarPlugin, CodeActionMenuPlugin, ListMaxIndentLevelPlugin, LexicalConfigProvider, LexicalStatePlugin, TableCellResizerPlugin, TablePlugin, } from '@datalayer/jupyter-lexical';
51
50
  // Import Chat components
52
51
  import { ChatSidebar, } from '../components/chat';
53
52
  import { useLexicalTools } from '../tools/adapters/agent-runtimes/lexicalHooks';
54
53
  import { editorConfig } from './lexical/editorConfig';
55
54
  import '@datalayer/jupyter-lexical/style/index.css';
55
+ import '@datalayer/jupyter-lexical/style/modal-overrides.css';
56
56
  import './lexical/lexical-theme.css';
57
57
  // Fixed lexical document ID
58
58
  const LEXICAL_ID = 'chat-lexical-example';
@@ -98,7 +98,7 @@ function LexicalEditor({ serviceManager }) {
98
98
  left: '24px',
99
99
  color: 'var(--fgColor-muted)',
100
100
  pointerEvents: 'none',
101
- }, children: "Start typing or use the chat to create content..." }), ErrorBoundary: LexicalErrorBoundary }), _jsx(HistoryPlugin, {}), _jsx(AutoFocusPlugin, {}), _jsx(OnChangePlugin, { onChange: onChange }), _jsx(MarkdownShortcutPlugin, { transformers: TRANSFORMERS }), _jsx(CodeHighlightingPlugin, {}), _jsx(ListPlugin, {}), _jsx(CheckListPlugin, {}), _jsx(LinkPlugin, {}), _jsx(TablePlugin, {}), _jsx(JupyterCellPlugin, {}), _jsx(JupyterInputOutputPlugin, {}), _jsx(ImagesPlugin, {}), _jsx(HorizontalRulePlugin, {}), _jsx(EquationsPlugin, {}), _jsx(YouTubePlugin, {}), _jsx(ExcalidrawPlugin, {}), _jsx(CollapsiblePlugin, {}), _jsx(AutoLinkPlugin, {}), _jsx(AutoEmbedPlugin, {}), _jsx(ListMaxIndentLevelPlugin, { maxDepth: 7 }), floatingAnchorElem && (_jsxs(_Fragment, { children: [_jsx(ComponentPickerMenuPlugin, {}), _jsx(DraggableBlockPlugin, { anchorElem: floatingAnchorElem }), _jsx(FloatingTextFormatToolbarPlugin, { anchorElem: floatingAnchorElem, setIsLinkEditMode: setIsLinkEditMode }), _jsx(CodeActionMenuPlugin, { anchorElem: floatingAnchorElem })] }))] })] }) }));
101
+ }, children: "Start typing or use the chat to create content..." }), ErrorBoundary: LexicalErrorBoundary }), _jsx(HistoryPlugin, {}), _jsx(AutoFocusPlugin, {}), _jsx(OnChangePlugin, { onChange: onChange }), _jsx(MarkdownShortcutPlugin, { transformers: TRANSFORMERS }), _jsx(CodeHighlightingPlugin, {}), _jsx(ListPlugin, {}), _jsx(CheckListPlugin, {}), _jsx(LinkPlugin, {}), _jsx(TablePlugin, {}), _jsx(TableCellResizerPlugin, {}), _jsx(JupyterCellPlugin, {}), _jsx(JupyterInputOutputPlugin, {}), _jsx(ImagesPlugin, {}), _jsx(HorizontalRulePlugin, {}), _jsx(EquationsPlugin, {}), _jsx(YouTubePlugin, {}), _jsx(ExcalidrawPlugin, {}), _jsx(CollapsiblePlugin, {}), _jsx(AutoLinkPlugin, {}), _jsx(AutoEmbedPlugin, {}), _jsx(ListMaxIndentLevelPlugin, { maxDepth: 7 }), floatingAnchorElem && (_jsxs(_Fragment, { children: [_jsx(ComponentPickerMenuPlugin, {}), _jsx(DraggableBlockPlugin, { anchorElem: floatingAnchorElem }), _jsx(FloatingTextFormatToolbarPlugin, { anchorElem: floatingAnchorElem, setIsLinkEditMode: setIsLinkEditMode }), _jsx(CodeActionMenuPlugin, { anchorElem: floatingAnchorElem })] }))] })] }) }));
102
102
  }
103
103
  export function ChatLexicalExampleInner({ serviceManager, }) {
104
104
  // Get lexical tools for ChatSidebar
@@ -30,7 +30,7 @@ const NOTEBOOK_CONTENT = MatplotlibNotebook;
30
30
  // Base URL for agent-runtimes server
31
31
  const BASE_URL = 'http://localhost:8765';
32
32
  const AGENT_ID = 'notebook-agent-runtime-example';
33
- // AG-UI endpoint for notebook operations
33
+ // AG-UI endpoint for notebook operations (trailing slash required for mounted Starlette apps)
34
34
  const AG_UI_ENDPOINT = `${BASE_URL}/api/v1/ag-ui/${AGENT_ID}/`;
35
35
  /**
36
36
  * Hook to ensure the demo-agent exists on the server.
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import type { Transport } from '../components/chat';
3
- import { type AgentLibrary } from './components';
3
+ import { type AgentLibrary, type McpServerSelection } from '../components';
4
4
  /**
5
5
  * Agent Runtime Example Component
6
6
  *
@@ -64,7 +64,7 @@ type AgentSpaceFormExampleProps = {
64
64
  initialEnableCodemode?: boolean;
65
65
  initialAllowDirectToolCalls?: boolean;
66
66
  initialEnableToolReranker?: boolean;
67
- initialSelectedMcpServers?: string[];
67
+ initialSelectedMcpServers?: McpServerSelection[];
68
68
  autoSelectMcpServers?: boolean;
69
69
  /**
70
70
  * Identity providers configuration.