From d827412febd69920bf1463b8943b7141288c7982 Mon Sep 17 00:00:00 2001 From: Avraham Sakal Date: Fri, 29 Aug 2025 16:17:39 -0400 Subject: [PATCH] update postgresql schema --- database/generated/Database.ts | 2 +- database/generated/public/Conversations.ts | 10 ++++---- database/generated/public/FactTriggers.ts | 28 ++++++++-------------- database/generated/public/Facts.ts | 18 ++++++-------- database/generated/public/Messages.ts | 20 +++++++--------- database/generated/public/PublicSchema.ts | 12 +++++----- database/generated/public/Role.ts | 5 +++- database/generated/public/Tools.ts | 28 ++++++++-------------- database/generated/public/Users.ts | 8 +++---- 9 files changed, 55 insertions(+), 76 deletions(-) diff --git a/database/generated/Database.ts b/database/generated/Database.ts index 8fa64f8..2fa9940 100644 --- a/database/generated/Database.ts +++ b/database/generated/Database.ts @@ -1,7 +1,7 @@ // @generated // This file is automatically generated by Kanel. Do not modify manually. -import type { default as PublicSchema } from "./public/PublicSchema"; +import type { default as PublicSchema } from './public/PublicSchema'; type Database = PublicSchema; diff --git a/database/generated/public/Conversations.ts b/database/generated/public/Conversations.ts index eebf6b2..6b0dce3 100644 --- a/database/generated/public/Conversations.ts +++ b/database/generated/public/Conversations.ts @@ -1,11 +1,11 @@ // @generated // This file is automatically generated by Kanel. Do not modify manually. -import type { UsersId } from "./Users"; -import type { ColumnType, Selectable, Insertable, Updateable } from "kysely"; +import type { UsersId } from './Users'; +import type { ColumnType, Selectable, Insertable, Updateable } from 'kysely'; /** Identifier type for public.conversations */ -export type ConversationsId = number & { __brand: "public.conversations" }; +export type ConversationsId = number & { __brand: 'public.conversations' }; /** Represents the table public.conversations */ export default interface ConversationsTable { @@ -13,9 +13,9 @@ export default interface ConversationsTable { title: ColumnType; - created_at: ColumnType; + createdAt: ColumnType; - user_id: ColumnType; + userId: ColumnType; } export type Conversations = Selectable; diff --git a/database/generated/public/FactTriggers.ts b/database/generated/public/FactTriggers.ts index aa8bdba..7734f06 100644 --- a/database/generated/public/FactTriggers.ts +++ b/database/generated/public/FactTriggers.ts @@ -1,36 +1,28 @@ // @generated // This file is automatically generated by Kanel. Do not modify manually. -import type { FactsId } from "./Facts"; -import type { ConversationsId } from "./Conversations"; -import type { ColumnType, Selectable, Insertable, Updateable } from "kysely"; +import type { FactsId } from './Facts'; +import type { ConversationsId } from './Conversations'; +import type { ColumnType, Selectable, Insertable, Updateable } from 'kysely'; /** Identifier type for public.fact_triggers */ -export type FactTriggersId = number & { __brand: "public.fact_triggers" }; +export type FactTriggersId = number & { __brand: 'public.fact_triggers' }; /** Represents the table public.fact_triggers */ export default interface FactTriggersTable { id: ColumnType; - fact_id: ColumnType; + sourceFactId: ColumnType; - trigger_phrase: ColumnType; + content: ColumnType; - priority_multiplier: ColumnType; + priorityMultiplier: ColumnType; - priority_multiplier_reason: ColumnType< - string | null, - string | null, - string | null - >; + priorityMultiplierReason: ColumnType; - scope_conversation_id: ColumnType< - ConversationsId | null, - ConversationsId | null, - ConversationsId | null - >; + scopeConversationId: ColumnType; - created_at: ColumnType; + createdAt: ColumnType; } export type FactTriggers = Selectable; diff --git a/database/generated/public/Facts.ts b/database/generated/public/Facts.ts index b44732b..271bc32 100644 --- a/database/generated/public/Facts.ts +++ b/database/generated/public/Facts.ts @@ -1,28 +1,24 @@ // @generated // This file is automatically generated by Kanel. Do not modify manually. -import type { UsersId } from "./Users"; -import type { MessagesId } from "./Messages"; -import type { ColumnType, Selectable, Insertable, Updateable } from "kysely"; +import type { UsersId } from './Users'; +import type { MessagesId } from './Messages'; +import type { ColumnType, Selectable, Insertable, Updateable } from 'kysely'; /** Identifier type for public.facts */ -export type FactsId = number & { __brand: "public.facts" }; +export type FactsId = number & { __brand: 'public.facts' }; /** Represents the table public.facts */ export default interface FactsTable { id: ColumnType; - user_id: ColumnType; + userId: ColumnType; - source_message_id: ColumnType< - MessagesId | null, - MessagesId | null, - MessagesId | null - >; + sourceMessageId: ColumnType; content: ColumnType; - created_at: ColumnType; + createdAt: ColumnType; } export type Facts = Selectable; diff --git a/database/generated/public/Messages.ts b/database/generated/public/Messages.ts index c596dee..7b2c4e5 100644 --- a/database/generated/public/Messages.ts +++ b/database/generated/public/Messages.ts @@ -1,32 +1,28 @@ // @generated // This file is automatically generated by Kanel. Do not modify manually. -import type { ConversationsId } from "./Conversations"; -import type { default as Role } from "./Role"; -import type { ColumnType, Selectable, Insertable, Updateable } from "kysely"; +import type { ConversationsId } from './Conversations'; +import type { default as Role } from './Role'; +import type { ColumnType, Selectable, Insertable, Updateable } from 'kysely'; /** Identifier type for public.messages */ -export type MessagesId = number & { __brand: "public.messages" }; +export type MessagesId = number & { __brand: 'public.messages' }; /** Represents the table public.messages */ export default interface MessagesTable { id: ColumnType; - conversation_id: ColumnType< - ConversationsId | null, - ConversationsId | null, - ConversationsId | null - >; + conversationId: ColumnType; index: ColumnType; - content: ColumnType; - - running_summary: ColumnType; + runningSummary: ColumnType; created_at: ColumnType; role: ColumnType; + + parts: ColumnType; } export type Messages = Selectable; diff --git a/database/generated/public/PublicSchema.ts b/database/generated/public/PublicSchema.ts index bb33082..5612c18 100644 --- a/database/generated/public/PublicSchema.ts +++ b/database/generated/public/PublicSchema.ts @@ -1,12 +1,12 @@ // @generated // This file is automatically generated by Kanel. Do not modify manually. -import type { default as UsersTable } from "./Users"; -import type { default as MessagesTable } from "./Messages"; -import type { default as ToolsTable } from "./Tools"; -import type { default as FactTriggersTable } from "./FactTriggers"; -import type { default as FactsTable } from "./Facts"; -import type { default as ConversationsTable } from "./Conversations"; +import type { default as UsersTable } from './Users'; +import type { default as MessagesTable } from './Messages'; +import type { default as ToolsTable } from './Tools'; +import type { default as FactTriggersTable } from './FactTriggers'; +import type { default as FactsTable } from './Facts'; +import type { default as ConversationsTable } from './Conversations'; export default interface PublicSchema { users: UsersTable; diff --git a/database/generated/public/Role.ts b/database/generated/public/Role.ts index c69e55f..309d9ed 100644 --- a/database/generated/public/Role.ts +++ b/database/generated/public/Role.ts @@ -2,6 +2,9 @@ // This file is automatically generated by Kanel. Do not modify manually. /** Represents the enum public.role */ -type Role = "user" | "assistant" | "system"; +type Role = + | 'user' + | 'assistant' + | 'system'; export default Role; diff --git a/database/generated/public/Tools.ts b/database/generated/public/Tools.ts index 2b8ad61..0c028b6 100644 --- a/database/generated/public/Tools.ts +++ b/database/generated/public/Tools.ts @@ -1,40 +1,32 @@ // @generated // This file is automatically generated by Kanel. Do not modify manually. -import type { UsersId } from "./Users"; -import type { MessagesId } from "./Messages"; -import type { ColumnType, Selectable, Insertable, Updateable } from "kysely"; +import type { UsersId } from './Users'; +import type { MessagesId } from './Messages'; +import type { ColumnType, Selectable, Insertable, Updateable } from 'kysely'; /** Identifier type for public.tools */ -export type ToolsId = number & { __brand: "public.tools" }; +export type ToolsId = number & { __brand: 'public.tools' }; /** Represents the table public.tools */ export default interface ToolsTable { id: ColumnType; - user_id: ColumnType; + userId: ColumnType; - source_message_id: ColumnType< - MessagesId | null, - MessagesId | null, - MessagesId | null - >; + sourceMessageId: ColumnType; name: ColumnType; description: ColumnType; - parameter_schema: ColumnType; + parameterSchema: ColumnType; - implementation_language: ColumnType< - string | null, - string | null, - string | null - >; + implementationLanguage: ColumnType; - implementation_code: ColumnType; + implementationCode: ColumnType; - created_at: ColumnType; + createdAt: ColumnType; } export type Tools = Selectable; diff --git a/database/generated/public/Users.ts b/database/generated/public/Users.ts index 5539cb0..07ef8ed 100644 --- a/database/generated/public/Users.ts +++ b/database/generated/public/Users.ts @@ -1,10 +1,10 @@ // @generated // This file is automatically generated by Kanel. Do not modify manually. -import type { ColumnType, Selectable, Insertable, Updateable } from "kysely"; +import type { ColumnType, Selectable, Insertable, Updateable } from 'kysely'; /** Identifier type for public.users */ -export type UsersId = number & { __brand: "public.users" }; +export type UsersId = number & { __brand: 'public.users' }; /** Represents the table public.users */ export default interface UsersTable { @@ -16,9 +16,9 @@ export default interface UsersTable { email: ColumnType; - last_login: ColumnType; + lastLogin: ColumnType; - created_at: ColumnType; + createdAt: ColumnType; } export type Users = Selectable;