107.json 148 KB

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