Skip to content

Instantly share code, notes, and snippets.

import { eq } from "drizzle-orm";
import { type DrizzleD1Database } from "drizzle-orm/d1";
import { type GenericTable, project } from "./db/schema";
// This is what I'd like to use, which is defined with my schema.
// (See import above, though the rest of the file shouldn't be relevant.)
// type GenericTable = typeof <tableA> | typeof <tableB> | ...
// I also tried this, but it doesn't work either.
// const Tables = {
@wadefletch
wadefletch / inference.py
Created July 23, 2024 23:44
Minimal triple extraction workflow
import asyncio
import logging
import re
import instructor
import pydantic
logging.basicConfig(level=logging.INFO)
logger = logging.getLogger(__name__)