0008_snapshot.json 58 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329
  1. {
  2. "version": "6",
  3. "dialect": "sqlite",
  4. "id": "f71bd72e-f1e8-45f0-a3a7-66eb3cd051ee",
  5. "prevId": "4acfdb59-bfc6-49ae-bc98-51e3b542511f",
  6. "tables": {
  7. "admin_sessions": {
  8. "name": "admin_sessions",
  9. "columns": {
  10. "id": {
  11. "name": "id",
  12. "type": "text",
  13. "primaryKey": true,
  14. "notNull": true,
  15. "autoincrement": false
  16. },
  17. "created_at": {
  18. "name": "created_at",
  19. "type": "text",
  20. "primaryKey": false,
  21. "notNull": true,
  22. "autoincrement": false,
  23. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  24. },
  25. "expires_at": {
  26. "name": "expires_at",
  27. "type": "text",
  28. "primaryKey": false,
  29. "notNull": true,
  30. "autoincrement": false
  31. }
  32. },
  33. "indexes": {},
  34. "foreignKeys": {},
  35. "compositePrimaryKeys": {},
  36. "uniqueConstraints": {},
  37. "checkConstraints": {}
  38. },
  39. "api_keys": {
  40. "name": "api_keys",
  41. "columns": {
  42. "id": {
  43. "name": "id",
  44. "type": "text",
  45. "primaryKey": true,
  46. "notNull": true,
  47. "autoincrement": false
  48. },
  49. "name": {
  50. "name": "name",
  51. "type": "text",
  52. "primaryKey": false,
  53. "notNull": true,
  54. "autoincrement": false
  55. },
  56. "key_hash": {
  57. "name": "key_hash",
  58. "type": "text",
  59. "primaryKey": false,
  60. "notNull": true,
  61. "autoincrement": false
  62. },
  63. "key_prefix": {
  64. "name": "key_prefix",
  65. "type": "text",
  66. "primaryKey": false,
  67. "notNull": true,
  68. "autoincrement": false
  69. },
  70. "enabled": {
  71. "name": "enabled",
  72. "type": "integer",
  73. "primaryKey": false,
  74. "notNull": true,
  75. "autoincrement": false,
  76. "default": true
  77. },
  78. "allowed_profile_ids": {
  79. "name": "allowed_profile_ids",
  80. "type": "text",
  81. "primaryKey": false,
  82. "notNull": true,
  83. "autoincrement": false,
  84. "default": "'[]'"
  85. },
  86. "default_profile_id": {
  87. "name": "default_profile_id",
  88. "type": "text",
  89. "primaryKey": false,
  90. "notNull": false,
  91. "autoincrement": false
  92. },
  93. "created_at": {
  94. "name": "created_at",
  95. "type": "text",
  96. "primaryKey": false,
  97. "notNull": true,
  98. "autoincrement": false,
  99. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  100. },
  101. "last_used_at": {
  102. "name": "last_used_at",
  103. "type": "text",
  104. "primaryKey": false,
  105. "notNull": false,
  106. "autoincrement": false
  107. }
  108. },
  109. "indexes": {
  110. "api_keys_key_hash_unique": {
  111. "name": "api_keys_key_hash_unique",
  112. "columns": [
  113. "key_hash"
  114. ],
  115. "isUnique": true
  116. }
  117. },
  118. "foreignKeys": {},
  119. "compositePrimaryKeys": {},
  120. "uniqueConstraints": {},
  121. "checkConstraints": {}
  122. },
  123. "audit_logs": {
  124. "name": "audit_logs",
  125. "columns": {
  126. "id": {
  127. "name": "id",
  128. "type": "integer",
  129. "primaryKey": true,
  130. "notNull": true,
  131. "autoincrement": true
  132. },
  133. "ts": {
  134. "name": "ts",
  135. "type": "text",
  136. "primaryKey": false,
  137. "notNull": true,
  138. "autoincrement": false,
  139. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  140. },
  141. "actor": {
  142. "name": "actor",
  143. "type": "text",
  144. "primaryKey": false,
  145. "notNull": true,
  146. "autoincrement": false
  147. },
  148. "session_id": {
  149. "name": "session_id",
  150. "type": "text",
  151. "primaryKey": false,
  152. "notNull": false,
  153. "autoincrement": false
  154. },
  155. "kind": {
  156. "name": "kind",
  157. "type": "text",
  158. "primaryKey": false,
  159. "notNull": true,
  160. "autoincrement": false
  161. },
  162. "summary": {
  163. "name": "summary",
  164. "type": "text",
  165. "primaryKey": false,
  166. "notNull": true,
  167. "autoincrement": false
  168. },
  169. "detail": {
  170. "name": "detail",
  171. "type": "text",
  172. "primaryKey": false,
  173. "notNull": false,
  174. "autoincrement": false
  175. }
  176. },
  177. "indexes": {
  178. "audit_ts_idx": {
  179. "name": "audit_ts_idx",
  180. "columns": [
  181. "ts"
  182. ],
  183. "isUnique": false
  184. }
  185. },
  186. "foreignKeys": {},
  187. "compositePrimaryKeys": {},
  188. "uniqueConstraints": {},
  189. "checkConstraints": {}
  190. },
  191. "bot_api_keys": {
  192. "name": "bot_api_keys",
  193. "columns": {
  194. "id": {
  195. "name": "id",
  196. "type": "text",
  197. "primaryKey": true,
  198. "notNull": true,
  199. "autoincrement": false
  200. },
  201. "name": {
  202. "name": "name",
  203. "type": "text",
  204. "primaryKey": false,
  205. "notNull": true,
  206. "autoincrement": false
  207. },
  208. "key_hash": {
  209. "name": "key_hash",
  210. "type": "text",
  211. "primaryKey": false,
  212. "notNull": true,
  213. "autoincrement": false
  214. },
  215. "key_prefix": {
  216. "name": "key_prefix",
  217. "type": "text",
  218. "primaryKey": false,
  219. "notNull": true,
  220. "autoincrement": false
  221. },
  222. "enabled": {
  223. "name": "enabled",
  224. "type": "integer",
  225. "primaryKey": false,
  226. "notNull": true,
  227. "autoincrement": false,
  228. "default": true
  229. },
  230. "allowed_bot_ids": {
  231. "name": "allowed_bot_ids",
  232. "type": "text",
  233. "primaryKey": false,
  234. "notNull": true,
  235. "autoincrement": false,
  236. "default": "'[]'"
  237. },
  238. "created_at": {
  239. "name": "created_at",
  240. "type": "text",
  241. "primaryKey": false,
  242. "notNull": true,
  243. "autoincrement": false,
  244. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  245. },
  246. "last_used_at": {
  247. "name": "last_used_at",
  248. "type": "text",
  249. "primaryKey": false,
  250. "notNull": false,
  251. "autoincrement": false
  252. }
  253. },
  254. "indexes": {
  255. "bot_api_keys_key_hash_unique": {
  256. "name": "bot_api_keys_key_hash_unique",
  257. "columns": [
  258. "key_hash"
  259. ],
  260. "isUnique": true
  261. }
  262. },
  263. "foreignKeys": {},
  264. "compositePrimaryKeys": {},
  265. "uniqueConstraints": {},
  266. "checkConstraints": {}
  267. },
  268. "bots": {
  269. "name": "bots",
  270. "columns": {
  271. "id": {
  272. "name": "id",
  273. "type": "text",
  274. "primaryKey": true,
  275. "notNull": true,
  276. "autoincrement": false
  277. },
  278. "name": {
  279. "name": "name",
  280. "type": "text",
  281. "primaryKey": false,
  282. "notNull": true,
  283. "autoincrement": false
  284. },
  285. "avatar": {
  286. "name": "avatar",
  287. "type": "text",
  288. "primaryKey": false,
  289. "notNull": true,
  290. "autoincrement": false,
  291. "default": "'🤖'"
  292. },
  293. "kind": {
  294. "name": "kind",
  295. "type": "text",
  296. "primaryKey": false,
  297. "notNull": true,
  298. "autoincrement": false
  299. },
  300. "description": {
  301. "name": "description",
  302. "type": "text",
  303. "primaryKey": false,
  304. "notNull": true,
  305. "autoincrement": false,
  306. "default": "''"
  307. },
  308. "profile_id": {
  309. "name": "profile_id",
  310. "type": "text",
  311. "primaryKey": false,
  312. "notNull": true,
  313. "autoincrement": false
  314. },
  315. "enabled": {
  316. "name": "enabled",
  317. "type": "integer",
  318. "primaryKey": false,
  319. "notNull": true,
  320. "autoincrement": false,
  321. "default": true
  322. },
  323. "created_at": {
  324. "name": "created_at",
  325. "type": "text",
  326. "primaryKey": false,
  327. "notNull": true,
  328. "autoincrement": false,
  329. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  330. },
  331. "updated_at": {
  332. "name": "updated_at",
  333. "type": "text",
  334. "primaryKey": false,
  335. "notNull": true,
  336. "autoincrement": false,
  337. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  338. }
  339. },
  340. "indexes": {
  341. "bots_name_unique": {
  342. "name": "bots_name_unique",
  343. "columns": [
  344. "name"
  345. ],
  346. "isUnique": true
  347. }
  348. },
  349. "foreignKeys": {},
  350. "compositePrimaryKeys": {},
  351. "uniqueConstraints": {},
  352. "checkConstraints": {}
  353. },
  354. "custom_skill_versions": {
  355. "name": "custom_skill_versions",
  356. "columns": {
  357. "skill_id": {
  358. "name": "skill_id",
  359. "type": "text",
  360. "primaryKey": false,
  361. "notNull": true,
  362. "autoincrement": false
  363. },
  364. "version": {
  365. "name": "version",
  366. "type": "integer",
  367. "primaryKey": false,
  368. "notNull": true,
  369. "autoincrement": false
  370. },
  371. "reason": {
  372. "name": "reason",
  373. "type": "text",
  374. "primaryKey": false,
  375. "notNull": true,
  376. "autoincrement": false
  377. },
  378. "files": {
  379. "name": "files",
  380. "type": "text",
  381. "primaryKey": false,
  382. "notNull": true,
  383. "autoincrement": false
  384. },
  385. "changed": {
  386. "name": "changed",
  387. "type": "text",
  388. "primaryKey": false,
  389. "notNull": true,
  390. "autoincrement": false
  391. },
  392. "created_at": {
  393. "name": "created_at",
  394. "type": "text",
  395. "primaryKey": false,
  396. "notNull": true,
  397. "autoincrement": false,
  398. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  399. }
  400. },
  401. "indexes": {},
  402. "foreignKeys": {},
  403. "compositePrimaryKeys": {
  404. "custom_skill_versions_skill_id_version_pk": {
  405. "columns": [
  406. "skill_id",
  407. "version"
  408. ],
  409. "name": "custom_skill_versions_skill_id_version_pk"
  410. }
  411. },
  412. "uniqueConstraints": {},
  413. "checkConstraints": {}
  414. },
  415. "custom_skills": {
  416. "name": "custom_skills",
  417. "columns": {
  418. "id": {
  419. "name": "id",
  420. "type": "text",
  421. "primaryKey": true,
  422. "notNull": true,
  423. "autoincrement": false
  424. },
  425. "name": {
  426. "name": "name",
  427. "type": "text",
  428. "primaryKey": false,
  429. "notNull": true,
  430. "autoincrement": false
  431. },
  432. "description": {
  433. "name": "description",
  434. "type": "text",
  435. "primaryKey": false,
  436. "notNull": true,
  437. "autoincrement": false,
  438. "default": "''"
  439. },
  440. "origin": {
  441. "name": "origin",
  442. "type": "text",
  443. "primaryKey": false,
  444. "notNull": true,
  445. "autoincrement": false
  446. },
  447. "source_id": {
  448. "name": "source_id",
  449. "type": "text",
  450. "primaryKey": false,
  451. "notNull": false,
  452. "autoincrement": false
  453. },
  454. "enabled": {
  455. "name": "enabled",
  456. "type": "integer",
  457. "primaryKey": false,
  458. "notNull": true,
  459. "autoincrement": false,
  460. "default": true
  461. },
  462. "include_in_all": {
  463. "name": "include_in_all",
  464. "type": "integer",
  465. "primaryKey": false,
  466. "notNull": true,
  467. "autoincrement": false,
  468. "default": false
  469. },
  470. "published_version": {
  471. "name": "published_version",
  472. "type": "integer",
  473. "primaryKey": false,
  474. "notNull": false,
  475. "autoincrement": false
  476. },
  477. "latest_version": {
  478. "name": "latest_version",
  479. "type": "integer",
  480. "primaryKey": false,
  481. "notNull": true,
  482. "autoincrement": false,
  483. "default": 0
  484. },
  485. "working_files": {
  486. "name": "working_files",
  487. "type": "text",
  488. "primaryKey": false,
  489. "notNull": true,
  490. "autoincrement": false,
  491. "default": "'{}'"
  492. },
  493. "created_at": {
  494. "name": "created_at",
  495. "type": "text",
  496. "primaryKey": false,
  497. "notNull": true,
  498. "autoincrement": false,
  499. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  500. },
  501. "updated_at": {
  502. "name": "updated_at",
  503. "type": "text",
  504. "primaryKey": false,
  505. "notNull": true,
  506. "autoincrement": false,
  507. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  508. }
  509. },
  510. "indexes": {
  511. "custom_skills_name_unique": {
  512. "name": "custom_skills_name_unique",
  513. "columns": [
  514. "name"
  515. ],
  516. "isUnique": true
  517. }
  518. },
  519. "foreignKeys": {},
  520. "compositePrimaryKeys": {},
  521. "uniqueConstraints": {},
  522. "checkConstraints": {}
  523. },
  524. "events": {
  525. "name": "events",
  526. "columns": {
  527. "session_id": {
  528. "name": "session_id",
  529. "type": "text",
  530. "primaryKey": false,
  531. "notNull": true,
  532. "autoincrement": false
  533. },
  534. "seq": {
  535. "name": "seq",
  536. "type": "integer",
  537. "primaryKey": false,
  538. "notNull": true,
  539. "autoincrement": false
  540. },
  541. "run_id": {
  542. "name": "run_id",
  543. "type": "text",
  544. "primaryKey": false,
  545. "notNull": false,
  546. "autoincrement": false
  547. },
  548. "type": {
  549. "name": "type",
  550. "type": "text",
  551. "primaryKey": false,
  552. "notNull": true,
  553. "autoincrement": false
  554. },
  555. "payload": {
  556. "name": "payload",
  557. "type": "text",
  558. "primaryKey": false,
  559. "notNull": true,
  560. "autoincrement": false
  561. },
  562. "ts": {
  563. "name": "ts",
  564. "type": "text",
  565. "primaryKey": false,
  566. "notNull": true,
  567. "autoincrement": false
  568. }
  569. },
  570. "indexes": {},
  571. "foreignKeys": {},
  572. "compositePrimaryKeys": {
  573. "events_session_id_seq_pk": {
  574. "columns": [
  575. "session_id",
  576. "seq"
  577. ],
  578. "name": "events_session_id_seq_pk"
  579. }
  580. },
  581. "uniqueConstraints": {},
  582. "checkConstraints": {}
  583. },
  584. "files": {
  585. "name": "files",
  586. "columns": {
  587. "id": {
  588. "name": "id",
  589. "type": "text",
  590. "primaryKey": true,
  591. "notNull": true,
  592. "autoincrement": false
  593. },
  594. "session_id": {
  595. "name": "session_id",
  596. "type": "text",
  597. "primaryKey": false,
  598. "notNull": true,
  599. "autoincrement": false
  600. },
  601. "rel_path": {
  602. "name": "rel_path",
  603. "type": "text",
  604. "primaryKey": false,
  605. "notNull": true,
  606. "autoincrement": false
  607. },
  608. "origin": {
  609. "name": "origin",
  610. "type": "text",
  611. "primaryKey": false,
  612. "notNull": true,
  613. "autoincrement": false
  614. },
  615. "mime": {
  616. "name": "mime",
  617. "type": "text",
  618. "primaryKey": false,
  619. "notNull": true,
  620. "autoincrement": false
  621. },
  622. "size": {
  623. "name": "size",
  624. "type": "integer",
  625. "primaryKey": false,
  626. "notNull": true,
  627. "autoincrement": false
  628. },
  629. "mtime_ms": {
  630. "name": "mtime_ms",
  631. "type": "real",
  632. "primaryKey": false,
  633. "notNull": true,
  634. "autoincrement": false
  635. },
  636. "created_at": {
  637. "name": "created_at",
  638. "type": "text",
  639. "primaryKey": false,
  640. "notNull": true,
  641. "autoincrement": false,
  642. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  643. },
  644. "updated_at": {
  645. "name": "updated_at",
  646. "type": "text",
  647. "primaryKey": false,
  648. "notNull": true,
  649. "autoincrement": false,
  650. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  651. }
  652. },
  653. "indexes": {
  654. "files_session_path_idx": {
  655. "name": "files_session_path_idx",
  656. "columns": [
  657. "session_id",
  658. "rel_path"
  659. ],
  660. "isUnique": false
  661. }
  662. },
  663. "foreignKeys": {},
  664. "compositePrimaryKeys": {},
  665. "uniqueConstraints": {},
  666. "checkConstraints": {}
  667. },
  668. "interactions": {
  669. "name": "interactions",
  670. "columns": {
  671. "id": {
  672. "name": "id",
  673. "type": "text",
  674. "primaryKey": true,
  675. "notNull": true,
  676. "autoincrement": false
  677. },
  678. "session_id": {
  679. "name": "session_id",
  680. "type": "text",
  681. "primaryKey": false,
  682. "notNull": true,
  683. "autoincrement": false
  684. },
  685. "run_id": {
  686. "name": "run_id",
  687. "type": "text",
  688. "primaryKey": false,
  689. "notNull": true,
  690. "autoincrement": false
  691. },
  692. "kind": {
  693. "name": "kind",
  694. "type": "text",
  695. "primaryKey": false,
  696. "notNull": true,
  697. "autoincrement": false
  698. },
  699. "request": {
  700. "name": "request",
  701. "type": "text",
  702. "primaryKey": false,
  703. "notNull": true,
  704. "autoincrement": false
  705. },
  706. "response": {
  707. "name": "response",
  708. "type": "text",
  709. "primaryKey": false,
  710. "notNull": false,
  711. "autoincrement": false
  712. },
  713. "status": {
  714. "name": "status",
  715. "type": "text",
  716. "primaryKey": false,
  717. "notNull": true,
  718. "autoincrement": false
  719. },
  720. "created_at": {
  721. "name": "created_at",
  722. "type": "text",
  723. "primaryKey": false,
  724. "notNull": true,
  725. "autoincrement": false,
  726. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  727. },
  728. "resolved_at": {
  729. "name": "resolved_at",
  730. "type": "text",
  731. "primaryKey": false,
  732. "notNull": false,
  733. "autoincrement": false
  734. },
  735. "expires_at": {
  736. "name": "expires_at",
  737. "type": "text",
  738. "primaryKey": false,
  739. "notNull": true,
  740. "autoincrement": false
  741. }
  742. },
  743. "indexes": {
  744. "interactions_session_idx": {
  745. "name": "interactions_session_idx",
  746. "columns": [
  747. "session_id",
  748. "status"
  749. ],
  750. "isUnique": false
  751. }
  752. },
  753. "foreignKeys": {},
  754. "compositePrimaryKeys": {},
  755. "uniqueConstraints": {},
  756. "checkConstraints": {}
  757. },
  758. "jobs": {
  759. "name": "jobs",
  760. "columns": {
  761. "id": {
  762. "name": "id",
  763. "type": "text",
  764. "primaryKey": true,
  765. "notNull": true,
  766. "autoincrement": false
  767. },
  768. "team_id": {
  769. "name": "team_id",
  770. "type": "text",
  771. "primaryKey": false,
  772. "notNull": true,
  773. "autoincrement": false
  774. },
  775. "no": {
  776. "name": "no",
  777. "type": "integer",
  778. "primaryKey": false,
  779. "notNull": true,
  780. "autoincrement": false
  781. },
  782. "title": {
  783. "name": "title",
  784. "type": "text",
  785. "primaryKey": false,
  786. "notNull": true,
  787. "autoincrement": false
  788. },
  789. "plan": {
  790. "name": "plan",
  791. "type": "text",
  792. "primaryKey": false,
  793. "notNull": true,
  794. "autoincrement": false,
  795. "default": "''"
  796. },
  797. "status": {
  798. "name": "status",
  799. "type": "text",
  800. "primaryKey": false,
  801. "notNull": true,
  802. "autoincrement": false,
  803. "default": "'running'"
  804. },
  805. "summary": {
  806. "name": "summary",
  807. "type": "text",
  808. "primaryKey": false,
  809. "notNull": false,
  810. "autoincrement": false
  811. },
  812. "files": {
  813. "name": "files",
  814. "type": "text",
  815. "primaryKey": false,
  816. "notNull": true,
  817. "autoincrement": false,
  818. "default": "'[]'"
  819. },
  820. "blocked_by": {
  821. "name": "blocked_by",
  822. "type": "text",
  823. "primaryKey": false,
  824. "notNull": false,
  825. "autoincrement": false
  826. },
  827. "limits": {
  828. "name": "limits",
  829. "type": "text",
  830. "primaryKey": false,
  831. "notNull": true,
  832. "autoincrement": false
  833. },
  834. "lead_runs": {
  835. "name": "lead_runs",
  836. "type": "integer",
  837. "primaryKey": false,
  838. "notNull": true,
  839. "autoincrement": false,
  840. "default": 0
  841. },
  842. "run_ids": {
  843. "name": "run_ids",
  844. "type": "text",
  845. "primaryKey": false,
  846. "notNull": true,
  847. "autoincrement": false,
  848. "default": "'[]'"
  849. },
  850. "created_at": {
  851. "name": "created_at",
  852. "type": "text",
  853. "primaryKey": false,
  854. "notNull": true,
  855. "autoincrement": false,
  856. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  857. },
  858. "ended_at": {
  859. "name": "ended_at",
  860. "type": "text",
  861. "primaryKey": false,
  862. "notNull": false,
  863. "autoincrement": false
  864. }
  865. },
  866. "indexes": {
  867. "jobs_team_idx": {
  868. "name": "jobs_team_idx",
  869. "columns": [
  870. "team_id",
  871. "no"
  872. ],
  873. "isUnique": false
  874. }
  875. },
  876. "foreignKeys": {},
  877. "compositePrimaryKeys": {},
  878. "uniqueConstraints": {},
  879. "checkConstraints": {}
  880. },
  881. "knowledge_roots": {
  882. "name": "knowledge_roots",
  883. "columns": {
  884. "id": {
  885. "name": "id",
  886. "type": "text",
  887. "primaryKey": true,
  888. "notNull": true,
  889. "autoincrement": false
  890. },
  891. "name": {
  892. "name": "name",
  893. "type": "text",
  894. "primaryKey": false,
  895. "notNull": true,
  896. "autoincrement": false
  897. },
  898. "path": {
  899. "name": "path",
  900. "type": "text",
  901. "primaryKey": false,
  902. "notNull": true,
  903. "autoincrement": false
  904. },
  905. "description": {
  906. "name": "description",
  907. "type": "text",
  908. "primaryKey": false,
  909. "notNull": true,
  910. "autoincrement": false,
  911. "default": "''"
  912. },
  913. "access": {
  914. "name": "access",
  915. "type": "text",
  916. "primaryKey": false,
  917. "notNull": true,
  918. "autoincrement": false,
  919. "default": "'read'"
  920. },
  921. "enabled": {
  922. "name": "enabled",
  923. "type": "integer",
  924. "primaryKey": false,
  925. "notNull": true,
  926. "autoincrement": false,
  927. "default": true
  928. },
  929. "created_at": {
  930. "name": "created_at",
  931. "type": "text",
  932. "primaryKey": false,
  933. "notNull": true,
  934. "autoincrement": false,
  935. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  936. },
  937. "updated_at": {
  938. "name": "updated_at",
  939. "type": "text",
  940. "primaryKey": false,
  941. "notNull": true,
  942. "autoincrement": false,
  943. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  944. }
  945. },
  946. "indexes": {},
  947. "foreignKeys": {},
  948. "compositePrimaryKeys": {},
  949. "uniqueConstraints": {},
  950. "checkConstraints": {}
  951. },
  952. "mcp_servers": {
  953. "name": "mcp_servers",
  954. "columns": {
  955. "id": {
  956. "name": "id",
  957. "type": "text",
  958. "primaryKey": true,
  959. "notNull": true,
  960. "autoincrement": false
  961. },
  962. "name": {
  963. "name": "name",
  964. "type": "text",
  965. "primaryKey": false,
  966. "notNull": true,
  967. "autoincrement": false
  968. },
  969. "title": {
  970. "name": "title",
  971. "type": "text",
  972. "primaryKey": false,
  973. "notNull": true,
  974. "autoincrement": false
  975. },
  976. "description": {
  977. "name": "description",
  978. "type": "text",
  979. "primaryKey": false,
  980. "notNull": true,
  981. "autoincrement": false,
  982. "default": "''"
  983. },
  984. "transport": {
  985. "name": "transport",
  986. "type": "text",
  987. "primaryKey": false,
  988. "notNull": true,
  989. "autoincrement": false
  990. },
  991. "enabled": {
  992. "name": "enabled",
  993. "type": "integer",
  994. "primaryKey": false,
  995. "notNull": true,
  996. "autoincrement": false,
  997. "default": true
  998. },
  999. "url": {
  1000. "name": "url",
  1001. "type": "text",
  1002. "primaryKey": false,
  1003. "notNull": true,
  1004. "autoincrement": false,
  1005. "default": "''"
  1006. },
  1007. "headers": {
  1008. "name": "headers",
  1009. "type": "text",
  1010. "primaryKey": false,
  1011. "notNull": true,
  1012. "autoincrement": false,
  1013. "default": "'{}'"
  1014. },
  1015. "command": {
  1016. "name": "command",
  1017. "type": "text",
  1018. "primaryKey": false,
  1019. "notNull": true,
  1020. "autoincrement": false,
  1021. "default": "''"
  1022. },
  1023. "args": {
  1024. "name": "args",
  1025. "type": "text",
  1026. "primaryKey": false,
  1027. "notNull": true,
  1028. "autoincrement": false,
  1029. "default": "'[]'"
  1030. },
  1031. "env": {
  1032. "name": "env",
  1033. "type": "text",
  1034. "primaryKey": false,
  1035. "notNull": true,
  1036. "autoincrement": false,
  1037. "default": "'{}'"
  1038. },
  1039. "allow_network": {
  1040. "name": "allow_network",
  1041. "type": "integer",
  1042. "primaryKey": false,
  1043. "notNull": true,
  1044. "autoincrement": false,
  1045. "default": false
  1046. },
  1047. "read_paths": {
  1048. "name": "read_paths",
  1049. "type": "text",
  1050. "primaryKey": false,
  1051. "notNull": true,
  1052. "autoincrement": false,
  1053. "default": "'[]'"
  1054. },
  1055. "write_paths": {
  1056. "name": "write_paths",
  1057. "type": "text",
  1058. "primaryKey": false,
  1059. "notNull": true,
  1060. "autoincrement": false,
  1061. "default": "'[]'"
  1062. },
  1063. "tool_policies": {
  1064. "name": "tool_policies",
  1065. "type": "text",
  1066. "primaryKey": false,
  1067. "notNull": true,
  1068. "autoincrement": false,
  1069. "default": "'{}'"
  1070. },
  1071. "tools_cache": {
  1072. "name": "tools_cache",
  1073. "type": "text",
  1074. "primaryKey": false,
  1075. "notNull": true,
  1076. "autoincrement": false,
  1077. "default": "'[]'"
  1078. },
  1079. "tools_updated_at": {
  1080. "name": "tools_updated_at",
  1081. "type": "text",
  1082. "primaryKey": false,
  1083. "notNull": false,
  1084. "autoincrement": false
  1085. },
  1086. "created_at": {
  1087. "name": "created_at",
  1088. "type": "text",
  1089. "primaryKey": false,
  1090. "notNull": true,
  1091. "autoincrement": false,
  1092. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1093. },
  1094. "updated_at": {
  1095. "name": "updated_at",
  1096. "type": "text",
  1097. "primaryKey": false,
  1098. "notNull": true,
  1099. "autoincrement": false,
  1100. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1101. }
  1102. },
  1103. "indexes": {
  1104. "mcp_servers_name_unique": {
  1105. "name": "mcp_servers_name_unique",
  1106. "columns": [
  1107. "name"
  1108. ],
  1109. "isUnique": true
  1110. }
  1111. },
  1112. "foreignKeys": {},
  1113. "compositePrimaryKeys": {},
  1114. "uniqueConstraints": {},
  1115. "checkConstraints": {}
  1116. },
  1117. "profile_versions": {
  1118. "name": "profile_versions",
  1119. "columns": {
  1120. "profile_id": {
  1121. "name": "profile_id",
  1122. "type": "text",
  1123. "primaryKey": false,
  1124. "notNull": true,
  1125. "autoincrement": false
  1126. },
  1127. "version": {
  1128. "name": "version",
  1129. "type": "integer",
  1130. "primaryKey": false,
  1131. "notNull": true,
  1132. "autoincrement": false
  1133. },
  1134. "snapshot": {
  1135. "name": "snapshot",
  1136. "type": "text",
  1137. "primaryKey": false,
  1138. "notNull": true,
  1139. "autoincrement": false
  1140. },
  1141. "created_at": {
  1142. "name": "created_at",
  1143. "type": "text",
  1144. "primaryKey": false,
  1145. "notNull": true,
  1146. "autoincrement": false,
  1147. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1148. }
  1149. },
  1150. "indexes": {},
  1151. "foreignKeys": {},
  1152. "compositePrimaryKeys": {
  1153. "profile_versions_profile_id_version_pk": {
  1154. "columns": [
  1155. "profile_id",
  1156. "version"
  1157. ],
  1158. "name": "profile_versions_profile_id_version_pk"
  1159. }
  1160. },
  1161. "uniqueConstraints": {},
  1162. "checkConstraints": {}
  1163. },
  1164. "profiles": {
  1165. "name": "profiles",
  1166. "columns": {
  1167. "id": {
  1168. "name": "id",
  1169. "type": "text",
  1170. "primaryKey": true,
  1171. "notNull": true,
  1172. "autoincrement": false
  1173. },
  1174. "name": {
  1175. "name": "name",
  1176. "type": "text",
  1177. "primaryKey": false,
  1178. "notNull": true,
  1179. "autoincrement": false
  1180. },
  1181. "description": {
  1182. "name": "description",
  1183. "type": "text",
  1184. "primaryKey": false,
  1185. "notNull": true,
  1186. "autoincrement": false,
  1187. "default": "''"
  1188. },
  1189. "provider": {
  1190. "name": "provider",
  1191. "type": "text",
  1192. "primaryKey": false,
  1193. "notNull": true,
  1194. "autoincrement": false
  1195. },
  1196. "model": {
  1197. "name": "model",
  1198. "type": "text",
  1199. "primaryKey": false,
  1200. "notNull": true,
  1201. "autoincrement": false
  1202. },
  1203. "system_prompt": {
  1204. "name": "system_prompt",
  1205. "type": "text",
  1206. "primaryKey": false,
  1207. "notNull": true,
  1208. "autoincrement": false,
  1209. "default": "''"
  1210. },
  1211. "permission_mode": {
  1212. "name": "permission_mode",
  1213. "type": "text",
  1214. "primaryKey": false,
  1215. "notNull": true,
  1216. "autoincrement": false,
  1217. "default": "'ask'"
  1218. },
  1219. "allowed_tools": {
  1220. "name": "allowed_tools",
  1221. "type": "text",
  1222. "primaryKey": false,
  1223. "notNull": true,
  1224. "autoincrement": false,
  1225. "default": "'[]'"
  1226. },
  1227. "disallowed_tools": {
  1228. "name": "disallowed_tools",
  1229. "type": "text",
  1230. "primaryKey": false,
  1231. "notNull": true,
  1232. "autoincrement": false,
  1233. "default": "'[]'"
  1234. },
  1235. "skills": {
  1236. "name": "skills",
  1237. "type": "text",
  1238. "primaryKey": false,
  1239. "notNull": true,
  1240. "autoincrement": false,
  1241. "default": "'\"all\"'"
  1242. },
  1243. "file_access": {
  1244. "name": "file_access",
  1245. "type": "text",
  1246. "primaryKey": false,
  1247. "notNull": true,
  1248. "autoincrement": false
  1249. },
  1250. "knowledge_root_ids": {
  1251. "name": "knowledge_root_ids",
  1252. "type": "text",
  1253. "primaryKey": false,
  1254. "notNull": true,
  1255. "autoincrement": false,
  1256. "default": "'[]'"
  1257. },
  1258. "mcp_server_ids": {
  1259. "name": "mcp_server_ids",
  1260. "type": "text",
  1261. "primaryKey": false,
  1262. "notNull": true,
  1263. "autoincrement": false,
  1264. "default": "'[]'"
  1265. },
  1266. "is_default": {
  1267. "name": "is_default",
  1268. "type": "integer",
  1269. "primaryKey": false,
  1270. "notNull": true,
  1271. "autoincrement": false,
  1272. "default": false
  1273. },
  1274. "builtin": {
  1275. "name": "builtin",
  1276. "type": "integer",
  1277. "primaryKey": false,
  1278. "notNull": true,
  1279. "autoincrement": false,
  1280. "default": false
  1281. },
  1282. "version": {
  1283. "name": "version",
  1284. "type": "integer",
  1285. "primaryKey": false,
  1286. "notNull": true,
  1287. "autoincrement": false,
  1288. "default": 1
  1289. },
  1290. "created_at": {
  1291. "name": "created_at",
  1292. "type": "text",
  1293. "primaryKey": false,
  1294. "notNull": true,
  1295. "autoincrement": false,
  1296. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1297. },
  1298. "updated_at": {
  1299. "name": "updated_at",
  1300. "type": "text",
  1301. "primaryKey": false,
  1302. "notNull": true,
  1303. "autoincrement": false,
  1304. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1305. }
  1306. },
  1307. "indexes": {},
  1308. "foreignKeys": {},
  1309. "compositePrimaryKeys": {},
  1310. "uniqueConstraints": {},
  1311. "checkConstraints": {}
  1312. },
  1313. "runs": {
  1314. "name": "runs",
  1315. "columns": {
  1316. "id": {
  1317. "name": "id",
  1318. "type": "text",
  1319. "primaryKey": true,
  1320. "notNull": true,
  1321. "autoincrement": false
  1322. },
  1323. "session_id": {
  1324. "name": "session_id",
  1325. "type": "text",
  1326. "primaryKey": false,
  1327. "notNull": true,
  1328. "autoincrement": false
  1329. },
  1330. "status": {
  1331. "name": "status",
  1332. "type": "text",
  1333. "primaryKey": false,
  1334. "notNull": true,
  1335. "autoincrement": false
  1336. },
  1337. "started_at": {
  1338. "name": "started_at",
  1339. "type": "text",
  1340. "primaryKey": false,
  1341. "notNull": false,
  1342. "autoincrement": false
  1343. },
  1344. "ended_at": {
  1345. "name": "ended_at",
  1346. "type": "text",
  1347. "primaryKey": false,
  1348. "notNull": false,
  1349. "autoincrement": false
  1350. },
  1351. "input_tokens": {
  1352. "name": "input_tokens",
  1353. "type": "integer",
  1354. "primaryKey": false,
  1355. "notNull": false,
  1356. "autoincrement": false
  1357. },
  1358. "output_tokens": {
  1359. "name": "output_tokens",
  1360. "type": "integer",
  1361. "primaryKey": false,
  1362. "notNull": false,
  1363. "autoincrement": false
  1364. },
  1365. "cache_read_tokens": {
  1366. "name": "cache_read_tokens",
  1367. "type": "integer",
  1368. "primaryKey": false,
  1369. "notNull": false,
  1370. "autoincrement": false
  1371. },
  1372. "cache_write_tokens": {
  1373. "name": "cache_write_tokens",
  1374. "type": "integer",
  1375. "primaryKey": false,
  1376. "notNull": false,
  1377. "autoincrement": false
  1378. },
  1379. "cost_usd": {
  1380. "name": "cost_usd",
  1381. "type": "real",
  1382. "primaryKey": false,
  1383. "notNull": false,
  1384. "autoincrement": false
  1385. },
  1386. "error": {
  1387. "name": "error",
  1388. "type": "text",
  1389. "primaryKey": false,
  1390. "notNull": false,
  1391. "autoincrement": false
  1392. },
  1393. "created_at": {
  1394. "name": "created_at",
  1395. "type": "text",
  1396. "primaryKey": false,
  1397. "notNull": true,
  1398. "autoincrement": false,
  1399. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1400. }
  1401. },
  1402. "indexes": {
  1403. "runs_session_idx": {
  1404. "name": "runs_session_idx",
  1405. "columns": [
  1406. "session_id"
  1407. ],
  1408. "isUnique": false
  1409. }
  1410. },
  1411. "foreignKeys": {},
  1412. "compositePrimaryKeys": {},
  1413. "uniqueConstraints": {},
  1414. "checkConstraints": {}
  1415. },
  1416. "sessions": {
  1417. "name": "sessions",
  1418. "columns": {
  1419. "id": {
  1420. "name": "id",
  1421. "type": "text",
  1422. "primaryKey": true,
  1423. "notNull": true,
  1424. "autoincrement": false
  1425. },
  1426. "source": {
  1427. "name": "source",
  1428. "type": "text",
  1429. "primaryKey": false,
  1430. "notNull": true,
  1431. "autoincrement": false
  1432. },
  1433. "profile_id": {
  1434. "name": "profile_id",
  1435. "type": "text",
  1436. "primaryKey": false,
  1437. "notNull": false,
  1438. "autoincrement": false
  1439. },
  1440. "provider": {
  1441. "name": "provider",
  1442. "type": "text",
  1443. "primaryKey": false,
  1444. "notNull": true,
  1445. "autoincrement": false
  1446. },
  1447. "model": {
  1448. "name": "model",
  1449. "type": "text",
  1450. "primaryKey": false,
  1451. "notNull": true,
  1452. "autoincrement": false
  1453. },
  1454. "permission_mode": {
  1455. "name": "permission_mode",
  1456. "type": "text",
  1457. "primaryKey": false,
  1458. "notNull": false,
  1459. "autoincrement": false
  1460. },
  1461. "system_prompt_append": {
  1462. "name": "system_prompt_append",
  1463. "type": "text",
  1464. "primaryKey": false,
  1465. "notNull": true,
  1466. "autoincrement": false,
  1467. "default": "''"
  1468. },
  1469. "provider_session_id": {
  1470. "name": "provider_session_id",
  1471. "type": "text",
  1472. "primaryKey": false,
  1473. "notNull": false,
  1474. "autoincrement": false
  1475. },
  1476. "workspace_dir": {
  1477. "name": "workspace_dir",
  1478. "type": "text",
  1479. "primaryKey": false,
  1480. "notNull": true,
  1481. "autoincrement": false
  1482. },
  1483. "title": {
  1484. "name": "title",
  1485. "type": "text",
  1486. "primaryKey": false,
  1487. "notNull": true,
  1488. "autoincrement": false,
  1489. "default": "''"
  1490. },
  1491. "last_seq": {
  1492. "name": "last_seq",
  1493. "type": "integer",
  1494. "primaryKey": false,
  1495. "notNull": true,
  1496. "autoincrement": false,
  1497. "default": 0
  1498. },
  1499. "archived": {
  1500. "name": "archived",
  1501. "type": "integer",
  1502. "primaryKey": false,
  1503. "notNull": true,
  1504. "autoincrement": false,
  1505. "default": false
  1506. },
  1507. "created_at": {
  1508. "name": "created_at",
  1509. "type": "text",
  1510. "primaryKey": false,
  1511. "notNull": true,
  1512. "autoincrement": false,
  1513. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1514. },
  1515. "updated_at": {
  1516. "name": "updated_at",
  1517. "type": "text",
  1518. "primaryKey": false,
  1519. "notNull": true,
  1520. "autoincrement": false,
  1521. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1522. }
  1523. },
  1524. "indexes": {
  1525. "sessions_source_idx": {
  1526. "name": "sessions_source_idx",
  1527. "columns": [
  1528. "source",
  1529. "updated_at"
  1530. ],
  1531. "isUnique": false
  1532. }
  1533. },
  1534. "foreignKeys": {},
  1535. "compositePrimaryKeys": {},
  1536. "uniqueConstraints": {},
  1537. "checkConstraints": {}
  1538. },
  1539. "settings": {
  1540. "name": "settings",
  1541. "columns": {
  1542. "key": {
  1543. "name": "key",
  1544. "type": "text",
  1545. "primaryKey": true,
  1546. "notNull": true,
  1547. "autoincrement": false
  1548. },
  1549. "value": {
  1550. "name": "value",
  1551. "type": "text",
  1552. "primaryKey": false,
  1553. "notNull": true,
  1554. "autoincrement": false
  1555. },
  1556. "updated_at": {
  1557. "name": "updated_at",
  1558. "type": "text",
  1559. "primaryKey": false,
  1560. "notNull": true,
  1561. "autoincrement": false,
  1562. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1563. }
  1564. },
  1565. "indexes": {},
  1566. "foreignKeys": {},
  1567. "compositePrimaryKeys": {},
  1568. "uniqueConstraints": {},
  1569. "checkConstraints": {}
  1570. },
  1571. "skill_sources": {
  1572. "name": "skill_sources",
  1573. "columns": {
  1574. "id": {
  1575. "name": "id",
  1576. "type": "text",
  1577. "primaryKey": true,
  1578. "notNull": true,
  1579. "autoincrement": false
  1580. },
  1581. "name": {
  1582. "name": "name",
  1583. "type": "text",
  1584. "primaryKey": false,
  1585. "notNull": true,
  1586. "autoincrement": false
  1587. },
  1588. "description": {
  1589. "name": "description",
  1590. "type": "text",
  1591. "primaryKey": false,
  1592. "notNull": true,
  1593. "autoincrement": false,
  1594. "default": "''"
  1595. },
  1596. "kind": {
  1597. "name": "kind",
  1598. "type": "text",
  1599. "primaryKey": false,
  1600. "notNull": true,
  1601. "autoincrement": false
  1602. },
  1603. "path": {
  1604. "name": "path",
  1605. "type": "text",
  1606. "primaryKey": false,
  1607. "notNull": true,
  1608. "autoincrement": false
  1609. },
  1610. "sync_mode": {
  1611. "name": "sync_mode",
  1612. "type": "text",
  1613. "primaryKey": false,
  1614. "notNull": true,
  1615. "autoincrement": false,
  1616. "default": "'manual'"
  1617. },
  1618. "interval_min": {
  1619. "name": "interval_min",
  1620. "type": "integer",
  1621. "primaryKey": false,
  1622. "notNull": true,
  1623. "autoincrement": false,
  1624. "default": 10
  1625. },
  1626. "last_sync_at": {
  1627. "name": "last_sync_at",
  1628. "type": "text",
  1629. "primaryKey": false,
  1630. "notNull": false,
  1631. "autoincrement": false
  1632. },
  1633. "last_sync_digest": {
  1634. "name": "last_sync_digest",
  1635. "type": "text",
  1636. "primaryKey": false,
  1637. "notNull": false,
  1638. "autoincrement": false
  1639. },
  1640. "status": {
  1641. "name": "status",
  1642. "type": "text",
  1643. "primaryKey": false,
  1644. "notNull": true,
  1645. "autoincrement": false,
  1646. "default": "'never'"
  1647. },
  1648. "last_error": {
  1649. "name": "last_error",
  1650. "type": "text",
  1651. "primaryKey": false,
  1652. "notNull": false,
  1653. "autoincrement": false
  1654. },
  1655. "created_at": {
  1656. "name": "created_at",
  1657. "type": "text",
  1658. "primaryKey": false,
  1659. "notNull": true,
  1660. "autoincrement": false,
  1661. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1662. },
  1663. "updated_at": {
  1664. "name": "updated_at",
  1665. "type": "text",
  1666. "primaryKey": false,
  1667. "notNull": true,
  1668. "autoincrement": false,
  1669. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1670. }
  1671. },
  1672. "indexes": {},
  1673. "foreignKeys": {},
  1674. "compositePrimaryKeys": {},
  1675. "uniqueConstraints": {},
  1676. "checkConstraints": {}
  1677. },
  1678. "tasks": {
  1679. "name": "tasks",
  1680. "columns": {
  1681. "id": {
  1682. "name": "id",
  1683. "type": "text",
  1684. "primaryKey": true,
  1685. "notNull": true,
  1686. "autoincrement": false
  1687. },
  1688. "job_id": {
  1689. "name": "job_id",
  1690. "type": "text",
  1691. "primaryKey": false,
  1692. "notNull": true,
  1693. "autoincrement": false
  1694. },
  1695. "team_id": {
  1696. "name": "team_id",
  1697. "type": "text",
  1698. "primaryKey": false,
  1699. "notNull": true,
  1700. "autoincrement": false
  1701. },
  1702. "no": {
  1703. "name": "no",
  1704. "type": "integer",
  1705. "primaryKey": false,
  1706. "notNull": true,
  1707. "autoincrement": false
  1708. },
  1709. "bot_id": {
  1710. "name": "bot_id",
  1711. "type": "text",
  1712. "primaryKey": false,
  1713. "notNull": true,
  1714. "autoincrement": false
  1715. },
  1716. "title": {
  1717. "name": "title",
  1718. "type": "text",
  1719. "primaryKey": false,
  1720. "notNull": true,
  1721. "autoincrement": false
  1722. },
  1723. "instructions": {
  1724. "name": "instructions",
  1725. "type": "text",
  1726. "primaryKey": false,
  1727. "notNull": true,
  1728. "autoincrement": false
  1729. },
  1730. "depends_on": {
  1731. "name": "depends_on",
  1732. "type": "text",
  1733. "primaryKey": false,
  1734. "notNull": true,
  1735. "autoincrement": false,
  1736. "default": "'[]'"
  1737. },
  1738. "status": {
  1739. "name": "status",
  1740. "type": "text",
  1741. "primaryKey": false,
  1742. "notNull": true,
  1743. "autoincrement": false
  1744. },
  1745. "result": {
  1746. "name": "result",
  1747. "type": "text",
  1748. "primaryKey": false,
  1749. "notNull": false,
  1750. "autoincrement": false
  1751. },
  1752. "files": {
  1753. "name": "files",
  1754. "type": "text",
  1755. "primaryKey": false,
  1756. "notNull": true,
  1757. "autoincrement": false,
  1758. "default": "'[]'"
  1759. },
  1760. "run_id": {
  1761. "name": "run_id",
  1762. "type": "text",
  1763. "primaryKey": false,
  1764. "notNull": false,
  1765. "autoincrement": false
  1766. },
  1767. "session_id": {
  1768. "name": "session_id",
  1769. "type": "text",
  1770. "primaryKey": false,
  1771. "notNull": false,
  1772. "autoincrement": false
  1773. },
  1774. "created_at": {
  1775. "name": "created_at",
  1776. "type": "text",
  1777. "primaryKey": false,
  1778. "notNull": true,
  1779. "autoincrement": false,
  1780. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1781. },
  1782. "started_at": {
  1783. "name": "started_at",
  1784. "type": "text",
  1785. "primaryKey": false,
  1786. "notNull": false,
  1787. "autoincrement": false
  1788. },
  1789. "ended_at": {
  1790. "name": "ended_at",
  1791. "type": "text",
  1792. "primaryKey": false,
  1793. "notNull": false,
  1794. "autoincrement": false
  1795. }
  1796. },
  1797. "indexes": {
  1798. "tasks_team_idx": {
  1799. "name": "tasks_team_idx",
  1800. "columns": [
  1801. "team_id",
  1802. "no"
  1803. ],
  1804. "isUnique": false
  1805. },
  1806. "tasks_job_idx": {
  1807. "name": "tasks_job_idx",
  1808. "columns": [
  1809. "job_id"
  1810. ],
  1811. "isUnique": false
  1812. }
  1813. },
  1814. "foreignKeys": {},
  1815. "compositePrimaryKeys": {},
  1816. "uniqueConstraints": {},
  1817. "checkConstraints": {}
  1818. },
  1819. "team_bot_sessions": {
  1820. "name": "team_bot_sessions",
  1821. "columns": {
  1822. "team_id": {
  1823. "name": "team_id",
  1824. "type": "text",
  1825. "primaryKey": false,
  1826. "notNull": true,
  1827. "autoincrement": false
  1828. },
  1829. "bot_id": {
  1830. "name": "bot_id",
  1831. "type": "text",
  1832. "primaryKey": false,
  1833. "notNull": true,
  1834. "autoincrement": false
  1835. },
  1836. "session_id": {
  1837. "name": "session_id",
  1838. "type": "text",
  1839. "primaryKey": false,
  1840. "notNull": true,
  1841. "autoincrement": false
  1842. },
  1843. "last_read_seq": {
  1844. "name": "last_read_seq",
  1845. "type": "integer",
  1846. "primaryKey": false,
  1847. "notNull": true,
  1848. "autoincrement": false,
  1849. "default": 0
  1850. }
  1851. },
  1852. "indexes": {
  1853. "team_bot_sessions_session_id_unique": {
  1854. "name": "team_bot_sessions_session_id_unique",
  1855. "columns": [
  1856. "session_id"
  1857. ],
  1858. "isUnique": true
  1859. }
  1860. },
  1861. "foreignKeys": {},
  1862. "compositePrimaryKeys": {
  1863. "team_bot_sessions_team_id_bot_id_pk": {
  1864. "columns": [
  1865. "team_id",
  1866. "bot_id"
  1867. ],
  1868. "name": "team_bot_sessions_team_id_bot_id_pk"
  1869. }
  1870. },
  1871. "uniqueConstraints": {},
  1872. "checkConstraints": {}
  1873. },
  1874. "team_bots": {
  1875. "name": "team_bots",
  1876. "columns": {
  1877. "team_id": {
  1878. "name": "team_id",
  1879. "type": "text",
  1880. "primaryKey": false,
  1881. "notNull": true,
  1882. "autoincrement": false
  1883. },
  1884. "bot_id": {
  1885. "name": "bot_id",
  1886. "type": "text",
  1887. "primaryKey": false,
  1888. "notNull": true,
  1889. "autoincrement": false
  1890. },
  1891. "role": {
  1892. "name": "role",
  1893. "type": "text",
  1894. "primaryKey": false,
  1895. "notNull": true,
  1896. "autoincrement": false
  1897. },
  1898. "joined_at": {
  1899. "name": "joined_at",
  1900. "type": "text",
  1901. "primaryKey": false,
  1902. "notNull": true,
  1903. "autoincrement": false,
  1904. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1905. }
  1906. },
  1907. "indexes": {
  1908. "team_bots_bot_idx": {
  1909. "name": "team_bots_bot_idx",
  1910. "columns": [
  1911. "bot_id"
  1912. ],
  1913. "isUnique": false
  1914. }
  1915. },
  1916. "foreignKeys": {},
  1917. "compositePrimaryKeys": {
  1918. "team_bots_team_id_bot_id_pk": {
  1919. "columns": [
  1920. "team_id",
  1921. "bot_id"
  1922. ],
  1923. "name": "team_bots_team_id_bot_id_pk"
  1924. }
  1925. },
  1926. "uniqueConstraints": {},
  1927. "checkConstraints": {}
  1928. },
  1929. "team_cases": {
  1930. "name": "team_cases",
  1931. "columns": {
  1932. "id": {
  1933. "name": "id",
  1934. "type": "text",
  1935. "primaryKey": true,
  1936. "notNull": true,
  1937. "autoincrement": false
  1938. },
  1939. "name": {
  1940. "name": "name",
  1941. "type": "text",
  1942. "primaryKey": false,
  1943. "notNull": true,
  1944. "autoincrement": false
  1945. },
  1946. "lead_bot_id": {
  1947. "name": "lead_bot_id",
  1948. "type": "text",
  1949. "primaryKey": false,
  1950. "notNull": false,
  1951. "autoincrement": false
  1952. },
  1953. "worker_bot_ids": {
  1954. "name": "worker_bot_ids",
  1955. "type": "text",
  1956. "primaryKey": false,
  1957. "notNull": true,
  1958. "autoincrement": false,
  1959. "default": "'[]'"
  1960. },
  1961. "stub_bot_ids": {
  1962. "name": "stub_bot_ids",
  1963. "type": "text",
  1964. "primaryKey": false,
  1965. "notNull": true,
  1966. "autoincrement": false,
  1967. "default": "'[]'"
  1968. },
  1969. "limits": {
  1970. "name": "limits",
  1971. "type": "text",
  1972. "primaryKey": false,
  1973. "notNull": false,
  1974. "autoincrement": false
  1975. },
  1976. "human_name": {
  1977. "name": "human_name",
  1978. "type": "text",
  1979. "primaryKey": false,
  1980. "notNull": true,
  1981. "autoincrement": false
  1982. },
  1983. "text": {
  1984. "name": "text",
  1985. "type": "text",
  1986. "primaryKey": false,
  1987. "notNull": true,
  1988. "autoincrement": false
  1989. },
  1990. "mentions": {
  1991. "name": "mentions",
  1992. "type": "text",
  1993. "primaryKey": false,
  1994. "notNull": true,
  1995. "autoincrement": false,
  1996. "default": "'[]'"
  1997. },
  1998. "files": {
  1999. "name": "files",
  2000. "type": "text",
  2001. "primaryKey": false,
  2002. "notNull": true,
  2003. "autoincrement": false,
  2004. "default": "'[]'"
  2005. },
  2006. "created_at": {
  2007. "name": "created_at",
  2008. "type": "text",
  2009. "primaryKey": false,
  2010. "notNull": true,
  2011. "autoincrement": false,
  2012. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2013. },
  2014. "updated_at": {
  2015. "name": "updated_at",
  2016. "type": "text",
  2017. "primaryKey": false,
  2018. "notNull": true,
  2019. "autoincrement": false,
  2020. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2021. }
  2022. },
  2023. "indexes": {},
  2024. "foreignKeys": {},
  2025. "compositePrimaryKeys": {},
  2026. "uniqueConstraints": {},
  2027. "checkConstraints": {}
  2028. },
  2029. "team_events": {
  2030. "name": "team_events",
  2031. "columns": {
  2032. "team_id": {
  2033. "name": "team_id",
  2034. "type": "text",
  2035. "primaryKey": false,
  2036. "notNull": true,
  2037. "autoincrement": false
  2038. },
  2039. "seq": {
  2040. "name": "seq",
  2041. "type": "integer",
  2042. "primaryKey": false,
  2043. "notNull": true,
  2044. "autoincrement": false
  2045. },
  2046. "type": {
  2047. "name": "type",
  2048. "type": "text",
  2049. "primaryKey": false,
  2050. "notNull": true,
  2051. "autoincrement": false
  2052. },
  2053. "payload": {
  2054. "name": "payload",
  2055. "type": "text",
  2056. "primaryKey": false,
  2057. "notNull": true,
  2058. "autoincrement": false
  2059. },
  2060. "ts": {
  2061. "name": "ts",
  2062. "type": "text",
  2063. "primaryKey": false,
  2064. "notNull": true,
  2065. "autoincrement": false
  2066. }
  2067. },
  2068. "indexes": {},
  2069. "foreignKeys": {},
  2070. "compositePrimaryKeys": {
  2071. "team_events_team_id_seq_pk": {
  2072. "columns": [
  2073. "team_id",
  2074. "seq"
  2075. ],
  2076. "name": "team_events_team_id_seq_pk"
  2077. }
  2078. },
  2079. "uniqueConstraints": {},
  2080. "checkConstraints": {}
  2081. },
  2082. "teams": {
  2083. "name": "teams",
  2084. "columns": {
  2085. "id": {
  2086. "name": "id",
  2087. "type": "text",
  2088. "primaryKey": true,
  2089. "notNull": true,
  2090. "autoincrement": false
  2091. },
  2092. "source": {
  2093. "name": "source",
  2094. "type": "text",
  2095. "primaryKey": false,
  2096. "notNull": true,
  2097. "autoincrement": false
  2098. },
  2099. "title": {
  2100. "name": "title",
  2101. "type": "text",
  2102. "primaryKey": false,
  2103. "notNull": true,
  2104. "autoincrement": false,
  2105. "default": "''"
  2106. },
  2107. "human": {
  2108. "name": "human",
  2109. "type": "text",
  2110. "primaryKey": false,
  2111. "notNull": true,
  2112. "autoincrement": false
  2113. },
  2114. "status": {
  2115. "name": "status",
  2116. "type": "text",
  2117. "primaryKey": false,
  2118. "notNull": true,
  2119. "autoincrement": false,
  2120. "default": "'active'"
  2121. },
  2122. "workspace_dir": {
  2123. "name": "workspace_dir",
  2124. "type": "text",
  2125. "primaryKey": false,
  2126. "notNull": true,
  2127. "autoincrement": false
  2128. },
  2129. "limits": {
  2130. "name": "limits",
  2131. "type": "text",
  2132. "primaryKey": false,
  2133. "notNull": false,
  2134. "autoincrement": false
  2135. },
  2136. "debug": {
  2137. "name": "debug",
  2138. "type": "text",
  2139. "primaryKey": false,
  2140. "notNull": true,
  2141. "autoincrement": false,
  2142. "default": "'{\"stepMode\":false,\"stubBotIds\":[]}'"
  2143. },
  2144. "last_seq": {
  2145. "name": "last_seq",
  2146. "type": "integer",
  2147. "primaryKey": false,
  2148. "notNull": true,
  2149. "autoincrement": false,
  2150. "default": 0
  2151. },
  2152. "case_id": {
  2153. "name": "case_id",
  2154. "type": "text",
  2155. "primaryKey": false,
  2156. "notNull": false,
  2157. "autoincrement": false
  2158. },
  2159. "created_at": {
  2160. "name": "created_at",
  2161. "type": "text",
  2162. "primaryKey": false,
  2163. "notNull": true,
  2164. "autoincrement": false,
  2165. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2166. },
  2167. "updated_at": {
  2168. "name": "updated_at",
  2169. "type": "text",
  2170. "primaryKey": false,
  2171. "notNull": true,
  2172. "autoincrement": false,
  2173. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2174. }
  2175. },
  2176. "indexes": {
  2177. "teams_source_idx": {
  2178. "name": "teams_source_idx",
  2179. "columns": [
  2180. "source",
  2181. "updated_at"
  2182. ],
  2183. "isUnique": false
  2184. },
  2185. "teams_case_idx": {
  2186. "name": "teams_case_idx",
  2187. "columns": [
  2188. "case_id"
  2189. ],
  2190. "isUnique": false
  2191. }
  2192. },
  2193. "foreignKeys": {},
  2194. "compositePrimaryKeys": {},
  2195. "uniqueConstraints": {},
  2196. "checkConstraints": {}
  2197. },
  2198. "usage_daily": {
  2199. "name": "usage_daily",
  2200. "columns": {
  2201. "date": {
  2202. "name": "date",
  2203. "type": "text",
  2204. "primaryKey": false,
  2205. "notNull": true,
  2206. "autoincrement": false
  2207. },
  2208. "source": {
  2209. "name": "source",
  2210. "type": "text",
  2211. "primaryKey": false,
  2212. "notNull": true,
  2213. "autoincrement": false
  2214. },
  2215. "provider": {
  2216. "name": "provider",
  2217. "type": "text",
  2218. "primaryKey": false,
  2219. "notNull": true,
  2220. "autoincrement": false
  2221. },
  2222. "model": {
  2223. "name": "model",
  2224. "type": "text",
  2225. "primaryKey": false,
  2226. "notNull": true,
  2227. "autoincrement": false
  2228. },
  2229. "runs": {
  2230. "name": "runs",
  2231. "type": "integer",
  2232. "primaryKey": false,
  2233. "notNull": true,
  2234. "autoincrement": false,
  2235. "default": 0
  2236. },
  2237. "failed": {
  2238. "name": "failed",
  2239. "type": "integer",
  2240. "primaryKey": false,
  2241. "notNull": true,
  2242. "autoincrement": false,
  2243. "default": 0
  2244. },
  2245. "interrupted": {
  2246. "name": "interrupted",
  2247. "type": "integer",
  2248. "primaryKey": false,
  2249. "notNull": true,
  2250. "autoincrement": false,
  2251. "default": 0
  2252. },
  2253. "input_tokens": {
  2254. "name": "input_tokens",
  2255. "type": "integer",
  2256. "primaryKey": false,
  2257. "notNull": true,
  2258. "autoincrement": false,
  2259. "default": 0
  2260. },
  2261. "output_tokens": {
  2262. "name": "output_tokens",
  2263. "type": "integer",
  2264. "primaryKey": false,
  2265. "notNull": true,
  2266. "autoincrement": false,
  2267. "default": 0
  2268. },
  2269. "cache_read_tokens": {
  2270. "name": "cache_read_tokens",
  2271. "type": "integer",
  2272. "primaryKey": false,
  2273. "notNull": true,
  2274. "autoincrement": false,
  2275. "default": 0
  2276. },
  2277. "cache_write_tokens": {
  2278. "name": "cache_write_tokens",
  2279. "type": "integer",
  2280. "primaryKey": false,
  2281. "notNull": true,
  2282. "autoincrement": false,
  2283. "default": 0
  2284. },
  2285. "cost_usd": {
  2286. "name": "cost_usd",
  2287. "type": "real",
  2288. "primaryKey": false,
  2289. "notNull": true,
  2290. "autoincrement": false,
  2291. "default": 0
  2292. },
  2293. "duration_ms": {
  2294. "name": "duration_ms",
  2295. "type": "integer",
  2296. "primaryKey": false,
  2297. "notNull": true,
  2298. "autoincrement": false,
  2299. "default": 0
  2300. }
  2301. },
  2302. "indexes": {},
  2303. "foreignKeys": {},
  2304. "compositePrimaryKeys": {
  2305. "usage_daily_date_source_provider_model_pk": {
  2306. "columns": [
  2307. "date",
  2308. "source",
  2309. "provider",
  2310. "model"
  2311. ],
  2312. "name": "usage_daily_date_source_provider_model_pk"
  2313. }
  2314. },
  2315. "uniqueConstraints": {},
  2316. "checkConstraints": {}
  2317. }
  2318. },
  2319. "views": {},
  2320. "enums": {},
  2321. "_meta": {
  2322. "schemas": {},
  2323. "tables": {},
  2324. "columns": {}
  2325. },
  2326. "internal": {
  2327. "indexes": {}
  2328. }
  2329. }