97.json 140 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539
  1. {
  2. "formatVersion": 1,
  3. "database": {
  4. "version": 97,
  5. "identityHash": "7eb5b4729e665212e9cddaf3dfac2101",
  6. "entities": [
  7. {
  8. "tableName": "books",
  9. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`bookUrl` TEXT NOT NULL DEFAULT '', `tocUrl` TEXT NOT NULL DEFAULT '', `origin` TEXT NOT NULL DEFAULT 'loc_book', `originName` TEXT NOT NULL DEFAULT '', `name` TEXT NOT NULL DEFAULT '', `author` TEXT NOT NULL DEFAULT '', `kind` TEXT, `customTag` TEXT, `coverUrl` TEXT, `customCoverUrl` TEXT, `intro` TEXT, `customIntro` TEXT, `remark` TEXT, `charset` TEXT, `type` INTEGER NOT NULL DEFAULT 0, `group` INTEGER NOT NULL DEFAULT 0, `latestChapterTitle` TEXT, `latestChapterTime` INTEGER NOT NULL DEFAULT 0, `lastCheckTime` INTEGER NOT NULL DEFAULT 0, `lastCheckCount` INTEGER NOT NULL DEFAULT 0, `totalChapterNum` INTEGER NOT NULL DEFAULT 0, `durChapterTitle` TEXT, `durChapterIndex` INTEGER NOT NULL DEFAULT 0, `durChapterPos` INTEGER NOT NULL DEFAULT 0, `durChapterTime` INTEGER NOT NULL DEFAULT 0, `wordCount` TEXT, `canUpdate` INTEGER NOT NULL DEFAULT 1, `order` INTEGER NOT NULL DEFAULT 0, `originOrder` INTEGER NOT NULL DEFAULT 0, `variable` TEXT, `readConfig` TEXT, `syncTime` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`bookUrl`))",
  10. "fields": [
  11. {
  12. "fieldPath": "bookUrl",
  13. "columnName": "bookUrl",
  14. "affinity": "TEXT",
  15. "notNull": true,
  16. "defaultValue": "''"
  17. },
  18. {
  19. "fieldPath": "tocUrl",
  20. "columnName": "tocUrl",
  21. "affinity": "TEXT",
  22. "notNull": true,
  23. "defaultValue": "''"
  24. },
  25. {
  26. "fieldPath": "origin",
  27. "columnName": "origin",
  28. "affinity": "TEXT",
  29. "notNull": true,
  30. "defaultValue": "'loc_book'"
  31. },
  32. {
  33. "fieldPath": "originName",
  34. "columnName": "originName",
  35. "affinity": "TEXT",
  36. "notNull": true,
  37. "defaultValue": "''"
  38. },
  39. {
  40. "fieldPath": "name",
  41. "columnName": "name",
  42. "affinity": "TEXT",
  43. "notNull": true,
  44. "defaultValue": "''"
  45. },
  46. {
  47. "fieldPath": "author",
  48. "columnName": "author",
  49. "affinity": "TEXT",
  50. "notNull": true,
  51. "defaultValue": "''"
  52. },
  53. {
  54. "fieldPath": "kind",
  55. "columnName": "kind",
  56. "affinity": "TEXT"
  57. },
  58. {
  59. "fieldPath": "customTag",
  60. "columnName": "customTag",
  61. "affinity": "TEXT"
  62. },
  63. {
  64. "fieldPath": "coverUrl",
  65. "columnName": "coverUrl",
  66. "affinity": "TEXT"
  67. },
  68. {
  69. "fieldPath": "customCoverUrl",
  70. "columnName": "customCoverUrl",
  71. "affinity": "TEXT"
  72. },
  73. {
  74. "fieldPath": "intro",
  75. "columnName": "intro",
  76. "affinity": "TEXT"
  77. },
  78. {
  79. "fieldPath": "customIntro",
  80. "columnName": "customIntro",
  81. "affinity": "TEXT"
  82. },
  83. {
  84. "fieldPath": "remark",
  85. "columnName": "remark",
  86. "affinity": "TEXT"
  87. },
  88. {
  89. "fieldPath": "charset",
  90. "columnName": "charset",
  91. "affinity": "TEXT"
  92. },
  93. {
  94. "fieldPath": "type",
  95. "columnName": "type",
  96. "affinity": "INTEGER",
  97. "notNull": true,
  98. "defaultValue": "0"
  99. },
  100. {
  101. "fieldPath": "group",
  102. "columnName": "group",
  103. "affinity": "INTEGER",
  104. "notNull": true,
  105. "defaultValue": "0"
  106. },
  107. {
  108. "fieldPath": "latestChapterTitle",
  109. "columnName": "latestChapterTitle",
  110. "affinity": "TEXT"
  111. },
  112. {
  113. "fieldPath": "latestChapterTime",
  114. "columnName": "latestChapterTime",
  115. "affinity": "INTEGER",
  116. "notNull": true,
  117. "defaultValue": "0"
  118. },
  119. {
  120. "fieldPath": "lastCheckTime",
  121. "columnName": "lastCheckTime",
  122. "affinity": "INTEGER",
  123. "notNull": true,
  124. "defaultValue": "0"
  125. },
  126. {
  127. "fieldPath": "lastCheckCount",
  128. "columnName": "lastCheckCount",
  129. "affinity": "INTEGER",
  130. "notNull": true,
  131. "defaultValue": "0"
  132. },
  133. {
  134. "fieldPath": "totalChapterNum",
  135. "columnName": "totalChapterNum",
  136. "affinity": "INTEGER",
  137. "notNull": true,
  138. "defaultValue": "0"
  139. },
  140. {
  141. "fieldPath": "durChapterTitle",
  142. "columnName": "durChapterTitle",
  143. "affinity": "TEXT"
  144. },
  145. {
  146. "fieldPath": "durChapterIndex",
  147. "columnName": "durChapterIndex",
  148. "affinity": "INTEGER",
  149. "notNull": true,
  150. "defaultValue": "0"
  151. },
  152. {
  153. "fieldPath": "durChapterPos",
  154. "columnName": "durChapterPos",
  155. "affinity": "INTEGER",
  156. "notNull": true,
  157. "defaultValue": "0"
  158. },
  159. {
  160. "fieldPath": "durChapterTime",
  161. "columnName": "durChapterTime",
  162. "affinity": "INTEGER",
  163. "notNull": true,
  164. "defaultValue": "0"
  165. },
  166. {
  167. "fieldPath": "wordCount",
  168. "columnName": "wordCount",
  169. "affinity": "TEXT"
  170. },
  171. {
  172. "fieldPath": "canUpdate",
  173. "columnName": "canUpdate",
  174. "affinity": "INTEGER",
  175. "notNull": true,
  176. "defaultValue": "1"
  177. },
  178. {
  179. "fieldPath": "order",
  180. "columnName": "order",
  181. "affinity": "INTEGER",
  182. "notNull": true,
  183. "defaultValue": "0"
  184. },
  185. {
  186. "fieldPath": "originOrder",
  187. "columnName": "originOrder",
  188. "affinity": "INTEGER",
  189. "notNull": true,
  190. "defaultValue": "0"
  191. },
  192. {
  193. "fieldPath": "variable",
  194. "columnName": "variable",
  195. "affinity": "TEXT"
  196. },
  197. {
  198. "fieldPath": "readConfig",
  199. "columnName": "readConfig",
  200. "affinity": "TEXT"
  201. },
  202. {
  203. "fieldPath": "syncTime",
  204. "columnName": "syncTime",
  205. "affinity": "INTEGER",
  206. "notNull": true,
  207. "defaultValue": "0"
  208. }
  209. ],
  210. "primaryKey": {
  211. "autoGenerate": false,
  212. "columnNames": [
  213. "bookUrl"
  214. ]
  215. },
  216. "indices": [
  217. {
  218. "name": "index_books_name_author",
  219. "unique": false,
  220. "columnNames": [
  221. "name",
  222. "author"
  223. ],
  224. "orders": [],
  225. "createSql": "CREATE INDEX IF NOT EXISTS `index_books_name_author` ON `${TABLE_NAME}` (`name`, `author`)"
  226. },
  227. {
  228. "name": "index_books_durChapterTime",
  229. "unique": false,
  230. "columnNames": [
  231. "durChapterTime"
  232. ],
  233. "orders": [],
  234. "createSql": "CREATE INDEX IF NOT EXISTS `index_books_durChapterTime` ON `${TABLE_NAME}` (`durChapterTime`)"
  235. }
  236. ]
  237. },
  238. {
  239. "tableName": "book_groups",
  240. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`groupId` INTEGER NOT NULL, `groupName` TEXT NOT NULL, `cover` TEXT, `order` INTEGER NOT NULL, `enableRefresh` INTEGER NOT NULL DEFAULT 1, `show` INTEGER NOT NULL DEFAULT 1, `bookSort` INTEGER NOT NULL DEFAULT -1, `isPrivate` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`groupId`))",
  241. "fields": [
  242. {
  243. "fieldPath": "groupId",
  244. "columnName": "groupId",
  245. "affinity": "INTEGER",
  246. "notNull": true
  247. },
  248. {
  249. "fieldPath": "groupName",
  250. "columnName": "groupName",
  251. "affinity": "TEXT",
  252. "notNull": true
  253. },
  254. {
  255. "fieldPath": "cover",
  256. "columnName": "cover",
  257. "affinity": "TEXT"
  258. },
  259. {
  260. "fieldPath": "order",
  261. "columnName": "order",
  262. "affinity": "INTEGER",
  263. "notNull": true
  264. },
  265. {
  266. "fieldPath": "enableRefresh",
  267. "columnName": "enableRefresh",
  268. "affinity": "INTEGER",
  269. "notNull": true,
  270. "defaultValue": "1"
  271. },
  272. {
  273. "fieldPath": "show",
  274. "columnName": "show",
  275. "affinity": "INTEGER",
  276. "notNull": true,
  277. "defaultValue": "1"
  278. },
  279. {
  280. "fieldPath": "bookSort",
  281. "columnName": "bookSort",
  282. "affinity": "INTEGER",
  283. "notNull": true,
  284. "defaultValue": "-1"
  285. },
  286. {
  287. "fieldPath": "isPrivate",
  288. "columnName": "isPrivate",
  289. "affinity": "INTEGER",
  290. "notNull": true,
  291. "defaultValue": "0"
  292. }
  293. ],
  294. "primaryKey": {
  295. "autoGenerate": false,
  296. "columnNames": [
  297. "groupId"
  298. ]
  299. }
  300. },
  301. {
  302. "tableName": "book_sources",
  303. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`bookSourceUrl` TEXT NOT NULL, `bookSourceName` TEXT NOT NULL, `bookSourceGroup` TEXT, `bookSourceType` INTEGER NOT NULL, `bookUrlPattern` TEXT, `customOrder` INTEGER NOT NULL DEFAULT 0, `enabled` INTEGER NOT NULL DEFAULT 1, `enabledExplore` INTEGER NOT NULL DEFAULT 1, `jsLib` TEXT, `enabledCookieJar` INTEGER DEFAULT 0, `concurrentRate` TEXT, `header` TEXT, `loginUrl` TEXT, `loginUi` TEXT, `loginCheckJs` TEXT, `coverDecodeJs` TEXT, `bookSourceComment` TEXT, `variableComment` TEXT, `lastUpdateTime` INTEGER NOT NULL, `respondTime` INTEGER NOT NULL, `weight` INTEGER NOT NULL, `exploreUrl` TEXT, `exploreScreen` TEXT, `ruleExplore` TEXT, `searchUrl` TEXT, `ruleSearch` TEXT, `ruleBookInfo` TEXT, `ruleToc` TEXT, `ruleContent` TEXT, `ruleReview` TEXT, `eventListener` INTEGER NOT NULL DEFAULT 0, `customButton` INTEGER NOT NULL DEFAULT 0, `homepageModules` TEXT, PRIMARY KEY(`bookSourceUrl`))",
  304. "fields": [
  305. {
  306. "fieldPath": "bookSourceUrl",
  307. "columnName": "bookSourceUrl",
  308. "affinity": "TEXT",
  309. "notNull": true
  310. },
  311. {
  312. "fieldPath": "bookSourceName",
  313. "columnName": "bookSourceName",
  314. "affinity": "TEXT",
  315. "notNull": true
  316. },
  317. {
  318. "fieldPath": "bookSourceGroup",
  319. "columnName": "bookSourceGroup",
  320. "affinity": "TEXT"
  321. },
  322. {
  323. "fieldPath": "bookSourceType",
  324. "columnName": "bookSourceType",
  325. "affinity": "INTEGER",
  326. "notNull": true
  327. },
  328. {
  329. "fieldPath": "bookUrlPattern",
  330. "columnName": "bookUrlPattern",
  331. "affinity": "TEXT"
  332. },
  333. {
  334. "fieldPath": "customOrder",
  335. "columnName": "customOrder",
  336. "affinity": "INTEGER",
  337. "notNull": true,
  338. "defaultValue": "0"
  339. },
  340. {
  341. "fieldPath": "enabled",
  342. "columnName": "enabled",
  343. "affinity": "INTEGER",
  344. "notNull": true,
  345. "defaultValue": "1"
  346. },
  347. {
  348. "fieldPath": "enabledExplore",
  349. "columnName": "enabledExplore",
  350. "affinity": "INTEGER",
  351. "notNull": true,
  352. "defaultValue": "1"
  353. },
  354. {
  355. "fieldPath": "jsLib",
  356. "columnName": "jsLib",
  357. "affinity": "TEXT"
  358. },
  359. {
  360. "fieldPath": "enabledCookieJar",
  361. "columnName": "enabledCookieJar",
  362. "affinity": "INTEGER",
  363. "defaultValue": "0"
  364. },
  365. {
  366. "fieldPath": "concurrentRate",
  367. "columnName": "concurrentRate",
  368. "affinity": "TEXT"
  369. },
  370. {
  371. "fieldPath": "header",
  372. "columnName": "header",
  373. "affinity": "TEXT"
  374. },
  375. {
  376. "fieldPath": "loginUrl",
  377. "columnName": "loginUrl",
  378. "affinity": "TEXT"
  379. },
  380. {
  381. "fieldPath": "loginUi",
  382. "columnName": "loginUi",
  383. "affinity": "TEXT"
  384. },
  385. {
  386. "fieldPath": "loginCheckJs",
  387. "columnName": "loginCheckJs",
  388. "affinity": "TEXT"
  389. },
  390. {
  391. "fieldPath": "coverDecodeJs",
  392. "columnName": "coverDecodeJs",
  393. "affinity": "TEXT"
  394. },
  395. {
  396. "fieldPath": "bookSourceComment",
  397. "columnName": "bookSourceComment",
  398. "affinity": "TEXT"
  399. },
  400. {
  401. "fieldPath": "variableComment",
  402. "columnName": "variableComment",
  403. "affinity": "TEXT"
  404. },
  405. {
  406. "fieldPath": "lastUpdateTime",
  407. "columnName": "lastUpdateTime",
  408. "affinity": "INTEGER",
  409. "notNull": true
  410. },
  411. {
  412. "fieldPath": "respondTime",
  413. "columnName": "respondTime",
  414. "affinity": "INTEGER",
  415. "notNull": true
  416. },
  417. {
  418. "fieldPath": "weight",
  419. "columnName": "weight",
  420. "affinity": "INTEGER",
  421. "notNull": true
  422. },
  423. {
  424. "fieldPath": "exploreUrl",
  425. "columnName": "exploreUrl",
  426. "affinity": "TEXT"
  427. },
  428. {
  429. "fieldPath": "exploreScreen",
  430. "columnName": "exploreScreen",
  431. "affinity": "TEXT"
  432. },
  433. {
  434. "fieldPath": "ruleExplore",
  435. "columnName": "ruleExplore",
  436. "affinity": "TEXT"
  437. },
  438. {
  439. "fieldPath": "searchUrl",
  440. "columnName": "searchUrl",
  441. "affinity": "TEXT"
  442. },
  443. {
  444. "fieldPath": "ruleSearch",
  445. "columnName": "ruleSearch",
  446. "affinity": "TEXT"
  447. },
  448. {
  449. "fieldPath": "ruleBookInfo",
  450. "columnName": "ruleBookInfo",
  451. "affinity": "TEXT"
  452. },
  453. {
  454. "fieldPath": "ruleToc",
  455. "columnName": "ruleToc",
  456. "affinity": "TEXT"
  457. },
  458. {
  459. "fieldPath": "ruleContent",
  460. "columnName": "ruleContent",
  461. "affinity": "TEXT"
  462. },
  463. {
  464. "fieldPath": "ruleReview",
  465. "columnName": "ruleReview",
  466. "affinity": "TEXT"
  467. },
  468. {
  469. "fieldPath": "eventListener",
  470. "columnName": "eventListener",
  471. "affinity": "INTEGER",
  472. "notNull": true,
  473. "defaultValue": "0"
  474. },
  475. {
  476. "fieldPath": "customButton",
  477. "columnName": "customButton",
  478. "affinity": "INTEGER",
  479. "notNull": true,
  480. "defaultValue": "0"
  481. },
  482. {
  483. "fieldPath": "homepageModules",
  484. "columnName": "homepageModules",
  485. "affinity": "TEXT"
  486. }
  487. ],
  488. "primaryKey": {
  489. "autoGenerate": false,
  490. "columnNames": [
  491. "bookSourceUrl"
  492. ]
  493. },
  494. "indices": [
  495. {
  496. "name": "index_book_sources_bookSourceUrl",
  497. "unique": false,
  498. "columnNames": [
  499. "bookSourceUrl"
  500. ],
  501. "orders": [],
  502. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_sources_bookSourceUrl` ON `${TABLE_NAME}` (`bookSourceUrl`)"
  503. }
  504. ]
  505. },
  506. {
  507. "tableName": "chapters",
  508. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`url` TEXT NOT NULL, `title` TEXT NOT NULL, `isVolume` INTEGER NOT NULL, `tocLevel` INTEGER NOT NULL DEFAULT 0, `baseUrl` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `index` INTEGER NOT NULL, `isVip` INTEGER NOT NULL, `isPay` INTEGER NOT NULL, `resourceUrl` TEXT, `tag` TEXT, `wordCount` TEXT, `start` INTEGER, `end` INTEGER, `startFragmentId` TEXT, `endFragmentId` TEXT, `variable` TEXT, `reviewImg` TEXT, PRIMARY KEY(`url`, `bookUrl`), FOREIGN KEY(`bookUrl`) REFERENCES `books`(`bookUrl`) ON UPDATE NO ACTION ON DELETE CASCADE )",
  509. "fields": [
  510. {
  511. "fieldPath": "url",
  512. "columnName": "url",
  513. "affinity": "TEXT",
  514. "notNull": true
  515. },
  516. {
  517. "fieldPath": "title",
  518. "columnName": "title",
  519. "affinity": "TEXT",
  520. "notNull": true
  521. },
  522. {
  523. "fieldPath": "isVolume",
  524. "columnName": "isVolume",
  525. "affinity": "INTEGER",
  526. "notNull": true
  527. },
  528. {
  529. "fieldPath": "tocLevel",
  530. "columnName": "tocLevel",
  531. "affinity": "INTEGER",
  532. "notNull": true,
  533. "defaultValue": "0"
  534. },
  535. {
  536. "fieldPath": "baseUrl",
  537. "columnName": "baseUrl",
  538. "affinity": "TEXT",
  539. "notNull": true
  540. },
  541. {
  542. "fieldPath": "bookUrl",
  543. "columnName": "bookUrl",
  544. "affinity": "TEXT",
  545. "notNull": true
  546. },
  547. {
  548. "fieldPath": "index",
  549. "columnName": "index",
  550. "affinity": "INTEGER",
  551. "notNull": true
  552. },
  553. {
  554. "fieldPath": "isVip",
  555. "columnName": "isVip",
  556. "affinity": "INTEGER",
  557. "notNull": true
  558. },
  559. {
  560. "fieldPath": "isPay",
  561. "columnName": "isPay",
  562. "affinity": "INTEGER",
  563. "notNull": true
  564. },
  565. {
  566. "fieldPath": "resourceUrl",
  567. "columnName": "resourceUrl",
  568. "affinity": "TEXT"
  569. },
  570. {
  571. "fieldPath": "tag",
  572. "columnName": "tag",
  573. "affinity": "TEXT"
  574. },
  575. {
  576. "fieldPath": "wordCount",
  577. "columnName": "wordCount",
  578. "affinity": "TEXT"
  579. },
  580. {
  581. "fieldPath": "start",
  582. "columnName": "start",
  583. "affinity": "INTEGER"
  584. },
  585. {
  586. "fieldPath": "end",
  587. "columnName": "end",
  588. "affinity": "INTEGER"
  589. },
  590. {
  591. "fieldPath": "startFragmentId",
  592. "columnName": "startFragmentId",
  593. "affinity": "TEXT"
  594. },
  595. {
  596. "fieldPath": "endFragmentId",
  597. "columnName": "endFragmentId",
  598. "affinity": "TEXT"
  599. },
  600. {
  601. "fieldPath": "variable",
  602. "columnName": "variable",
  603. "affinity": "TEXT"
  604. },
  605. {
  606. "fieldPath": "reviewImg",
  607. "columnName": "reviewImg",
  608. "affinity": "TEXT"
  609. }
  610. ],
  611. "primaryKey": {
  612. "autoGenerate": false,
  613. "columnNames": [
  614. "url",
  615. "bookUrl"
  616. ]
  617. },
  618. "indices": [
  619. {
  620. "name": "index_chapters_bookUrl",
  621. "unique": false,
  622. "columnNames": [
  623. "bookUrl"
  624. ],
  625. "orders": [],
  626. "createSql": "CREATE INDEX IF NOT EXISTS `index_chapters_bookUrl` ON `${TABLE_NAME}` (`bookUrl`)"
  627. },
  628. {
  629. "name": "index_chapters_bookUrl_index",
  630. "unique": true,
  631. "columnNames": [
  632. "bookUrl",
  633. "index"
  634. ],
  635. "orders": [],
  636. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_chapters_bookUrl_index` ON `${TABLE_NAME}` (`bookUrl`, `index`)"
  637. }
  638. ],
  639. "foreignKeys": [
  640. {
  641. "table": "books",
  642. "onDelete": "CASCADE",
  643. "onUpdate": "NO ACTION",
  644. "columns": [
  645. "bookUrl"
  646. ],
  647. "referencedColumns": [
  648. "bookUrl"
  649. ]
  650. }
  651. ]
  652. },
  653. {
  654. "tableName": "replace_rules",
  655. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `name` TEXT NOT NULL DEFAULT '', `group` TEXT, `pattern` TEXT NOT NULL DEFAULT '', `replacement` TEXT NOT NULL DEFAULT '', `scope` TEXT, `scopeTitle` INTEGER NOT NULL DEFAULT 0, `scopeContent` INTEGER NOT NULL DEFAULT 1, `excludeScope` TEXT, `isEnabled` INTEGER NOT NULL DEFAULT 1, `isRegex` INTEGER NOT NULL DEFAULT 1, `timeoutMillisecond` INTEGER NOT NULL DEFAULT 3000, `sortOrder` INTEGER NOT NULL DEFAULT 0)",
  656. "fields": [
  657. {
  658. "fieldPath": "id",
  659. "columnName": "id",
  660. "affinity": "INTEGER",
  661. "notNull": true
  662. },
  663. {
  664. "fieldPath": "name",
  665. "columnName": "name",
  666. "affinity": "TEXT",
  667. "notNull": true,
  668. "defaultValue": "''"
  669. },
  670. {
  671. "fieldPath": "group",
  672. "columnName": "group",
  673. "affinity": "TEXT"
  674. },
  675. {
  676. "fieldPath": "pattern",
  677. "columnName": "pattern",
  678. "affinity": "TEXT",
  679. "notNull": true,
  680. "defaultValue": "''"
  681. },
  682. {
  683. "fieldPath": "replacement",
  684. "columnName": "replacement",
  685. "affinity": "TEXT",
  686. "notNull": true,
  687. "defaultValue": "''"
  688. },
  689. {
  690. "fieldPath": "scope",
  691. "columnName": "scope",
  692. "affinity": "TEXT"
  693. },
  694. {
  695. "fieldPath": "scopeTitle",
  696. "columnName": "scopeTitle",
  697. "affinity": "INTEGER",
  698. "notNull": true,
  699. "defaultValue": "0"
  700. },
  701. {
  702. "fieldPath": "scopeContent",
  703. "columnName": "scopeContent",
  704. "affinity": "INTEGER",
  705. "notNull": true,
  706. "defaultValue": "1"
  707. },
  708. {
  709. "fieldPath": "excludeScope",
  710. "columnName": "excludeScope",
  711. "affinity": "TEXT"
  712. },
  713. {
  714. "fieldPath": "isEnabled",
  715. "columnName": "isEnabled",
  716. "affinity": "INTEGER",
  717. "notNull": true,
  718. "defaultValue": "1"
  719. },
  720. {
  721. "fieldPath": "isRegex",
  722. "columnName": "isRegex",
  723. "affinity": "INTEGER",
  724. "notNull": true,
  725. "defaultValue": "1"
  726. },
  727. {
  728. "fieldPath": "timeoutMillisecond",
  729. "columnName": "timeoutMillisecond",
  730. "affinity": "INTEGER",
  731. "notNull": true,
  732. "defaultValue": "3000"
  733. },
  734. {
  735. "fieldPath": "order",
  736. "columnName": "sortOrder",
  737. "affinity": "INTEGER",
  738. "notNull": true,
  739. "defaultValue": "0"
  740. }
  741. ],
  742. "primaryKey": {
  743. "autoGenerate": true,
  744. "columnNames": [
  745. "id"
  746. ]
  747. },
  748. "indices": [
  749. {
  750. "name": "index_replace_rules_id",
  751. "unique": false,
  752. "columnNames": [
  753. "id"
  754. ],
  755. "orders": [],
  756. "createSql": "CREATE INDEX IF NOT EXISTS `index_replace_rules_id` ON `${TABLE_NAME}` (`id`)"
  757. }
  758. ]
  759. },
  760. {
  761. "tableName": "searchBooks",
  762. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`bookUrl` TEXT NOT NULL, `origin` TEXT NOT NULL, `originName` TEXT NOT NULL, `type` INTEGER NOT NULL, `name` TEXT NOT NULL, `author` TEXT NOT NULL, `kind` TEXT, `coverUrl` TEXT, `intro` TEXT, `wordCount` TEXT, `latestChapterTitle` TEXT, `tocUrl` TEXT NOT NULL, `time` INTEGER NOT NULL, `variable` TEXT, `originOrder` INTEGER NOT NULL, `chapterWordCountText` TEXT, `chapterWordCount` INTEGER NOT NULL DEFAULT -1, `respondTime` INTEGER NOT NULL DEFAULT -1, PRIMARY KEY(`bookUrl`), FOREIGN KEY(`origin`) REFERENCES `book_sources`(`bookSourceUrl`) ON UPDATE NO ACTION ON DELETE CASCADE )",
  763. "fields": [
  764. {
  765. "fieldPath": "bookUrl",
  766. "columnName": "bookUrl",
  767. "affinity": "TEXT",
  768. "notNull": true
  769. },
  770. {
  771. "fieldPath": "origin",
  772. "columnName": "origin",
  773. "affinity": "TEXT",
  774. "notNull": true
  775. },
  776. {
  777. "fieldPath": "originName",
  778. "columnName": "originName",
  779. "affinity": "TEXT",
  780. "notNull": true
  781. },
  782. {
  783. "fieldPath": "type",
  784. "columnName": "type",
  785. "affinity": "INTEGER",
  786. "notNull": true
  787. },
  788. {
  789. "fieldPath": "name",
  790. "columnName": "name",
  791. "affinity": "TEXT",
  792. "notNull": true
  793. },
  794. {
  795. "fieldPath": "author",
  796. "columnName": "author",
  797. "affinity": "TEXT",
  798. "notNull": true
  799. },
  800. {
  801. "fieldPath": "kind",
  802. "columnName": "kind",
  803. "affinity": "TEXT"
  804. },
  805. {
  806. "fieldPath": "coverUrl",
  807. "columnName": "coverUrl",
  808. "affinity": "TEXT"
  809. },
  810. {
  811. "fieldPath": "intro",
  812. "columnName": "intro",
  813. "affinity": "TEXT"
  814. },
  815. {
  816. "fieldPath": "wordCount",
  817. "columnName": "wordCount",
  818. "affinity": "TEXT"
  819. },
  820. {
  821. "fieldPath": "latestChapterTitle",
  822. "columnName": "latestChapterTitle",
  823. "affinity": "TEXT"
  824. },
  825. {
  826. "fieldPath": "tocUrl",
  827. "columnName": "tocUrl",
  828. "affinity": "TEXT",
  829. "notNull": true
  830. },
  831. {
  832. "fieldPath": "time",
  833. "columnName": "time",
  834. "affinity": "INTEGER",
  835. "notNull": true
  836. },
  837. {
  838. "fieldPath": "variable",
  839. "columnName": "variable",
  840. "affinity": "TEXT"
  841. },
  842. {
  843. "fieldPath": "originOrder",
  844. "columnName": "originOrder",
  845. "affinity": "INTEGER",
  846. "notNull": true
  847. },
  848. {
  849. "fieldPath": "chapterWordCountText",
  850. "columnName": "chapterWordCountText",
  851. "affinity": "TEXT"
  852. },
  853. {
  854. "fieldPath": "chapterWordCount",
  855. "columnName": "chapterWordCount",
  856. "affinity": "INTEGER",
  857. "notNull": true,
  858. "defaultValue": "-1"
  859. },
  860. {
  861. "fieldPath": "respondTime",
  862. "columnName": "respondTime",
  863. "affinity": "INTEGER",
  864. "notNull": true,
  865. "defaultValue": "-1"
  866. }
  867. ],
  868. "primaryKey": {
  869. "autoGenerate": false,
  870. "columnNames": [
  871. "bookUrl"
  872. ]
  873. },
  874. "indices": [
  875. {
  876. "name": "index_searchBooks_bookUrl",
  877. "unique": true,
  878. "columnNames": [
  879. "bookUrl"
  880. ],
  881. "orders": [],
  882. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_searchBooks_bookUrl` ON `${TABLE_NAME}` (`bookUrl`)"
  883. },
  884. {
  885. "name": "index_searchBooks_origin",
  886. "unique": false,
  887. "columnNames": [
  888. "origin"
  889. ],
  890. "orders": [],
  891. "createSql": "CREATE INDEX IF NOT EXISTS `index_searchBooks_origin` ON `${TABLE_NAME}` (`origin`)"
  892. }
  893. ],
  894. "foreignKeys": [
  895. {
  896. "table": "book_sources",
  897. "onDelete": "CASCADE",
  898. "onUpdate": "NO ACTION",
  899. "columns": [
  900. "origin"
  901. ],
  902. "referencedColumns": [
  903. "bookSourceUrl"
  904. ]
  905. }
  906. ]
  907. },
  908. {
  909. "tableName": "search_keywords",
  910. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`word` TEXT NOT NULL, `usage` INTEGER NOT NULL, `lastUseTime` INTEGER NOT NULL, PRIMARY KEY(`word`))",
  911. "fields": [
  912. {
  913. "fieldPath": "word",
  914. "columnName": "word",
  915. "affinity": "TEXT",
  916. "notNull": true
  917. },
  918. {
  919. "fieldPath": "usage",
  920. "columnName": "usage",
  921. "affinity": "INTEGER",
  922. "notNull": true
  923. },
  924. {
  925. "fieldPath": "lastUseTime",
  926. "columnName": "lastUseTime",
  927. "affinity": "INTEGER",
  928. "notNull": true
  929. }
  930. ],
  931. "primaryKey": {
  932. "autoGenerate": false,
  933. "columnNames": [
  934. "word"
  935. ]
  936. },
  937. "indices": [
  938. {
  939. "name": "index_search_keywords_word",
  940. "unique": true,
  941. "columnNames": [
  942. "word"
  943. ],
  944. "orders": [],
  945. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_search_keywords_word` ON `${TABLE_NAME}` (`word`)"
  946. }
  947. ]
  948. },
  949. {
  950. "tableName": "cookies",
  951. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`url` TEXT NOT NULL, `cookie` TEXT NOT NULL, PRIMARY KEY(`url`))",
  952. "fields": [
  953. {
  954. "fieldPath": "url",
  955. "columnName": "url",
  956. "affinity": "TEXT",
  957. "notNull": true
  958. },
  959. {
  960. "fieldPath": "cookie",
  961. "columnName": "cookie",
  962. "affinity": "TEXT",
  963. "notNull": true
  964. }
  965. ],
  966. "primaryKey": {
  967. "autoGenerate": false,
  968. "columnNames": [
  969. "url"
  970. ]
  971. },
  972. "indices": [
  973. {
  974. "name": "index_cookies_url",
  975. "unique": true,
  976. "columnNames": [
  977. "url"
  978. ],
  979. "orders": [],
  980. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_cookies_url` ON `${TABLE_NAME}` (`url`)"
  981. }
  982. ]
  983. },
  984. {
  985. "tableName": "rssSources",
  986. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`sourceUrl` TEXT NOT NULL, `sourceName` TEXT NOT NULL, `sourceIcon` TEXT NOT NULL, `sourceGroup` TEXT, `sourceComment` TEXT, `enabled` INTEGER NOT NULL, `variableComment` TEXT, `jsLib` TEXT, `enabledCookieJar` INTEGER DEFAULT 0, `concurrentRate` TEXT, `header` TEXT, `loginUrl` TEXT, `loginUi` TEXT, `loginCheckJs` TEXT, `coverDecodeJs` TEXT, `sortUrl` TEXT, `singleUrl` INTEGER NOT NULL, `articleStyle` INTEGER NOT NULL DEFAULT 0, `ruleArticles` TEXT, `ruleNextPage` TEXT, `ruleTitle` TEXT, `rulePubDate` TEXT, `ruleDescription` TEXT, `ruleImage` TEXT, `ruleLink` TEXT, `ruleContent` TEXT, `contentWhitelist` TEXT, `contentBlacklist` TEXT, `shouldOverrideUrlLoading` TEXT, `style` TEXT, `enableJs` INTEGER NOT NULL DEFAULT 1, `loadWithBaseUrl` INTEGER NOT NULL DEFAULT 1, `injectJs` TEXT, `preloadJs` TEXT, `startHtml` TEXT, `startStyle` TEXT, `startJs` TEXT, `showWebLog` INTEGER NOT NULL DEFAULT 0, `lastUpdateTime` INTEGER NOT NULL DEFAULT 0, `customOrder` INTEGER NOT NULL DEFAULT 0, `type` INTEGER NOT NULL DEFAULT 0, `preload` INTEGER NOT NULL DEFAULT 0, `cacheFirst` INTEGER NOT NULL DEFAULT 0, `searchUrl` TEXT, `redirectPolicy` TEXT NOT NULL DEFAULT 'ASK_CROSS_ORIGIN', PRIMARY KEY(`sourceUrl`))",
  987. "fields": [
  988. {
  989. "fieldPath": "sourceUrl",
  990. "columnName": "sourceUrl",
  991. "affinity": "TEXT",
  992. "notNull": true
  993. },
  994. {
  995. "fieldPath": "sourceName",
  996. "columnName": "sourceName",
  997. "affinity": "TEXT",
  998. "notNull": true
  999. },
  1000. {
  1001. "fieldPath": "sourceIcon",
  1002. "columnName": "sourceIcon",
  1003. "affinity": "TEXT",
  1004. "notNull": true
  1005. },
  1006. {
  1007. "fieldPath": "sourceGroup",
  1008. "columnName": "sourceGroup",
  1009. "affinity": "TEXT"
  1010. },
  1011. {
  1012. "fieldPath": "sourceComment",
  1013. "columnName": "sourceComment",
  1014. "affinity": "TEXT"
  1015. },
  1016. {
  1017. "fieldPath": "enabled",
  1018. "columnName": "enabled",
  1019. "affinity": "INTEGER",
  1020. "notNull": true
  1021. },
  1022. {
  1023. "fieldPath": "variableComment",
  1024. "columnName": "variableComment",
  1025. "affinity": "TEXT"
  1026. },
  1027. {
  1028. "fieldPath": "jsLib",
  1029. "columnName": "jsLib",
  1030. "affinity": "TEXT"
  1031. },
  1032. {
  1033. "fieldPath": "enabledCookieJar",
  1034. "columnName": "enabledCookieJar",
  1035. "affinity": "INTEGER",
  1036. "defaultValue": "0"
  1037. },
  1038. {
  1039. "fieldPath": "concurrentRate",
  1040. "columnName": "concurrentRate",
  1041. "affinity": "TEXT"
  1042. },
  1043. {
  1044. "fieldPath": "header",
  1045. "columnName": "header",
  1046. "affinity": "TEXT"
  1047. },
  1048. {
  1049. "fieldPath": "loginUrl",
  1050. "columnName": "loginUrl",
  1051. "affinity": "TEXT"
  1052. },
  1053. {
  1054. "fieldPath": "loginUi",
  1055. "columnName": "loginUi",
  1056. "affinity": "TEXT"
  1057. },
  1058. {
  1059. "fieldPath": "loginCheckJs",
  1060. "columnName": "loginCheckJs",
  1061. "affinity": "TEXT"
  1062. },
  1063. {
  1064. "fieldPath": "coverDecodeJs",
  1065. "columnName": "coverDecodeJs",
  1066. "affinity": "TEXT"
  1067. },
  1068. {
  1069. "fieldPath": "sortUrl",
  1070. "columnName": "sortUrl",
  1071. "affinity": "TEXT"
  1072. },
  1073. {
  1074. "fieldPath": "singleUrl",
  1075. "columnName": "singleUrl",
  1076. "affinity": "INTEGER",
  1077. "notNull": true
  1078. },
  1079. {
  1080. "fieldPath": "articleStyle",
  1081. "columnName": "articleStyle",
  1082. "affinity": "INTEGER",
  1083. "notNull": true,
  1084. "defaultValue": "0"
  1085. },
  1086. {
  1087. "fieldPath": "ruleArticles",
  1088. "columnName": "ruleArticles",
  1089. "affinity": "TEXT"
  1090. },
  1091. {
  1092. "fieldPath": "ruleNextPage",
  1093. "columnName": "ruleNextPage",
  1094. "affinity": "TEXT"
  1095. },
  1096. {
  1097. "fieldPath": "ruleTitle",
  1098. "columnName": "ruleTitle",
  1099. "affinity": "TEXT"
  1100. },
  1101. {
  1102. "fieldPath": "rulePubDate",
  1103. "columnName": "rulePubDate",
  1104. "affinity": "TEXT"
  1105. },
  1106. {
  1107. "fieldPath": "ruleDescription",
  1108. "columnName": "ruleDescription",
  1109. "affinity": "TEXT"
  1110. },
  1111. {
  1112. "fieldPath": "ruleImage",
  1113. "columnName": "ruleImage",
  1114. "affinity": "TEXT"
  1115. },
  1116. {
  1117. "fieldPath": "ruleLink",
  1118. "columnName": "ruleLink",
  1119. "affinity": "TEXT"
  1120. },
  1121. {
  1122. "fieldPath": "ruleContent",
  1123. "columnName": "ruleContent",
  1124. "affinity": "TEXT"
  1125. },
  1126. {
  1127. "fieldPath": "contentWhitelist",
  1128. "columnName": "contentWhitelist",
  1129. "affinity": "TEXT"
  1130. },
  1131. {
  1132. "fieldPath": "contentBlacklist",
  1133. "columnName": "contentBlacklist",
  1134. "affinity": "TEXT"
  1135. },
  1136. {
  1137. "fieldPath": "shouldOverrideUrlLoading",
  1138. "columnName": "shouldOverrideUrlLoading",
  1139. "affinity": "TEXT"
  1140. },
  1141. {
  1142. "fieldPath": "style",
  1143. "columnName": "style",
  1144. "affinity": "TEXT"
  1145. },
  1146. {
  1147. "fieldPath": "enableJs",
  1148. "columnName": "enableJs",
  1149. "affinity": "INTEGER",
  1150. "notNull": true,
  1151. "defaultValue": "1"
  1152. },
  1153. {
  1154. "fieldPath": "loadWithBaseUrl",
  1155. "columnName": "loadWithBaseUrl",
  1156. "affinity": "INTEGER",
  1157. "notNull": true,
  1158. "defaultValue": "1"
  1159. },
  1160. {
  1161. "fieldPath": "injectJs",
  1162. "columnName": "injectJs",
  1163. "affinity": "TEXT"
  1164. },
  1165. {
  1166. "fieldPath": "preloadJs",
  1167. "columnName": "preloadJs",
  1168. "affinity": "TEXT"
  1169. },
  1170. {
  1171. "fieldPath": "startHtml",
  1172. "columnName": "startHtml",
  1173. "affinity": "TEXT"
  1174. },
  1175. {
  1176. "fieldPath": "startStyle",
  1177. "columnName": "startStyle",
  1178. "affinity": "TEXT"
  1179. },
  1180. {
  1181. "fieldPath": "startJs",
  1182. "columnName": "startJs",
  1183. "affinity": "TEXT"
  1184. },
  1185. {
  1186. "fieldPath": "showWebLog",
  1187. "columnName": "showWebLog",
  1188. "affinity": "INTEGER",
  1189. "notNull": true,
  1190. "defaultValue": "0"
  1191. },
  1192. {
  1193. "fieldPath": "lastUpdateTime",
  1194. "columnName": "lastUpdateTime",
  1195. "affinity": "INTEGER",
  1196. "notNull": true,
  1197. "defaultValue": "0"
  1198. },
  1199. {
  1200. "fieldPath": "customOrder",
  1201. "columnName": "customOrder",
  1202. "affinity": "INTEGER",
  1203. "notNull": true,
  1204. "defaultValue": "0"
  1205. },
  1206. {
  1207. "fieldPath": "type",
  1208. "columnName": "type",
  1209. "affinity": "INTEGER",
  1210. "notNull": true,
  1211. "defaultValue": "0"
  1212. },
  1213. {
  1214. "fieldPath": "preload",
  1215. "columnName": "preload",
  1216. "affinity": "INTEGER",
  1217. "notNull": true,
  1218. "defaultValue": "0"
  1219. },
  1220. {
  1221. "fieldPath": "cacheFirst",
  1222. "columnName": "cacheFirst",
  1223. "affinity": "INTEGER",
  1224. "notNull": true,
  1225. "defaultValue": "0"
  1226. },
  1227. {
  1228. "fieldPath": "searchUrl",
  1229. "columnName": "searchUrl",
  1230. "affinity": "TEXT"
  1231. },
  1232. {
  1233. "fieldPath": "redirectPolicy",
  1234. "columnName": "redirectPolicy",
  1235. "affinity": "TEXT",
  1236. "notNull": true,
  1237. "defaultValue": "'ASK_CROSS_ORIGIN'"
  1238. }
  1239. ],
  1240. "primaryKey": {
  1241. "autoGenerate": false,
  1242. "columnNames": [
  1243. "sourceUrl"
  1244. ]
  1245. },
  1246. "indices": [
  1247. {
  1248. "name": "index_rssSources_sourceUrl",
  1249. "unique": false,
  1250. "columnNames": [
  1251. "sourceUrl"
  1252. ],
  1253. "orders": [],
  1254. "createSql": "CREATE INDEX IF NOT EXISTS `index_rssSources_sourceUrl` ON `${TABLE_NAME}` (`sourceUrl`)"
  1255. }
  1256. ]
  1257. },
  1258. {
  1259. "tableName": "bookmarks",
  1260. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`time` INTEGER NOT NULL, `bookName` TEXT NOT NULL, `bookAuthor` TEXT NOT NULL DEFAULT '', `chapterIndex` INTEGER NOT NULL, `chapterPos` INTEGER NOT NULL, `chapterName` TEXT NOT NULL, `bookText` TEXT NOT NULL, `content` TEXT NOT NULL, PRIMARY KEY(`time`))",
  1261. "fields": [
  1262. {
  1263. "fieldPath": "time",
  1264. "columnName": "time",
  1265. "affinity": "INTEGER",
  1266. "notNull": true
  1267. },
  1268. {
  1269. "fieldPath": "bookName",
  1270. "columnName": "bookName",
  1271. "affinity": "TEXT",
  1272. "notNull": true
  1273. },
  1274. {
  1275. "fieldPath": "bookAuthor",
  1276. "columnName": "bookAuthor",
  1277. "affinity": "TEXT",
  1278. "notNull": true,
  1279. "defaultValue": "''"
  1280. },
  1281. {
  1282. "fieldPath": "chapterIndex",
  1283. "columnName": "chapterIndex",
  1284. "affinity": "INTEGER",
  1285. "notNull": true
  1286. },
  1287. {
  1288. "fieldPath": "chapterPos",
  1289. "columnName": "chapterPos",
  1290. "affinity": "INTEGER",
  1291. "notNull": true
  1292. },
  1293. {
  1294. "fieldPath": "chapterName",
  1295. "columnName": "chapterName",
  1296. "affinity": "TEXT",
  1297. "notNull": true
  1298. },
  1299. {
  1300. "fieldPath": "bookText",
  1301. "columnName": "bookText",
  1302. "affinity": "TEXT",
  1303. "notNull": true
  1304. },
  1305. {
  1306. "fieldPath": "content",
  1307. "columnName": "content",
  1308. "affinity": "TEXT",
  1309. "notNull": true
  1310. }
  1311. ],
  1312. "primaryKey": {
  1313. "autoGenerate": false,
  1314. "columnNames": [
  1315. "time"
  1316. ]
  1317. },
  1318. "indices": [
  1319. {
  1320. "name": "index_bookmarks_bookName_bookAuthor",
  1321. "unique": false,
  1322. "columnNames": [
  1323. "bookName",
  1324. "bookAuthor"
  1325. ],
  1326. "orders": [],
  1327. "createSql": "CREATE INDEX IF NOT EXISTS `index_bookmarks_bookName_bookAuthor` ON `${TABLE_NAME}` (`bookName`, `bookAuthor`)"
  1328. }
  1329. ]
  1330. },
  1331. {
  1332. "tableName": "rssArticles",
  1333. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`origin` TEXT NOT NULL, `sort` TEXT NOT NULL, `title` TEXT NOT NULL, `order` INTEGER NOT NULL, `link` TEXT NOT NULL, `pubDate` TEXT, `description` TEXT, `content` TEXT, `image` TEXT, `group` TEXT NOT NULL DEFAULT '默认分组', `read` INTEGER NOT NULL, `variable` TEXT, `type` INTEGER NOT NULL DEFAULT 0, `durPos` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`origin`, `link`, `sort`))",
  1334. "fields": [
  1335. {
  1336. "fieldPath": "origin",
  1337. "columnName": "origin",
  1338. "affinity": "TEXT",
  1339. "notNull": true
  1340. },
  1341. {
  1342. "fieldPath": "sort",
  1343. "columnName": "sort",
  1344. "affinity": "TEXT",
  1345. "notNull": true
  1346. },
  1347. {
  1348. "fieldPath": "title",
  1349. "columnName": "title",
  1350. "affinity": "TEXT",
  1351. "notNull": true
  1352. },
  1353. {
  1354. "fieldPath": "order",
  1355. "columnName": "order",
  1356. "affinity": "INTEGER",
  1357. "notNull": true
  1358. },
  1359. {
  1360. "fieldPath": "link",
  1361. "columnName": "link",
  1362. "affinity": "TEXT",
  1363. "notNull": true
  1364. },
  1365. {
  1366. "fieldPath": "pubDate",
  1367. "columnName": "pubDate",
  1368. "affinity": "TEXT"
  1369. },
  1370. {
  1371. "fieldPath": "description",
  1372. "columnName": "description",
  1373. "affinity": "TEXT"
  1374. },
  1375. {
  1376. "fieldPath": "content",
  1377. "columnName": "content",
  1378. "affinity": "TEXT"
  1379. },
  1380. {
  1381. "fieldPath": "image",
  1382. "columnName": "image",
  1383. "affinity": "TEXT"
  1384. },
  1385. {
  1386. "fieldPath": "group",
  1387. "columnName": "group",
  1388. "affinity": "TEXT",
  1389. "notNull": true,
  1390. "defaultValue": "'默认分组'"
  1391. },
  1392. {
  1393. "fieldPath": "read",
  1394. "columnName": "read",
  1395. "affinity": "INTEGER",
  1396. "notNull": true
  1397. },
  1398. {
  1399. "fieldPath": "variable",
  1400. "columnName": "variable",
  1401. "affinity": "TEXT"
  1402. },
  1403. {
  1404. "fieldPath": "type",
  1405. "columnName": "type",
  1406. "affinity": "INTEGER",
  1407. "notNull": true,
  1408. "defaultValue": "0"
  1409. },
  1410. {
  1411. "fieldPath": "durPos",
  1412. "columnName": "durPos",
  1413. "affinity": "INTEGER",
  1414. "notNull": true,
  1415. "defaultValue": "0"
  1416. }
  1417. ],
  1418. "primaryKey": {
  1419. "autoGenerate": false,
  1420. "columnNames": [
  1421. "origin",
  1422. "link",
  1423. "sort"
  1424. ]
  1425. }
  1426. },
  1427. {
  1428. "tableName": "rssReadRecords",
  1429. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`record` TEXT NOT NULL, `title` TEXT, `readTime` INTEGER, `read` INTEGER NOT NULL, `origin` TEXT NOT NULL DEFAULT '', `sort` TEXT NOT NULL DEFAULT '', `image` TEXT, `type` INTEGER NOT NULL DEFAULT 0, `durPos` INTEGER NOT NULL DEFAULT 0, `pubDate` TEXT, PRIMARY KEY(`record`))",
  1430. "fields": [
  1431. {
  1432. "fieldPath": "record",
  1433. "columnName": "record",
  1434. "affinity": "TEXT",
  1435. "notNull": true
  1436. },
  1437. {
  1438. "fieldPath": "title",
  1439. "columnName": "title",
  1440. "affinity": "TEXT"
  1441. },
  1442. {
  1443. "fieldPath": "readTime",
  1444. "columnName": "readTime",
  1445. "affinity": "INTEGER"
  1446. },
  1447. {
  1448. "fieldPath": "read",
  1449. "columnName": "read",
  1450. "affinity": "INTEGER",
  1451. "notNull": true
  1452. },
  1453. {
  1454. "fieldPath": "origin",
  1455. "columnName": "origin",
  1456. "affinity": "TEXT",
  1457. "notNull": true,
  1458. "defaultValue": "''"
  1459. },
  1460. {
  1461. "fieldPath": "sort",
  1462. "columnName": "sort",
  1463. "affinity": "TEXT",
  1464. "notNull": true,
  1465. "defaultValue": "''"
  1466. },
  1467. {
  1468. "fieldPath": "image",
  1469. "columnName": "image",
  1470. "affinity": "TEXT"
  1471. },
  1472. {
  1473. "fieldPath": "type",
  1474. "columnName": "type",
  1475. "affinity": "INTEGER",
  1476. "notNull": true,
  1477. "defaultValue": "0"
  1478. },
  1479. {
  1480. "fieldPath": "durPos",
  1481. "columnName": "durPos",
  1482. "affinity": "INTEGER",
  1483. "notNull": true,
  1484. "defaultValue": "0"
  1485. },
  1486. {
  1487. "fieldPath": "pubDate",
  1488. "columnName": "pubDate",
  1489. "affinity": "TEXT"
  1490. }
  1491. ],
  1492. "primaryKey": {
  1493. "autoGenerate": false,
  1494. "columnNames": [
  1495. "record"
  1496. ]
  1497. },
  1498. "indices": [
  1499. {
  1500. "name": "index_rssReadRecords_origin",
  1501. "unique": false,
  1502. "columnNames": [
  1503. "origin"
  1504. ],
  1505. "orders": [],
  1506. "createSql": "CREATE INDEX IF NOT EXISTS `index_rssReadRecords_origin` ON `${TABLE_NAME}` (`origin`)"
  1507. }
  1508. ]
  1509. },
  1510. {
  1511. "tableName": "readRecordDetail",
  1512. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`deviceId` TEXT NOT NULL, `bookName` TEXT NOT NULL, `bookAuthor` TEXT NOT NULL DEFAULT '', `date` TEXT NOT NULL, `readTime` INTEGER NOT NULL DEFAULT 0, `readWords` INTEGER NOT NULL DEFAULT 0, `firstReadTime` INTEGER NOT NULL DEFAULT 0, `lastReadTime` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`deviceId`, `bookName`, `bookAuthor`, `date`))",
  1513. "fields": [
  1514. {
  1515. "fieldPath": "deviceId",
  1516. "columnName": "deviceId",
  1517. "affinity": "TEXT",
  1518. "notNull": true
  1519. },
  1520. {
  1521. "fieldPath": "bookName",
  1522. "columnName": "bookName",
  1523. "affinity": "TEXT",
  1524. "notNull": true
  1525. },
  1526. {
  1527. "fieldPath": "bookAuthor",
  1528. "columnName": "bookAuthor",
  1529. "affinity": "TEXT",
  1530. "notNull": true,
  1531. "defaultValue": "''"
  1532. },
  1533. {
  1534. "fieldPath": "date",
  1535. "columnName": "date",
  1536. "affinity": "TEXT",
  1537. "notNull": true
  1538. },
  1539. {
  1540. "fieldPath": "readTime",
  1541. "columnName": "readTime",
  1542. "affinity": "INTEGER",
  1543. "notNull": true,
  1544. "defaultValue": "0"
  1545. },
  1546. {
  1547. "fieldPath": "readWords",
  1548. "columnName": "readWords",
  1549. "affinity": "INTEGER",
  1550. "notNull": true,
  1551. "defaultValue": "0"
  1552. },
  1553. {
  1554. "fieldPath": "firstReadTime",
  1555. "columnName": "firstReadTime",
  1556. "affinity": "INTEGER",
  1557. "notNull": true,
  1558. "defaultValue": "0"
  1559. },
  1560. {
  1561. "fieldPath": "lastReadTime",
  1562. "columnName": "lastReadTime",
  1563. "affinity": "INTEGER",
  1564. "notNull": true,
  1565. "defaultValue": "0"
  1566. }
  1567. ],
  1568. "primaryKey": {
  1569. "autoGenerate": false,
  1570. "columnNames": [
  1571. "deviceId",
  1572. "bookName",
  1573. "bookAuthor",
  1574. "date"
  1575. ]
  1576. }
  1577. },
  1578. {
  1579. "tableName": "readRecordSession",
  1580. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `deviceId` TEXT NOT NULL, `bookName` TEXT NOT NULL, `bookAuthor` TEXT NOT NULL DEFAULT '', `startTime` INTEGER NOT NULL, `endTime` INTEGER NOT NULL, `words` INTEGER NOT NULL)",
  1581. "fields": [
  1582. {
  1583. "fieldPath": "id",
  1584. "columnName": "id",
  1585. "affinity": "INTEGER",
  1586. "notNull": true
  1587. },
  1588. {
  1589. "fieldPath": "deviceId",
  1590. "columnName": "deviceId",
  1591. "affinity": "TEXT",
  1592. "notNull": true
  1593. },
  1594. {
  1595. "fieldPath": "bookName",
  1596. "columnName": "bookName",
  1597. "affinity": "TEXT",
  1598. "notNull": true
  1599. },
  1600. {
  1601. "fieldPath": "bookAuthor",
  1602. "columnName": "bookAuthor",
  1603. "affinity": "TEXT",
  1604. "notNull": true,
  1605. "defaultValue": "''"
  1606. },
  1607. {
  1608. "fieldPath": "startTime",
  1609. "columnName": "startTime",
  1610. "affinity": "INTEGER",
  1611. "notNull": true
  1612. },
  1613. {
  1614. "fieldPath": "endTime",
  1615. "columnName": "endTime",
  1616. "affinity": "INTEGER",
  1617. "notNull": true
  1618. },
  1619. {
  1620. "fieldPath": "words",
  1621. "columnName": "words",
  1622. "affinity": "INTEGER",
  1623. "notNull": true
  1624. }
  1625. ],
  1626. "primaryKey": {
  1627. "autoGenerate": true,
  1628. "columnNames": [
  1629. "id"
  1630. ]
  1631. }
  1632. },
  1633. {
  1634. "tableName": "rssStars",
  1635. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`origin` TEXT NOT NULL, `sort` TEXT NOT NULL, `title` TEXT NOT NULL, `starTime` INTEGER NOT NULL, `link` TEXT NOT NULL, `pubDate` TEXT, `description` TEXT, `content` TEXT, `image` TEXT, `group` TEXT NOT NULL DEFAULT '默认分组', `variable` TEXT, `type` INTEGER NOT NULL DEFAULT 0, `durPos` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`origin`, `link`))",
  1636. "fields": [
  1637. {
  1638. "fieldPath": "origin",
  1639. "columnName": "origin",
  1640. "affinity": "TEXT",
  1641. "notNull": true
  1642. },
  1643. {
  1644. "fieldPath": "sort",
  1645. "columnName": "sort",
  1646. "affinity": "TEXT",
  1647. "notNull": true
  1648. },
  1649. {
  1650. "fieldPath": "title",
  1651. "columnName": "title",
  1652. "affinity": "TEXT",
  1653. "notNull": true
  1654. },
  1655. {
  1656. "fieldPath": "starTime",
  1657. "columnName": "starTime",
  1658. "affinity": "INTEGER",
  1659. "notNull": true
  1660. },
  1661. {
  1662. "fieldPath": "link",
  1663. "columnName": "link",
  1664. "affinity": "TEXT",
  1665. "notNull": true
  1666. },
  1667. {
  1668. "fieldPath": "pubDate",
  1669. "columnName": "pubDate",
  1670. "affinity": "TEXT"
  1671. },
  1672. {
  1673. "fieldPath": "description",
  1674. "columnName": "description",
  1675. "affinity": "TEXT"
  1676. },
  1677. {
  1678. "fieldPath": "content",
  1679. "columnName": "content",
  1680. "affinity": "TEXT"
  1681. },
  1682. {
  1683. "fieldPath": "image",
  1684. "columnName": "image",
  1685. "affinity": "TEXT"
  1686. },
  1687. {
  1688. "fieldPath": "group",
  1689. "columnName": "group",
  1690. "affinity": "TEXT",
  1691. "notNull": true,
  1692. "defaultValue": "'默认分组'"
  1693. },
  1694. {
  1695. "fieldPath": "variable",
  1696. "columnName": "variable",
  1697. "affinity": "TEXT"
  1698. },
  1699. {
  1700. "fieldPath": "type",
  1701. "columnName": "type",
  1702. "affinity": "INTEGER",
  1703. "notNull": true,
  1704. "defaultValue": "0"
  1705. },
  1706. {
  1707. "fieldPath": "durPos",
  1708. "columnName": "durPos",
  1709. "affinity": "INTEGER",
  1710. "notNull": true,
  1711. "defaultValue": "0"
  1712. }
  1713. ],
  1714. "primaryKey": {
  1715. "autoGenerate": false,
  1716. "columnNames": [
  1717. "origin",
  1718. "link"
  1719. ]
  1720. }
  1721. },
  1722. {
  1723. "tableName": "txtTocRules",
  1724. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `name` TEXT NOT NULL, `rule` TEXT NOT NULL, `example` TEXT, `serialNumber` INTEGER NOT NULL, `enable` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  1725. "fields": [
  1726. {
  1727. "fieldPath": "id",
  1728. "columnName": "id",
  1729. "affinity": "INTEGER",
  1730. "notNull": true
  1731. },
  1732. {
  1733. "fieldPath": "name",
  1734. "columnName": "name",
  1735. "affinity": "TEXT",
  1736. "notNull": true
  1737. },
  1738. {
  1739. "fieldPath": "rule",
  1740. "columnName": "rule",
  1741. "affinity": "TEXT",
  1742. "notNull": true
  1743. },
  1744. {
  1745. "fieldPath": "example",
  1746. "columnName": "example",
  1747. "affinity": "TEXT"
  1748. },
  1749. {
  1750. "fieldPath": "serialNumber",
  1751. "columnName": "serialNumber",
  1752. "affinity": "INTEGER",
  1753. "notNull": true
  1754. },
  1755. {
  1756. "fieldPath": "enable",
  1757. "columnName": "enable",
  1758. "affinity": "INTEGER",
  1759. "notNull": true
  1760. }
  1761. ],
  1762. "primaryKey": {
  1763. "autoGenerate": false,
  1764. "columnNames": [
  1765. "id"
  1766. ]
  1767. }
  1768. },
  1769. {
  1770. "tableName": "readRecord",
  1771. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`deviceId` TEXT NOT NULL, `bookName` TEXT NOT NULL, `bookAuthor` TEXT NOT NULL DEFAULT '', `readTime` INTEGER NOT NULL DEFAULT 0, `lastRead` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`deviceId`, `bookName`, `bookAuthor`))",
  1772. "fields": [
  1773. {
  1774. "fieldPath": "deviceId",
  1775. "columnName": "deviceId",
  1776. "affinity": "TEXT",
  1777. "notNull": true
  1778. },
  1779. {
  1780. "fieldPath": "bookName",
  1781. "columnName": "bookName",
  1782. "affinity": "TEXT",
  1783. "notNull": true
  1784. },
  1785. {
  1786. "fieldPath": "bookAuthor",
  1787. "columnName": "bookAuthor",
  1788. "affinity": "TEXT",
  1789. "notNull": true,
  1790. "defaultValue": "''"
  1791. },
  1792. {
  1793. "fieldPath": "readTime",
  1794. "columnName": "readTime",
  1795. "affinity": "INTEGER",
  1796. "notNull": true,
  1797. "defaultValue": "0"
  1798. },
  1799. {
  1800. "fieldPath": "lastRead",
  1801. "columnName": "lastRead",
  1802. "affinity": "INTEGER",
  1803. "notNull": true,
  1804. "defaultValue": "0"
  1805. }
  1806. ],
  1807. "primaryKey": {
  1808. "autoGenerate": false,
  1809. "columnNames": [
  1810. "deviceId",
  1811. "bookName",
  1812. "bookAuthor"
  1813. ]
  1814. }
  1815. },
  1816. {
  1817. "tableName": "httpTTS",
  1818. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `name` TEXT NOT NULL, `url` TEXT NOT NULL, `contentType` TEXT, `concurrentRate` TEXT DEFAULT '0', `loginUrl` TEXT, `loginUi` TEXT, `header` TEXT, `jsLib` TEXT, `enabledCookieJar` INTEGER DEFAULT 0, `loginCheckJs` TEXT, `lastUpdateTime` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`id`))",
  1819. "fields": [
  1820. {
  1821. "fieldPath": "id",
  1822. "columnName": "id",
  1823. "affinity": "INTEGER",
  1824. "notNull": true
  1825. },
  1826. {
  1827. "fieldPath": "name",
  1828. "columnName": "name",
  1829. "affinity": "TEXT",
  1830. "notNull": true
  1831. },
  1832. {
  1833. "fieldPath": "url",
  1834. "columnName": "url",
  1835. "affinity": "TEXT",
  1836. "notNull": true
  1837. },
  1838. {
  1839. "fieldPath": "contentType",
  1840. "columnName": "contentType",
  1841. "affinity": "TEXT"
  1842. },
  1843. {
  1844. "fieldPath": "concurrentRate",
  1845. "columnName": "concurrentRate",
  1846. "affinity": "TEXT",
  1847. "defaultValue": "'0'"
  1848. },
  1849. {
  1850. "fieldPath": "loginUrl",
  1851. "columnName": "loginUrl",
  1852. "affinity": "TEXT"
  1853. },
  1854. {
  1855. "fieldPath": "loginUi",
  1856. "columnName": "loginUi",
  1857. "affinity": "TEXT"
  1858. },
  1859. {
  1860. "fieldPath": "header",
  1861. "columnName": "header",
  1862. "affinity": "TEXT"
  1863. },
  1864. {
  1865. "fieldPath": "jsLib",
  1866. "columnName": "jsLib",
  1867. "affinity": "TEXT"
  1868. },
  1869. {
  1870. "fieldPath": "enabledCookieJar",
  1871. "columnName": "enabledCookieJar",
  1872. "affinity": "INTEGER",
  1873. "defaultValue": "0"
  1874. },
  1875. {
  1876. "fieldPath": "loginCheckJs",
  1877. "columnName": "loginCheckJs",
  1878. "affinity": "TEXT"
  1879. },
  1880. {
  1881. "fieldPath": "lastUpdateTime",
  1882. "columnName": "lastUpdateTime",
  1883. "affinity": "INTEGER",
  1884. "notNull": true,
  1885. "defaultValue": "0"
  1886. }
  1887. ],
  1888. "primaryKey": {
  1889. "autoGenerate": false,
  1890. "columnNames": [
  1891. "id"
  1892. ]
  1893. }
  1894. },
  1895. {
  1896. "tableName": "caches",
  1897. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`key` TEXT NOT NULL, `value` TEXT, `deadline` INTEGER NOT NULL, PRIMARY KEY(`key`))",
  1898. "fields": [
  1899. {
  1900. "fieldPath": "key",
  1901. "columnName": "key",
  1902. "affinity": "TEXT",
  1903. "notNull": true
  1904. },
  1905. {
  1906. "fieldPath": "value",
  1907. "columnName": "value",
  1908. "affinity": "TEXT"
  1909. },
  1910. {
  1911. "fieldPath": "deadline",
  1912. "columnName": "deadline",
  1913. "affinity": "INTEGER",
  1914. "notNull": true
  1915. }
  1916. ],
  1917. "primaryKey": {
  1918. "autoGenerate": false,
  1919. "columnNames": [
  1920. "key"
  1921. ]
  1922. },
  1923. "indices": [
  1924. {
  1925. "name": "index_caches_key",
  1926. "unique": true,
  1927. "columnNames": [
  1928. "key"
  1929. ],
  1930. "orders": [],
  1931. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_caches_key` ON `${TABLE_NAME}` (`key`)"
  1932. }
  1933. ]
  1934. },
  1935. {
  1936. "tableName": "ruleSubs",
  1937. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `name` TEXT NOT NULL, `url` TEXT NOT NULL, `type` INTEGER NOT NULL, `customOrder` INTEGER NOT NULL, `autoUpdate` INTEGER NOT NULL, `update` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  1938. "fields": [
  1939. {
  1940. "fieldPath": "id",
  1941. "columnName": "id",
  1942. "affinity": "INTEGER",
  1943. "notNull": true
  1944. },
  1945. {
  1946. "fieldPath": "name",
  1947. "columnName": "name",
  1948. "affinity": "TEXT",
  1949. "notNull": true
  1950. },
  1951. {
  1952. "fieldPath": "url",
  1953. "columnName": "url",
  1954. "affinity": "TEXT",
  1955. "notNull": true
  1956. },
  1957. {
  1958. "fieldPath": "type",
  1959. "columnName": "type",
  1960. "affinity": "INTEGER",
  1961. "notNull": true
  1962. },
  1963. {
  1964. "fieldPath": "customOrder",
  1965. "columnName": "customOrder",
  1966. "affinity": "INTEGER",
  1967. "notNull": true
  1968. },
  1969. {
  1970. "fieldPath": "autoUpdate",
  1971. "columnName": "autoUpdate",
  1972. "affinity": "INTEGER",
  1973. "notNull": true
  1974. },
  1975. {
  1976. "fieldPath": "update",
  1977. "columnName": "update",
  1978. "affinity": "INTEGER",
  1979. "notNull": true
  1980. }
  1981. ],
  1982. "primaryKey": {
  1983. "autoGenerate": false,
  1984. "columnNames": [
  1985. "id"
  1986. ]
  1987. }
  1988. },
  1989. {
  1990. "tableName": "dictRules",
  1991. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`name` TEXT NOT NULL, `urlRule` TEXT NOT NULL, `showRule` TEXT NOT NULL, `enabled` INTEGER NOT NULL DEFAULT 1, `sortNumber` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`name`))",
  1992. "fields": [
  1993. {
  1994. "fieldPath": "name",
  1995. "columnName": "name",
  1996. "affinity": "TEXT",
  1997. "notNull": true
  1998. },
  1999. {
  2000. "fieldPath": "urlRule",
  2001. "columnName": "urlRule",
  2002. "affinity": "TEXT",
  2003. "notNull": true
  2004. },
  2005. {
  2006. "fieldPath": "showRule",
  2007. "columnName": "showRule",
  2008. "affinity": "TEXT",
  2009. "notNull": true
  2010. },
  2011. {
  2012. "fieldPath": "enabled",
  2013. "columnName": "enabled",
  2014. "affinity": "INTEGER",
  2015. "notNull": true,
  2016. "defaultValue": "1"
  2017. },
  2018. {
  2019. "fieldPath": "sortNumber",
  2020. "columnName": "sortNumber",
  2021. "affinity": "INTEGER",
  2022. "notNull": true,
  2023. "defaultValue": "0"
  2024. }
  2025. ],
  2026. "primaryKey": {
  2027. "autoGenerate": false,
  2028. "columnNames": [
  2029. "name"
  2030. ]
  2031. }
  2032. },
  2033. {
  2034. "tableName": "keyboardAssists",
  2035. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`type` INTEGER NOT NULL DEFAULT 0, `key` TEXT NOT NULL DEFAULT '', `value` TEXT NOT NULL DEFAULT '', `serialNo` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`type`, `key`))",
  2036. "fields": [
  2037. {
  2038. "fieldPath": "type",
  2039. "columnName": "type",
  2040. "affinity": "INTEGER",
  2041. "notNull": true,
  2042. "defaultValue": "0"
  2043. },
  2044. {
  2045. "fieldPath": "key",
  2046. "columnName": "key",
  2047. "affinity": "TEXT",
  2048. "notNull": true,
  2049. "defaultValue": "''"
  2050. },
  2051. {
  2052. "fieldPath": "value",
  2053. "columnName": "value",
  2054. "affinity": "TEXT",
  2055. "notNull": true,
  2056. "defaultValue": "''"
  2057. },
  2058. {
  2059. "fieldPath": "serialNo",
  2060. "columnName": "serialNo",
  2061. "affinity": "INTEGER",
  2062. "notNull": true,
  2063. "defaultValue": "0"
  2064. }
  2065. ],
  2066. "primaryKey": {
  2067. "autoGenerate": false,
  2068. "columnNames": [
  2069. "type",
  2070. "key"
  2071. ]
  2072. }
  2073. },
  2074. {
  2075. "tableName": "servers",
  2076. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `name` TEXT NOT NULL, `type` TEXT NOT NULL, `config` TEXT, `sortNumber` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  2077. "fields": [
  2078. {
  2079. "fieldPath": "id",
  2080. "columnName": "id",
  2081. "affinity": "INTEGER",
  2082. "notNull": true
  2083. },
  2084. {
  2085. "fieldPath": "name",
  2086. "columnName": "name",
  2087. "affinity": "TEXT",
  2088. "notNull": true
  2089. },
  2090. {
  2091. "fieldPath": "type",
  2092. "columnName": "type",
  2093. "affinity": "TEXT",
  2094. "notNull": true
  2095. },
  2096. {
  2097. "fieldPath": "config",
  2098. "columnName": "config",
  2099. "affinity": "TEXT"
  2100. },
  2101. {
  2102. "fieldPath": "sortNumber",
  2103. "columnName": "sortNumber",
  2104. "affinity": "INTEGER",
  2105. "notNull": true
  2106. }
  2107. ],
  2108. "primaryKey": {
  2109. "autoGenerate": false,
  2110. "columnNames": [
  2111. "id"
  2112. ]
  2113. }
  2114. },
  2115. {
  2116. "tableName": "search_content_history",
  2117. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `bookName` TEXT DEFAULT '', `bookAuthor` TEXT DEFAULT '', `query` TEXT NOT NULL, `time` INTEGER NOT NULL)",
  2118. "fields": [
  2119. {
  2120. "fieldPath": "id",
  2121. "columnName": "id",
  2122. "affinity": "INTEGER",
  2123. "notNull": true
  2124. },
  2125. {
  2126. "fieldPath": "bookName",
  2127. "columnName": "bookName",
  2128. "affinity": "TEXT",
  2129. "defaultValue": "''"
  2130. },
  2131. {
  2132. "fieldPath": "bookAuthor",
  2133. "columnName": "bookAuthor",
  2134. "affinity": "TEXT",
  2135. "defaultValue": "''"
  2136. },
  2137. {
  2138. "fieldPath": "query",
  2139. "columnName": "query",
  2140. "affinity": "TEXT",
  2141. "notNull": true
  2142. },
  2143. {
  2144. "fieldPath": "time",
  2145. "columnName": "time",
  2146. "affinity": "INTEGER",
  2147. "notNull": true
  2148. }
  2149. ],
  2150. "primaryKey": {
  2151. "autoGenerate": true,
  2152. "columnNames": [
  2153. "id"
  2154. ]
  2155. },
  2156. "indices": [
  2157. {
  2158. "name": "index_search_content_history_bookName_bookAuthor_query",
  2159. "unique": true,
  2160. "columnNames": [
  2161. "bookName",
  2162. "bookAuthor",
  2163. "query"
  2164. ],
  2165. "orders": [],
  2166. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_search_content_history_bookName_bookAuthor_query` ON `${TABLE_NAME}` (`bookName`, `bookAuthor`, `query`)"
  2167. }
  2168. ]
  2169. },
  2170. {
  2171. "tableName": "homepage_modules",
  2172. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `sourceUrl` TEXT NOT NULL, `moduleKey` TEXT NOT NULL, `type` TEXT NOT NULL, `title` TEXT NOT NULL, `args` TEXT, `layoutConfig` TEXT, `url` TEXT, `isEnabled` INTEGER NOT NULL, `sortOrder` INTEGER NOT NULL, `customSetId` TEXT, `isUserCreated` INTEGER NOT NULL, `customTitle` TEXT, `customSetTitle` TEXT, `sourceJsonHash` TEXT, `syncedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  2173. "fields": [
  2174. {
  2175. "fieldPath": "id",
  2176. "columnName": "id",
  2177. "affinity": "TEXT",
  2178. "notNull": true
  2179. },
  2180. {
  2181. "fieldPath": "sourceUrl",
  2182. "columnName": "sourceUrl",
  2183. "affinity": "TEXT",
  2184. "notNull": true
  2185. },
  2186. {
  2187. "fieldPath": "moduleKey",
  2188. "columnName": "moduleKey",
  2189. "affinity": "TEXT",
  2190. "notNull": true
  2191. },
  2192. {
  2193. "fieldPath": "type",
  2194. "columnName": "type",
  2195. "affinity": "TEXT",
  2196. "notNull": true
  2197. },
  2198. {
  2199. "fieldPath": "title",
  2200. "columnName": "title",
  2201. "affinity": "TEXT",
  2202. "notNull": true
  2203. },
  2204. {
  2205. "fieldPath": "args",
  2206. "columnName": "args",
  2207. "affinity": "TEXT"
  2208. },
  2209. {
  2210. "fieldPath": "layoutConfig",
  2211. "columnName": "layoutConfig",
  2212. "affinity": "TEXT"
  2213. },
  2214. {
  2215. "fieldPath": "url",
  2216. "columnName": "url",
  2217. "affinity": "TEXT"
  2218. },
  2219. {
  2220. "fieldPath": "isEnabled",
  2221. "columnName": "isEnabled",
  2222. "affinity": "INTEGER",
  2223. "notNull": true
  2224. },
  2225. {
  2226. "fieldPath": "sortOrder",
  2227. "columnName": "sortOrder",
  2228. "affinity": "INTEGER",
  2229. "notNull": true
  2230. },
  2231. {
  2232. "fieldPath": "customSetId",
  2233. "columnName": "customSetId",
  2234. "affinity": "TEXT"
  2235. },
  2236. {
  2237. "fieldPath": "isUserCreated",
  2238. "columnName": "isUserCreated",
  2239. "affinity": "INTEGER",
  2240. "notNull": true
  2241. },
  2242. {
  2243. "fieldPath": "customTitle",
  2244. "columnName": "customTitle",
  2245. "affinity": "TEXT"
  2246. },
  2247. {
  2248. "fieldPath": "customSetTitle",
  2249. "columnName": "customSetTitle",
  2250. "affinity": "TEXT"
  2251. },
  2252. {
  2253. "fieldPath": "sourceJsonHash",
  2254. "columnName": "sourceJsonHash",
  2255. "affinity": "TEXT"
  2256. },
  2257. {
  2258. "fieldPath": "syncedAt",
  2259. "columnName": "syncedAt",
  2260. "affinity": "INTEGER",
  2261. "notNull": true
  2262. }
  2263. ],
  2264. "primaryKey": {
  2265. "autoGenerate": false,
  2266. "columnNames": [
  2267. "id"
  2268. ]
  2269. }
  2270. },
  2271. {
  2272. "tableName": "homepage_custom_sets",
  2273. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `name` TEXT NOT NULL, `sortOrder` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  2274. "fields": [
  2275. {
  2276. "fieldPath": "id",
  2277. "columnName": "id",
  2278. "affinity": "TEXT",
  2279. "notNull": true
  2280. },
  2281. {
  2282. "fieldPath": "name",
  2283. "columnName": "name",
  2284. "affinity": "TEXT",
  2285. "notNull": true
  2286. },
  2287. {
  2288. "fieldPath": "sortOrder",
  2289. "columnName": "sortOrder",
  2290. "affinity": "INTEGER",
  2291. "notNull": true
  2292. }
  2293. ],
  2294. "primaryKey": {
  2295. "autoGenerate": false,
  2296. "columnNames": [
  2297. "id"
  2298. ]
  2299. }
  2300. },
  2301. {
  2302. "tableName": "highlightRules",
  2303. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `name` TEXT NOT NULL, `pattern` TEXT NOT NULL, `sampleText` TEXT NOT NULL, `targetScope` INTEGER NOT NULL, `enabled` INTEGER NOT NULL, `position` INTEGER NOT NULL, `textColor` INTEGER, `bgColor` INTEGER, `underlineMode` INTEGER NOT NULL, `underlineColor` INTEGER, `underlineWidth` REAL NOT NULL, `underlineOffset` REAL NOT NULL, `underlineSvgPath` TEXT, `bgImage` TEXT, `bgImageFit` INTEGER NOT NULL, `bgImageScale` REAL NOT NULL, `configName` TEXT, `fontPath` TEXT, PRIMARY KEY(`id`))",
  2304. "fields": [
  2305. {
  2306. "fieldPath": "id",
  2307. "columnName": "id",
  2308. "affinity": "TEXT",
  2309. "notNull": true
  2310. },
  2311. {
  2312. "fieldPath": "name",
  2313. "columnName": "name",
  2314. "affinity": "TEXT",
  2315. "notNull": true
  2316. },
  2317. {
  2318. "fieldPath": "pattern",
  2319. "columnName": "pattern",
  2320. "affinity": "TEXT",
  2321. "notNull": true
  2322. },
  2323. {
  2324. "fieldPath": "sampleText",
  2325. "columnName": "sampleText",
  2326. "affinity": "TEXT",
  2327. "notNull": true
  2328. },
  2329. {
  2330. "fieldPath": "targetScope",
  2331. "columnName": "targetScope",
  2332. "affinity": "INTEGER",
  2333. "notNull": true
  2334. },
  2335. {
  2336. "fieldPath": "enabled",
  2337. "columnName": "enabled",
  2338. "affinity": "INTEGER",
  2339. "notNull": true
  2340. },
  2341. {
  2342. "fieldPath": "position",
  2343. "columnName": "position",
  2344. "affinity": "INTEGER",
  2345. "notNull": true
  2346. },
  2347. {
  2348. "fieldPath": "textColor",
  2349. "columnName": "textColor",
  2350. "affinity": "INTEGER"
  2351. },
  2352. {
  2353. "fieldPath": "bgColor",
  2354. "columnName": "bgColor",
  2355. "affinity": "INTEGER"
  2356. },
  2357. {
  2358. "fieldPath": "underlineMode",
  2359. "columnName": "underlineMode",
  2360. "affinity": "INTEGER",
  2361. "notNull": true
  2362. },
  2363. {
  2364. "fieldPath": "underlineColor",
  2365. "columnName": "underlineColor",
  2366. "affinity": "INTEGER"
  2367. },
  2368. {
  2369. "fieldPath": "underlineWidth",
  2370. "columnName": "underlineWidth",
  2371. "affinity": "REAL",
  2372. "notNull": true
  2373. },
  2374. {
  2375. "fieldPath": "underlineOffset",
  2376. "columnName": "underlineOffset",
  2377. "affinity": "REAL",
  2378. "notNull": true
  2379. },
  2380. {
  2381. "fieldPath": "underlineSvgPath",
  2382. "columnName": "underlineSvgPath",
  2383. "affinity": "TEXT"
  2384. },
  2385. {
  2386. "fieldPath": "bgImage",
  2387. "columnName": "bgImage",
  2388. "affinity": "TEXT"
  2389. },
  2390. {
  2391. "fieldPath": "bgImageFit",
  2392. "columnName": "bgImageFit",
  2393. "affinity": "INTEGER",
  2394. "notNull": true
  2395. },
  2396. {
  2397. "fieldPath": "bgImageScale",
  2398. "columnName": "bgImageScale",
  2399. "affinity": "REAL",
  2400. "notNull": true
  2401. },
  2402. {
  2403. "fieldPath": "configName",
  2404. "columnName": "configName",
  2405. "affinity": "TEXT"
  2406. },
  2407. {
  2408. "fieldPath": "fontPath",
  2409. "columnName": "fontPath",
  2410. "affinity": "TEXT"
  2411. }
  2412. ],
  2413. "primaryKey": {
  2414. "autoGenerate": false,
  2415. "columnNames": [
  2416. "id"
  2417. ]
  2418. }
  2419. },
  2420. {
  2421. "tableName": "ai_provider_profiles",
  2422. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `name` TEXT NOT NULL, `protocol` TEXT NOT NULL, `baseUrl` TEXT NOT NULL, `modelsUrl` TEXT, `apiKey` TEXT NOT NULL, `authType` TEXT NOT NULL, `secretRef` TEXT, `headersJson` TEXT, `chatPath` TEXT, `responsesPath` TEXT, `messagesPath` TEXT, `modelsPath` TEXT, `customHeadersJson` TEXT, `enabled` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  2423. "fields": [
  2424. {
  2425. "fieldPath": "id",
  2426. "columnName": "id",
  2427. "affinity": "TEXT",
  2428. "notNull": true
  2429. },
  2430. {
  2431. "fieldPath": "name",
  2432. "columnName": "name",
  2433. "affinity": "TEXT",
  2434. "notNull": true
  2435. },
  2436. {
  2437. "fieldPath": "protocol",
  2438. "columnName": "protocol",
  2439. "affinity": "TEXT",
  2440. "notNull": true
  2441. },
  2442. {
  2443. "fieldPath": "baseUrl",
  2444. "columnName": "baseUrl",
  2445. "affinity": "TEXT",
  2446. "notNull": true
  2447. },
  2448. {
  2449. "fieldPath": "modelsUrl",
  2450. "columnName": "modelsUrl",
  2451. "affinity": "TEXT"
  2452. },
  2453. {
  2454. "fieldPath": "apiKey",
  2455. "columnName": "apiKey",
  2456. "affinity": "TEXT",
  2457. "notNull": true
  2458. },
  2459. {
  2460. "fieldPath": "authType",
  2461. "columnName": "authType",
  2462. "affinity": "TEXT",
  2463. "notNull": true
  2464. },
  2465. {
  2466. "fieldPath": "secretRef",
  2467. "columnName": "secretRef",
  2468. "affinity": "TEXT"
  2469. },
  2470. {
  2471. "fieldPath": "headersJson",
  2472. "columnName": "headersJson",
  2473. "affinity": "TEXT"
  2474. },
  2475. {
  2476. "fieldPath": "chatPath",
  2477. "columnName": "chatPath",
  2478. "affinity": "TEXT"
  2479. },
  2480. {
  2481. "fieldPath": "responsesPath",
  2482. "columnName": "responsesPath",
  2483. "affinity": "TEXT"
  2484. },
  2485. {
  2486. "fieldPath": "messagesPath",
  2487. "columnName": "messagesPath",
  2488. "affinity": "TEXT"
  2489. },
  2490. {
  2491. "fieldPath": "modelsPath",
  2492. "columnName": "modelsPath",
  2493. "affinity": "TEXT"
  2494. },
  2495. {
  2496. "fieldPath": "customHeadersJson",
  2497. "columnName": "customHeadersJson",
  2498. "affinity": "TEXT"
  2499. },
  2500. {
  2501. "fieldPath": "enabled",
  2502. "columnName": "enabled",
  2503. "affinity": "INTEGER",
  2504. "notNull": true
  2505. },
  2506. {
  2507. "fieldPath": "createdAt",
  2508. "columnName": "createdAt",
  2509. "affinity": "INTEGER",
  2510. "notNull": true
  2511. },
  2512. {
  2513. "fieldPath": "updatedAt",
  2514. "columnName": "updatedAt",
  2515. "affinity": "INTEGER",
  2516. "notNull": true
  2517. }
  2518. ],
  2519. "primaryKey": {
  2520. "autoGenerate": false,
  2521. "columnNames": [
  2522. "id"
  2523. ]
  2524. }
  2525. },
  2526. {
  2527. "tableName": "ai_model_profiles",
  2528. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `providerId` TEXT NOT NULL, `displayName` TEXT NOT NULL, `modelId` TEXT NOT NULL, `contextWindow` INTEGER NOT NULL, `maxOutputTokens` INTEGER NOT NULL, `capabilities` TEXT NOT NULL, `defaultParamsJson` TEXT, `enabled` INTEGER NOT NULL, `sortNumber` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  2529. "fields": [
  2530. {
  2531. "fieldPath": "id",
  2532. "columnName": "id",
  2533. "affinity": "TEXT",
  2534. "notNull": true
  2535. },
  2536. {
  2537. "fieldPath": "providerId",
  2538. "columnName": "providerId",
  2539. "affinity": "TEXT",
  2540. "notNull": true
  2541. },
  2542. {
  2543. "fieldPath": "displayName",
  2544. "columnName": "displayName",
  2545. "affinity": "TEXT",
  2546. "notNull": true
  2547. },
  2548. {
  2549. "fieldPath": "modelId",
  2550. "columnName": "modelId",
  2551. "affinity": "TEXT",
  2552. "notNull": true
  2553. },
  2554. {
  2555. "fieldPath": "contextWindow",
  2556. "columnName": "contextWindow",
  2557. "affinity": "INTEGER",
  2558. "notNull": true
  2559. },
  2560. {
  2561. "fieldPath": "maxOutputTokens",
  2562. "columnName": "maxOutputTokens",
  2563. "affinity": "INTEGER",
  2564. "notNull": true
  2565. },
  2566. {
  2567. "fieldPath": "capabilities",
  2568. "columnName": "capabilities",
  2569. "affinity": "TEXT",
  2570. "notNull": true
  2571. },
  2572. {
  2573. "fieldPath": "defaultParamsJson",
  2574. "columnName": "defaultParamsJson",
  2575. "affinity": "TEXT"
  2576. },
  2577. {
  2578. "fieldPath": "enabled",
  2579. "columnName": "enabled",
  2580. "affinity": "INTEGER",
  2581. "notNull": true
  2582. },
  2583. {
  2584. "fieldPath": "sortNumber",
  2585. "columnName": "sortNumber",
  2586. "affinity": "INTEGER",
  2587. "notNull": true
  2588. },
  2589. {
  2590. "fieldPath": "createdAt",
  2591. "columnName": "createdAt",
  2592. "affinity": "INTEGER",
  2593. "notNull": true
  2594. },
  2595. {
  2596. "fieldPath": "updatedAt",
  2597. "columnName": "updatedAt",
  2598. "affinity": "INTEGER",
  2599. "notNull": true
  2600. }
  2601. ],
  2602. "primaryKey": {
  2603. "autoGenerate": false,
  2604. "columnNames": [
  2605. "id"
  2606. ]
  2607. },
  2608. "indices": [
  2609. {
  2610. "name": "index_ai_model_profiles_providerId",
  2611. "unique": false,
  2612. "columnNames": [
  2613. "providerId"
  2614. ],
  2615. "orders": [],
  2616. "createSql": "CREATE INDEX IF NOT EXISTS `index_ai_model_profiles_providerId` ON `${TABLE_NAME}` (`providerId`)"
  2617. }
  2618. ]
  2619. },
  2620. {
  2621. "tableName": "ai_task_presets",
  2622. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `taskType` TEXT NOT NULL, `name` TEXT NOT NULL, `modelProfileId` TEXT NOT NULL, `promptTemplate` TEXT NOT NULL, `paramsJson` TEXT, `chunkPolicyJson` TEXT, `enabled` INTEGER NOT NULL, `isDefault` INTEGER NOT NULL, `sortNumber` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  2623. "fields": [
  2624. {
  2625. "fieldPath": "id",
  2626. "columnName": "id",
  2627. "affinity": "TEXT",
  2628. "notNull": true
  2629. },
  2630. {
  2631. "fieldPath": "taskType",
  2632. "columnName": "taskType",
  2633. "affinity": "TEXT",
  2634. "notNull": true
  2635. },
  2636. {
  2637. "fieldPath": "name",
  2638. "columnName": "name",
  2639. "affinity": "TEXT",
  2640. "notNull": true
  2641. },
  2642. {
  2643. "fieldPath": "modelProfileId",
  2644. "columnName": "modelProfileId",
  2645. "affinity": "TEXT",
  2646. "notNull": true
  2647. },
  2648. {
  2649. "fieldPath": "promptTemplate",
  2650. "columnName": "promptTemplate",
  2651. "affinity": "TEXT",
  2652. "notNull": true
  2653. },
  2654. {
  2655. "fieldPath": "paramsJson",
  2656. "columnName": "paramsJson",
  2657. "affinity": "TEXT"
  2658. },
  2659. {
  2660. "fieldPath": "chunkPolicyJson",
  2661. "columnName": "chunkPolicyJson",
  2662. "affinity": "TEXT"
  2663. },
  2664. {
  2665. "fieldPath": "enabled",
  2666. "columnName": "enabled",
  2667. "affinity": "INTEGER",
  2668. "notNull": true
  2669. },
  2670. {
  2671. "fieldPath": "isDefault",
  2672. "columnName": "isDefault",
  2673. "affinity": "INTEGER",
  2674. "notNull": true
  2675. },
  2676. {
  2677. "fieldPath": "sortNumber",
  2678. "columnName": "sortNumber",
  2679. "affinity": "INTEGER",
  2680. "notNull": true
  2681. },
  2682. {
  2683. "fieldPath": "createdAt",
  2684. "columnName": "createdAt",
  2685. "affinity": "INTEGER",
  2686. "notNull": true
  2687. },
  2688. {
  2689. "fieldPath": "updatedAt",
  2690. "columnName": "updatedAt",
  2691. "affinity": "INTEGER",
  2692. "notNull": true
  2693. }
  2694. ],
  2695. "primaryKey": {
  2696. "autoGenerate": false,
  2697. "columnNames": [
  2698. "id"
  2699. ]
  2700. },
  2701. "indices": [
  2702. {
  2703. "name": "index_ai_task_presets_taskType",
  2704. "unique": false,
  2705. "columnNames": [
  2706. "taskType"
  2707. ],
  2708. "orders": [],
  2709. "createSql": "CREATE INDEX IF NOT EXISTS `index_ai_task_presets_taskType` ON `${TABLE_NAME}` (`taskType`)"
  2710. },
  2711. {
  2712. "name": "index_ai_task_presets_modelProfileId",
  2713. "unique": false,
  2714. "columnNames": [
  2715. "modelProfileId"
  2716. ],
  2717. "orders": [],
  2718. "createSql": "CREATE INDEX IF NOT EXISTS `index_ai_task_presets_modelProfileId` ON `${TABLE_NAME}` (`modelProfileId`)"
  2719. }
  2720. ]
  2721. },
  2722. {
  2723. "tableName": "ai_artifacts",
  2724. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `taskType` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `chapterIndex` INTEGER, `contentHash` TEXT NOT NULL, `promptHash` TEXT NOT NULL, `modelProfileId` TEXT NOT NULL, `status` INTEGER NOT NULL, `output` TEXT, `errorMessage` TEXT, `schemaVersion` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  2725. "fields": [
  2726. {
  2727. "fieldPath": "id",
  2728. "columnName": "id",
  2729. "affinity": "TEXT",
  2730. "notNull": true
  2731. },
  2732. {
  2733. "fieldPath": "taskType",
  2734. "columnName": "taskType",
  2735. "affinity": "TEXT",
  2736. "notNull": true
  2737. },
  2738. {
  2739. "fieldPath": "bookUrl",
  2740. "columnName": "bookUrl",
  2741. "affinity": "TEXT",
  2742. "notNull": true
  2743. },
  2744. {
  2745. "fieldPath": "chapterIndex",
  2746. "columnName": "chapterIndex",
  2747. "affinity": "INTEGER"
  2748. },
  2749. {
  2750. "fieldPath": "contentHash",
  2751. "columnName": "contentHash",
  2752. "affinity": "TEXT",
  2753. "notNull": true
  2754. },
  2755. {
  2756. "fieldPath": "promptHash",
  2757. "columnName": "promptHash",
  2758. "affinity": "TEXT",
  2759. "notNull": true
  2760. },
  2761. {
  2762. "fieldPath": "modelProfileId",
  2763. "columnName": "modelProfileId",
  2764. "affinity": "TEXT",
  2765. "notNull": true
  2766. },
  2767. {
  2768. "fieldPath": "status",
  2769. "columnName": "status",
  2770. "affinity": "INTEGER",
  2771. "notNull": true
  2772. },
  2773. {
  2774. "fieldPath": "output",
  2775. "columnName": "output",
  2776. "affinity": "TEXT"
  2777. },
  2778. {
  2779. "fieldPath": "errorMessage",
  2780. "columnName": "errorMessage",
  2781. "affinity": "TEXT"
  2782. },
  2783. {
  2784. "fieldPath": "schemaVersion",
  2785. "columnName": "schemaVersion",
  2786. "affinity": "INTEGER",
  2787. "notNull": true
  2788. },
  2789. {
  2790. "fieldPath": "createdAt",
  2791. "columnName": "createdAt",
  2792. "affinity": "INTEGER",
  2793. "notNull": true
  2794. },
  2795. {
  2796. "fieldPath": "updatedAt",
  2797. "columnName": "updatedAt",
  2798. "affinity": "INTEGER",
  2799. "notNull": true
  2800. }
  2801. ],
  2802. "primaryKey": {
  2803. "autoGenerate": false,
  2804. "columnNames": [
  2805. "id"
  2806. ]
  2807. },
  2808. "indices": [
  2809. {
  2810. "name": "index_ai_artifacts_bookUrl_chapterIndex_taskType",
  2811. "unique": false,
  2812. "columnNames": [
  2813. "bookUrl",
  2814. "chapterIndex",
  2815. "taskType"
  2816. ],
  2817. "orders": [],
  2818. "createSql": "CREATE INDEX IF NOT EXISTS `index_ai_artifacts_bookUrl_chapterIndex_taskType` ON `${TABLE_NAME}` (`bookUrl`, `chapterIndex`, `taskType`)"
  2819. },
  2820. {
  2821. "name": "index_ai_artifacts_contentHash_promptHash_modelProfileId",
  2822. "unique": false,
  2823. "columnNames": [
  2824. "contentHash",
  2825. "promptHash",
  2826. "modelProfileId"
  2827. ],
  2828. "orders": [],
  2829. "createSql": "CREATE INDEX IF NOT EXISTS `index_ai_artifacts_contentHash_promptHash_modelProfileId` ON `${TABLE_NAME}` (`contentHash`, `promptHash`, `modelProfileId`)"
  2830. }
  2831. ]
  2832. },
  2833. {
  2834. "tableName": "ai_chat_conversations",
  2835. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `title` TEXT NOT NULL, `reasoningLevel` TEXT NOT NULL, `modelProfileId` TEXT, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  2836. "fields": [
  2837. {
  2838. "fieldPath": "id",
  2839. "columnName": "id",
  2840. "affinity": "TEXT",
  2841. "notNull": true
  2842. },
  2843. {
  2844. "fieldPath": "title",
  2845. "columnName": "title",
  2846. "affinity": "TEXT",
  2847. "notNull": true
  2848. },
  2849. {
  2850. "fieldPath": "reasoningLevel",
  2851. "columnName": "reasoningLevel",
  2852. "affinity": "TEXT",
  2853. "notNull": true
  2854. },
  2855. {
  2856. "fieldPath": "modelProfileId",
  2857. "columnName": "modelProfileId",
  2858. "affinity": "TEXT"
  2859. },
  2860. {
  2861. "fieldPath": "createdAt",
  2862. "columnName": "createdAt",
  2863. "affinity": "INTEGER",
  2864. "notNull": true
  2865. },
  2866. {
  2867. "fieldPath": "updatedAt",
  2868. "columnName": "updatedAt",
  2869. "affinity": "INTEGER",
  2870. "notNull": true
  2871. }
  2872. ],
  2873. "primaryKey": {
  2874. "autoGenerate": false,
  2875. "columnNames": [
  2876. "id"
  2877. ]
  2878. }
  2879. },
  2880. {
  2881. "tableName": "ai_chat_messages",
  2882. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `conversationId` TEXT NOT NULL, `role` TEXT NOT NULL, `partsJson` TEXT NOT NULL, `createdAt` INTEGER NOT NULL, `branchIndex` INTEGER NOT NULL, `isSelected` INTEGER NOT NULL, `parentMessageId` TEXT, `thinkingDuration` INTEGER NOT NULL DEFAULT 0, PRIMARY KEY(`id`))",
  2883. "fields": [
  2884. {
  2885. "fieldPath": "id",
  2886. "columnName": "id",
  2887. "affinity": "TEXT",
  2888. "notNull": true
  2889. },
  2890. {
  2891. "fieldPath": "conversationId",
  2892. "columnName": "conversationId",
  2893. "affinity": "TEXT",
  2894. "notNull": true
  2895. },
  2896. {
  2897. "fieldPath": "role",
  2898. "columnName": "role",
  2899. "affinity": "TEXT",
  2900. "notNull": true
  2901. },
  2902. {
  2903. "fieldPath": "partsJson",
  2904. "columnName": "partsJson",
  2905. "affinity": "TEXT",
  2906. "notNull": true
  2907. },
  2908. {
  2909. "fieldPath": "createdAt",
  2910. "columnName": "createdAt",
  2911. "affinity": "INTEGER",
  2912. "notNull": true
  2913. },
  2914. {
  2915. "fieldPath": "branchIndex",
  2916. "columnName": "branchIndex",
  2917. "affinity": "INTEGER",
  2918. "notNull": true
  2919. },
  2920. {
  2921. "fieldPath": "isSelected",
  2922. "columnName": "isSelected",
  2923. "affinity": "INTEGER",
  2924. "notNull": true
  2925. },
  2926. {
  2927. "fieldPath": "parentMessageId",
  2928. "columnName": "parentMessageId",
  2929. "affinity": "TEXT"
  2930. },
  2931. {
  2932. "fieldPath": "thinkingDuration",
  2933. "columnName": "thinkingDuration",
  2934. "affinity": "INTEGER",
  2935. "notNull": true,
  2936. "defaultValue": "0"
  2937. }
  2938. ],
  2939. "primaryKey": {
  2940. "autoGenerate": false,
  2941. "columnNames": [
  2942. "id"
  2943. ]
  2944. },
  2945. "indices": [
  2946. {
  2947. "name": "index_ai_chat_messages_conversationId_createdAt",
  2948. "unique": false,
  2949. "columnNames": [
  2950. "conversationId",
  2951. "createdAt"
  2952. ],
  2953. "orders": [],
  2954. "createSql": "CREATE INDEX IF NOT EXISTS `index_ai_chat_messages_conversationId_createdAt` ON `${TABLE_NAME}` (`conversationId`, `createdAt`)"
  2955. }
  2956. ]
  2957. },
  2958. {
  2959. "tableName": "ai_memory",
  2960. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`conversationId` TEXT NOT NULL, `key` TEXT NOT NULL, `value` TEXT NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`conversationId`, `key`))",
  2961. "fields": [
  2962. {
  2963. "fieldPath": "conversationId",
  2964. "columnName": "conversationId",
  2965. "affinity": "TEXT",
  2966. "notNull": true
  2967. },
  2968. {
  2969. "fieldPath": "key",
  2970. "columnName": "key",
  2971. "affinity": "TEXT",
  2972. "notNull": true
  2973. },
  2974. {
  2975. "fieldPath": "value",
  2976. "columnName": "value",
  2977. "affinity": "TEXT",
  2978. "notNull": true
  2979. },
  2980. {
  2981. "fieldPath": "updatedAt",
  2982. "columnName": "updatedAt",
  2983. "affinity": "INTEGER",
  2984. "notNull": true
  2985. }
  2986. ],
  2987. "primaryKey": {
  2988. "autoGenerate": false,
  2989. "columnNames": [
  2990. "conversationId",
  2991. "key"
  2992. ]
  2993. },
  2994. "indices": [
  2995. {
  2996. "name": "index_ai_memory_conversationId",
  2997. "unique": false,
  2998. "columnNames": [
  2999. "conversationId"
  3000. ],
  3001. "orders": [],
  3002. "createSql": "CREATE INDEX IF NOT EXISTS `index_ai_memory_conversationId` ON `${TABLE_NAME}` (`conversationId`)"
  3003. }
  3004. ]
  3005. },
  3006. {
  3007. "tableName": "highlight_tag_rules",
  3008. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `title` TEXT NOT NULL, `pattern` TEXT NOT NULL, `enabled` INTEGER NOT NULL, `order` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3009. "fields": [
  3010. {
  3011. "fieldPath": "id",
  3012. "columnName": "id",
  3013. "affinity": "INTEGER",
  3014. "notNull": true
  3015. },
  3016. {
  3017. "fieldPath": "title",
  3018. "columnName": "title",
  3019. "affinity": "TEXT",
  3020. "notNull": true
  3021. },
  3022. {
  3023. "fieldPath": "pattern",
  3024. "columnName": "pattern",
  3025. "affinity": "TEXT",
  3026. "notNull": true
  3027. },
  3028. {
  3029. "fieldPath": "enabled",
  3030. "columnName": "enabled",
  3031. "affinity": "INTEGER",
  3032. "notNull": true
  3033. },
  3034. {
  3035. "fieldPath": "order",
  3036. "columnName": "order",
  3037. "affinity": "INTEGER",
  3038. "notNull": true
  3039. }
  3040. ],
  3041. "primaryKey": {
  3042. "autoGenerate": false,
  3043. "columnNames": [
  3044. "id"
  3045. ]
  3046. }
  3047. },
  3048. {
  3049. "tableName": "tag_group_rules",
  3050. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `pattern` TEXT NOT NULL, `groupName` TEXT NOT NULL, `order` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3051. "fields": [
  3052. {
  3053. "fieldPath": "id",
  3054. "columnName": "id",
  3055. "affinity": "INTEGER",
  3056. "notNull": true
  3057. },
  3058. {
  3059. "fieldPath": "pattern",
  3060. "columnName": "pattern",
  3061. "affinity": "TEXT",
  3062. "notNull": true
  3063. },
  3064. {
  3065. "fieldPath": "groupName",
  3066. "columnName": "groupName",
  3067. "affinity": "TEXT",
  3068. "notNull": true
  3069. },
  3070. {
  3071. "fieldPath": "order",
  3072. "columnName": "order",
  3073. "affinity": "INTEGER",
  3074. "notNull": true
  3075. }
  3076. ],
  3077. "primaryKey": {
  3078. "autoGenerate": false,
  3079. "columnNames": [
  3080. "id"
  3081. ]
  3082. }
  3083. },
  3084. {
  3085. "tableName": "book_content_processes",
  3086. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `chapterIndex` INTEGER, `kind` TEXT NOT NULL, `stage` TEXT NOT NULL, `target` TEXT NOT NULL, `anchorJson` TEXT NOT NULL, `actionJson` TEXT NOT NULL, `styleJson` TEXT, `source` TEXT NOT NULL, `aiArtifactId` TEXT, `sourceContentHash` TEXT, `enabled` INTEGER NOT NULL, `sortOrder` INTEGER NOT NULL, `status` INTEGER NOT NULL, `schemaVersion` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3087. "fields": [
  3088. {
  3089. "fieldPath": "id",
  3090. "columnName": "id",
  3091. "affinity": "TEXT",
  3092. "notNull": true
  3093. },
  3094. {
  3095. "fieldPath": "bookUrl",
  3096. "columnName": "bookUrl",
  3097. "affinity": "TEXT",
  3098. "notNull": true
  3099. },
  3100. {
  3101. "fieldPath": "chapterIndex",
  3102. "columnName": "chapterIndex",
  3103. "affinity": "INTEGER"
  3104. },
  3105. {
  3106. "fieldPath": "kind",
  3107. "columnName": "kind",
  3108. "affinity": "TEXT",
  3109. "notNull": true
  3110. },
  3111. {
  3112. "fieldPath": "stage",
  3113. "columnName": "stage",
  3114. "affinity": "TEXT",
  3115. "notNull": true
  3116. },
  3117. {
  3118. "fieldPath": "target",
  3119. "columnName": "target",
  3120. "affinity": "TEXT",
  3121. "notNull": true
  3122. },
  3123. {
  3124. "fieldPath": "anchorJson",
  3125. "columnName": "anchorJson",
  3126. "affinity": "TEXT",
  3127. "notNull": true
  3128. },
  3129. {
  3130. "fieldPath": "actionJson",
  3131. "columnName": "actionJson",
  3132. "affinity": "TEXT",
  3133. "notNull": true
  3134. },
  3135. {
  3136. "fieldPath": "styleJson",
  3137. "columnName": "styleJson",
  3138. "affinity": "TEXT"
  3139. },
  3140. {
  3141. "fieldPath": "source",
  3142. "columnName": "source",
  3143. "affinity": "TEXT",
  3144. "notNull": true
  3145. },
  3146. {
  3147. "fieldPath": "aiArtifactId",
  3148. "columnName": "aiArtifactId",
  3149. "affinity": "TEXT"
  3150. },
  3151. {
  3152. "fieldPath": "sourceContentHash",
  3153. "columnName": "sourceContentHash",
  3154. "affinity": "TEXT"
  3155. },
  3156. {
  3157. "fieldPath": "enabled",
  3158. "columnName": "enabled",
  3159. "affinity": "INTEGER",
  3160. "notNull": true
  3161. },
  3162. {
  3163. "fieldPath": "sortOrder",
  3164. "columnName": "sortOrder",
  3165. "affinity": "INTEGER",
  3166. "notNull": true
  3167. },
  3168. {
  3169. "fieldPath": "status",
  3170. "columnName": "status",
  3171. "affinity": "INTEGER",
  3172. "notNull": true
  3173. },
  3174. {
  3175. "fieldPath": "schemaVersion",
  3176. "columnName": "schemaVersion",
  3177. "affinity": "INTEGER",
  3178. "notNull": true
  3179. },
  3180. {
  3181. "fieldPath": "createdAt",
  3182. "columnName": "createdAt",
  3183. "affinity": "INTEGER",
  3184. "notNull": true
  3185. },
  3186. {
  3187. "fieldPath": "updatedAt",
  3188. "columnName": "updatedAt",
  3189. "affinity": "INTEGER",
  3190. "notNull": true
  3191. }
  3192. ],
  3193. "primaryKey": {
  3194. "autoGenerate": false,
  3195. "columnNames": [
  3196. "id"
  3197. ]
  3198. },
  3199. "indices": [
  3200. {
  3201. "name": "index_book_content_processes_bookUrl_chapterIndex_enabled_sortOrder",
  3202. "unique": false,
  3203. "columnNames": [
  3204. "bookUrl",
  3205. "chapterIndex",
  3206. "enabled",
  3207. "sortOrder"
  3208. ],
  3209. "orders": [],
  3210. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_content_processes_bookUrl_chapterIndex_enabled_sortOrder` ON `${TABLE_NAME}` (`bookUrl`, `chapterIndex`, `enabled`, `sortOrder`)"
  3211. },
  3212. {
  3213. "name": "index_book_content_processes_bookUrl_kind",
  3214. "unique": false,
  3215. "columnNames": [
  3216. "bookUrl",
  3217. "kind"
  3218. ],
  3219. "orders": [],
  3220. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_content_processes_bookUrl_kind` ON `${TABLE_NAME}` (`bookUrl`, `kind`)"
  3221. },
  3222. {
  3223. "name": "index_book_content_processes_aiArtifactId",
  3224. "unique": false,
  3225. "columnNames": [
  3226. "aiArtifactId"
  3227. ],
  3228. "orders": [],
  3229. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_content_processes_aiArtifactId` ON `${TABLE_NAME}` (`aiArtifactId`)"
  3230. }
  3231. ]
  3232. },
  3233. {
  3234. "tableName": "ai_prompt_presets",
  3235. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `taskType` TEXT NOT NULL, `name` TEXT NOT NULL, `instruction` TEXT NOT NULL, `enabled` INTEGER NOT NULL, `builtIn` INTEGER NOT NULL, `sortNumber` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3236. "fields": [
  3237. {
  3238. "fieldPath": "id",
  3239. "columnName": "id",
  3240. "affinity": "TEXT",
  3241. "notNull": true
  3242. },
  3243. {
  3244. "fieldPath": "taskType",
  3245. "columnName": "taskType",
  3246. "affinity": "TEXT",
  3247. "notNull": true
  3248. },
  3249. {
  3250. "fieldPath": "name",
  3251. "columnName": "name",
  3252. "affinity": "TEXT",
  3253. "notNull": true
  3254. },
  3255. {
  3256. "fieldPath": "instruction",
  3257. "columnName": "instruction",
  3258. "affinity": "TEXT",
  3259. "notNull": true
  3260. },
  3261. {
  3262. "fieldPath": "enabled",
  3263. "columnName": "enabled",
  3264. "affinity": "INTEGER",
  3265. "notNull": true
  3266. },
  3267. {
  3268. "fieldPath": "builtIn",
  3269. "columnName": "builtIn",
  3270. "affinity": "INTEGER",
  3271. "notNull": true
  3272. },
  3273. {
  3274. "fieldPath": "sortNumber",
  3275. "columnName": "sortNumber",
  3276. "affinity": "INTEGER",
  3277. "notNull": true
  3278. },
  3279. {
  3280. "fieldPath": "createdAt",
  3281. "columnName": "createdAt",
  3282. "affinity": "INTEGER",
  3283. "notNull": true
  3284. },
  3285. {
  3286. "fieldPath": "updatedAt",
  3287. "columnName": "updatedAt",
  3288. "affinity": "INTEGER",
  3289. "notNull": true
  3290. }
  3291. ],
  3292. "primaryKey": {
  3293. "autoGenerate": false,
  3294. "columnNames": [
  3295. "id"
  3296. ]
  3297. },
  3298. "indices": [
  3299. {
  3300. "name": "index_ai_prompt_presets_taskType_enabled_sortNumber",
  3301. "unique": false,
  3302. "columnNames": [
  3303. "taskType",
  3304. "enabled",
  3305. "sortNumber"
  3306. ],
  3307. "orders": [],
  3308. "createSql": "CREATE INDEX IF NOT EXISTS `index_ai_prompt_presets_taskType_enabled_sortNumber` ON `${TABLE_NAME}` (`taskType`, `enabled`, `sortNumber`)"
  3309. }
  3310. ]
  3311. },
  3312. {
  3313. "tableName": "book_character_profiles",
  3314. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `name` TEXT NOT NULL, `aliasesJson` TEXT NOT NULL, `avatarUri` TEXT, `tagsJson` TEXT NOT NULL, `role` TEXT NOT NULL, `voiceGender` TEXT NOT NULL DEFAULT 'unknown', `voiceAgeBand` TEXT NOT NULL DEFAULT 'unknown', `personality` TEXT NOT NULL, `summary` TEXT NOT NULL, `status` INTEGER NOT NULL, `source` TEXT NOT NULL, `confidence` REAL NOT NULL, `schemaVersion` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3315. "fields": [
  3316. {
  3317. "fieldPath": "id",
  3318. "columnName": "id",
  3319. "affinity": "TEXT",
  3320. "notNull": true
  3321. },
  3322. {
  3323. "fieldPath": "bookUrl",
  3324. "columnName": "bookUrl",
  3325. "affinity": "TEXT",
  3326. "notNull": true
  3327. },
  3328. {
  3329. "fieldPath": "name",
  3330. "columnName": "name",
  3331. "affinity": "TEXT",
  3332. "notNull": true
  3333. },
  3334. {
  3335. "fieldPath": "aliasesJson",
  3336. "columnName": "aliasesJson",
  3337. "affinity": "TEXT",
  3338. "notNull": true
  3339. },
  3340. {
  3341. "fieldPath": "avatarUri",
  3342. "columnName": "avatarUri",
  3343. "affinity": "TEXT"
  3344. },
  3345. {
  3346. "fieldPath": "tagsJson",
  3347. "columnName": "tagsJson",
  3348. "affinity": "TEXT",
  3349. "notNull": true
  3350. },
  3351. {
  3352. "fieldPath": "role",
  3353. "columnName": "role",
  3354. "affinity": "TEXT",
  3355. "notNull": true
  3356. },
  3357. {
  3358. "fieldPath": "voiceGender",
  3359. "columnName": "voiceGender",
  3360. "affinity": "TEXT",
  3361. "notNull": true,
  3362. "defaultValue": "'unknown'"
  3363. },
  3364. {
  3365. "fieldPath": "voiceAgeBand",
  3366. "columnName": "voiceAgeBand",
  3367. "affinity": "TEXT",
  3368. "notNull": true,
  3369. "defaultValue": "'unknown'"
  3370. },
  3371. {
  3372. "fieldPath": "personality",
  3373. "columnName": "personality",
  3374. "affinity": "TEXT",
  3375. "notNull": true
  3376. },
  3377. {
  3378. "fieldPath": "summary",
  3379. "columnName": "summary",
  3380. "affinity": "TEXT",
  3381. "notNull": true
  3382. },
  3383. {
  3384. "fieldPath": "status",
  3385. "columnName": "status",
  3386. "affinity": "INTEGER",
  3387. "notNull": true
  3388. },
  3389. {
  3390. "fieldPath": "source",
  3391. "columnName": "source",
  3392. "affinity": "TEXT",
  3393. "notNull": true
  3394. },
  3395. {
  3396. "fieldPath": "confidence",
  3397. "columnName": "confidence",
  3398. "affinity": "REAL",
  3399. "notNull": true
  3400. },
  3401. {
  3402. "fieldPath": "schemaVersion",
  3403. "columnName": "schemaVersion",
  3404. "affinity": "INTEGER",
  3405. "notNull": true
  3406. },
  3407. {
  3408. "fieldPath": "createdAt",
  3409. "columnName": "createdAt",
  3410. "affinity": "INTEGER",
  3411. "notNull": true
  3412. },
  3413. {
  3414. "fieldPath": "updatedAt",
  3415. "columnName": "updatedAt",
  3416. "affinity": "INTEGER",
  3417. "notNull": true
  3418. }
  3419. ],
  3420. "primaryKey": {
  3421. "autoGenerate": false,
  3422. "columnNames": [
  3423. "id"
  3424. ]
  3425. },
  3426. "indices": [
  3427. {
  3428. "name": "index_book_character_profiles_bookUrl_name",
  3429. "unique": true,
  3430. "columnNames": [
  3431. "bookUrl",
  3432. "name"
  3433. ],
  3434. "orders": [],
  3435. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_book_character_profiles_bookUrl_name` ON `${TABLE_NAME}` (`bookUrl`, `name`)"
  3436. },
  3437. {
  3438. "name": "index_book_character_profiles_bookUrl_updatedAt",
  3439. "unique": false,
  3440. "columnNames": [
  3441. "bookUrl",
  3442. "updatedAt"
  3443. ],
  3444. "orders": [],
  3445. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_character_profiles_bookUrl_updatedAt` ON `${TABLE_NAME}` (`bookUrl`, `updatedAt`)"
  3446. }
  3447. ]
  3448. },
  3449. {
  3450. "tableName": "book_character_events",
  3451. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `characterId` TEXT NOT NULL, `chapterIndex` INTEGER, `chapterTitle` TEXT NOT NULL, `eventTimeText` TEXT NOT NULL, `content` TEXT NOT NULL, `importance` INTEGER NOT NULL, `sourceTextHash` TEXT, `evidenceJson` TEXT NOT NULL, `source` TEXT NOT NULL, `confidence` REAL NOT NULL, `schemaVersion` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3452. "fields": [
  3453. {
  3454. "fieldPath": "id",
  3455. "columnName": "id",
  3456. "affinity": "TEXT",
  3457. "notNull": true
  3458. },
  3459. {
  3460. "fieldPath": "bookUrl",
  3461. "columnName": "bookUrl",
  3462. "affinity": "TEXT",
  3463. "notNull": true
  3464. },
  3465. {
  3466. "fieldPath": "characterId",
  3467. "columnName": "characterId",
  3468. "affinity": "TEXT",
  3469. "notNull": true
  3470. },
  3471. {
  3472. "fieldPath": "chapterIndex",
  3473. "columnName": "chapterIndex",
  3474. "affinity": "INTEGER"
  3475. },
  3476. {
  3477. "fieldPath": "chapterTitle",
  3478. "columnName": "chapterTitle",
  3479. "affinity": "TEXT",
  3480. "notNull": true
  3481. },
  3482. {
  3483. "fieldPath": "eventTimeText",
  3484. "columnName": "eventTimeText",
  3485. "affinity": "TEXT",
  3486. "notNull": true
  3487. },
  3488. {
  3489. "fieldPath": "content",
  3490. "columnName": "content",
  3491. "affinity": "TEXT",
  3492. "notNull": true
  3493. },
  3494. {
  3495. "fieldPath": "importance",
  3496. "columnName": "importance",
  3497. "affinity": "INTEGER",
  3498. "notNull": true
  3499. },
  3500. {
  3501. "fieldPath": "sourceTextHash",
  3502. "columnName": "sourceTextHash",
  3503. "affinity": "TEXT"
  3504. },
  3505. {
  3506. "fieldPath": "evidenceJson",
  3507. "columnName": "evidenceJson",
  3508. "affinity": "TEXT",
  3509. "notNull": true
  3510. },
  3511. {
  3512. "fieldPath": "source",
  3513. "columnName": "source",
  3514. "affinity": "TEXT",
  3515. "notNull": true
  3516. },
  3517. {
  3518. "fieldPath": "confidence",
  3519. "columnName": "confidence",
  3520. "affinity": "REAL",
  3521. "notNull": true
  3522. },
  3523. {
  3524. "fieldPath": "schemaVersion",
  3525. "columnName": "schemaVersion",
  3526. "affinity": "INTEGER",
  3527. "notNull": true
  3528. },
  3529. {
  3530. "fieldPath": "createdAt",
  3531. "columnName": "createdAt",
  3532. "affinity": "INTEGER",
  3533. "notNull": true
  3534. },
  3535. {
  3536. "fieldPath": "updatedAt",
  3537. "columnName": "updatedAt",
  3538. "affinity": "INTEGER",
  3539. "notNull": true
  3540. }
  3541. ],
  3542. "primaryKey": {
  3543. "autoGenerate": false,
  3544. "columnNames": [
  3545. "id"
  3546. ]
  3547. },
  3548. "indices": [
  3549. {
  3550. "name": "index_book_character_events_bookUrl_characterId_chapterIndex",
  3551. "unique": false,
  3552. "columnNames": [
  3553. "bookUrl",
  3554. "characterId",
  3555. "chapterIndex"
  3556. ],
  3557. "orders": [],
  3558. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_character_events_bookUrl_characterId_chapterIndex` ON `${TABLE_NAME}` (`bookUrl`, `characterId`, `chapterIndex`)"
  3559. },
  3560. {
  3561. "name": "index_book_character_events_bookUrl_chapterIndex",
  3562. "unique": false,
  3563. "columnNames": [
  3564. "bookUrl",
  3565. "chapterIndex"
  3566. ],
  3567. "orders": [],
  3568. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_character_events_bookUrl_chapterIndex` ON `${TABLE_NAME}` (`bookUrl`, `chapterIndex`)"
  3569. }
  3570. ]
  3571. },
  3572. {
  3573. "tableName": "book_character_relations",
  3574. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `fromCharacterId` TEXT NOT NULL, `toCharacterId` TEXT NOT NULL, `relationType` TEXT NOT NULL, `summary` TEXT NOT NULL, `attitude` TEXT NOT NULL, `evidenceJson` TEXT NOT NULL, `chapterIndex` INTEGER, `status` INTEGER NOT NULL, `source` TEXT NOT NULL, `confidence` REAL NOT NULL, `schemaVersion` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3575. "fields": [
  3576. {
  3577. "fieldPath": "id",
  3578. "columnName": "id",
  3579. "affinity": "TEXT",
  3580. "notNull": true
  3581. },
  3582. {
  3583. "fieldPath": "bookUrl",
  3584. "columnName": "bookUrl",
  3585. "affinity": "TEXT",
  3586. "notNull": true
  3587. },
  3588. {
  3589. "fieldPath": "fromCharacterId",
  3590. "columnName": "fromCharacterId",
  3591. "affinity": "TEXT",
  3592. "notNull": true
  3593. },
  3594. {
  3595. "fieldPath": "toCharacterId",
  3596. "columnName": "toCharacterId",
  3597. "affinity": "TEXT",
  3598. "notNull": true
  3599. },
  3600. {
  3601. "fieldPath": "relationType",
  3602. "columnName": "relationType",
  3603. "affinity": "TEXT",
  3604. "notNull": true
  3605. },
  3606. {
  3607. "fieldPath": "summary",
  3608. "columnName": "summary",
  3609. "affinity": "TEXT",
  3610. "notNull": true
  3611. },
  3612. {
  3613. "fieldPath": "attitude",
  3614. "columnName": "attitude",
  3615. "affinity": "TEXT",
  3616. "notNull": true
  3617. },
  3618. {
  3619. "fieldPath": "evidenceJson",
  3620. "columnName": "evidenceJson",
  3621. "affinity": "TEXT",
  3622. "notNull": true
  3623. },
  3624. {
  3625. "fieldPath": "chapterIndex",
  3626. "columnName": "chapterIndex",
  3627. "affinity": "INTEGER"
  3628. },
  3629. {
  3630. "fieldPath": "status",
  3631. "columnName": "status",
  3632. "affinity": "INTEGER",
  3633. "notNull": true
  3634. },
  3635. {
  3636. "fieldPath": "source",
  3637. "columnName": "source",
  3638. "affinity": "TEXT",
  3639. "notNull": true
  3640. },
  3641. {
  3642. "fieldPath": "confidence",
  3643. "columnName": "confidence",
  3644. "affinity": "REAL",
  3645. "notNull": true
  3646. },
  3647. {
  3648. "fieldPath": "schemaVersion",
  3649. "columnName": "schemaVersion",
  3650. "affinity": "INTEGER",
  3651. "notNull": true
  3652. },
  3653. {
  3654. "fieldPath": "createdAt",
  3655. "columnName": "createdAt",
  3656. "affinity": "INTEGER",
  3657. "notNull": true
  3658. },
  3659. {
  3660. "fieldPath": "updatedAt",
  3661. "columnName": "updatedAt",
  3662. "affinity": "INTEGER",
  3663. "notNull": true
  3664. }
  3665. ],
  3666. "primaryKey": {
  3667. "autoGenerate": false,
  3668. "columnNames": [
  3669. "id"
  3670. ]
  3671. },
  3672. "indices": [
  3673. {
  3674. "name": "index_book_character_relations_bookUrl_fromCharacterId_toCharacterId",
  3675. "unique": true,
  3676. "columnNames": [
  3677. "bookUrl",
  3678. "fromCharacterId",
  3679. "toCharacterId"
  3680. ],
  3681. "orders": [],
  3682. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_book_character_relations_bookUrl_fromCharacterId_toCharacterId` ON `${TABLE_NAME}` (`bookUrl`, `fromCharacterId`, `toCharacterId`)"
  3683. },
  3684. {
  3685. "name": "index_book_character_relations_bookUrl_fromCharacterId",
  3686. "unique": false,
  3687. "columnNames": [
  3688. "bookUrl",
  3689. "fromCharacterId"
  3690. ],
  3691. "orders": [],
  3692. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_character_relations_bookUrl_fromCharacterId` ON `${TABLE_NAME}` (`bookUrl`, `fromCharacterId`)"
  3693. },
  3694. {
  3695. "name": "index_book_character_relations_bookUrl_toCharacterId",
  3696. "unique": false,
  3697. "columnNames": [
  3698. "bookUrl",
  3699. "toCharacterId"
  3700. ],
  3701. "orders": [],
  3702. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_character_relations_bookUrl_toCharacterId` ON `${TABLE_NAME}` (`bookUrl`, `toCharacterId`)"
  3703. }
  3704. ]
  3705. },
  3706. {
  3707. "tableName": "book_knowledge_entries",
  3708. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `type` TEXT NOT NULL, `title` TEXT NOT NULL, `keywordsJson` TEXT NOT NULL, `content` TEXT NOT NULL, `scopeStartChapter` INTEGER, `scopeEndChapter` INTEGER, `priority` INTEGER NOT NULL, `source` TEXT NOT NULL, `confidence` REAL NOT NULL, `evidenceJson` TEXT NOT NULL, `schemaVersion` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3709. "fields": [
  3710. {
  3711. "fieldPath": "id",
  3712. "columnName": "id",
  3713. "affinity": "TEXT",
  3714. "notNull": true
  3715. },
  3716. {
  3717. "fieldPath": "bookUrl",
  3718. "columnName": "bookUrl",
  3719. "affinity": "TEXT",
  3720. "notNull": true
  3721. },
  3722. {
  3723. "fieldPath": "type",
  3724. "columnName": "type",
  3725. "affinity": "TEXT",
  3726. "notNull": true
  3727. },
  3728. {
  3729. "fieldPath": "title",
  3730. "columnName": "title",
  3731. "affinity": "TEXT",
  3732. "notNull": true
  3733. },
  3734. {
  3735. "fieldPath": "keywordsJson",
  3736. "columnName": "keywordsJson",
  3737. "affinity": "TEXT",
  3738. "notNull": true
  3739. },
  3740. {
  3741. "fieldPath": "content",
  3742. "columnName": "content",
  3743. "affinity": "TEXT",
  3744. "notNull": true
  3745. },
  3746. {
  3747. "fieldPath": "scopeStartChapter",
  3748. "columnName": "scopeStartChapter",
  3749. "affinity": "INTEGER"
  3750. },
  3751. {
  3752. "fieldPath": "scopeEndChapter",
  3753. "columnName": "scopeEndChapter",
  3754. "affinity": "INTEGER"
  3755. },
  3756. {
  3757. "fieldPath": "priority",
  3758. "columnName": "priority",
  3759. "affinity": "INTEGER",
  3760. "notNull": true
  3761. },
  3762. {
  3763. "fieldPath": "source",
  3764. "columnName": "source",
  3765. "affinity": "TEXT",
  3766. "notNull": true
  3767. },
  3768. {
  3769. "fieldPath": "confidence",
  3770. "columnName": "confidence",
  3771. "affinity": "REAL",
  3772. "notNull": true
  3773. },
  3774. {
  3775. "fieldPath": "evidenceJson",
  3776. "columnName": "evidenceJson",
  3777. "affinity": "TEXT",
  3778. "notNull": true
  3779. },
  3780. {
  3781. "fieldPath": "schemaVersion",
  3782. "columnName": "schemaVersion",
  3783. "affinity": "INTEGER",
  3784. "notNull": true
  3785. },
  3786. {
  3787. "fieldPath": "createdAt",
  3788. "columnName": "createdAt",
  3789. "affinity": "INTEGER",
  3790. "notNull": true
  3791. },
  3792. {
  3793. "fieldPath": "updatedAt",
  3794. "columnName": "updatedAt",
  3795. "affinity": "INTEGER",
  3796. "notNull": true
  3797. }
  3798. ],
  3799. "primaryKey": {
  3800. "autoGenerate": false,
  3801. "columnNames": [
  3802. "id"
  3803. ]
  3804. },
  3805. "indices": [
  3806. {
  3807. "name": "index_book_knowledge_entries_bookUrl_type_priority",
  3808. "unique": false,
  3809. "columnNames": [
  3810. "bookUrl",
  3811. "type",
  3812. "priority"
  3813. ],
  3814. "orders": [],
  3815. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_knowledge_entries_bookUrl_type_priority` ON `${TABLE_NAME}` (`bookUrl`, `type`, `priority`)"
  3816. },
  3817. {
  3818. "name": "index_book_knowledge_entries_bookUrl_title",
  3819. "unique": false,
  3820. "columnNames": [
  3821. "bookUrl",
  3822. "title"
  3823. ],
  3824. "orders": [],
  3825. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_knowledge_entries_bookUrl_title` ON `${TABLE_NAME}` (`bookUrl`, `title`)"
  3826. }
  3827. ]
  3828. },
  3829. {
  3830. "tableName": "book_outline_nodes",
  3831. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `parentId` TEXT, `nodeType` TEXT NOT NULL, `title` TEXT NOT NULL, `summary` TEXT NOT NULL, `startChapterIndex` INTEGER, `endChapterIndex` INTEGER, `order` INTEGER NOT NULL, `source` TEXT NOT NULL, `confidence` REAL NOT NULL, `schemaVersion` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3832. "fields": [
  3833. {
  3834. "fieldPath": "id",
  3835. "columnName": "id",
  3836. "affinity": "TEXT",
  3837. "notNull": true
  3838. },
  3839. {
  3840. "fieldPath": "bookUrl",
  3841. "columnName": "bookUrl",
  3842. "affinity": "TEXT",
  3843. "notNull": true
  3844. },
  3845. {
  3846. "fieldPath": "parentId",
  3847. "columnName": "parentId",
  3848. "affinity": "TEXT"
  3849. },
  3850. {
  3851. "fieldPath": "nodeType",
  3852. "columnName": "nodeType",
  3853. "affinity": "TEXT",
  3854. "notNull": true
  3855. },
  3856. {
  3857. "fieldPath": "title",
  3858. "columnName": "title",
  3859. "affinity": "TEXT",
  3860. "notNull": true
  3861. },
  3862. {
  3863. "fieldPath": "summary",
  3864. "columnName": "summary",
  3865. "affinity": "TEXT",
  3866. "notNull": true
  3867. },
  3868. {
  3869. "fieldPath": "startChapterIndex",
  3870. "columnName": "startChapterIndex",
  3871. "affinity": "INTEGER"
  3872. },
  3873. {
  3874. "fieldPath": "endChapterIndex",
  3875. "columnName": "endChapterIndex",
  3876. "affinity": "INTEGER"
  3877. },
  3878. {
  3879. "fieldPath": "order",
  3880. "columnName": "order",
  3881. "affinity": "INTEGER",
  3882. "notNull": true
  3883. },
  3884. {
  3885. "fieldPath": "source",
  3886. "columnName": "source",
  3887. "affinity": "TEXT",
  3888. "notNull": true
  3889. },
  3890. {
  3891. "fieldPath": "confidence",
  3892. "columnName": "confidence",
  3893. "affinity": "REAL",
  3894. "notNull": true
  3895. },
  3896. {
  3897. "fieldPath": "schemaVersion",
  3898. "columnName": "schemaVersion",
  3899. "affinity": "INTEGER",
  3900. "notNull": true
  3901. },
  3902. {
  3903. "fieldPath": "createdAt",
  3904. "columnName": "createdAt",
  3905. "affinity": "INTEGER",
  3906. "notNull": true
  3907. },
  3908. {
  3909. "fieldPath": "updatedAt",
  3910. "columnName": "updatedAt",
  3911. "affinity": "INTEGER",
  3912. "notNull": true
  3913. }
  3914. ],
  3915. "primaryKey": {
  3916. "autoGenerate": false,
  3917. "columnNames": [
  3918. "id"
  3919. ]
  3920. },
  3921. "indices": [
  3922. {
  3923. "name": "index_book_outline_nodes_bookUrl_nodeType_startChapterIndex_endChapterIndex",
  3924. "unique": false,
  3925. "columnNames": [
  3926. "bookUrl",
  3927. "nodeType",
  3928. "startChapterIndex",
  3929. "endChapterIndex"
  3930. ],
  3931. "orders": [],
  3932. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_outline_nodes_bookUrl_nodeType_startChapterIndex_endChapterIndex` ON `${TABLE_NAME}` (`bookUrl`, `nodeType`, `startChapterIndex`, `endChapterIndex`)"
  3933. },
  3934. {
  3935. "name": "index_book_outline_nodes_bookUrl_parentId_order",
  3936. "unique": false,
  3937. "columnNames": [
  3938. "bookUrl",
  3939. "parentId",
  3940. "order"
  3941. ],
  3942. "orders": [],
  3943. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_outline_nodes_bookUrl_parentId_order` ON `${TABLE_NAME}` (`bookUrl`, `parentId`, `order`)"
  3944. }
  3945. ]
  3946. },
  3947. {
  3948. "tableName": "read_aloud_voices",
  3949. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `engineType` TEXT NOT NULL, `engineId` TEXT NOT NULL DEFAULT '', `speakerId` TEXT NOT NULL DEFAULT '', `displayName` TEXT NOT NULL, `traitsJson` TEXT NOT NULL DEFAULT '[]', `emotionCatalogJson` TEXT NOT NULL DEFAULT '[]', `managedBy` TEXT NOT NULL DEFAULT 'user', `enabled` INTEGER NOT NULL DEFAULT 1, `available` INTEGER NOT NULL DEFAULT 1, `revision` INTEGER NOT NULL DEFAULT 0, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  3950. "fields": [
  3951. {
  3952. "fieldPath": "id",
  3953. "columnName": "id",
  3954. "affinity": "TEXT",
  3955. "notNull": true
  3956. },
  3957. {
  3958. "fieldPath": "engineType",
  3959. "columnName": "engineType",
  3960. "affinity": "TEXT",
  3961. "notNull": true
  3962. },
  3963. {
  3964. "fieldPath": "engineId",
  3965. "columnName": "engineId",
  3966. "affinity": "TEXT",
  3967. "notNull": true,
  3968. "defaultValue": "''"
  3969. },
  3970. {
  3971. "fieldPath": "speakerId",
  3972. "columnName": "speakerId",
  3973. "affinity": "TEXT",
  3974. "notNull": true,
  3975. "defaultValue": "''"
  3976. },
  3977. {
  3978. "fieldPath": "displayName",
  3979. "columnName": "displayName",
  3980. "affinity": "TEXT",
  3981. "notNull": true
  3982. },
  3983. {
  3984. "fieldPath": "traitsJson",
  3985. "columnName": "traitsJson",
  3986. "affinity": "TEXT",
  3987. "notNull": true,
  3988. "defaultValue": "'[]'"
  3989. },
  3990. {
  3991. "fieldPath": "emotionCatalogJson",
  3992. "columnName": "emotionCatalogJson",
  3993. "affinity": "TEXT",
  3994. "notNull": true,
  3995. "defaultValue": "'[]'"
  3996. },
  3997. {
  3998. "fieldPath": "managedBy",
  3999. "columnName": "managedBy",
  4000. "affinity": "TEXT",
  4001. "notNull": true,
  4002. "defaultValue": "'user'"
  4003. },
  4004. {
  4005. "fieldPath": "enabled",
  4006. "columnName": "enabled",
  4007. "affinity": "INTEGER",
  4008. "notNull": true,
  4009. "defaultValue": "1"
  4010. },
  4011. {
  4012. "fieldPath": "available",
  4013. "columnName": "available",
  4014. "affinity": "INTEGER",
  4015. "notNull": true,
  4016. "defaultValue": "1"
  4017. },
  4018. {
  4019. "fieldPath": "revision",
  4020. "columnName": "revision",
  4021. "affinity": "INTEGER",
  4022. "notNull": true,
  4023. "defaultValue": "0"
  4024. },
  4025. {
  4026. "fieldPath": "createdAt",
  4027. "columnName": "createdAt",
  4028. "affinity": "INTEGER",
  4029. "notNull": true
  4030. },
  4031. {
  4032. "fieldPath": "updatedAt",
  4033. "columnName": "updatedAt",
  4034. "affinity": "INTEGER",
  4035. "notNull": true
  4036. }
  4037. ],
  4038. "primaryKey": {
  4039. "autoGenerate": false,
  4040. "columnNames": [
  4041. "id"
  4042. ]
  4043. },
  4044. "indices": [
  4045. {
  4046. "name": "index_read_aloud_voices_engineType_engineId_speakerId",
  4047. "unique": true,
  4048. "columnNames": [
  4049. "engineType",
  4050. "engineId",
  4051. "speakerId"
  4052. ],
  4053. "orders": [],
  4054. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_read_aloud_voices_engineType_engineId_speakerId` ON `${TABLE_NAME}` (`engineType`, `engineId`, `speakerId`)"
  4055. },
  4056. {
  4057. "name": "index_read_aloud_voices_enabled_displayName",
  4058. "unique": false,
  4059. "columnNames": [
  4060. "enabled",
  4061. "displayName"
  4062. ],
  4063. "orders": [],
  4064. "createSql": "CREATE INDEX IF NOT EXISTS `index_read_aloud_voices_enabled_displayName` ON `${TABLE_NAME}` (`enabled`, `displayName`)"
  4065. }
  4066. ]
  4067. },
  4068. {
  4069. "tableName": "book_voice_bindings",
  4070. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`bookUrl` TEXT NOT NULL, `subjectType` TEXT NOT NULL, `subjectId` TEXT NOT NULL, `voiceId` TEXT NOT NULL, `locked` INTEGER NOT NULL DEFAULT 0, `source` TEXT NOT NULL DEFAULT 'user', `confidence` REAL NOT NULL DEFAULT 1, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`bookUrl`, `subjectType`, `subjectId`))",
  4071. "fields": [
  4072. {
  4073. "fieldPath": "bookUrl",
  4074. "columnName": "bookUrl",
  4075. "affinity": "TEXT",
  4076. "notNull": true
  4077. },
  4078. {
  4079. "fieldPath": "subjectType",
  4080. "columnName": "subjectType",
  4081. "affinity": "TEXT",
  4082. "notNull": true
  4083. },
  4084. {
  4085. "fieldPath": "subjectId",
  4086. "columnName": "subjectId",
  4087. "affinity": "TEXT",
  4088. "notNull": true
  4089. },
  4090. {
  4091. "fieldPath": "voiceId",
  4092. "columnName": "voiceId",
  4093. "affinity": "TEXT",
  4094. "notNull": true
  4095. },
  4096. {
  4097. "fieldPath": "locked",
  4098. "columnName": "locked",
  4099. "affinity": "INTEGER",
  4100. "notNull": true,
  4101. "defaultValue": "0"
  4102. },
  4103. {
  4104. "fieldPath": "source",
  4105. "columnName": "source",
  4106. "affinity": "TEXT",
  4107. "notNull": true,
  4108. "defaultValue": "'user'"
  4109. },
  4110. {
  4111. "fieldPath": "confidence",
  4112. "columnName": "confidence",
  4113. "affinity": "REAL",
  4114. "notNull": true,
  4115. "defaultValue": "1"
  4116. },
  4117. {
  4118. "fieldPath": "createdAt",
  4119. "columnName": "createdAt",
  4120. "affinity": "INTEGER",
  4121. "notNull": true
  4122. },
  4123. {
  4124. "fieldPath": "updatedAt",
  4125. "columnName": "updatedAt",
  4126. "affinity": "INTEGER",
  4127. "notNull": true
  4128. }
  4129. ],
  4130. "primaryKey": {
  4131. "autoGenerate": false,
  4132. "columnNames": [
  4133. "bookUrl",
  4134. "subjectType",
  4135. "subjectId"
  4136. ]
  4137. },
  4138. "indices": [
  4139. {
  4140. "name": "index_book_voice_bindings_bookUrl_subjectType",
  4141. "unique": false,
  4142. "columnNames": [
  4143. "bookUrl",
  4144. "subjectType"
  4145. ],
  4146. "orders": [],
  4147. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_voice_bindings_bookUrl_subjectType` ON `${TABLE_NAME}` (`bookUrl`, `subjectType`)"
  4148. },
  4149. {
  4150. "name": "index_book_voice_bindings_voiceId",
  4151. "unique": false,
  4152. "columnNames": [
  4153. "voiceId"
  4154. ],
  4155. "orders": [],
  4156. "createSql": "CREATE INDEX IF NOT EXISTS `index_book_voice_bindings_voiceId` ON `${TABLE_NAME}` (`voiceId`)"
  4157. }
  4158. ]
  4159. },
  4160. {
  4161. "tableName": "chapter_speech_analysis",
  4162. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `chapterIndex` INTEGER NOT NULL, `contentHash` TEXT NOT NULL, `resolverVersion` TEXT NOT NULL, `characterRevision` TEXT NOT NULL DEFAULT '', `status` TEXT NOT NULL DEFAULT 'pending', `error` TEXT NOT NULL DEFAULT '', `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  4163. "fields": [
  4164. {
  4165. "fieldPath": "id",
  4166. "columnName": "id",
  4167. "affinity": "TEXT",
  4168. "notNull": true
  4169. },
  4170. {
  4171. "fieldPath": "bookUrl",
  4172. "columnName": "bookUrl",
  4173. "affinity": "TEXT",
  4174. "notNull": true
  4175. },
  4176. {
  4177. "fieldPath": "chapterIndex",
  4178. "columnName": "chapterIndex",
  4179. "affinity": "INTEGER",
  4180. "notNull": true
  4181. },
  4182. {
  4183. "fieldPath": "contentHash",
  4184. "columnName": "contentHash",
  4185. "affinity": "TEXT",
  4186. "notNull": true
  4187. },
  4188. {
  4189. "fieldPath": "resolverVersion",
  4190. "columnName": "resolverVersion",
  4191. "affinity": "TEXT",
  4192. "notNull": true
  4193. },
  4194. {
  4195. "fieldPath": "characterRevision",
  4196. "columnName": "characterRevision",
  4197. "affinity": "TEXT",
  4198. "notNull": true,
  4199. "defaultValue": "''"
  4200. },
  4201. {
  4202. "fieldPath": "status",
  4203. "columnName": "status",
  4204. "affinity": "TEXT",
  4205. "notNull": true,
  4206. "defaultValue": "'pending'"
  4207. },
  4208. {
  4209. "fieldPath": "error",
  4210. "columnName": "error",
  4211. "affinity": "TEXT",
  4212. "notNull": true,
  4213. "defaultValue": "''"
  4214. },
  4215. {
  4216. "fieldPath": "createdAt",
  4217. "columnName": "createdAt",
  4218. "affinity": "INTEGER",
  4219. "notNull": true
  4220. },
  4221. {
  4222. "fieldPath": "updatedAt",
  4223. "columnName": "updatedAt",
  4224. "affinity": "INTEGER",
  4225. "notNull": true
  4226. }
  4227. ],
  4228. "primaryKey": {
  4229. "autoGenerate": false,
  4230. "columnNames": [
  4231. "id"
  4232. ]
  4233. },
  4234. "indices": [
  4235. {
  4236. "name": "index_chapter_speech_analysis_bookUrl_chapterIndex_contentHash_resolverVersion",
  4237. "unique": true,
  4238. "columnNames": [
  4239. "bookUrl",
  4240. "chapterIndex",
  4241. "contentHash",
  4242. "resolverVersion"
  4243. ],
  4244. "orders": [],
  4245. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_chapter_speech_analysis_bookUrl_chapterIndex_contentHash_resolverVersion` ON `${TABLE_NAME}` (`bookUrl`, `chapterIndex`, `contentHash`, `resolverVersion`)"
  4246. },
  4247. {
  4248. "name": "index_chapter_speech_analysis_bookUrl_chapterIndex_updatedAt",
  4249. "unique": false,
  4250. "columnNames": [
  4251. "bookUrl",
  4252. "chapterIndex",
  4253. "updatedAt"
  4254. ],
  4255. "orders": [],
  4256. "createSql": "CREATE INDEX IF NOT EXISTS `index_chapter_speech_analysis_bookUrl_chapterIndex_updatedAt` ON `${TABLE_NAME}` (`bookUrl`, `chapterIndex`, `updatedAt`)"
  4257. }
  4258. ]
  4259. },
  4260. {
  4261. "tableName": "chapter_speech_segments",
  4262. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `analysisId` TEXT NOT NULL, `bookUrl` TEXT NOT NULL, `chapterIndex` INTEGER NOT NULL, `paragraphIndex` INTEGER NOT NULL, `start` INTEGER NOT NULL, `end` INTEGER NOT NULL, `chapterPosition` INTEGER NOT NULL, `text` TEXT NOT NULL, `roleType` TEXT NOT NULL, `characterId` TEXT, `characterName` TEXT NOT NULL DEFAULT '', `emotion` TEXT NOT NULL DEFAULT '', `confidence` REAL NOT NULL DEFAULT 0, `source` TEXT NOT NULL, `userLocked` INTEGER NOT NULL DEFAULT 0, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  4263. "fields": [
  4264. {
  4265. "fieldPath": "id",
  4266. "columnName": "id",
  4267. "affinity": "TEXT",
  4268. "notNull": true
  4269. },
  4270. {
  4271. "fieldPath": "analysisId",
  4272. "columnName": "analysisId",
  4273. "affinity": "TEXT",
  4274. "notNull": true
  4275. },
  4276. {
  4277. "fieldPath": "bookUrl",
  4278. "columnName": "bookUrl",
  4279. "affinity": "TEXT",
  4280. "notNull": true
  4281. },
  4282. {
  4283. "fieldPath": "chapterIndex",
  4284. "columnName": "chapterIndex",
  4285. "affinity": "INTEGER",
  4286. "notNull": true
  4287. },
  4288. {
  4289. "fieldPath": "paragraphIndex",
  4290. "columnName": "paragraphIndex",
  4291. "affinity": "INTEGER",
  4292. "notNull": true
  4293. },
  4294. {
  4295. "fieldPath": "start",
  4296. "columnName": "start",
  4297. "affinity": "INTEGER",
  4298. "notNull": true
  4299. },
  4300. {
  4301. "fieldPath": "end",
  4302. "columnName": "end",
  4303. "affinity": "INTEGER",
  4304. "notNull": true
  4305. },
  4306. {
  4307. "fieldPath": "chapterPosition",
  4308. "columnName": "chapterPosition",
  4309. "affinity": "INTEGER",
  4310. "notNull": true
  4311. },
  4312. {
  4313. "fieldPath": "text",
  4314. "columnName": "text",
  4315. "affinity": "TEXT",
  4316. "notNull": true
  4317. },
  4318. {
  4319. "fieldPath": "roleType",
  4320. "columnName": "roleType",
  4321. "affinity": "TEXT",
  4322. "notNull": true
  4323. },
  4324. {
  4325. "fieldPath": "characterId",
  4326. "columnName": "characterId",
  4327. "affinity": "TEXT"
  4328. },
  4329. {
  4330. "fieldPath": "characterName",
  4331. "columnName": "characterName",
  4332. "affinity": "TEXT",
  4333. "notNull": true,
  4334. "defaultValue": "''"
  4335. },
  4336. {
  4337. "fieldPath": "emotion",
  4338. "columnName": "emotion",
  4339. "affinity": "TEXT",
  4340. "notNull": true,
  4341. "defaultValue": "''"
  4342. },
  4343. {
  4344. "fieldPath": "confidence",
  4345. "columnName": "confidence",
  4346. "affinity": "REAL",
  4347. "notNull": true,
  4348. "defaultValue": "0"
  4349. },
  4350. {
  4351. "fieldPath": "source",
  4352. "columnName": "source",
  4353. "affinity": "TEXT",
  4354. "notNull": true
  4355. },
  4356. {
  4357. "fieldPath": "userLocked",
  4358. "columnName": "userLocked",
  4359. "affinity": "INTEGER",
  4360. "notNull": true,
  4361. "defaultValue": "0"
  4362. },
  4363. {
  4364. "fieldPath": "createdAt",
  4365. "columnName": "createdAt",
  4366. "affinity": "INTEGER",
  4367. "notNull": true
  4368. },
  4369. {
  4370. "fieldPath": "updatedAt",
  4371. "columnName": "updatedAt",
  4372. "affinity": "INTEGER",
  4373. "notNull": true
  4374. }
  4375. ],
  4376. "primaryKey": {
  4377. "autoGenerate": false,
  4378. "columnNames": [
  4379. "id"
  4380. ]
  4381. },
  4382. "indices": [
  4383. {
  4384. "name": "index_chapter_speech_segments_analysisId_paragraphIndex_start_end",
  4385. "unique": true,
  4386. "columnNames": [
  4387. "analysisId",
  4388. "paragraphIndex",
  4389. "start",
  4390. "end"
  4391. ],
  4392. "orders": [],
  4393. "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_chapter_speech_segments_analysisId_paragraphIndex_start_end` ON `${TABLE_NAME}` (`analysisId`, `paragraphIndex`, `start`, `end`)"
  4394. },
  4395. {
  4396. "name": "index_chapter_speech_segments_bookUrl_chapterIndex_paragraphIndex",
  4397. "unique": false,
  4398. "columnNames": [
  4399. "bookUrl",
  4400. "chapterIndex",
  4401. "paragraphIndex"
  4402. ],
  4403. "orders": [],
  4404. "createSql": "CREATE INDEX IF NOT EXISTS `index_chapter_speech_segments_bookUrl_chapterIndex_paragraphIndex` ON `${TABLE_NAME}` (`bookUrl`, `chapterIndex`, `paragraphIndex`)"
  4405. },
  4406. {
  4407. "name": "index_chapter_speech_segments_characterId",
  4408. "unique": false,
  4409. "columnNames": [
  4410. "characterId"
  4411. ],
  4412. "orders": [],
  4413. "createSql": "CREATE INDEX IF NOT EXISTS `index_chapter_speech_segments_characterId` ON `${TABLE_NAME}` (`characterId`)"
  4414. }
  4415. ]
  4416. },
  4417. {
  4418. "tableName": "cloud_tts_engines",
  4419. "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `name` TEXT NOT NULL, `provider` TEXT NOT NULL, `baseUrl` TEXT NOT NULL DEFAULT '', `apiKey` TEXT NOT NULL DEFAULT '', `secretKey` TEXT NOT NULL DEFAULT '', `region` TEXT NOT NULL DEFAULT '', `appId` TEXT NOT NULL DEFAULT '', `model` TEXT NOT NULL DEFAULT '', `optionsJson` TEXT NOT NULL DEFAULT '{}', `enabled` INTEGER NOT NULL DEFAULT 1, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))",
  4420. "fields": [
  4421. {
  4422. "fieldPath": "id",
  4423. "columnName": "id",
  4424. "affinity": "TEXT",
  4425. "notNull": true
  4426. },
  4427. {
  4428. "fieldPath": "name",
  4429. "columnName": "name",
  4430. "affinity": "TEXT",
  4431. "notNull": true
  4432. },
  4433. {
  4434. "fieldPath": "provider",
  4435. "columnName": "provider",
  4436. "affinity": "TEXT",
  4437. "notNull": true
  4438. },
  4439. {
  4440. "fieldPath": "baseUrl",
  4441. "columnName": "baseUrl",
  4442. "affinity": "TEXT",
  4443. "notNull": true,
  4444. "defaultValue": "''"
  4445. },
  4446. {
  4447. "fieldPath": "apiKey",
  4448. "columnName": "apiKey",
  4449. "affinity": "TEXT",
  4450. "notNull": true,
  4451. "defaultValue": "''"
  4452. },
  4453. {
  4454. "fieldPath": "secretKey",
  4455. "columnName": "secretKey",
  4456. "affinity": "TEXT",
  4457. "notNull": true,
  4458. "defaultValue": "''"
  4459. },
  4460. {
  4461. "fieldPath": "region",
  4462. "columnName": "region",
  4463. "affinity": "TEXT",
  4464. "notNull": true,
  4465. "defaultValue": "''"
  4466. },
  4467. {
  4468. "fieldPath": "appId",
  4469. "columnName": "appId",
  4470. "affinity": "TEXT",
  4471. "notNull": true,
  4472. "defaultValue": "''"
  4473. },
  4474. {
  4475. "fieldPath": "model",
  4476. "columnName": "model",
  4477. "affinity": "TEXT",
  4478. "notNull": true,
  4479. "defaultValue": "''"
  4480. },
  4481. {
  4482. "fieldPath": "optionsJson",
  4483. "columnName": "optionsJson",
  4484. "affinity": "TEXT",
  4485. "notNull": true,
  4486. "defaultValue": "'{}'"
  4487. },
  4488. {
  4489. "fieldPath": "enabled",
  4490. "columnName": "enabled",
  4491. "affinity": "INTEGER",
  4492. "notNull": true,
  4493. "defaultValue": "1"
  4494. },
  4495. {
  4496. "fieldPath": "createdAt",
  4497. "columnName": "createdAt",
  4498. "affinity": "INTEGER",
  4499. "notNull": true
  4500. },
  4501. {
  4502. "fieldPath": "updatedAt",
  4503. "columnName": "updatedAt",
  4504. "affinity": "INTEGER",
  4505. "notNull": true
  4506. }
  4507. ],
  4508. "primaryKey": {
  4509. "autoGenerate": false,
  4510. "columnNames": [
  4511. "id"
  4512. ]
  4513. },
  4514. "indices": [
  4515. {
  4516. "name": "index_cloud_tts_engines_provider_enabled",
  4517. "unique": false,
  4518. "columnNames": [
  4519. "provider",
  4520. "enabled"
  4521. ],
  4522. "orders": [],
  4523. "createSql": "CREATE INDEX IF NOT EXISTS `index_cloud_tts_engines_provider_enabled` ON `${TABLE_NAME}` (`provider`, `enabled`)"
  4524. }
  4525. ]
  4526. }
  4527. ],
  4528. "views": [
  4529. {
  4530. "viewName": "book_sources_part",
  4531. "createSql": "CREATE VIEW `${VIEW_NAME}` AS select bookSourceUrl, bookSourceName, bookSourceGroup, customOrder, enabled, enabledExplore, \n (loginUrl is not null and trim(loginUrl) <> '') hasLoginUrl, lastUpdateTime, respondTime, weight, \n (exploreUrl is not null and trim(exploreUrl) <> '') hasExploreUrl \n from book_sources"
  4532. }
  4533. ],
  4534. "setupQueries": [
  4535. "CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)",
  4536. "INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, '7eb5b4729e665212e9cddaf3dfac2101')"
  4537. ]
  4538. }
  4539. }