Modern-Apps.git
Publicgit clone https://git.maproj.org/Modern-Apps.gitModern-Apps.git / openassistant / schemas / com.vayunmathur.openassistant.data.database.MessageDatabase / 5.json
5.json131 lines · 3.8 KiBRaw
| 1 | { |
| 2 | "formatVersion": 1, |
| 3 | "database": { |
| 4 | "version": 5, |
| 5 | "identityHash": "f18779167ff0e30f8ecf68b4d2a320b3", |
| 6 | "entities": [ |
| 7 | { |
| 8 | "tableName": "Message", |
| 9 | "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `conversationId` INTEGER NOT NULL, `role` TEXT NOT NULL, `textContent` TEXT NOT NULL, `displayContent` TEXT, `images` TEXT NOT NULL, `toolCallId` TEXT, `toolCalls` TEXT NOT NULL, `timestamp` INTEGER NOT NULL, FOREIGN KEY(`conversationId`) REFERENCES `Conversation`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )", |
| 10 | "fields": [ |
| 11 | { |
| 12 | "fieldPath": "id", |
| 13 | "columnName": "id", |
| 14 | "affinity": "INTEGER", |
| 15 | "notNull": true |
| 16 | }, |
| 17 | { |
| 18 | "fieldPath": "conversationId", |
| 19 | "columnName": "conversationId", |
| 20 | "affinity": "INTEGER", |
| 21 | "notNull": true |
| 22 | }, |
| 23 | { |
| 24 | "fieldPath": "role", |
| 25 | "columnName": "role", |
| 26 | "affinity": "TEXT", |
| 27 | "notNull": true |
| 28 | }, |
| 29 | { |
| 30 | "fieldPath": "textContent", |
| 31 | "columnName": "textContent", |
| 32 | "affinity": "TEXT", |
| 33 | "notNull": true |
| 34 | }, |
| 35 | { |
| 36 | "fieldPath": "displayContent", |
| 37 | "columnName": "displayContent", |
| 38 | "affinity": "TEXT" |
| 39 | }, |
| 40 | { |
| 41 | "fieldPath": "images", |
| 42 | "columnName": "images", |
| 43 | "affinity": "TEXT", |
| 44 | "notNull": true |
| 45 | }, |
| 46 | { |
| 47 | "fieldPath": "toolCallId", |
| 48 | "columnName": "toolCallId", |
| 49 | "affinity": "TEXT" |
| 50 | }, |
| 51 | { |
| 52 | "fieldPath": "toolCalls", |
| 53 | "columnName": "toolCalls", |
| 54 | "affinity": "TEXT", |
| 55 | "notNull": true |
| 56 | }, |
| 57 | { |
| 58 | "fieldPath": "timestamp", |
| 59 | "columnName": "timestamp", |
| 60 | "affinity": "INTEGER", |
| 61 | "notNull": true |
| 62 | } |
| 63 | ], |
| 64 | "primaryKey": { |
| 65 | "autoGenerate": true, |
| 66 | "columnNames": [ |
| 67 | "id" |
| 68 | ] |
| 69 | }, |
| 70 | "indices": [ |
| 71 | { |
| 72 | "name": "index_Message_conversationId", |
| 73 | "unique": false, |
| 74 | "columnNames": [ |
| 75 | "conversationId" |
| 76 | ], |
| 77 | "orders": [], |
| 78 | "createSql": "CREATE INDEX IF NOT EXISTS `index_Message_conversationId` ON `${TABLE_NAME}` (`conversationId`)" |
| 79 | } |
| 80 | ], |
| 81 | "foreignKeys": [ |
| 82 | { |
| 83 | "table": "Conversation", |
| 84 | "onDelete": "CASCADE", |
| 85 | "onUpdate": "NO ACTION", |
| 86 | "columns": [ |
| 87 | "conversationId" |
| 88 | ], |
| 89 | "referencedColumns": [ |
| 90 | "id" |
| 91 | ] |
| 92 | } |
| 93 | ] |
| 94 | }, |
| 95 | { |
| 96 | "tableName": "Conversation", |
| 97 | "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `title` TEXT NOT NULL, `createdAt` INTEGER NOT NULL)", |
| 98 | "fields": [ |
| 99 | { |
| 100 | "fieldPath": "id", |
| 101 | "columnName": "id", |
| 102 | "affinity": "INTEGER", |
| 103 | "notNull": true |
| 104 | }, |
| 105 | { |
| 106 | "fieldPath": "title", |
| 107 | "columnName": "title", |
| 108 | "affinity": "TEXT", |
| 109 | "notNull": true |
| 110 | }, |
| 111 | { |
| 112 | "fieldPath": "createdAt", |
| 113 | "columnName": "createdAt", |
| 114 | "affinity": "INTEGER", |
| 115 | "notNull": true |
| 116 | } |
| 117 | ], |
| 118 | "primaryKey": { |
| 119 | "autoGenerate": true, |
| 120 | "columnNames": [ |
| 121 | "id" |
| 122 | ] |
| 123 | } |
| 124 | } |
| 125 | ], |
| 126 | "setupQueries": [ |
| 127 | "CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)", |
| 128 | "INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, 'f18779167ff0e30f8ecf68b4d2a320b3')" |
| 129 | ] |
| 130 | } |
| 131 | } |