102.json 147 KB

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