@sentry/junior 0.313.0 → 0.315.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (652) hide show
  1. package/dist/{channel-access-mt7K6dPh.js → adapter-context-BlSGE44V.js} +46 -7
  2. package/dist/{admin-Cyhb4TwZ.js → admin-5jUYY46p.js} +1 -1
  3. package/dist/agent-runner-C7GNLRB6.js +23438 -0
  4. package/dist/agent-update-delivery-BNEYQsAf.js +149 -0
  5. package/dist/api/schema.d.ts +9500 -2
  6. package/dist/api/schema.js +5 -7
  7. package/dist/api.d.ts +2 -3
  8. package/dist/api.js +1172 -371
  9. package/dist/{app-DA8-hCMj.d.ts → app-D_bAXRDe.d.ts} +312 -48
  10. package/dist/app.d.ts +2 -2
  11. package/dist/app.js +305 -184
  12. package/dist/change-record-Bqsa5ZXE.d.ts +175 -0
  13. package/dist/chat-core-engine-CxkwRpn9.js +123 -0
  14. package/dist/child-message--2G3Ft26.js +19 -0
  15. package/dist/cli/chat.d.ts +4 -1
  16. package/dist/cli/chat.js +40 -25
  17. package/dist/cli/check.js +4 -4
  18. package/dist/cli/main.js +2 -2
  19. package/dist/cli/plugins.js +4 -5
  20. package/dist/cli/run.d.ts +1 -1
  21. package/dist/cli/run.js +1 -1
  22. package/dist/cli/snapshot-create.js +2 -5
  23. package/dist/cli/upgrade.d.ts +1 -1
  24. package/dist/cli/upgrade.js +68 -97
  25. package/dist/{continue-in-slack-CxyFzdlF.js → continue-in-slack-BGKjIdFp.js} +3 -7
  26. package/dist/{conversation-feed-BEXLD3Me.js → conversation-feed-Sl8lKKmR.js} +22 -2
  27. package/dist/{conversation-turn-B35eu0uz.js → conversation-turn-BoLK9i6g.js} +514 -83
  28. package/dist/create-BOycVH9h.js +213 -0
  29. package/dist/{credential-sync-DWTOEQrm.js → credential-sync-Mn4OdkEh.js} +10 -18
  30. package/dist/db-BpxcYXfD.d.ts +2 -0
  31. package/dist/{credentialed-Dyv8b-lu.js → db-DXTOYRzR.js} +22220 -9334
  32. package/dist/deployment-CG3TchWh.js +51 -0
  33. package/dist/direct-url-BYgYfuIy.js +22 -0
  34. package/dist/engine-context-dyWlfNdD.js +1817 -0
  35. package/dist/{html-DidUcRhI.js → html-CfXEwl_h.js} +2 -7
  36. package/dist/instrumentation.js +3 -3
  37. package/dist/job-runner-CySgpi9v.js +1131 -0
  38. package/dist/{lineage-BXplQAVH.js → lineage-tRTOcrsL.js} +1 -2
  39. package/dist/{list-DyIyReSV.js → list-DXBz8SYL.js} +610 -173
  40. package/dist/local-server-CpnGhYml.js +276 -0
  41. package/dist/{logging-DNt-qOIO.js → logging-czs0nqLC.js} +2 -45
  42. package/dist/{turn-membership-DTR3SaKD.js → mailbox-turn-79Nv1JXv.js} +4153 -559
  43. package/dist/markers-CE0HMXWT.js +67 -0
  44. package/dist/{media-B0pZJ0bG.js → media-Cr9pGkzr.js} +701 -41
  45. package/dist/{message-Z5YKC-Af.js → message-BTox2Cmb.js} +25 -36
  46. package/dist/{model-input-BhPJYdSV.js → model-input-IRGa98V7.js} +3 -3
  47. package/dist/nitro.d.ts +8 -4
  48. package/dist/nitro.js +106 -24
  49. package/dist/{oauth-callback-server-ByvDdcdY.js → oauth-callback-server-NXK7AlBp.js} +2 -2
  50. package/dist/{oauth-relay-D-kK0yoN.js → oauth-relay-6NBPSpFE.js} +1 -1
  51. package/dist/{package-discovery-DD9vencX.js → package-discovery-BI6T_RkD.js} +50 -1
  52. package/dist/parent-result-Dg6P6roR.js +323 -0
  53. package/dist/people-Cegp1Iwq.js +81 -0
  54. package/dist/{plugins-Bkk0XRo2.js → plugins-BXMdNdyA.js} +1 -1
  55. package/dist/{conversation-privacy-BrMiDN61.js → proxy-path-Dc-0jXGi.js} +16 -2
  56. package/dist/{resolve-CWtBNSKP.js → resolve-BUFkmxkT.js} +229 -4
  57. package/dist/result-DfATzX77.js +337 -0
  58. package/dist/{runner-CsZ_VRxp.js → runner-CmKP3inb.js} +7 -8
  59. package/dist/{sandbox-egress-signals-FbCk1FkN.js → sandbox-egress-signals-DYo5BsM7.js} +1 -1
  60. package/dist/{schema-DojR2uCL.js → schema-DrBMdPmv.js} +197 -20
  61. package/dist/{service-account-CDYb9hfX.js → service-account-CxTX7nnR.js} +4 -5
  62. package/dist/{skills-B0jP4whm.js → skills-BlHUDj7k.js} +4 -4
  63. package/dist/{slack-conversation-unfurl-D26t9kBC.js → slack-conversation-unfurl-Dhe3lB1U.js} +6 -10
  64. package/dist/{spawn-BjljgExZ.js → spawn-CfvlFdfz.js} +8 -17
  65. package/dist/start-conversation-Uh8Sk1EF.js +162 -0
  66. package/dist/system-prompt-table-CDCYVwqN.js +1169 -0
  67. package/dist/{task-runner--Ke8KSMf.js → task-runner-DcdQJd9e.js} +163 -55
  68. package/dist/{thread-context-B8exINEe.js → thread-context-DF5uDcWN.js} +7 -9
  69. package/dist/topic-CRYYBYp-.js +7 -0
  70. package/dist/transcript-BHhJVY0P.js +410 -0
  71. package/dist/turn-session-routing-GtetHsdO.js +1309 -0
  72. package/dist/turn-wake-um5Ubd4m.js +152 -0
  73. package/dist/user-customization-B27StpVQ.js +9 -0
  74. package/dist/{validation-Ce0qbMlT.js → validation-CJyuOPD2.js} +1 -1
  75. package/dist/{version-DFh4n9nr.js → version-Bhe7RPIe.js} +1 -1
  76. package/dist/version.js +1 -1
  77. package/dist/virtual-module-BeKA_EII.js +12 -0
  78. package/dist/{worker-CDg9Lbpg.js → worker-D8PRgUqr.js} +3 -6
  79. package/migrations/20260711145847_initial/snapshot.json +2103 -0
  80. package/migrations/20260711145900_conversation_metrics/snapshot.json +135 -0
  81. package/migrations/20260712153649_conversation_message_search/snapshot.json +50 -0
  82. package/migrations/20260713040256_peaceful_scalphunter/snapshot.json +42 -0
  83. package/migrations/20260715174202_useful_magus/snapshot.json +42 -0
  84. package/migrations/20260715174203_conversation_events/snapshot.json +539 -0
  85. package/migrations/20260723042835_drop_legacy_conversation_messages/snapshot.json +9 -0
  86. package/migrations/20260723050612_thick_sugar_man/snapshot.json +120 -0
  87. package/migrations/20260727223822_sticky_rage/snapshot.json +274 -0
  88. package/migrations/20260728033158_slippery_harrier/snapshot.json +191 -0
  89. package/migrations/20260728040836_native_conversation_history/snapshot.json +9 -0
  90. package/migrations/20260728204900_sour_golden_guardian/snapshot.json +124 -0
  91. package/migrations/20260730233332_structured_conversation_events/snapshot.json +9 -0
  92. package/migrations/20260731164038_conversation_session_source/snapshot.json +42 -0
  93. package/migrations/20260801230336_source_visibility/snapshot.json +9 -0
  94. package/migrations/20260802023731_magical_ezekiel_stane/snapshot.json +266 -0
  95. package/migrations/20260804015843_neat_the_anarchist/snapshot.json +714 -0
  96. package/migrations/20260804165952_drop_paused_scheduled_tasks/snapshot.json +9 -0
  97. package/migrations/20260804225613_curvy_excalibur/snapshot.json +223 -0
  98. package/migrations/20260805174033_lowly_valkyrie/snapshot.json +344 -0
  99. package/migrations/20260805200301_restrict_task_execution_kinds/snapshot.json +36 -0
  100. package/migrations/20260806030729_first_warhawk/snapshot.json +690 -0
  101. package/migrations/20260807185200_task_execution_status/snapshot.json +92 -0
  102. package/migrations/20260808014743_task_title_columns/snapshot.json +68 -0
  103. package/migrations/20260809220421_misty_typhoid_mary/snapshot.json +191 -0
  104. package/migrations/20260811193709_mcp_credential_subject/snapshot.json +9 -0
  105. package/migrations/20260812032924_conversation_event_actor_and_participants/snapshot.json +393 -0
  106. package/migrations/20260812172418_attachment_storage/snapshot.json +341 -0
  107. package/migrations/20260813230732_artifacts/snapshot.json +349 -0
  108. package/migrations/20260814062905_dizzy_barracuda/snapshot.json +342 -0
  109. package/migrations/20260814231353_drop_workspace_repo_primary/snapshot.json +55 -0
  110. package/migrations/20260815030100_wild_phantom_reporter/snapshot.json +135 -0
  111. package/migrations/20260817082233_workspace_snapshots_table/snapshot.json +625 -0
  112. package/migrations/20260818160339_workspace_snapshot_active_build/snapshot.json +62 -0
  113. package/migrations/20260821180755_strong_randall/snapshot.json +42 -0
  114. package/migrations/20260823030308_workspace_snapshot_size_bytes/snapshot.json +62 -0
  115. package/migrations/20260824190313_complex_rage/snapshot.json +690 -0
  116. package/migrations/20260827233711_conversation_location/snapshot.json +42 -0
  117. package/migrations/20260901224306_event_task_status/snapshot.json +100 -0
  118. package/migrations/20260904153232_attachment_provider/snapshot.json +234 -0
  119. package/migrations/20260909111415_conversation_briefs/snapshot.json +364 -0
  120. package/migrations/20260910144928_automation_outcomes_backfill/snapshot.json +9 -0
  121. package/migrations/20260911184346_conversation_metrics/snapshot.json +226 -0
  122. package/migrations/20260921140842_scheduled_automation_channel_destinations/snapshot.json +9 -0
  123. package/migrations/20260922221709_event_automation_channel_destinations/snapshot.json +9 -0
  124. package/migrations/20261001113455_conversation_forks/snapshot.json +120 -0
  125. package/migrations/20261005161844_automation_versions/snapshot.json +150 -0
  126. package/migrations/20261006152043_user_timezone/snapshot.json +37 -0
  127. package/migrations/20261008200858_user_admin/snapshot.json +37 -0
  128. package/migrations/20261009145407_event_automation_status_reason/snapshot.json +42 -0
  129. package/migrations/20261013160816_agent_invocation_parent_mailbox/snapshot.json +93 -0
  130. package/migrations/20261013215020_agent_invocation_parent_tool_call/snapshot.json +42 -0
  131. package/migrations/20261014011138_agent_invocation_title/snapshot.json +42 -0
  132. package/migrations/20261014211942_conversation_stopped_at/snapshot.json +42 -0
  133. package/migrations/20261015012820_flowery_rage/snapshot.json +42 -0
  134. package/migrations/20261017000924_automations/snapshot.json +790 -0
  135. package/migrations/20261017134736_automation_runs/snapshot.json +474 -0
  136. package/migrations/20261017170250_drop_legacy_automation_tables/snapshot.json +397 -0
  137. package/migrations/20261018134754_automation_creator_identity/snapshot.json +130 -0
  138. package/migrations/20261023071954_automation_run_version/snapshot.json +79 -0
  139. package/migrations/20261025233137_identity_signed_in_at/snapshot.json +42 -0
  140. package/migrations/20261027234315_workspace_vcpus/snapshot.json +37 -0
  141. package/migrations/20261028124242_plugin_report_index/snapshot.json +68 -0
  142. package/migrations/20261028154230_agent_invocation_type/snapshot.json +42 -0
  143. package/migrations/20261030021803_any_resource_event_triggers/snapshot.json +42 -0
  144. package/migrations/20261030234309_user_customization/snapshot.json +37 -0
  145. package/migrations/20261031020656_review_items/snapshot.json +1078 -0
  146. package/migrations/20261031024151_review_item_dedupe_tenant/snapshot.json +62 -0
  147. package/migrations/20261031024246_review_item_slack_cards/snapshot.json +159 -0
  148. package/migrations/20261031155308_system_identity/snapshot.json +9 -0
  149. package/migrations/20261101193952_review_item_foreign_keys/snapshot.json +108 -0
  150. package/migrations/20261102172751_review_item_turn/snapshot.json +42 -0
  151. package/migrations/20261102221411_conversation_read_positions/snapshot.json +190 -0
  152. package/migrations/20261104085028_conversation_quick_question/snapshot.json +42 -0
  153. package/migrations/20261104145136_conversation_participant_pins/snapshot.json +42 -0
  154. package/migrations/20261104164429_conversation_detail_version/snapshot.json +42 -0
  155. package/migrations/20261104172055_conversation_auto_archive/snapshot.json +206 -0
  156. package/migrations/20261105005443_drop_agent_invocation_model_profile/snapshot.json +30 -0
  157. package/migrations/20261105043807_plugin_conversation_index/snapshot.json +76 -0
  158. package/migrations/20261105051837_conversation_event_author_index/snapshot.json +70 -0
  159. package/migrations/20261105182854_conversation_event_latest_message_indexes/snapshot.json +136 -0
  160. package/migrations/20261106011443_conversation_pin_position/snapshot.json +42 -0
  161. package/migrations/20261106095004_push_notifications/snapshot.json +308 -0
  162. package/migrations/20261106162740_conversation_kind/snapshot.json +88 -0
  163. package/migrations/20261107002001_read_position_backfill/snapshot.json +9 -0
  164. package/migrations/20261107025209_child_archived_at/snapshot.json +42 -0
  165. package/migrations/20261107035735_shared_archive/snapshot.json +67 -0
  166. package/migrations/20261107215055_child_location/snapshot.json +9 -0
  167. package/migrations/20261108191927_conversation_unsubscribe/snapshot.json +42 -0
  168. package/migrations/20261109021618_conversation_paused_status/snapshot.json +9 -0
  169. package/migrations/20261109111553_guardian_review_time_index/snapshot.json +54 -0
  170. package/migrations/20261109173130_conversation_participant_unsubscribed_index/snapshot.json +62 -0
  171. package/migrations/20261109182006_turn_metric_actor/snapshot.json +128 -0
  172. package/migrations/20261109202836_participant_root_actor_backfill/snapshot.json +9 -0
  173. package/migrations/20261109232640_conversation_delivery_paused_at/snapshot.json +42 -0
  174. package/migrations/20261110120937_web_linked_slack_identity_repair/snapshot.json +9 -0
  175. package/migrations/20261110175824_automation_task_kind/snapshot.json +145 -0
  176. package/migrations/20261110210242_conversation_kind_automation/snapshot.json +55 -0
  177. package/migrations/20261110222632_review_item_plugin_actions/snapshot.json +37 -0
  178. package/migrations/20261110225157_conversation_last_message_at/snapshot.json +42 -0
  179. package/migrations/20261111013351_automation_task_kind_repair/snapshot.json +9 -0
  180. package/migrations/20261111163126_drop_legacy_columns/snapshot.json +9 -0
  181. package/migrations/20261111170150_code_change_last_activity/snapshot.json +42 -0
  182. package/migrations/20261111191441_agent_invocation_fork/snapshot.json +42 -0
  183. package/migrations/20261112142841_code_change_draft/snapshot.json +37 -0
  184. package/migrations/20261112202901_attachment_uploads/snapshot.json +255 -0
  185. package/migrations/20261112220407_conversation_agent_config/snapshot.json +42 -0
  186. package/migrations/20261113081247_attachment_deferred_download/snapshot.json +52 -0
  187. package/migrations/20261113225551_conversation_embeddings/snapshot.json +203 -0
  188. package/migrations/20261114213238_user_preferences/snapshot.json +37 -0
  189. package/migrations/20261114222527_code_change_repository_state_index/snapshot.json +70 -0
  190. package/migrations/20261115172605_attachment_kinds/snapshot.json +244 -0
  191. package/migrations/20261115173004_attachment_url_fill/snapshot.json +9 -0
  192. package/migrations/20261115180216_attachment_url_index/snapshot.json +62 -0
  193. package/migrations/20261116103700_plan_items/snapshot.json +420 -0
  194. package/migrations/20261117100100_automation_creator_slack_index/snapshot.json +62 -0
  195. package/migrations/20261117132522_conversation_event_search/snapshot.json +396 -0
  196. package/migrations/20261117164007_automation_last_run/snapshot.json +108 -0
  197. package/migrations/20261117164047_automation_last_run_index/snapshot.json +54 -0
  198. package/migrations/20261117210444_money_micro_usd/snapshot.json +68 -0
  199. package/migrations/20261117210505_conversation_cost_micro_usd/snapshot.json +9 -0
  200. package/migrations/20261118081416_people_list_metric_index/snapshot.json +86 -0
  201. package/migrations/20261118095216_automation_rollout_repair/snapshot.json +9 -0
  202. package/migrations/20261118143948_cache_warming_history_reset/snapshot.json +9 -0
  203. package/migrations/20261119040651_artifact_visibility/snapshot.json +132 -0
  204. package/migrations/20261119040715_artifact_public_sha_index/snapshot.json +9 -0
  205. package/migrations/20261119052706_artifact_drop_public/snapshot.json +71 -0
  206. package/migrations/20261119053831_artifact_path/snapshot.json +114 -0
  207. package/migrations/20261119053844_artifact_path_index/snapshot.json +9 -0
  208. package/migrations/20261119091949_review_item_answered_index/snapshot.json +70 -0
  209. package/migrations/20261119100029_review_item_status_index/snapshot.json +54 -0
  210. package/migrations/20261119165607_brief_outcome_status/snapshot.json +42 -0
  211. package/migrations/20261119165622_brief_outcome_status_backfill/snapshot.json +9 -0
  212. package/migrations/20261119213716_brief_created_at_index/snapshot.json +62 -0
  213. package/migrations/20261119222456_slack_person_search_index/snapshot.json +50 -0
  214. package/migrations/20261119225522_code_change_size/snapshot.json +104 -0
  215. package/migrations/20261119232253_merge_conflict_notice_dismiss/snapshot.json +9 -0
  216. package/migrations/20261119235649_inbox_snoozes/snapshot.json +605 -0
  217. package/migrations/20261120093118_code_change_search_index/snapshot.json +89 -0
  218. package/migrations/20261120093452_review_item_owner/snapshot.json +314 -0
  219. package/migrations/20261120185654_review_item_owner_index/snapshot.json +62 -0
  220. package/migrations/20261120185754_memory_core_adoption/snapshot.json +1184 -0
  221. package/migrations/20261120185854_memory_core_indexes/snapshot.json +70 -0
  222. package/migrations/20261120235226_todos/snapshot.json +473 -0
  223. package/migrations/20261121082316_inbox_items/snapshot.json +2026 -0
  224. package/migrations/20261121175651_todo_changed_by_agent/snapshot.json +42 -0
  225. package/migrations/20261121183527_inbox_item_subject_title_parts/snapshot.json +42 -0
  226. package/migrations/20261121194143_inbox_snooze_wake_reason/snapshot.json +42 -0
  227. package/migrations/20261121222400_authorization_request_index/snapshot.json +62 -0
  228. package/migrations/20261121225908_conversation_metadata/snapshot.json +184 -0
  229. package/migrations/20261121225910_conversation_metadata_fill/snapshot.json +9 -0
  230. package/migrations/20261121225913_conversation_search_index/snapshot.json +50 -0
  231. package/migrations/20261122022900_inbox_item_legacy_automation_keys/snapshot.json +9 -0
  232. package/migrations/20261122024454_artifact_expiry/snapshot.json +37 -0
  233. package/migrations/20261122024455_artifact_permanent_sha_index/snapshot.json +62 -0
  234. package/migrations/20261122024457_artifact_drop_public_sha_index/snapshot.json +37 -0
  235. package/migrations/20261122024458_conversation_kind_lead/snapshot.json +55 -0
  236. package/migrations/20261122024459_conversation_lead_actor_index/snapshot.json +54 -0
  237. package/migrations/20261122071549_keep_legacy_archive_columns/snapshot.json +49 -0
  238. package/migrations/20261122191400_conversation_embeddings_fk_validate/snapshot.json +9 -0
  239. package/migrations/20261122204325_money_micro_usd_repair/migration.sql +99 -0
  240. package/migrations/20261122204325_money_micro_usd_repair/snapshot.json +9 -0
  241. package/migrations/20261122204326_agent_config_backfill/migration.sql +34 -0
  242. package/migrations/20261122204326_agent_config_backfill/snapshot.json +143 -0
  243. package/migrations/20261122221456_inbox_item_deliveries/migration.sql +15 -0
  244. package/migrations/20261122221456_inbox_item_deliveries/snapshot.json +301 -0
  245. package/migrations/20261123155735_pg_trgm/migration.sql +2 -0
  246. package/migrations/20261123155735_pg_trgm/snapshot.json +9 -0
  247. package/migrations/20261123155739_search_indexes/migration.sql +4 -0
  248. package/migrations/20261123155739_search_indexes/snapshot.json +167 -0
  249. package/migrations/20261123172647_drop_legacy_archive_columns/migration.sql +4 -0
  250. package/migrations/20261123172647_drop_legacy_archive_columns/snapshot.json +9 -0
  251. package/migrations/20261123192506_memory_prefix_index/migration.sql +1 -0
  252. package/migrations/20261123192506_memory_prefix_index/snapshot.json +69 -0
  253. package/migrations/20261123201740_todo_search_indexes/migration.sql +2 -0
  254. package/migrations/20261123201740_todo_search_indexes/snapshot.json +89 -0
  255. package/migrations/20261123211505_todo_inbox_items/migration.sql +4 -0
  256. package/migrations/20261123211505_todo_inbox_items/snapshot.json +38 -0
  257. package/migrations/20261123214917_drop_code_urls/migration.sql +2 -0
  258. package/migrations/20261123214917_drop_code_urls/snapshot.json +44 -0
  259. package/migrations/20261123224000_code_change_conversations_index/migration.sql +1 -0
  260. package/migrations/20261123224000_code_change_conversations_index/snapshot.json +54 -0
  261. package/migrations/20261124122023_drop_code_change_sizes/migration.sql +4 -0
  262. package/migrations/20261124122023_drop_code_change_sizes/snapshot.json +82 -0
  263. package/migrations/20261124142958_conversation_root_lookup_index/migration.sql +1 -0
  264. package/migrations/20261124142958_conversation_root_lookup_index/snapshot.json +62 -0
  265. package/migrations/20261124183352_legacy_brief_metadata_fill/migration.sql +26 -0
  266. package/migrations/20261124183352_legacy_brief_metadata_fill/snapshot.json +114 -0
  267. package/migrations/20261124202143_drizzle_v1_baseline/migration.sql +5 -0
  268. package/migrations/20261124202143_drizzle_v1_baseline/snapshot.json +2012 -0
  269. package/migrations/20261124221751_spaces/migration.sql +22 -0
  270. package/migrations/20261124221751_spaces/snapshot.json +436 -0
  271. package/migrations/20261124230319_conversation_metrics_utc_day_stats/migration.sql +11 -0
  272. package/migrations/20261124230319_conversation_metrics_utc_day_stats/snapshot.json +9 -0
  273. package/migrations/20261124234024_space_conversations/migration.sql +5 -0
  274. package/migrations/20261124234024_space_conversations/snapshot.json +103 -0
  275. package/migrations/20261124234026_space_conversations_index/migration.sql +1 -0
  276. package/migrations/20261124234026_space_conversations_index/snapshot.json +62 -0
  277. package/migrations/20261125012448_drop_lead_actor_index/migration.sql +3 -0
  278. package/migrations/20261125012448_drop_lead_actor_index/snapshot.json +36 -0
  279. package/migrations/20261125012452_space_lead_index/migration.sql +1 -0
  280. package/migrations/20261125012452_space_lead_index/snapshot.json +54 -0
  281. package/migrations/20261125043821_space_configurations/migration.sql +11 -0
  282. package/migrations/20261125043821_space_configurations/snapshot.json +194 -0
  283. package/migrations/20261125064854_agent_update_done_status/migration.sql +9 -0
  284. package/migrations/20261125064854_agent_update_done_status/snapshot.json +9 -0
  285. package/migrations/20261125073321_turn_engine_tables/migration.sql +75 -0
  286. package/migrations/20261125073321_turn_engine_tables/snapshot.json +1497 -0
  287. package/migrations/20261125073339_turn_inbox_one_source/migration.sql +5 -0
  288. package/migrations/20261125073339_turn_inbox_one_source/snapshot.json +9 -0
  289. package/migrations/20261125124506_versions_notify/migration.sql +27 -0
  290. package/migrations/20261125124506_versions_notify/snapshot.json +9 -0
  291. package/migrations/20261125140339_turn_group_key/migration.sql +14 -0
  292. package/migrations/20261125140339_turn_group_key/snapshot.json +75 -0
  293. package/migrations/20261125140343_turn_group_key_not_null/migration.sql +4 -0
  294. package/migrations/20261125140343_turn_group_key_not_null/snapshot.json +29 -0
  295. package/migrations/20261125142845_code_change_requesters/migration.sql +1 -0
  296. package/migrations/20261125142845_code_change_requesters/snapshot.json +42 -0
  297. package/migrations/20261125142846_code_change_requesters_index/migration.sql +1 -0
  298. package/migrations/20261125142846_code_change_requesters_index/snapshot.json +54 -0
  299. package/migrations/20261125143903_space_visibility/migration.sql +1 -0
  300. package/migrations/20261125143903_space_visibility/snapshot.json +37 -0
  301. package/migrations/20261125154848_merge_leaves/migration.sql +2 -0
  302. package/migrations/20261125154848_merge_leaves/snapshot.json +14 -0
  303. package/package.json +17 -25
  304. package/skills/design-automation-skill/SKILL.md +3 -4
  305. package/dist/actor-BsBdxDXQ.js +0 -208
  306. package/dist/adapter-CYAvJzZS.js +0 -259
  307. package/dist/adapter-context-CVsHoVSf.js +0 -43
  308. package/dist/agent-runner-B5y9MsT-.js +0 -11295
  309. package/dist/background-compaction-queue-iZXadLV3.js +0 -206
  310. package/dist/catalog-runtime-kkE3hvCX.js +0 -6
  311. package/dist/config-CWbwKj0j.js +0 -2331
  312. package/dist/db-DYGcXYl3.d.ts +0 -274
  313. package/dist/db-PwSRzWWn.js +0 -3607
  314. package/dist/executor-CgWyWfYz.js +0 -1858
  315. package/dist/fan-out-Cod-yEHG.js +0 -10
  316. package/dist/history-CYstOMKX.js +0 -577
  317. package/dist/ingest-B0AggUEC.js +0 -7931
  318. package/dist/install-2urLLXNt.js +0 -228
  319. package/dist/proxy-path-BHYoKZdq.js +0 -15
  320. package/dist/registry-POH4bZC4.js +0 -1686
  321. package/dist/request-deadline-BUiRYQYj.js +0 -24
  322. package/dist/rule-DAxQY-1h.js +0 -20
  323. package/dist/schema-DBf18QPS.d.ts +0 -9339
  324. package/dist/service-account-o15pZWcJ.js +0 -931
  325. package/dist/start-conversation-DbVujrwO.js +0 -755
  326. package/dist/state-BTawTCme.js +0 -161
  327. package/dist/statuses-BKwqCPhj.js +0 -69
  328. package/dist/store-CjXrp-Up.js +0 -492
  329. package/dist/task-queue-Cwlatjz3.js +0 -90
  330. package/dist/vercel-queue-q4z8w5QO.js +0 -349
  331. package/dist/warmup-D5hzqTcp.js +0 -12257
  332. package/migrations/meta/0000_snapshot.json +0 -946
  333. package/migrations/meta/0001_snapshot.json +0 -972
  334. package/migrations/meta/0002_snapshot.json +0 -987
  335. package/migrations/meta/0003_snapshot.json +0 -1035
  336. package/migrations/meta/0004_snapshot.json +0 -1041
  337. package/migrations/meta/0005_snapshot.json +0 -948
  338. package/migrations/meta/0006_snapshot.json +0 -948
  339. package/migrations/meta/0007_snapshot.json +0 -1013
  340. package/migrations/meta/0008_snapshot.json +0 -1076
  341. package/migrations/meta/0009_snapshot.json +0 -1146
  342. package/migrations/meta/0010_snapshot.json +0 -1190
  343. package/migrations/meta/0011_snapshot.json +0 -1195
  344. package/migrations/meta/0012_snapshot.json +0 -1244
  345. package/migrations/meta/0013_snapshot.json +0 -1250
  346. package/migrations/meta/0014_snapshot.json +0 -1201
  347. package/migrations/meta/0015_snapshot.json +0 -1360
  348. package/migrations/meta/0016_snapshot.json +0 -1617
  349. package/migrations/meta/0017_snapshot.json +0 -1666
  350. package/migrations/meta/0018_snapshot.json +0 -1756
  351. package/migrations/meta/0019_snapshot.json +0 -1904
  352. package/migrations/meta/0020_snapshot.json +0 -1848
  353. package/migrations/meta/0021_snapshot.json +0 -2176
  354. package/migrations/meta/0022_snapshot.json +0 -2186
  355. package/migrations/meta/0023_snapshot.json +0 -2198
  356. package/migrations/meta/0024_snapshot.json +0 -2275
  357. package/migrations/meta/0025_snapshot.json +0 -2275
  358. package/migrations/meta/0026_snapshot.json +0 -2424
  359. package/migrations/meta/0027_snapshot.json +0 -2554
  360. package/migrations/meta/0028_snapshot.json +0 -2685
  361. package/migrations/meta/0029_snapshot.json +0 -2709
  362. package/migrations/meta/0030_snapshot.json +0 -2799
  363. package/migrations/meta/0031_snapshot.json +0 -2823
  364. package/migrations/meta/0032_snapshot.json +0 -2892
  365. package/migrations/meta/0033_snapshot.json +0 -2914
  366. package/migrations/meta/0034_snapshot.json +0 -3038
  367. package/migrations/meta/0035_snapshot.json +0 -3048
  368. package/migrations/meta/0036_snapshot.json +0 -3186
  369. package/migrations/meta/0037_snapshot.json +0 -3192
  370. package/migrations/meta/0038_snapshot.json +0 -3323
  371. package/migrations/meta/0039_snapshot.json +0 -3368
  372. package/migrations/meta/0040_snapshot.json +0 -3516
  373. package/migrations/meta/0041_snapshot.json +0 -3516
  374. package/migrations/meta/0042_snapshot.json +0 -3610
  375. package/migrations/meta/0043_snapshot.json +0 -3610
  376. package/migrations/meta/0044_snapshot.json +0 -3473
  377. package/migrations/meta/0045_snapshot.json +0 -3503
  378. package/migrations/meta/0046_snapshot.json +0 -3707
  379. package/migrations/meta/0047_snapshot.json +0 -3713
  380. package/migrations/meta/0048_snapshot.json +0 -3720
  381. package/migrations/meta/0049_snapshot.json +0 -3581
  382. package/migrations/meta/0050_snapshot.json +0 -3753
  383. package/migrations/meta/0051_snapshot.json +0 -3759
  384. package/migrations/meta/0052_snapshot.json +0 -3765
  385. package/migrations/meta/0053_snapshot.json +0 -3771
  386. package/migrations/meta/0054_snapshot.json +0 -3777
  387. package/migrations/meta/0055_snapshot.json +0 -3948
  388. package/migrations/meta/0056_snapshot.json +0 -4280
  389. package/migrations/meta/0057_snapshot.json +0 -3618
  390. package/migrations/meta/0058_snapshot.json +0 -3598
  391. package/migrations/meta/0059_snapshot.json +0 -3619
  392. package/migrations/meta/0060_snapshot.json +0 -3465
  393. package/migrations/meta/0061_snapshot.json +0 -3471
  394. package/migrations/meta/0062_snapshot.json +0 -3499
  395. package/migrations/meta/0063_snapshot.json +0 -3505
  396. package/migrations/meta/0064_snapshot.json +0 -3505
  397. package/migrations/meta/0065_snapshot.json +0 -3511
  398. package/migrations/meta/0066_snapshot.json +0 -4099
  399. package/migrations/meta/0067_snapshot.json +0 -3921
  400. package/migrations/meta/0068_snapshot.json +0 -4176
  401. package/migrations/meta/0069_snapshot.json +0 -3979
  402. package/migrations/meta/0070_snapshot.json +0 -3997
  403. package/migrations/meta/0071_snapshot.json +0 -4003
  404. package/migrations/meta/0072_snapshot.json +0 -4064
  405. package/migrations/meta/0073_snapshot.json +0 -4070
  406. package/migrations/meta/0074_snapshot.json +0 -4076
  407. package/migrations/meta/0075_snapshot.json +0 -4083
  408. package/migrations/meta/0076_snapshot.json +0 -4147
  409. package/migrations/meta/0077_snapshot.json +0 -4141
  410. package/migrations/meta/0078_snapshot.json +0 -4175
  411. package/migrations/meta/0079_snapshot.json +0 -4203
  412. package/migrations/meta/0080_snapshot.json +0 -4265
  413. package/migrations/meta/0081_snapshot.json +0 -4271
  414. package/migrations/meta/0082_snapshot.json +0 -4373
  415. package/migrations/meta/0083_snapshot.json +0 -4388
  416. package/migrations/meta/0084_snapshot.json +0 -4388
  417. package/migrations/meta/0085_snapshot.json +0 -4394
  418. package/migrations/meta/0086_snapshot.json +0 -4366
  419. package/migrations/meta/0087_snapshot.json +0 -4366
  420. package/migrations/meta/0088_snapshot.json +0 -4372
  421. package/migrations/meta/0089_snapshot.json +0 -4372
  422. package/migrations/meta/0090_snapshot.json +0 -4388
  423. package/migrations/meta/0091_snapshot.json +0 -4410
  424. package/migrations/meta/0092_snapshot.json +0 -4446
  425. package/migrations/meta/0093_snapshot.json +0 -4446
  426. package/migrations/meta/0094_snapshot.json +0 -4452
  427. package/migrations/meta/0095_snapshot.json +0 -4452
  428. package/migrations/meta/0096_snapshot.json +0 -4490
  429. package/migrations/meta/0097_snapshot.json +0 -4490
  430. package/migrations/meta/0098_snapshot.json +0 -4490
  431. package/migrations/meta/0099_snapshot.json +0 -4496
  432. package/migrations/meta/0100_snapshot.json +0 -4496
  433. package/migrations/meta/0101_snapshot.json +0 -4496
  434. package/migrations/meta/0102_snapshot.json +0 -4502
  435. package/migrations/meta/0103_snapshot.json +0 -4509
  436. package/migrations/meta/0104_snapshot.json +0 -4516
  437. package/migrations/meta/0105_snapshot.json +0 -4611
  438. package/migrations/meta/0106_snapshot.json +0 -4617
  439. package/migrations/meta/0107_snapshot.json +0 -4617
  440. package/migrations/meta/0108_snapshot.json +0 -4688
  441. package/migrations/meta/0109_snapshot.json +0 -4925
  442. package/migrations/meta/0110_snapshot.json +0 -4952
  443. package/migrations/meta/0111_snapshot.json +0 -5011
  444. package/migrations/meta/0112_snapshot.json +0 -5011
  445. package/migrations/meta/0113_snapshot.json +0 -5033
  446. package/migrations/meta/0114_snapshot.json +0 -5203
  447. package/migrations/meta/0115_snapshot.json +0 -5225
  448. package/migrations/meta/0116_snapshot.json +0 -5388
  449. package/migrations/meta/0117_snapshot.json +0 -5413
  450. package/migrations/meta/0118_snapshot.json +0 -5428
  451. package/migrations/meta/0119_snapshot.json +0 -5441
  452. package/migrations/meta/0120_snapshot.json +0 -5441
  453. package/migrations/meta/0121_snapshot.json +0 -5481
  454. package/migrations/meta/0122_snapshot.json +0 -5481
  455. package/migrations/meta/0123_snapshot.json +0 -5481
  456. package/migrations/meta/0124_snapshot.json +0 -5516
  457. package/migrations/meta/0125_snapshot.json +0 -5516
  458. package/migrations/meta/0126_snapshot.json +0 -5488
  459. package/migrations/meta/0127_snapshot.json +0 -5519
  460. package/migrations/meta/0128_snapshot.json +0 -5519
  461. package/migrations/meta/0129_snapshot.json +0 -5547
  462. package/migrations/meta/0130_snapshot.json +0 -5563
  463. package/migrations/meta/0131_snapshot.json +0 -5569
  464. package/migrations/meta/0132_snapshot.json +0 -5569
  465. package/migrations/meta/0133_snapshot.json +0 -5590
  466. package/migrations/meta/0134_snapshot.json +0 -5606
  467. package/migrations/meta/0135_snapshot.json +0 -5624
  468. package/migrations/meta/0136_snapshot.json +0 -5624
  469. package/migrations/meta/0137_snapshot.json +0 -5864
  470. package/migrations/meta/0138_snapshot.json +0 -5894
  471. package/migrations/meta/0139_snapshot.json +0 -5898
  472. package/migrations/meta/0140_snapshot.json +0 -5919
  473. package/migrations/meta/0141_snapshot.json +0 -6429
  474. package/migrations/meta/0142_snapshot.json +0 -6457
  475. package/migrations/meta/0143_snapshot.json +0 -6434
  476. package/migrations/meta/0144_snapshot.json +0 -6434
  477. package/migrations/meta/0145_snapshot.json +0 -6440
  478. package/migrations/meta/0146_snapshot.json +0 -6446
  479. package/migrations/meta/0147_snapshot.json +0 -6452
  480. package/migrations/meta/0148_snapshot.json +0 -6474
  481. package/migrations/meta/0149_snapshot.json +0 -6490
  482. package/migrations/meta/0150_snapshot.json +0 -6490
  483. package/migrations/meta/0151_snapshot.json +0 -6505
  484. package/migrations/meta/0152_snapshot.json +0 -6505
  485. package/migrations/meta/0153_snapshot.json +0 -6511
  486. package/migrations/meta/0154_snapshot.json +0 -6533
  487. package/migrations/meta/0155_snapshot.json +0 -6511
  488. package/migrations/meta/0156_snapshot.json +0 -6511
  489. package/migrations/meta/0157_snapshot.json +0 -6527
  490. package/migrations/meta/0158_snapshot.json +0 -6515
  491. package/migrations/meta/0159_snapshot.json +0 -6515
  492. package/migrations/meta/_journal.json +0 -1126
  493. /package/migrations/{0000_initial.sql → 20260711145847_initial/migration.sql} +0 -0
  494. /package/migrations/{0001_conversation_metrics.sql → 20260711145900_conversation_metrics/migration.sql} +0 -0
  495. /package/migrations/{0002_conversation_message_search.sql → 20260712153649_conversation_message_search/migration.sql} +0 -0
  496. /package/migrations/{0003_peaceful_scalphunter.sql → 20260713040256_peaceful_scalphunter/migration.sql} +0 -0
  497. /package/migrations/{0004_useful_magus.sql → 20260715174202_useful_magus/migration.sql} +0 -0
  498. /package/migrations/{0005_conversation_events.sql → 20260715174203_conversation_events/migration.sql} +0 -0
  499. /package/migrations/{0006_drop_legacy_conversation_messages.sql → 20260723042835_drop_legacy_conversation_messages/migration.sql} +0 -0
  500. /package/migrations/{0007_thick_sugar_man.sql → 20260723050612_thick_sugar_man/migration.sql} +0 -0
  501. /package/migrations/{0008_sticky_rage.sql → 20260727223822_sticky_rage/migration.sql} +0 -0
  502. /package/migrations/{0009_slippery_harrier.sql → 20260728033158_slippery_harrier/migration.sql} +0 -0
  503. /package/migrations/{0010_native_conversation_history.sql → 20260728040836_native_conversation_history/migration.sql} +0 -0
  504. /package/migrations/{0011_sour_golden_guardian.sql → 20260728204900_sour_golden_guardian/migration.sql} +0 -0
  505. /package/migrations/{0012_structured_conversation_events.sql → 20260730233332_structured_conversation_events/migration.sql} +0 -0
  506. /package/migrations/{0013_conversation_session_source.sql → 20260731164038_conversation_session_source/migration.sql} +0 -0
  507. /package/migrations/{0014_source_visibility.sql → 20260801230336_source_visibility/migration.sql} +0 -0
  508. /package/migrations/{0015_magical_ezekiel_stane.sql → 20260802023731_magical_ezekiel_stane/migration.sql} +0 -0
  509. /package/migrations/{0016_neat_the_anarchist.sql → 20260804015843_neat_the_anarchist/migration.sql} +0 -0
  510. /package/migrations/{0017_drop_paused_scheduled_tasks.sql → 20260804165952_drop_paused_scheduled_tasks/migration.sql} +0 -0
  511. /package/migrations/{0018_curvy_excalibur.sql → 20260804225613_curvy_excalibur/migration.sql} +0 -0
  512. /package/migrations/{0019_lowly_valkyrie.sql → 20260805174033_lowly_valkyrie/migration.sql} +0 -0
  513. /package/migrations/{0020_restrict_task_execution_kinds.sql → 20260805200301_restrict_task_execution_kinds/migration.sql} +0 -0
  514. /package/migrations/{0021_first_warhawk.sql → 20260806030729_first_warhawk/migration.sql} +0 -0
  515. /package/migrations/{0022_task_execution_status.sql → 20260807185200_task_execution_status/migration.sql} +0 -0
  516. /package/migrations/{0023_task_title_columns.sql → 20260808014743_task_title_columns/migration.sql} +0 -0
  517. /package/migrations/{0024_misty_typhoid_mary.sql → 20260809220421_misty_typhoid_mary/migration.sql} +0 -0
  518. /package/migrations/{0025_mcp_credential_subject.sql → 20260811193709_mcp_credential_subject/migration.sql} +0 -0
  519. /package/migrations/{0026_conversation_event_actor_and_participants.sql → 20260812032924_conversation_event_actor_and_participants/migration.sql} +0 -0
  520. /package/migrations/{0027_attachment_storage.sql → 20260812172418_attachment_storage/migration.sql} +0 -0
  521. /package/migrations/{0028_artifacts.sql → 20260813230732_artifacts/migration.sql} +0 -0
  522. /package/migrations/{0029_dizzy_barracuda.sql → 20260814062905_dizzy_barracuda/migration.sql} +0 -0
  523. /package/migrations/{0030_drop_workspace_repo_primary.sql → 20260814231353_drop_workspace_repo_primary/migration.sql} +0 -0
  524. /package/migrations/{0031_wild_phantom_reporter.sql → 20260815030100_wild_phantom_reporter/migration.sql} +0 -0
  525. /package/migrations/{0032_workspace_snapshots_table.sql → 20260817082233_workspace_snapshots_table/migration.sql} +0 -0
  526. /package/migrations/{0033_workspace_snapshot_active_build.sql → 20260818160339_workspace_snapshot_active_build/migration.sql} +0 -0
  527. /package/migrations/{0034_strong_randall.sql → 20260821180755_strong_randall/migration.sql} +0 -0
  528. /package/migrations/{0035_workspace_snapshot_size_bytes.sql → 20260823030308_workspace_snapshot_size_bytes/migration.sql} +0 -0
  529. /package/migrations/{0036_complex_rage.sql → 20260824190313_complex_rage/migration.sql} +0 -0
  530. /package/migrations/{0037_conversation_location.sql → 20260827233711_conversation_location/migration.sql} +0 -0
  531. /package/migrations/{0038_event_task_status.sql → 20260901224306_event_task_status/migration.sql} +0 -0
  532. /package/migrations/{0039_attachment_provider.sql → 20260904153232_attachment_provider/migration.sql} +0 -0
  533. /package/migrations/{0040_conversation_briefs.sql → 20260909111415_conversation_briefs/migration.sql} +0 -0
  534. /package/migrations/{0041_automation_outcomes_backfill.sql → 20260910144928_automation_outcomes_backfill/migration.sql} +0 -0
  535. /package/migrations/{0042_conversation_metrics.sql → 20260911184346_conversation_metrics/migration.sql} +0 -0
  536. /package/migrations/{0043_scheduled_automation_channel_destinations.sql → 20260921140842_scheduled_automation_channel_destinations/migration.sql} +0 -0
  537. /package/migrations/{0044_event_automation_channel_destinations.sql → 20260922221709_event_automation_channel_destinations/migration.sql} +0 -0
  538. /package/migrations/{0045_conversation_forks.sql → 20261001113455_conversation_forks/migration.sql} +0 -0
  539. /package/migrations/{0046_automation_versions.sql → 20261005161844_automation_versions/migration.sql} +0 -0
  540. /package/migrations/{0047_user_timezone.sql → 20261006152043_user_timezone/migration.sql} +0 -0
  541. /package/migrations/{0048_user_admin.sql → 20261008200858_user_admin/migration.sql} +0 -0
  542. /package/migrations/{0049_event_automation_status_reason.sql → 20261009145407_event_automation_status_reason/migration.sql} +0 -0
  543. /package/migrations/{0050_agent_invocation_parent_mailbox.sql → 20261013160816_agent_invocation_parent_mailbox/migration.sql} +0 -0
  544. /package/migrations/{0051_agent_invocation_parent_tool_call.sql → 20261013215020_agent_invocation_parent_tool_call/migration.sql} +0 -0
  545. /package/migrations/{0052_agent_invocation_title.sql → 20261014011138_agent_invocation_title/migration.sql} +0 -0
  546. /package/migrations/{0053_conversation_stopped_at.sql → 20261014211942_conversation_stopped_at/migration.sql} +0 -0
  547. /package/migrations/{0054_flowery_rage.sql → 20261015012820_flowery_rage/migration.sql} +0 -0
  548. /package/migrations/{0055_automations.sql → 20261017000924_automations/migration.sql} +0 -0
  549. /package/migrations/{0056_automation_runs.sql → 20261017134736_automation_runs/migration.sql} +0 -0
  550. /package/migrations/{0057_drop_legacy_automation_tables.sql → 20261017170250_drop_legacy_automation_tables/migration.sql} +0 -0
  551. /package/migrations/{0058_automation_creator_identity.sql → 20261018134754_automation_creator_identity/migration.sql} +0 -0
  552. /package/migrations/{0059_automation_run_version.sql → 20261023071954_automation_run_version/migration.sql} +0 -0
  553. /package/migrations/{0060_identity_signed_in_at.sql → 20261025233137_identity_signed_in_at/migration.sql} +0 -0
  554. /package/migrations/{0061_workspace_vcpus.sql → 20261027234315_workspace_vcpus/migration.sql} +0 -0
  555. /package/migrations/{0062_plugin_report_index.sql → 20261028124242_plugin_report_index/migration.sql} +0 -0
  556. /package/migrations/{0063_agent_invocation_type.sql → 20261028154230_agent_invocation_type/migration.sql} +0 -0
  557. /package/migrations/{0064_any_resource_event_triggers.sql → 20261030021803_any_resource_event_triggers/migration.sql} +0 -0
  558. /package/migrations/{0065_user_customization.sql → 20261030234309_user_customization/migration.sql} +0 -0
  559. /package/migrations/{0066_review_items.sql → 20261031020656_review_items/migration.sql} +0 -0
  560. /package/migrations/{0067_review_item_dedupe_tenant.sql → 20261031024151_review_item_dedupe_tenant/migration.sql} +0 -0
  561. /package/migrations/{0068_review_item_slack_cards.sql → 20261031024246_review_item_slack_cards/migration.sql} +0 -0
  562. /package/migrations/{0069_system_identity.sql → 20261031155308_system_identity/migration.sql} +0 -0
  563. /package/migrations/{0070_review_item_foreign_keys.sql → 20261101193952_review_item_foreign_keys/migration.sql} +0 -0
  564. /package/migrations/{0071_review_item_turn.sql → 20261102172751_review_item_turn/migration.sql} +0 -0
  565. /package/migrations/{0072_conversation_read_positions.sql → 20261102221411_conversation_read_positions/migration.sql} +0 -0
  566. /package/migrations/{0073_conversation_quick_question.sql → 20261104085028_conversation_quick_question/migration.sql} +0 -0
  567. /package/migrations/{0074_conversation_participant_pins.sql → 20261104145136_conversation_participant_pins/migration.sql} +0 -0
  568. /package/migrations/{0075_conversation_detail_version.sql → 20261104164429_conversation_detail_version/migration.sql} +0 -0
  569. /package/migrations/{0076_conversation_auto_archive.sql → 20261104172055_conversation_auto_archive/migration.sql} +0 -0
  570. /package/migrations/{0077_drop_agent_invocation_model_profile.sql → 20261105005443_drop_agent_invocation_model_profile/migration.sql} +0 -0
  571. /package/migrations/{0078_plugin_conversation_index.sql → 20261105043807_plugin_conversation_index/migration.sql} +0 -0
  572. /package/migrations/{0079_conversation_event_author_index.sql → 20261105051837_conversation_event_author_index/migration.sql} +0 -0
  573. /package/migrations/{0080_conversation_event_latest_message_indexes.sql → 20261105182854_conversation_event_latest_message_indexes/migration.sql} +0 -0
  574. /package/migrations/{0081_conversation_pin_position.sql → 20261106011443_conversation_pin_position/migration.sql} +0 -0
  575. /package/migrations/{0082_push_notifications.sql → 20261106095004_push_notifications/migration.sql} +0 -0
  576. /package/migrations/{0083_conversation_kind.sql → 20261106162740_conversation_kind/migration.sql} +0 -0
  577. /package/migrations/{0084_read_position_backfill.sql → 20261107002001_read_position_backfill/migration.sql} +0 -0
  578. /package/migrations/{0085_child_archived_at.sql → 20261107025209_child_archived_at/migration.sql} +0 -0
  579. /package/migrations/{0086_shared_archive.sql → 20261107035735_shared_archive/migration.sql} +0 -0
  580. /package/migrations/{0087_child_location.sql → 20261107215055_child_location/migration.sql} +0 -0
  581. /package/migrations/{0088_conversation_unsubscribe.sql → 20261108191927_conversation_unsubscribe/migration.sql} +0 -0
  582. /package/migrations/{0089_conversation_paused_status.sql → 20261109021618_conversation_paused_status/migration.sql} +0 -0
  583. /package/migrations/{0090_guardian_review_time_index.sql → 20261109111553_guardian_review_time_index/migration.sql} +0 -0
  584. /package/migrations/{0091_conversation_participant_unsubscribed_index.sql → 20261109173130_conversation_participant_unsubscribed_index/migration.sql} +0 -0
  585. /package/migrations/{0092_turn_metric_actor.sql → 20261109182006_turn_metric_actor/migration.sql} +0 -0
  586. /package/migrations/{0093_participant_root_actor_backfill.sql → 20261109202836_participant_root_actor_backfill/migration.sql} +0 -0
  587. /package/migrations/{0094_conversation_delivery_paused_at.sql → 20261109232640_conversation_delivery_paused_at/migration.sql} +0 -0
  588. /package/migrations/{0095_web_linked_slack_identity_repair.sql → 20261110120937_web_linked_slack_identity_repair/migration.sql} +0 -0
  589. /package/migrations/{0096_automation_task_kind.sql → 20261110175824_automation_task_kind/migration.sql} +0 -0
  590. /package/migrations/{0097_conversation_kind_automation.sql → 20261110210242_conversation_kind_automation/migration.sql} +0 -0
  591. /package/migrations/{0098_review_item_plugin_actions.sql → 20261110222632_review_item_plugin_actions/migration.sql} +0 -0
  592. /package/migrations/{0099_conversation_last_message_at.sql → 20261110225157_conversation_last_message_at/migration.sql} +0 -0
  593. /package/migrations/{0100_automation_task_kind_repair.sql → 20261111013351_automation_task_kind_repair/migration.sql} +0 -0
  594. /package/migrations/{0101_drop_legacy_columns.sql → 20261111163126_drop_legacy_columns/migration.sql} +0 -0
  595. /package/migrations/{0102_code_change_last_activity.sql → 20261111170150_code_change_last_activity/migration.sql} +0 -0
  596. /package/migrations/{0103_agent_invocation_fork.sql → 20261111191441_agent_invocation_fork/migration.sql} +0 -0
  597. /package/migrations/{0104_code_change_draft.sql → 20261112142841_code_change_draft/migration.sql} +0 -0
  598. /package/migrations/{0105_attachment_uploads.sql → 20261112202901_attachment_uploads/migration.sql} +0 -0
  599. /package/migrations/{0106_conversation_agent_config.sql → 20261112220407_conversation_agent_config/migration.sql} +0 -0
  600. /package/migrations/{0107_attachment_deferred_download.sql → 20261113081247_attachment_deferred_download/migration.sql} +0 -0
  601. /package/migrations/{0108_conversation_embeddings.sql → 20261113225551_conversation_embeddings/migration.sql} +0 -0
  602. /package/migrations/{0109_user_preferences.sql → 20261114213238_user_preferences/migration.sql} +0 -0
  603. /package/migrations/{0110_code_change_repository_state_index.sql → 20261114222527_code_change_repository_state_index/migration.sql} +0 -0
  604. /package/migrations/{0111_attachment_kinds.sql → 20261115172605_attachment_kinds/migration.sql} +0 -0
  605. /package/migrations/{0112_attachment_url_fill.sql → 20261115173004_attachment_url_fill/migration.sql} +0 -0
  606. /package/migrations/{0113_attachment_url_index.sql → 20261115180216_attachment_url_index/migration.sql} +0 -0
  607. /package/migrations/{0114_plan_items.sql → 20261116103700_plan_items/migration.sql} +0 -0
  608. /package/migrations/{0115_automation_creator_slack_index.sql → 20261117100100_automation_creator_slack_index/migration.sql} +0 -0
  609. /package/migrations/{0116_conversation_event_search.sql → 20261117132522_conversation_event_search/migration.sql} +0 -0
  610. /package/migrations/{0117_automation_last_run.sql → 20261117164007_automation_last_run/migration.sql} +0 -0
  611. /package/migrations/{0118_automation_last_run_index.sql → 20261117164047_automation_last_run_index/migration.sql} +0 -0
  612. /package/migrations/{0119_money_micro_usd.sql → 20261117210444_money_micro_usd/migration.sql} +0 -0
  613. /package/migrations/{0120_conversation_cost_micro_usd.sql → 20261117210505_conversation_cost_micro_usd/migration.sql} +0 -0
  614. /package/migrations/{0121_people_list_metric_index.sql → 20261118081416_people_list_metric_index/migration.sql} +0 -0
  615. /package/migrations/{0122_automation_rollout_repair.sql → 20261118095216_automation_rollout_repair/migration.sql} +0 -0
  616. /package/migrations/{0123_cache_warming_history_reset.sql → 20261118143948_cache_warming_history_reset/migration.sql} +0 -0
  617. /package/migrations/{0124_artifact_visibility.sql → 20261119040651_artifact_visibility/migration.sql} +0 -0
  618. /package/migrations/{0125_artifact_public_sha_index.sql → 20261119040715_artifact_public_sha_index/migration.sql} +0 -0
  619. /package/migrations/{0126_artifact_drop_public.sql → 20261119052706_artifact_drop_public/migration.sql} +0 -0
  620. /package/migrations/{0127_artifact_path.sql → 20261119053831_artifact_path/migration.sql} +0 -0
  621. /package/migrations/{0128_artifact_path_index.sql → 20261119053844_artifact_path_index/migration.sql} +0 -0
  622. /package/migrations/{0129_review_item_answered_index.sql → 20261119091949_review_item_answered_index/migration.sql} +0 -0
  623. /package/migrations/{0130_review_item_status_index.sql → 20261119100029_review_item_status_index/migration.sql} +0 -0
  624. /package/migrations/{0131_brief_outcome_status.sql → 20261119165607_brief_outcome_status/migration.sql} +0 -0
  625. /package/migrations/{0132_brief_outcome_status_backfill.sql → 20261119165622_brief_outcome_status_backfill/migration.sql} +0 -0
  626. /package/migrations/{0133_brief_created_at_index.sql → 20261119213716_brief_created_at_index/migration.sql} +0 -0
  627. /package/migrations/{0134_slack_person_search_index.sql → 20261119222456_slack_person_search_index/migration.sql} +0 -0
  628. /package/migrations/{0135_code_change_size.sql → 20261119225522_code_change_size/migration.sql} +0 -0
  629. /package/migrations/{0136_merge_conflict_notice_dismiss.sql → 20261119232253_merge_conflict_notice_dismiss/migration.sql} +0 -0
  630. /package/migrations/{0137_inbox_snoozes.sql → 20261119235649_inbox_snoozes/migration.sql} +0 -0
  631. /package/migrations/{0138_code_change_search_index.sql → 20261120093118_code_change_search_index/migration.sql} +0 -0
  632. /package/migrations/{0139_review_item_owner.sql → 20261120093452_review_item_owner/migration.sql} +0 -0
  633. /package/migrations/{0140_review_item_owner_index.sql → 20261120185654_review_item_owner_index/migration.sql} +0 -0
  634. /package/migrations/{0141_memory_core_adoption.sql → 20261120185754_memory_core_adoption/migration.sql} +0 -0
  635. /package/migrations/{0142_memory_core_indexes.sql → 20261120185854_memory_core_indexes/migration.sql} +0 -0
  636. /package/migrations/{0143_todos.sql → 20261120235226_todos/migration.sql} +0 -0
  637. /package/migrations/{0144_inbox_items.sql → 20261121082316_inbox_items/migration.sql} +0 -0
  638. /package/migrations/{0145_todo_changed_by_agent.sql → 20261121175651_todo_changed_by_agent/migration.sql} +0 -0
  639. /package/migrations/{0146_inbox_item_subject_title_parts.sql → 20261121183527_inbox_item_subject_title_parts/migration.sql} +0 -0
  640. /package/migrations/{0147_inbox_snooze_wake_reason.sql → 20261121194143_inbox_snooze_wake_reason/migration.sql} +0 -0
  641. /package/migrations/{0148_authorization_request_index.sql → 20261121222400_authorization_request_index/migration.sql} +0 -0
  642. /package/migrations/{0149_conversation_metadata.sql → 20261121225908_conversation_metadata/migration.sql} +0 -0
  643. /package/migrations/{0150_conversation_metadata_fill.sql → 20261121225910_conversation_metadata_fill/migration.sql} +0 -0
  644. /package/migrations/{0151_conversation_search_index.sql → 20261121225913_conversation_search_index/migration.sql} +0 -0
  645. /package/migrations/{0152_inbox_item_legacy_automation_keys.sql → 20261122022900_inbox_item_legacy_automation_keys/migration.sql} +0 -0
  646. /package/migrations/{0153_artifact_expiry.sql → 20261122024454_artifact_expiry/migration.sql} +0 -0
  647. /package/migrations/{0154_artifact_permanent_sha_index.sql → 20261122024455_artifact_permanent_sha_index/migration.sql} +0 -0
  648. /package/migrations/{0155_artifact_drop_public_sha_index.sql → 20261122024457_artifact_drop_public_sha_index/migration.sql} +0 -0
  649. /package/migrations/{0156_conversation_kind_lead.sql → 20261122024458_conversation_kind_lead/migration.sql} +0 -0
  650. /package/migrations/{0157_conversation_lead_actor_index.sql → 20261122024459_conversation_lead_actor_index/migration.sql} +0 -0
  651. /package/migrations/{0158_keep_legacy_archive_columns.sql → 20261122071549_keep_legacy_archive_columns/migration.sql} +0 -0
  652. /package/migrations/{0159_conversation_embeddings_fk_validate.sql → 20261122191400_conversation_embeddings_fk_validate/migration.sql} +0 -0
@@ -1,4952 +0,0 @@
1
- {
2
- "id": "5a444536-4cd9-4f93-9afb-bd986c973f0a",
3
- "prevId": "1880d763-2db8-4b02-931d-e59c0840186a",
4
- "version": "7",
5
- "dialect": "postgresql",
6
- "tables": {
7
- "public.junior_agent_bindings": {
8
- "name": "junior_agent_bindings",
9
- "schema": "",
10
- "columns": {
11
- "parent_conversation_id": {
12
- "name": "parent_conversation_id",
13
- "type": "text",
14
- "primaryKey": false,
15
- "notNull": true
16
- },
17
- "name": {
18
- "name": "name",
19
- "type": "text",
20
- "primaryKey": false,
21
- "notNull": true
22
- },
23
- "child_conversation_id": {
24
- "name": "child_conversation_id",
25
- "type": "text",
26
- "primaryKey": false,
27
- "notNull": true
28
- }
29
- },
30
- "indexes": {
31
- "junior_agent_bindings_child_idx": {
32
- "name": "junior_agent_bindings_child_idx",
33
- "columns": [
34
- {
35
- "expression": "child_conversation_id",
36
- "isExpression": false,
37
- "asc": true,
38
- "nulls": "last"
39
- }
40
- ],
41
- "isUnique": true,
42
- "concurrently": false,
43
- "method": "btree",
44
- "with": {}
45
- }
46
- },
47
- "foreignKeys": {
48
- "junior_agent_bindings_parent_conversation_id_junior_conversations_conversation_id_fk": {
49
- "name": "junior_agent_bindings_parent_conversation_id_junior_conversations_conversation_id_fk",
50
- "tableFrom": "junior_agent_bindings",
51
- "tableTo": "junior_conversations",
52
- "columnsFrom": [
53
- "parent_conversation_id"
54
- ],
55
- "columnsTo": [
56
- "conversation_id"
57
- ],
58
- "onDelete": "no action",
59
- "onUpdate": "no action"
60
- },
61
- "junior_agent_bindings_child_conversation_id_junior_conversations_conversation_id_fk": {
62
- "name": "junior_agent_bindings_child_conversation_id_junior_conversations_conversation_id_fk",
63
- "tableFrom": "junior_agent_bindings",
64
- "tableTo": "junior_conversations",
65
- "columnsFrom": [
66
- "child_conversation_id"
67
- ],
68
- "columnsTo": [
69
- "conversation_id"
70
- ],
71
- "onDelete": "no action",
72
- "onUpdate": "no action"
73
- }
74
- },
75
- "compositePrimaryKeys": {
76
- "junior_agent_bindings_parent_conversation_id_name_pk": {
77
- "name": "junior_agent_bindings_parent_conversation_id_name_pk",
78
- "columns": [
79
- "parent_conversation_id",
80
- "name"
81
- ]
82
- }
83
- },
84
- "uniqueConstraints": {},
85
- "policies": {},
86
- "checkConstraints": {},
87
- "isRLSEnabled": false
88
- },
89
- "public.junior_agent_invocations": {
90
- "name": "junior_agent_invocations",
91
- "schema": "",
92
- "columns": {
93
- "invocation_id": {
94
- "name": "invocation_id",
95
- "type": "text",
96
- "primaryKey": true,
97
- "notNull": true
98
- },
99
- "parent_conversation_id": {
100
- "name": "parent_conversation_id",
101
- "type": "text",
102
- "primaryKey": false,
103
- "notNull": true
104
- },
105
- "child_conversation_id": {
106
- "name": "child_conversation_id",
107
- "type": "text",
108
- "primaryKey": false,
109
- "notNull": true
110
- },
111
- "agent_name": {
112
- "name": "agent_name",
113
- "type": "text",
114
- "primaryKey": false,
115
- "notNull": false
116
- },
117
- "input": {
118
- "name": "input",
119
- "type": "text",
120
- "primaryKey": false,
121
- "notNull": true
122
- },
123
- "title": {
124
- "name": "title",
125
- "type": "text",
126
- "primaryKey": false,
127
- "notNull": false
128
- },
129
- "actor_json": {
130
- "name": "actor_json",
131
- "type": "jsonb",
132
- "primaryKey": false,
133
- "notNull": true
134
- },
135
- "credential_context_json": {
136
- "name": "credential_context_json",
137
- "type": "jsonb",
138
- "primaryKey": false,
139
- "notNull": false
140
- },
141
- "source_json": {
142
- "name": "source_json",
143
- "type": "jsonb",
144
- "primaryKey": false,
145
- "notNull": true
146
- },
147
- "destination_json": {
148
- "name": "destination_json",
149
- "type": "jsonb",
150
- "primaryKey": false,
151
- "notNull": true
152
- },
153
- "destination_visibility": {
154
- "name": "destination_visibility",
155
- "type": "text",
156
- "primaryKey": false,
157
- "notNull": false
158
- },
159
- "agent_type": {
160
- "name": "agent_type",
161
- "type": "text",
162
- "primaryKey": false,
163
- "notNull": false
164
- },
165
- "fork": {
166
- "name": "fork",
167
- "type": "boolean",
168
- "primaryKey": false,
169
- "notNull": true,
170
- "default": false
171
- },
172
- "reasoning_level": {
173
- "name": "reasoning_level",
174
- "type": "text",
175
- "primaryKey": false,
176
- "notNull": false
177
- },
178
- "parent_tool_call_id": {
179
- "name": "parent_tool_call_id",
180
- "type": "text",
181
- "primaryKey": false,
182
- "notNull": false
183
- },
184
- "status": {
185
- "name": "status",
186
- "type": "text",
187
- "primaryKey": false,
188
- "notNull": true
189
- },
190
- "mailbox_status": {
191
- "name": "mailbox_status",
192
- "type": "text",
193
- "primaryKey": false,
194
- "notNull": true
195
- },
196
- "parent_mailbox_status": {
197
- "name": "parent_mailbox_status",
198
- "type": "text",
199
- "primaryKey": false,
200
- "notNull": false
201
- },
202
- "result": {
203
- "name": "result",
204
- "type": "text",
205
- "primaryKey": false,
206
- "notNull": false
207
- },
208
- "error_message": {
209
- "name": "error_message",
210
- "type": "text",
211
- "primaryKey": false,
212
- "notNull": false
213
- },
214
- "created_at": {
215
- "name": "created_at",
216
- "type": "timestamp with time zone",
217
- "primaryKey": false,
218
- "notNull": true
219
- },
220
- "updated_at": {
221
- "name": "updated_at",
222
- "type": "timestamp with time zone",
223
- "primaryKey": false,
224
- "notNull": true
225
- },
226
- "terminal_at": {
227
- "name": "terminal_at",
228
- "type": "timestamp with time zone",
229
- "primaryKey": false,
230
- "notNull": false
231
- }
232
- },
233
- "indexes": {
234
- "junior_agent_invocations_child_idx": {
235
- "name": "junior_agent_invocations_child_idx",
236
- "columns": [
237
- {
238
- "expression": "child_conversation_id",
239
- "isExpression": false,
240
- "asc": true,
241
- "nulls": "last"
242
- }
243
- ],
244
- "isUnique": false,
245
- "concurrently": false,
246
- "method": "btree",
247
- "with": {}
248
- },
249
- "junior_agent_invocations_mailbox_idx": {
250
- "name": "junior_agent_invocations_mailbox_idx",
251
- "columns": [
252
- {
253
- "expression": "mailbox_status",
254
- "isExpression": false,
255
- "asc": true,
256
- "nulls": "last"
257
- },
258
- {
259
- "expression": "created_at",
260
- "isExpression": false,
261
- "asc": true,
262
- "nulls": "last"
263
- }
264
- ],
265
- "isUnique": false,
266
- "concurrently": false,
267
- "method": "btree",
268
- "with": {}
269
- },
270
- "junior_agent_invocations_parent_mailbox_idx": {
271
- "name": "junior_agent_invocations_parent_mailbox_idx",
272
- "columns": [
273
- {
274
- "expression": "parent_mailbox_status",
275
- "isExpression": false,
276
- "asc": true,
277
- "nulls": "last"
278
- },
279
- {
280
- "expression": "terminal_at",
281
- "isExpression": false,
282
- "asc": true,
283
- "nulls": "last"
284
- }
285
- ],
286
- "isUnique": false,
287
- "concurrently": false,
288
- "method": "btree",
289
- "with": {}
290
- }
291
- },
292
- "foreignKeys": {
293
- "junior_agent_invocations_parent_conversation_id_junior_conversations_conversation_id_fk": {
294
- "name": "junior_agent_invocations_parent_conversation_id_junior_conversations_conversation_id_fk",
295
- "tableFrom": "junior_agent_invocations",
296
- "tableTo": "junior_conversations",
297
- "columnsFrom": [
298
- "parent_conversation_id"
299
- ],
300
- "columnsTo": [
301
- "conversation_id"
302
- ],
303
- "onDelete": "no action",
304
- "onUpdate": "no action"
305
- },
306
- "junior_agent_invocations_child_conversation_id_junior_conversations_conversation_id_fk": {
307
- "name": "junior_agent_invocations_child_conversation_id_junior_conversations_conversation_id_fk",
308
- "tableFrom": "junior_agent_invocations",
309
- "tableTo": "junior_conversations",
310
- "columnsFrom": [
311
- "child_conversation_id"
312
- ],
313
- "columnsTo": [
314
- "conversation_id"
315
- ],
316
- "onDelete": "no action",
317
- "onUpdate": "no action"
318
- }
319
- },
320
- "compositePrimaryKeys": {},
321
- "uniqueConstraints": {},
322
- "policies": {},
323
- "checkConstraints": {},
324
- "isRLSEnabled": false
325
- },
326
- "public.junior_api_tokens": {
327
- "name": "junior_api_tokens",
328
- "schema": "",
329
- "columns": {
330
- "id": {
331
- "name": "id",
332
- "type": "text",
333
- "primaryKey": true,
334
- "notNull": true
335
- },
336
- "owner_email_normalized": {
337
- "name": "owner_email_normalized",
338
- "type": "text",
339
- "primaryKey": false,
340
- "notNull": true
341
- },
342
- "name": {
343
- "name": "name",
344
- "type": "text",
345
- "primaryKey": false,
346
- "notNull": true
347
- },
348
- "token_hash": {
349
- "name": "token_hash",
350
- "type": "text",
351
- "primaryKey": false,
352
- "notNull": true
353
- },
354
- "token_suffix": {
355
- "name": "token_suffix",
356
- "type": "text",
357
- "primaryKey": false,
358
- "notNull": true
359
- },
360
- "created_at": {
361
- "name": "created_at",
362
- "type": "timestamp with time zone",
363
- "primaryKey": false,
364
- "notNull": true
365
- },
366
- "expires_at": {
367
- "name": "expires_at",
368
- "type": "timestamp with time zone",
369
- "primaryKey": false,
370
- "notNull": true
371
- },
372
- "last_used_at": {
373
- "name": "last_used_at",
374
- "type": "timestamp with time zone",
375
- "primaryKey": false,
376
- "notNull": false
377
- },
378
- "revoked_at": {
379
- "name": "revoked_at",
380
- "type": "timestamp with time zone",
381
- "primaryKey": false,
382
- "notNull": false
383
- }
384
- },
385
- "indexes": {
386
- "junior_api_tokens_token_hash_uidx": {
387
- "name": "junior_api_tokens_token_hash_uidx",
388
- "columns": [
389
- {
390
- "expression": "token_hash",
391
- "isExpression": false,
392
- "asc": true,
393
- "nulls": "last"
394
- }
395
- ],
396
- "isUnique": true,
397
- "concurrently": false,
398
- "method": "btree",
399
- "with": {}
400
- },
401
- "junior_api_tokens_owner_email_idx": {
402
- "name": "junior_api_tokens_owner_email_idx",
403
- "columns": [
404
- {
405
- "expression": "owner_email_normalized",
406
- "isExpression": false,
407
- "asc": true,
408
- "nulls": "last"
409
- }
410
- ],
411
- "isUnique": false,
412
- "concurrently": false,
413
- "method": "btree",
414
- "with": {}
415
- }
416
- },
417
- "foreignKeys": {},
418
- "compositePrimaryKeys": {},
419
- "uniqueConstraints": {},
420
- "policies": {},
421
- "checkConstraints": {},
422
- "isRLSEnabled": false
423
- },
424
- "public.junior_artifacts": {
425
- "name": "junior_artifacts",
426
- "schema": "",
427
- "columns": {
428
- "id": {
429
- "name": "id",
430
- "type": "text",
431
- "primaryKey": true,
432
- "notNull": true
433
- },
434
- "conversation_id": {
435
- "name": "conversation_id",
436
- "type": "text",
437
- "primaryKey": false,
438
- "notNull": true
439
- },
440
- "sha256": {
441
- "name": "sha256",
442
- "type": "text",
443
- "primaryKey": false,
444
- "notNull": true
445
- },
446
- "ext": {
447
- "name": "ext",
448
- "type": "text",
449
- "primaryKey": false,
450
- "notNull": true
451
- },
452
- "storage_key": {
453
- "name": "storage_key",
454
- "type": "text",
455
- "primaryKey": false,
456
- "notNull": true
457
- },
458
- "content_type": {
459
- "name": "content_type",
460
- "type": "text",
461
- "primaryKey": false,
462
- "notNull": true
463
- },
464
- "bytes": {
465
- "name": "bytes",
466
- "type": "integer",
467
- "primaryKey": false,
468
- "notNull": true
469
- },
470
- "public": {
471
- "name": "public",
472
- "type": "boolean",
473
- "primaryKey": false,
474
- "notNull": true
475
- },
476
- "created_at": {
477
- "name": "created_at",
478
- "type": "timestamp with time zone",
479
- "primaryKey": false,
480
- "notNull": true
481
- },
482
- "delete_requested_at": {
483
- "name": "delete_requested_at",
484
- "type": "timestamp with time zone",
485
- "primaryKey": false,
486
- "notNull": false
487
- }
488
- },
489
- "indexes": {
490
- "junior_artifacts_conversation_sha_uidx": {
491
- "name": "junior_artifacts_conversation_sha_uidx",
492
- "columns": [
493
- {
494
- "expression": "conversation_id",
495
- "isExpression": false,
496
- "asc": true,
497
- "nulls": "last"
498
- },
499
- {
500
- "expression": "sha256",
501
- "isExpression": false,
502
- "asc": true,
503
- "nulls": "last"
504
- }
505
- ],
506
- "isUnique": true,
507
- "concurrently": false,
508
- "method": "btree",
509
- "with": {}
510
- },
511
- "junior_artifacts_gc_idx": {
512
- "name": "junior_artifacts_gc_idx",
513
- "columns": [
514
- {
515
- "expression": "delete_requested_at",
516
- "isExpression": false,
517
- "asc": true,
518
- "nulls": "last"
519
- },
520
- {
521
- "expression": "created_at",
522
- "isExpression": false,
523
- "asc": true,
524
- "nulls": "last"
525
- }
526
- ],
527
- "isUnique": false,
528
- "concurrently": false,
529
- "method": "btree",
530
- "with": {}
531
- },
532
- "junior_artifacts_conversation_idx": {
533
- "name": "junior_artifacts_conversation_idx",
534
- "columns": [
535
- {
536
- "expression": "conversation_id",
537
- "isExpression": false,
538
- "asc": true,
539
- "nulls": "last"
540
- }
541
- ],
542
- "isUnique": false,
543
- "concurrently": false,
544
- "method": "btree",
545
- "with": {}
546
- }
547
- },
548
- "foreignKeys": {},
549
- "compositePrimaryKeys": {},
550
- "uniqueConstraints": {},
551
- "policies": {},
552
- "checkConstraints": {},
553
- "isRLSEnabled": false
554
- },
555
- "public.junior_attachment_uploads": {
556
- "name": "junior_attachment_uploads",
557
- "schema": "",
558
- "columns": {
559
- "id": {
560
- "name": "id",
561
- "type": "text",
562
- "primaryKey": true,
563
- "notNull": true
564
- },
565
- "conversation_id": {
566
- "name": "conversation_id",
567
- "type": "text",
568
- "primaryKey": false,
569
- "notNull": true
570
- },
571
- "user_id": {
572
- "name": "user_id",
573
- "type": "text",
574
- "primaryKey": false,
575
- "notNull": true
576
- },
577
- "idempotency_key": {
578
- "name": "idempotency_key",
579
- "type": "text",
580
- "primaryKey": false,
581
- "notNull": true
582
- },
583
- "storage_provider": {
584
- "name": "storage_provider",
585
- "type": "text",
586
- "primaryKey": false,
587
- "notNull": true
588
- },
589
- "storage_key": {
590
- "name": "storage_key",
591
- "type": "text",
592
- "primaryKey": false,
593
- "notNull": true
594
- },
595
- "filename": {
596
- "name": "filename",
597
- "type": "text",
598
- "primaryKey": false,
599
- "notNull": true
600
- },
601
- "content_type": {
602
- "name": "content_type",
603
- "type": "text",
604
- "primaryKey": false,
605
- "notNull": true
606
- },
607
- "bytes": {
608
- "name": "bytes",
609
- "type": "integer",
610
- "primaryKey": false,
611
- "notNull": true
612
- },
613
- "created_at": {
614
- "name": "created_at",
615
- "type": "timestamp with time zone",
616
- "primaryKey": false,
617
- "notNull": true
618
- }
619
- },
620
- "indexes": {
621
- "junior_attachment_uploads_gc_idx": {
622
- "name": "junior_attachment_uploads_gc_idx",
623
- "columns": [
624
- {
625
- "expression": "storage_provider",
626
- "isExpression": false,
627
- "asc": true,
628
- "nulls": "last"
629
- },
630
- {
631
- "expression": "created_at",
632
- "isExpression": false,
633
- "asc": true,
634
- "nulls": "last"
635
- }
636
- ],
637
- "isUnique": false,
638
- "concurrently": false,
639
- "method": "btree",
640
- "with": {}
641
- }
642
- },
643
- "foreignKeys": {},
644
- "compositePrimaryKeys": {},
645
- "uniqueConstraints": {},
646
- "policies": {},
647
- "checkConstraints": {},
648
- "isRLSEnabled": false
649
- },
650
- "public.junior_attachments": {
651
- "name": "junior_attachments",
652
- "schema": "",
653
- "columns": {
654
- "id": {
655
- "name": "id",
656
- "type": "text",
657
- "primaryKey": true,
658
- "notNull": true
659
- },
660
- "conversation_id": {
661
- "name": "conversation_id",
662
- "type": "text",
663
- "primaryKey": false,
664
- "notNull": true
665
- },
666
- "storage_provider": {
667
- "name": "storage_provider",
668
- "type": "text",
669
- "primaryKey": false,
670
- "notNull": true
671
- },
672
- "storage_key": {
673
- "name": "storage_key",
674
- "type": "text",
675
- "primaryKey": false,
676
- "notNull": false
677
- },
678
- "provider": {
679
- "name": "provider",
680
- "type": "text",
681
- "primaryKey": false,
682
- "notNull": false
683
- },
684
- "provider_id": {
685
- "name": "provider_id",
686
- "type": "text",
687
- "primaryKey": false,
688
- "notNull": false
689
- },
690
- "filename": {
691
- "name": "filename",
692
- "type": "text",
693
- "primaryKey": false,
694
- "notNull": true
695
- },
696
- "content_type": {
697
- "name": "content_type",
698
- "type": "text",
699
- "primaryKey": false,
700
- "notNull": true
701
- },
702
- "bytes": {
703
- "name": "bytes",
704
- "type": "integer",
705
- "primaryKey": false,
706
- "notNull": true
707
- },
708
- "sha256": {
709
- "name": "sha256",
710
- "type": "text",
711
- "primaryKey": false,
712
- "notNull": false
713
- },
714
- "vision_summary": {
715
- "name": "vision_summary",
716
- "type": "text",
717
- "primaryKey": false,
718
- "notNull": false
719
- },
720
- "created_at": {
721
- "name": "created_at",
722
- "type": "timestamp with time zone",
723
- "primaryKey": false,
724
- "notNull": true
725
- },
726
- "delete_requested_at": {
727
- "name": "delete_requested_at",
728
- "type": "timestamp with time zone",
729
- "primaryKey": false,
730
- "notNull": false
731
- }
732
- },
733
- "indexes": {
734
- "junior_attachments_conversation_idx": {
735
- "name": "junior_attachments_conversation_idx",
736
- "columns": [
737
- {
738
- "expression": "conversation_id",
739
- "isExpression": false,
740
- "asc": true,
741
- "nulls": "last"
742
- }
743
- ],
744
- "isUnique": false,
745
- "concurrently": false,
746
- "method": "btree",
747
- "with": {}
748
- },
749
- "junior_attachments_provider_idx": {
750
- "name": "junior_attachments_provider_idx",
751
- "columns": [
752
- {
753
- "expression": "conversation_id",
754
- "isExpression": false,
755
- "asc": true,
756
- "nulls": "last"
757
- },
758
- {
759
- "expression": "provider",
760
- "isExpression": false,
761
- "asc": true,
762
- "nulls": "last"
763
- },
764
- {
765
- "expression": "provider_id",
766
- "isExpression": false,
767
- "asc": true,
768
- "nulls": "last"
769
- }
770
- ],
771
- "isUnique": false,
772
- "concurrently": false,
773
- "method": "btree",
774
- "with": {}
775
- },
776
- "junior_attachments_gc_idx": {
777
- "name": "junior_attachments_gc_idx",
778
- "columns": [
779
- {
780
- "expression": "storage_provider",
781
- "isExpression": false,
782
- "asc": true,
783
- "nulls": "last"
784
- },
785
- {
786
- "expression": "delete_requested_at",
787
- "isExpression": false,
788
- "asc": true,
789
- "nulls": "last"
790
- },
791
- {
792
- "expression": "created_at",
793
- "isExpression": false,
794
- "asc": true,
795
- "nulls": "last"
796
- }
797
- ],
798
- "isUnique": false,
799
- "concurrently": false,
800
- "method": "btree",
801
- "with": {}
802
- }
803
- },
804
- "foreignKeys": {
805
- "junior_attachments_conversation_id_junior_conversations_conversation_id_fk": {
806
- "name": "junior_attachments_conversation_id_junior_conversations_conversation_id_fk",
807
- "tableFrom": "junior_attachments",
808
- "tableTo": "junior_conversations",
809
- "columnsFrom": [
810
- "conversation_id"
811
- ],
812
- "columnsTo": [
813
- "conversation_id"
814
- ],
815
- "onDelete": "cascade",
816
- "onUpdate": "no action"
817
- }
818
- },
819
- "compositePrimaryKeys": {},
820
- "uniqueConstraints": {},
821
- "policies": {},
822
- "checkConstraints": {},
823
- "isRLSEnabled": false
824
- },
825
- "public.junior_automation_runs": {
826
- "name": "junior_automation_runs",
827
- "schema": "",
828
- "columns": {
829
- "id": {
830
- "name": "id",
831
- "type": "text",
832
- "primaryKey": true,
833
- "notNull": true
834
- },
835
- "automation_id": {
836
- "name": "automation_id",
837
- "type": "text",
838
- "primaryKey": false,
839
- "notNull": true
840
- },
841
- "conversation_id": {
842
- "name": "conversation_id",
843
- "type": "text",
844
- "primaryKey": false,
845
- "notNull": false
846
- },
847
- "status": {
848
- "name": "status",
849
- "type": "text",
850
- "primaryKey": false,
851
- "notNull": true
852
- },
853
- "automation_version": {
854
- "name": "automation_version",
855
- "type": "integer",
856
- "primaryKey": false,
857
- "notNull": false
858
- },
859
- "scheduled_for_ms": {
860
- "name": "scheduled_for_ms",
861
- "type": "bigint",
862
- "primaryKey": false,
863
- "notNull": false
864
- },
865
- "attempt": {
866
- "name": "attempt",
867
- "type": "integer",
868
- "primaryKey": false,
869
- "notNull": false
870
- },
871
- "claimed_at_ms": {
872
- "name": "claimed_at_ms",
873
- "type": "bigint",
874
- "primaryKey": false,
875
- "notNull": false
876
- },
877
- "dispatch_id": {
878
- "name": "dispatch_id",
879
- "type": "text",
880
- "primaryKey": false,
881
- "notNull": false
882
- },
883
- "started_at_ms": {
884
- "name": "started_at_ms",
885
- "type": "bigint",
886
- "primaryKey": false,
887
- "notNull": false
888
- },
889
- "completed_at_ms": {
890
- "name": "completed_at_ms",
891
- "type": "bigint",
892
- "primaryKey": false,
893
- "notNull": false
894
- },
895
- "error_message": {
896
- "name": "error_message",
897
- "type": "text",
898
- "primaryKey": false,
899
- "notNull": false
900
- },
901
- "result_message_ts": {
902
- "name": "result_message_ts",
903
- "type": "text",
904
- "primaryKey": false,
905
- "notNull": false
906
- }
907
- },
908
- "indexes": {
909
- "junior_automation_runs_automation_idx": {
910
- "name": "junior_automation_runs_automation_idx",
911
- "columns": [
912
- {
913
- "expression": "automation_id",
914
- "isExpression": false,
915
- "asc": true,
916
- "nulls": "last"
917
- },
918
- {
919
- "expression": "completed_at_ms",
920
- "isExpression": false,
921
- "asc": true,
922
- "nulls": "last"
923
- }
924
- ],
925
- "isUnique": false,
926
- "concurrently": false,
927
- "method": "btree",
928
- "with": {}
929
- },
930
- "junior_automation_runs_completed_idx": {
931
- "name": "junior_automation_runs_completed_idx",
932
- "columns": [
933
- {
934
- "expression": "completed_at_ms",
935
- "isExpression": false,
936
- "asc": true,
937
- "nulls": "last"
938
- }
939
- ],
940
- "isUnique": false,
941
- "concurrently": false,
942
- "method": "btree",
943
- "with": {}
944
- },
945
- "junior_automation_runs_incomplete_idx": {
946
- "name": "junior_automation_runs_incomplete_idx",
947
- "columns": [
948
- {
949
- "expression": "automation_id",
950
- "isExpression": false,
951
- "asc": true,
952
- "nulls": "last"
953
- },
954
- {
955
- "expression": "scheduled_for_ms",
956
- "isExpression": false,
957
- "asc": true,
958
- "nulls": "last"
959
- }
960
- ],
961
- "isUnique": false,
962
- "where": "\"junior_automation_runs\".\"status\" in ('pending', 'running')",
963
- "concurrently": false,
964
- "method": "btree",
965
- "with": {}
966
- }
967
- },
968
- "foreignKeys": {
969
- "junior_automation_runs_automation_id_junior_automations_id_fk": {
970
- "name": "junior_automation_runs_automation_id_junior_automations_id_fk",
971
- "tableFrom": "junior_automation_runs",
972
- "tableTo": "junior_automations",
973
- "columnsFrom": [
974
- "automation_id"
975
- ],
976
- "columnsTo": [
977
- "id"
978
- ],
979
- "onDelete": "cascade",
980
- "onUpdate": "no action"
981
- },
982
- "junior_automation_runs_conversation_id_junior_conversations_conversation_id_fk": {
983
- "name": "junior_automation_runs_conversation_id_junior_conversations_conversation_id_fk",
984
- "tableFrom": "junior_automation_runs",
985
- "tableTo": "junior_conversations",
986
- "columnsFrom": [
987
- "conversation_id"
988
- ],
989
- "columnsTo": [
990
- "conversation_id"
991
- ],
992
- "onDelete": "no action",
993
- "onUpdate": "no action"
994
- },
995
- "junior_automation_runs_automation_version_fk": {
996
- "name": "junior_automation_runs_automation_version_fk",
997
- "tableFrom": "junior_automation_runs",
998
- "tableTo": "junior_automation_versions",
999
- "columnsFrom": [
1000
- "automation_id",
1001
- "automation_version"
1002
- ],
1003
- "columnsTo": [
1004
- "automation_id",
1005
- "version"
1006
- ],
1007
- "onDelete": "no action",
1008
- "onUpdate": "no action"
1009
- }
1010
- },
1011
- "compositePrimaryKeys": {},
1012
- "uniqueConstraints": {
1013
- "junior_automation_runs_conversation_id_unique": {
1014
- "name": "junior_automation_runs_conversation_id_unique",
1015
- "nullsNotDistinct": false,
1016
- "columns": [
1017
- "conversation_id"
1018
- ]
1019
- }
1020
- },
1021
- "policies": {},
1022
- "checkConstraints": {
1023
- "junior_automation_runs_status_check": {
1024
- "name": "junior_automation_runs_status_check",
1025
- "value": "\"junior_automation_runs\".\"status\" in ('pending', 'running', 'completed', 'failed', 'blocked', 'skipped')"
1026
- }
1027
- },
1028
- "isRLSEnabled": false
1029
- },
1030
- "public.junior_automation_versions": {
1031
- "name": "junior_automation_versions",
1032
- "schema": "",
1033
- "columns": {
1034
- "automation_id": {
1035
- "name": "automation_id",
1036
- "type": "text",
1037
- "primaryKey": false,
1038
- "notNull": true
1039
- },
1040
- "version": {
1041
- "name": "version",
1042
- "type": "integer",
1043
- "primaryKey": false,
1044
- "notNull": true
1045
- },
1046
- "created_at_ms": {
1047
- "name": "created_at_ms",
1048
- "type": "bigint",
1049
- "primaryKey": false,
1050
- "notNull": true
1051
- },
1052
- "edited_by": {
1053
- "name": "edited_by",
1054
- "type": "jsonb",
1055
- "primaryKey": false,
1056
- "notNull": false
1057
- },
1058
- "definition": {
1059
- "name": "definition",
1060
- "type": "jsonb",
1061
- "primaryKey": false,
1062
- "notNull": true
1063
- }
1064
- },
1065
- "indexes": {},
1066
- "foreignKeys": {
1067
- "junior_automation_versions_automation_id_fk": {
1068
- "name": "junior_automation_versions_automation_id_fk",
1069
- "tableFrom": "junior_automation_versions",
1070
- "tableTo": "junior_automations",
1071
- "columnsFrom": [
1072
- "automation_id"
1073
- ],
1074
- "columnsTo": [
1075
- "id"
1076
- ],
1077
- "onDelete": "cascade",
1078
- "onUpdate": "no action"
1079
- }
1080
- },
1081
- "compositePrimaryKeys": {
1082
- "junior_automation_versions_pk": {
1083
- "name": "junior_automation_versions_pk",
1084
- "columns": [
1085
- "automation_id",
1086
- "version"
1087
- ]
1088
- }
1089
- },
1090
- "uniqueConstraints": {},
1091
- "policies": {},
1092
- "checkConstraints": {},
1093
- "isRLSEnabled": false
1094
- },
1095
- "public.junior_automations": {
1096
- "name": "junior_automations",
1097
- "schema": "",
1098
- "columns": {
1099
- "id": {
1100
- "name": "id",
1101
- "type": "text",
1102
- "primaryKey": true,
1103
- "notNull": true
1104
- },
1105
- "kind": {
1106
- "name": "kind",
1107
- "type": "text",
1108
- "primaryKey": false,
1109
- "notNull": true
1110
- },
1111
- "team_id": {
1112
- "name": "team_id",
1113
- "type": "text",
1114
- "primaryKey": false,
1115
- "notNull": true
1116
- },
1117
- "channel_id": {
1118
- "name": "channel_id",
1119
- "type": "text",
1120
- "primaryKey": false,
1121
- "notNull": true
1122
- },
1123
- "creator_slack_user_id": {
1124
- "name": "creator_slack_user_id",
1125
- "type": "text",
1126
- "primaryKey": false,
1127
- "notNull": true
1128
- },
1129
- "creator_identity_id": {
1130
- "name": "creator_identity_id",
1131
- "type": "text",
1132
- "primaryKey": false,
1133
- "notNull": true
1134
- },
1135
- "status": {
1136
- "name": "status",
1137
- "type": "text",
1138
- "primaryKey": false,
1139
- "notNull": true
1140
- },
1141
- "status_reason": {
1142
- "name": "status_reason",
1143
- "type": "text",
1144
- "primaryKey": false,
1145
- "notNull": false
1146
- },
1147
- "title": {
1148
- "name": "title",
1149
- "type": "text",
1150
- "primaryKey": false,
1151
- "notNull": false
1152
- },
1153
- "instruction": {
1154
- "name": "instruction",
1155
- "type": "text",
1156
- "primaryKey": false,
1157
- "notNull": false
1158
- },
1159
- "skill": {
1160
- "name": "skill",
1161
- "type": "text",
1162
- "primaryKey": false,
1163
- "notNull": false
1164
- },
1165
- "created_at_ms": {
1166
- "name": "created_at_ms",
1167
- "type": "bigint",
1168
- "primaryKey": false,
1169
- "notNull": true
1170
- },
1171
- "next_run_at_ms": {
1172
- "name": "next_run_at_ms",
1173
- "type": "bigint",
1174
- "primaryKey": false,
1175
- "notNull": false
1176
- },
1177
- "run_now_at_ms": {
1178
- "name": "run_now_at_ms",
1179
- "type": "bigint",
1180
- "primaryKey": false,
1181
- "notNull": false
1182
- },
1183
- "namespace": {
1184
- "name": "namespace",
1185
- "type": "text",
1186
- "primaryKey": false,
1187
- "notNull": false
1188
- },
1189
- "identifier": {
1190
- "name": "identifier",
1191
- "type": "text",
1192
- "primaryKey": false,
1193
- "notNull": false
1194
- },
1195
- "record": {
1196
- "name": "record",
1197
- "type": "jsonb",
1198
- "primaryKey": false,
1199
- "notNull": true
1200
- }
1201
- },
1202
- "indexes": {
1203
- "junior_automations_team_idx": {
1204
- "name": "junior_automations_team_idx",
1205
- "columns": [
1206
- {
1207
- "expression": "team_id",
1208
- "isExpression": false,
1209
- "asc": true,
1210
- "nulls": "last"
1211
- },
1212
- {
1213
- "expression": "created_at_ms",
1214
- "isExpression": false,
1215
- "asc": true,
1216
- "nulls": "last"
1217
- },
1218
- {
1219
- "expression": "id",
1220
- "isExpression": false,
1221
- "asc": true,
1222
- "nulls": "last"
1223
- }
1224
- ],
1225
- "isUnique": false,
1226
- "where": "\"junior_automations\".\"status\" <> 'deleted'",
1227
- "concurrently": false,
1228
- "method": "btree",
1229
- "with": {}
1230
- },
1231
- "junior_automations_creator_identity_idx": {
1232
- "name": "junior_automations_creator_identity_idx",
1233
- "columns": [
1234
- {
1235
- "expression": "creator_identity_id",
1236
- "isExpression": false,
1237
- "asc": true,
1238
- "nulls": "last"
1239
- },
1240
- {
1241
- "expression": "created_at_ms",
1242
- "isExpression": false,
1243
- "asc": true,
1244
- "nulls": "last"
1245
- },
1246
- {
1247
- "expression": "id",
1248
- "isExpression": false,
1249
- "asc": true,
1250
- "nulls": "last"
1251
- }
1252
- ],
1253
- "isUnique": false,
1254
- "concurrently": false,
1255
- "method": "btree",
1256
- "with": {}
1257
- },
1258
- "junior_automations_run_now_due_idx": {
1259
- "name": "junior_automations_run_now_due_idx",
1260
- "columns": [
1261
- {
1262
- "expression": "run_now_at_ms",
1263
- "isExpression": false,
1264
- "asc": true,
1265
- "nulls": "last"
1266
- },
1267
- {
1268
- "expression": "created_at_ms",
1269
- "isExpression": false,
1270
- "asc": true,
1271
- "nulls": "last"
1272
- },
1273
- {
1274
- "expression": "id",
1275
- "isExpression": false,
1276
- "asc": true,
1277
- "nulls": "last"
1278
- }
1279
- ],
1280
- "isUnique": false,
1281
- "where": "\"junior_automations\".\"status\" = 'active' AND \"junior_automations\".\"run_now_at_ms\" IS NOT NULL",
1282
- "concurrently": false,
1283
- "method": "btree",
1284
- "with": {}
1285
- },
1286
- "junior_automations_next_run_due_idx": {
1287
- "name": "junior_automations_next_run_due_idx",
1288
- "columns": [
1289
- {
1290
- "expression": "next_run_at_ms",
1291
- "isExpression": false,
1292
- "asc": true,
1293
- "nulls": "last"
1294
- },
1295
- {
1296
- "expression": "created_at_ms",
1297
- "isExpression": false,
1298
- "asc": true,
1299
- "nulls": "last"
1300
- },
1301
- {
1302
- "expression": "id",
1303
- "isExpression": false,
1304
- "asc": true,
1305
- "nulls": "last"
1306
- }
1307
- ],
1308
- "isUnique": false,
1309
- "where": "\"junior_automations\".\"status\" = 'active' AND \"junior_automations\".\"next_run_at_ms\" IS NOT NULL",
1310
- "concurrently": false,
1311
- "method": "btree",
1312
- "with": {}
1313
- },
1314
- "junior_automations_skill_idx": {
1315
- "name": "junior_automations_skill_idx",
1316
- "columns": [
1317
- {
1318
- "expression": "skill",
1319
- "isExpression": false,
1320
- "asc": true,
1321
- "nulls": "last"
1322
- },
1323
- {
1324
- "expression": "created_at_ms",
1325
- "isExpression": false,
1326
- "asc": true,
1327
- "nulls": "last"
1328
- },
1329
- {
1330
- "expression": "id",
1331
- "isExpression": false,
1332
- "asc": true,
1333
- "nulls": "last"
1334
- }
1335
- ],
1336
- "isUnique": false,
1337
- "where": "\"junior_automations\".\"status\" <> 'deleted' AND \"junior_automations\".\"skill\" IS NOT NULL",
1338
- "concurrently": false,
1339
- "method": "btree",
1340
- "with": {}
1341
- },
1342
- "junior_automations_match_idx": {
1343
- "name": "junior_automations_match_idx",
1344
- "columns": [
1345
- {
1346
- "expression": "namespace",
1347
- "isExpression": false,
1348
- "asc": true,
1349
- "nulls": "last"
1350
- },
1351
- {
1352
- "expression": "identifier",
1353
- "isExpression": false,
1354
- "asc": true,
1355
- "nulls": "last"
1356
- },
1357
- {
1358
- "expression": "created_at_ms",
1359
- "isExpression": false,
1360
- "asc": true,
1361
- "nulls": "last"
1362
- },
1363
- {
1364
- "expression": "id",
1365
- "isExpression": false,
1366
- "asc": true,
1367
- "nulls": "last"
1368
- }
1369
- ],
1370
- "isUnique": false,
1371
- "where": "\"junior_automations\".\"status\" <> 'deleted'",
1372
- "concurrently": false,
1373
- "method": "btree",
1374
- "with": {}
1375
- }
1376
- },
1377
- "foreignKeys": {
1378
- "junior_automations_creator_identity_id_junior_identities_id_fk": {
1379
- "name": "junior_automations_creator_identity_id_junior_identities_id_fk",
1380
- "tableFrom": "junior_automations",
1381
- "tableTo": "junior_identities",
1382
- "columnsFrom": [
1383
- "creator_identity_id"
1384
- ],
1385
- "columnsTo": [
1386
- "id"
1387
- ],
1388
- "onDelete": "no action",
1389
- "onUpdate": "no action"
1390
- }
1391
- },
1392
- "compositePrimaryKeys": {},
1393
- "uniqueConstraints": {},
1394
- "policies": {},
1395
- "checkConstraints": {
1396
- "junior_automations_kind_check": {
1397
- "name": "junior_automations_kind_check",
1398
- "value": "\"junior_automations\".\"kind\" in ('scheduled', 'event')"
1399
- },
1400
- "junior_automations_status_check": {
1401
- "name": "junior_automations_status_check",
1402
- "value": "\"junior_automations\".\"status\" in ('active', 'blocked', 'paused', 'completed', 'deleted')"
1403
- },
1404
- "junior_automations_task_check": {
1405
- "name": "junior_automations_task_check",
1406
- "value": "(\"junior_automations\".\"instruction\" is null) <> (\"junior_automations\".\"skill\" is null)"
1407
- },
1408
- "junior_automations_record_check": {
1409
- "name": "junior_automations_record_check",
1410
- "value": "jsonb_typeof(\"junior_automations\".\"record\") = 'object'"
1411
- },
1412
- "junior_automations_trigger_check": {
1413
- "name": "junior_automations_trigger_check",
1414
- "value": "(\"junior_automations\".\"kind\" = 'scheduled' and \"junior_automations\".\"namespace\" is null and \"junior_automations\".\"identifier\" is null) or (\"junior_automations\".\"kind\" = 'event' and \"junior_automations\".\"namespace\" is not null and \"junior_automations\".\"next_run_at_ms\" is null and \"junior_automations\".\"run_now_at_ms\" is null and \"junior_automations\".\"status\" <> 'completed')"
1415
- }
1416
- },
1417
- "isRLSEnabled": false
1418
- },
1419
- "public.junior_code_changes": {
1420
- "name": "junior_code_changes",
1421
- "schema": "",
1422
- "columns": {
1423
- "id": {
1424
- "name": "id",
1425
- "type": "uuid",
1426
- "primaryKey": true,
1427
- "notNull": true
1428
- },
1429
- "closed_at": {
1430
- "name": "closed_at",
1431
- "type": "timestamp with time zone",
1432
- "primaryKey": false,
1433
- "notNull": false
1434
- },
1435
- "conversation_ids": {
1436
- "name": "conversation_ids",
1437
- "type": "text[]",
1438
- "primaryKey": false,
1439
- "notNull": true,
1440
- "default": "ARRAY[]::text[]"
1441
- },
1442
- "draft": {
1443
- "name": "draft",
1444
- "type": "boolean",
1445
- "primaryKey": false,
1446
- "notNull": true,
1447
- "default": false
1448
- },
1449
- "last_activity_at": {
1450
- "name": "last_activity_at",
1451
- "type": "timestamp with time zone",
1452
- "primaryKey": false,
1453
- "notNull": false
1454
- },
1455
- "merged_at": {
1456
- "name": "merged_at",
1457
- "type": "timestamp with time zone",
1458
- "primaryKey": false,
1459
- "notNull": false
1460
- },
1461
- "number": {
1462
- "name": "number",
1463
- "type": "integer",
1464
- "primaryKey": false,
1465
- "notNull": true
1466
- },
1467
- "opened_at": {
1468
- "name": "opened_at",
1469
- "type": "timestamp with time zone",
1470
- "primaryKey": false,
1471
- "notNull": true
1472
- },
1473
- "provider": {
1474
- "name": "provider",
1475
- "type": "text",
1476
- "primaryKey": false,
1477
- "notNull": true
1478
- },
1479
- "provider_id": {
1480
- "name": "provider_id",
1481
- "type": "text",
1482
- "primaryKey": false,
1483
- "notNull": true
1484
- },
1485
- "repository_id": {
1486
- "name": "repository_id",
1487
- "type": "uuid",
1488
- "primaryKey": false,
1489
- "notNull": true
1490
- },
1491
- "state": {
1492
- "name": "state",
1493
- "type": "text",
1494
- "primaryKey": false,
1495
- "notNull": true
1496
- },
1497
- "title": {
1498
- "name": "title",
1499
- "type": "text",
1500
- "primaryKey": false,
1501
- "notNull": false
1502
- },
1503
- "updated_at": {
1504
- "name": "updated_at",
1505
- "type": "timestamp with time zone",
1506
- "primaryKey": false,
1507
- "notNull": true
1508
- },
1509
- "url": {
1510
- "name": "url",
1511
- "type": "text",
1512
- "primaryKey": false,
1513
- "notNull": false
1514
- }
1515
- },
1516
- "indexes": {
1517
- "junior_code_changes_provider_id_idx": {
1518
- "name": "junior_code_changes_provider_id_idx",
1519
- "columns": [
1520
- {
1521
- "expression": "provider",
1522
- "isExpression": false,
1523
- "asc": true,
1524
- "nulls": "last"
1525
- },
1526
- {
1527
- "expression": "provider_id",
1528
- "isExpression": false,
1529
- "asc": true,
1530
- "nulls": "last"
1531
- }
1532
- ],
1533
- "isUnique": true,
1534
- "concurrently": false,
1535
- "method": "btree",
1536
- "with": {}
1537
- },
1538
- "junior_code_changes_opened_at_idx": {
1539
- "name": "junior_code_changes_opened_at_idx",
1540
- "columns": [
1541
- {
1542
- "expression": "opened_at",
1543
- "isExpression": false,
1544
- "asc": true,
1545
- "nulls": "last"
1546
- }
1547
- ],
1548
- "isUnique": false,
1549
- "concurrently": false,
1550
- "method": "btree",
1551
- "with": {}
1552
- },
1553
- "junior_code_changes_merged_at_idx": {
1554
- "name": "junior_code_changes_merged_at_idx",
1555
- "columns": [
1556
- {
1557
- "expression": "merged_at",
1558
- "isExpression": false,
1559
- "asc": true,
1560
- "nulls": "last"
1561
- }
1562
- ],
1563
- "isUnique": false,
1564
- "concurrently": false,
1565
- "method": "btree",
1566
- "with": {}
1567
- },
1568
- "junior_code_changes_closed_at_idx": {
1569
- "name": "junior_code_changes_closed_at_idx",
1570
- "columns": [
1571
- {
1572
- "expression": "closed_at",
1573
- "isExpression": false,
1574
- "asc": true,
1575
- "nulls": "last"
1576
- }
1577
- ],
1578
- "isUnique": false,
1579
- "concurrently": false,
1580
- "method": "btree",
1581
- "with": {}
1582
- },
1583
- "junior_code_changes_repository_state_idx": {
1584
- "name": "junior_code_changes_repository_state_idx",
1585
- "columns": [
1586
- {
1587
- "expression": "repository_id",
1588
- "isExpression": false,
1589
- "asc": true,
1590
- "nulls": "last"
1591
- },
1592
- {
1593
- "expression": "state",
1594
- "isExpression": false,
1595
- "asc": true,
1596
- "nulls": "last"
1597
- },
1598
- {
1599
- "expression": "updated_at",
1600
- "isExpression": false,
1601
- "asc": false,
1602
- "nulls": "last"
1603
- }
1604
- ],
1605
- "isUnique": false,
1606
- "concurrently": false,
1607
- "method": "btree",
1608
- "with": {}
1609
- },
1610
- "junior_code_changes_open_idx": {
1611
- "name": "junior_code_changes_open_idx",
1612
- "columns": [
1613
- {
1614
- "expression": "id",
1615
- "isExpression": false,
1616
- "asc": true,
1617
- "nulls": "last"
1618
- }
1619
- ],
1620
- "isUnique": false,
1621
- "where": "\"junior_code_changes\".\"state\" = 'open'",
1622
- "concurrently": false,
1623
- "method": "btree",
1624
- "with": {}
1625
- }
1626
- },
1627
- "foreignKeys": {
1628
- "junior_code_changes_repository_id_junior_code_repositories_id_fk": {
1629
- "name": "junior_code_changes_repository_id_junior_code_repositories_id_fk",
1630
- "tableFrom": "junior_code_changes",
1631
- "tableTo": "junior_code_repositories",
1632
- "columnsFrom": [
1633
- "repository_id"
1634
- ],
1635
- "columnsTo": [
1636
- "id"
1637
- ],
1638
- "onDelete": "cascade",
1639
- "onUpdate": "no action"
1640
- }
1641
- },
1642
- "compositePrimaryKeys": {},
1643
- "uniqueConstraints": {},
1644
- "policies": {},
1645
- "checkConstraints": {},
1646
- "isRLSEnabled": false
1647
- },
1648
- "public.junior_code_repositories": {
1649
- "name": "junior_code_repositories",
1650
- "schema": "",
1651
- "columns": {
1652
- "id": {
1653
- "name": "id",
1654
- "type": "uuid",
1655
- "primaryKey": true,
1656
- "notNull": true
1657
- },
1658
- "name": {
1659
- "name": "name",
1660
- "type": "text",
1661
- "primaryKey": false,
1662
- "notNull": true
1663
- },
1664
- "provider": {
1665
- "name": "provider",
1666
- "type": "text",
1667
- "primaryKey": false,
1668
- "notNull": true
1669
- },
1670
- "provider_id": {
1671
- "name": "provider_id",
1672
- "type": "text",
1673
- "primaryKey": false,
1674
- "notNull": true
1675
- },
1676
- "url": {
1677
- "name": "url",
1678
- "type": "text",
1679
- "primaryKey": false,
1680
- "notNull": false
1681
- },
1682
- "updated_at": {
1683
- "name": "updated_at",
1684
- "type": "timestamp with time zone",
1685
- "primaryKey": false,
1686
- "notNull": true
1687
- }
1688
- },
1689
- "indexes": {
1690
- "junior_code_repositories_provider_id_idx": {
1691
- "name": "junior_code_repositories_provider_id_idx",
1692
- "columns": [
1693
- {
1694
- "expression": "provider",
1695
- "isExpression": false,
1696
- "asc": true,
1697
- "nulls": "last"
1698
- },
1699
- {
1700
- "expression": "provider_id",
1701
- "isExpression": false,
1702
- "asc": true,
1703
- "nulls": "last"
1704
- }
1705
- ],
1706
- "isUnique": true,
1707
- "concurrently": false,
1708
- "method": "btree",
1709
- "with": {}
1710
- }
1711
- },
1712
- "foreignKeys": {},
1713
- "compositePrimaryKeys": {},
1714
- "uniqueConstraints": {},
1715
- "policies": {},
1716
- "checkConstraints": {},
1717
- "isRLSEnabled": false
1718
- },
1719
- "public.junior_conversation_annotations": {
1720
- "name": "junior_conversation_annotations",
1721
- "schema": "",
1722
- "columns": {
1723
- "conversation_id": {
1724
- "name": "conversation_id",
1725
- "type": "text",
1726
- "primaryKey": false,
1727
- "notNull": true
1728
- },
1729
- "plugin": {
1730
- "name": "plugin",
1731
- "type": "text",
1732
- "primaryKey": false,
1733
- "notNull": true
1734
- },
1735
- "kind": {
1736
- "name": "kind",
1737
- "type": "text",
1738
- "primaryKey": false,
1739
- "notNull": true
1740
- },
1741
- "key": {
1742
- "name": "key",
1743
- "type": "text",
1744
- "primaryKey": false,
1745
- "notNull": true
1746
- },
1747
- "annotation_json": {
1748
- "name": "annotation_json",
1749
- "type": "jsonb",
1750
- "primaryKey": false,
1751
- "notNull": true
1752
- },
1753
- "created_at": {
1754
- "name": "created_at",
1755
- "type": "timestamp with time zone",
1756
- "primaryKey": false,
1757
- "notNull": true
1758
- },
1759
- "updated_at": {
1760
- "name": "updated_at",
1761
- "type": "timestamp with time zone",
1762
- "primaryKey": false,
1763
- "notNull": true
1764
- }
1765
- },
1766
- "indexes": {},
1767
- "foreignKeys": {
1768
- "junior_conversation_annotations_conversation_id_fk": {
1769
- "name": "junior_conversation_annotations_conversation_id_fk",
1770
- "tableFrom": "junior_conversation_annotations",
1771
- "tableTo": "junior_conversations",
1772
- "columnsFrom": [
1773
- "conversation_id"
1774
- ],
1775
- "columnsTo": [
1776
- "conversation_id"
1777
- ],
1778
- "onDelete": "cascade",
1779
- "onUpdate": "no action"
1780
- }
1781
- },
1782
- "compositePrimaryKeys": {
1783
- "junior_conversation_annotations_pk": {
1784
- "name": "junior_conversation_annotations_pk",
1785
- "columns": [
1786
- "conversation_id",
1787
- "plugin",
1788
- "kind",
1789
- "key"
1790
- ]
1791
- }
1792
- },
1793
- "uniqueConstraints": {},
1794
- "policies": {},
1795
- "checkConstraints": {},
1796
- "isRLSEnabled": false
1797
- },
1798
- "public.junior_conversation_bindings": {
1799
- "name": "junior_conversation_bindings",
1800
- "schema": "",
1801
- "columns": {
1802
- "conversation_id": {
1803
- "name": "conversation_id",
1804
- "type": "text",
1805
- "primaryKey": false,
1806
- "notNull": true
1807
- },
1808
- "provider": {
1809
- "name": "provider",
1810
- "type": "text",
1811
- "primaryKey": false,
1812
- "notNull": true
1813
- },
1814
- "provider_tenant_id": {
1815
- "name": "provider_tenant_id",
1816
- "type": "text",
1817
- "primaryKey": false,
1818
- "notNull": true,
1819
- "default": "''"
1820
- },
1821
- "provider_destination_id": {
1822
- "name": "provider_destination_id",
1823
- "type": "text",
1824
- "primaryKey": false,
1825
- "notNull": true
1826
- },
1827
- "provider_conversation_id": {
1828
- "name": "provider_conversation_id",
1829
- "type": "text",
1830
- "primaryKey": false,
1831
- "notNull": true
1832
- },
1833
- "created_at": {
1834
- "name": "created_at",
1835
- "type": "timestamp with time zone",
1836
- "primaryKey": false,
1837
- "notNull": true
1838
- }
1839
- },
1840
- "indexes": {
1841
- "junior_conversation_bindings_conversation_idx": {
1842
- "name": "junior_conversation_bindings_conversation_idx",
1843
- "columns": [
1844
- {
1845
- "expression": "conversation_id",
1846
- "isExpression": false,
1847
- "asc": true,
1848
- "nulls": "last"
1849
- }
1850
- ],
1851
- "isUnique": false,
1852
- "concurrently": false,
1853
- "method": "btree",
1854
- "with": {}
1855
- }
1856
- },
1857
- "foreignKeys": {
1858
- "junior_conversation_bindings_conversation_id_junior_conversations_conversation_id_fk": {
1859
- "name": "junior_conversation_bindings_conversation_id_junior_conversations_conversation_id_fk",
1860
- "tableFrom": "junior_conversation_bindings",
1861
- "tableTo": "junior_conversations",
1862
- "columnsFrom": [
1863
- "conversation_id"
1864
- ],
1865
- "columnsTo": [
1866
- "conversation_id"
1867
- ],
1868
- "onDelete": "no action",
1869
- "onUpdate": "no action"
1870
- }
1871
- },
1872
- "compositePrimaryKeys": {
1873
- "junior_conversation_bindings_provider_conversation_pk": {
1874
- "name": "junior_conversation_bindings_provider_conversation_pk",
1875
- "columns": [
1876
- "provider",
1877
- "provider_tenant_id",
1878
- "provider_destination_id",
1879
- "provider_conversation_id"
1880
- ]
1881
- }
1882
- },
1883
- "uniqueConstraints": {},
1884
- "policies": {},
1885
- "checkConstraints": {},
1886
- "isRLSEnabled": false
1887
- },
1888
- "public.junior_conversation_briefs": {
1889
- "name": "junior_conversation_briefs",
1890
- "schema": "",
1891
- "columns": {
1892
- "conversation_id": {
1893
- "name": "conversation_id",
1894
- "type": "text",
1895
- "primaryKey": false,
1896
- "notNull": true
1897
- },
1898
- "version": {
1899
- "name": "version",
1900
- "type": "integer",
1901
- "primaryKey": false,
1902
- "notNull": true
1903
- },
1904
- "turn_id": {
1905
- "name": "turn_id",
1906
- "type": "text",
1907
- "primaryKey": false,
1908
- "notNull": true
1909
- },
1910
- "through_seq": {
1911
- "name": "through_seq",
1912
- "type": "integer",
1913
- "primaryKey": false,
1914
- "notNull": true
1915
- },
1916
- "content": {
1917
- "name": "content",
1918
- "type": "jsonb",
1919
- "primaryKey": false,
1920
- "notNull": true
1921
- },
1922
- "search_text": {
1923
- "name": "search_text",
1924
- "type": "text",
1925
- "primaryKey": false,
1926
- "notNull": true
1927
- },
1928
- "model_id": {
1929
- "name": "model_id",
1930
- "type": "text",
1931
- "primaryKey": false,
1932
- "notNull": true
1933
- },
1934
- "cost_usd": {
1935
- "name": "cost_usd",
1936
- "type": "double precision",
1937
- "primaryKey": false,
1938
- "notNull": false
1939
- },
1940
- "created_at": {
1941
- "name": "created_at",
1942
- "type": "timestamp with time zone",
1943
- "primaryKey": false,
1944
- "notNull": true,
1945
- "default": "now()"
1946
- }
1947
- },
1948
- "indexes": {
1949
- "junior_conversation_briefs_conversation_turn_idx": {
1950
- "name": "junior_conversation_briefs_conversation_turn_idx",
1951
- "columns": [
1952
- {
1953
- "expression": "conversation_id",
1954
- "isExpression": false,
1955
- "asc": true,
1956
- "nulls": "last"
1957
- },
1958
- {
1959
- "expression": "turn_id",
1960
- "isExpression": false,
1961
- "asc": true,
1962
- "nulls": "last"
1963
- }
1964
- ],
1965
- "isUnique": true,
1966
- "concurrently": false,
1967
- "method": "btree",
1968
- "with": {}
1969
- },
1970
- "junior_conversation_briefs_conversation_version_idx": {
1971
- "name": "junior_conversation_briefs_conversation_version_idx",
1972
- "columns": [
1973
- {
1974
- "expression": "conversation_id",
1975
- "isExpression": false,
1976
- "asc": true,
1977
- "nulls": "last"
1978
- },
1979
- {
1980
- "expression": "version",
1981
- "isExpression": false,
1982
- "asc": false,
1983
- "nulls": "last"
1984
- }
1985
- ],
1986
- "isUnique": false,
1987
- "concurrently": false,
1988
- "method": "btree",
1989
- "with": {}
1990
- },
1991
- "junior_conversation_briefs_search_idx": {
1992
- "name": "junior_conversation_briefs_search_idx",
1993
- "columns": [
1994
- {
1995
- "expression": "to_tsvector('english', \"search_text\")",
1996
- "asc": true,
1997
- "isExpression": true,
1998
- "nulls": "last"
1999
- }
2000
- ],
2001
- "isUnique": false,
2002
- "concurrently": false,
2003
- "method": "gin",
2004
- "with": {}
2005
- }
2006
- },
2007
- "foreignKeys": {
2008
- "junior_conversation_briefs_conversation_id_junior_conversations_conversation_id_fk": {
2009
- "name": "junior_conversation_briefs_conversation_id_junior_conversations_conversation_id_fk",
2010
- "tableFrom": "junior_conversation_briefs",
2011
- "tableTo": "junior_conversations",
2012
- "columnsFrom": [
2013
- "conversation_id"
2014
- ],
2015
- "columnsTo": [
2016
- "conversation_id"
2017
- ],
2018
- "onDelete": "cascade",
2019
- "onUpdate": "no action"
2020
- }
2021
- },
2022
- "compositePrimaryKeys": {
2023
- "junior_conversation_briefs_conversation_id_version_pk": {
2024
- "name": "junior_conversation_briefs_conversation_id_version_pk",
2025
- "columns": [
2026
- "conversation_id",
2027
- "version"
2028
- ]
2029
- }
2030
- },
2031
- "uniqueConstraints": {},
2032
- "policies": {},
2033
- "checkConstraints": {},
2034
- "isRLSEnabled": false
2035
- },
2036
- "public.junior_conversation_embeddings": {
2037
- "name": "junior_conversation_embeddings",
2038
- "schema": "",
2039
- "columns": {
2040
- "conversation_id": {
2041
- "name": "conversation_id",
2042
- "type": "text",
2043
- "primaryKey": true,
2044
- "notNull": true
2045
- },
2046
- "brief_version": {
2047
- "name": "brief_version",
2048
- "type": "integer",
2049
- "primaryKey": false,
2050
- "notNull": true
2051
- },
2052
- "provider": {
2053
- "name": "provider",
2054
- "type": "text",
2055
- "primaryKey": false,
2056
- "notNull": true
2057
- },
2058
- "model": {
2059
- "name": "model",
2060
- "type": "text",
2061
- "primaryKey": false,
2062
- "notNull": true
2063
- },
2064
- "dimensions": {
2065
- "name": "dimensions",
2066
- "type": "integer",
2067
- "primaryKey": false,
2068
- "notNull": true
2069
- },
2070
- "embedding": {
2071
- "name": "embedding",
2072
- "type": "vector",
2073
- "primaryKey": false,
2074
- "notNull": true
2075
- },
2076
- "created_at": {
2077
- "name": "created_at",
2078
- "type": "timestamp with time zone",
2079
- "primaryKey": false,
2080
- "notNull": true,
2081
- "default": "now()"
2082
- }
2083
- },
2084
- "indexes": {},
2085
- "foreignKeys": {
2086
- "junior_conversation_embeddings_brief_fk": {
2087
- "name": "junior_conversation_embeddings_brief_fk",
2088
- "tableFrom": "junior_conversation_embeddings",
2089
- "tableTo": "junior_conversation_briefs",
2090
- "columnsFrom": [
2091
- "conversation_id",
2092
- "brief_version"
2093
- ],
2094
- "columnsTo": [
2095
- "conversation_id",
2096
- "version"
2097
- ],
2098
- "onDelete": "cascade",
2099
- "onUpdate": "no action"
2100
- }
2101
- },
2102
- "compositePrimaryKeys": {},
2103
- "uniqueConstraints": {},
2104
- "policies": {},
2105
- "checkConstraints": {
2106
- "junior_conversation_embeddings_dimensions_check": {
2107
- "name": "junior_conversation_embeddings_dimensions_check",
2108
- "value": "vector_dims(\"junior_conversation_embeddings\".\"embedding\") = \"junior_conversation_embeddings\".\"dimensions\""
2109
- }
2110
- },
2111
- "isRLSEnabled": false
2112
- },
2113
- "public.junior_conversation_events": {
2114
- "name": "junior_conversation_events",
2115
- "schema": "",
2116
- "columns": {
2117
- "conversation_id": {
2118
- "name": "conversation_id",
2119
- "type": "text",
2120
- "primaryKey": false,
2121
- "notNull": true
2122
- },
2123
- "seq": {
2124
- "name": "seq",
2125
- "type": "integer",
2126
- "primaryKey": false,
2127
- "notNull": true
2128
- },
2129
- "history_version": {
2130
- "name": "history_version",
2131
- "type": "integer",
2132
- "primaryKey": false,
2133
- "notNull": true
2134
- },
2135
- "schema_version": {
2136
- "name": "schema_version",
2137
- "type": "integer",
2138
- "primaryKey": false,
2139
- "notNull": true,
2140
- "default": 1
2141
- },
2142
- "idempotency_key": {
2143
- "name": "idempotency_key",
2144
- "type": "text",
2145
- "primaryKey": false,
2146
- "notNull": false
2147
- },
2148
- "type": {
2149
- "name": "type",
2150
- "type": "text",
2151
- "primaryKey": false,
2152
- "notNull": true
2153
- },
2154
- "payload": {
2155
- "name": "payload",
2156
- "type": "jsonb",
2157
- "primaryKey": false,
2158
- "notNull": true
2159
- },
2160
- "actor_identity_id": {
2161
- "name": "actor_identity_id",
2162
- "type": "text",
2163
- "primaryKey": false,
2164
- "notNull": false
2165
- },
2166
- "created_at": {
2167
- "name": "created_at",
2168
- "type": "timestamp with time zone",
2169
- "primaryKey": false,
2170
- "notNull": true
2171
- }
2172
- },
2173
- "indexes": {
2174
- "junior_conversation_events_history_version_idx": {
2175
- "name": "junior_conversation_events_history_version_idx",
2176
- "columns": [
2177
- {
2178
- "expression": "conversation_id",
2179
- "isExpression": false,
2180
- "asc": true,
2181
- "nulls": "last"
2182
- },
2183
- {
2184
- "expression": "history_version",
2185
- "isExpression": false,
2186
- "asc": true,
2187
- "nulls": "last"
2188
- },
2189
- {
2190
- "expression": "seq",
2191
- "isExpression": false,
2192
- "asc": true,
2193
- "nulls": "last"
2194
- }
2195
- ],
2196
- "isUnique": false,
2197
- "concurrently": false,
2198
- "method": "btree",
2199
- "with": {}
2200
- },
2201
- "junior_conversation_events_type_idx": {
2202
- "name": "junior_conversation_events_type_idx",
2203
- "columns": [
2204
- {
2205
- "expression": "conversation_id",
2206
- "isExpression": false,
2207
- "asc": true,
2208
- "nulls": "last"
2209
- },
2210
- {
2211
- "expression": "type",
2212
- "isExpression": false,
2213
- "asc": true,
2214
- "nulls": "last"
2215
- },
2216
- {
2217
- "expression": "seq",
2218
- "isExpression": false,
2219
- "asc": true,
2220
- "nulls": "last"
2221
- }
2222
- ],
2223
- "isUnique": false,
2224
- "concurrently": false,
2225
- "method": "btree",
2226
- "with": {}
2227
- },
2228
- "junior_conversation_events_plugin_report_idx": {
2229
- "name": "junior_conversation_events_plugin_report_idx",
2230
- "columns": [
2231
- {
2232
- "expression": "(\"payload\"->>'namespace')",
2233
- "asc": true,
2234
- "isExpression": true,
2235
- "nulls": "last"
2236
- },
2237
- {
2238
- "expression": "(\"payload\"->>'name')",
2239
- "asc": true,
2240
- "isExpression": true,
2241
- "nulls": "last"
2242
- },
2243
- {
2244
- "expression": "created_at",
2245
- "isExpression": false,
2246
- "asc": true,
2247
- "nulls": "last"
2248
- }
2249
- ],
2250
- "isUnique": false,
2251
- "where": "\"junior_conversation_events\".\"type\" = 'structured_event'",
2252
- "concurrently": false,
2253
- "method": "btree",
2254
- "with": {}
2255
- },
2256
- "junior_conversation_events_guardian_review_time_idx": {
2257
- "name": "junior_conversation_events_guardian_review_time_idx",
2258
- "columns": [
2259
- {
2260
- "expression": "created_at",
2261
- "isExpression": false,
2262
- "asc": true,
2263
- "nulls": "last"
2264
- }
2265
- ],
2266
- "isUnique": false,
2267
- "where": "\"junior_conversation_events\".\"type\" = 'guardian_action_reviewed'",
2268
- "concurrently": false,
2269
- "method": "btree",
2270
- "with": {}
2271
- },
2272
- "junior_conversation_events_plugin_conversation_idx": {
2273
- "name": "junior_conversation_events_plugin_conversation_idx",
2274
- "columns": [
2275
- {
2276
- "expression": "conversation_id",
2277
- "isExpression": false,
2278
- "asc": true,
2279
- "nulls": "last"
2280
- },
2281
- {
2282
- "expression": "(\"payload\"->>'namespace')",
2283
- "asc": true,
2284
- "isExpression": true,
2285
- "nulls": "last"
2286
- },
2287
- {
2288
- "expression": "(\"payload\"->>'name')",
2289
- "asc": true,
2290
- "isExpression": true,
2291
- "nulls": "last"
2292
- },
2293
- {
2294
- "expression": "seq",
2295
- "isExpression": false,
2296
- "asc": true,
2297
- "nulls": "last"
2298
- }
2299
- ],
2300
- "isUnique": false,
2301
- "where": "\"junior_conversation_events\".\"type\" = 'structured_event'",
2302
- "concurrently": false,
2303
- "method": "btree",
2304
- "with": {}
2305
- },
2306
- "junior_conversation_events_actor_identity_idx": {
2307
- "name": "junior_conversation_events_actor_identity_idx",
2308
- "columns": [
2309
- {
2310
- "expression": "actor_identity_id",
2311
- "isExpression": false,
2312
- "asc": true,
2313
- "nulls": "last"
2314
- },
2315
- {
2316
- "expression": "conversation_id",
2317
- "isExpression": false,
2318
- "asc": true,
2319
- "nulls": "last"
2320
- },
2321
- {
2322
- "expression": "seq",
2323
- "isExpression": false,
2324
- "asc": true,
2325
- "nulls": "last"
2326
- }
2327
- ],
2328
- "isUnique": false,
2329
- "concurrently": false,
2330
- "method": "btree",
2331
- "with": {}
2332
- },
2333
- "junior_conversation_events_author_idx": {
2334
- "name": "junior_conversation_events_author_idx",
2335
- "columns": [
2336
- {
2337
- "expression": "conversation_id",
2338
- "isExpression": false,
2339
- "asc": true,
2340
- "nulls": "last"
2341
- },
2342
- {
2343
- "expression": "actor_identity_id",
2344
- "isExpression": false,
2345
- "asc": true,
2346
- "nulls": "last"
2347
- },
2348
- {
2349
- "expression": "seq",
2350
- "isExpression": false,
2351
- "asc": true,
2352
- "nulls": "last"
2353
- }
2354
- ],
2355
- "isUnique": false,
2356
- "where": "\"junior_conversation_events\".\"actor_identity_id\" is not null",
2357
- "concurrently": false,
2358
- "method": "btree",
2359
- "with": {}
2360
- },
2361
- "junior_conversation_events_message_role_idx": {
2362
- "name": "junior_conversation_events_message_role_idx",
2363
- "columns": [
2364
- {
2365
- "expression": "conversation_id",
2366
- "isExpression": false,
2367
- "asc": true,
2368
- "nulls": "last"
2369
- },
2370
- {
2371
- "expression": "(\"payload\"->>'role')",
2372
- "asc": true,
2373
- "isExpression": true,
2374
- "nulls": "last"
2375
- },
2376
- {
2377
- "expression": "created_at",
2378
- "isExpression": false,
2379
- "asc": true,
2380
- "nulls": "last"
2381
- },
2382
- {
2383
- "expression": "seq",
2384
- "isExpression": false,
2385
- "asc": true,
2386
- "nulls": "last"
2387
- }
2388
- ],
2389
- "isUnique": false,
2390
- "where": "\"junior_conversation_events\".\"type\" = 'message'",
2391
- "concurrently": false,
2392
- "method": "btree",
2393
- "with": {}
2394
- },
2395
- "junior_conversation_events_user_message_time_idx": {
2396
- "name": "junior_conversation_events_user_message_time_idx",
2397
- "columns": [
2398
- {
2399
- "expression": "conversation_id",
2400
- "isExpression": false,
2401
- "asc": true,
2402
- "nulls": "last"
2403
- },
2404
- {
2405
- "expression": "created_at",
2406
- "isExpression": false,
2407
- "asc": true,
2408
- "nulls": "last"
2409
- },
2410
- {
2411
- "expression": "seq",
2412
- "isExpression": false,
2413
- "asc": true,
2414
- "nulls": "last"
2415
- }
2416
- ],
2417
- "isUnique": false,
2418
- "where": "\"junior_conversation_events\".\"type\" = 'user_message' and (\"junior_conversation_events\".\"payload\"->'provenance'->>'authority') = 'instruction' and (\"junior_conversation_events\".\"payload\"->'provenance'->'actor'->>'platform') in ('slack', 'local', 'web')",
2419
- "concurrently": false,
2420
- "method": "btree",
2421
- "with": {}
2422
- },
2423
- "junior_conversation_events_message_search_idx": {
2424
- "name": "junior_conversation_events_message_search_idx",
2425
- "columns": [
2426
- {
2427
- "expression": "to_tsvector('english', \"payload\"->>'text')",
2428
- "asc": true,
2429
- "isExpression": true,
2430
- "nulls": "last"
2431
- }
2432
- ],
2433
- "isUnique": false,
2434
- "where": "\"junior_conversation_events\".\"type\" = 'message'",
2435
- "concurrently": false,
2436
- "method": "gin",
2437
- "with": {}
2438
- },
2439
- "junior_conversation_events_idempotency_idx": {
2440
- "name": "junior_conversation_events_idempotency_idx",
2441
- "columns": [
2442
- {
2443
- "expression": "conversation_id",
2444
- "isExpression": false,
2445
- "asc": true,
2446
- "nulls": "last"
2447
- },
2448
- {
2449
- "expression": "idempotency_key",
2450
- "isExpression": false,
2451
- "asc": true,
2452
- "nulls": "last"
2453
- }
2454
- ],
2455
- "isUnique": true,
2456
- "concurrently": false,
2457
- "method": "btree",
2458
- "with": {}
2459
- }
2460
- },
2461
- "foreignKeys": {
2462
- "junior_conversation_events_actor_identity_id_junior_identities_id_fk": {
2463
- "name": "junior_conversation_events_actor_identity_id_junior_identities_id_fk",
2464
- "tableFrom": "junior_conversation_events",
2465
- "tableTo": "junior_identities",
2466
- "columnsFrom": [
2467
- "actor_identity_id"
2468
- ],
2469
- "columnsTo": [
2470
- "id"
2471
- ],
2472
- "onDelete": "no action",
2473
- "onUpdate": "no action"
2474
- },
2475
- "junior_conversation_events_conversation_id_junior_conversations_conversation_id_fk": {
2476
- "name": "junior_conversation_events_conversation_id_junior_conversations_conversation_id_fk",
2477
- "tableFrom": "junior_conversation_events",
2478
- "tableTo": "junior_conversations",
2479
- "columnsFrom": [
2480
- "conversation_id"
2481
- ],
2482
- "columnsTo": [
2483
- "conversation_id"
2484
- ],
2485
- "onDelete": "no action",
2486
- "onUpdate": "no action"
2487
- }
2488
- },
2489
- "compositePrimaryKeys": {
2490
- "junior_conversation_events_conversation_id_seq_pk": {
2491
- "name": "junior_conversation_events_conversation_id_seq_pk",
2492
- "columns": [
2493
- "conversation_id",
2494
- "seq"
2495
- ]
2496
- }
2497
- },
2498
- "uniqueConstraints": {},
2499
- "policies": {},
2500
- "checkConstraints": {},
2501
- "isRLSEnabled": false
2502
- },
2503
- "public.junior_conversation_metrics": {
2504
- "name": "junior_conversation_metrics",
2505
- "schema": "",
2506
- "columns": {
2507
- "conversation_id": {
2508
- "name": "conversation_id",
2509
- "type": "text",
2510
- "primaryKey": false,
2511
- "notNull": true
2512
- },
2513
- "run_id": {
2514
- "name": "run_id",
2515
- "type": "text",
2516
- "primaryKey": false,
2517
- "notNull": true
2518
- },
2519
- "metric": {
2520
- "name": "metric",
2521
- "type": "text",
2522
- "primaryKey": false,
2523
- "notNull": true
2524
- },
2525
- "actor_identity_id": {
2526
- "name": "actor_identity_id",
2527
- "type": "text",
2528
- "primaryKey": false,
2529
- "notNull": false
2530
- },
2531
- "value": {
2532
- "name": "value",
2533
- "type": "double precision",
2534
- "primaryKey": false,
2535
- "notNull": true
2536
- },
2537
- "occurred_at": {
2538
- "name": "occurred_at",
2539
- "type": "timestamp with time zone",
2540
- "primaryKey": false,
2541
- "notNull": true
2542
- },
2543
- "updated_at": {
2544
- "name": "updated_at",
2545
- "type": "timestamp with time zone",
2546
- "primaryKey": false,
2547
- "notNull": true
2548
- }
2549
- },
2550
- "indexes": {
2551
- "junior_conversation_metrics_actor_identity_occurred_at_idx": {
2552
- "name": "junior_conversation_metrics_actor_identity_occurred_at_idx",
2553
- "columns": [
2554
- {
2555
- "expression": "actor_identity_id",
2556
- "isExpression": false,
2557
- "asc": true,
2558
- "nulls": "last"
2559
- },
2560
- {
2561
- "expression": "occurred_at",
2562
- "isExpression": false,
2563
- "asc": true,
2564
- "nulls": "last"
2565
- }
2566
- ],
2567
- "isUnique": false,
2568
- "concurrently": false,
2569
- "method": "btree",
2570
- "with": {}
2571
- },
2572
- "junior_conversation_metrics_occurred_at_metric_idx": {
2573
- "name": "junior_conversation_metrics_occurred_at_metric_idx",
2574
- "columns": [
2575
- {
2576
- "expression": "occurred_at",
2577
- "isExpression": false,
2578
- "asc": true,
2579
- "nulls": "last"
2580
- },
2581
- {
2582
- "expression": "metric",
2583
- "isExpression": false,
2584
- "asc": true,
2585
- "nulls": "last"
2586
- }
2587
- ],
2588
- "isUnique": false,
2589
- "concurrently": false,
2590
- "method": "btree",
2591
- "with": {}
2592
- }
2593
- },
2594
- "foreignKeys": {
2595
- "junior_conversation_metrics_actor_identity_id_junior_identities_id_fk": {
2596
- "name": "junior_conversation_metrics_actor_identity_id_junior_identities_id_fk",
2597
- "tableFrom": "junior_conversation_metrics",
2598
- "tableTo": "junior_identities",
2599
- "columnsFrom": [
2600
- "actor_identity_id"
2601
- ],
2602
- "columnsTo": [
2603
- "id"
2604
- ],
2605
- "onDelete": "no action",
2606
- "onUpdate": "no action"
2607
- },
2608
- "junior_conversation_metrics_conversation_id_junior_conversations_conversation_id_fk": {
2609
- "name": "junior_conversation_metrics_conversation_id_junior_conversations_conversation_id_fk",
2610
- "tableFrom": "junior_conversation_metrics",
2611
- "tableTo": "junior_conversations",
2612
- "columnsFrom": [
2613
- "conversation_id"
2614
- ],
2615
- "columnsTo": [
2616
- "conversation_id"
2617
- ],
2618
- "onDelete": "no action",
2619
- "onUpdate": "no action"
2620
- }
2621
- },
2622
- "compositePrimaryKeys": {
2623
- "junior_conversation_metrics_conversation_id_run_id_metric_pk": {
2624
- "name": "junior_conversation_metrics_conversation_id_run_id_metric_pk",
2625
- "columns": [
2626
- "conversation_id",
2627
- "run_id",
2628
- "metric"
2629
- ]
2630
- }
2631
- },
2632
- "uniqueConstraints": {},
2633
- "policies": {},
2634
- "checkConstraints": {},
2635
- "isRLSEnabled": false
2636
- },
2637
- "public.junior_conversation_participants": {
2638
- "name": "junior_conversation_participants",
2639
- "schema": "",
2640
- "columns": {
2641
- "user_id": {
2642
- "name": "user_id",
2643
- "type": "text",
2644
- "primaryKey": false,
2645
- "notNull": true
2646
- },
2647
- "root_conversation_id": {
2648
- "name": "root_conversation_id",
2649
- "type": "text",
2650
- "primaryKey": false,
2651
- "notNull": true
2652
- },
2653
- "last_message_at": {
2654
- "name": "last_message_at",
2655
- "type": "timestamp with time zone",
2656
- "primaryKey": false,
2657
- "notNull": true
2658
- },
2659
- "archived_at": {
2660
- "name": "archived_at",
2661
- "type": "timestamp with time zone",
2662
- "primaryKey": false,
2663
- "notNull": false
2664
- },
2665
- "pinned_at": {
2666
- "name": "pinned_at",
2667
- "type": "timestamp with time zone",
2668
- "primaryKey": false,
2669
- "notNull": false
2670
- },
2671
- "pin_position": {
2672
- "name": "pin_position",
2673
- "type": "integer",
2674
- "primaryKey": false,
2675
- "notNull": false
2676
- },
2677
- "auto_archive": {
2678
- "name": "auto_archive",
2679
- "type": "boolean",
2680
- "primaryKey": false,
2681
- "notNull": false
2682
- },
2683
- "unsubscribed_at": {
2684
- "name": "unsubscribed_at",
2685
- "type": "timestamp with time zone",
2686
- "primaryKey": false,
2687
- "notNull": false
2688
- }
2689
- },
2690
- "indexes": {
2691
- "junior_conversation_participants_user_activity_idx": {
2692
- "name": "junior_conversation_participants_user_activity_idx",
2693
- "columns": [
2694
- {
2695
- "expression": "user_id",
2696
- "isExpression": false,
2697
- "asc": true,
2698
- "nulls": "last"
2699
- },
2700
- {
2701
- "expression": "last_message_at",
2702
- "isExpression": false,
2703
- "asc": false,
2704
- "nulls": "last"
2705
- }
2706
- ],
2707
- "isUnique": false,
2708
- "concurrently": false,
2709
- "method": "btree",
2710
- "with": {}
2711
- },
2712
- "junior_conversation_participants_root_idx": {
2713
- "name": "junior_conversation_participants_root_idx",
2714
- "columns": [
2715
- {
2716
- "expression": "root_conversation_id",
2717
- "isExpression": false,
2718
- "asc": true,
2719
- "nulls": "last"
2720
- }
2721
- ],
2722
- "isUnique": false,
2723
- "concurrently": false,
2724
- "method": "btree",
2725
- "with": {}
2726
- },
2727
- "junior_conversation_participants_auto_archive_idx": {
2728
- "name": "junior_conversation_participants_auto_archive_idx",
2729
- "columns": [
2730
- {
2731
- "expression": "user_id",
2732
- "isExpression": false,
2733
- "asc": true,
2734
- "nulls": "last"
2735
- }
2736
- ],
2737
- "isUnique": false,
2738
- "where": "\"junior_conversation_participants\".\"auto_archive\"",
2739
- "concurrently": false,
2740
- "method": "btree",
2741
- "with": {}
2742
- },
2743
- "junior_conversation_participants_unsubscribed_idx": {
2744
- "name": "junior_conversation_participants_unsubscribed_idx",
2745
- "columns": [
2746
- {
2747
- "expression": "user_id",
2748
- "isExpression": false,
2749
- "asc": true,
2750
- "nulls": "last"
2751
- },
2752
- {
2753
- "expression": "root_conversation_id",
2754
- "isExpression": false,
2755
- "asc": true,
2756
- "nulls": "last"
2757
- }
2758
- ],
2759
- "isUnique": false,
2760
- "where": "\"junior_conversation_participants\".\"unsubscribed_at\" is not null",
2761
- "concurrently": false,
2762
- "method": "btree",
2763
- "with": {}
2764
- }
2765
- },
2766
- "foreignKeys": {
2767
- "junior_conversation_participants_user_id_junior_users_id_fk": {
2768
- "name": "junior_conversation_participants_user_id_junior_users_id_fk",
2769
- "tableFrom": "junior_conversation_participants",
2770
- "tableTo": "junior_users",
2771
- "columnsFrom": [
2772
- "user_id"
2773
- ],
2774
- "columnsTo": [
2775
- "id"
2776
- ],
2777
- "onDelete": "no action",
2778
- "onUpdate": "no action"
2779
- },
2780
- "junior_conversation_participants_root_conversation_id_junior_conversations_conversation_id_fk": {
2781
- "name": "junior_conversation_participants_root_conversation_id_junior_conversations_conversation_id_fk",
2782
- "tableFrom": "junior_conversation_participants",
2783
- "tableTo": "junior_conversations",
2784
- "columnsFrom": [
2785
- "root_conversation_id"
2786
- ],
2787
- "columnsTo": [
2788
- "conversation_id"
2789
- ],
2790
- "onDelete": "no action",
2791
- "onUpdate": "no action"
2792
- }
2793
- },
2794
- "compositePrimaryKeys": {
2795
- "junior_conversation_participants_user_root_pk": {
2796
- "name": "junior_conversation_participants_user_root_pk",
2797
- "columns": [
2798
- "user_id",
2799
- "root_conversation_id"
2800
- ]
2801
- }
2802
- },
2803
- "uniqueConstraints": {},
2804
- "policies": {},
2805
- "checkConstraints": {},
2806
- "isRLSEnabled": false
2807
- },
2808
- "public.junior_conversation_read_positions": {
2809
- "name": "junior_conversation_read_positions",
2810
- "schema": "",
2811
- "columns": {
2812
- "user_id": {
2813
- "name": "user_id",
2814
- "type": "text",
2815
- "primaryKey": false,
2816
- "notNull": true
2817
- },
2818
- "conversation_id": {
2819
- "name": "conversation_id",
2820
- "type": "text",
2821
- "primaryKey": false,
2822
- "notNull": true
2823
- },
2824
- "last_read_seq": {
2825
- "name": "last_read_seq",
2826
- "type": "integer",
2827
- "primaryKey": false,
2828
- "notNull": true
2829
- },
2830
- "updated_at": {
2831
- "name": "updated_at",
2832
- "type": "timestamp with time zone",
2833
- "primaryKey": false,
2834
- "notNull": true
2835
- }
2836
- },
2837
- "indexes": {},
2838
- "foreignKeys": {
2839
- "junior_conversation_read_positions_user_id_junior_users_id_fk": {
2840
- "name": "junior_conversation_read_positions_user_id_junior_users_id_fk",
2841
- "tableFrom": "junior_conversation_read_positions",
2842
- "tableTo": "junior_users",
2843
- "columnsFrom": [
2844
- "user_id"
2845
- ],
2846
- "columnsTo": [
2847
- "id"
2848
- ],
2849
- "onDelete": "no action",
2850
- "onUpdate": "no action"
2851
- },
2852
- "junior_conversation_read_positions_conversation_id_junior_conversations_conversation_id_fk": {
2853
- "name": "junior_conversation_read_positions_conversation_id_junior_conversations_conversation_id_fk",
2854
- "tableFrom": "junior_conversation_read_positions",
2855
- "tableTo": "junior_conversations",
2856
- "columnsFrom": [
2857
- "conversation_id"
2858
- ],
2859
- "columnsTo": [
2860
- "conversation_id"
2861
- ],
2862
- "onDelete": "no action",
2863
- "onUpdate": "no action"
2864
- }
2865
- },
2866
- "compositePrimaryKeys": {
2867
- "junior_conversation_read_positions_user_conversation_pk": {
2868
- "name": "junior_conversation_read_positions_user_conversation_pk",
2869
- "columns": [
2870
- "user_id",
2871
- "conversation_id"
2872
- ]
2873
- }
2874
- },
2875
- "uniqueConstraints": {},
2876
- "policies": {},
2877
- "checkConstraints": {},
2878
- "isRLSEnabled": false
2879
- },
2880
- "public.junior_conversations": {
2881
- "name": "junior_conversations",
2882
- "schema": "",
2883
- "columns": {
2884
- "conversation_id": {
2885
- "name": "conversation_id",
2886
- "type": "text",
2887
- "primaryKey": true,
2888
- "notNull": true
2889
- },
2890
- "schema_version": {
2891
- "name": "schema_version",
2892
- "type": "integer",
2893
- "primaryKey": false,
2894
- "notNull": true,
2895
- "default": 1
2896
- },
2897
- "source": {
2898
- "name": "source",
2899
- "type": "text",
2900
- "primaryKey": false,
2901
- "notNull": false
2902
- },
2903
- "source_json": {
2904
- "name": "source_json",
2905
- "type": "jsonb",
2906
- "primaryKey": false,
2907
- "notNull": false
2908
- },
2909
- "location_json": {
2910
- "name": "location_json",
2911
- "type": "jsonb",
2912
- "primaryKey": false,
2913
- "notNull": false
2914
- },
2915
- "destination_id": {
2916
- "name": "destination_id",
2917
- "type": "text",
2918
- "primaryKey": false,
2919
- "notNull": false
2920
- },
2921
- "destination_json": {
2922
- "name": "destination_json",
2923
- "type": "jsonb",
2924
- "primaryKey": false,
2925
- "notNull": false
2926
- },
2927
- "actor_identity_id": {
2928
- "name": "actor_identity_id",
2929
- "type": "text",
2930
- "primaryKey": false,
2931
- "notNull": false
2932
- },
2933
- "creator_identity_id": {
2934
- "name": "creator_identity_id",
2935
- "type": "text",
2936
- "primaryKey": false,
2937
- "notNull": false
2938
- },
2939
- "credential_subject_identity_id": {
2940
- "name": "credential_subject_identity_id",
2941
- "type": "text",
2942
- "primaryKey": false,
2943
- "notNull": false
2944
- },
2945
- "actor_json": {
2946
- "name": "actor_json",
2947
- "type": "jsonb",
2948
- "primaryKey": false,
2949
- "notNull": false
2950
- },
2951
- "channel_name": {
2952
- "name": "channel_name",
2953
- "type": "text",
2954
- "primaryKey": false,
2955
- "notNull": false
2956
- },
2957
- "title": {
2958
- "name": "title",
2959
- "type": "text",
2960
- "primaryKey": false,
2961
- "notNull": false
2962
- },
2963
- "created_at": {
2964
- "name": "created_at",
2965
- "type": "timestamp with time zone",
2966
- "primaryKey": false,
2967
- "notNull": true
2968
- },
2969
- "last_activity_at": {
2970
- "name": "last_activity_at",
2971
- "type": "timestamp with time zone",
2972
- "primaryKey": false,
2973
- "notNull": true
2974
- },
2975
- "last_message_at": {
2976
- "name": "last_message_at",
2977
- "type": "timestamp with time zone",
2978
- "primaryKey": false,
2979
- "notNull": false
2980
- },
2981
- "updated_at": {
2982
- "name": "updated_at",
2983
- "type": "timestamp with time zone",
2984
- "primaryKey": false,
2985
- "notNull": true
2986
- },
2987
- "execution_updated_at": {
2988
- "name": "execution_updated_at",
2989
- "type": "timestamp with time zone",
2990
- "primaryKey": false,
2991
- "notNull": false
2992
- },
2993
- "execution_status": {
2994
- "name": "execution_status",
2995
- "type": "text",
2996
- "primaryKey": false,
2997
- "notNull": true
2998
- },
2999
- "run_id": {
3000
- "name": "run_id",
3001
- "type": "text",
3002
- "primaryKey": false,
3003
- "notNull": false
3004
- },
3005
- "last_checkpoint_at": {
3006
- "name": "last_checkpoint_at",
3007
- "type": "timestamp with time zone",
3008
- "primaryKey": false,
3009
- "notNull": false
3010
- },
3011
- "last_enqueued_at": {
3012
- "name": "last_enqueued_at",
3013
- "type": "timestamp with time zone",
3014
- "primaryKey": false,
3015
- "notNull": false
3016
- },
3017
- "parent_conversation_id": {
3018
- "name": "parent_conversation_id",
3019
- "type": "text",
3020
- "primaryKey": false,
3021
- "notNull": false
3022
- },
3023
- "kind": {
3024
- "name": "kind",
3025
- "type": "text",
3026
- "primaryKey": false,
3027
- "notNull": false
3028
- },
3029
- "agent_config_json": {
3030
- "name": "agent_config_json",
3031
- "type": "jsonb",
3032
- "primaryKey": false,
3033
- "notNull": false
3034
- },
3035
- "archived_at": {
3036
- "name": "archived_at",
3037
- "type": "timestamp with time zone",
3038
- "primaryKey": false,
3039
- "notNull": false
3040
- },
3041
- "child_archived_at": {
3042
- "name": "child_archived_at",
3043
- "type": "timestamp with time zone",
3044
- "primaryKey": false,
3045
- "notNull": false
3046
- },
3047
- "forked_from_conversation_id": {
3048
- "name": "forked_from_conversation_id",
3049
- "type": "text",
3050
- "primaryKey": false,
3051
- "notNull": false
3052
- },
3053
- "quick_question_at": {
3054
- "name": "quick_question_at",
3055
- "type": "timestamp with time zone",
3056
- "primaryKey": false,
3057
- "notNull": false
3058
- },
3059
- "root_conversation_id": {
3060
- "name": "root_conversation_id",
3061
- "type": "text",
3062
- "primaryKey": false,
3063
- "notNull": false
3064
- },
3065
- "transcript_purged_at": {
3066
- "name": "transcript_purged_at",
3067
- "type": "timestamp with time zone",
3068
- "primaryKey": false,
3069
- "notNull": false
3070
- },
3071
- "stopped_at": {
3072
- "name": "stopped_at",
3073
- "type": "timestamp with time zone",
3074
- "primaryKey": false,
3075
- "notNull": false
3076
- },
3077
- "delivery_paused_at": {
3078
- "name": "delivery_paused_at",
3079
- "type": "timestamp with time zone",
3080
- "primaryKey": false,
3081
- "notNull": false
3082
- },
3083
- "duration_ms": {
3084
- "name": "duration_ms",
3085
- "type": "integer",
3086
- "primaryKey": false,
3087
- "notNull": true,
3088
- "default": 0
3089
- },
3090
- "usage_json": {
3091
- "name": "usage_json",
3092
- "type": "jsonb",
3093
- "primaryKey": false,
3094
- "notNull": false
3095
- },
3096
- "execution_duration_ms": {
3097
- "name": "execution_duration_ms",
3098
- "type": "integer",
3099
- "primaryKey": false,
3100
- "notNull": true,
3101
- "default": 0
3102
- },
3103
- "execution_usage_json": {
3104
- "name": "execution_usage_json",
3105
- "type": "jsonb",
3106
- "primaryKey": false,
3107
- "notNull": false
3108
- },
3109
- "metric_run_id": {
3110
- "name": "metric_run_id",
3111
- "type": "text",
3112
- "primaryKey": false,
3113
- "notNull": false
3114
- },
3115
- "detail_version": {
3116
- "name": "detail_version",
3117
- "type": "integer",
3118
- "primaryKey": false,
3119
- "notNull": true,
3120
- "default": 0
3121
- }
3122
- },
3123
- "indexes": {
3124
- "junior_conversations_last_activity_idx": {
3125
- "name": "junior_conversations_last_activity_idx",
3126
- "columns": [
3127
- {
3128
- "expression": "last_activity_at",
3129
- "isExpression": false,
3130
- "asc": false,
3131
- "nulls": "last"
3132
- },
3133
- {
3134
- "expression": "conversation_id",
3135
- "isExpression": false,
3136
- "asc": true,
3137
- "nulls": "last"
3138
- }
3139
- ],
3140
- "isUnique": false,
3141
- "concurrently": false,
3142
- "method": "btree",
3143
- "with": {}
3144
- },
3145
- "junior_conversations_active_idx": {
3146
- "name": "junior_conversations_active_idx",
3147
- "columns": [
3148
- {
3149
- "expression": "coalesce(\"execution_updated_at\", \"updated_at\")",
3150
- "asc": true,
3151
- "isExpression": true,
3152
- "nulls": "last"
3153
- },
3154
- {
3155
- "expression": "conversation_id",
3156
- "isExpression": false,
3157
- "asc": true,
3158
- "nulls": "last"
3159
- }
3160
- ],
3161
- "isUnique": false,
3162
- "where": "\"junior_conversations\".\"execution_status\" <> 'idle'",
3163
- "concurrently": false,
3164
- "method": "btree",
3165
- "with": {}
3166
- },
3167
- "junior_conversations_destination_activity_idx": {
3168
- "name": "junior_conversations_destination_activity_idx",
3169
- "columns": [
3170
- {
3171
- "expression": "destination_id",
3172
- "isExpression": false,
3173
- "asc": true,
3174
- "nulls": "last"
3175
- },
3176
- {
3177
- "expression": "last_activity_at",
3178
- "isExpression": false,
3179
- "asc": false,
3180
- "nulls": "last"
3181
- }
3182
- ],
3183
- "isUnique": false,
3184
- "concurrently": false,
3185
- "method": "btree",
3186
- "with": {}
3187
- },
3188
- "junior_conversations_actor_activity_idx": {
3189
- "name": "junior_conversations_actor_activity_idx",
3190
- "columns": [
3191
- {
3192
- "expression": "actor_identity_id",
3193
- "isExpression": false,
3194
- "asc": true,
3195
- "nulls": "last"
3196
- },
3197
- {
3198
- "expression": "last_activity_at",
3199
- "isExpression": false,
3200
- "asc": false,
3201
- "nulls": "last"
3202
- }
3203
- ],
3204
- "isUnique": false,
3205
- "concurrently": false,
3206
- "method": "btree",
3207
- "with": {}
3208
- },
3209
- "junior_conversations_parent_idx": {
3210
- "name": "junior_conversations_parent_idx",
3211
- "columns": [
3212
- {
3213
- "expression": "parent_conversation_id",
3214
- "isExpression": false,
3215
- "asc": true,
3216
- "nulls": "last"
3217
- }
3218
- ],
3219
- "isUnique": false,
3220
- "concurrently": false,
3221
- "method": "btree",
3222
- "with": {}
3223
- },
3224
- "junior_conversations_forked_from_idx": {
3225
- "name": "junior_conversations_forked_from_idx",
3226
- "columns": [
3227
- {
3228
- "expression": "forked_from_conversation_id",
3229
- "isExpression": false,
3230
- "asc": true,
3231
- "nulls": "last"
3232
- }
3233
- ],
3234
- "isUnique": false,
3235
- "concurrently": false,
3236
- "method": "btree",
3237
- "with": {}
3238
- },
3239
- "junior_conversations_root_idx": {
3240
- "name": "junior_conversations_root_idx",
3241
- "columns": [
3242
- {
3243
- "expression": "root_conversation_id",
3244
- "isExpression": false,
3245
- "asc": true,
3246
- "nulls": "last"
3247
- }
3248
- ],
3249
- "isUnique": false,
3250
- "concurrently": false,
3251
- "method": "btree",
3252
- "with": {}
3253
- }
3254
- },
3255
- "foreignKeys": {
3256
- "junior_conversations_destination_id_junior_destinations_id_fk": {
3257
- "name": "junior_conversations_destination_id_junior_destinations_id_fk",
3258
- "tableFrom": "junior_conversations",
3259
- "tableTo": "junior_destinations",
3260
- "columnsFrom": [
3261
- "destination_id"
3262
- ],
3263
- "columnsTo": [
3264
- "id"
3265
- ],
3266
- "onDelete": "no action",
3267
- "onUpdate": "no action"
3268
- },
3269
- "junior_conversations_actor_identity_id_junior_identities_id_fk": {
3270
- "name": "junior_conversations_actor_identity_id_junior_identities_id_fk",
3271
- "tableFrom": "junior_conversations",
3272
- "tableTo": "junior_identities",
3273
- "columnsFrom": [
3274
- "actor_identity_id"
3275
- ],
3276
- "columnsTo": [
3277
- "id"
3278
- ],
3279
- "onDelete": "no action",
3280
- "onUpdate": "no action"
3281
- },
3282
- "junior_conversations_creator_identity_id_junior_identities_id_fk": {
3283
- "name": "junior_conversations_creator_identity_id_junior_identities_id_fk",
3284
- "tableFrom": "junior_conversations",
3285
- "tableTo": "junior_identities",
3286
- "columnsFrom": [
3287
- "creator_identity_id"
3288
- ],
3289
- "columnsTo": [
3290
- "id"
3291
- ],
3292
- "onDelete": "no action",
3293
- "onUpdate": "no action"
3294
- },
3295
- "junior_conversations_credential_subject_identity_id_junior_identities_id_fk": {
3296
- "name": "junior_conversations_credential_subject_identity_id_junior_identities_id_fk",
3297
- "tableFrom": "junior_conversations",
3298
- "tableTo": "junior_identities",
3299
- "columnsFrom": [
3300
- "credential_subject_identity_id"
3301
- ],
3302
- "columnsTo": [
3303
- "id"
3304
- ],
3305
- "onDelete": "no action",
3306
- "onUpdate": "no action"
3307
- },
3308
- "junior_conversations_parent_conversation_id_junior_conversations_conversation_id_fk": {
3309
- "name": "junior_conversations_parent_conversation_id_junior_conversations_conversation_id_fk",
3310
- "tableFrom": "junior_conversations",
3311
- "tableTo": "junior_conversations",
3312
- "columnsFrom": [
3313
- "parent_conversation_id"
3314
- ],
3315
- "columnsTo": [
3316
- "conversation_id"
3317
- ],
3318
- "onDelete": "no action",
3319
- "onUpdate": "no action"
3320
- },
3321
- "junior_conversations_forked_from_conversation_id_junior_conversations_conversation_id_fk": {
3322
- "name": "junior_conversations_forked_from_conversation_id_junior_conversations_conversation_id_fk",
3323
- "tableFrom": "junior_conversations",
3324
- "tableTo": "junior_conversations",
3325
- "columnsFrom": [
3326
- "forked_from_conversation_id"
3327
- ],
3328
- "columnsTo": [
3329
- "conversation_id"
3330
- ],
3331
- "onDelete": "set null",
3332
- "onUpdate": "no action"
3333
- },
3334
- "junior_conversations_root_conversation_id_junior_conversations_conversation_id_fk": {
3335
- "name": "junior_conversations_root_conversation_id_junior_conversations_conversation_id_fk",
3336
- "tableFrom": "junior_conversations",
3337
- "tableTo": "junior_conversations",
3338
- "columnsFrom": [
3339
- "root_conversation_id"
3340
- ],
3341
- "columnsTo": [
3342
- "conversation_id"
3343
- ],
3344
- "onDelete": "no action",
3345
- "onUpdate": "no action"
3346
- }
3347
- },
3348
- "compositePrimaryKeys": {},
3349
- "uniqueConstraints": {},
3350
- "policies": {},
3351
- "checkConstraints": {
3352
- "junior_conversations_kind_check": {
3353
- "name": "junior_conversations_kind_check",
3354
- "value": "\"junior_conversations\".\"kind\" in ('root', 'automation', 'thread', 'task')"
3355
- },
3356
- "junior_conversations_kind_parent_check": {
3357
- "name": "junior_conversations_kind_parent_check",
3358
- "value": "\"junior_conversations\".\"kind\" is null or ((\"junior_conversations\".\"kind\" in ('root', 'automation')) = (\"junior_conversations\".\"parent_conversation_id\" is null))"
3359
- }
3360
- },
3361
- "isRLSEnabled": false
3362
- },
3363
- "public.junior_destinations": {
3364
- "name": "junior_destinations",
3365
- "schema": "",
3366
- "columns": {
3367
- "id": {
3368
- "name": "id",
3369
- "type": "text",
3370
- "primaryKey": true,
3371
- "notNull": true
3372
- },
3373
- "provider": {
3374
- "name": "provider",
3375
- "type": "text",
3376
- "primaryKey": false,
3377
- "notNull": true
3378
- },
3379
- "provider_tenant_id": {
3380
- "name": "provider_tenant_id",
3381
- "type": "text",
3382
- "primaryKey": false,
3383
- "notNull": true,
3384
- "default": "''"
3385
- },
3386
- "provider_destination_id": {
3387
- "name": "provider_destination_id",
3388
- "type": "text",
3389
- "primaryKey": false,
3390
- "notNull": true
3391
- },
3392
- "kind": {
3393
- "name": "kind",
3394
- "type": "text",
3395
- "primaryKey": false,
3396
- "notNull": true
3397
- },
3398
- "parent_destination_id": {
3399
- "name": "parent_destination_id",
3400
- "type": "text",
3401
- "primaryKey": false,
3402
- "notNull": false
3403
- },
3404
- "display_name": {
3405
- "name": "display_name",
3406
- "type": "text",
3407
- "primaryKey": false,
3408
- "notNull": false
3409
- },
3410
- "visibility": {
3411
- "name": "visibility",
3412
- "type": "text",
3413
- "primaryKey": false,
3414
- "notNull": true,
3415
- "default": "'unknown'"
3416
- },
3417
- "metadata_json": {
3418
- "name": "metadata_json",
3419
- "type": "jsonb",
3420
- "primaryKey": false,
3421
- "notNull": false
3422
- },
3423
- "created_at": {
3424
- "name": "created_at",
3425
- "type": "timestamp with time zone",
3426
- "primaryKey": false,
3427
- "notNull": true
3428
- },
3429
- "updated_at": {
3430
- "name": "updated_at",
3431
- "type": "timestamp with time zone",
3432
- "primaryKey": false,
3433
- "notNull": true
3434
- }
3435
- },
3436
- "indexes": {
3437
- "junior_destinations_provider_destination_uidx": {
3438
- "name": "junior_destinations_provider_destination_uidx",
3439
- "columns": [
3440
- {
3441
- "expression": "provider",
3442
- "isExpression": false,
3443
- "asc": true,
3444
- "nulls": "last"
3445
- },
3446
- {
3447
- "expression": "provider_tenant_id",
3448
- "isExpression": false,
3449
- "asc": true,
3450
- "nulls": "last"
3451
- },
3452
- {
3453
- "expression": "provider_destination_id",
3454
- "isExpression": false,
3455
- "asc": true,
3456
- "nulls": "last"
3457
- }
3458
- ],
3459
- "isUnique": true,
3460
- "concurrently": false,
3461
- "method": "btree",
3462
- "with": {}
3463
- },
3464
- "junior_destinations_provider_kind_idx": {
3465
- "name": "junior_destinations_provider_kind_idx",
3466
- "columns": [
3467
- {
3468
- "expression": "provider",
3469
- "isExpression": false,
3470
- "asc": true,
3471
- "nulls": "last"
3472
- },
3473
- {
3474
- "expression": "kind",
3475
- "isExpression": false,
3476
- "asc": true,
3477
- "nulls": "last"
3478
- }
3479
- ],
3480
- "isUnique": false,
3481
- "concurrently": false,
3482
- "method": "btree",
3483
- "with": {}
3484
- }
3485
- },
3486
- "foreignKeys": {},
3487
- "compositePrimaryKeys": {},
3488
- "uniqueConstraints": {},
3489
- "policies": {},
3490
- "checkConstraints": {},
3491
- "isRLSEnabled": false
3492
- },
3493
- "public.junior_identities": {
3494
- "name": "junior_identities",
3495
- "schema": "",
3496
- "columns": {
3497
- "id": {
3498
- "name": "id",
3499
- "type": "text",
3500
- "primaryKey": true,
3501
- "notNull": true
3502
- },
3503
- "kind": {
3504
- "name": "kind",
3505
- "type": "text",
3506
- "primaryKey": false,
3507
- "notNull": true
3508
- },
3509
- "provider": {
3510
- "name": "provider",
3511
- "type": "text",
3512
- "primaryKey": false,
3513
- "notNull": true
3514
- },
3515
- "provider_tenant_id": {
3516
- "name": "provider_tenant_id",
3517
- "type": "text",
3518
- "primaryKey": false,
3519
- "notNull": true,
3520
- "default": "''"
3521
- },
3522
- "provider_subject_id": {
3523
- "name": "provider_subject_id",
3524
- "type": "text",
3525
- "primaryKey": false,
3526
- "notNull": true
3527
- },
3528
- "display_name": {
3529
- "name": "display_name",
3530
- "type": "text",
3531
- "primaryKey": false,
3532
- "notNull": false
3533
- },
3534
- "handle": {
3535
- "name": "handle",
3536
- "type": "text",
3537
- "primaryKey": false,
3538
- "notNull": false
3539
- },
3540
- "email": {
3541
- "name": "email",
3542
- "type": "text",
3543
- "primaryKey": false,
3544
- "notNull": false
3545
- },
3546
- "avatar_url": {
3547
- "name": "avatar_url",
3548
- "type": "text",
3549
- "primaryKey": false,
3550
- "notNull": false
3551
- },
3552
- "metadata_json": {
3553
- "name": "metadata_json",
3554
- "type": "jsonb",
3555
- "primaryKey": false,
3556
- "notNull": false
3557
- },
3558
- "created_at": {
3559
- "name": "created_at",
3560
- "type": "timestamp with time zone",
3561
- "primaryKey": false,
3562
- "notNull": true
3563
- },
3564
- "updated_at": {
3565
- "name": "updated_at",
3566
- "type": "timestamp with time zone",
3567
- "primaryKey": false,
3568
- "notNull": true
3569
- },
3570
- "user_id": {
3571
- "name": "user_id",
3572
- "type": "text",
3573
- "primaryKey": false,
3574
- "notNull": false
3575
- },
3576
- "email_normalized": {
3577
- "name": "email_normalized",
3578
- "type": "text",
3579
- "primaryKey": false,
3580
- "notNull": false
3581
- },
3582
- "email_verified": {
3583
- "name": "email_verified",
3584
- "type": "boolean",
3585
- "primaryKey": false,
3586
- "notNull": true,
3587
- "default": false
3588
- },
3589
- "signed_in_at": {
3590
- "name": "signed_in_at",
3591
- "type": "timestamp with time zone",
3592
- "primaryKey": false,
3593
- "notNull": false
3594
- }
3595
- },
3596
- "indexes": {
3597
- "junior_identities_provider_subject_uidx": {
3598
- "name": "junior_identities_provider_subject_uidx",
3599
- "columns": [
3600
- {
3601
- "expression": "provider",
3602
- "isExpression": false,
3603
- "asc": true,
3604
- "nulls": "last"
3605
- },
3606
- {
3607
- "expression": "provider_tenant_id",
3608
- "isExpression": false,
3609
- "asc": true,
3610
- "nulls": "last"
3611
- },
3612
- {
3613
- "expression": "provider_subject_id",
3614
- "isExpression": false,
3615
- "asc": true,
3616
- "nulls": "last"
3617
- }
3618
- ],
3619
- "isUnique": true,
3620
- "concurrently": false,
3621
- "method": "btree",
3622
- "with": {}
3623
- },
3624
- "junior_identities_user_idx": {
3625
- "name": "junior_identities_user_idx",
3626
- "columns": [
3627
- {
3628
- "expression": "user_id",
3629
- "isExpression": false,
3630
- "asc": true,
3631
- "nulls": "last"
3632
- }
3633
- ],
3634
- "isUnique": false,
3635
- "concurrently": false,
3636
- "method": "btree",
3637
- "with": {}
3638
- },
3639
- "junior_identities_verified_email_idx": {
3640
- "name": "junior_identities_verified_email_idx",
3641
- "columns": [
3642
- {
3643
- "expression": "email_normalized",
3644
- "isExpression": false,
3645
- "asc": true,
3646
- "nulls": "last"
3647
- }
3648
- ],
3649
- "isUnique": false,
3650
- "where": "\"junior_identities\".\"email_verified\" = true AND \"junior_identities\".\"email_normalized\" IS NOT NULL",
3651
- "concurrently": false,
3652
- "method": "btree",
3653
- "with": {}
3654
- },
3655
- "junior_identities_kind_provider_idx": {
3656
- "name": "junior_identities_kind_provider_idx",
3657
- "columns": [
3658
- {
3659
- "expression": "kind",
3660
- "isExpression": false,
3661
- "asc": true,
3662
- "nulls": "last"
3663
- },
3664
- {
3665
- "expression": "provider",
3666
- "isExpression": false,
3667
- "asc": true,
3668
- "nulls": "last"
3669
- }
3670
- ],
3671
- "isUnique": false,
3672
- "concurrently": false,
3673
- "method": "btree",
3674
- "with": {}
3675
- }
3676
- },
3677
- "foreignKeys": {
3678
- "junior_identities_user_id_junior_users_id_fk": {
3679
- "name": "junior_identities_user_id_junior_users_id_fk",
3680
- "tableFrom": "junior_identities",
3681
- "tableTo": "junior_users",
3682
- "columnsFrom": [
3683
- "user_id"
3684
- ],
3685
- "columnsTo": [
3686
- "id"
3687
- ],
3688
- "onDelete": "no action",
3689
- "onUpdate": "no action"
3690
- }
3691
- },
3692
- "compositePrimaryKeys": {},
3693
- "uniqueConstraints": {},
3694
- "policies": {},
3695
- "checkConstraints": {},
3696
- "isRLSEnabled": false
3697
- },
3698
- "public.junior_location_configurations": {
3699
- "name": "junior_location_configurations",
3700
- "schema": "",
3701
- "columns": {
3702
- "location_id": {
3703
- "name": "location_id",
3704
- "type": "text",
3705
- "primaryKey": false,
3706
- "notNull": true
3707
- },
3708
- "key": {
3709
- "name": "key",
3710
- "type": "text",
3711
- "primaryKey": false,
3712
- "notNull": true
3713
- },
3714
- "value": {
3715
- "name": "value",
3716
- "type": "text",
3717
- "primaryKey": false,
3718
- "notNull": true
3719
- },
3720
- "updated_at": {
3721
- "name": "updated_at",
3722
- "type": "timestamp with time zone",
3723
- "primaryKey": false,
3724
- "notNull": true
3725
- },
3726
- "updated_by": {
3727
- "name": "updated_by",
3728
- "type": "text",
3729
- "primaryKey": false,
3730
- "notNull": false
3731
- },
3732
- "source": {
3733
- "name": "source",
3734
- "type": "text",
3735
- "primaryKey": false,
3736
- "notNull": false
3737
- },
3738
- "expires_at": {
3739
- "name": "expires_at",
3740
- "type": "text",
3741
- "primaryKey": false,
3742
- "notNull": false
3743
- }
3744
- },
3745
- "indexes": {},
3746
- "foreignKeys": {
3747
- "junior_location_configurations_location_id_junior_destinations_id_fk": {
3748
- "name": "junior_location_configurations_location_id_junior_destinations_id_fk",
3749
- "tableFrom": "junior_location_configurations",
3750
- "tableTo": "junior_destinations",
3751
- "columnsFrom": [
3752
- "location_id"
3753
- ],
3754
- "columnsTo": [
3755
- "id"
3756
- ],
3757
- "onDelete": "cascade",
3758
- "onUpdate": "no action"
3759
- }
3760
- },
3761
- "compositePrimaryKeys": {
3762
- "junior_location_configurations_location_id_key_pk": {
3763
- "name": "junior_location_configurations_location_id_key_pk",
3764
- "columns": [
3765
- "location_id",
3766
- "key"
3767
- ]
3768
- }
3769
- },
3770
- "uniqueConstraints": {},
3771
- "policies": {},
3772
- "checkConstraints": {},
3773
- "isRLSEnabled": false
3774
- },
3775
- "public.junior_push_subscriptions": {
3776
- "name": "junior_push_subscriptions",
3777
- "schema": "",
3778
- "columns": {
3779
- "id": {
3780
- "name": "id",
3781
- "type": "text",
3782
- "primaryKey": true,
3783
- "notNull": true
3784
- },
3785
- "user_id": {
3786
- "name": "user_id",
3787
- "type": "text",
3788
- "primaryKey": false,
3789
- "notNull": true
3790
- },
3791
- "endpoint": {
3792
- "name": "endpoint",
3793
- "type": "text",
3794
- "primaryKey": false,
3795
- "notNull": true
3796
- },
3797
- "p256dh": {
3798
- "name": "p256dh",
3799
- "type": "text",
3800
- "primaryKey": false,
3801
- "notNull": true
3802
- },
3803
- "auth": {
3804
- "name": "auth",
3805
- "type": "text",
3806
- "primaryKey": false,
3807
- "notNull": true
3808
- },
3809
- "created_at": {
3810
- "name": "created_at",
3811
- "type": "timestamp with time zone",
3812
- "primaryKey": false,
3813
- "notNull": true
3814
- },
3815
- "updated_at": {
3816
- "name": "updated_at",
3817
- "type": "timestamp with time zone",
3818
- "primaryKey": false,
3819
- "notNull": true
3820
- }
3821
- },
3822
- "indexes": {
3823
- "junior_push_subscriptions_endpoint_uidx": {
3824
- "name": "junior_push_subscriptions_endpoint_uidx",
3825
- "columns": [
3826
- {
3827
- "expression": "endpoint",
3828
- "isExpression": false,
3829
- "asc": true,
3830
- "nulls": "last"
3831
- }
3832
- ],
3833
- "isUnique": true,
3834
- "concurrently": false,
3835
- "method": "btree",
3836
- "with": {}
3837
- },
3838
- "junior_push_subscriptions_user_idx": {
3839
- "name": "junior_push_subscriptions_user_idx",
3840
- "columns": [
3841
- {
3842
- "expression": "user_id",
3843
- "isExpression": false,
3844
- "asc": true,
3845
- "nulls": "last"
3846
- }
3847
- ],
3848
- "isUnique": false,
3849
- "concurrently": false,
3850
- "method": "btree",
3851
- "with": {}
3852
- }
3853
- },
3854
- "foreignKeys": {
3855
- "junior_push_subscriptions_user_id_junior_users_id_fk": {
3856
- "name": "junior_push_subscriptions_user_id_junior_users_id_fk",
3857
- "tableFrom": "junior_push_subscriptions",
3858
- "tableTo": "junior_users",
3859
- "columnsFrom": [
3860
- "user_id"
3861
- ],
3862
- "columnsTo": [
3863
- "id"
3864
- ],
3865
- "onDelete": "cascade",
3866
- "onUpdate": "no action"
3867
- }
3868
- },
3869
- "compositePrimaryKeys": {},
3870
- "uniqueConstraints": {},
3871
- "policies": {},
3872
- "checkConstraints": {},
3873
- "isRLSEnabled": false
3874
- },
3875
- "public.junior_review_item_assignees": {
3876
- "name": "junior_review_item_assignees",
3877
- "schema": "",
3878
- "columns": {
3879
- "item_id": {
3880
- "name": "item_id",
3881
- "type": "text",
3882
- "primaryKey": false,
3883
- "notNull": true
3884
- },
3885
- "user_id": {
3886
- "name": "user_id",
3887
- "type": "text",
3888
- "primaryKey": false,
3889
- "notNull": true
3890
- }
3891
- },
3892
- "indexes": {
3893
- "junior_review_item_assignees_user_idx": {
3894
- "name": "junior_review_item_assignees_user_idx",
3895
- "columns": [
3896
- {
3897
- "expression": "user_id",
3898
- "isExpression": false,
3899
- "asc": true,
3900
- "nulls": "last"
3901
- }
3902
- ],
3903
- "isUnique": false,
3904
- "concurrently": false,
3905
- "method": "btree",
3906
- "with": {}
3907
- }
3908
- },
3909
- "foreignKeys": {
3910
- "junior_review_item_assignees_item_id_junior_review_items_id_fk": {
3911
- "name": "junior_review_item_assignees_item_id_junior_review_items_id_fk",
3912
- "tableFrom": "junior_review_item_assignees",
3913
- "tableTo": "junior_review_items",
3914
- "columnsFrom": [
3915
- "item_id"
3916
- ],
3917
- "columnsTo": [
3918
- "id"
3919
- ],
3920
- "onDelete": "cascade",
3921
- "onUpdate": "no action"
3922
- },
3923
- "junior_review_item_assignees_user_id_junior_users_id_fk": {
3924
- "name": "junior_review_item_assignees_user_id_junior_users_id_fk",
3925
- "tableFrom": "junior_review_item_assignees",
3926
- "tableTo": "junior_users",
3927
- "columnsFrom": [
3928
- "user_id"
3929
- ],
3930
- "columnsTo": [
3931
- "id"
3932
- ],
3933
- "onDelete": "cascade",
3934
- "onUpdate": "no action"
3935
- }
3936
- },
3937
- "compositePrimaryKeys": {
3938
- "junior_review_item_assignees_item_id_user_id_pk": {
3939
- "name": "junior_review_item_assignees_item_id_user_id_pk",
3940
- "columns": [
3941
- "item_id",
3942
- "user_id"
3943
- ]
3944
- }
3945
- },
3946
- "uniqueConstraints": {},
3947
- "policies": {},
3948
- "checkConstraints": {},
3949
- "isRLSEnabled": false
3950
- },
3951
- "public.junior_review_item_conversations": {
3952
- "name": "junior_review_item_conversations",
3953
- "schema": "",
3954
- "columns": {
3955
- "item_id": {
3956
- "name": "item_id",
3957
- "type": "text",
3958
- "primaryKey": false,
3959
- "notNull": true
3960
- },
3961
- "conversation_id": {
3962
- "name": "conversation_id",
3963
- "type": "text",
3964
- "primaryKey": false,
3965
- "notNull": true
3966
- }
3967
- },
3968
- "indexes": {
3969
- "junior_review_item_conversations_conversation_idx": {
3970
- "name": "junior_review_item_conversations_conversation_idx",
3971
- "columns": [
3972
- {
3973
- "expression": "conversation_id",
3974
- "isExpression": false,
3975
- "asc": true,
3976
- "nulls": "last"
3977
- }
3978
- ],
3979
- "isUnique": false,
3980
- "concurrently": false,
3981
- "method": "btree",
3982
- "with": {}
3983
- }
3984
- },
3985
- "foreignKeys": {
3986
- "junior_review_item_conversations_item_id_junior_review_items_id_fk": {
3987
- "name": "junior_review_item_conversations_item_id_junior_review_items_id_fk",
3988
- "tableFrom": "junior_review_item_conversations",
3989
- "tableTo": "junior_review_items",
3990
- "columnsFrom": [
3991
- "item_id"
3992
- ],
3993
- "columnsTo": [
3994
- "id"
3995
- ],
3996
- "onDelete": "cascade",
3997
- "onUpdate": "no action"
3998
- },
3999
- "junior_review_item_conversations_conversation_id_junior_conversations_conversation_id_fk": {
4000
- "name": "junior_review_item_conversations_conversation_id_junior_conversations_conversation_id_fk",
4001
- "tableFrom": "junior_review_item_conversations",
4002
- "tableTo": "junior_conversations",
4003
- "columnsFrom": [
4004
- "conversation_id"
4005
- ],
4006
- "columnsTo": [
4007
- "conversation_id"
4008
- ],
4009
- "onDelete": "cascade",
4010
- "onUpdate": "no action"
4011
- }
4012
- },
4013
- "compositePrimaryKeys": {
4014
- "junior_review_item_conversations_item_id_conversation_id_pk": {
4015
- "name": "junior_review_item_conversations_item_id_conversation_id_pk",
4016
- "columns": [
4017
- "item_id",
4018
- "conversation_id"
4019
- ]
4020
- }
4021
- },
4022
- "uniqueConstraints": {},
4023
- "policies": {},
4024
- "checkConstraints": {},
4025
- "isRLSEnabled": false
4026
- },
4027
- "public.junior_review_item_slack_cards": {
4028
- "name": "junior_review_item_slack_cards",
4029
- "schema": "",
4030
- "columns": {
4031
- "item_id": {
4032
- "name": "item_id",
4033
- "type": "text",
4034
- "primaryKey": false,
4035
- "notNull": true
4036
- },
4037
- "conversation_id": {
4038
- "name": "conversation_id",
4039
- "type": "text",
4040
- "primaryKey": false,
4041
- "notNull": true
4042
- },
4043
- "team_id": {
4044
- "name": "team_id",
4045
- "type": "text",
4046
- "primaryKey": false,
4047
- "notNull": true
4048
- },
4049
- "channel_id": {
4050
- "name": "channel_id",
4051
- "type": "text",
4052
- "primaryKey": false,
4053
- "notNull": true
4054
- },
4055
- "message_ts": {
4056
- "name": "message_ts",
4057
- "type": "text",
4058
- "primaryKey": false,
4059
- "notNull": true
4060
- }
4061
- },
4062
- "indexes": {},
4063
- "foreignKeys": {
4064
- "junior_review_item_slack_cards_item_id_junior_review_items_id_fk": {
4065
- "name": "junior_review_item_slack_cards_item_id_junior_review_items_id_fk",
4066
- "tableFrom": "junior_review_item_slack_cards",
4067
- "tableTo": "junior_review_items",
4068
- "columnsFrom": [
4069
- "item_id"
4070
- ],
4071
- "columnsTo": [
4072
- "id"
4073
- ],
4074
- "onDelete": "cascade",
4075
- "onUpdate": "no action"
4076
- },
4077
- "junior_review_item_slack_cards_conversation_id_junior_conversations_conversation_id_fk": {
4078
- "name": "junior_review_item_slack_cards_conversation_id_junior_conversations_conversation_id_fk",
4079
- "tableFrom": "junior_review_item_slack_cards",
4080
- "tableTo": "junior_conversations",
4081
- "columnsFrom": [
4082
- "conversation_id"
4083
- ],
4084
- "columnsTo": [
4085
- "conversation_id"
4086
- ],
4087
- "onDelete": "cascade",
4088
- "onUpdate": "no action"
4089
- }
4090
- },
4091
- "compositePrimaryKeys": {
4092
- "junior_review_item_slack_cards_item_id_conversation_id_pk": {
4093
- "name": "junior_review_item_slack_cards_item_id_conversation_id_pk",
4094
- "columns": [
4095
- "item_id",
4096
- "conversation_id"
4097
- ]
4098
- }
4099
- },
4100
- "uniqueConstraints": {},
4101
- "policies": {},
4102
- "checkConstraints": {},
4103
- "isRLSEnabled": false
4104
- },
4105
- "public.junior_review_items": {
4106
- "name": "junior_review_items",
4107
- "schema": "",
4108
- "columns": {
4109
- "id": {
4110
- "name": "id",
4111
- "type": "text",
4112
- "primaryKey": true,
4113
- "notNull": true
4114
- },
4115
- "kind": {
4116
- "name": "kind",
4117
- "type": "text",
4118
- "primaryKey": false,
4119
- "notNull": true
4120
- },
4121
- "status": {
4122
- "name": "status",
4123
- "type": "text",
4124
- "primaryKey": false,
4125
- "notNull": true
4126
- },
4127
- "visibility": {
4128
- "name": "visibility",
4129
- "type": "text",
4130
- "primaryKey": false,
4131
- "notNull": true
4132
- },
4133
- "title": {
4134
- "name": "title",
4135
- "type": "text",
4136
- "primaryKey": false,
4137
- "notNull": true
4138
- },
4139
- "body": {
4140
- "name": "body",
4141
- "type": "text",
4142
- "primaryKey": false,
4143
- "notNull": true
4144
- },
4145
- "request": {
4146
- "name": "request",
4147
- "type": "jsonb",
4148
- "primaryKey": false,
4149
- "notNull": false
4150
- },
4151
- "answer": {
4152
- "name": "answer",
4153
- "type": "jsonb",
4154
- "primaryKey": false,
4155
- "notNull": false
4156
- },
4157
- "assigned_to_everyone": {
4158
- "name": "assigned_to_everyone",
4159
- "type": "boolean",
4160
- "primaryKey": false,
4161
- "notNull": true,
4162
- "default": false
4163
- },
4164
- "dedupe_key": {
4165
- "name": "dedupe_key",
4166
- "type": "text",
4167
- "primaryKey": false,
4168
- "notNull": true
4169
- },
4170
- "subject_id": {
4171
- "name": "subject_id",
4172
- "type": "text",
4173
- "primaryKey": false,
4174
- "notNull": false
4175
- },
4176
- "subject_title": {
4177
- "name": "subject_title",
4178
- "type": "text",
4179
- "primaryKey": false,
4180
- "notNull": false
4181
- },
4182
- "subject_url": {
4183
- "name": "subject_url",
4184
- "type": "text",
4185
- "primaryKey": false,
4186
- "notNull": false
4187
- },
4188
- "added_by_conversation_id": {
4189
- "name": "added_by_conversation_id",
4190
- "type": "text",
4191
- "primaryKey": false,
4192
- "notNull": true
4193
- },
4194
- "added_by_turn_id": {
4195
- "name": "added_by_turn_id",
4196
- "type": "text",
4197
- "primaryKey": false,
4198
- "notNull": false
4199
- },
4200
- "provider": {
4201
- "name": "provider",
4202
- "type": "text",
4203
- "primaryKey": false,
4204
- "notNull": false
4205
- },
4206
- "provider_tenant_id": {
4207
- "name": "provider_tenant_id",
4208
- "type": "text",
4209
- "primaryKey": false,
4210
- "notNull": false
4211
- },
4212
- "automation_id": {
4213
- "name": "automation_id",
4214
- "type": "text",
4215
- "primaryKey": false,
4216
- "notNull": false
4217
- },
4218
- "closed_at": {
4219
- "name": "closed_at",
4220
- "type": "timestamp with time zone",
4221
- "primaryKey": false,
4222
- "notNull": false
4223
- },
4224
- "closed_by_user_id": {
4225
- "name": "closed_by_user_id",
4226
- "type": "text",
4227
- "primaryKey": false,
4228
- "notNull": false
4229
- },
4230
- "close_reason": {
4231
- "name": "close_reason",
4232
- "type": "text",
4233
- "primaryKey": false,
4234
- "notNull": false
4235
- },
4236
- "created_at": {
4237
- "name": "created_at",
4238
- "type": "timestamp with time zone",
4239
- "primaryKey": false,
4240
- "notNull": true
4241
- },
4242
- "updated_at": {
4243
- "name": "updated_at",
4244
- "type": "timestamp with time zone",
4245
- "primaryKey": false,
4246
- "notNull": true
4247
- }
4248
- },
4249
- "indexes": {
4250
- "junior_review_items_open_dedupe_uidx": {
4251
- "name": "junior_review_items_open_dedupe_uidx",
4252
- "columns": [
4253
- {
4254
- "expression": "coalesce(\"provider\", '')",
4255
- "asc": true,
4256
- "isExpression": true,
4257
- "nulls": "last"
4258
- },
4259
- {
4260
- "expression": "coalesce(\"provider_tenant_id\", '')",
4261
- "asc": true,
4262
- "isExpression": true,
4263
- "nulls": "last"
4264
- },
4265
- {
4266
- "expression": "dedupe_key",
4267
- "isExpression": false,
4268
- "asc": true,
4269
- "nulls": "last"
4270
- }
4271
- ],
4272
- "isUnique": true,
4273
- "where": "\"junior_review_items\".\"status\" = 'open'",
4274
- "concurrently": false,
4275
- "method": "btree",
4276
- "with": {}
4277
- },
4278
- "junior_review_items_status_idx": {
4279
- "name": "junior_review_items_status_idx",
4280
- "columns": [
4281
- {
4282
- "expression": "status",
4283
- "isExpression": false,
4284
- "asc": true,
4285
- "nulls": "last"
4286
- },
4287
- {
4288
- "expression": "updated_at",
4289
- "isExpression": false,
4290
- "asc": true,
4291
- "nulls": "last"
4292
- },
4293
- {
4294
- "expression": "id",
4295
- "isExpression": false,
4296
- "asc": true,
4297
- "nulls": "last"
4298
- }
4299
- ],
4300
- "isUnique": false,
4301
- "concurrently": false,
4302
- "method": "btree",
4303
- "with": {}
4304
- },
4305
- "junior_review_items_subject_idx": {
4306
- "name": "junior_review_items_subject_idx",
4307
- "columns": [
4308
- {
4309
- "expression": "subject_id",
4310
- "isExpression": false,
4311
- "asc": true,
4312
- "nulls": "last"
4313
- },
4314
- {
4315
- "expression": "status",
4316
- "isExpression": false,
4317
- "asc": true,
4318
- "nulls": "last"
4319
- }
4320
- ],
4321
- "isUnique": false,
4322
- "concurrently": false,
4323
- "method": "btree",
4324
- "with": {}
4325
- },
4326
- "junior_review_items_automation_idx": {
4327
- "name": "junior_review_items_automation_idx",
4328
- "columns": [
4329
- {
4330
- "expression": "automation_id",
4331
- "isExpression": false,
4332
- "asc": true,
4333
- "nulls": "last"
4334
- },
4335
- {
4336
- "expression": "status",
4337
- "isExpression": false,
4338
- "asc": true,
4339
- "nulls": "last"
4340
- }
4341
- ],
4342
- "isUnique": false,
4343
- "concurrently": false,
4344
- "method": "btree",
4345
- "with": {}
4346
- }
4347
- },
4348
- "foreignKeys": {
4349
- "junior_review_items_added_by_conversation_id_junior_conversations_conversation_id_fk": {
4350
- "name": "junior_review_items_added_by_conversation_id_junior_conversations_conversation_id_fk",
4351
- "tableFrom": "junior_review_items",
4352
- "tableTo": "junior_conversations",
4353
- "columnsFrom": [
4354
- "added_by_conversation_id"
4355
- ],
4356
- "columnsTo": [
4357
- "conversation_id"
4358
- ],
4359
- "onDelete": "cascade",
4360
- "onUpdate": "no action"
4361
- },
4362
- "junior_review_items_automation_id_junior_automations_id_fk": {
4363
- "name": "junior_review_items_automation_id_junior_automations_id_fk",
4364
- "tableFrom": "junior_review_items",
4365
- "tableTo": "junior_automations",
4366
- "columnsFrom": [
4367
- "automation_id"
4368
- ],
4369
- "columnsTo": [
4370
- "id"
4371
- ],
4372
- "onDelete": "set null",
4373
- "onUpdate": "no action"
4374
- },
4375
- "junior_review_items_closed_by_user_id_junior_users_id_fk": {
4376
- "name": "junior_review_items_closed_by_user_id_junior_users_id_fk",
4377
- "tableFrom": "junior_review_items",
4378
- "tableTo": "junior_users",
4379
- "columnsFrom": [
4380
- "closed_by_user_id"
4381
- ],
4382
- "columnsTo": [
4383
- "id"
4384
- ],
4385
- "onDelete": "set null",
4386
- "onUpdate": "no action"
4387
- }
4388
- },
4389
- "compositePrimaryKeys": {},
4390
- "uniqueConstraints": {},
4391
- "policies": {},
4392
- "checkConstraints": {
4393
- "junior_review_items_kind_check": {
4394
- "name": "junior_review_items_kind_check",
4395
- "value": "(\"junior_review_items\".\"kind\" = 'notice' and \"junior_review_items\".\"request\" is null and \"junior_review_items\".\"answer\" is null) or (\"junior_review_items\".\"kind\" = 'action' and (\"junior_review_items\".\"request\" is not null or (\"junior_review_items\".\"dedupe_key\" like 'plugin:%' and \"junior_review_items\".\"answer\" is null)))"
4396
- },
4397
- "junior_review_items_status_check": {
4398
- "name": "junior_review_items_status_check",
4399
- "value": "(\"junior_review_items\".\"status\" = 'open' and \"junior_review_items\".\"closed_at\" is null) or (\"junior_review_items\".\"status\" in ('done', 'dismissed') and \"junior_review_items\".\"closed_at\" is not null)"
4400
- },
4401
- "junior_review_items_tenant_check": {
4402
- "name": "junior_review_items_tenant_check",
4403
- "value": "(\"junior_review_items\".\"provider\" is null) = (\"junior_review_items\".\"provider_tenant_id\" is null)"
4404
- },
4405
- "junior_review_items_visibility_check": {
4406
- "name": "junior_review_items_visibility_check",
4407
- "value": "\"junior_review_items\".\"visibility\" = 'public' or not \"junior_review_items\".\"assigned_to_everyone\""
4408
- }
4409
- },
4410
- "isRLSEnabled": false
4411
- },
4412
- "public.junior_snapshots": {
4413
- "name": "junior_snapshots",
4414
- "schema": "",
4415
- "columns": {
4416
- "id": {
4417
- "name": "id",
4418
- "type": "text",
4419
- "primaryKey": true,
4420
- "notNull": true
4421
- },
4422
- "workspace_id": {
4423
- "name": "workspace_id",
4424
- "type": "text",
4425
- "primaryKey": false,
4426
- "notNull": true
4427
- },
4428
- "profile_hash": {
4429
- "name": "profile_hash",
4430
- "type": "text",
4431
- "primaryKey": false,
4432
- "notNull": true
4433
- },
4434
- "status": {
4435
- "name": "status",
4436
- "type": "text",
4437
- "primaryKey": false,
4438
- "notNull": true
4439
- },
4440
- "snapshot_id": {
4441
- "name": "snapshot_id",
4442
- "type": "text",
4443
- "primaryKey": false,
4444
- "notNull": false
4445
- },
4446
- "build_duration_ms": {
4447
- "name": "build_duration_ms",
4448
- "type": "integer",
4449
- "primaryKey": false,
4450
- "notNull": false
4451
- },
4452
- "size_bytes": {
4453
- "name": "size_bytes",
4454
- "type": "bigint",
4455
- "primaryKey": false,
4456
- "notNull": false
4457
- },
4458
- "generated_at": {
4459
- "name": "generated_at",
4460
- "type": "timestamp with time zone",
4461
- "primaryKey": false,
4462
- "notNull": false
4463
- },
4464
- "build_started_at": {
4465
- "name": "build_started_at",
4466
- "type": "timestamp with time zone",
4467
- "primaryKey": false,
4468
- "notNull": false
4469
- },
4470
- "build_phase": {
4471
- "name": "build_phase",
4472
- "type": "text",
4473
- "primaryKey": false,
4474
- "notNull": false
4475
- },
4476
- "build_sandbox_name": {
4477
- "name": "build_sandbox_name",
4478
- "type": "text",
4479
- "primaryKey": false,
4480
- "notNull": false
4481
- },
4482
- "build_command_id": {
4483
- "name": "build_command_id",
4484
- "type": "text",
4485
- "primaryKey": false,
4486
- "notNull": false
4487
- },
4488
- "build_error": {
4489
- "name": "build_error",
4490
- "type": "text",
4491
- "primaryKey": false,
4492
- "notNull": false
4493
- },
4494
- "created_at": {
4495
- "name": "created_at",
4496
- "type": "timestamp with time zone",
4497
- "primaryKey": false,
4498
- "notNull": true
4499
- },
4500
- "updated_at": {
4501
- "name": "updated_at",
4502
- "type": "timestamp with time zone",
4503
- "primaryKey": false,
4504
- "notNull": true
4505
- }
4506
- },
4507
- "indexes": {
4508
- "junior_snapshots_snapshot_id_uidx": {
4509
- "name": "junior_snapshots_snapshot_id_uidx",
4510
- "columns": [
4511
- {
4512
- "expression": "snapshot_id",
4513
- "isExpression": false,
4514
- "asc": true,
4515
- "nulls": "last"
4516
- }
4517
- ],
4518
- "isUnique": true,
4519
- "concurrently": false,
4520
- "method": "btree",
4521
- "with": {}
4522
- },
4523
- "junior_snapshots_workspace_idx": {
4524
- "name": "junior_snapshots_workspace_idx",
4525
- "columns": [
4526
- {
4527
- "expression": "workspace_id",
4528
- "isExpression": false,
4529
- "asc": true,
4530
- "nulls": "last"
4531
- }
4532
- ],
4533
- "isUnique": false,
4534
- "concurrently": false,
4535
- "method": "btree",
4536
- "with": {}
4537
- },
4538
- "junior_snapshots_workspace_profile_status_idx": {
4539
- "name": "junior_snapshots_workspace_profile_status_idx",
4540
- "columns": [
4541
- {
4542
- "expression": "workspace_id",
4543
- "isExpression": false,
4544
- "asc": true,
4545
- "nulls": "last"
4546
- },
4547
- {
4548
- "expression": "profile_hash",
4549
- "isExpression": false,
4550
- "asc": true,
4551
- "nulls": "last"
4552
- },
4553
- {
4554
- "expression": "status",
4555
- "isExpression": false,
4556
- "asc": true,
4557
- "nulls": "last"
4558
- }
4559
- ],
4560
- "isUnique": false,
4561
- "concurrently": false,
4562
- "method": "btree",
4563
- "with": {}
4564
- },
4565
- "junior_snapshots_active_build_uidx": {
4566
- "name": "junior_snapshots_active_build_uidx",
4567
- "columns": [
4568
- {
4569
- "expression": "workspace_id",
4570
- "isExpression": false,
4571
- "asc": true,
4572
- "nulls": "last"
4573
- },
4574
- {
4575
- "expression": "profile_hash",
4576
- "isExpression": false,
4577
- "asc": true,
4578
- "nulls": "last"
4579
- }
4580
- ],
4581
- "isUnique": true,
4582
- "where": "\"junior_snapshots\".\"status\" = 'building'",
4583
- "concurrently": false,
4584
- "method": "btree",
4585
- "with": {}
4586
- },
4587
- "junior_snapshots_workspace_status_idx": {
4588
- "name": "junior_snapshots_workspace_status_idx",
4589
- "columns": [
4590
- {
4591
- "expression": "workspace_id",
4592
- "isExpression": false,
4593
- "asc": true,
4594
- "nulls": "last"
4595
- },
4596
- {
4597
- "expression": "status",
4598
- "isExpression": false,
4599
- "asc": true,
4600
- "nulls": "last"
4601
- }
4602
- ],
4603
- "isUnique": false,
4604
- "concurrently": false,
4605
- "method": "btree",
4606
- "with": {}
4607
- }
4608
- },
4609
- "foreignKeys": {
4610
- "junior_snapshots_workspace_id_junior_workspaces_id_fk": {
4611
- "name": "junior_snapshots_workspace_id_junior_workspaces_id_fk",
4612
- "tableFrom": "junior_snapshots",
4613
- "tableTo": "junior_workspaces",
4614
- "columnsFrom": [
4615
- "workspace_id"
4616
- ],
4617
- "columnsTo": [
4618
- "id"
4619
- ],
4620
- "onDelete": "cascade",
4621
- "onUpdate": "no action"
4622
- }
4623
- },
4624
- "compositePrimaryKeys": {},
4625
- "uniqueConstraints": {},
4626
- "policies": {},
4627
- "checkConstraints": {
4628
- "junior_snapshots_status_check": {
4629
- "name": "junior_snapshots_status_check",
4630
- "value": "\"junior_snapshots\".\"status\" in ('building', 'failed', 'ready')"
4631
- },
4632
- "junior_snapshots_build_phase_check": {
4633
- "name": "junior_snapshots_build_phase_check",
4634
- "value": "\"junior_snapshots\".\"build_phase\" is null or \"junior_snapshots\".\"build_phase\" in ('created', 'dependencies_installed', 'repositories_prepared')"
4635
- },
4636
- "junior_snapshots_ready_fields_check": {
4637
- "name": "junior_snapshots_ready_fields_check",
4638
- "value": "\"junior_snapshots\".\"status\" <> 'ready' or (\"junior_snapshots\".\"snapshot_id\" is not null and \"junior_snapshots\".\"build_duration_ms\" is not null and \"junior_snapshots\".\"generated_at\" is not null)"
4639
- },
4640
- "junior_snapshots_build_fields_check": {
4641
- "name": "junior_snapshots_build_fields_check",
4642
- "value": "\"junior_snapshots\".\"status\" = 'ready' or (\"junior_snapshots\".\"build_started_at\" is not null and \"junior_snapshots\".\"build_phase\" is not null)"
4643
- },
4644
- "junior_snapshots_build_duration_check": {
4645
- "name": "junior_snapshots_build_duration_check",
4646
- "value": "\"junior_snapshots\".\"build_duration_ms\" is null or \"junior_snapshots\".\"build_duration_ms\" >= 0"
4647
- },
4648
- "junior_snapshots_size_bytes_check": {
4649
- "name": "junior_snapshots_size_bytes_check",
4650
- "value": "\"junior_snapshots\".\"size_bytes\" is null or \"junior_snapshots\".\"size_bytes\" >= 0"
4651
- }
4652
- },
4653
- "isRLSEnabled": false
4654
- },
4655
- "public.junior_stats": {
4656
- "name": "junior_stats",
4657
- "schema": "",
4658
- "columns": {
4659
- "date": {
4660
- "name": "date",
4661
- "type": "date",
4662
- "primaryKey": false,
4663
- "notNull": true
4664
- },
4665
- "namespace": {
4666
- "name": "namespace",
4667
- "type": "text",
4668
- "primaryKey": false,
4669
- "notNull": true
4670
- },
4671
- "metric": {
4672
- "name": "metric",
4673
- "type": "text",
4674
- "primaryKey": false,
4675
- "notNull": true
4676
- },
4677
- "name": {
4678
- "name": "name",
4679
- "type": "text",
4680
- "primaryKey": false,
4681
- "notNull": true
4682
- },
4683
- "count": {
4684
- "name": "count",
4685
- "type": "integer",
4686
- "primaryKey": false,
4687
- "notNull": true,
4688
- "default": 0
4689
- }
4690
- },
4691
- "indexes": {},
4692
- "foreignKeys": {},
4693
- "compositePrimaryKeys": {
4694
- "junior_stats_date_namespace_metric_name_pk": {
4695
- "name": "junior_stats_date_namespace_metric_name_pk",
4696
- "columns": [
4697
- "date",
4698
- "namespace",
4699
- "metric",
4700
- "name"
4701
- ]
4702
- }
4703
- },
4704
- "uniqueConstraints": {},
4705
- "policies": {},
4706
- "checkConstraints": {},
4707
- "isRLSEnabled": false
4708
- },
4709
- "public.junior_users": {
4710
- "name": "junior_users",
4711
- "schema": "",
4712
- "columns": {
4713
- "id": {
4714
- "name": "id",
4715
- "type": "text",
4716
- "primaryKey": true,
4717
- "notNull": true
4718
- },
4719
- "primary_email": {
4720
- "name": "primary_email",
4721
- "type": "text",
4722
- "primaryKey": false,
4723
- "notNull": true
4724
- },
4725
- "primary_email_normalized": {
4726
- "name": "primary_email_normalized",
4727
- "type": "text",
4728
- "primaryKey": false,
4729
- "notNull": true
4730
- },
4731
- "display_name": {
4732
- "name": "display_name",
4733
- "type": "text",
4734
- "primaryKey": false,
4735
- "notNull": false
4736
- },
4737
- "timezone": {
4738
- "name": "timezone",
4739
- "type": "text",
4740
- "primaryKey": false,
4741
- "notNull": false
4742
- },
4743
- "customization": {
4744
- "name": "customization",
4745
- "type": "text",
4746
- "primaryKey": false,
4747
- "notNull": false
4748
- },
4749
- "notification_schedule": {
4750
- "name": "notification_schedule",
4751
- "type": "jsonb",
4752
- "primaryKey": false,
4753
- "notNull": false
4754
- },
4755
- "is_admin": {
4756
- "name": "is_admin",
4757
- "type": "boolean",
4758
- "primaryKey": false,
4759
- "notNull": true,
4760
- "default": false
4761
- },
4762
- "auto_archive_default": {
4763
- "name": "auto_archive_default",
4764
- "type": "boolean",
4765
- "primaryKey": false,
4766
- "notNull": true,
4767
- "default": false
4768
- },
4769
- "auto_archive_grace_hours": {
4770
- "name": "auto_archive_grace_hours",
4771
- "type": "integer",
4772
- "primaryKey": false,
4773
- "notNull": true,
4774
- "default": 24
4775
- },
4776
- "preferences": {
4777
- "name": "preferences",
4778
- "type": "jsonb",
4779
- "primaryKey": false,
4780
- "notNull": true,
4781
- "default": "'{}'::jsonb"
4782
- },
4783
- "created_at": {
4784
- "name": "created_at",
4785
- "type": "timestamp with time zone",
4786
- "primaryKey": false,
4787
- "notNull": true
4788
- },
4789
- "updated_at": {
4790
- "name": "updated_at",
4791
- "type": "timestamp with time zone",
4792
- "primaryKey": false,
4793
- "notNull": true
4794
- }
4795
- },
4796
- "indexes": {
4797
- "junior_users_primary_email_normalized_uidx": {
4798
- "name": "junior_users_primary_email_normalized_uidx",
4799
- "columns": [
4800
- {
4801
- "expression": "primary_email_normalized",
4802
- "isExpression": false,
4803
- "asc": true,
4804
- "nulls": "last"
4805
- }
4806
- ],
4807
- "isUnique": true,
4808
- "concurrently": false,
4809
- "method": "btree",
4810
- "with": {}
4811
- }
4812
- },
4813
- "foreignKeys": {},
4814
- "compositePrimaryKeys": {},
4815
- "uniqueConstraints": {},
4816
- "policies": {},
4817
- "checkConstraints": {},
4818
- "isRLSEnabled": false
4819
- },
4820
- "public.junior_workspace_repos": {
4821
- "name": "junior_workspace_repos",
4822
- "schema": "",
4823
- "columns": {
4824
- "workspace_id": {
4825
- "name": "workspace_id",
4826
- "type": "text",
4827
- "primaryKey": false,
4828
- "notNull": true
4829
- },
4830
- "provider": {
4831
- "name": "provider",
4832
- "type": "text",
4833
- "primaryKey": false,
4834
- "notNull": true
4835
- },
4836
- "repo": {
4837
- "name": "repo",
4838
- "type": "text",
4839
- "primaryKey": false,
4840
- "notNull": true
4841
- }
4842
- },
4843
- "indexes": {},
4844
- "foreignKeys": {
4845
- "junior_workspace_repos_workspace_id_junior_workspaces_id_fk": {
4846
- "name": "junior_workspace_repos_workspace_id_junior_workspaces_id_fk",
4847
- "tableFrom": "junior_workspace_repos",
4848
- "tableTo": "junior_workspaces",
4849
- "columnsFrom": [
4850
- "workspace_id"
4851
- ],
4852
- "columnsTo": [
4853
- "id"
4854
- ],
4855
- "onDelete": "cascade",
4856
- "onUpdate": "no action"
4857
- }
4858
- },
4859
- "compositePrimaryKeys": {
4860
- "junior_workspace_repos_workspace_id_provider_repo_pk": {
4861
- "name": "junior_workspace_repos_workspace_id_provider_repo_pk",
4862
- "columns": [
4863
- "workspace_id",
4864
- "provider",
4865
- "repo"
4866
- ]
4867
- }
4868
- },
4869
- "uniqueConstraints": {},
4870
- "policies": {},
4871
- "checkConstraints": {},
4872
- "isRLSEnabled": false
4873
- },
4874
- "public.junior_workspaces": {
4875
- "name": "junior_workspaces",
4876
- "schema": "",
4877
- "columns": {
4878
- "id": {
4879
- "name": "id",
4880
- "type": "text",
4881
- "primaryKey": true,
4882
- "notNull": true
4883
- },
4884
- "name": {
4885
- "name": "name",
4886
- "type": "text",
4887
- "primaryKey": false,
4888
- "notNull": true
4889
- },
4890
- "setup_script": {
4891
- "name": "setup_script",
4892
- "type": "text",
4893
- "primaryKey": false,
4894
- "notNull": true,
4895
- "default": "''"
4896
- },
4897
- "vcpus": {
4898
- "name": "vcpus",
4899
- "type": "integer",
4900
- "primaryKey": false,
4901
- "notNull": false
4902
- },
4903
- "created_at": {
4904
- "name": "created_at",
4905
- "type": "timestamp with time zone",
4906
- "primaryKey": false,
4907
- "notNull": true
4908
- },
4909
- "updated_at": {
4910
- "name": "updated_at",
4911
- "type": "timestamp with time zone",
4912
- "primaryKey": false,
4913
- "notNull": true
4914
- }
4915
- },
4916
- "indexes": {
4917
- "junior_workspaces_name_idx": {
4918
- "name": "junior_workspaces_name_idx",
4919
- "columns": [
4920
- {
4921
- "expression": "name",
4922
- "isExpression": false,
4923
- "asc": true,
4924
- "nulls": "last"
4925
- }
4926
- ],
4927
- "isUnique": true,
4928
- "concurrently": false,
4929
- "method": "btree",
4930
- "with": {}
4931
- }
4932
- },
4933
- "foreignKeys": {},
4934
- "compositePrimaryKeys": {},
4935
- "uniqueConstraints": {},
4936
- "policies": {},
4937
- "checkConstraints": {},
4938
- "isRLSEnabled": false
4939
- }
4940
- },
4941
- "enums": {},
4942
- "schemas": {},
4943
- "sequences": {},
4944
- "roles": {},
4945
- "policies": {},
4946
- "views": {},
4947
- "_meta": {
4948
- "columns": {},
4949
- "schemas": {},
4950
- "tables": {}
4951
- }
4952
- }