chat-js 1.0.0-alpha.2 → 1.0.0-alpha.4

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 (439) hide show
  1. package/README.md +6 -4
  2. package/dist/index.js +2627 -2667
  3. package/package.json +10 -4
  4. package/templates/chat-app/.env.example +2 -8
  5. package/templates/chat-app/agent/agent.ts +8 -38
  6. package/templates/chat-app/agent/channels/eve.ts +37 -17
  7. package/templates/chat-app/agent/hooks/activity.ts +2 -1
  8. package/templates/chat-app/agent/hooks/billing.ts +11 -8
  9. package/templates/chat-app/agent/hooks/conversation.ts +2 -2
  10. package/templates/chat-app/agent/hooks/tool-selection.ts +7 -1
  11. package/templates/chat-app/agent/instructions/chat.ts +14 -10
  12. package/templates/chat-app/agent/sandbox.ts +2 -4
  13. package/templates/chat-app/agent/tools/installed.ts +19 -1
  14. package/templates/chat-app/app/(chat)/layout.tsx +10 -8
  15. package/templates/chat-app/app/api/agent-conversations/[id]/route.test.ts +1 -1
  16. package/templates/chat-app/app/api/agent-conversations/[id]/route.ts +1 -5
  17. package/templates/chat-app/app/api/agent-conversations/route.test.ts +31 -2
  18. package/templates/chat-app/app/api/agent-conversations/route.ts +10 -1
  19. package/templates/chat-app/app/api/agent-workspaces/[id]/route.test.ts +5 -31
  20. package/templates/chat-app/app/api/agent-workspaces/[id]/route.ts +2 -10
  21. package/templates/chat-app/app/api/eve/[...path]/route.test.ts +2 -2
  22. package/templates/chat-app/app/apple-icon.png +0 -0
  23. package/templates/chat-app/app/favicon.ico +0 -0
  24. package/templates/chat-app/app/icon.svg +1 -3
  25. package/templates/chat-app/app/opengraph-image.alt.txt +1 -0
  26. package/templates/chat-app/app/opengraph-image.png +0 -0
  27. package/templates/chat-app/chat.config.ts +0 -18
  28. package/templates/chat-app/chatjs/core/chat/compose.ts +35 -11
  29. package/templates/chat-app/chatjs/core/chat/contracts.ts +6 -0
  30. package/templates/chat-app/chatjs/core/installation/contracts.ts +1 -4
  31. package/templates/chat-app/chatjs/core/session/contracts.ts +19 -4
  32. package/templates/chat-app/chatjs/generated/composer-tools.ts +5 -12
  33. package/templates/chat-app/chatjs/generated/installed-chat-ui.ts +11 -5
  34. package/templates/chat-app/chatjs/generated/installed-config.ts +5 -13
  35. package/templates/chat-app/chatjs/generated/installed-instrumentation.ts +1 -2
  36. package/templates/chat-app/chatjs/generated/installed-layout.ts +1 -7
  37. package/templates/chat-app/chatjs/generated/installed-tools.ts +3 -3
  38. package/templates/chat-app/chatjs/generated/installed.ts +3 -3
  39. package/templates/chat-app/chatjs/generated/providers.ts +5 -11
  40. package/templates/chat-app/chatjs/generated/tool-availability.ts +3 -7
  41. package/templates/chat-app/chatjs/generated/tool-definitions.ts +3 -4
  42. package/templates/chat-app/chatjs/generated/tool-requirements.ts +40 -0
  43. package/templates/chat-app/chatjs/generated/tools.ts +7 -28
  44. package/templates/chat-app/chatjs/generated/ui.ts +3 -13
  45. package/templates/chat-app/chatjs/plugins/ai-titles/generate-title.ts +0 -2
  46. package/templates/chat-app/chatjs/plugins/attachment-uploads/chatjs.json +0 -1
  47. package/templates/chat-app/chatjs/plugins/guest-chat/session-profile.ts +2 -0
  48. package/templates/chat-app/chatjs/plugins/guest-chat/signed-out.tsx +70 -34
  49. package/templates/chat-app/chatjs/plugins/image-viewer/chatjs.json +17 -0
  50. package/templates/chat-app/chatjs/plugins/image-viewer/client-plugin.ts +9 -0
  51. package/templates/chat-app/{components → chatjs/plugins/image-viewer}/image-modal.tsx +3 -87
  52. package/templates/chat-app/chatjs/plugins/image-viewer/viewer-action.tsx +47 -0
  53. package/templates/chat-app/chatjs/plugins/mcp/composer.tsx +1 -6
  54. package/templates/chat-app/chatjs/plugins/projects/ui/chat-contributions.tsx +22 -2
  55. package/templates/chat-app/chatjs/plugins/projects/ui/sidebar-project-item.tsx +48 -33
  56. package/templates/chat-app/chatjs/plugins/projects/ui/sidebar-projects.tsx +41 -22
  57. package/templates/chat-app/chatjs/plugins/search/chat.ts +4 -0
  58. package/templates/chat-app/chatjs/plugins/search/search-chats.tsx +9 -3
  59. package/templates/chat-app/chatjs/plugins/search/search-hook.ts +5 -6
  60. package/templates/chat-app/chatjs/plugins/search/search-results-view.tsx +1 -1
  61. package/templates/chat-app/chatjs/plugins/search/search-text.ts +21 -15
  62. package/templates/chat-app/chatjs/plugins/search/sidebar-item.tsx +7 -1
  63. package/templates/chat-app/chatjs/plugins/sharing/ui/share-button.tsx +13 -3
  64. package/templates/chat-app/chatjs/plugins/sharing/ui/shared-page.tsx +23 -39
  65. package/templates/chat-app/chatjs/plugins/sharing/ui/transcript-messages.tsx +2 -2
  66. package/templates/chat-app/chatjs/plugins/spreadsheet-viewer/chatjs.json +18 -0
  67. package/templates/chat-app/chatjs/plugins/spreadsheet-viewer/client-plugin.ts +9 -0
  68. package/templates/chat-app/chatjs/plugins/spreadsheet-viewer/load.ts +120 -0
  69. package/templates/chat-app/chatjs/plugins/spreadsheet-viewer/preview.tsx +72 -0
  70. package/templates/chat-app/chatjs/plugins/spreadsheet-viewer/viewer-action.tsx +97 -0
  71. package/templates/chat-app/chatjs/plugins/video-viewer/chatjs.json +16 -0
  72. package/templates/chat-app/chatjs/plugins/video-viewer/client-plugin.ts +9 -0
  73. package/templates/chat-app/chatjs/plugins/video-viewer/viewer-action.tsx +64 -0
  74. package/templates/chat-app/chatjs/tools/_shared/lib/define-tool-renderer.test.ts +16 -22
  75. package/templates/chat-app/chatjs/tools/attach-workspace-file/attach-conversation-file.ts +34 -0
  76. package/templates/chat-app/chatjs/tools/attach-workspace-file/attach.ts +106 -0
  77. package/templates/chat-app/chatjs/tools/attach-workspace-file/chatjs.json +19 -0
  78. package/templates/chat-app/chatjs/tools/attach-workspace-file/import.ts +71 -0
  79. package/templates/chat-app/chatjs/tools/attach-workspace-file/renderer.tsx +19 -0
  80. package/templates/chat-app/chatjs/tools/attach-workspace-file/schemas.ts +51 -0
  81. package/templates/chat-app/chatjs/tools/attach-workspace-file/tool.ts +62 -0
  82. package/templates/chat-app/chatjs/tools/deep-research/chatjs.json +18 -4
  83. package/templates/chat-app/chatjs/tools/deep-research/progress-panel.tsx +2 -31
  84. package/templates/chat-app/chatjs/tools/deep-research/renderer.tsx +7 -19
  85. package/templates/chat-app/chatjs/tools/deep-research/schemas.ts +1 -46
  86. package/templates/chat-app/chatjs/tools/deep-research/task.tsx +0 -41
  87. package/templates/chat-app/chatjs/tools/deep-research/tasks.tsx +2 -7
  88. package/templates/chat-app/chatjs/tools/generate-image/chatjs.json +4 -1
  89. package/templates/chat-app/chatjs/tools/generate-image/image-generation.ts +0 -1
  90. package/templates/chat-app/chatjs/tools/generate-image/renderer.tsx +39 -51
  91. package/templates/chat-app/chatjs/tools/generate-video/chatjs.json +4 -1
  92. package/templates/chat-app/chatjs/tools/generate-video/renderer.tsx +22 -11
  93. package/templates/chat-app/components/ai-elements/response.tsx +1 -1
  94. package/templates/chat-app/components/app-sidebar.tsx +26 -86
  95. package/templates/chat-app/components/artifact-actions.tsx +19 -0
  96. package/templates/chat-app/components/artifact-download-action.tsx +59 -0
  97. package/templates/chat-app/components/attachment-card.tsx +15 -9
  98. package/templates/chat-app/components/chat/chat-account.tsx +189 -0
  99. package/templates/chat-app/components/{controlled-chat-composer.tsx → chat/chat-composer.tsx} +6 -6
  100. package/templates/chat-app/components/chat/chat-conversation-screen.tsx +75 -0
  101. package/templates/chat-app/components/chat/chat-conversation.tsx +35 -0
  102. package/templates/chat-app/components/chat/chat-header.tsx +52 -0
  103. package/templates/chat-app/components/chat/chat-message-editor.tsx +24 -0
  104. package/templates/chat-app/components/chat/chat-navigation.tsx +11 -0
  105. package/templates/chat-app/components/chat/chat-sidebar.tsx +134 -0
  106. package/templates/chat-app/components/{eve/eve-messages.tsx → chat/chat-transcript.tsx} +7 -28
  107. package/templates/chat-app/components/chat/chat-workspace.tsx +19 -0
  108. package/templates/chat-app/components/chat/connected-chat-sidebar.tsx +8 -0
  109. package/templates/chat-app/components/chat-header-view.tsx +14 -13
  110. package/templates/chat-app/components/chat-slots.tsx +13 -3
  111. package/templates/chat-app/components/composer/active-tool.tsx +3 -1
  112. package/templates/chat-app/components/composer/composer-menu.tsx +4 -2
  113. package/templates/chat-app/components/composer/control.ts +4 -1
  114. package/templates/chat-app/components/composer/prompt-form.tsx +1 -1
  115. package/templates/chat-app/components/composer/tool-availability.tsx +8 -0
  116. package/templates/chat-app/components/composer/tool-controls.tsx +17 -50
  117. package/templates/chat-app/components/composer/tool-display.ts +3 -2
  118. package/templates/chat-app/components/eve/bash-output.tsx +33 -0
  119. package/templates/chat-app/components/eve/eve-chat-page.tsx +5 -26
  120. package/templates/chat-app/components/eve/eve-composer.tsx +11 -8
  121. package/templates/chat-app/components/eve/eve-conversation.tsx +237 -309
  122. package/templates/chat-app/components/eve/eve-deletion-provider.tsx +1 -1
  123. package/templates/chat-app/components/eve/eve-history-list.tsx +7 -3
  124. package/templates/chat-app/components/eve/eve-message-part.tsx +28 -22
  125. package/templates/chat-app/components/eve/eve-pending-input.tsx +54 -1
  126. package/templates/chat-app/components/eve/eve-runtime-provider.tsx +0 -5
  127. package/templates/chat-app/components/eve/new-conversation-view.tsx +7 -3
  128. package/templates/chat-app/components/file-artifact-card.tsx +37 -0
  129. package/templates/chat-app/components/header-actions.tsx +9 -2
  130. package/templates/chat-app/components/image-actions.tsx +93 -0
  131. package/templates/chat-app/components/internal-link.tsx +15 -2
  132. package/templates/chat-app/components/keyboard-shortcuts.tsx +8 -2
  133. package/templates/chat-app/components/part/tool-activity.tsx +1 -1
  134. package/templates/chat-app/components/part/tool-data.tsx +1 -1
  135. package/templates/chat-app/components/sidebar-user-nav.tsx +35 -198
  136. package/templates/chat-app/components/video-player.tsx +43 -0
  137. package/templates/chat-app/composer-controls.ts +0 -4
  138. package/templates/chat-app/docs/guest-sessions.md +1 -1
  139. package/templates/chat-app/instrumentation.ts +2 -6
  140. package/templates/chat-app/integrations/chat/models.ts +10 -0
  141. package/templates/chat-app/integrations/tools/catalog.ts +0 -3
  142. package/templates/chat-app/lib/ai/app-models.test.ts +13 -1
  143. package/templates/chat-app/lib/ai/app-models.ts +13 -3
  144. package/templates/chat-app/lib/ai/tool-context.ts +1 -14
  145. package/templates/chat-app/lib/ai/tool-renderer-registry.ts +10 -5
  146. package/templates/chat-app/lib/db/eve-current-copy.ts +13 -95
  147. package/templates/chat-app/lib/db/eve-deletion.ts +2 -61
  148. package/templates/chat-app/lib/db/eve-dispatch.ts +64 -18
  149. package/templates/chat-app/lib/db/eve-file-purge.ts +11 -145
  150. package/templates/chat-app/lib/db/eve-files.ts +11 -9
  151. package/templates/chat-app/lib/db/eve-orphaned-files.ts +3 -22
  152. package/templates/chat-app/lib/db/eve-queries.ts +32 -16
  153. package/templates/chat-app/lib/db/eve-workspace-deletion.ts +149 -0
  154. package/templates/chat-app/lib/db/migrate.ts +30 -0
  155. package/templates/chat-app/lib/db/migrations/0024_abandoned_toxin.sql +67 -0
  156. package/templates/chat-app/lib/db/migrations/0025_cloudy_thunderbolt.sql +1 -0
  157. package/templates/chat-app/lib/db/migrations/0026_loving_mesmero.sql +3 -0
  158. package/templates/chat-app/lib/db/migrations/0027_misty_stephen_strange.sql +1 -0
  159. package/templates/chat-app/lib/db/migrations/0028_faithful_hannibal_king.sql +12 -0
  160. package/templates/chat-app/lib/db/migrations/meta/0024_snapshot.json +4119 -0
  161. package/templates/chat-app/lib/db/migrations/meta/0025_snapshot.json +3988 -0
  162. package/templates/chat-app/lib/db/migrations/meta/0026_snapshot.json +3686 -0
  163. package/templates/chat-app/lib/db/migrations/meta/0027_snapshot.json +3596 -0
  164. package/templates/chat-app/lib/db/migrations/meta/0028_snapshot.json +2554 -0
  165. package/templates/chat-app/lib/db/migrations/meta/_journal.json +35 -0
  166. package/templates/chat-app/lib/db/schema.ts +1 -360
  167. package/templates/chat-app/lib/env-schema.ts +0 -7
  168. package/templates/chat-app/lib/eve/application-model.ts +56 -0
  169. package/templates/chat-app/lib/eve/bash-result.ts +22 -0
  170. package/templates/chat-app/lib/eve/branch-history.test.ts +59 -0
  171. package/templates/chat-app/lib/eve/branch-history.ts +19 -0
  172. package/templates/chat-app/lib/eve/channel-files.test.ts +14 -11
  173. package/templates/chat-app/lib/eve/channel-files.ts +2 -12
  174. package/templates/chat-app/lib/eve/completed-copy-source.test.ts +81 -17
  175. package/templates/chat-app/lib/eve/completed-copy-source.ts +2 -6
  176. package/templates/chat-app/lib/eve/connection-options.ts +7 -7
  177. package/templates/chat-app/lib/eve/contracts.test.ts +1 -1
  178. package/templates/chat-app/lib/eve/copy-seed.test.ts +17 -28
  179. package/templates/chat-app/lib/eve/copy-seed.ts +8 -34
  180. package/templates/chat-app/lib/eve/copy-transcript.test.ts +143 -47
  181. package/templates/chat-app/lib/eve/copy-transcript.ts +20 -101
  182. package/templates/chat-app/lib/eve/create-conversation-operation.test.ts +11 -31
  183. package/templates/chat-app/lib/eve/create-conversation-operation.ts +0 -10
  184. package/templates/chat-app/lib/eve/delete-local-conversation.test.ts +12 -20
  185. package/templates/chat-app/lib/eve/delete-local-conversation.ts +2 -8
  186. package/templates/chat-app/lib/eve/environment.test.ts +7 -0
  187. package/templates/chat-app/lib/eve/environment.ts +11 -0
  188. package/templates/chat-app/lib/eve/execute-conversation-creation.ts +3 -55
  189. package/templates/chat-app/lib/eve/gateway-auth.test.ts +2 -21
  190. package/templates/chat-app/lib/eve/gateway-auth.ts +7 -13
  191. package/templates/chat-app/lib/eve/generated-files.test.ts +1 -1
  192. package/templates/chat-app/lib/eve/generated-files.ts +2 -2
  193. package/templates/chat-app/lib/eve/installed-tools.test.ts +16 -9
  194. package/templates/chat-app/lib/eve/lifecycle/postgres/compatibility.ts +8 -5
  195. package/templates/chat-app/lib/eve/lifecycle/postgres/eve-payload-purge.ts +6 -2
  196. package/templates/chat-app/lib/eve/lifecycle/postgres/eve-queue-fence.ts +2 -2
  197. package/templates/chat-app/lib/eve/lifecycle/postgres/eve-queue-inventory.ts +2 -2
  198. package/templates/chat-app/lib/eve/lifecycle/postgres/eve-queue-purge.ts +3 -2
  199. package/templates/chat-app/lib/eve/lifecycle/postgres/eve-resource-fence.ts +2 -8
  200. package/templates/chat-app/lib/eve/lifecycle/postgres/eve-run-inventory.ts +1 -1
  201. package/templates/chat-app/lib/eve/lifecycle/postgres/eve-stream-positions.ts +9 -4
  202. package/templates/chat-app/lib/eve/logical-chat.test.ts +4 -3
  203. package/templates/chat-app/lib/eve/logical-chat.ts +8 -8
  204. package/templates/chat-app/lib/eve/message-delivery.test.ts +1 -1
  205. package/templates/chat-app/lib/eve/message-display.test.ts +5 -5
  206. package/templates/chat-app/lib/eve/message-display.ts +31 -1
  207. package/templates/chat-app/lib/eve/message-tool-selection.test.ts +2 -2
  208. package/templates/chat-app/lib/eve/model-accounting.test.ts +28 -45
  209. package/templates/chat-app/lib/eve/model-accounting.ts +8 -54
  210. package/templates/chat-app/lib/eve/purge-files.ts +0 -13
  211. package/templates/chat-app/lib/eve/purge-local-resources.ts +4 -47
  212. package/templates/chat-app/lib/eve/readonly-message-types.ts +8 -3
  213. package/templates/chat-app/lib/eve/reconcile-workspace-turn.ts +2 -37
  214. package/templates/chat-app/lib/eve/response-group-lineage.test.ts +3 -3
  215. package/templates/chat-app/lib/eve/retire-session.test.ts +25 -8
  216. package/templates/chat-app/lib/eve/retire-session.ts +10 -4
  217. package/templates/chat-app/lib/eve/selected-tools.ts +7 -18
  218. package/templates/chat-app/lib/eve/server.test.ts +29 -3
  219. package/templates/chat-app/lib/eve/session-profile.test.ts +12 -9
  220. package/templates/chat-app/lib/eve/session-profile.ts +7 -4
  221. package/templates/chat-app/lib/eve/shared-messages.test.ts +3 -4
  222. package/templates/chat-app/lib/eve/shared-messages.ts +5 -2
  223. package/templates/chat-app/lib/eve/tool-accounting.test.ts +131 -0
  224. package/templates/chat-app/lib/eve/tool-accounting.ts +96 -0
  225. package/templates/chat-app/lib/eve/tool-availability.ts +4 -1
  226. package/templates/chat-app/lib/eve/tool-configuration.ts +29 -0
  227. package/templates/chat-app/lib/eve/tool-result.ts +1 -1
  228. package/templates/chat-app/lib/eve/turn-tools.ts +3 -12
  229. package/templates/chat-app/lib/eve/usage.test.ts +54 -39
  230. package/templates/chat-app/lib/eve/usage.ts +9 -1
  231. package/templates/chat-app/lib/eve/workspace-turn-evidence.test.ts +8 -6
  232. package/templates/chat-app/lib/eve/workspace-turn-evidence.ts +0 -5
  233. package/templates/chat-app/lib/required-credentials.test.ts +2 -2
  234. package/templates/chat-app/lib/tool-readiness.test.ts +69 -0
  235. package/templates/chat-app/lib/tool-readiness.ts +43 -0
  236. package/templates/chat-app/logo.svg +1 -1
  237. package/templates/chat-app/next.config.ts +1 -5
  238. package/templates/chat-app/oxlint.config.ts +3 -6
  239. package/templates/chat-app/package.json +4 -16
  240. package/templates/chat-app/providers/chat-models-provider.tsx +3 -3
  241. package/templates/chat-app/providers/default-model-provider.tsx +4 -4
  242. package/templates/chat-app/providers/session-context.ts +24 -0
  243. package/templates/chat-app/providers/session-provider.tsx +4 -21
  244. package/templates/chat-app/scripts/agent-status.ts +124 -0
  245. package/templates/chat-app/scripts/check-env.ts +0 -10
  246. package/templates/chat-app/scripts/dev-supervisor.mts +3 -30
  247. package/templates/chat-app/scripts/eve-setup.ts +3 -0
  248. package/templates/chat-app/tests/helpers/eve-dynamic-context.ts +2 -0
  249. package/templates/chat-app/tools/platform/research-updates-schema.ts +1 -20
  250. package/templates/chat-app/trpc/context.tsx +8 -0
  251. package/templates/chat-app/trpc/react.tsx +3 -4
  252. package/templates/chat-app/trpc/routers/eve.router.ts +2 -74
  253. package/templates/chat-app/vendor/workflow-world-postgres-5.1.1.tgz +0 -0
  254. package/templates/electron/icon.png +0 -0
  255. package/templates/electron/package.json +2 -1
  256. package/templates/electron/src/application.test.ts +347 -0
  257. package/templates/electron/src/application.ts +849 -0
  258. package/templates/electron/src/lib/auth-cookies.ts +1 -1
  259. package/templates/electron/src/main.test.ts +175 -0
  260. package/templates/electron/src/main.ts +5 -745
  261. package/templates/electron/src/squirrel-startup.ts +61 -0
  262. package/templates/chat-app/agent/hooks/persistent-sandbox.ts +0 -14
  263. package/templates/chat-app/app/api/agent-conversation-copies/route.test.ts +0 -190
  264. package/templates/chat-app/app/api/agent-conversation-copies/route.ts +0 -105
  265. package/templates/chat-app/chatjs/core/documents/compose-views.ts +0 -12
  266. package/templates/chat-app/chatjs/core/documents/contracts.ts +0 -91
  267. package/templates/chat-app/chatjs/core/documents/document-definition.test.ts +0 -60
  268. package/templates/chat-app/chatjs/core/documents/document-definition.ts +0 -55
  269. package/templates/chat-app/chatjs/core/documents/ui.ts +0 -67
  270. package/templates/chat-app/chatjs/generated/code-executor.ts +0 -6
  271. package/templates/chat-app/chatjs/generated/document-run.ts +0 -12
  272. package/templates/chat-app/chatjs/generated/document-ui.ts +0 -7
  273. package/templates/chat-app/chatjs/generated/documents.ts +0 -6
  274. package/templates/chat-app/chatjs/plugins/langfuse/chatjs.json +0 -14
  275. package/templates/chat-app/chatjs/plugins/langfuse/credentials.ts +0 -22
  276. package/templates/chat-app/chatjs/plugins/langfuse/instrumentation.ts +0 -22
  277. package/templates/chat-app/chatjs/plugins/langfuse/server-plugin.ts +0 -5
  278. package/templates/chat-app/chatjs/plugins/vercel-analytics/chatjs.json +0 -15
  279. package/templates/chat-app/chatjs/plugins/vercel-analytics/client-plugin.ts +0 -9
  280. package/templates/chat-app/chatjs/plugins/vercel-analytics/component.tsx +0 -5
  281. package/templates/chat-app/chatjs/plugins/vercel-speed-insights/chatjs.json +0 -15
  282. package/templates/chat-app/chatjs/plugins/vercel-speed-insights/client-plugin.ts +0 -9
  283. package/templates/chat-app/chatjs/plugins/vercel-speed-insights/component.tsx +0 -4
  284. package/templates/chat-app/chatjs/providers/sandbox/adapter.ts +0 -232
  285. package/templates/chat-app/chatjs/providers/sandbox/options.ts +0 -13
  286. package/templates/chat-app/chatjs/providers/sandbox/persistent.ts +0 -258
  287. package/templates/chat-app/chatjs/providers/sandbox/provider.ts +0 -27
  288. package/templates/chat-app/chatjs/providers/sandbox/vercel-sandbox-env.ts +0 -22
  289. package/templates/chat-app/chatjs/tools/_shared/code-execution/code-execution-chart.tsx +0 -83
  290. package/templates/chat-app/chatjs/tools/_shared/code-execution/interactive-chart-impl.tsx +0 -290
  291. package/templates/chat-app/chatjs/tools/_shared/code-execution/interactive-charts.tsx +0 -24
  292. package/templates/chat-app/chatjs/tools/_shared/code-execution/javascript.ts +0 -222
  293. package/templates/chat-app/chatjs/tools/_shared/code-execution/python.ts +0 -381
  294. package/templates/chat-app/chatjs/tools/_shared/code-execution/types.ts +0 -27
  295. package/templates/chat-app/chatjs/tools/code-documents/assistant-actions.ts +0 -16
  296. package/templates/chat-app/chatjs/tools/code-documents/chatjs.json +0 -20
  297. package/templates/chat-app/chatjs/tools/code-documents/configuration-schema.ts +0 -7
  298. package/templates/chat-app/chatjs/tools/code-documents/definition.ts +0 -9
  299. package/templates/chat-app/chatjs/tools/code-documents/document.tsx +0 -33
  300. package/templates/chat-app/chatjs/tools/code-documents/editor.tsx +0 -144
  301. package/templates/chat-app/chatjs/tools/code-documents/guidelines.ts +0 -15
  302. package/templates/chat-app/chatjs/tools/code-documents/tool.ts +0 -54
  303. package/templates/chat-app/chatjs/tools/code-execution/chatjs.json +0 -21
  304. package/templates/chat-app/chatjs/tools/code-execution/python.test.ts +0 -207
  305. package/templates/chat-app/chatjs/tools/code-execution/renderer.test.tsx +0 -142
  306. package/templates/chat-app/chatjs/tools/code-execution/renderer.tsx +0 -68
  307. package/templates/chat-app/chatjs/tools/code-execution/schemas.ts +0 -23
  308. package/templates/chat-app/chatjs/tools/code-execution/tool.ts +0 -93
  309. package/templates/chat-app/chatjs/tools/deep-research/agent.ts +0 -18
  310. package/templates/chat-app/chatjs/tools/deep-research/availability.ts +0 -23
  311. package/templates/chat-app/chatjs/tools/deep-research/configuration-schema.ts +0 -36
  312. package/templates/chat-app/chatjs/tools/deep-research/configuration.ts +0 -22
  313. package/templates/chat-app/chatjs/tools/deep-research/prompts.ts +0 -280
  314. package/templates/chat-app/chatjs/tools/deep-research/search-updates.ts +0 -76
  315. package/templates/chat-app/chatjs/tools/deep-research/steps.ts +0 -92
  316. package/templates/chat-app/chatjs/tools/delete-document/availability.ts +0 -13
  317. package/templates/chat-app/chatjs/tools/delete-document/chatjs.json +0 -9
  318. package/templates/chat-app/chatjs/tools/delete-document/execute.ts +0 -78
  319. package/templates/chat-app/chatjs/tools/delete-document/schemas.ts +0 -18
  320. package/templates/chat-app/chatjs/tools/delete-document/tool.ts +0 -49
  321. package/templates/chat-app/chatjs/tools/get-weather/chatjs.json +0 -14
  322. package/templates/chat-app/chatjs/tools/get-weather/definition.ts +0 -10
  323. package/templates/chat-app/chatjs/tools/get-weather/renderer.test.tsx +0 -57
  324. package/templates/chat-app/chatjs/tools/get-weather/renderer.tsx +0 -290
  325. package/templates/chat-app/chatjs/tools/get-weather/schemas.ts +0 -51
  326. package/templates/chat-app/chatjs/tools/get-weather/tool.ts +0 -34
  327. package/templates/chat-app/chatjs/tools/read-document/chatjs.json +0 -8
  328. package/templates/chat-app/chatjs/tools/read-document/tool.ts +0 -27
  329. package/templates/chat-app/chatjs/tools/retrieve-url/chatjs.json +0 -11
  330. package/templates/chat-app/chatjs/tools/retrieve-url/renderer.tsx +0 -200
  331. package/templates/chat-app/chatjs/tools/retrieve-url/retrieve-url-env.ts +0 -11
  332. package/templates/chat-app/chatjs/tools/retrieve-url/schemas.ts +0 -24
  333. package/templates/chat-app/chatjs/tools/retrieve-url/tool.test.ts +0 -144
  334. package/templates/chat-app/chatjs/tools/retrieve-url/tool.ts +0 -169
  335. package/templates/chat-app/chatjs/tools/saved-code-execution/chatjs.json +0 -12
  336. package/templates/chat-app/chatjs/tools/saved-code-execution/document-runs.ts +0 -31
  337. package/templates/chat-app/chatjs/tools/saved-code-execution/document.tsx +0 -84
  338. package/templates/chat-app/chatjs/tools/saved-code-execution/execute.ts +0 -126
  339. package/templates/chat-app/chatjs/tools/saved-code-execution/renderer.tsx +0 -30
  340. package/templates/chat-app/chatjs/tools/saved-code-execution/result.tsx +0 -42
  341. package/templates/chat-app/chatjs/tools/saved-code-execution/schemas.ts +0 -82
  342. package/templates/chat-app/chatjs/tools/saved-code-execution/tool.ts +0 -12
  343. package/templates/chat-app/chatjs/tools/sheet-documents/assistant-actions.ts +0 -22
  344. package/templates/chat-app/chatjs/tools/sheet-documents/chatjs.json +0 -20
  345. package/templates/chat-app/chatjs/tools/sheet-documents/configuration-schema.ts +0 -10
  346. package/templates/chat-app/chatjs/tools/sheet-documents/definition.ts +0 -9
  347. package/templates/chat-app/chatjs/tools/sheet-documents/document.tsx +0 -41
  348. package/templates/chat-app/chatjs/tools/sheet-documents/editor.tsx +0 -180
  349. package/templates/chat-app/chatjs/tools/sheet-documents/guidelines.ts +0 -5
  350. package/templates/chat-app/chatjs/tools/sheet-documents/tool.ts +0 -54
  351. package/templates/chat-app/chatjs/tools/tavily-search/chatjs.json +0 -19
  352. package/templates/chat-app/chatjs/tools/tavily-search/renderer.tsx +0 -25
  353. package/templates/chat-app/chatjs/tools/tavily-search/schemas.ts +0 -39
  354. package/templates/chat-app/chatjs/tools/tavily-search/tavily-search-env.ts +0 -11
  355. package/templates/chat-app/chatjs/tools/tavily-search/tool.test.ts +0 -114
  356. package/templates/chat-app/chatjs/tools/tavily-search/tool.ts +0 -143
  357. package/templates/chat-app/chatjs/tools/text-documents/assistant-actions.ts +0 -12
  358. package/templates/chat-app/chatjs/tools/text-documents/chatjs.json +0 -20
  359. package/templates/chat-app/chatjs/tools/text-documents/comparison.tsx +0 -72
  360. package/templates/chat-app/chatjs/tools/text-documents/configuration-schema.ts +0 -7
  361. package/templates/chat-app/chatjs/tools/text-documents/definition.ts +0 -9
  362. package/templates/chat-app/chatjs/tools/text-documents/diffview.tsx +0 -214
  363. package/templates/chat-app/chatjs/tools/text-documents/document.tsx +0 -46
  364. package/templates/chat-app/chatjs/tools/text-documents/editor-config.ts +0 -53
  365. package/templates/chat-app/chatjs/tools/text-documents/editor.tsx +0 -139
  366. package/templates/chat-app/chatjs/tools/text-documents/guidelines.ts +0 -7
  367. package/templates/chat-app/chatjs/tools/text-documents/tool.ts +0 -54
  368. package/templates/chat-app/chatjs/tools/word-count/chatjs.json +0 -14
  369. package/templates/chat-app/chatjs/tools/word-count/definition.ts +0 -10
  370. package/templates/chat-app/chatjs/tools/word-count/renderer.tsx +0 -64
  371. package/templates/chat-app/chatjs/tools/word-count/schemas.ts +0 -13
  372. package/templates/chat-app/chatjs/tools/word-count/tool.ts +0 -45
  373. package/templates/chat-app/components/chat/chat-layout.tsx +0 -129
  374. package/templates/chat-app/components/chat-sidebar-view.tsx +0 -53
  375. package/templates/chat-app/components/document-skeleton.tsx +0 -33
  376. package/templates/chat-app/components/eve/eve-artifact-layout.tsx +0 -722
  377. package/templates/chat-app/components/eve/eve-copy-button.tsx +0 -165
  378. package/templates/chat-app/components/eve/eve-document-actions.tsx +0 -124
  379. package/templates/chat-app/components/eve/eve-document-assistant-actions.tsx +0 -157
  380. package/templates/chat-app/components/eve/eve-document-body.tsx +0 -29
  381. package/templates/chat-app/components/eve/eve-document-context.tsx +0 -12
  382. package/templates/chat-app/components/eve/eve-document-preview.tsx +0 -128
  383. package/templates/chat-app/components/eve/eve-document-tool.tsx +0 -190
  384. package/templates/chat-app/components/eve/eve-history.tsx +0 -25
  385. package/templates/chat-app/components/eve/use-document-draft.ts +0 -281
  386. package/templates/chat-app/components/favicon-group.tsx +0 -50
  387. package/templates/chat-app/components/part/document-common.tsx +0 -152
  388. package/templates/chat-app/components/part/web-search.tsx +0 -75
  389. package/templates/chat-app/components/sandbox.tsx +0 -43
  390. package/templates/chat-app/components/source-badge.tsx +0 -50
  391. package/templates/chat-app/components/sources.tsx +0 -140
  392. package/templates/chat-app/hooks/use-artifact.tsx +0 -180
  393. package/templates/chat-app/integrations/documents/definitions.ts +0 -4
  394. package/templates/chat-app/integrations/documents/run.ts +0 -1
  395. package/templates/chat-app/integrations/documents/ui.ts +0 -4
  396. package/templates/chat-app/integrations/providers/sandbox.ts +0 -10
  397. package/templates/chat-app/integrations/tools/code-executor.ts +0 -1
  398. package/templates/chat-app/lib/ai/telemetry.ts +0 -4
  399. package/templates/chat-app/lib/artifacts/artifact-kind.ts +0 -8
  400. package/templates/chat-app/lib/artifacts/types.ts +0 -19
  401. package/templates/chat-app/lib/db/eve-code-sandboxes.ts +0 -197
  402. package/templates/chat-app/lib/db/eve-document-retention.ts +0 -36
  403. package/templates/chat-app/lib/db/eve-documents.ts +0 -700
  404. package/templates/chat-app/lib/eve/code-executor.ts +0 -32
  405. package/templates/chat-app/lib/eve/code-sandbox-name.test.ts +0 -60
  406. package/templates/chat-app/lib/eve/code-sandbox-name.ts +0 -56
  407. package/templates/chat-app/lib/eve/code-sandbox-ownership.ts +0 -88
  408. package/templates/chat-app/lib/eve/copy-input.ts +0 -11
  409. package/templates/chat-app/lib/eve/create-native-copy.ts +0 -38
  410. package/templates/chat-app/lib/eve/document-assistant-actions.test.ts +0 -48
  411. package/templates/chat-app/lib/eve/document-assistant-actions.ts +0 -22
  412. package/templates/chat-app/lib/eve/document-kind-lifecycle.test.ts +0 -148
  413. package/templates/chat-app/lib/eve/document-tools.ts +0 -164
  414. package/templates/chat-app/lib/eve/lifecycle/postgres/eve-sandbox-coverage-proof.ts +0 -140
  415. package/templates/chat-app/lib/eve/persistent-sandbox-store.ts +0 -621
  416. package/templates/chat-app/lib/eve/persistent-sandbox.test.ts +0 -209
  417. package/templates/chat-app/lib/eve/persistent-sandbox.ts +0 -328
  418. package/templates/chat-app/lib/eve/purge-code-sandboxes.test.ts +0 -125
  419. package/templates/chat-app/lib/eve/purge-code-sandboxes.ts +0 -83
  420. package/templates/chat-app/lib/eve/request-copy.test.ts +0 -95
  421. package/templates/chat-app/lib/eve/request-copy.ts +0 -129
  422. package/templates/chat-app/lib/eve/research-progress.test.ts +0 -95
  423. package/templates/chat-app/lib/eve/research-progress.ts +0 -42
  424. package/templates/chat-app/lib/eve/sandbox-environment.test.ts +0 -49
  425. package/templates/chat-app/lib/eve/sandbox-environment.ts +0 -29
  426. package/templates/chat-app/lib/eve/save-copy-operation.ts +0 -33
  427. package/templates/chat-app/lib/eve/save-document.ts +0 -87
  428. package/templates/chat-app/lib/eve/verify-local-coverage.ts +0 -84
  429. package/templates/chat-app/lib/eve/workspace-attachments.ts +0 -173
  430. package/templates/chat-app/lib/sandbox/runtime.ts +0 -12
  431. package/templates/chat-app/scripts/persistent-sandbox-cleanup.ts +0 -128
  432. package/templates/chat-app/scripts/stop-persistent-sandboxes.ts +0 -24
  433. package/templates/chat-app/tests/artifacts.e2e.ts +0 -7
  434. package/templates/chat-app/tools/platform/documents/types.ts +0 -11
  435. package/templates/chat-app/tools/platform/search-presentation.ts +0 -138
  436. package/templates/chat-app/tools/platform/steps/multi-query-web-search.test.ts +0 -45
  437. package/templates/chat-app/tools/platform/steps/multi-query-web-search.ts +0 -142
  438. package/templates/chat-app/tools/platform/steps/search-utils.ts +0 -26
  439. package/templates/chat-app/vendor/workflow-world-postgres-5.0.0-beta.40.tgz +0 -0
@@ -0,0 +1,2554 @@
1
+ {
2
+ "id": "fead720d-0704-4da9-9736-d4ffc66e51ec",
3
+ "prevId": "3dd6df7e-46ac-4493-8742-5a4bc1175dcb",
4
+ "version": "7",
5
+ "dialect": "postgresql",
6
+ "tables": {
7
+ "public.account": {
8
+ "name": "account",
9
+ "schema": "",
10
+ "columns": {
11
+ "access_token": {
12
+ "name": "access_token",
13
+ "type": "text",
14
+ "primaryKey": false,
15
+ "notNull": false
16
+ },
17
+ "access_token_expires_at": {
18
+ "name": "access_token_expires_at",
19
+ "type": "timestamp",
20
+ "primaryKey": false,
21
+ "notNull": false
22
+ },
23
+ "account_id": {
24
+ "name": "account_id",
25
+ "type": "text",
26
+ "primaryKey": false,
27
+ "notNull": true
28
+ },
29
+ "created_at": {
30
+ "name": "created_at",
31
+ "type": "timestamp",
32
+ "primaryKey": false,
33
+ "notNull": true,
34
+ "default": "now()"
35
+ },
36
+ "id": {
37
+ "name": "id",
38
+ "type": "text",
39
+ "primaryKey": true,
40
+ "notNull": true
41
+ },
42
+ "id_token": {
43
+ "name": "id_token",
44
+ "type": "text",
45
+ "primaryKey": false,
46
+ "notNull": false
47
+ },
48
+ "password": {
49
+ "name": "password",
50
+ "type": "text",
51
+ "primaryKey": false,
52
+ "notNull": false
53
+ },
54
+ "provider_id": {
55
+ "name": "provider_id",
56
+ "type": "text",
57
+ "primaryKey": false,
58
+ "notNull": true
59
+ },
60
+ "refresh_token": {
61
+ "name": "refresh_token",
62
+ "type": "text",
63
+ "primaryKey": false,
64
+ "notNull": false
65
+ },
66
+ "refresh_token_expires_at": {
67
+ "name": "refresh_token_expires_at",
68
+ "type": "timestamp",
69
+ "primaryKey": false,
70
+ "notNull": false
71
+ },
72
+ "scope": {
73
+ "name": "scope",
74
+ "type": "text",
75
+ "primaryKey": false,
76
+ "notNull": false
77
+ },
78
+ "updated_at": {
79
+ "name": "updated_at",
80
+ "type": "timestamp",
81
+ "primaryKey": false,
82
+ "notNull": true
83
+ },
84
+ "user_id": {
85
+ "name": "user_id",
86
+ "type": "text",
87
+ "primaryKey": false,
88
+ "notNull": true
89
+ }
90
+ },
91
+ "indexes": {},
92
+ "foreignKeys": {
93
+ "account_user_id_user_id_fk": {
94
+ "name": "account_user_id_user_id_fk",
95
+ "tableFrom": "account",
96
+ "tableTo": "user",
97
+ "columnsFrom": [
98
+ "user_id"
99
+ ],
100
+ "columnsTo": [
101
+ "id"
102
+ ],
103
+ "onDelete": "cascade",
104
+ "onUpdate": "no action"
105
+ }
106
+ },
107
+ "compositePrimaryKeys": {},
108
+ "uniqueConstraints": {},
109
+ "policies": {},
110
+ "checkConstraints": {},
111
+ "isRLSEnabled": false
112
+ },
113
+ "public.EveChat": {
114
+ "name": "EveChat",
115
+ "schema": "",
116
+ "columns": {
117
+ "activeConversationId": {
118
+ "name": "activeConversationId",
119
+ "type": "uuid",
120
+ "primaryKey": false,
121
+ "notNull": false
122
+ },
123
+ "createdAt": {
124
+ "name": "createdAt",
125
+ "type": "timestamp",
126
+ "primaryKey": false,
127
+ "notNull": true,
128
+ "default": "now()"
129
+ },
130
+ "id": {
131
+ "name": "id",
132
+ "type": "uuid",
133
+ "primaryKey": true,
134
+ "notNull": true,
135
+ "default": "gen_random_uuid()"
136
+ },
137
+ "isPinned": {
138
+ "name": "isPinned",
139
+ "type": "boolean",
140
+ "primaryKey": false,
141
+ "notNull": true,
142
+ "default": false
143
+ },
144
+ "ownerId": {
145
+ "name": "ownerId",
146
+ "type": "text",
147
+ "primaryKey": false,
148
+ "notNull": true
149
+ },
150
+ "title": {
151
+ "name": "title",
152
+ "type": "text",
153
+ "primaryKey": false,
154
+ "notNull": true
155
+ },
156
+ "titleStatus": {
157
+ "name": "titleStatus",
158
+ "type": "text",
159
+ "primaryKey": false,
160
+ "notNull": true,
161
+ "default": "'pending'"
162
+ },
163
+ "updatedAt": {
164
+ "name": "updatedAt",
165
+ "type": "timestamp",
166
+ "primaryKey": false,
167
+ "notNull": true,
168
+ "default": "now()"
169
+ }
170
+ },
171
+ "indexes": {
172
+ "EveChat_search_title": {
173
+ "name": "EveChat_search_title",
174
+ "columns": [
175
+ {
176
+ "expression": "to_tsvector('simple', \"title\")",
177
+ "asc": true,
178
+ "isExpression": true,
179
+ "nulls": "last"
180
+ }
181
+ ],
182
+ "isUnique": false,
183
+ "concurrently": false,
184
+ "method": "gin",
185
+ "with": {}
186
+ },
187
+ "EveChat_owner_activity": {
188
+ "name": "EveChat_owner_activity",
189
+ "columns": [
190
+ {
191
+ "expression": "ownerId",
192
+ "isExpression": false,
193
+ "asc": true,
194
+ "nulls": "last"
195
+ },
196
+ {
197
+ "expression": "isPinned",
198
+ "isExpression": false,
199
+ "asc": true,
200
+ "nulls": "last"
201
+ },
202
+ {
203
+ "expression": "updatedAt",
204
+ "isExpression": false,
205
+ "asc": true,
206
+ "nulls": "last"
207
+ }
208
+ ],
209
+ "isUnique": false,
210
+ "concurrently": false,
211
+ "method": "btree",
212
+ "with": {}
213
+ }
214
+ },
215
+ "foreignKeys": {
216
+ "EveChat_ownerId_user_id_fk": {
217
+ "name": "EveChat_ownerId_user_id_fk",
218
+ "tableFrom": "EveChat",
219
+ "tableTo": "user",
220
+ "columnsFrom": [
221
+ "ownerId"
222
+ ],
223
+ "columnsTo": [
224
+ "id"
225
+ ],
226
+ "onDelete": "cascade",
227
+ "onUpdate": "no action"
228
+ }
229
+ },
230
+ "compositePrimaryKeys": {},
231
+ "uniqueConstraints": {
232
+ "EveChat_id_owner": {
233
+ "name": "EveChat_id_owner",
234
+ "nullsNotDistinct": false,
235
+ "columns": [
236
+ "id",
237
+ "ownerId"
238
+ ]
239
+ }
240
+ },
241
+ "policies": {},
242
+ "checkConstraints": {
243
+ "EveChat_title_status": {
244
+ "name": "EveChat_title_status",
245
+ "value": "\"EveChat\".\"titleStatus\" in ('pending', 'fallback', 'generated', 'manual')"
246
+ }
247
+ },
248
+ "isRLSEnabled": false
249
+ },
250
+ "public.EveConversation": {
251
+ "name": "EveConversation",
252
+ "schema": "",
253
+ "columns": {
254
+ "chatId": {
255
+ "name": "chatId",
256
+ "type": "uuid",
257
+ "primaryKey": false,
258
+ "notNull": true
259
+ },
260
+ "workspaceId": {
261
+ "name": "workspaceId",
262
+ "type": "uuid",
263
+ "primaryKey": false,
264
+ "notNull": true
265
+ },
266
+ "createdAt": {
267
+ "name": "createdAt",
268
+ "type": "timestamp",
269
+ "primaryKey": false,
270
+ "notNull": true,
271
+ "default": "now()"
272
+ },
273
+ "creationKind": {
274
+ "name": "creationKind",
275
+ "type": "text",
276
+ "primaryKey": false,
277
+ "notNull": true,
278
+ "default": "'message'"
279
+ },
280
+ "firstMessage": {
281
+ "name": "firstMessage",
282
+ "type": "text",
283
+ "primaryKey": false,
284
+ "notNull": true
285
+ },
286
+ "forkCheckpointId": {
287
+ "name": "forkCheckpointId",
288
+ "type": "uuid",
289
+ "primaryKey": false,
290
+ "notNull": false
291
+ },
292
+ "forkKind": {
293
+ "name": "forkKind",
294
+ "type": "text",
295
+ "primaryKey": false,
296
+ "notNull": false
297
+ },
298
+ "forkMessageId": {
299
+ "name": "forkMessageId",
300
+ "type": "text",
301
+ "primaryKey": false,
302
+ "notNull": false
303
+ },
304
+ "forkTurnId": {
305
+ "name": "forkTurnId",
306
+ "type": "text",
307
+ "primaryKey": false,
308
+ "notNull": false
309
+ },
310
+ "id": {
311
+ "name": "id",
312
+ "type": "uuid",
313
+ "primaryKey": true,
314
+ "notNull": true,
315
+ "default": "gen_random_uuid()"
316
+ },
317
+ "initialContentHash": {
318
+ "name": "initialContentHash",
319
+ "type": "text",
320
+ "primaryKey": false,
321
+ "notNull": false
322
+ },
323
+ "initialModelId": {
324
+ "name": "initialModelId",
325
+ "type": "text",
326
+ "primaryKey": false,
327
+ "notNull": false
328
+ },
329
+ "initialRequest": {
330
+ "name": "initialRequest",
331
+ "type": "jsonb",
332
+ "primaryKey": false,
333
+ "notNull": false
334
+ },
335
+ "initialSeed": {
336
+ "name": "initialSeed",
337
+ "type": "jsonb",
338
+ "primaryKey": false,
339
+ "notNull": false
340
+ },
341
+ "operationId": {
342
+ "name": "operationId",
343
+ "type": "uuid",
344
+ "primaryKey": false,
345
+ "notNull": true
346
+ },
347
+ "ownerId": {
348
+ "name": "ownerId",
349
+ "type": "text",
350
+ "primaryKey": false,
351
+ "notNull": true
352
+ },
353
+ "parentConversationId": {
354
+ "name": "parentConversationId",
355
+ "type": "uuid",
356
+ "primaryKey": false,
357
+ "notNull": false
358
+ },
359
+ "rootConversationId": {
360
+ "name": "rootConversationId",
361
+ "type": "uuid",
362
+ "primaryKey": false,
363
+ "notNull": false
364
+ },
365
+ "sessionId": {
366
+ "name": "sessionId",
367
+ "type": "text",
368
+ "primaryKey": false,
369
+ "notNull": false
370
+ },
371
+ "state": {
372
+ "name": "state",
373
+ "type": "text",
374
+ "primaryKey": false,
375
+ "notNull": true,
376
+ "default": "'creating'"
377
+ },
378
+ "usageStreamIndex": {
379
+ "name": "usageStreamIndex",
380
+ "type": "integer",
381
+ "primaryKey": false,
382
+ "notNull": true,
383
+ "default": 0
384
+ },
385
+ "visibility": {
386
+ "name": "visibility",
387
+ "type": "varchar",
388
+ "primaryKey": false,
389
+ "notNull": true,
390
+ "default": "'private'"
391
+ }
392
+ },
393
+ "indexes": {
394
+ "EveConversation_owner_chat": {
395
+ "name": "EveConversation_owner_chat",
396
+ "columns": [
397
+ {
398
+ "expression": "ownerId",
399
+ "isExpression": false,
400
+ "asc": true,
401
+ "nulls": "last"
402
+ },
403
+ {
404
+ "expression": "chatId",
405
+ "isExpression": false,
406
+ "asc": true,
407
+ "nulls": "last"
408
+ }
409
+ ],
410
+ "isUnique": false,
411
+ "concurrently": false,
412
+ "method": "btree",
413
+ "with": {}
414
+ },
415
+ "EveConversation_workspace": {
416
+ "name": "EveConversation_workspace",
417
+ "columns": [
418
+ {
419
+ "expression": "workspaceId",
420
+ "isExpression": false,
421
+ "asc": true,
422
+ "nulls": "last"
423
+ }
424
+ ],
425
+ "isUnique": false,
426
+ "concurrently": false,
427
+ "method": "btree",
428
+ "with": {}
429
+ },
430
+ "EveConversation_owner_root": {
431
+ "name": "EveConversation_owner_root",
432
+ "columns": [
433
+ {
434
+ "expression": "ownerId",
435
+ "isExpression": false,
436
+ "asc": true,
437
+ "nulls": "last"
438
+ },
439
+ {
440
+ "expression": "rootConversationId",
441
+ "isExpression": false,
442
+ "asc": true,
443
+ "nulls": "last"
444
+ }
445
+ ],
446
+ "isUnique": false,
447
+ "concurrently": false,
448
+ "method": "btree",
449
+ "with": {}
450
+ },
451
+ "EveConversation_owner_operation": {
452
+ "name": "EveConversation_owner_operation",
453
+ "columns": [
454
+ {
455
+ "expression": "ownerId",
456
+ "isExpression": false,
457
+ "asc": true,
458
+ "nulls": "last"
459
+ },
460
+ {
461
+ "expression": "operationId",
462
+ "isExpression": false,
463
+ "asc": true,
464
+ "nulls": "last"
465
+ }
466
+ ],
467
+ "isUnique": true,
468
+ "concurrently": false,
469
+ "method": "btree",
470
+ "with": {}
471
+ }
472
+ },
473
+ "foreignKeys": {
474
+ "EveConversation_ownerId_user_id_fk": {
475
+ "name": "EveConversation_ownerId_user_id_fk",
476
+ "tableFrom": "EveConversation",
477
+ "tableTo": "user",
478
+ "columnsFrom": [
479
+ "ownerId"
480
+ ],
481
+ "columnsTo": [
482
+ "id"
483
+ ],
484
+ "onDelete": "no action",
485
+ "onUpdate": "no action"
486
+ },
487
+ "EveConversation_workspace_owner_fk": {
488
+ "name": "EveConversation_workspace_owner_fk",
489
+ "tableFrom": "EveConversation",
490
+ "tableTo": "EveWorkspace",
491
+ "columnsFrom": [
492
+ "workspaceId",
493
+ "ownerId"
494
+ ],
495
+ "columnsTo": [
496
+ "id",
497
+ "ownerId"
498
+ ],
499
+ "onDelete": "no action",
500
+ "onUpdate": "no action"
501
+ },
502
+ "EveConversation_chat_owner_fk": {
503
+ "name": "EveConversation_chat_owner_fk",
504
+ "tableFrom": "EveConversation",
505
+ "tableTo": "EveChat",
506
+ "columnsFrom": [
507
+ "chatId",
508
+ "ownerId"
509
+ ],
510
+ "columnsTo": [
511
+ "id",
512
+ "ownerId"
513
+ ],
514
+ "onDelete": "no action",
515
+ "onUpdate": "no action"
516
+ },
517
+ "EveConversation_parent_owner_fk": {
518
+ "name": "EveConversation_parent_owner_fk",
519
+ "tableFrom": "EveConversation",
520
+ "tableTo": "EveConversation",
521
+ "columnsFrom": [
522
+ "parentConversationId",
523
+ "ownerId",
524
+ "chatId"
525
+ ],
526
+ "columnsTo": [
527
+ "id",
528
+ "ownerId",
529
+ "chatId"
530
+ ],
531
+ "onDelete": "no action",
532
+ "onUpdate": "no action"
533
+ },
534
+ "EveConversation_root_owner_fk": {
535
+ "name": "EveConversation_root_owner_fk",
536
+ "tableFrom": "EveConversation",
537
+ "tableTo": "EveConversation",
538
+ "columnsFrom": [
539
+ "rootConversationId",
540
+ "ownerId",
541
+ "chatId"
542
+ ],
543
+ "columnsTo": [
544
+ "id",
545
+ "ownerId",
546
+ "chatId"
547
+ ],
548
+ "onDelete": "no action",
549
+ "onUpdate": "no action"
550
+ }
551
+ },
552
+ "compositePrimaryKeys": {},
553
+ "uniqueConstraints": {
554
+ "EveConversation_sessionId_unique": {
555
+ "name": "EveConversation_sessionId_unique",
556
+ "nullsNotDistinct": false,
557
+ "columns": [
558
+ "sessionId"
559
+ ]
560
+ },
561
+ "EveConversation_id_owner": {
562
+ "name": "EveConversation_id_owner",
563
+ "nullsNotDistinct": false,
564
+ "columns": [
565
+ "id",
566
+ "ownerId"
567
+ ]
568
+ },
569
+ "EveConversation_id_owner_chat": {
570
+ "name": "EveConversation_id_owner_chat",
571
+ "nullsNotDistinct": false,
572
+ "columns": [
573
+ "id",
574
+ "ownerId",
575
+ "chatId"
576
+ ]
577
+ }
578
+ },
579
+ "policies": {},
580
+ "checkConstraints": {
581
+ "EveConversation_creation_kind": {
582
+ "name": "EveConversation_creation_kind",
583
+ "value": "\"EveConversation\".\"creationKind\" in ('message', 'copy')"
584
+ },
585
+ "EveConversation_named_fork_shape": {
586
+ "name": "EveConversation_named_fork_shape",
587
+ "value": "\"EveConversation\".\"forkCheckpointId\" is null or (\n \"EveConversation\".\"parentConversationId\" is not null and \"EveConversation\".\"forkMessageId\" is null\n )"
588
+ },
589
+ "EveConversation_fork_shape": {
590
+ "name": "EveConversation_fork_shape",
591
+ "value": "(\n \"EveConversation\".\"parentConversationId\" is null and \"EveConversation\".\"rootConversationId\" is null and\n \"EveConversation\".\"forkTurnId\" is null and \"EveConversation\".\"forkMessageId\" is null and \"EveConversation\".\"forkKind\" is null\n ) or (\n \"EveConversation\".\"parentConversationId\" is not null and \"EveConversation\".\"rootConversationId\" is not null and\n (\n (\"EveConversation\".\"forkTurnId\" is null and \"EveConversation\".\"forkMessageId\" is null) or\n (\"EveConversation\".\"forkTurnId\" is not null and \"EveConversation\".\"forkTurnId\" ~ '^turn_(0|[1-9][0-9]*)$' and \"EveConversation\".\"forkMessageId\" is null) or\n (\"EveConversation\".\"forkMessageId\" is not null and length(\"EveConversation\".\"forkMessageId\") between 1 and 512 and \"EveConversation\".\"forkTurnId\" is null)\n ) and\n \"EveConversation\".\"parentConversationId\" <> \"EveConversation\".\"id\" and \"EveConversation\".\"rootConversationId\" <> \"EveConversation\".\"id\"\n )"
592
+ },
593
+ "EveConversation_fork_kind": {
594
+ "name": "EveConversation_fork_kind",
595
+ "value": "\"EveConversation\".\"forkKind\" is null or \"EveConversation\".\"forkKind\" in ('edit', 'regenerate', 'comparison')"
596
+ }
597
+ },
598
+ "isRLSEnabled": false
599
+ },
600
+ "public.EveDispatch": {
601
+ "name": "EveDispatch",
602
+ "schema": "",
603
+ "columns": {
604
+ "ownerId": {
605
+ "name": "ownerId",
606
+ "type": "text",
607
+ "primaryKey": false,
608
+ "notNull": true
609
+ },
610
+ "operationId": {
611
+ "name": "operationId",
612
+ "type": "uuid",
613
+ "primaryKey": false,
614
+ "notNull": true
615
+ },
616
+ "conversationId": {
617
+ "name": "conversationId",
618
+ "type": "uuid",
619
+ "primaryKey": false,
620
+ "notNull": true
621
+ },
622
+ "kind": {
623
+ "name": "kind",
624
+ "type": "text",
625
+ "primaryKey": false,
626
+ "notNull": true
627
+ },
628
+ "intent": {
629
+ "name": "intent",
630
+ "type": "jsonb",
631
+ "primaryKey": false,
632
+ "notNull": true
633
+ },
634
+ "sessionId": {
635
+ "name": "sessionId",
636
+ "type": "text",
637
+ "primaryKey": false,
638
+ "notNull": false
639
+ },
640
+ "deliveryId": {
641
+ "name": "deliveryId",
642
+ "type": "text",
643
+ "primaryKey": false,
644
+ "notNull": false
645
+ },
646
+ "createdAt": {
647
+ "name": "createdAt",
648
+ "type": "timestamp",
649
+ "primaryKey": false,
650
+ "notNull": true,
651
+ "default": "now()"
652
+ }
653
+ },
654
+ "indexes": {},
655
+ "foreignKeys": {
656
+ "EveDispatch_ownerId_user_id_fk": {
657
+ "name": "EveDispatch_ownerId_user_id_fk",
658
+ "tableFrom": "EveDispatch",
659
+ "tableTo": "user",
660
+ "columnsFrom": [
661
+ "ownerId"
662
+ ],
663
+ "columnsTo": [
664
+ "id"
665
+ ],
666
+ "onDelete": "no action",
667
+ "onUpdate": "no action"
668
+ },
669
+ "EveDispatch_conversation_owner_fk": {
670
+ "name": "EveDispatch_conversation_owner_fk",
671
+ "tableFrom": "EveDispatch",
672
+ "tableTo": "EveConversation",
673
+ "columnsFrom": [
674
+ "conversationId",
675
+ "ownerId"
676
+ ],
677
+ "columnsTo": [
678
+ "id",
679
+ "ownerId"
680
+ ],
681
+ "onDelete": "no action",
682
+ "onUpdate": "no action"
683
+ }
684
+ },
685
+ "compositePrimaryKeys": {
686
+ "EveDispatch_ownerId_operationId_pk": {
687
+ "name": "EveDispatch_ownerId_operationId_pk",
688
+ "columns": [
689
+ "ownerId",
690
+ "operationId"
691
+ ]
692
+ }
693
+ },
694
+ "uniqueConstraints": {},
695
+ "policies": {},
696
+ "checkConstraints": {
697
+ "EveDispatch_kind": {
698
+ "name": "EveDispatch_kind",
699
+ "value": "\"EveDispatch\".\"kind\" in ('create', 'copy', 'send')"
700
+ },
701
+ "EveDispatch_binding": {
702
+ "name": "EveDispatch_binding",
703
+ "value": "\"EveDispatch\".\"deliveryId\" is null or \"EveDispatch\".\"sessionId\" is not null"
704
+ }
705
+ },
706
+ "isRLSEnabled": false
707
+ },
708
+ "public.EveFileReference": {
709
+ "name": "EveFileReference",
710
+ "schema": "",
711
+ "columns": {
712
+ "conversationId": {
713
+ "name": "conversationId",
714
+ "type": "uuid",
715
+ "primaryKey": false,
716
+ "notNull": true
717
+ },
718
+ "key": {
719
+ "name": "key",
720
+ "type": "text",
721
+ "primaryKey": false,
722
+ "notNull": true
723
+ },
724
+ "ownerId": {
725
+ "name": "ownerId",
726
+ "type": "text",
727
+ "primaryKey": false,
728
+ "notNull": true
729
+ }
730
+ },
731
+ "indexes": {
732
+ "EveFileReference_key": {
733
+ "name": "EveFileReference_key",
734
+ "columns": [
735
+ {
736
+ "expression": "key",
737
+ "isExpression": false,
738
+ "asc": true,
739
+ "nulls": "last"
740
+ }
741
+ ],
742
+ "isUnique": false,
743
+ "concurrently": false,
744
+ "method": "btree",
745
+ "with": {}
746
+ }
747
+ },
748
+ "foreignKeys": {
749
+ "EveFileReference_conversationId_ownerId_EveConversation_id_ownerId_fk": {
750
+ "name": "EveFileReference_conversationId_ownerId_EveConversation_id_ownerId_fk",
751
+ "tableFrom": "EveFileReference",
752
+ "tableTo": "EveConversation",
753
+ "columnsFrom": [
754
+ "conversationId",
755
+ "ownerId"
756
+ ],
757
+ "columnsTo": [
758
+ "id",
759
+ "ownerId"
760
+ ],
761
+ "onDelete": "no action",
762
+ "onUpdate": "no action"
763
+ },
764
+ "EveFileReference_key_ownerId_EveStoredFile_key_ownerId_fk": {
765
+ "name": "EveFileReference_key_ownerId_EveStoredFile_key_ownerId_fk",
766
+ "tableFrom": "EveFileReference",
767
+ "tableTo": "EveStoredFile",
768
+ "columnsFrom": [
769
+ "key",
770
+ "ownerId"
771
+ ],
772
+ "columnsTo": [
773
+ "key",
774
+ "ownerId"
775
+ ],
776
+ "onDelete": "no action",
777
+ "onUpdate": "no action"
778
+ }
779
+ },
780
+ "compositePrimaryKeys": {
781
+ "EveFileReference_conversationId_key_pk": {
782
+ "name": "EveFileReference_conversationId_key_pk",
783
+ "columns": [
784
+ "conversationId",
785
+ "key"
786
+ ]
787
+ }
788
+ },
789
+ "uniqueConstraints": {},
790
+ "policies": {},
791
+ "checkConstraints": {},
792
+ "isRLSEnabled": false
793
+ },
794
+ "public.EveResponseGroup": {
795
+ "name": "EveResponseGroup",
796
+ "schema": "",
797
+ "columns": {
798
+ "candidateOperationIds": {
799
+ "name": "candidateOperationIds",
800
+ "type": "uuid[]",
801
+ "primaryKey": false,
802
+ "notNull": true
803
+ },
804
+ "candidates": {
805
+ "name": "candidates",
806
+ "type": "jsonb",
807
+ "primaryKey": false,
808
+ "notNull": false
809
+ },
810
+ "createdAt": {
811
+ "name": "createdAt",
812
+ "type": "timestamp",
813
+ "primaryKey": false,
814
+ "notNull": true,
815
+ "default": "now()"
816
+ },
817
+ "deleted": {
818
+ "name": "deleted",
819
+ "type": "boolean",
820
+ "primaryKey": false,
821
+ "notNull": true,
822
+ "default": false
823
+ },
824
+ "id": {
825
+ "name": "id",
826
+ "type": "uuid",
827
+ "primaryKey": true,
828
+ "notNull": true,
829
+ "default": "gen_random_uuid()"
830
+ },
831
+ "inputHash": {
832
+ "name": "inputHash",
833
+ "type": "text",
834
+ "primaryKey": false,
835
+ "notNull": false
836
+ },
837
+ "operationId": {
838
+ "name": "operationId",
839
+ "type": "uuid",
840
+ "primaryKey": false,
841
+ "notNull": true
842
+ },
843
+ "ownerId": {
844
+ "name": "ownerId",
845
+ "type": "text",
846
+ "primaryKey": false,
847
+ "notNull": true
848
+ },
849
+ "sourceConversationId": {
850
+ "name": "sourceConversationId",
851
+ "type": "uuid",
852
+ "primaryKey": false,
853
+ "notNull": false
854
+ },
855
+ "sourceIdentityKnown": {
856
+ "name": "sourceIdentityKnown",
857
+ "type": "boolean",
858
+ "primaryKey": false,
859
+ "notNull": true,
860
+ "default": false
861
+ }
862
+ },
863
+ "indexes": {
864
+ "EveResponseGroup_owner_operation": {
865
+ "name": "EveResponseGroup_owner_operation",
866
+ "columns": [
867
+ {
868
+ "expression": "ownerId",
869
+ "isExpression": false,
870
+ "asc": true,
871
+ "nulls": "last"
872
+ },
873
+ {
874
+ "expression": "operationId",
875
+ "isExpression": false,
876
+ "asc": true,
877
+ "nulls": "last"
878
+ }
879
+ ],
880
+ "isUnique": true,
881
+ "concurrently": false,
882
+ "method": "btree",
883
+ "with": {}
884
+ }
885
+ },
886
+ "foreignKeys": {
887
+ "EveResponseGroup_ownerId_user_id_fk": {
888
+ "name": "EveResponseGroup_ownerId_user_id_fk",
889
+ "tableFrom": "EveResponseGroup",
890
+ "tableTo": "user",
891
+ "columnsFrom": [
892
+ "ownerId"
893
+ ],
894
+ "columnsTo": [
895
+ "id"
896
+ ],
897
+ "onDelete": "no action",
898
+ "onUpdate": "no action"
899
+ }
900
+ },
901
+ "compositePrimaryKeys": {},
902
+ "uniqueConstraints": {},
903
+ "policies": {},
904
+ "checkConstraints": {},
905
+ "isRLSEnabled": false
906
+ },
907
+ "public.EveStoredFile": {
908
+ "name": "EveStoredFile",
909
+ "schema": "",
910
+ "columns": {
911
+ "createdAt": {
912
+ "name": "createdAt",
913
+ "type": "timestamp",
914
+ "primaryKey": false,
915
+ "notNull": true,
916
+ "default": "now()"
917
+ },
918
+ "key": {
919
+ "name": "key",
920
+ "type": "text",
921
+ "primaryKey": true,
922
+ "notNull": true
923
+ },
924
+ "ownerId": {
925
+ "name": "ownerId",
926
+ "type": "text",
927
+ "primaryKey": false,
928
+ "notNull": true
929
+ },
930
+ "state": {
931
+ "name": "state",
932
+ "type": "text",
933
+ "primaryKey": false,
934
+ "notNull": true,
935
+ "default": "'active'"
936
+ },
937
+ "storageKey": {
938
+ "name": "storageKey",
939
+ "type": "text",
940
+ "primaryKey": false,
941
+ "notNull": true,
942
+ "default": "gen_random_uuid()::text"
943
+ }
944
+ },
945
+ "indexes": {
946
+ "EveStoredFile_owner": {
947
+ "name": "EveStoredFile_owner",
948
+ "columns": [
949
+ {
950
+ "expression": "ownerId",
951
+ "isExpression": false,
952
+ "asc": true,
953
+ "nulls": "last"
954
+ }
955
+ ],
956
+ "isUnique": false,
957
+ "concurrently": false,
958
+ "method": "btree",
959
+ "with": {}
960
+ }
961
+ },
962
+ "foreignKeys": {
963
+ "EveStoredFile_ownerId_user_id_fk": {
964
+ "name": "EveStoredFile_ownerId_user_id_fk",
965
+ "tableFrom": "EveStoredFile",
966
+ "tableTo": "user",
967
+ "columnsFrom": [
968
+ "ownerId"
969
+ ],
970
+ "columnsTo": [
971
+ "id"
972
+ ],
973
+ "onDelete": "no action",
974
+ "onUpdate": "no action"
975
+ }
976
+ },
977
+ "compositePrimaryKeys": {},
978
+ "uniqueConstraints": {
979
+ "EveStoredFile_storageKey_unique": {
980
+ "name": "EveStoredFile_storageKey_unique",
981
+ "nullsNotDistinct": false,
982
+ "columns": [
983
+ "storageKey"
984
+ ]
985
+ },
986
+ "EveStoredFile_key_owner": {
987
+ "name": "EveStoredFile_key_owner",
988
+ "nullsNotDistinct": false,
989
+ "columns": [
990
+ "key",
991
+ "ownerId"
992
+ ]
993
+ }
994
+ },
995
+ "policies": {},
996
+ "checkConstraints": {},
997
+ "isRLSEnabled": false
998
+ },
999
+ "public.EveSubagentSession": {
1000
+ "name": "EveSubagentSession",
1001
+ "schema": "",
1002
+ "columns": {
1003
+ "conversationId": {
1004
+ "name": "conversationId",
1005
+ "type": "uuid",
1006
+ "primaryKey": false,
1007
+ "notNull": true
1008
+ },
1009
+ "ownerId": {
1010
+ "name": "ownerId",
1011
+ "type": "text",
1012
+ "primaryKey": false,
1013
+ "notNull": true
1014
+ },
1015
+ "parentSessionId": {
1016
+ "name": "parentSessionId",
1017
+ "type": "text",
1018
+ "primaryKey": false,
1019
+ "notNull": true
1020
+ },
1021
+ "rootTurnId": {
1022
+ "name": "rootTurnId",
1023
+ "type": "text",
1024
+ "primaryKey": false,
1025
+ "notNull": true
1026
+ },
1027
+ "sessionId": {
1028
+ "name": "sessionId",
1029
+ "type": "text",
1030
+ "primaryKey": true,
1031
+ "notNull": true
1032
+ },
1033
+ "usageStreamIndex": {
1034
+ "name": "usageStreamIndex",
1035
+ "type": "integer",
1036
+ "primaryKey": false,
1037
+ "notNull": true,
1038
+ "default": 0
1039
+ }
1040
+ },
1041
+ "indexes": {
1042
+ "EveSubagentSession_conversation": {
1043
+ "name": "EveSubagentSession_conversation",
1044
+ "columns": [
1045
+ {
1046
+ "expression": "conversationId",
1047
+ "isExpression": false,
1048
+ "asc": true,
1049
+ "nulls": "last"
1050
+ }
1051
+ ],
1052
+ "isUnique": false,
1053
+ "concurrently": false,
1054
+ "method": "btree",
1055
+ "with": {}
1056
+ }
1057
+ },
1058
+ "foreignKeys": {
1059
+ "EveSubagentSession_conversation_owner_fk": {
1060
+ "name": "EveSubagentSession_conversation_owner_fk",
1061
+ "tableFrom": "EveSubagentSession",
1062
+ "tableTo": "EveConversation",
1063
+ "columnsFrom": [
1064
+ "conversationId",
1065
+ "ownerId"
1066
+ ],
1067
+ "columnsTo": [
1068
+ "id",
1069
+ "ownerId"
1070
+ ],
1071
+ "onDelete": "cascade",
1072
+ "onUpdate": "no action"
1073
+ }
1074
+ },
1075
+ "compositePrimaryKeys": {},
1076
+ "uniqueConstraints": {},
1077
+ "policies": {},
1078
+ "checkConstraints": {
1079
+ "EveSubagentSession_not_self": {
1080
+ "name": "EveSubagentSession_not_self",
1081
+ "value": "\"EveSubagentSession\".\"sessionId\" <> \"EveSubagentSession\".\"parentSessionId\""
1082
+ },
1083
+ "EveSubagentSession_cursor": {
1084
+ "name": "EveSubagentSession_cursor",
1085
+ "value": "\"EveSubagentSession\".\"usageStreamIndex\" >= 0"
1086
+ }
1087
+ },
1088
+ "isRLSEnabled": false
1089
+ },
1090
+ "public.EveUsage": {
1091
+ "name": "EveUsage",
1092
+ "schema": "",
1093
+ "columns": {
1094
+ "chargedCents": {
1095
+ "name": "chargedCents",
1096
+ "type": "integer",
1097
+ "primaryKey": false,
1098
+ "notNull": true,
1099
+ "default": 0
1100
+ },
1101
+ "costUsd": {
1102
+ "name": "costUsd",
1103
+ "type": "numeric(24, 12)",
1104
+ "primaryKey": false,
1105
+ "notNull": false
1106
+ },
1107
+ "createdAt": {
1108
+ "name": "createdAt",
1109
+ "type": "timestamp",
1110
+ "primaryKey": false,
1111
+ "notNull": true,
1112
+ "default": "now()"
1113
+ },
1114
+ "eventId": {
1115
+ "name": "eventId",
1116
+ "type": "text",
1117
+ "primaryKey": true,
1118
+ "notNull": true
1119
+ },
1120
+ "generationId": {
1121
+ "name": "generationId",
1122
+ "type": "text",
1123
+ "primaryKey": false,
1124
+ "notNull": false
1125
+ },
1126
+ "modelAttempt": {
1127
+ "name": "modelAttempt",
1128
+ "type": "jsonb",
1129
+ "primaryKey": false,
1130
+ "notNull": false
1131
+ },
1132
+ "ownerId": {
1133
+ "name": "ownerId",
1134
+ "type": "text",
1135
+ "primaryKey": false,
1136
+ "notNull": true
1137
+ },
1138
+ "sessionId": {
1139
+ "name": "sessionId",
1140
+ "type": "text",
1141
+ "primaryKey": false,
1142
+ "notNull": true
1143
+ },
1144
+ "turnId": {
1145
+ "name": "turnId",
1146
+ "type": "text",
1147
+ "primaryKey": false,
1148
+ "notNull": true
1149
+ }
1150
+ },
1151
+ "indexes": {
1152
+ "EveUsage_session_turn": {
1153
+ "name": "EveUsage_session_turn",
1154
+ "columns": [
1155
+ {
1156
+ "expression": "sessionId",
1157
+ "isExpression": false,
1158
+ "asc": true,
1159
+ "nulls": "last"
1160
+ },
1161
+ {
1162
+ "expression": "turnId",
1163
+ "isExpression": false,
1164
+ "asc": true,
1165
+ "nulls": "last"
1166
+ }
1167
+ ],
1168
+ "isUnique": false,
1169
+ "concurrently": false,
1170
+ "method": "btree",
1171
+ "with": {}
1172
+ },
1173
+ "EveUsage_unpriced_owner": {
1174
+ "name": "EveUsage_unpriced_owner",
1175
+ "columns": [
1176
+ {
1177
+ "expression": "ownerId",
1178
+ "isExpression": false,
1179
+ "asc": true,
1180
+ "nulls": "last"
1181
+ }
1182
+ ],
1183
+ "isUnique": false,
1184
+ "where": "\"EveUsage\".\"costUsd\" is null",
1185
+ "concurrently": false,
1186
+ "method": "btree",
1187
+ "with": {}
1188
+ }
1189
+ },
1190
+ "foreignKeys": {
1191
+ "EveUsage_ownerId_user_id_fk": {
1192
+ "name": "EveUsage_ownerId_user_id_fk",
1193
+ "tableFrom": "EveUsage",
1194
+ "tableTo": "user",
1195
+ "columnsFrom": [
1196
+ "ownerId"
1197
+ ],
1198
+ "columnsTo": [
1199
+ "id"
1200
+ ],
1201
+ "onDelete": "no action",
1202
+ "onUpdate": "no action"
1203
+ }
1204
+ },
1205
+ "compositePrimaryKeys": {},
1206
+ "uniqueConstraints": {},
1207
+ "policies": {},
1208
+ "checkConstraints": {},
1209
+ "isRLSEnabled": false
1210
+ },
1211
+ "public.EveWorkflowBackend": {
1212
+ "name": "EveWorkflowBackend",
1213
+ "schema": "",
1214
+ "columns": {
1215
+ "id": {
1216
+ "name": "id",
1217
+ "type": "integer",
1218
+ "primaryKey": true,
1219
+ "notNull": true,
1220
+ "default": 1
1221
+ },
1222
+ "world": {
1223
+ "name": "world",
1224
+ "type": "text",
1225
+ "primaryKey": false,
1226
+ "notNull": true
1227
+ }
1228
+ },
1229
+ "indexes": {},
1230
+ "foreignKeys": {},
1231
+ "compositePrimaryKeys": {},
1232
+ "uniqueConstraints": {},
1233
+ "policies": {},
1234
+ "checkConstraints": {
1235
+ "EveWorkflowBackend_singleton": {
1236
+ "name": "EveWorkflowBackend_singleton",
1237
+ "value": "\"EveWorkflowBackend\".\"id\" = 1"
1238
+ }
1239
+ },
1240
+ "isRLSEnabled": false
1241
+ },
1242
+ "public.EveWorkspace": {
1243
+ "name": "EveWorkspace",
1244
+ "schema": "",
1245
+ "columns": {
1246
+ "id": {
1247
+ "name": "id",
1248
+ "type": "uuid",
1249
+ "primaryKey": true,
1250
+ "notNull": true,
1251
+ "default": "gen_random_uuid()"
1252
+ },
1253
+ "ownerId": {
1254
+ "name": "ownerId",
1255
+ "type": "text",
1256
+ "primaryKey": false,
1257
+ "notNull": true
1258
+ },
1259
+ "state": {
1260
+ "name": "state",
1261
+ "type": "text",
1262
+ "primaryKey": false,
1263
+ "notNull": true,
1264
+ "default": "'active'"
1265
+ },
1266
+ "activeOperationId": {
1267
+ "name": "activeOperationId",
1268
+ "type": "uuid",
1269
+ "primaryKey": false,
1270
+ "notNull": false
1271
+ }
1272
+ },
1273
+ "indexes": {},
1274
+ "foreignKeys": {
1275
+ "EveWorkspace_ownerId_user_id_fk": {
1276
+ "name": "EveWorkspace_ownerId_user_id_fk",
1277
+ "tableFrom": "EveWorkspace",
1278
+ "tableTo": "user",
1279
+ "columnsFrom": [
1280
+ "ownerId"
1281
+ ],
1282
+ "columnsTo": [
1283
+ "id"
1284
+ ],
1285
+ "onDelete": "cascade",
1286
+ "onUpdate": "no action"
1287
+ }
1288
+ },
1289
+ "compositePrimaryKeys": {},
1290
+ "uniqueConstraints": {
1291
+ "EveWorkspace_id_owner": {
1292
+ "name": "EveWorkspace_id_owner",
1293
+ "nullsNotDistinct": false,
1294
+ "columns": [
1295
+ "id",
1296
+ "ownerId"
1297
+ ]
1298
+ }
1299
+ },
1300
+ "policies": {},
1301
+ "checkConstraints": {},
1302
+ "isRLSEnabled": false
1303
+ },
1304
+ "public.session": {
1305
+ "name": "session",
1306
+ "schema": "",
1307
+ "columns": {
1308
+ "created_at": {
1309
+ "name": "created_at",
1310
+ "type": "timestamp",
1311
+ "primaryKey": false,
1312
+ "notNull": true,
1313
+ "default": "now()"
1314
+ },
1315
+ "expires_at": {
1316
+ "name": "expires_at",
1317
+ "type": "timestamp",
1318
+ "primaryKey": false,
1319
+ "notNull": true
1320
+ },
1321
+ "id": {
1322
+ "name": "id",
1323
+ "type": "text",
1324
+ "primaryKey": true,
1325
+ "notNull": true
1326
+ },
1327
+ "ip_address": {
1328
+ "name": "ip_address",
1329
+ "type": "text",
1330
+ "primaryKey": false,
1331
+ "notNull": false
1332
+ },
1333
+ "token": {
1334
+ "name": "token",
1335
+ "type": "text",
1336
+ "primaryKey": false,
1337
+ "notNull": true
1338
+ },
1339
+ "updated_at": {
1340
+ "name": "updated_at",
1341
+ "type": "timestamp",
1342
+ "primaryKey": false,
1343
+ "notNull": true
1344
+ },
1345
+ "user_agent": {
1346
+ "name": "user_agent",
1347
+ "type": "text",
1348
+ "primaryKey": false,
1349
+ "notNull": false
1350
+ },
1351
+ "user_id": {
1352
+ "name": "user_id",
1353
+ "type": "text",
1354
+ "primaryKey": false,
1355
+ "notNull": true
1356
+ }
1357
+ },
1358
+ "indexes": {},
1359
+ "foreignKeys": {
1360
+ "session_user_id_user_id_fk": {
1361
+ "name": "session_user_id_user_id_fk",
1362
+ "tableFrom": "session",
1363
+ "tableTo": "user",
1364
+ "columnsFrom": [
1365
+ "user_id"
1366
+ ],
1367
+ "columnsTo": [
1368
+ "id"
1369
+ ],
1370
+ "onDelete": "cascade",
1371
+ "onUpdate": "no action"
1372
+ }
1373
+ },
1374
+ "compositePrimaryKeys": {},
1375
+ "uniqueConstraints": {
1376
+ "session_token_unique": {
1377
+ "name": "session_token_unique",
1378
+ "nullsNotDistinct": false,
1379
+ "columns": [
1380
+ "token"
1381
+ ]
1382
+ }
1383
+ },
1384
+ "policies": {},
1385
+ "checkConstraints": {},
1386
+ "isRLSEnabled": false
1387
+ },
1388
+ "public.user": {
1389
+ "name": "user",
1390
+ "schema": "",
1391
+ "columns": {
1392
+ "created_at": {
1393
+ "name": "created_at",
1394
+ "type": "timestamp",
1395
+ "primaryKey": false,
1396
+ "notNull": true,
1397
+ "default": "now()"
1398
+ },
1399
+ "email": {
1400
+ "name": "email",
1401
+ "type": "text",
1402
+ "primaryKey": false,
1403
+ "notNull": true
1404
+ },
1405
+ "email_verified": {
1406
+ "name": "email_verified",
1407
+ "type": "boolean",
1408
+ "primaryKey": false,
1409
+ "notNull": true,
1410
+ "default": false
1411
+ },
1412
+ "eve_usage_reconciled_at": {
1413
+ "name": "eve_usage_reconciled_at",
1414
+ "type": "timestamp",
1415
+ "primaryKey": false,
1416
+ "notNull": false
1417
+ },
1418
+ "id": {
1419
+ "name": "id",
1420
+ "type": "text",
1421
+ "primaryKey": true,
1422
+ "notNull": true
1423
+ },
1424
+ "image": {
1425
+ "name": "image",
1426
+ "type": "text",
1427
+ "primaryKey": false,
1428
+ "notNull": false
1429
+ },
1430
+ "name": {
1431
+ "name": "name",
1432
+ "type": "text",
1433
+ "primaryKey": false,
1434
+ "notNull": true
1435
+ },
1436
+ "updated_at": {
1437
+ "name": "updated_at",
1438
+ "type": "timestamp",
1439
+ "primaryKey": false,
1440
+ "notNull": true,
1441
+ "default": "now()"
1442
+ }
1443
+ },
1444
+ "indexes": {},
1445
+ "foreignKeys": {},
1446
+ "compositePrimaryKeys": {},
1447
+ "uniqueConstraints": {
1448
+ "user_email_unique": {
1449
+ "name": "user_email_unique",
1450
+ "nullsNotDistinct": false,
1451
+ "columns": [
1452
+ "email"
1453
+ ]
1454
+ }
1455
+ },
1456
+ "policies": {},
1457
+ "checkConstraints": {},
1458
+ "isRLSEnabled": false
1459
+ },
1460
+ "public.verification": {
1461
+ "name": "verification",
1462
+ "schema": "",
1463
+ "columns": {
1464
+ "created_at": {
1465
+ "name": "created_at",
1466
+ "type": "timestamp",
1467
+ "primaryKey": false,
1468
+ "notNull": true,
1469
+ "default": "now()"
1470
+ },
1471
+ "expires_at": {
1472
+ "name": "expires_at",
1473
+ "type": "timestamp",
1474
+ "primaryKey": false,
1475
+ "notNull": true
1476
+ },
1477
+ "id": {
1478
+ "name": "id",
1479
+ "type": "text",
1480
+ "primaryKey": true,
1481
+ "notNull": true
1482
+ },
1483
+ "identifier": {
1484
+ "name": "identifier",
1485
+ "type": "text",
1486
+ "primaryKey": false,
1487
+ "notNull": true
1488
+ },
1489
+ "updated_at": {
1490
+ "name": "updated_at",
1491
+ "type": "timestamp",
1492
+ "primaryKey": false,
1493
+ "notNull": true,
1494
+ "default": "now()"
1495
+ },
1496
+ "value": {
1497
+ "name": "value",
1498
+ "type": "text",
1499
+ "primaryKey": false,
1500
+ "notNull": true
1501
+ }
1502
+ },
1503
+ "indexes": {},
1504
+ "foreignKeys": {},
1505
+ "compositePrimaryKeys": {},
1506
+ "uniqueConstraints": {},
1507
+ "policies": {},
1508
+ "checkConstraints": {},
1509
+ "isRLSEnabled": false
1510
+ },
1511
+ "public.UserCredit": {
1512
+ "name": "UserCredit",
1513
+ "schema": "",
1514
+ "columns": {
1515
+ "credits": {
1516
+ "name": "credits",
1517
+ "type": "integer",
1518
+ "primaryKey": false,
1519
+ "notNull": true,
1520
+ "default": 50
1521
+ },
1522
+ "userId": {
1523
+ "name": "userId",
1524
+ "type": "text",
1525
+ "primaryKey": true,
1526
+ "notNull": true
1527
+ }
1528
+ },
1529
+ "indexes": {},
1530
+ "foreignKeys": {
1531
+ "UserCredit_userId_user_id_fk": {
1532
+ "name": "UserCredit_userId_user_id_fk",
1533
+ "tableFrom": "UserCredit",
1534
+ "tableTo": "user",
1535
+ "columnsFrom": [
1536
+ "userId"
1537
+ ],
1538
+ "columnsTo": [
1539
+ "id"
1540
+ ],
1541
+ "onDelete": "cascade",
1542
+ "onUpdate": "no action"
1543
+ }
1544
+ },
1545
+ "compositePrimaryKeys": {},
1546
+ "uniqueConstraints": {},
1547
+ "policies": {},
1548
+ "checkConstraints": {},
1549
+ "isRLSEnabled": false
1550
+ },
1551
+ "public.EveVote": {
1552
+ "name": "EveVote",
1553
+ "schema": "",
1554
+ "columns": {
1555
+ "conversationId": {
1556
+ "name": "conversationId",
1557
+ "type": "uuid",
1558
+ "primaryKey": false,
1559
+ "notNull": true
1560
+ },
1561
+ "isUpvoted": {
1562
+ "name": "isUpvoted",
1563
+ "type": "boolean",
1564
+ "primaryKey": false,
1565
+ "notNull": true
1566
+ },
1567
+ "messageId": {
1568
+ "name": "messageId",
1569
+ "type": "text",
1570
+ "primaryKey": false,
1571
+ "notNull": true
1572
+ }
1573
+ },
1574
+ "indexes": {},
1575
+ "foreignKeys": {
1576
+ "EveVote_conversationId_EveConversation_id_fk": {
1577
+ "name": "EveVote_conversationId_EveConversation_id_fk",
1578
+ "tableFrom": "EveVote",
1579
+ "tableTo": "EveConversation",
1580
+ "columnsFrom": [
1581
+ "conversationId"
1582
+ ],
1583
+ "columnsTo": [
1584
+ "id"
1585
+ ],
1586
+ "onDelete": "cascade",
1587
+ "onUpdate": "no action"
1588
+ }
1589
+ },
1590
+ "compositePrimaryKeys": {
1591
+ "EveVote_conversationId_messageId_pk": {
1592
+ "name": "EveVote_conversationId_messageId_pk",
1593
+ "columns": [
1594
+ "conversationId",
1595
+ "messageId"
1596
+ ]
1597
+ }
1598
+ },
1599
+ "uniqueConstraints": {},
1600
+ "policies": {},
1601
+ "checkConstraints": {},
1602
+ "isRLSEnabled": false
1603
+ },
1604
+ "public.EveFollowup": {
1605
+ "name": "EveFollowup",
1606
+ "schema": "",
1607
+ "columns": {
1608
+ "chatId": {
1609
+ "name": "chatId",
1610
+ "type": "uuid",
1611
+ "primaryKey": false,
1612
+ "notNull": true
1613
+ },
1614
+ "ownerId": {
1615
+ "name": "ownerId",
1616
+ "type": "text",
1617
+ "primaryKey": false,
1618
+ "notNull": true
1619
+ },
1620
+ "turnId": {
1621
+ "name": "turnId",
1622
+ "type": "text",
1623
+ "primaryKey": false,
1624
+ "notNull": true
1625
+ },
1626
+ "sessionId": {
1627
+ "name": "sessionId",
1628
+ "type": "text",
1629
+ "primaryKey": false,
1630
+ "notNull": true
1631
+ },
1632
+ "eventId": {
1633
+ "name": "eventId",
1634
+ "type": "text",
1635
+ "primaryKey": true,
1636
+ "notNull": true
1637
+ },
1638
+ "suggestions": {
1639
+ "name": "suggestions",
1640
+ "type": "jsonb",
1641
+ "primaryKey": false,
1642
+ "notNull": false
1643
+ }
1644
+ },
1645
+ "indexes": {
1646
+ "EveFollowup_chat": {
1647
+ "name": "EveFollowup_chat",
1648
+ "columns": [
1649
+ {
1650
+ "expression": "chatId",
1651
+ "isExpression": false,
1652
+ "asc": true,
1653
+ "nulls": "last"
1654
+ }
1655
+ ],
1656
+ "isUnique": false,
1657
+ "concurrently": false,
1658
+ "method": "btree",
1659
+ "with": {}
1660
+ }
1661
+ },
1662
+ "foreignKeys": {
1663
+ "EveFollowup_chatId_ownerId_EveChat_id_ownerId_fk": {
1664
+ "name": "EveFollowup_chatId_ownerId_EveChat_id_ownerId_fk",
1665
+ "tableFrom": "EveFollowup",
1666
+ "tableTo": "EveChat",
1667
+ "columnsFrom": [
1668
+ "chatId",
1669
+ "ownerId"
1670
+ ],
1671
+ "columnsTo": [
1672
+ "id",
1673
+ "ownerId"
1674
+ ],
1675
+ "onDelete": "cascade",
1676
+ "onUpdate": "no action"
1677
+ }
1678
+ },
1679
+ "compositePrimaryKeys": {},
1680
+ "uniqueConstraints": {
1681
+ "EveFollowup_sessionId_turnId_unique": {
1682
+ "name": "EveFollowup_sessionId_turnId_unique",
1683
+ "nullsNotDistinct": false,
1684
+ "columns": [
1685
+ "sessionId",
1686
+ "turnId"
1687
+ ]
1688
+ }
1689
+ },
1690
+ "policies": {},
1691
+ "checkConstraints": {},
1692
+ "isRLSEnabled": false
1693
+ },
1694
+ "public.GuestRuntimeRate": {
1695
+ "name": "GuestRuntimeRate",
1696
+ "schema": "",
1697
+ "columns": {
1698
+ "ipHash": {
1699
+ "name": "ipHash",
1700
+ "type": "text",
1701
+ "primaryKey": false,
1702
+ "notNull": true
1703
+ },
1704
+ "kind": {
1705
+ "name": "kind",
1706
+ "type": "text",
1707
+ "primaryKey": false,
1708
+ "notNull": true
1709
+ },
1710
+ "startsAt": {
1711
+ "name": "startsAt",
1712
+ "type": "timestamp with time zone",
1713
+ "primaryKey": false,
1714
+ "notNull": true
1715
+ },
1716
+ "requests": {
1717
+ "name": "requests",
1718
+ "type": "integer",
1719
+ "primaryKey": false,
1720
+ "notNull": true,
1721
+ "default": 0
1722
+ }
1723
+ },
1724
+ "indexes": {},
1725
+ "foreignKeys": {},
1726
+ "compositePrimaryKeys": {
1727
+ "GuestRuntimeRate_ipHash_kind_startsAt_pk": {
1728
+ "name": "GuestRuntimeRate_ipHash_kind_startsAt_pk",
1729
+ "columns": [
1730
+ "ipHash",
1731
+ "kind",
1732
+ "startsAt"
1733
+ ]
1734
+ }
1735
+ },
1736
+ "uniqueConstraints": {},
1737
+ "policies": {},
1738
+ "checkConstraints": {
1739
+ "GuestRuntimeRate_requests": {
1740
+ "name": "GuestRuntimeRate_requests",
1741
+ "value": "\"GuestRuntimeRate\".\"requests\" >= 0"
1742
+ },
1743
+ "GuestRuntimeRate_kind": {
1744
+ "name": "GuestRuntimeRate_kind",
1745
+ "value": "\"GuestRuntimeRate\".\"kind\" in ('session', 'message')"
1746
+ }
1747
+ },
1748
+ "isRLSEnabled": false
1749
+ },
1750
+ "public.GuestRuntimeSession": {
1751
+ "name": "GuestRuntimeSession",
1752
+ "schema": "",
1753
+ "columns": {
1754
+ "id": {
1755
+ "name": "id",
1756
+ "type": "uuid",
1757
+ "primaryKey": true,
1758
+ "notNull": true,
1759
+ "default": "gen_random_uuid()"
1760
+ },
1761
+ "ownerId": {
1762
+ "name": "ownerId",
1763
+ "type": "text",
1764
+ "primaryKey": false,
1765
+ "notNull": true
1766
+ },
1767
+ "sessionId": {
1768
+ "name": "sessionId",
1769
+ "type": "text",
1770
+ "primaryKey": false,
1771
+ "notNull": false
1772
+ },
1773
+ "modelId": {
1774
+ "name": "modelId",
1775
+ "type": "text",
1776
+ "primaryKey": false,
1777
+ "notNull": true
1778
+ },
1779
+ "ipHash": {
1780
+ "name": "ipHash",
1781
+ "type": "text",
1782
+ "primaryKey": false,
1783
+ "notNull": true
1784
+ },
1785
+ "policyVersion": {
1786
+ "name": "policyVersion",
1787
+ "type": "integer",
1788
+ "primaryKey": false,
1789
+ "notNull": true,
1790
+ "default": 1
1791
+ },
1792
+ "state": {
1793
+ "name": "state",
1794
+ "type": "text",
1795
+ "primaryKey": false,
1796
+ "notNull": true,
1797
+ "default": "'active'"
1798
+ },
1799
+ "createdAt": {
1800
+ "name": "createdAt",
1801
+ "type": "timestamp with time zone",
1802
+ "primaryKey": false,
1803
+ "notNull": true,
1804
+ "default": "now()"
1805
+ },
1806
+ "expiresAt": {
1807
+ "name": "expiresAt",
1808
+ "type": "timestamp with time zone",
1809
+ "primaryKey": false,
1810
+ "notNull": true,
1811
+ "default": "now() + interval '24 hours'"
1812
+ },
1813
+ "credentialExpiresAt": {
1814
+ "name": "credentialExpiresAt",
1815
+ "type": "timestamp with time zone",
1816
+ "primaryKey": false,
1817
+ "notNull": true
1818
+ },
1819
+ "inputCharactersUsed": {
1820
+ "name": "inputCharactersUsed",
1821
+ "type": "integer",
1822
+ "primaryKey": false,
1823
+ "notNull": true,
1824
+ "default": 0
1825
+ },
1826
+ "cleanupAttemptedAt": {
1827
+ "name": "cleanupAttemptedAt",
1828
+ "type": "timestamp with time zone",
1829
+ "primaryKey": false,
1830
+ "notNull": false
1831
+ },
1832
+ "deletedAt": {
1833
+ "name": "deletedAt",
1834
+ "type": "timestamp with time zone",
1835
+ "primaryKey": false,
1836
+ "notNull": false
1837
+ }
1838
+ },
1839
+ "indexes": {
1840
+ "GuestRuntimeSession_cleanup_idx": {
1841
+ "name": "GuestRuntimeSession_cleanup_idx",
1842
+ "columns": [
1843
+ {
1844
+ "expression": "state",
1845
+ "isExpression": false,
1846
+ "asc": true,
1847
+ "nulls": "last"
1848
+ },
1849
+ {
1850
+ "expression": "expiresAt",
1851
+ "isExpression": false,
1852
+ "asc": true,
1853
+ "nulls": "last"
1854
+ }
1855
+ ],
1856
+ "isUnique": false,
1857
+ "concurrently": false,
1858
+ "method": "btree",
1859
+ "with": {}
1860
+ }
1861
+ },
1862
+ "foreignKeys": {},
1863
+ "compositePrimaryKeys": {},
1864
+ "uniqueConstraints": {
1865
+ "GuestRuntimeSession_ownerId_unique": {
1866
+ "name": "GuestRuntimeSession_ownerId_unique",
1867
+ "nullsNotDistinct": false,
1868
+ "columns": [
1869
+ "ownerId"
1870
+ ]
1871
+ },
1872
+ "GuestRuntimeSession_sessionId_unique": {
1873
+ "name": "GuestRuntimeSession_sessionId_unique",
1874
+ "nullsNotDistinct": false,
1875
+ "columns": [
1876
+ "sessionId"
1877
+ ]
1878
+ }
1879
+ },
1880
+ "policies": {},
1881
+ "checkConstraints": {
1882
+ "GuestRuntimeSession_state": {
1883
+ "name": "GuestRuntimeSession_state",
1884
+ "value": "\"GuestRuntimeSession\".\"state\" in ('active', 'deleting', 'deleted')"
1885
+ },
1886
+ "GuestRuntimeSession_ip_hash": {
1887
+ "name": "GuestRuntimeSession_ip_hash",
1888
+ "value": "\"GuestRuntimeSession\".\"ipHash\" ~ '^[0-9a-f]{64}$'"
1889
+ },
1890
+ "GuestRuntimeSession_expiry": {
1891
+ "name": "GuestRuntimeSession_expiry",
1892
+ "value": "\"GuestRuntimeSession\".\"expiresAt\" = \"GuestRuntimeSession\".\"createdAt\" + interval '24 hours'"
1893
+ }
1894
+ },
1895
+ "isRLSEnabled": false
1896
+ },
1897
+ "public.McpConnector": {
1898
+ "name": "McpConnector",
1899
+ "schema": "",
1900
+ "columns": {
1901
+ "createdAt": {
1902
+ "name": "createdAt",
1903
+ "type": "timestamp",
1904
+ "primaryKey": false,
1905
+ "notNull": true,
1906
+ "default": "now()"
1907
+ },
1908
+ "enabled": {
1909
+ "name": "enabled",
1910
+ "type": "boolean",
1911
+ "primaryKey": false,
1912
+ "notNull": true,
1913
+ "default": true
1914
+ },
1915
+ "id": {
1916
+ "name": "id",
1917
+ "type": "uuid",
1918
+ "primaryKey": true,
1919
+ "notNull": true,
1920
+ "default": "gen_random_uuid()"
1921
+ },
1922
+ "name": {
1923
+ "name": "name",
1924
+ "type": "varchar(256)",
1925
+ "primaryKey": false,
1926
+ "notNull": true
1927
+ },
1928
+ "nameId": {
1929
+ "name": "nameId",
1930
+ "type": "varchar(256)",
1931
+ "primaryKey": false,
1932
+ "notNull": true
1933
+ },
1934
+ "oauthClientId": {
1935
+ "name": "oauthClientId",
1936
+ "type": "text",
1937
+ "primaryKey": false,
1938
+ "notNull": false
1939
+ },
1940
+ "oauthClientSecret": {
1941
+ "name": "oauthClientSecret",
1942
+ "type": "text",
1943
+ "primaryKey": false,
1944
+ "notNull": false
1945
+ },
1946
+ "requireApproval": {
1947
+ "name": "requireApproval",
1948
+ "type": "boolean",
1949
+ "primaryKey": false,
1950
+ "notNull": true,
1951
+ "default": false
1952
+ },
1953
+ "type": {
1954
+ "name": "type",
1955
+ "type": "varchar",
1956
+ "primaryKey": false,
1957
+ "notNull": true,
1958
+ "default": "'http'"
1959
+ },
1960
+ "updatedAt": {
1961
+ "name": "updatedAt",
1962
+ "type": "timestamp",
1963
+ "primaryKey": false,
1964
+ "notNull": true,
1965
+ "default": "now()"
1966
+ },
1967
+ "url": {
1968
+ "name": "url",
1969
+ "type": "text",
1970
+ "primaryKey": false,
1971
+ "notNull": true
1972
+ },
1973
+ "userId": {
1974
+ "name": "userId",
1975
+ "type": "text",
1976
+ "primaryKey": false,
1977
+ "notNull": false
1978
+ }
1979
+ },
1980
+ "indexes": {
1981
+ "McpConnector_user_id_idx": {
1982
+ "name": "McpConnector_user_id_idx",
1983
+ "columns": [
1984
+ {
1985
+ "expression": "userId",
1986
+ "isExpression": false,
1987
+ "asc": true,
1988
+ "nulls": "last"
1989
+ }
1990
+ ],
1991
+ "isUnique": false,
1992
+ "concurrently": false,
1993
+ "method": "btree",
1994
+ "with": {}
1995
+ },
1996
+ "McpConnector_user_name_id_idx": {
1997
+ "name": "McpConnector_user_name_id_idx",
1998
+ "columns": [
1999
+ {
2000
+ "expression": "userId",
2001
+ "isExpression": false,
2002
+ "asc": true,
2003
+ "nulls": "last"
2004
+ },
2005
+ {
2006
+ "expression": "nameId",
2007
+ "isExpression": false,
2008
+ "asc": true,
2009
+ "nulls": "last"
2010
+ }
2011
+ ],
2012
+ "isUnique": false,
2013
+ "concurrently": false,
2014
+ "method": "btree",
2015
+ "with": {}
2016
+ },
2017
+ "McpConnector_user_name_id_unique": {
2018
+ "name": "McpConnector_user_name_id_unique",
2019
+ "columns": [
2020
+ {
2021
+ "expression": "userId",
2022
+ "isExpression": false,
2023
+ "asc": true,
2024
+ "nulls": "last"
2025
+ },
2026
+ {
2027
+ "expression": "nameId",
2028
+ "isExpression": false,
2029
+ "asc": true,
2030
+ "nulls": "last"
2031
+ }
2032
+ ],
2033
+ "isUnique": true,
2034
+ "concurrently": false,
2035
+ "method": "btree",
2036
+ "with": {}
2037
+ }
2038
+ },
2039
+ "foreignKeys": {
2040
+ "McpConnector_userId_user_id_fk": {
2041
+ "name": "McpConnector_userId_user_id_fk",
2042
+ "tableFrom": "McpConnector",
2043
+ "tableTo": "user",
2044
+ "columnsFrom": [
2045
+ "userId"
2046
+ ],
2047
+ "columnsTo": [
2048
+ "id"
2049
+ ],
2050
+ "onDelete": "cascade",
2051
+ "onUpdate": "no action"
2052
+ }
2053
+ },
2054
+ "compositePrimaryKeys": {},
2055
+ "uniqueConstraints": {},
2056
+ "policies": {},
2057
+ "checkConstraints": {},
2058
+ "isRLSEnabled": false
2059
+ },
2060
+ "public.McpOAuthSession": {
2061
+ "name": "McpOAuthSession",
2062
+ "schema": "",
2063
+ "columns": {
2064
+ "clientInfo": {
2065
+ "name": "clientInfo",
2066
+ "type": "text",
2067
+ "primaryKey": false,
2068
+ "notNull": false
2069
+ },
2070
+ "codeVerifier": {
2071
+ "name": "codeVerifier",
2072
+ "type": "text",
2073
+ "primaryKey": false,
2074
+ "notNull": false
2075
+ },
2076
+ "createdAt": {
2077
+ "name": "createdAt",
2078
+ "type": "timestamp",
2079
+ "primaryKey": false,
2080
+ "notNull": true,
2081
+ "default": "now()"
2082
+ },
2083
+ "id": {
2084
+ "name": "id",
2085
+ "type": "uuid",
2086
+ "primaryKey": true,
2087
+ "notNull": true,
2088
+ "default": "gen_random_uuid()"
2089
+ },
2090
+ "mcpConnectorId": {
2091
+ "name": "mcpConnectorId",
2092
+ "type": "uuid",
2093
+ "primaryKey": false,
2094
+ "notNull": true
2095
+ },
2096
+ "serverUrl": {
2097
+ "name": "serverUrl",
2098
+ "type": "text",
2099
+ "primaryKey": false,
2100
+ "notNull": true
2101
+ },
2102
+ "state": {
2103
+ "name": "state",
2104
+ "type": "text",
2105
+ "primaryKey": false,
2106
+ "notNull": false
2107
+ },
2108
+ "tokens": {
2109
+ "name": "tokens",
2110
+ "type": "text",
2111
+ "primaryKey": false,
2112
+ "notNull": false
2113
+ },
2114
+ "updatedAt": {
2115
+ "name": "updatedAt",
2116
+ "type": "timestamp",
2117
+ "primaryKey": false,
2118
+ "notNull": true,
2119
+ "default": "now()"
2120
+ }
2121
+ },
2122
+ "indexes": {
2123
+ "McpOAuthSession_connector_idx": {
2124
+ "name": "McpOAuthSession_connector_idx",
2125
+ "columns": [
2126
+ {
2127
+ "expression": "mcpConnectorId",
2128
+ "isExpression": false,
2129
+ "asc": true,
2130
+ "nulls": "last"
2131
+ }
2132
+ ],
2133
+ "isUnique": false,
2134
+ "concurrently": false,
2135
+ "method": "btree",
2136
+ "with": {}
2137
+ },
2138
+ "McpOAuthSession_state_idx": {
2139
+ "name": "McpOAuthSession_state_idx",
2140
+ "columns": [
2141
+ {
2142
+ "expression": "state",
2143
+ "isExpression": false,
2144
+ "asc": true,
2145
+ "nulls": "last"
2146
+ }
2147
+ ],
2148
+ "isUnique": false,
2149
+ "concurrently": false,
2150
+ "method": "btree",
2151
+ "with": {}
2152
+ }
2153
+ },
2154
+ "foreignKeys": {
2155
+ "McpOAuthSession_mcpConnectorId_McpConnector_id_fk": {
2156
+ "name": "McpOAuthSession_mcpConnectorId_McpConnector_id_fk",
2157
+ "tableFrom": "McpOAuthSession",
2158
+ "tableTo": "McpConnector",
2159
+ "columnsFrom": [
2160
+ "mcpConnectorId"
2161
+ ],
2162
+ "columnsTo": [
2163
+ "id"
2164
+ ],
2165
+ "onDelete": "cascade",
2166
+ "onUpdate": "no action"
2167
+ }
2168
+ },
2169
+ "compositePrimaryKeys": {},
2170
+ "uniqueConstraints": {
2171
+ "McpOAuthSession_state_unique": {
2172
+ "name": "McpOAuthSession_state_unique",
2173
+ "nullsNotDistinct": false,
2174
+ "columns": [
2175
+ "state"
2176
+ ]
2177
+ }
2178
+ },
2179
+ "policies": {},
2180
+ "checkConstraints": {},
2181
+ "isRLSEnabled": false
2182
+ },
2183
+ "public.UserModelPreference": {
2184
+ "name": "UserModelPreference",
2185
+ "schema": "",
2186
+ "columns": {
2187
+ "createdAt": {
2188
+ "name": "createdAt",
2189
+ "type": "timestamp",
2190
+ "primaryKey": false,
2191
+ "notNull": true,
2192
+ "default": "now()"
2193
+ },
2194
+ "enabled": {
2195
+ "name": "enabled",
2196
+ "type": "boolean",
2197
+ "primaryKey": false,
2198
+ "notNull": true
2199
+ },
2200
+ "modelId": {
2201
+ "name": "modelId",
2202
+ "type": "varchar(256)",
2203
+ "primaryKey": false,
2204
+ "notNull": true
2205
+ },
2206
+ "updatedAt": {
2207
+ "name": "updatedAt",
2208
+ "type": "timestamp",
2209
+ "primaryKey": false,
2210
+ "notNull": true,
2211
+ "default": "now()"
2212
+ },
2213
+ "userId": {
2214
+ "name": "userId",
2215
+ "type": "text",
2216
+ "primaryKey": false,
2217
+ "notNull": true
2218
+ }
2219
+ },
2220
+ "indexes": {
2221
+ "UserModelPreference_user_id_idx": {
2222
+ "name": "UserModelPreference_user_id_idx",
2223
+ "columns": [
2224
+ {
2225
+ "expression": "userId",
2226
+ "isExpression": false,
2227
+ "asc": true,
2228
+ "nulls": "last"
2229
+ }
2230
+ ],
2231
+ "isUnique": false,
2232
+ "concurrently": false,
2233
+ "method": "btree",
2234
+ "with": {}
2235
+ }
2236
+ },
2237
+ "foreignKeys": {
2238
+ "UserModelPreference_userId_user_id_fk": {
2239
+ "name": "UserModelPreference_userId_user_id_fk",
2240
+ "tableFrom": "UserModelPreference",
2241
+ "tableTo": "user",
2242
+ "columnsFrom": [
2243
+ "userId"
2244
+ ],
2245
+ "columnsTo": [
2246
+ "id"
2247
+ ],
2248
+ "onDelete": "cascade",
2249
+ "onUpdate": "no action"
2250
+ }
2251
+ },
2252
+ "compositePrimaryKeys": {
2253
+ "UserModelPreference_userId_modelId_pk": {
2254
+ "name": "UserModelPreference_userId_modelId_pk",
2255
+ "columns": [
2256
+ "userId",
2257
+ "modelId"
2258
+ ]
2259
+ }
2260
+ },
2261
+ "uniqueConstraints": {},
2262
+ "policies": {},
2263
+ "checkConstraints": {},
2264
+ "isRLSEnabled": false
2265
+ },
2266
+ "public.EveChatProject": {
2267
+ "name": "EveChatProject",
2268
+ "schema": "",
2269
+ "columns": {
2270
+ "chatId": {
2271
+ "name": "chatId",
2272
+ "type": "uuid",
2273
+ "primaryKey": true,
2274
+ "notNull": true
2275
+ },
2276
+ "ownerId": {
2277
+ "name": "ownerId",
2278
+ "type": "text",
2279
+ "primaryKey": false,
2280
+ "notNull": true
2281
+ },
2282
+ "projectId": {
2283
+ "name": "projectId",
2284
+ "type": "uuid",
2285
+ "primaryKey": false,
2286
+ "notNull": true
2287
+ }
2288
+ },
2289
+ "indexes": {
2290
+ "EveChatProject_project": {
2291
+ "name": "EveChatProject_project",
2292
+ "columns": [
2293
+ {
2294
+ "expression": "projectId",
2295
+ "isExpression": false,
2296
+ "asc": true,
2297
+ "nulls": "last"
2298
+ }
2299
+ ],
2300
+ "isUnique": false,
2301
+ "concurrently": false,
2302
+ "method": "btree",
2303
+ "with": {}
2304
+ }
2305
+ },
2306
+ "foreignKeys": {
2307
+ "EveChatProject_chatId_ownerId_EveChat_id_ownerId_fk": {
2308
+ "name": "EveChatProject_chatId_ownerId_EveChat_id_ownerId_fk",
2309
+ "tableFrom": "EveChatProject",
2310
+ "tableTo": "EveChat",
2311
+ "columnsFrom": [
2312
+ "chatId",
2313
+ "ownerId"
2314
+ ],
2315
+ "columnsTo": [
2316
+ "id",
2317
+ "ownerId"
2318
+ ],
2319
+ "onDelete": "cascade",
2320
+ "onUpdate": "no action"
2321
+ },
2322
+ "EveChatProject_projectId_ownerId_Project_id_userId_fk": {
2323
+ "name": "EveChatProject_projectId_ownerId_Project_id_userId_fk",
2324
+ "tableFrom": "EveChatProject",
2325
+ "tableTo": "Project",
2326
+ "columnsFrom": [
2327
+ "projectId",
2328
+ "ownerId"
2329
+ ],
2330
+ "columnsTo": [
2331
+ "id",
2332
+ "userId"
2333
+ ],
2334
+ "onDelete": "cascade",
2335
+ "onUpdate": "no action"
2336
+ }
2337
+ },
2338
+ "compositePrimaryKeys": {},
2339
+ "uniqueConstraints": {},
2340
+ "policies": {},
2341
+ "checkConstraints": {},
2342
+ "isRLSEnabled": false
2343
+ },
2344
+ "public.Project": {
2345
+ "name": "Project",
2346
+ "schema": "",
2347
+ "columns": {
2348
+ "createdAt": {
2349
+ "name": "createdAt",
2350
+ "type": "timestamp",
2351
+ "primaryKey": false,
2352
+ "notNull": true,
2353
+ "default": "now()"
2354
+ },
2355
+ "icon": {
2356
+ "name": "icon",
2357
+ "type": "varchar(64)",
2358
+ "primaryKey": false,
2359
+ "notNull": true,
2360
+ "default": "'folder'"
2361
+ },
2362
+ "iconColor": {
2363
+ "name": "iconColor",
2364
+ "type": "varchar(32)",
2365
+ "primaryKey": false,
2366
+ "notNull": true,
2367
+ "default": "'gray'"
2368
+ },
2369
+ "id": {
2370
+ "name": "id",
2371
+ "type": "uuid",
2372
+ "primaryKey": true,
2373
+ "notNull": true,
2374
+ "default": "gen_random_uuid()"
2375
+ },
2376
+ "instructions": {
2377
+ "name": "instructions",
2378
+ "type": "text",
2379
+ "primaryKey": false,
2380
+ "notNull": true,
2381
+ "default": "''"
2382
+ },
2383
+ "name": {
2384
+ "name": "name",
2385
+ "type": "text",
2386
+ "primaryKey": false,
2387
+ "notNull": true
2388
+ },
2389
+ "updatedAt": {
2390
+ "name": "updatedAt",
2391
+ "type": "timestamp",
2392
+ "primaryKey": false,
2393
+ "notNull": true,
2394
+ "default": "now()"
2395
+ },
2396
+ "userId": {
2397
+ "name": "userId",
2398
+ "type": "text",
2399
+ "primaryKey": false,
2400
+ "notNull": true
2401
+ }
2402
+ },
2403
+ "indexes": {
2404
+ "Project_user_id_idx": {
2405
+ "name": "Project_user_id_idx",
2406
+ "columns": [
2407
+ {
2408
+ "expression": "userId",
2409
+ "isExpression": false,
2410
+ "asc": true,
2411
+ "nulls": "last"
2412
+ }
2413
+ ],
2414
+ "isUnique": false,
2415
+ "concurrently": false,
2416
+ "method": "btree",
2417
+ "with": {}
2418
+ }
2419
+ },
2420
+ "foreignKeys": {
2421
+ "Project_userId_user_id_fk": {
2422
+ "name": "Project_userId_user_id_fk",
2423
+ "tableFrom": "Project",
2424
+ "tableTo": "user",
2425
+ "columnsFrom": [
2426
+ "userId"
2427
+ ],
2428
+ "columnsTo": [
2429
+ "id"
2430
+ ],
2431
+ "onDelete": "cascade",
2432
+ "onUpdate": "no action"
2433
+ }
2434
+ },
2435
+ "compositePrimaryKeys": {},
2436
+ "uniqueConstraints": {
2437
+ "Project_id_user": {
2438
+ "name": "Project_id_user",
2439
+ "nullsNotDistinct": false,
2440
+ "columns": [
2441
+ "id",
2442
+ "userId"
2443
+ ]
2444
+ }
2445
+ },
2446
+ "policies": {},
2447
+ "checkConstraints": {},
2448
+ "isRLSEnabled": false
2449
+ },
2450
+ "public.EveSearchText": {
2451
+ "name": "EveSearchText",
2452
+ "schema": "",
2453
+ "columns": {
2454
+ "conversationId": {
2455
+ "name": "conversationId",
2456
+ "type": "uuid",
2457
+ "primaryKey": false,
2458
+ "notNull": true
2459
+ },
2460
+ "key": {
2461
+ "name": "key",
2462
+ "type": "text",
2463
+ "primaryKey": false,
2464
+ "notNull": true
2465
+ },
2466
+ "ownerId": {
2467
+ "name": "ownerId",
2468
+ "type": "text",
2469
+ "primaryKey": false,
2470
+ "notNull": true
2471
+ },
2472
+ "text": {
2473
+ "name": "text",
2474
+ "type": "text",
2475
+ "primaryKey": false,
2476
+ "notNull": true
2477
+ }
2478
+ },
2479
+ "indexes": {
2480
+ "EveSearchText_owner": {
2481
+ "name": "EveSearchText_owner",
2482
+ "columns": [
2483
+ {
2484
+ "expression": "ownerId",
2485
+ "isExpression": false,
2486
+ "asc": true,
2487
+ "nulls": "last"
2488
+ }
2489
+ ],
2490
+ "isUnique": false,
2491
+ "concurrently": false,
2492
+ "method": "btree",
2493
+ "with": {}
2494
+ },
2495
+ "EveSearchText_content": {
2496
+ "name": "EveSearchText_content",
2497
+ "columns": [
2498
+ {
2499
+ "expression": "to_tsvector('simple', \"text\")",
2500
+ "asc": true,
2501
+ "isExpression": true,
2502
+ "nulls": "last"
2503
+ }
2504
+ ],
2505
+ "isUnique": false,
2506
+ "concurrently": false,
2507
+ "method": "gin",
2508
+ "with": {}
2509
+ }
2510
+ },
2511
+ "foreignKeys": {
2512
+ "EveSearchText_conversationId_ownerId_EveConversation_id_ownerId_fk": {
2513
+ "name": "EveSearchText_conversationId_ownerId_EveConversation_id_ownerId_fk",
2514
+ "tableFrom": "EveSearchText",
2515
+ "tableTo": "EveConversation",
2516
+ "columnsFrom": [
2517
+ "conversationId",
2518
+ "ownerId"
2519
+ ],
2520
+ "columnsTo": [
2521
+ "id",
2522
+ "ownerId"
2523
+ ],
2524
+ "onDelete": "cascade",
2525
+ "onUpdate": "no action"
2526
+ }
2527
+ },
2528
+ "compositePrimaryKeys": {
2529
+ "EveSearchText_conversationId_key_pk": {
2530
+ "name": "EveSearchText_conversationId_key_pk",
2531
+ "columns": [
2532
+ "conversationId",
2533
+ "key"
2534
+ ]
2535
+ }
2536
+ },
2537
+ "uniqueConstraints": {},
2538
+ "policies": {},
2539
+ "checkConstraints": {},
2540
+ "isRLSEnabled": false
2541
+ }
2542
+ },
2543
+ "enums": {},
2544
+ "schemas": {},
2545
+ "sequences": {},
2546
+ "roles": {},
2547
+ "policies": {},
2548
+ "views": {},
2549
+ "_meta": {
2550
+ "columns": {},
2551
+ "schemas": {},
2552
+ "tables": {}
2553
+ }
2554
+ }