xonecas.io
5414
Sa

sat / commit 44ff317

feat: persistance

xonecas2026-01-14 44ff3170dbfdec385ed1610f9ac6bfe5f6d1a3c4 parent 5cbce41

16 files changed

This diff is too big to show in full. The first 1000 lines are below, and every file is listed with its counts.

drizzle.config.ts+14−0
@@ -0,0 +1,14 @@
1+import { defineConfig } from "drizzle-kit";
2+
3+if (!process.env.DATABASE_URL) {
4+ throw new Error("DATABASE_URL environment variable is required");
5+}
6+
7+export default defineConfig({
8+ dialect: "postgresql",
9+ schema: "./src/db/schema.ts",
10+ out: "./drizzle",
11+ dbCredentials: {
12+ url: process.env.DATABASE_URL,
13+ },
14+});
drizzle/0000_handy_kang.sql+18−0
@@ -0,0 +1,18 @@
1+CREATE TABLE "conversations" (
2+ "id" uuid PRIMARY KEY DEFAULT gen_random_uuid() NOT NULL,
3+ "title" text,
4+ "created_at" timestamp DEFAULT now() NOT NULL,
5+ "updated_at" timestamp DEFAULT now() NOT NULL
6+);
7+--> statement-breakpoint
8+CREATE TABLE "turns" (
9+ "id" uuid PRIMARY KEY DEFAULT gen_random_uuid() NOT NULL,
10+ "conversation_id" uuid NOT NULL,
11+ "role" text NOT NULL,
12+ "content" text NOT NULL,
13+ "reasoning" text,
14+ "tool_calls" jsonb,
15+ "created_at" timestamp DEFAULT now() NOT NULL
16+);
17+--> statement-breakpoint
18+ALTER TABLE "turns" ADD CONSTRAINT "turns_conversation_id_conversations_id_fk" FOREIGN KEY ("conversation_id") REFERENCES "public"."conversations"("id") ON DELETE cascade ON UPDATE no action;
drizzle/meta/0000_snapshot.json+130−0
@@ -0,0 +1,130 @@
1+{
2+ "id": "c5145db9-57d5-4900-a75f-768038e4d932",
3+ "prevId": "00000000-0000-0000-0000-000000000000",
4+ "version": "7",
5+ "dialect": "postgresql",
6+ "tables": {
7+ "public.conversations": {
8+ "name": "conversations",
9+ "schema": "",
10+ "columns": {
11+ "id": {
12+ "name": "id",
13+ "type": "uuid",
14+ "primaryKey": true,
15+ "notNull": true,
16+ "default": "gen_random_uuid()"
17+ },
18+ "title": {
19+ "name": "title",
20+ "type": "text",
21+ "primaryKey": false,
22+ "notNull": false
23+ },
24+ "created_at": {
25+ "name": "created_at",
26+ "type": "timestamp",
27+ "primaryKey": false,
28+ "notNull": true,
29+ "default": "now()"
30+ },
31+ "updated_at": {
32+ "name": "updated_at",
33+ "type": "timestamp",
34+ "primaryKey": false,
35+ "notNull": true,
36+ "default": "now()"
37+ }
38+ },
39+ "indexes": {},
40+ "foreignKeys": {},
41+ "compositePrimaryKeys": {},
42+ "uniqueConstraints": {},
43+ "policies": {},
44+ "checkConstraints": {},
45+ "isRLSEnabled": false
46+ },
47+ "public.turns": {
48+ "name": "turns",
49+ "schema": "",
50+ "columns": {
51+ "id": {
52+ "name": "id",
53+ "type": "uuid",
54+ "primaryKey": true,
55+ "notNull": true,
56+ "default": "gen_random_uuid()"
57+ },
58+ "conversation_id": {
59+ "name": "conversation_id",
60+ "type": "uuid",
61+ "primaryKey": false,
62+ "notNull": true
63+ },
64+ "role": {
65+ "name": "role",
66+ "type": "text",
67+ "primaryKey": false,
68+ "notNull": true
69+ },
70+ "content": {
71+ "name": "content",
72+ "type": "text",
73+ "primaryKey": false,
74+ "notNull": true
75+ },
76+ "reasoning": {
77+ "name": "reasoning",
78+ "type": "text",
79+ "primaryKey": false,
80+ "notNull": false
81+ },
82+ "tool_calls": {
83+ "name": "tool_calls",
84+ "type": "jsonb",
85+ "primaryKey": false,
86+ "notNull": false
87+ },
88+ "created_at": {
89+ "name": "created_at",
90+ "type": "timestamp",
91+ "primaryKey": false,
92+ "notNull": true,
93+ "default": "now()"
94+ }
95+ },
96+ "indexes": {},
97+ "foreignKeys": {
98+ "turns_conversation_id_conversations_id_fk": {
99+ "name": "turns_conversation_id_conversations_id_fk",
100+ "tableFrom": "turns",
101+ "tableTo": "conversations",
102+ "columnsFrom": [
103+ "conversation_id"
104+ ],
105+ "columnsTo": [
106+ "id"
107+ ],
108+ "onDelete": "cascade",
109+ "onUpdate": "no action"
110+ }
111+ },
112+ "compositePrimaryKeys": {},
113+ "uniqueConstraints": {},
114+ "policies": {},
115+ "checkConstraints": {},
116+ "isRLSEnabled": false
117+ }
118+ },
119+ "enums": {},
120+ "schemas": {},
121+ "sequences": {},
122+ "roles": {},
123+ "policies": {},
124+ "views": {},
125+ "_meta": {
126+ "columns": {},
127+ "schemas": {},
128+ "tables": {}
129+ }
130+}
drizzle/meta/_journal.json+13−0
@@ -0,0 +1,13 @@
1+{
2+ "version": "7",
3+ "dialect": "postgresql",
4+ "entries": [
5+ {
6+ "idx": 0,
7+ "version": "7",
8+ "when": 1768430745778,
9+ "tag": "0000_handy_kang",
10+ "breakpoints": true
11+ }
12+ ]
13+}
package-lock.json+1307−12
@@ -13,15 +13,18 @@
1313 "@langchain/ollama": "^1.2.0",
1414 "class-variance-authority": "^0.7.1",
1515 "clsx": "^2.1.1",
16+ "drizzle-orm": "^0.45.1",
1617 "langchain": "^1.2.8",
1718 "lucide-react": "^0.562.0",
1819 "next": "16.1.1",
1920 "next-themes": "^0.4.6",
21+ "pg": "^8.17.0",
2022 "radix-ui": "^1.4.3",
2123 "react": "19.2.3",
2224 "react-dom": "19.2.3",
2325 "react-markdown": "^10.1.0",
2426 "shadcn": "^3.6.3",
27+ "sonner": "^2.0.7",
2528 "tailwind-merge": "^3.4.0",
2629 "tw-animate-css": "^1.4.0",
2730 "zod": "^4.3.5"
@@ -30,8 +33,10 @@
3033 "@biomejs/biome": "2.2.0",
3134 "@tailwindcss/postcss": "^4",
3235 "@types/node": "^20",
36+ "@types/pg": "^8.16.0",
3337 "@types/react": "^19",
3438 "@types/react-dom": "^19",
39+ "drizzle-kit": "^0.31.8",
3540 "tailwindcss": "^4",
3641 "typescript": "^5"
3742 }
@@ -864,28 +869,913 @@
864869 "node": ">=6"
865870 }
866871 },
872+ "node_modules/@drizzle-team/brocli": {
873+ "version": "0.10.2",
874+ "resolved": "https://registry.npmjs.org/@drizzle-team/brocli/-/brocli-0.10.2.tgz",
875+ "integrity": "sha512-z33Il7l5dKjUgGULTqBsQBQwckHh5AbIuxhdsIxDDiZAzBOrZO6q9ogcWC65kU382AfynTfgNumVcNIjuIua6w==",
876+ "dev": true,
877+ "license": "Apache-2.0"
878+ },
867879 "node_modules/@ecies/ciphers": {
868880 "version": "0.2.5",
869881 "resolved": "https://registry.npmjs.org/@ecies/ciphers/-/ciphers-0.2.5.tgz",
870882 "integrity": "sha512-GalEZH4JgOMHYYcYmVqnFirFsjZHeoGMDt9IxEnM9F7GRUUyUksJ7Ou53L83WHJq3RWKD3AcBpo0iQh0oMpf8A==",
871883 "license": "MIT",
872884 "engines": {
873- "bun": ">=1",
874- "deno": ">=2",
875- "node": ">=16"
876- },
877- "peerDependencies": {
878- "@noble/ciphers": "^1.0.0"
885+ "bun": ">=1",
886+ "deno": ">=2",
887+ "node": ">=16"
888+ },
889+ "peerDependencies": {
890+ "@noble/ciphers": "^1.0.0"
891+ }
892+ },
893+ "node_modules/@emnapi/runtime": {
894+ "version": "1.8.1",
895+ "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz",
896+ "integrity": "sha512-mehfKSMWjjNol8659Z8KxEMrdSJDDot5SXMq00dM8BN4o+CLNXQ0xH2V7EchNHV4RmbZLmmPdEaXZc5H2FXmDg==",
897+ "license": "MIT",
898+ "optional": true,
899+ "dependencies": {
900+ "tslib": "^2.4.0"
901+ }
902+ },
903+ "node_modules/@esbuild-kit/core-utils": {
904+ "version": "3.3.2",
905+ "resolved": "https://registry.npmjs.org/@esbuild-kit/core-utils/-/core-utils-3.3.2.tgz",
906+ "integrity": "sha512-sPRAnw9CdSsRmEtnsl2WXWdyquogVpB3yZ3dgwJfe8zrOzTsV7cJvmwrKVa+0ma5BoiGJ+BoqkMvawbayKUsqQ==",
907+ "deprecated": "Merged into tsx: https://tsx.is",
908+ "dev": true,
909+ "license": "MIT",
910+ "dependencies": {
911+ "esbuild": "~0.18.20",
912+ "source-map-support": "^0.5.21"
913+ }
914+ },
915+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/android-arm": {
916+ "version": "0.18.20",
917+ "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.18.20.tgz",
918+ "integrity": "sha512-fyi7TDI/ijKKNZTUJAQqiG5T7YjJXgnzkURqmGj13C6dCqckZBLdl4h7bkhHt/t0WP+zO9/zwroDvANaOqO5Sw==",
919+ "cpu": [
920+ "arm"
921+ ],
922+ "dev": true,
923+ "license": "MIT",
924+ "optional": true,
925+ "os": [
926+ "android"
927+ ],
928+ "engines": {
929+ "node": ">=12"
930+ }
931+ },
932+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/android-arm64": {
933+ "version": "0.18.20",
934+ "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.18.20.tgz",
935+ "integrity": "sha512-Nz4rJcchGDtENV0eMKUNa6L12zz2zBDXuhj/Vjh18zGqB44Bi7MBMSXjgunJgjRhCmKOjnPuZp4Mb6OKqtMHLQ==",
936+ "cpu": [
937+ "arm64"
938+ ],
939+ "dev": true,
940+ "license": "MIT",
941+ "optional": true,
942+ "os": [
943+ "android"
944+ ],
945+ "engines": {
946+ "node": ">=12"
947+ }
948+ },
949+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/android-x64": {
950+ "version": "0.18.20",
951+ "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.18.20.tgz",
952+ "integrity": "sha512-8GDdlePJA8D6zlZYJV/jnrRAi6rOiNaCC/JclcXpB+KIuvfBN4owLtgzY2bsxnx666XjJx2kDPUmnTtR8qKQUg==",
953+ "cpu": [
954+ "x64"
955+ ],
956+ "dev": true,
957+ "license": "MIT",
958+ "optional": true,
959+ "os": [
960+ "android"
961+ ],
962+ "engines": {
963+ "node": ">=12"
964+ }
965+ },
966+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/darwin-arm64": {
967+ "version": "0.18.20",
968+ "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.18.20.tgz",
969+ "integrity": "sha512-bxRHW5kHU38zS2lPTPOyuyTm+S+eobPUnTNkdJEfAddYgEcll4xkT8DB9d2008DtTbl7uJag2HuE5NZAZgnNEA==",
970+ "cpu": [
971+ "arm64"
972+ ],
973+ "dev": true,
974+ "license": "MIT",
975+ "optional": true,
976+ "os": [
977+ "darwin"
978+ ],
979+ "engines": {
980+ "node": ">=12"
981+ }
982+ },
983+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/darwin-x64": {
984+ "version": "0.18.20",
985+ "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.18.20.tgz",
986+ "integrity": "sha512-pc5gxlMDxzm513qPGbCbDukOdsGtKhfxD1zJKXjCCcU7ju50O7MeAZ8c4krSJcOIJGFR+qx21yMMVYwiQvyTyQ==",
987+ "cpu": [
988+ "x64"
989+ ],
990+ "dev": true,
991+ "license": "MIT",
992+ "optional": true,
993+ "os": [
994+ "darwin"
995+ ],
996+ "engines": {
997+ "node": ">=12"
998+ }
999+ },
1000+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/freebsd-arm64": {
1001+ "version": "0.18.20",
1002+ "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.18.20.tgz",
1003+ "integrity": "sha512-yqDQHy4QHevpMAaxhhIwYPMv1NECwOvIpGCZkECn8w2WFHXjEwrBn3CeNIYsibZ/iZEUemj++M26W3cNR5h+Tw==",
1004+ "cpu": [
1005+ "arm64"
1006+ ],
1007+ "dev": true,
1008+ "license": "MIT",
1009+ "optional": true,
1010+ "os": [
1011+ "freebsd"
1012+ ],
1013+ "engines": {
1014+ "node": ">=12"
1015+ }
1016+ },
1017+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/freebsd-x64": {
1018+ "version": "0.18.20",
1019+ "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.18.20.tgz",
1020+ "integrity": "sha512-tgWRPPuQsd3RmBZwarGVHZQvtzfEBOreNuxEMKFcd5DaDn2PbBxfwLcj4+aenoh7ctXcbXmOQIn8HI6mCSw5MQ==",
1021+ "cpu": [
1022+ "x64"
1023+ ],
1024+ "dev": true,
1025+ "license": "MIT",
1026+ "optional": true,
1027+ "os": [
1028+ "freebsd"
1029+ ],
1030+ "engines": {
1031+ "node": ">=12"
1032+ }
1033+ },
1034+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-arm": {
1035+ "version": "0.18.20",
1036+ "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.18.20.tgz",
1037+ "integrity": "sha512-/5bHkMWnq1EgKr1V+Ybz3s1hWXok7mDFUMQ4cG10AfW3wL02PSZi5kFpYKrptDsgb2WAJIvRcDm+qIvXf/apvg==",
1038+ "cpu": [
1039+ "arm"
1040+ ],
1041+ "dev": true,
1042+ "license": "MIT",
1043+ "optional": true,
1044+ "os": [
1045+ "linux"
1046+ ],
1047+ "engines": {
1048+ "node": ">=12"
1049+ }
1050+ },
1051+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-arm64": {
1052+ "version": "0.18.20",
1053+ "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.18.20.tgz",
1054+ "integrity": "sha512-2YbscF+UL7SQAVIpnWvYwM+3LskyDmPhe31pE7/aoTMFKKzIc9lLbyGUpmmb8a8AixOL61sQ/mFh3jEjHYFvdA==",
1055+ "cpu": [
1056+ "arm64"
1057+ ],
1058+ "dev": true,
1059+ "license": "MIT",
1060+ "optional": true,
1061+ "os": [
1062+ "linux"
1063+ ],
1064+ "engines": {
1065+ "node": ">=12"
1066+ }
1067+ },
1068+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-ia32": {
1069+ "version": "0.18.20",
1070+ "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.18.20.tgz",
1071+ "integrity": "sha512-P4etWwq6IsReT0E1KHU40bOnzMHoH73aXp96Fs8TIT6z9Hu8G6+0SHSw9i2isWrD2nbx2qo5yUqACgdfVGx7TA==",
1072+ "cpu": [
1073+ "ia32"
1074+ ],
1075+ "dev": true,
1076+ "license": "MIT",
1077+ "optional": true,
1078+ "os": [
1079+ "linux"
1080+ ],
1081+ "engines": {
1082+ "node": ">=12"
1083+ }
1084+ },
1085+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-loong64": {
1086+ "version": "0.18.20",
1087+ "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.18.20.tgz",
1088+ "integrity": "sha512-nXW8nqBTrOpDLPgPY9uV+/1DjxoQ7DoB2N8eocyq8I9XuqJ7BiAMDMf9n1xZM9TgW0J8zrquIb/A7s3BJv7rjg==",
1089+ "cpu": [
1090+ "loong64"
1091+ ],
1092+ "dev": true,
1093+ "license": "MIT",
1094+ "optional": true,
1095+ "os": [
1096+ "linux"
1097+ ],
1098+ "engines": {
1099+ "node": ">=12"
1100+ }
1101+ },
1102+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-mips64el": {
1103+ "version": "0.18.20",
1104+ "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.18.20.tgz",
1105+ "integrity": "sha512-d5NeaXZcHp8PzYy5VnXV3VSd2D328Zb+9dEq5HE6bw6+N86JVPExrA6O68OPwobntbNJ0pzCpUFZTo3w0GyetQ==",
1106+ "cpu": [
1107+ "mips64el"
1108+ ],
1109+ "dev": true,
1110+ "license": "MIT",
1111+ "optional": true,
1112+ "os": [
1113+ "linux"
1114+ ],
1115+ "engines": {
1116+ "node": ">=12"
1117+ }
1118+ },
1119+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-ppc64": {
1120+ "version": "0.18.20",
1121+ "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.18.20.tgz",
1122+ "integrity": "sha512-WHPyeScRNcmANnLQkq6AfyXRFr5D6N2sKgkFo2FqguP44Nw2eyDlbTdZwd9GYk98DZG9QItIiTlFLHJHjxP3FA==",
1123+ "cpu": [
1124+ "ppc64"
1125+ ],
1126+ "dev": true,
1127+ "license": "MIT",
1128+ "optional": true,
1129+ "os": [
1130+ "linux"
1131+ ],
1132+ "engines": {
1133+ "node": ">=12"
1134+ }
1135+ },
1136+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-riscv64": {
1137+ "version": "0.18.20",
1138+ "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.18.20.tgz",
1139+ "integrity": "sha512-WSxo6h5ecI5XH34KC7w5veNnKkju3zBRLEQNY7mv5mtBmrP/MjNBCAlsM2u5hDBlS3NGcTQpoBvRzqBcRtpq1A==",
1140+ "cpu": [
1141+ "riscv64"
1142+ ],
1143+ "dev": true,
1144+ "license": "MIT",
1145+ "optional": true,
1146+ "os": [
1147+ "linux"
1148+ ],
1149+ "engines": {
1150+ "node": ">=12"
1151+ }
1152+ },
1153+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-s390x": {
1154+ "version": "0.18.20",
1155+ "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.18.20.tgz",
1156+ "integrity": "sha512-+8231GMs3mAEth6Ja1iK0a1sQ3ohfcpzpRLH8uuc5/KVDFneH6jtAJLFGafpzpMRO6DzJ6AvXKze9LfFMrIHVQ==",
1157+ "cpu": [
1158+ "s390x"
1159+ ],
1160+ "dev": true,
1161+ "license": "MIT",
1162+ "optional": true,
1163+ "os": [
1164+ "linux"
1165+ ],
1166+ "engines": {
1167+ "node": ">=12"
1168+ }
1169+ },
1170+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/linux-x64": {
1171+ "version": "0.18.20",
1172+ "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.18.20.tgz",
1173+ "integrity": "sha512-UYqiqemphJcNsFEskc73jQ7B9jgwjWrSayxawS6UVFZGWrAAtkzjxSqnoclCXxWtfwLdzU+vTpcNYhpn43uP1w==",
1174+ "cpu": [
1175+ "x64"
1176+ ],
1177+ "dev": true,
1178+ "license": "MIT",
1179+ "optional": true,
1180+ "os": [
1181+ "linux"
1182+ ],
1183+ "engines": {
1184+ "node": ">=12"
1185+ }
1186+ },
1187+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/netbsd-x64": {
1188+ "version": "0.18.20",
1189+ "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.18.20.tgz",
1190+ "integrity": "sha512-iO1c++VP6xUBUmltHZoMtCUdPlnPGdBom6IrO4gyKPFFVBKioIImVooR5I83nTew5UOYrk3gIJhbZh8X44y06A==",
1191+ "cpu": [
1192+ "x64"
1193+ ],
1194+ "dev": true,
1195+ "license": "MIT",
1196+ "optional": true,
1197+ "os": [
1198+ "netbsd"
1199+ ],
1200+ "engines": {
1201+ "node": ">=12"
1202+ }
1203+ },
1204+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/openbsd-x64": {
1205+ "version": "0.18.20",
1206+ "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.18.20.tgz",
1207+ "integrity": "sha512-e5e4YSsuQfX4cxcygw/UCPIEP6wbIL+se3sxPdCiMbFLBWu0eiZOJ7WoD+ptCLrmjZBK1Wk7I6D/I3NglUGOxg==",
1208+ "cpu": [
1209+ "x64"
1210+ ],
1211+ "dev": true,
1212+ "license": "MIT",
1213+ "optional": true,
1214+ "os": [
1215+ "openbsd"
1216+ ],
1217+ "engines": {
1218+ "node": ">=12"
1219+ }
1220+ },
1221+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/sunos-x64": {
1222+ "version": "0.18.20",
1223+ "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.18.20.tgz",
1224+ "integrity": "sha512-kDbFRFp0YpTQVVrqUd5FTYmWo45zGaXe0X8E1G/LKFC0v8x0vWrhOWSLITcCn63lmZIxfOMXtCfti/RxN/0wnQ==",
1225+ "cpu": [
1226+ "x64"
1227+ ],
1228+ "dev": true,
1229+ "license": "MIT",
1230+ "optional": true,
1231+ "os": [
1232+ "sunos"
1233+ ],
1234+ "engines": {
1235+ "node": ">=12"
1236+ }
1237+ },
1238+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/win32-arm64": {
1239+ "version": "0.18.20",
1240+ "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.18.20.tgz",
1241+ "integrity": "sha512-ddYFR6ItYgoaq4v4JmQQaAI5s7npztfV4Ag6NrhiaW0RrnOXqBkgwZLofVTlq1daVTQNhtI5oieTvkRPfZrePg==",
1242+ "cpu": [
1243+ "arm64"
1244+ ],
1245+ "dev": true,
1246+ "license": "MIT",
1247+ "optional": true,
1248+ "os": [
1249+ "win32"
1250+ ],
1251+ "engines": {
1252+ "node": ">=12"
1253+ }
1254+ },
1255+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/win32-ia32": {
1256+ "version": "0.18.20",
1257+ "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.18.20.tgz",
1258+ "integrity": "sha512-Wv7QBi3ID/rROT08SABTS7eV4hX26sVduqDOTe1MvGMjNd3EjOz4b7zeexIR62GTIEKrfJXKL9LFxTYgkyeu7g==",
1259+ "cpu": [
1260+ "ia32"
1261+ ],
1262+ "dev": true,
1263+ "license": "MIT",
1264+ "optional": true,
1265+ "os": [
1266+ "win32"
1267+ ],
1268+ "engines": {
1269+ "node": ">=12"
1270+ }
1271+ },
1272+ "node_modules/@esbuild-kit/core-utils/node_modules/@esbuild/win32-x64": {
1273+ "version": "0.18.20",
1274+ "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.18.20.tgz",
1275+ "integrity": "sha512-kTdfRcSiDfQca/y9QIkng02avJ+NCaQvrMejlsB3RRv5sE9rRoeBPISaZpKxHELzRxZyLvNts1P27W3wV+8geQ==",
1276+ "cpu": [
1277+ "x64"
1278+ ],
1279+ "dev": true,
1280+ "license": "MIT",
1281+ "optional": true,
1282+ "os": [
1283+ "win32"
1284+ ],
1285+ "engines": {
1286+ "node": ">=12"
1287+ }
1288+ },
1289+ "node_modules/@esbuild-kit/core-utils/node_modules/esbuild": {
1290+ "version": "0.18.20",
1291+ "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.18.20.tgz",
1292+ "integrity": "sha512-ceqxoedUrcayh7Y7ZX6NdbbDzGROiyVBgC4PriJThBKSVPWnnFHZAkfI1lJT8QFkOwH4qOS2SJkS4wvpGl8BpA==",
1293+ "dev": true,
1294+ "hasInstallScript": true,
1295+ "license": "MIT",
1296+ "bin": {
1297+ "esbuild": "bin/esbuild"
1298+ },
1299+ "engines": {
1300+ "node": ">=12"
1301+ },
1302+ "optionalDependencies": {
1303+ "@esbuild/android-arm": "0.18.20",
1304+ "@esbuild/android-arm64": "0.18.20",
1305+ "@esbuild/android-x64": "0.18.20",
1306+ "@esbuild/darwin-arm64": "0.18.20",
1307+ "@esbuild/darwin-x64": "0.18.20",
1308+ "@esbuild/freebsd-arm64": "0.18.20",
1309+ "@esbuild/freebsd-x64": "0.18.20",
1310+ "@esbuild/linux-arm": "0.18.20",
1311+ "@esbuild/linux-arm64": "0.18.20",
1312+ "@esbuild/linux-ia32": "0.18.20",
1313+ "@esbuild/linux-loong64": "0.18.20",
1314+ "@esbuild/linux-mips64el": "0.18.20",
1315+ "@esbuild/linux-ppc64": "0.18.20",
1316+ "@esbuild/linux-riscv64": "0.18.20",
1317+ "@esbuild/linux-s390x": "0.18.20",
1318+ "@esbuild/linux-x64": "0.18.20",
1319+ "@esbuild/netbsd-x64": "0.18.20",
1320+ "@esbuild/openbsd-x64": "0.18.20",
1321+ "@esbuild/sunos-x64": "0.18.20",
1322+ "@esbuild/win32-arm64": "0.18.20",
1323+ "@esbuild/win32-ia32": "0.18.20",
1324+ "@esbuild/win32-x64": "0.18.20"
1325+ }
1326+ },
1327+ "node_modules/@esbuild-kit/esm-loader": {
1328+ "version": "2.6.5",
1329+ "resolved": "https://registry.npmjs.org/@esbuild-kit/esm-loader/-/esm-loader-2.6.5.tgz",
1330+ "integrity": "sha512-FxEMIkJKnodyA1OaCUoEvbYRkoZlLZ4d/eXFu9Fh8CbBBgP5EmZxrfTRyN0qpXZ4vOvqnE5YdRdcrmUUXuU+dA==",
1331+ "deprecated": "Merged into tsx: https://tsx.is",
1332+ "dev": true,
1333+ "license": "MIT",
1334+ "dependencies": {
1335+ "@esbuild-kit/core-utils": "^3.3.2",
1336+ "get-tsconfig": "^4.7.0"
1337+ }
1338+ },
1339+ "node_modules/@esbuild/aix-ppc64": {
1340+ "version": "0.25.12",
1341+ "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.12.tgz",
1342+ "integrity": "sha512-Hhmwd6CInZ3dwpuGTF8fJG6yoWmsToE+vYgD4nytZVxcu1ulHpUQRAB1UJ8+N1Am3Mz4+xOByoQoSZf4D+CpkA==",
1343+ "cpu": [
1344+ "ppc64"
1345+ ],
1346+ "dev": true,
1347+ "license": "MIT",
1348+ "optional": true,
1349+ "os": [
1350+ "aix"
1351+ ],
1352+ "engines": {
1353+ "node": ">=18"
1354+ }
1355+ },
1356+ "node_modules/@esbuild/android-arm": {
1357+ "version": "0.25.12",
1358+ "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.12.tgz",
1359+ "integrity": "sha512-VJ+sKvNA/GE7Ccacc9Cha7bpS8nyzVv0jdVgwNDaR4gDMC/2TTRc33Ip8qrNYUcpkOHUT5OZ0bUcNNVZQ9RLlg==",
1360+ "cpu": [
1361+ "arm"
1362+ ],
1363+ "dev": true,
1364+ "license": "MIT",
1365+ "optional": true,
1366+ "os": [
1367+ "android"
1368+ ],
1369+ "engines": {
1370+ "node": ">=18"
1371+ }
1372+ },
1373+ "node_modules/@esbuild/android-arm64": {
1374+ "version": "0.25.12",
1375+ "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.12.tgz",
1376+ "integrity": "sha512-6AAmLG7zwD1Z159jCKPvAxZd4y/VTO0VkprYy+3N2FtJ8+BQWFXU+OxARIwA46c5tdD9SsKGZ/1ocqBS/gAKHg==",
1377+ "cpu": [
1378+ "arm64"
1379+ ],
1380+ "dev": true,
1381+ "license": "MIT",
1382+ "optional": true,
1383+ "os": [
1384+ "android"
1385+ ],
1386+ "engines": {
1387+ "node": ">=18"
1388+ }
1389+ },
1390+ "node_modules/@esbuild/android-x64": {
1391+ "version": "0.25.12",
1392+ "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.12.tgz",
1393+ "integrity": "sha512-5jbb+2hhDHx5phYR2By8GTWEzn6I9UqR11Kwf22iKbNpYrsmRB18aX/9ivc5cabcUiAT/wM+YIZ6SG9QO6a8kg==",
1394+ "cpu": [
1395+ "x64"
1396+ ],
1397+ "dev": true,
1398+ "license": "MIT",
1399+ "optional": true,
1400+ "os": [
1401+ "android"
1402+ ],
1403+ "engines": {
1404+ "node": ">=18"
1405+ }
1406+ },
1407+ "node_modules/@esbuild/darwin-arm64": {
1408+ "version": "0.25.12",
1409+ "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.12.tgz",
1410+ "integrity": "sha512-N3zl+lxHCifgIlcMUP5016ESkeQjLj/959RxxNYIthIg+CQHInujFuXeWbWMgnTo4cp5XVHqFPmpyu9J65C1Yg==",
1411+ "cpu": [
1412+ "arm64"
1413+ ],
1414+ "dev": true,
1415+ "license": "MIT",
1416+ "optional": true,
1417+ "os": [
1418+ "darwin"
1419+ ],
1420+ "engines": {
1421+ "node": ">=18"
1422+ }
1423+ },
1424+ "node_modules/@esbuild/darwin-x64": {
1425+ "version": "0.25.12",
1426+ "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.12.tgz",
1427+ "integrity": "sha512-HQ9ka4Kx21qHXwtlTUVbKJOAnmG1ipXhdWTmNXiPzPfWKpXqASVcWdnf2bnL73wgjNrFXAa3yYvBSd9pzfEIpA==",
1428+ "cpu": [
1429+ "x64"
1430+ ],
1431+ "dev": true,
1432+ "license": "MIT",
1433+ "optional": true,
1434+ "os": [
1435+ "darwin"
1436+ ],
1437+ "engines": {
1438+ "node": ">=18"
1439+ }
1440+ },
1441+ "node_modules/@esbuild/freebsd-arm64": {
1442+ "version": "0.25.12",
1443+ "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.12.tgz",
1444+ "integrity": "sha512-gA0Bx759+7Jve03K1S0vkOu5Lg/85dou3EseOGUes8flVOGxbhDDh/iZaoek11Y8mtyKPGF3vP8XhnkDEAmzeg==",
1445+ "cpu": [
1446+ "arm64"
1447+ ],
1448+ "dev": true,
1449+ "license": "MIT",
1450+ "optional": true,
1451+ "os": [
1452+ "freebsd"
1453+ ],
1454+ "engines": {
1455+ "node": ">=18"
1456+ }
1457+ },
1458+ "node_modules/@esbuild/freebsd-x64": {
1459+ "version": "0.25.12",
1460+ "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.12.tgz",
1461+ "integrity": "sha512-TGbO26Yw2xsHzxtbVFGEXBFH0FRAP7gtcPE7P5yP7wGy7cXK2oO7RyOhL5NLiqTlBh47XhmIUXuGciXEqYFfBQ==",
1462+ "cpu": [
1463+ "x64"
1464+ ],
1465+ "dev": true,
1466+ "license": "MIT",
1467+ "optional": true,
1468+ "os": [
1469+ "freebsd"
1470+ ],
1471+ "engines": {
1472+ "node": ">=18"
1473+ }
1474+ },
1475+ "node_modules/@esbuild/linux-arm": {
1476+ "version": "0.25.12",
1477+ "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.12.tgz",
1478+ "integrity": "sha512-lPDGyC1JPDou8kGcywY0YILzWlhhnRjdof3UlcoqYmS9El818LLfJJc3PXXgZHrHCAKs/Z2SeZtDJr5MrkxtOw==",
1479+ "cpu": [
1480+ "arm"
1481+ ],
1482+ "dev": true,
1483+ "license": "MIT",
1484+ "optional": true,
1485+ "os": [
1486+ "linux"
1487+ ],
1488+ "engines": {
1489+ "node": ">=18"
1490+ }
1491+ },
1492+ "node_modules/@esbuild/linux-arm64": {
1493+ "version": "0.25.12",
1494+ "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.12.tgz",
1495+ "integrity": "sha512-8bwX7a8FghIgrupcxb4aUmYDLp8pX06rGh5HqDT7bB+8Rdells6mHvrFHHW2JAOPZUbnjUpKTLg6ECyzvas2AQ==",
1496+ "cpu": [
1497+ "arm64"
1498+ ],
1499+ "dev": true,
1500+ "license": "MIT",
1501+ "optional": true,
1502+ "os": [
1503+ "linux"
1504+ ],
1505+ "engines": {
1506+ "node": ">=18"
1507+ }
1508+ },
1509+ "node_modules/@esbuild/linux-ia32": {
1510+ "version": "0.25.12",
1511+ "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.12.tgz",
1512+ "integrity": "sha512-0y9KrdVnbMM2/vG8KfU0byhUN+EFCny9+8g202gYqSSVMonbsCfLjUO+rCci7pM0WBEtz+oK/PIwHkzxkyharA==",
1513+ "cpu": [
1514+ "ia32"
1515+ ],
1516+ "dev": true,
1517+ "license": "MIT",
1518+ "optional": true,
1519+ "os": [
1520+ "linux"
1521+ ],
1522+ "engines": {
1523+ "node": ">=18"
1524+ }
1525+ },
1526+ "node_modules/@esbuild/linux-loong64": {
1527+ "version": "0.25.12",
1528+ "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.12.tgz",
1529+ "integrity": "sha512-h///Lr5a9rib/v1GGqXVGzjL4TMvVTv+s1DPoxQdz7l/AYv6LDSxdIwzxkrPW438oUXiDtwM10o9PmwS/6Z0Ng==",
1530+ "cpu": [
1531+ "loong64"
1532+ ],
1533+ "dev": true,
1534+ "license": "MIT",
1535+ "optional": true,
1536+ "os": [
1537+ "linux"
1538+ ],
1539+ "engines": {
1540+ "node": ">=18"
1541+ }
1542+ },
1543+ "node_modules/@esbuild/linux-mips64el": {
1544+ "version": "0.25.12",
1545+ "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.12.tgz",
1546+ "integrity": "sha512-iyRrM1Pzy9GFMDLsXn1iHUm18nhKnNMWscjmp4+hpafcZjrr2WbT//d20xaGljXDBYHqRcl8HnxbX6uaA/eGVw==",
1547+ "cpu": [
1548+ "mips64el"
1549+ ],
1550+ "dev": true,
1551+ "license": "MIT",
1552+ "optional": true,
1553+ "os": [
1554+ "linux"
1555+ ],
1556+ "engines": {
1557+ "node": ">=18"
1558+ }
1559+ },
1560+ "node_modules/@esbuild/linux-ppc64": {
1561+ "version": "0.25.12",
1562+ "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.12.tgz",
1563+ "integrity": "sha512-9meM/lRXxMi5PSUqEXRCtVjEZBGwB7P/D4yT8UG/mwIdze2aV4Vo6U5gD3+RsoHXKkHCfSxZKzmDssVlRj1QQA==",
1564+ "cpu": [
1565+ "ppc64"
1566+ ],
1567+ "dev": true,
1568+ "license": "MIT",
1569+ "optional": true,
1570+ "os": [
1571+ "linux"
1572+ ],
1573+ "engines": {
1574+ "node": ">=18"
1575+ }
1576+ },
1577+ "node_modules/@esbuild/linux-riscv64": {
1578+ "version": "0.25.12",
1579+ "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.12.tgz",
1580+ "integrity": "sha512-Zr7KR4hgKUpWAwb1f3o5ygT04MzqVrGEGXGLnj15YQDJErYu/BGg+wmFlIDOdJp0PmB0lLvxFIOXZgFRrdjR0w==",
1581+ "cpu": [
1582+ "riscv64"
1583+ ],
1584+ "dev": true,
1585+ "license": "MIT",
1586+ "optional": true,
1587+ "os": [
1588+ "linux"
1589+ ],
1590+ "engines": {
1591+ "node": ">=18"
1592+ }
1593+ },
1594+ "node_modules/@esbuild/linux-s390x": {
1595+ "version": "0.25.12",
1596+ "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.12.tgz",
1597+ "integrity": "sha512-MsKncOcgTNvdtiISc/jZs/Zf8d0cl/t3gYWX8J9ubBnVOwlk65UIEEvgBORTiljloIWnBzLs4qhzPkJcitIzIg==",
1598+ "cpu": [
1599+ "s390x"
1600+ ],
1601+ "dev": true,
1602+ "license": "MIT",
1603+ "optional": true,
1604+ "os": [
1605+ "linux"
1606+ ],
1607+ "engines": {
1608+ "node": ">=18"
1609+ }
1610+ },
1611+ "node_modules/@esbuild/linux-x64": {
1612+ "version": "0.25.12",
1613+ "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.12.tgz",
1614+ "integrity": "sha512-uqZMTLr/zR/ed4jIGnwSLkaHmPjOjJvnm6TVVitAa08SLS9Z0VM8wIRx7gWbJB5/J54YuIMInDquWyYvQLZkgw==",
1615+ "cpu": [
1616+ "x64"
1617+ ],
1618+ "dev": true,
1619+ "license": "MIT",
1620+ "optional": true,
1621+ "os": [
1622+ "linux"
1623+ ],
1624+ "engines": {
1625+ "node": ">=18"
1626+ }
1627+ },
1628+ "node_modules/@esbuild/netbsd-arm64": {
1629+ "version": "0.25.12",
1630+ "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.12.tgz",
1631+ "integrity": "sha512-xXwcTq4GhRM7J9A8Gv5boanHhRa/Q9KLVmcyXHCTaM4wKfIpWkdXiMog/KsnxzJ0A1+nD+zoecuzqPmCRyBGjg==",
1632+ "cpu": [
1633+ "arm64"
1634+ ],
1635+ "dev": true,
1636+ "license": "MIT",
1637+ "optional": true,
1638+ "os": [
1639+ "netbsd"
1640+ ],
1641+ "engines": {
1642+ "node": ">=18"
1643+ }
1644+ },
1645+ "node_modules/@esbuild/netbsd-x64": {
1646+ "version": "0.25.12",
1647+ "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.12.tgz",
1648+ "integrity": "sha512-Ld5pTlzPy3YwGec4OuHh1aCVCRvOXdH8DgRjfDy/oumVovmuSzWfnSJg+VtakB9Cm0gxNO9BzWkj6mtO1FMXkQ==",
1649+ "cpu": [
1650+ "x64"
1651+ ],
1652+ "dev": true,
Cut short: this commit's diff is over 1000 lines.
package.json+9−1
Cut short: this commit's diff is over 1000 lines.
src/app/actions/conversations.ts+94−0
Cut short: this commit's diff is over 1000 lines.
src/app/conversation/[id]/page.tsx+21−0
Cut short: this commit's diff is over 1000 lines.
src/app/layout.tsx+2−0
Cut short: this commit's diff is over 1000 lines.
src/components/app-sidebar.tsx+141−1
Cut short: this commit's diff is over 1000 lines.
src/components/chat.tsx+126−5
Cut short: this commit's diff is over 1000 lines.
src/components/ui/sonner.tsx+49−0
Cut short: this commit's diff is over 1000 lines.
src/db/index.ts+10−0
Cut short: this commit's diff is over 1000 lines.
src/db/schema.ts+41−0
Cut short: this commit's diff is over 1000 lines.
src/lib/chat.ts+4−4
Cut short: this commit's diff is over 1000 lines.
src/lib/env.ts+14−0
Cut short: this commit's diff is over 1000 lines.