aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gn3/api/llm.py2
-rw-r--r--sql/update/llm_db_tables.sql2
-rw-r--r--sql/update/llm_db_update.sql2
3 files changed, 3 insertions, 3 deletions
diff --git a/gn3/api/llm.py b/gn3/api/llm.py
index 8d17bc2..9ee4a79 100644
--- a/gn3/api/llm.py
+++ b/gn3/api/llm.py
@@ -40,7 +40,7 @@ def search():
history(user_id TEXT NOT NULL,
task_id TEXT NOT NULL,
query TEXT NOT NULL,
- results TEXT,
+ results JSONB,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY(task_id)) WITHOUT ROWID""")
cursor.execute(
diff --git a/sql/update/llm_db_tables.sql b/sql/update/llm_db_tables.sql
index a6c0479..b501832 100644
--- a/sql/update/llm_db_tables.sql
+++ b/sql/update/llm_db_tables.sql
@@ -26,7 +26,7 @@ CREATE TABLE IF NOT EXISTS history (
user_id TEXT NOT NULL,
task_id TEXT NOT NULL,
query TEXT NOT NULL,
- results TEXT,
+ results JSONB,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (task_id)
) WITHOUT ROWID;
diff --git a/sql/update/llm_db_update.sql b/sql/update/llm_db_update.sql
index a4eb848..7f1a9f9 100644
--- a/sql/update/llm_db_update.sql
+++ b/sql/update/llm_db_update.sql
@@ -25,7 +25,7 @@ CREATE TABLE IF NOT EXISTS history (
user_id TEXT NOT NULL,
task_id TEXT NOT NULL,
query TEXT NOT NULL,
- results TEXT,
+ results JSONB,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (task_id)
) WITHOUT ROWID;