+/- table definition

Query

CREATE TABLE "agents_observations"  (
  "id" varchar(36) PRIMARY KEY NOT NULL,
  "agentId" varchar(36) NOT NULL,
  "observationScopeId" varchar(255) NOT NULL,
  "marker" varchar(16) NOT NULL,
  "text" text NOT NULL,
  "parentId" varchar(36),
  "tokenCount" integer NOT NULL DEFAULT (0),
  "status" varchar(16) NOT NULL,
  "supersededBy" varchar(36),
  "createdAt" datetime(3) NOT NULL DEFAULT (STRFTIME('%Y-%m-%d %H:%M:%f', 'NOW')),
  "updatedAt" datetime(3) NOT NULL DEFAULT (STRFTIME('%Y-%m-%d %H:%M:%f', 'NOW')),
  CONSTRAINT "CHK_agents_observations_marker" CHECK ("marker" IN ('critical', 'important', 'info', 'completion')),
  CONSTRAINT "CHK_agents_observations_status" CHECK ("status" IN ('active', 'superseded', 'dropped')),
  CONSTRAINT "FK_d206432be97b7ed88d187479b1b" FOREIGN KEY ("agentId") REFERENCES "agents" ("id") ON DELETE CASCADE,
  CONSTRAINT "FK_4cfd8a70ebb0a5b0cf047dca3cf" FOREIGN KEY ("observationScopeId") REFERENCES "agents_threads" ("id") ON DELETE CASCADE,
  CONSTRAINT "FK_501e2d1701a10e24fb69ab5fc5f" FOREIGN KEY ("parentId") REFERENCES "agents_observations" ("id"),
  CONSTRAINT "FK_127ee1078ffa952bb37b511efad" FOREIGN KEY ("supersededBy") REFERENCES "agents_observations" ("id")
)
Use Shift + Up/Down to navigate recently-executed queries