0012_snapshot.json 69 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732
  1. {
  2. "version": "6",
  3. "dialect": "sqlite",
  4. "id": "ab94bbd8-de0b-41e5-a1f9-97bd1752c3e1",
  5. "prevId": "305d48b6-563e-4dbb-b0c8-8f1b276cdfc5",
  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. "background_calls": {
  192. "name": "background_calls",
  193. "columns": {
  194. "id": {
  195. "name": "id",
  196. "type": "text",
  197. "primaryKey": true,
  198. "notNull": true,
  199. "autoincrement": false
  200. },
  201. "session_id": {
  202. "name": "session_id",
  203. "type": "text",
  204. "primaryKey": false,
  205. "notNull": true,
  206. "autoincrement": false
  207. },
  208. "team_id": {
  209. "name": "team_id",
  210. "type": "text",
  211. "primaryKey": false,
  212. "notNull": false,
  213. "autoincrement": false
  214. },
  215. "bot_id": {
  216. "name": "bot_id",
  217. "type": "text",
  218. "primaryKey": false,
  219. "notNull": false,
  220. "autoincrement": false
  221. },
  222. "task_id": {
  223. "name": "task_id",
  224. "type": "text",
  225. "primaryKey": false,
  226. "notNull": false,
  227. "autoincrement": false
  228. },
  229. "server_id": {
  230. "name": "server_id",
  231. "type": "text",
  232. "primaryKey": false,
  233. "notNull": true,
  234. "autoincrement": false
  235. },
  236. "server_name": {
  237. "name": "server_name",
  238. "type": "text",
  239. "primaryKey": false,
  240. "notNull": true,
  241. "autoincrement": false
  242. },
  243. "server_title": {
  244. "name": "server_title",
  245. "type": "text",
  246. "primaryKey": false,
  247. "notNull": true,
  248. "autoincrement": false
  249. },
  250. "tool": {
  251. "name": "tool",
  252. "type": "text",
  253. "primaryKey": false,
  254. "notNull": true,
  255. "autoincrement": false
  256. },
  257. "args": {
  258. "name": "args",
  259. "type": "text",
  260. "primaryKey": false,
  261. "notNull": true,
  262. "autoincrement": false
  263. },
  264. "status": {
  265. "name": "status",
  266. "type": "text",
  267. "primaryKey": false,
  268. "notNull": true,
  269. "autoincrement": false,
  270. "default": "'running'"
  271. },
  272. "started_at": {
  273. "name": "started_at",
  274. "type": "text",
  275. "primaryKey": false,
  276. "notNull": true,
  277. "autoincrement": false,
  278. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  279. },
  280. "ended_at": {
  281. "name": "ended_at",
  282. "type": "text",
  283. "primaryKey": false,
  284. "notNull": false,
  285. "autoincrement": false
  286. },
  287. "result": {
  288. "name": "result",
  289. "type": "text",
  290. "primaryKey": false,
  291. "notNull": false,
  292. "autoincrement": false
  293. },
  294. "error": {
  295. "name": "error",
  296. "type": "text",
  297. "primaryKey": false,
  298. "notNull": false,
  299. "autoincrement": false
  300. },
  301. "delivered": {
  302. "name": "delivered",
  303. "type": "integer",
  304. "primaryKey": false,
  305. "notNull": true,
  306. "autoincrement": false,
  307. "default": false
  308. }
  309. },
  310. "indexes": {
  311. "background_calls_session_idx": {
  312. "name": "background_calls_session_idx",
  313. "columns": [
  314. "session_id"
  315. ],
  316. "isUnique": false
  317. },
  318. "background_calls_team_idx": {
  319. "name": "background_calls_team_idx",
  320. "columns": [
  321. "team_id"
  322. ],
  323. "isUnique": false
  324. },
  325. "background_calls_status_idx": {
  326. "name": "background_calls_status_idx",
  327. "columns": [
  328. "status",
  329. "delivered"
  330. ],
  331. "isUnique": false
  332. }
  333. },
  334. "foreignKeys": {},
  335. "compositePrimaryKeys": {},
  336. "uniqueConstraints": {},
  337. "checkConstraints": {}
  338. },
  339. "bot_api_keys": {
  340. "name": "bot_api_keys",
  341. "columns": {
  342. "id": {
  343. "name": "id",
  344. "type": "text",
  345. "primaryKey": true,
  346. "notNull": true,
  347. "autoincrement": false
  348. },
  349. "name": {
  350. "name": "name",
  351. "type": "text",
  352. "primaryKey": false,
  353. "notNull": true,
  354. "autoincrement": false
  355. },
  356. "key_hash": {
  357. "name": "key_hash",
  358. "type": "text",
  359. "primaryKey": false,
  360. "notNull": true,
  361. "autoincrement": false
  362. },
  363. "key_prefix": {
  364. "name": "key_prefix",
  365. "type": "text",
  366. "primaryKey": false,
  367. "notNull": true,
  368. "autoincrement": false
  369. },
  370. "enabled": {
  371. "name": "enabled",
  372. "type": "integer",
  373. "primaryKey": false,
  374. "notNull": true,
  375. "autoincrement": false,
  376. "default": true
  377. },
  378. "allowed_bot_ids": {
  379. "name": "allowed_bot_ids",
  380. "type": "text",
  381. "primaryKey": false,
  382. "notNull": true,
  383. "autoincrement": false,
  384. "default": "'[]'"
  385. },
  386. "created_at": {
  387. "name": "created_at",
  388. "type": "text",
  389. "primaryKey": false,
  390. "notNull": true,
  391. "autoincrement": false,
  392. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  393. },
  394. "last_used_at": {
  395. "name": "last_used_at",
  396. "type": "text",
  397. "primaryKey": false,
  398. "notNull": false,
  399. "autoincrement": false
  400. }
  401. },
  402. "indexes": {
  403. "bot_api_keys_key_hash_unique": {
  404. "name": "bot_api_keys_key_hash_unique",
  405. "columns": [
  406. "key_hash"
  407. ],
  408. "isUnique": true
  409. }
  410. },
  411. "foreignKeys": {},
  412. "compositePrimaryKeys": {},
  413. "uniqueConstraints": {},
  414. "checkConstraints": {}
  415. },
  416. "bots": {
  417. "name": "bots",
  418. "columns": {
  419. "id": {
  420. "name": "id",
  421. "type": "text",
  422. "primaryKey": true,
  423. "notNull": true,
  424. "autoincrement": false
  425. },
  426. "name": {
  427. "name": "name",
  428. "type": "text",
  429. "primaryKey": false,
  430. "notNull": true,
  431. "autoincrement": false
  432. },
  433. "avatar": {
  434. "name": "avatar",
  435. "type": "text",
  436. "primaryKey": false,
  437. "notNull": true,
  438. "autoincrement": false,
  439. "default": "'🤖'"
  440. },
  441. "kind": {
  442. "name": "kind",
  443. "type": "text",
  444. "primaryKey": false,
  445. "notNull": true,
  446. "autoincrement": false
  447. },
  448. "description": {
  449. "name": "description",
  450. "type": "text",
  451. "primaryKey": false,
  452. "notNull": true,
  453. "autoincrement": false,
  454. "default": "''"
  455. },
  456. "profile_id": {
  457. "name": "profile_id",
  458. "type": "text",
  459. "primaryKey": false,
  460. "notNull": true,
  461. "autoincrement": false
  462. },
  463. "enabled": {
  464. "name": "enabled",
  465. "type": "integer",
  466. "primaryKey": false,
  467. "notNull": true,
  468. "autoincrement": false,
  469. "default": true
  470. },
  471. "created_at": {
  472. "name": "created_at",
  473. "type": "text",
  474. "primaryKey": false,
  475. "notNull": true,
  476. "autoincrement": false,
  477. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  478. },
  479. "updated_at": {
  480. "name": "updated_at",
  481. "type": "text",
  482. "primaryKey": false,
  483. "notNull": true,
  484. "autoincrement": false,
  485. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  486. }
  487. },
  488. "indexes": {
  489. "bots_name_unique": {
  490. "name": "bots_name_unique",
  491. "columns": [
  492. "name"
  493. ],
  494. "isUnique": true
  495. }
  496. },
  497. "foreignKeys": {},
  498. "compositePrimaryKeys": {},
  499. "uniqueConstraints": {},
  500. "checkConstraints": {}
  501. },
  502. "custom_skill_versions": {
  503. "name": "custom_skill_versions",
  504. "columns": {
  505. "skill_id": {
  506. "name": "skill_id",
  507. "type": "text",
  508. "primaryKey": false,
  509. "notNull": true,
  510. "autoincrement": false
  511. },
  512. "version": {
  513. "name": "version",
  514. "type": "integer",
  515. "primaryKey": false,
  516. "notNull": true,
  517. "autoincrement": false
  518. },
  519. "reason": {
  520. "name": "reason",
  521. "type": "text",
  522. "primaryKey": false,
  523. "notNull": true,
  524. "autoincrement": false
  525. },
  526. "files": {
  527. "name": "files",
  528. "type": "text",
  529. "primaryKey": false,
  530. "notNull": true,
  531. "autoincrement": false
  532. },
  533. "changed": {
  534. "name": "changed",
  535. "type": "text",
  536. "primaryKey": false,
  537. "notNull": true,
  538. "autoincrement": false
  539. },
  540. "created_at": {
  541. "name": "created_at",
  542. "type": "text",
  543. "primaryKey": false,
  544. "notNull": true,
  545. "autoincrement": false,
  546. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  547. }
  548. },
  549. "indexes": {},
  550. "foreignKeys": {},
  551. "compositePrimaryKeys": {
  552. "custom_skill_versions_skill_id_version_pk": {
  553. "columns": [
  554. "skill_id",
  555. "version"
  556. ],
  557. "name": "custom_skill_versions_skill_id_version_pk"
  558. }
  559. },
  560. "uniqueConstraints": {},
  561. "checkConstraints": {}
  562. },
  563. "custom_skills": {
  564. "name": "custom_skills",
  565. "columns": {
  566. "id": {
  567. "name": "id",
  568. "type": "text",
  569. "primaryKey": true,
  570. "notNull": true,
  571. "autoincrement": false
  572. },
  573. "name": {
  574. "name": "name",
  575. "type": "text",
  576. "primaryKey": false,
  577. "notNull": true,
  578. "autoincrement": false
  579. },
  580. "description": {
  581. "name": "description",
  582. "type": "text",
  583. "primaryKey": false,
  584. "notNull": true,
  585. "autoincrement": false,
  586. "default": "''"
  587. },
  588. "origin": {
  589. "name": "origin",
  590. "type": "text",
  591. "primaryKey": false,
  592. "notNull": true,
  593. "autoincrement": false
  594. },
  595. "source_id": {
  596. "name": "source_id",
  597. "type": "text",
  598. "primaryKey": false,
  599. "notNull": false,
  600. "autoincrement": false
  601. },
  602. "enabled": {
  603. "name": "enabled",
  604. "type": "integer",
  605. "primaryKey": false,
  606. "notNull": true,
  607. "autoincrement": false,
  608. "default": true
  609. },
  610. "include_in_all": {
  611. "name": "include_in_all",
  612. "type": "integer",
  613. "primaryKey": false,
  614. "notNull": true,
  615. "autoincrement": false,
  616. "default": false
  617. },
  618. "published_version": {
  619. "name": "published_version",
  620. "type": "integer",
  621. "primaryKey": false,
  622. "notNull": false,
  623. "autoincrement": false
  624. },
  625. "latest_version": {
  626. "name": "latest_version",
  627. "type": "integer",
  628. "primaryKey": false,
  629. "notNull": true,
  630. "autoincrement": false,
  631. "default": 0
  632. },
  633. "working_files": {
  634. "name": "working_files",
  635. "type": "text",
  636. "primaryKey": false,
  637. "notNull": true,
  638. "autoincrement": false,
  639. "default": "'{}'"
  640. },
  641. "created_at": {
  642. "name": "created_at",
  643. "type": "text",
  644. "primaryKey": false,
  645. "notNull": true,
  646. "autoincrement": false,
  647. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  648. },
  649. "updated_at": {
  650. "name": "updated_at",
  651. "type": "text",
  652. "primaryKey": false,
  653. "notNull": true,
  654. "autoincrement": false,
  655. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  656. }
  657. },
  658. "indexes": {
  659. "custom_skills_name_unique": {
  660. "name": "custom_skills_name_unique",
  661. "columns": [
  662. "name"
  663. ],
  664. "isUnique": true
  665. }
  666. },
  667. "foreignKeys": {},
  668. "compositePrimaryKeys": {},
  669. "uniqueConstraints": {},
  670. "checkConstraints": {}
  671. },
  672. "events": {
  673. "name": "events",
  674. "columns": {
  675. "session_id": {
  676. "name": "session_id",
  677. "type": "text",
  678. "primaryKey": false,
  679. "notNull": true,
  680. "autoincrement": false
  681. },
  682. "seq": {
  683. "name": "seq",
  684. "type": "integer",
  685. "primaryKey": false,
  686. "notNull": true,
  687. "autoincrement": false
  688. },
  689. "run_id": {
  690. "name": "run_id",
  691. "type": "text",
  692. "primaryKey": false,
  693. "notNull": false,
  694. "autoincrement": false
  695. },
  696. "type": {
  697. "name": "type",
  698. "type": "text",
  699. "primaryKey": false,
  700. "notNull": true,
  701. "autoincrement": false
  702. },
  703. "payload": {
  704. "name": "payload",
  705. "type": "text",
  706. "primaryKey": false,
  707. "notNull": true,
  708. "autoincrement": false
  709. },
  710. "ts": {
  711. "name": "ts",
  712. "type": "text",
  713. "primaryKey": false,
  714. "notNull": true,
  715. "autoincrement": false
  716. }
  717. },
  718. "indexes": {},
  719. "foreignKeys": {},
  720. "compositePrimaryKeys": {
  721. "events_session_id_seq_pk": {
  722. "columns": [
  723. "session_id",
  724. "seq"
  725. ],
  726. "name": "events_session_id_seq_pk"
  727. }
  728. },
  729. "uniqueConstraints": {},
  730. "checkConstraints": {}
  731. },
  732. "files": {
  733. "name": "files",
  734. "columns": {
  735. "id": {
  736. "name": "id",
  737. "type": "text",
  738. "primaryKey": true,
  739. "notNull": true,
  740. "autoincrement": false
  741. },
  742. "session_id": {
  743. "name": "session_id",
  744. "type": "text",
  745. "primaryKey": false,
  746. "notNull": true,
  747. "autoincrement": false
  748. },
  749. "rel_path": {
  750. "name": "rel_path",
  751. "type": "text",
  752. "primaryKey": false,
  753. "notNull": true,
  754. "autoincrement": false
  755. },
  756. "origin": {
  757. "name": "origin",
  758. "type": "text",
  759. "primaryKey": false,
  760. "notNull": true,
  761. "autoincrement": false
  762. },
  763. "mime": {
  764. "name": "mime",
  765. "type": "text",
  766. "primaryKey": false,
  767. "notNull": true,
  768. "autoincrement": false
  769. },
  770. "size": {
  771. "name": "size",
  772. "type": "integer",
  773. "primaryKey": false,
  774. "notNull": true,
  775. "autoincrement": false
  776. },
  777. "mtime_ms": {
  778. "name": "mtime_ms",
  779. "type": "real",
  780. "primaryKey": false,
  781. "notNull": true,
  782. "autoincrement": false
  783. },
  784. "created_at": {
  785. "name": "created_at",
  786. "type": "text",
  787. "primaryKey": false,
  788. "notNull": true,
  789. "autoincrement": false,
  790. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  791. },
  792. "updated_at": {
  793. "name": "updated_at",
  794. "type": "text",
  795. "primaryKey": false,
  796. "notNull": true,
  797. "autoincrement": false,
  798. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  799. }
  800. },
  801. "indexes": {
  802. "files_session_path_idx": {
  803. "name": "files_session_path_idx",
  804. "columns": [
  805. "session_id",
  806. "rel_path"
  807. ],
  808. "isUnique": false
  809. }
  810. },
  811. "foreignKeys": {},
  812. "compositePrimaryKeys": {},
  813. "uniqueConstraints": {},
  814. "checkConstraints": {}
  815. },
  816. "interactions": {
  817. "name": "interactions",
  818. "columns": {
  819. "id": {
  820. "name": "id",
  821. "type": "text",
  822. "primaryKey": true,
  823. "notNull": true,
  824. "autoincrement": false
  825. },
  826. "session_id": {
  827. "name": "session_id",
  828. "type": "text",
  829. "primaryKey": false,
  830. "notNull": true,
  831. "autoincrement": false
  832. },
  833. "run_id": {
  834. "name": "run_id",
  835. "type": "text",
  836. "primaryKey": false,
  837. "notNull": true,
  838. "autoincrement": false
  839. },
  840. "kind": {
  841. "name": "kind",
  842. "type": "text",
  843. "primaryKey": false,
  844. "notNull": true,
  845. "autoincrement": false
  846. },
  847. "request": {
  848. "name": "request",
  849. "type": "text",
  850. "primaryKey": false,
  851. "notNull": true,
  852. "autoincrement": false
  853. },
  854. "response": {
  855. "name": "response",
  856. "type": "text",
  857. "primaryKey": false,
  858. "notNull": false,
  859. "autoincrement": false
  860. },
  861. "status": {
  862. "name": "status",
  863. "type": "text",
  864. "primaryKey": false,
  865. "notNull": true,
  866. "autoincrement": false
  867. },
  868. "created_at": {
  869. "name": "created_at",
  870. "type": "text",
  871. "primaryKey": false,
  872. "notNull": true,
  873. "autoincrement": false,
  874. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  875. },
  876. "resolved_at": {
  877. "name": "resolved_at",
  878. "type": "text",
  879. "primaryKey": false,
  880. "notNull": false,
  881. "autoincrement": false
  882. },
  883. "expires_at": {
  884. "name": "expires_at",
  885. "type": "text",
  886. "primaryKey": false,
  887. "notNull": true,
  888. "autoincrement": false
  889. }
  890. },
  891. "indexes": {
  892. "interactions_session_idx": {
  893. "name": "interactions_session_idx",
  894. "columns": [
  895. "session_id",
  896. "status"
  897. ],
  898. "isUnique": false
  899. }
  900. },
  901. "foreignKeys": {},
  902. "compositePrimaryKeys": {},
  903. "uniqueConstraints": {},
  904. "checkConstraints": {}
  905. },
  906. "jobs": {
  907. "name": "jobs",
  908. "columns": {
  909. "id": {
  910. "name": "id",
  911. "type": "text",
  912. "primaryKey": true,
  913. "notNull": true,
  914. "autoincrement": false
  915. },
  916. "team_id": {
  917. "name": "team_id",
  918. "type": "text",
  919. "primaryKey": false,
  920. "notNull": true,
  921. "autoincrement": false
  922. },
  923. "no": {
  924. "name": "no",
  925. "type": "integer",
  926. "primaryKey": false,
  927. "notNull": true,
  928. "autoincrement": false
  929. },
  930. "title": {
  931. "name": "title",
  932. "type": "text",
  933. "primaryKey": false,
  934. "notNull": true,
  935. "autoincrement": false
  936. },
  937. "plan": {
  938. "name": "plan",
  939. "type": "text",
  940. "primaryKey": false,
  941. "notNull": true,
  942. "autoincrement": false,
  943. "default": "''"
  944. },
  945. "status": {
  946. "name": "status",
  947. "type": "text",
  948. "primaryKey": false,
  949. "notNull": true,
  950. "autoincrement": false,
  951. "default": "'running'"
  952. },
  953. "summary": {
  954. "name": "summary",
  955. "type": "text",
  956. "primaryKey": false,
  957. "notNull": false,
  958. "autoincrement": false
  959. },
  960. "files": {
  961. "name": "files",
  962. "type": "text",
  963. "primaryKey": false,
  964. "notNull": true,
  965. "autoincrement": false,
  966. "default": "'[]'"
  967. },
  968. "blocked_by": {
  969. "name": "blocked_by",
  970. "type": "text",
  971. "primaryKey": false,
  972. "notNull": false,
  973. "autoincrement": false
  974. },
  975. "limits": {
  976. "name": "limits",
  977. "type": "text",
  978. "primaryKey": false,
  979. "notNull": true,
  980. "autoincrement": false
  981. },
  982. "lead_runs": {
  983. "name": "lead_runs",
  984. "type": "integer",
  985. "primaryKey": false,
  986. "notNull": true,
  987. "autoincrement": false,
  988. "default": 0
  989. },
  990. "run_ids": {
  991. "name": "run_ids",
  992. "type": "text",
  993. "primaryKey": false,
  994. "notNull": true,
  995. "autoincrement": false,
  996. "default": "'[]'"
  997. },
  998. "created_at": {
  999. "name": "created_at",
  1000. "type": "text",
  1001. "primaryKey": false,
  1002. "notNull": true,
  1003. "autoincrement": false,
  1004. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1005. },
  1006. "ended_at": {
  1007. "name": "ended_at",
  1008. "type": "text",
  1009. "primaryKey": false,
  1010. "notNull": false,
  1011. "autoincrement": false
  1012. }
  1013. },
  1014. "indexes": {
  1015. "jobs_team_idx": {
  1016. "name": "jobs_team_idx",
  1017. "columns": [
  1018. "team_id",
  1019. "no"
  1020. ],
  1021. "isUnique": false
  1022. }
  1023. },
  1024. "foreignKeys": {},
  1025. "compositePrimaryKeys": {},
  1026. "uniqueConstraints": {},
  1027. "checkConstraints": {}
  1028. },
  1029. "knowledge_roots": {
  1030. "name": "knowledge_roots",
  1031. "columns": {
  1032. "id": {
  1033. "name": "id",
  1034. "type": "text",
  1035. "primaryKey": true,
  1036. "notNull": true,
  1037. "autoincrement": false
  1038. },
  1039. "name": {
  1040. "name": "name",
  1041. "type": "text",
  1042. "primaryKey": false,
  1043. "notNull": true,
  1044. "autoincrement": false
  1045. },
  1046. "path": {
  1047. "name": "path",
  1048. "type": "text",
  1049. "primaryKey": false,
  1050. "notNull": true,
  1051. "autoincrement": false
  1052. },
  1053. "description": {
  1054. "name": "description",
  1055. "type": "text",
  1056. "primaryKey": false,
  1057. "notNull": true,
  1058. "autoincrement": false,
  1059. "default": "''"
  1060. },
  1061. "access": {
  1062. "name": "access",
  1063. "type": "text",
  1064. "primaryKey": false,
  1065. "notNull": true,
  1066. "autoincrement": false,
  1067. "default": "'read'"
  1068. },
  1069. "enabled": {
  1070. "name": "enabled",
  1071. "type": "integer",
  1072. "primaryKey": false,
  1073. "notNull": true,
  1074. "autoincrement": false,
  1075. "default": true
  1076. },
  1077. "created_at": {
  1078. "name": "created_at",
  1079. "type": "text",
  1080. "primaryKey": false,
  1081. "notNull": true,
  1082. "autoincrement": false,
  1083. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1084. },
  1085. "updated_at": {
  1086. "name": "updated_at",
  1087. "type": "text",
  1088. "primaryKey": false,
  1089. "notNull": true,
  1090. "autoincrement": false,
  1091. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1092. }
  1093. },
  1094. "indexes": {},
  1095. "foreignKeys": {},
  1096. "compositePrimaryKeys": {},
  1097. "uniqueConstraints": {},
  1098. "checkConstraints": {}
  1099. },
  1100. "mcp_servers": {
  1101. "name": "mcp_servers",
  1102. "columns": {
  1103. "id": {
  1104. "name": "id",
  1105. "type": "text",
  1106. "primaryKey": true,
  1107. "notNull": true,
  1108. "autoincrement": false
  1109. },
  1110. "name": {
  1111. "name": "name",
  1112. "type": "text",
  1113. "primaryKey": false,
  1114. "notNull": true,
  1115. "autoincrement": false
  1116. },
  1117. "title": {
  1118. "name": "title",
  1119. "type": "text",
  1120. "primaryKey": false,
  1121. "notNull": true,
  1122. "autoincrement": false
  1123. },
  1124. "description": {
  1125. "name": "description",
  1126. "type": "text",
  1127. "primaryKey": false,
  1128. "notNull": true,
  1129. "autoincrement": false,
  1130. "default": "''"
  1131. },
  1132. "transport": {
  1133. "name": "transport",
  1134. "type": "text",
  1135. "primaryKey": false,
  1136. "notNull": true,
  1137. "autoincrement": false
  1138. },
  1139. "enabled": {
  1140. "name": "enabled",
  1141. "type": "integer",
  1142. "primaryKey": false,
  1143. "notNull": true,
  1144. "autoincrement": false,
  1145. "default": true
  1146. },
  1147. "url": {
  1148. "name": "url",
  1149. "type": "text",
  1150. "primaryKey": false,
  1151. "notNull": true,
  1152. "autoincrement": false,
  1153. "default": "''"
  1154. },
  1155. "headers": {
  1156. "name": "headers",
  1157. "type": "text",
  1158. "primaryKey": false,
  1159. "notNull": true,
  1160. "autoincrement": false,
  1161. "default": "'{}'"
  1162. },
  1163. "command": {
  1164. "name": "command",
  1165. "type": "text",
  1166. "primaryKey": false,
  1167. "notNull": true,
  1168. "autoincrement": false,
  1169. "default": "''"
  1170. },
  1171. "args": {
  1172. "name": "args",
  1173. "type": "text",
  1174. "primaryKey": false,
  1175. "notNull": true,
  1176. "autoincrement": false,
  1177. "default": "'[]'"
  1178. },
  1179. "env": {
  1180. "name": "env",
  1181. "type": "text",
  1182. "primaryKey": false,
  1183. "notNull": true,
  1184. "autoincrement": false,
  1185. "default": "'{}'"
  1186. },
  1187. "allow_network": {
  1188. "name": "allow_network",
  1189. "type": "integer",
  1190. "primaryKey": false,
  1191. "notNull": true,
  1192. "autoincrement": false,
  1193. "default": false
  1194. },
  1195. "read_paths": {
  1196. "name": "read_paths",
  1197. "type": "text",
  1198. "primaryKey": false,
  1199. "notNull": true,
  1200. "autoincrement": false,
  1201. "default": "'[]'"
  1202. },
  1203. "write_paths": {
  1204. "name": "write_paths",
  1205. "type": "text",
  1206. "primaryKey": false,
  1207. "notNull": true,
  1208. "autoincrement": false,
  1209. "default": "'[]'"
  1210. },
  1211. "tool_policies": {
  1212. "name": "tool_policies",
  1213. "type": "text",
  1214. "primaryKey": false,
  1215. "notNull": true,
  1216. "autoincrement": false,
  1217. "default": "'{}'"
  1218. },
  1219. "background_tools": {
  1220. "name": "background_tools",
  1221. "type": "text",
  1222. "primaryKey": false,
  1223. "notNull": true,
  1224. "autoincrement": false,
  1225. "default": "'[]'"
  1226. },
  1227. "tools_cache": {
  1228. "name": "tools_cache",
  1229. "type": "text",
  1230. "primaryKey": false,
  1231. "notNull": true,
  1232. "autoincrement": false,
  1233. "default": "'[]'"
  1234. },
  1235. "tools_updated_at": {
  1236. "name": "tools_updated_at",
  1237. "type": "text",
  1238. "primaryKey": false,
  1239. "notNull": false,
  1240. "autoincrement": false
  1241. },
  1242. "created_at": {
  1243. "name": "created_at",
  1244. "type": "text",
  1245. "primaryKey": false,
  1246. "notNull": true,
  1247. "autoincrement": false,
  1248. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1249. },
  1250. "updated_at": {
  1251. "name": "updated_at",
  1252. "type": "text",
  1253. "primaryKey": false,
  1254. "notNull": true,
  1255. "autoincrement": false,
  1256. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1257. }
  1258. },
  1259. "indexes": {
  1260. "mcp_servers_name_unique": {
  1261. "name": "mcp_servers_name_unique",
  1262. "columns": [
  1263. "name"
  1264. ],
  1265. "isUnique": true
  1266. }
  1267. },
  1268. "foreignKeys": {},
  1269. "compositePrimaryKeys": {},
  1270. "uniqueConstraints": {},
  1271. "checkConstraints": {}
  1272. },
  1273. "profile_versions": {
  1274. "name": "profile_versions",
  1275. "columns": {
  1276. "profile_id": {
  1277. "name": "profile_id",
  1278. "type": "text",
  1279. "primaryKey": false,
  1280. "notNull": true,
  1281. "autoincrement": false
  1282. },
  1283. "version": {
  1284. "name": "version",
  1285. "type": "integer",
  1286. "primaryKey": false,
  1287. "notNull": true,
  1288. "autoincrement": false
  1289. },
  1290. "snapshot": {
  1291. "name": "snapshot",
  1292. "type": "text",
  1293. "primaryKey": false,
  1294. "notNull": true,
  1295. "autoincrement": false
  1296. },
  1297. "created_at": {
  1298. "name": "created_at",
  1299. "type": "text",
  1300. "primaryKey": false,
  1301. "notNull": true,
  1302. "autoincrement": false,
  1303. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1304. }
  1305. },
  1306. "indexes": {},
  1307. "foreignKeys": {},
  1308. "compositePrimaryKeys": {
  1309. "profile_versions_profile_id_version_pk": {
  1310. "columns": [
  1311. "profile_id",
  1312. "version"
  1313. ],
  1314. "name": "profile_versions_profile_id_version_pk"
  1315. }
  1316. },
  1317. "uniqueConstraints": {},
  1318. "checkConstraints": {}
  1319. },
  1320. "profiles": {
  1321. "name": "profiles",
  1322. "columns": {
  1323. "id": {
  1324. "name": "id",
  1325. "type": "text",
  1326. "primaryKey": true,
  1327. "notNull": true,
  1328. "autoincrement": false
  1329. },
  1330. "name": {
  1331. "name": "name",
  1332. "type": "text",
  1333. "primaryKey": false,
  1334. "notNull": true,
  1335. "autoincrement": false
  1336. },
  1337. "description": {
  1338. "name": "description",
  1339. "type": "text",
  1340. "primaryKey": false,
  1341. "notNull": true,
  1342. "autoincrement": false,
  1343. "default": "''"
  1344. },
  1345. "provider": {
  1346. "name": "provider",
  1347. "type": "text",
  1348. "primaryKey": false,
  1349. "notNull": true,
  1350. "autoincrement": false
  1351. },
  1352. "model": {
  1353. "name": "model",
  1354. "type": "text",
  1355. "primaryKey": false,
  1356. "notNull": true,
  1357. "autoincrement": false
  1358. },
  1359. "system_prompt": {
  1360. "name": "system_prompt",
  1361. "type": "text",
  1362. "primaryKey": false,
  1363. "notNull": true,
  1364. "autoincrement": false,
  1365. "default": "''"
  1366. },
  1367. "permission_mode": {
  1368. "name": "permission_mode",
  1369. "type": "text",
  1370. "primaryKey": false,
  1371. "notNull": true,
  1372. "autoincrement": false,
  1373. "default": "'ask'"
  1374. },
  1375. "allowed_tools": {
  1376. "name": "allowed_tools",
  1377. "type": "text",
  1378. "primaryKey": false,
  1379. "notNull": true,
  1380. "autoincrement": false,
  1381. "default": "'[]'"
  1382. },
  1383. "disallowed_tools": {
  1384. "name": "disallowed_tools",
  1385. "type": "text",
  1386. "primaryKey": false,
  1387. "notNull": true,
  1388. "autoincrement": false,
  1389. "default": "'[]'"
  1390. },
  1391. "skills": {
  1392. "name": "skills",
  1393. "type": "text",
  1394. "primaryKey": false,
  1395. "notNull": true,
  1396. "autoincrement": false,
  1397. "default": "'\"all\"'"
  1398. },
  1399. "file_access": {
  1400. "name": "file_access",
  1401. "type": "text",
  1402. "primaryKey": false,
  1403. "notNull": true,
  1404. "autoincrement": false
  1405. },
  1406. "knowledge_root_ids": {
  1407. "name": "knowledge_root_ids",
  1408. "type": "text",
  1409. "primaryKey": false,
  1410. "notNull": true,
  1411. "autoincrement": false,
  1412. "default": "'[]'"
  1413. },
  1414. "mcp_server_ids": {
  1415. "name": "mcp_server_ids",
  1416. "type": "text",
  1417. "primaryKey": false,
  1418. "notNull": true,
  1419. "autoincrement": false,
  1420. "default": "'[]'"
  1421. },
  1422. "is_default": {
  1423. "name": "is_default",
  1424. "type": "integer",
  1425. "primaryKey": false,
  1426. "notNull": true,
  1427. "autoincrement": false,
  1428. "default": false
  1429. },
  1430. "builtin": {
  1431. "name": "builtin",
  1432. "type": "integer",
  1433. "primaryKey": false,
  1434. "notNull": true,
  1435. "autoincrement": false,
  1436. "default": false
  1437. },
  1438. "builtin_key": {
  1439. "name": "builtin_key",
  1440. "type": "text",
  1441. "primaryKey": false,
  1442. "notNull": false,
  1443. "autoincrement": false
  1444. },
  1445. "version": {
  1446. "name": "version",
  1447. "type": "integer",
  1448. "primaryKey": false,
  1449. "notNull": true,
  1450. "autoincrement": false,
  1451. "default": 1
  1452. },
  1453. "created_at": {
  1454. "name": "created_at",
  1455. "type": "text",
  1456. "primaryKey": false,
  1457. "notNull": true,
  1458. "autoincrement": false,
  1459. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1460. },
  1461. "updated_at": {
  1462. "name": "updated_at",
  1463. "type": "text",
  1464. "primaryKey": false,
  1465. "notNull": true,
  1466. "autoincrement": false,
  1467. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1468. }
  1469. },
  1470. "indexes": {},
  1471. "foreignKeys": {},
  1472. "compositePrimaryKeys": {},
  1473. "uniqueConstraints": {},
  1474. "checkConstraints": {}
  1475. },
  1476. "runs": {
  1477. "name": "runs",
  1478. "columns": {
  1479. "id": {
  1480. "name": "id",
  1481. "type": "text",
  1482. "primaryKey": true,
  1483. "notNull": true,
  1484. "autoincrement": false
  1485. },
  1486. "session_id": {
  1487. "name": "session_id",
  1488. "type": "text",
  1489. "primaryKey": false,
  1490. "notNull": true,
  1491. "autoincrement": false
  1492. },
  1493. "status": {
  1494. "name": "status",
  1495. "type": "text",
  1496. "primaryKey": false,
  1497. "notNull": true,
  1498. "autoincrement": false
  1499. },
  1500. "started_at": {
  1501. "name": "started_at",
  1502. "type": "text",
  1503. "primaryKey": false,
  1504. "notNull": false,
  1505. "autoincrement": false
  1506. },
  1507. "ended_at": {
  1508. "name": "ended_at",
  1509. "type": "text",
  1510. "primaryKey": false,
  1511. "notNull": false,
  1512. "autoincrement": false
  1513. },
  1514. "input_tokens": {
  1515. "name": "input_tokens",
  1516. "type": "integer",
  1517. "primaryKey": false,
  1518. "notNull": false,
  1519. "autoincrement": false
  1520. },
  1521. "output_tokens": {
  1522. "name": "output_tokens",
  1523. "type": "integer",
  1524. "primaryKey": false,
  1525. "notNull": false,
  1526. "autoincrement": false
  1527. },
  1528. "cache_read_tokens": {
  1529. "name": "cache_read_tokens",
  1530. "type": "integer",
  1531. "primaryKey": false,
  1532. "notNull": false,
  1533. "autoincrement": false
  1534. },
  1535. "cache_write_tokens": {
  1536. "name": "cache_write_tokens",
  1537. "type": "integer",
  1538. "primaryKey": false,
  1539. "notNull": false,
  1540. "autoincrement": false
  1541. },
  1542. "cost_usd": {
  1543. "name": "cost_usd",
  1544. "type": "real",
  1545. "primaryKey": false,
  1546. "notNull": false,
  1547. "autoincrement": false
  1548. },
  1549. "context_tokens": {
  1550. "name": "context_tokens",
  1551. "type": "integer",
  1552. "primaryKey": false,
  1553. "notNull": false,
  1554. "autoincrement": false
  1555. },
  1556. "error": {
  1557. "name": "error",
  1558. "type": "text",
  1559. "primaryKey": false,
  1560. "notNull": false,
  1561. "autoincrement": false
  1562. },
  1563. "created_at": {
  1564. "name": "created_at",
  1565. "type": "text",
  1566. "primaryKey": false,
  1567. "notNull": true,
  1568. "autoincrement": false,
  1569. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1570. }
  1571. },
  1572. "indexes": {
  1573. "runs_session_idx": {
  1574. "name": "runs_session_idx",
  1575. "columns": [
  1576. "session_id"
  1577. ],
  1578. "isUnique": false
  1579. }
  1580. },
  1581. "foreignKeys": {},
  1582. "compositePrimaryKeys": {},
  1583. "uniqueConstraints": {},
  1584. "checkConstraints": {}
  1585. },
  1586. "schedule_runs": {
  1587. "name": "schedule_runs",
  1588. "columns": {
  1589. "id": {
  1590. "name": "id",
  1591. "type": "integer",
  1592. "primaryKey": true,
  1593. "notNull": true,
  1594. "autoincrement": true
  1595. },
  1596. "schedule_id": {
  1597. "name": "schedule_id",
  1598. "type": "text",
  1599. "primaryKey": false,
  1600. "notNull": true,
  1601. "autoincrement": false
  1602. },
  1603. "ts": {
  1604. "name": "ts",
  1605. "type": "text",
  1606. "primaryKey": false,
  1607. "notNull": true,
  1608. "autoincrement": false,
  1609. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1610. },
  1611. "outcome": {
  1612. "name": "outcome",
  1613. "type": "text",
  1614. "primaryKey": false,
  1615. "notNull": true,
  1616. "autoincrement": false
  1617. },
  1618. "run_id": {
  1619. "name": "run_id",
  1620. "type": "text",
  1621. "primaryKey": false,
  1622. "notNull": false,
  1623. "autoincrement": false
  1624. },
  1625. "cost_usd": {
  1626. "name": "cost_usd",
  1627. "type": "real",
  1628. "primaryKey": false,
  1629. "notNull": false,
  1630. "autoincrement": false
  1631. },
  1632. "note": {
  1633. "name": "note",
  1634. "type": "text",
  1635. "primaryKey": false,
  1636. "notNull": false,
  1637. "autoincrement": false
  1638. }
  1639. },
  1640. "indexes": {
  1641. "schedule_runs_idx": {
  1642. "name": "schedule_runs_idx",
  1643. "columns": [
  1644. "schedule_id",
  1645. "id"
  1646. ],
  1647. "isUnique": false
  1648. }
  1649. },
  1650. "foreignKeys": {},
  1651. "compositePrimaryKeys": {},
  1652. "uniqueConstraints": {},
  1653. "checkConstraints": {}
  1654. },
  1655. "schedules": {
  1656. "name": "schedules",
  1657. "columns": {
  1658. "id": {
  1659. "name": "id",
  1660. "type": "text",
  1661. "primaryKey": true,
  1662. "notNull": true,
  1663. "autoincrement": false
  1664. },
  1665. "session_id": {
  1666. "name": "session_id",
  1667. "type": "text",
  1668. "primaryKey": false,
  1669. "notNull": false,
  1670. "autoincrement": false
  1671. },
  1672. "team_id": {
  1673. "name": "team_id",
  1674. "type": "text",
  1675. "primaryKey": false,
  1676. "notNull": false,
  1677. "autoincrement": false
  1678. },
  1679. "created_by_bot_id": {
  1680. "name": "created_by_bot_id",
  1681. "type": "text",
  1682. "primaryKey": false,
  1683. "notNull": false,
  1684. "autoincrement": false
  1685. },
  1686. "title": {
  1687. "name": "title",
  1688. "type": "text",
  1689. "primaryKey": false,
  1690. "notNull": true,
  1691. "autoincrement": false
  1692. },
  1693. "prompt": {
  1694. "name": "prompt",
  1695. "type": "text",
  1696. "primaryKey": false,
  1697. "notNull": true,
  1698. "autoincrement": false
  1699. },
  1700. "spec": {
  1701. "name": "spec",
  1702. "type": "text",
  1703. "primaryKey": false,
  1704. "notNull": true,
  1705. "autoincrement": false
  1706. },
  1707. "timezone": {
  1708. "name": "timezone",
  1709. "type": "text",
  1710. "primaryKey": false,
  1711. "notNull": true,
  1712. "autoincrement": false
  1713. },
  1714. "status": {
  1715. "name": "status",
  1716. "type": "text",
  1717. "primaryKey": false,
  1718. "notNull": true,
  1719. "autoincrement": false,
  1720. "default": "'active'"
  1721. },
  1722. "status_note": {
  1723. "name": "status_note",
  1724. "type": "text",
  1725. "primaryKey": false,
  1726. "notNull": false,
  1727. "autoincrement": false
  1728. },
  1729. "next_run_at": {
  1730. "name": "next_run_at",
  1731. "type": "text",
  1732. "primaryKey": false,
  1733. "notNull": false,
  1734. "autoincrement": false
  1735. },
  1736. "last_run_at": {
  1737. "name": "last_run_at",
  1738. "type": "text",
  1739. "primaryKey": false,
  1740. "notNull": false,
  1741. "autoincrement": false
  1742. },
  1743. "last_outcome": {
  1744. "name": "last_outcome",
  1745. "type": "text",
  1746. "primaryKey": false,
  1747. "notNull": false,
  1748. "autoincrement": false
  1749. },
  1750. "run_count": {
  1751. "name": "run_count",
  1752. "type": "integer",
  1753. "primaryKey": false,
  1754. "notNull": true,
  1755. "autoincrement": false,
  1756. "default": 0
  1757. },
  1758. "created_at": {
  1759. "name": "created_at",
  1760. "type": "text",
  1761. "primaryKey": false,
  1762. "notNull": true,
  1763. "autoincrement": false,
  1764. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1765. },
  1766. "updated_at": {
  1767. "name": "updated_at",
  1768. "type": "text",
  1769. "primaryKey": false,
  1770. "notNull": true,
  1771. "autoincrement": false,
  1772. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1773. }
  1774. },
  1775. "indexes": {
  1776. "schedules_due_idx": {
  1777. "name": "schedules_due_idx",
  1778. "columns": [
  1779. "status",
  1780. "next_run_at"
  1781. ],
  1782. "isUnique": false
  1783. },
  1784. "schedules_session_idx": {
  1785. "name": "schedules_session_idx",
  1786. "columns": [
  1787. "session_id"
  1788. ],
  1789. "isUnique": false
  1790. },
  1791. "schedules_team_idx": {
  1792. "name": "schedules_team_idx",
  1793. "columns": [
  1794. "team_id"
  1795. ],
  1796. "isUnique": false
  1797. }
  1798. },
  1799. "foreignKeys": {},
  1800. "compositePrimaryKeys": {},
  1801. "uniqueConstraints": {},
  1802. "checkConstraints": {}
  1803. },
  1804. "sessions": {
  1805. "name": "sessions",
  1806. "columns": {
  1807. "id": {
  1808. "name": "id",
  1809. "type": "text",
  1810. "primaryKey": true,
  1811. "notNull": true,
  1812. "autoincrement": false
  1813. },
  1814. "source": {
  1815. "name": "source",
  1816. "type": "text",
  1817. "primaryKey": false,
  1818. "notNull": true,
  1819. "autoincrement": false
  1820. },
  1821. "profile_id": {
  1822. "name": "profile_id",
  1823. "type": "text",
  1824. "primaryKey": false,
  1825. "notNull": false,
  1826. "autoincrement": false
  1827. },
  1828. "provider": {
  1829. "name": "provider",
  1830. "type": "text",
  1831. "primaryKey": false,
  1832. "notNull": true,
  1833. "autoincrement": false
  1834. },
  1835. "model": {
  1836. "name": "model",
  1837. "type": "text",
  1838. "primaryKey": false,
  1839. "notNull": true,
  1840. "autoincrement": false
  1841. },
  1842. "permission_mode": {
  1843. "name": "permission_mode",
  1844. "type": "text",
  1845. "primaryKey": false,
  1846. "notNull": false,
  1847. "autoincrement": false
  1848. },
  1849. "system_prompt_append": {
  1850. "name": "system_prompt_append",
  1851. "type": "text",
  1852. "primaryKey": false,
  1853. "notNull": true,
  1854. "autoincrement": false,
  1855. "default": "''"
  1856. },
  1857. "provider_session_id": {
  1858. "name": "provider_session_id",
  1859. "type": "text",
  1860. "primaryKey": false,
  1861. "notNull": false,
  1862. "autoincrement": false
  1863. },
  1864. "workspace_dir": {
  1865. "name": "workspace_dir",
  1866. "type": "text",
  1867. "primaryKey": false,
  1868. "notNull": true,
  1869. "autoincrement": false
  1870. },
  1871. "title": {
  1872. "name": "title",
  1873. "type": "text",
  1874. "primaryKey": false,
  1875. "notNull": true,
  1876. "autoincrement": false,
  1877. "default": "''"
  1878. },
  1879. "last_seq": {
  1880. "name": "last_seq",
  1881. "type": "integer",
  1882. "primaryKey": false,
  1883. "notNull": true,
  1884. "autoincrement": false,
  1885. "default": 0
  1886. },
  1887. "archived": {
  1888. "name": "archived",
  1889. "type": "integer",
  1890. "primaryKey": false,
  1891. "notNull": true,
  1892. "autoincrement": false,
  1893. "default": false
  1894. },
  1895. "created_at": {
  1896. "name": "created_at",
  1897. "type": "text",
  1898. "primaryKey": false,
  1899. "notNull": true,
  1900. "autoincrement": false,
  1901. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1902. },
  1903. "updated_at": {
  1904. "name": "updated_at",
  1905. "type": "text",
  1906. "primaryKey": false,
  1907. "notNull": true,
  1908. "autoincrement": false,
  1909. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1910. }
  1911. },
  1912. "indexes": {
  1913. "sessions_source_idx": {
  1914. "name": "sessions_source_idx",
  1915. "columns": [
  1916. "source",
  1917. "updated_at"
  1918. ],
  1919. "isUnique": false
  1920. }
  1921. },
  1922. "foreignKeys": {},
  1923. "compositePrimaryKeys": {},
  1924. "uniqueConstraints": {},
  1925. "checkConstraints": {}
  1926. },
  1927. "settings": {
  1928. "name": "settings",
  1929. "columns": {
  1930. "key": {
  1931. "name": "key",
  1932. "type": "text",
  1933. "primaryKey": true,
  1934. "notNull": true,
  1935. "autoincrement": false
  1936. },
  1937. "value": {
  1938. "name": "value",
  1939. "type": "text",
  1940. "primaryKey": false,
  1941. "notNull": true,
  1942. "autoincrement": false
  1943. },
  1944. "updated_at": {
  1945. "name": "updated_at",
  1946. "type": "text",
  1947. "primaryKey": false,
  1948. "notNull": true,
  1949. "autoincrement": false,
  1950. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  1951. }
  1952. },
  1953. "indexes": {},
  1954. "foreignKeys": {},
  1955. "compositePrimaryKeys": {},
  1956. "uniqueConstraints": {},
  1957. "checkConstraints": {}
  1958. },
  1959. "skill_sources": {
  1960. "name": "skill_sources",
  1961. "columns": {
  1962. "id": {
  1963. "name": "id",
  1964. "type": "text",
  1965. "primaryKey": true,
  1966. "notNull": true,
  1967. "autoincrement": false
  1968. },
  1969. "name": {
  1970. "name": "name",
  1971. "type": "text",
  1972. "primaryKey": false,
  1973. "notNull": true,
  1974. "autoincrement": false
  1975. },
  1976. "description": {
  1977. "name": "description",
  1978. "type": "text",
  1979. "primaryKey": false,
  1980. "notNull": true,
  1981. "autoincrement": false,
  1982. "default": "''"
  1983. },
  1984. "kind": {
  1985. "name": "kind",
  1986. "type": "text",
  1987. "primaryKey": false,
  1988. "notNull": true,
  1989. "autoincrement": false
  1990. },
  1991. "path": {
  1992. "name": "path",
  1993. "type": "text",
  1994. "primaryKey": false,
  1995. "notNull": true,
  1996. "autoincrement": false
  1997. },
  1998. "sync_mode": {
  1999. "name": "sync_mode",
  2000. "type": "text",
  2001. "primaryKey": false,
  2002. "notNull": true,
  2003. "autoincrement": false,
  2004. "default": "'manual'"
  2005. },
  2006. "interval_min": {
  2007. "name": "interval_min",
  2008. "type": "integer",
  2009. "primaryKey": false,
  2010. "notNull": true,
  2011. "autoincrement": false,
  2012. "default": 10
  2013. },
  2014. "last_sync_at": {
  2015. "name": "last_sync_at",
  2016. "type": "text",
  2017. "primaryKey": false,
  2018. "notNull": false,
  2019. "autoincrement": false
  2020. },
  2021. "last_sync_digest": {
  2022. "name": "last_sync_digest",
  2023. "type": "text",
  2024. "primaryKey": false,
  2025. "notNull": false,
  2026. "autoincrement": false
  2027. },
  2028. "status": {
  2029. "name": "status",
  2030. "type": "text",
  2031. "primaryKey": false,
  2032. "notNull": true,
  2033. "autoincrement": false,
  2034. "default": "'never'"
  2035. },
  2036. "last_error": {
  2037. "name": "last_error",
  2038. "type": "text",
  2039. "primaryKey": false,
  2040. "notNull": false,
  2041. "autoincrement": false
  2042. },
  2043. "created_at": {
  2044. "name": "created_at",
  2045. "type": "text",
  2046. "primaryKey": false,
  2047. "notNull": true,
  2048. "autoincrement": false,
  2049. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2050. },
  2051. "updated_at": {
  2052. "name": "updated_at",
  2053. "type": "text",
  2054. "primaryKey": false,
  2055. "notNull": true,
  2056. "autoincrement": false,
  2057. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2058. }
  2059. },
  2060. "indexes": {},
  2061. "foreignKeys": {},
  2062. "compositePrimaryKeys": {},
  2063. "uniqueConstraints": {},
  2064. "checkConstraints": {}
  2065. },
  2066. "tasks": {
  2067. "name": "tasks",
  2068. "columns": {
  2069. "id": {
  2070. "name": "id",
  2071. "type": "text",
  2072. "primaryKey": true,
  2073. "notNull": true,
  2074. "autoincrement": false
  2075. },
  2076. "job_id": {
  2077. "name": "job_id",
  2078. "type": "text",
  2079. "primaryKey": false,
  2080. "notNull": true,
  2081. "autoincrement": false
  2082. },
  2083. "team_id": {
  2084. "name": "team_id",
  2085. "type": "text",
  2086. "primaryKey": false,
  2087. "notNull": true,
  2088. "autoincrement": false
  2089. },
  2090. "no": {
  2091. "name": "no",
  2092. "type": "integer",
  2093. "primaryKey": false,
  2094. "notNull": true,
  2095. "autoincrement": false
  2096. },
  2097. "bot_id": {
  2098. "name": "bot_id",
  2099. "type": "text",
  2100. "primaryKey": false,
  2101. "notNull": true,
  2102. "autoincrement": false
  2103. },
  2104. "title": {
  2105. "name": "title",
  2106. "type": "text",
  2107. "primaryKey": false,
  2108. "notNull": true,
  2109. "autoincrement": false
  2110. },
  2111. "instructions": {
  2112. "name": "instructions",
  2113. "type": "text",
  2114. "primaryKey": false,
  2115. "notNull": true,
  2116. "autoincrement": false
  2117. },
  2118. "depends_on": {
  2119. "name": "depends_on",
  2120. "type": "text",
  2121. "primaryKey": false,
  2122. "notNull": true,
  2123. "autoincrement": false,
  2124. "default": "'[]'"
  2125. },
  2126. "status": {
  2127. "name": "status",
  2128. "type": "text",
  2129. "primaryKey": false,
  2130. "notNull": true,
  2131. "autoincrement": false
  2132. },
  2133. "follow_up": {
  2134. "name": "follow_up",
  2135. "type": "text",
  2136. "primaryKey": false,
  2137. "notNull": false,
  2138. "autoincrement": false
  2139. },
  2140. "result": {
  2141. "name": "result",
  2142. "type": "text",
  2143. "primaryKey": false,
  2144. "notNull": false,
  2145. "autoincrement": false
  2146. },
  2147. "files": {
  2148. "name": "files",
  2149. "type": "text",
  2150. "primaryKey": false,
  2151. "notNull": true,
  2152. "autoincrement": false,
  2153. "default": "'[]'"
  2154. },
  2155. "run_id": {
  2156. "name": "run_id",
  2157. "type": "text",
  2158. "primaryKey": false,
  2159. "notNull": false,
  2160. "autoincrement": false
  2161. },
  2162. "session_id": {
  2163. "name": "session_id",
  2164. "type": "text",
  2165. "primaryKey": false,
  2166. "notNull": false,
  2167. "autoincrement": false
  2168. },
  2169. "created_at": {
  2170. "name": "created_at",
  2171. "type": "text",
  2172. "primaryKey": false,
  2173. "notNull": true,
  2174. "autoincrement": false,
  2175. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2176. },
  2177. "started_at": {
  2178. "name": "started_at",
  2179. "type": "text",
  2180. "primaryKey": false,
  2181. "notNull": false,
  2182. "autoincrement": false
  2183. },
  2184. "ended_at": {
  2185. "name": "ended_at",
  2186. "type": "text",
  2187. "primaryKey": false,
  2188. "notNull": false,
  2189. "autoincrement": false
  2190. }
  2191. },
  2192. "indexes": {
  2193. "tasks_team_idx": {
  2194. "name": "tasks_team_idx",
  2195. "columns": [
  2196. "team_id",
  2197. "no"
  2198. ],
  2199. "isUnique": false
  2200. },
  2201. "tasks_job_idx": {
  2202. "name": "tasks_job_idx",
  2203. "columns": [
  2204. "job_id"
  2205. ],
  2206. "isUnique": false
  2207. }
  2208. },
  2209. "foreignKeys": {},
  2210. "compositePrimaryKeys": {},
  2211. "uniqueConstraints": {},
  2212. "checkConstraints": {}
  2213. },
  2214. "team_bot_sessions": {
  2215. "name": "team_bot_sessions",
  2216. "columns": {
  2217. "team_id": {
  2218. "name": "team_id",
  2219. "type": "text",
  2220. "primaryKey": false,
  2221. "notNull": true,
  2222. "autoincrement": false
  2223. },
  2224. "bot_id": {
  2225. "name": "bot_id",
  2226. "type": "text",
  2227. "primaryKey": false,
  2228. "notNull": true,
  2229. "autoincrement": false
  2230. },
  2231. "session_id": {
  2232. "name": "session_id",
  2233. "type": "text",
  2234. "primaryKey": false,
  2235. "notNull": true,
  2236. "autoincrement": false
  2237. },
  2238. "last_read_seq": {
  2239. "name": "last_read_seq",
  2240. "type": "integer",
  2241. "primaryKey": false,
  2242. "notNull": true,
  2243. "autoincrement": false,
  2244. "default": 0
  2245. },
  2246. "reset_requested": {
  2247. "name": "reset_requested",
  2248. "type": "integer",
  2249. "primaryKey": false,
  2250. "notNull": true,
  2251. "autoincrement": false,
  2252. "default": false
  2253. }
  2254. },
  2255. "indexes": {
  2256. "team_bot_sessions_session_id_unique": {
  2257. "name": "team_bot_sessions_session_id_unique",
  2258. "columns": [
  2259. "session_id"
  2260. ],
  2261. "isUnique": true
  2262. }
  2263. },
  2264. "foreignKeys": {},
  2265. "compositePrimaryKeys": {
  2266. "team_bot_sessions_team_id_bot_id_pk": {
  2267. "columns": [
  2268. "team_id",
  2269. "bot_id"
  2270. ],
  2271. "name": "team_bot_sessions_team_id_bot_id_pk"
  2272. }
  2273. },
  2274. "uniqueConstraints": {},
  2275. "checkConstraints": {}
  2276. },
  2277. "team_bots": {
  2278. "name": "team_bots",
  2279. "columns": {
  2280. "team_id": {
  2281. "name": "team_id",
  2282. "type": "text",
  2283. "primaryKey": false,
  2284. "notNull": true,
  2285. "autoincrement": false
  2286. },
  2287. "bot_id": {
  2288. "name": "bot_id",
  2289. "type": "text",
  2290. "primaryKey": false,
  2291. "notNull": true,
  2292. "autoincrement": false
  2293. },
  2294. "role": {
  2295. "name": "role",
  2296. "type": "text",
  2297. "primaryKey": false,
  2298. "notNull": true,
  2299. "autoincrement": false
  2300. },
  2301. "joined_at": {
  2302. "name": "joined_at",
  2303. "type": "text",
  2304. "primaryKey": false,
  2305. "notNull": true,
  2306. "autoincrement": false,
  2307. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2308. }
  2309. },
  2310. "indexes": {
  2311. "team_bots_bot_idx": {
  2312. "name": "team_bots_bot_idx",
  2313. "columns": [
  2314. "bot_id"
  2315. ],
  2316. "isUnique": false
  2317. }
  2318. },
  2319. "foreignKeys": {},
  2320. "compositePrimaryKeys": {
  2321. "team_bots_team_id_bot_id_pk": {
  2322. "columns": [
  2323. "team_id",
  2324. "bot_id"
  2325. ],
  2326. "name": "team_bots_team_id_bot_id_pk"
  2327. }
  2328. },
  2329. "uniqueConstraints": {},
  2330. "checkConstraints": {}
  2331. },
  2332. "team_cases": {
  2333. "name": "team_cases",
  2334. "columns": {
  2335. "id": {
  2336. "name": "id",
  2337. "type": "text",
  2338. "primaryKey": true,
  2339. "notNull": true,
  2340. "autoincrement": false
  2341. },
  2342. "name": {
  2343. "name": "name",
  2344. "type": "text",
  2345. "primaryKey": false,
  2346. "notNull": true,
  2347. "autoincrement": false
  2348. },
  2349. "lead_bot_id": {
  2350. "name": "lead_bot_id",
  2351. "type": "text",
  2352. "primaryKey": false,
  2353. "notNull": false,
  2354. "autoincrement": false
  2355. },
  2356. "worker_bot_ids": {
  2357. "name": "worker_bot_ids",
  2358. "type": "text",
  2359. "primaryKey": false,
  2360. "notNull": true,
  2361. "autoincrement": false,
  2362. "default": "'[]'"
  2363. },
  2364. "stub_bot_ids": {
  2365. "name": "stub_bot_ids",
  2366. "type": "text",
  2367. "primaryKey": false,
  2368. "notNull": true,
  2369. "autoincrement": false,
  2370. "default": "'[]'"
  2371. },
  2372. "limits": {
  2373. "name": "limits",
  2374. "type": "text",
  2375. "primaryKey": false,
  2376. "notNull": false,
  2377. "autoincrement": false
  2378. },
  2379. "human_name": {
  2380. "name": "human_name",
  2381. "type": "text",
  2382. "primaryKey": false,
  2383. "notNull": true,
  2384. "autoincrement": false
  2385. },
  2386. "text": {
  2387. "name": "text",
  2388. "type": "text",
  2389. "primaryKey": false,
  2390. "notNull": true,
  2391. "autoincrement": false
  2392. },
  2393. "mentions": {
  2394. "name": "mentions",
  2395. "type": "text",
  2396. "primaryKey": false,
  2397. "notNull": true,
  2398. "autoincrement": false,
  2399. "default": "'[]'"
  2400. },
  2401. "files": {
  2402. "name": "files",
  2403. "type": "text",
  2404. "primaryKey": false,
  2405. "notNull": true,
  2406. "autoincrement": false,
  2407. "default": "'[]'"
  2408. },
  2409. "created_at": {
  2410. "name": "created_at",
  2411. "type": "text",
  2412. "primaryKey": false,
  2413. "notNull": true,
  2414. "autoincrement": false,
  2415. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2416. },
  2417. "updated_at": {
  2418. "name": "updated_at",
  2419. "type": "text",
  2420. "primaryKey": false,
  2421. "notNull": true,
  2422. "autoincrement": false,
  2423. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2424. }
  2425. },
  2426. "indexes": {},
  2427. "foreignKeys": {},
  2428. "compositePrimaryKeys": {},
  2429. "uniqueConstraints": {},
  2430. "checkConstraints": {}
  2431. },
  2432. "team_events": {
  2433. "name": "team_events",
  2434. "columns": {
  2435. "team_id": {
  2436. "name": "team_id",
  2437. "type": "text",
  2438. "primaryKey": false,
  2439. "notNull": true,
  2440. "autoincrement": false
  2441. },
  2442. "seq": {
  2443. "name": "seq",
  2444. "type": "integer",
  2445. "primaryKey": false,
  2446. "notNull": true,
  2447. "autoincrement": false
  2448. },
  2449. "type": {
  2450. "name": "type",
  2451. "type": "text",
  2452. "primaryKey": false,
  2453. "notNull": true,
  2454. "autoincrement": false
  2455. },
  2456. "payload": {
  2457. "name": "payload",
  2458. "type": "text",
  2459. "primaryKey": false,
  2460. "notNull": true,
  2461. "autoincrement": false
  2462. },
  2463. "ts": {
  2464. "name": "ts",
  2465. "type": "text",
  2466. "primaryKey": false,
  2467. "notNull": true,
  2468. "autoincrement": false
  2469. }
  2470. },
  2471. "indexes": {},
  2472. "foreignKeys": {},
  2473. "compositePrimaryKeys": {
  2474. "team_events_team_id_seq_pk": {
  2475. "columns": [
  2476. "team_id",
  2477. "seq"
  2478. ],
  2479. "name": "team_events_team_id_seq_pk"
  2480. }
  2481. },
  2482. "uniqueConstraints": {},
  2483. "checkConstraints": {}
  2484. },
  2485. "teams": {
  2486. "name": "teams",
  2487. "columns": {
  2488. "id": {
  2489. "name": "id",
  2490. "type": "text",
  2491. "primaryKey": true,
  2492. "notNull": true,
  2493. "autoincrement": false
  2494. },
  2495. "source": {
  2496. "name": "source",
  2497. "type": "text",
  2498. "primaryKey": false,
  2499. "notNull": true,
  2500. "autoincrement": false
  2501. },
  2502. "title": {
  2503. "name": "title",
  2504. "type": "text",
  2505. "primaryKey": false,
  2506. "notNull": true,
  2507. "autoincrement": false,
  2508. "default": "''"
  2509. },
  2510. "human": {
  2511. "name": "human",
  2512. "type": "text",
  2513. "primaryKey": false,
  2514. "notNull": true,
  2515. "autoincrement": false
  2516. },
  2517. "status": {
  2518. "name": "status",
  2519. "type": "text",
  2520. "primaryKey": false,
  2521. "notNull": true,
  2522. "autoincrement": false,
  2523. "default": "'active'"
  2524. },
  2525. "workspace_dir": {
  2526. "name": "workspace_dir",
  2527. "type": "text",
  2528. "primaryKey": false,
  2529. "notNull": true,
  2530. "autoincrement": false
  2531. },
  2532. "limits": {
  2533. "name": "limits",
  2534. "type": "text",
  2535. "primaryKey": false,
  2536. "notNull": false,
  2537. "autoincrement": false
  2538. },
  2539. "debug": {
  2540. "name": "debug",
  2541. "type": "text",
  2542. "primaryKey": false,
  2543. "notNull": true,
  2544. "autoincrement": false,
  2545. "default": "'{\"stepMode\":false,\"stubBotIds\":[]}'"
  2546. },
  2547. "last_seq": {
  2548. "name": "last_seq",
  2549. "type": "integer",
  2550. "primaryKey": false,
  2551. "notNull": true,
  2552. "autoincrement": false,
  2553. "default": 0
  2554. },
  2555. "case_id": {
  2556. "name": "case_id",
  2557. "type": "text",
  2558. "primaryKey": false,
  2559. "notNull": false,
  2560. "autoincrement": false
  2561. },
  2562. "created_at": {
  2563. "name": "created_at",
  2564. "type": "text",
  2565. "primaryKey": false,
  2566. "notNull": true,
  2567. "autoincrement": false,
  2568. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2569. },
  2570. "updated_at": {
  2571. "name": "updated_at",
  2572. "type": "text",
  2573. "primaryKey": false,
  2574. "notNull": true,
  2575. "autoincrement": false,
  2576. "default": "(strftime('%Y-%m-%dT%H:%M:%fZ','now'))"
  2577. }
  2578. },
  2579. "indexes": {
  2580. "teams_source_idx": {
  2581. "name": "teams_source_idx",
  2582. "columns": [
  2583. "source",
  2584. "updated_at"
  2585. ],
  2586. "isUnique": false
  2587. },
  2588. "teams_case_idx": {
  2589. "name": "teams_case_idx",
  2590. "columns": [
  2591. "case_id"
  2592. ],
  2593. "isUnique": false
  2594. }
  2595. },
  2596. "foreignKeys": {},
  2597. "compositePrimaryKeys": {},
  2598. "uniqueConstraints": {},
  2599. "checkConstraints": {}
  2600. },
  2601. "usage_daily": {
  2602. "name": "usage_daily",
  2603. "columns": {
  2604. "date": {
  2605. "name": "date",
  2606. "type": "text",
  2607. "primaryKey": false,
  2608. "notNull": true,
  2609. "autoincrement": false
  2610. },
  2611. "source": {
  2612. "name": "source",
  2613. "type": "text",
  2614. "primaryKey": false,
  2615. "notNull": true,
  2616. "autoincrement": false
  2617. },
  2618. "provider": {
  2619. "name": "provider",
  2620. "type": "text",
  2621. "primaryKey": false,
  2622. "notNull": true,
  2623. "autoincrement": false
  2624. },
  2625. "model": {
  2626. "name": "model",
  2627. "type": "text",
  2628. "primaryKey": false,
  2629. "notNull": true,
  2630. "autoincrement": false
  2631. },
  2632. "runs": {
  2633. "name": "runs",
  2634. "type": "integer",
  2635. "primaryKey": false,
  2636. "notNull": true,
  2637. "autoincrement": false,
  2638. "default": 0
  2639. },
  2640. "failed": {
  2641. "name": "failed",
  2642. "type": "integer",
  2643. "primaryKey": false,
  2644. "notNull": true,
  2645. "autoincrement": false,
  2646. "default": 0
  2647. },
  2648. "interrupted": {
  2649. "name": "interrupted",
  2650. "type": "integer",
  2651. "primaryKey": false,
  2652. "notNull": true,
  2653. "autoincrement": false,
  2654. "default": 0
  2655. },
  2656. "input_tokens": {
  2657. "name": "input_tokens",
  2658. "type": "integer",
  2659. "primaryKey": false,
  2660. "notNull": true,
  2661. "autoincrement": false,
  2662. "default": 0
  2663. },
  2664. "output_tokens": {
  2665. "name": "output_tokens",
  2666. "type": "integer",
  2667. "primaryKey": false,
  2668. "notNull": true,
  2669. "autoincrement": false,
  2670. "default": 0
  2671. },
  2672. "cache_read_tokens": {
  2673. "name": "cache_read_tokens",
  2674. "type": "integer",
  2675. "primaryKey": false,
  2676. "notNull": true,
  2677. "autoincrement": false,
  2678. "default": 0
  2679. },
  2680. "cache_write_tokens": {
  2681. "name": "cache_write_tokens",
  2682. "type": "integer",
  2683. "primaryKey": false,
  2684. "notNull": true,
  2685. "autoincrement": false,
  2686. "default": 0
  2687. },
  2688. "cost_usd": {
  2689. "name": "cost_usd",
  2690. "type": "real",
  2691. "primaryKey": false,
  2692. "notNull": true,
  2693. "autoincrement": false,
  2694. "default": 0
  2695. },
  2696. "duration_ms": {
  2697. "name": "duration_ms",
  2698. "type": "integer",
  2699. "primaryKey": false,
  2700. "notNull": true,
  2701. "autoincrement": false,
  2702. "default": 0
  2703. }
  2704. },
  2705. "indexes": {},
  2706. "foreignKeys": {},
  2707. "compositePrimaryKeys": {
  2708. "usage_daily_date_source_provider_model_pk": {
  2709. "columns": [
  2710. "date",
  2711. "source",
  2712. "provider",
  2713. "model"
  2714. ],
  2715. "name": "usage_daily_date_source_provider_model_pk"
  2716. }
  2717. },
  2718. "uniqueConstraints": {},
  2719. "checkConstraints": {}
  2720. }
  2721. },
  2722. "views": {},
  2723. "enums": {},
  2724. "_meta": {
  2725. "schemas": {},
  2726. "tables": {},
  2727. "columns": {}
  2728. },
  2729. "internal": {
  2730. "indexes": {}
  2731. }
  2732. }