refactor(core): consolidate tool architecture
This commit is contained in:
parent
0fd73a2976
commit
8db7487c89
466 changed files with 9405 additions and 11071 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import { sqliteTable, text, integer, index, uniqueIndex } from "drizzle-orm/sqlite-core"
|
||||
import type { EventV2 } from "../event"
|
||||
import { Event } from "@opencode-ai/schema/event"
|
||||
|
||||
export const EventSequenceTable = sqliteTable("event_sequence", {
|
||||
aggregate_id: text().notNull().primaryKey(),
|
||||
|
|
@ -10,7 +10,7 @@ export const EventSequenceTable = sqliteTable("event_sequence", {
|
|||
export const EventTable = sqliteTable(
|
||||
"event",
|
||||
{
|
||||
id: text().$type<EventV2.ID>().primaryKey(),
|
||||
id: text().$type<Event.ID>().primaryKey(),
|
||||
aggregate_id: text()
|
||||
.notNull()
|
||||
.references(() => EventSequenceTable.aggregate_id, { onDelete: "cascade" }),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue