SPB Git

spb/airiskindex Public

The most methodologically rigorous, fully transparent AI job-exposure index.

TypeScript 88% Python 6.1% SQL 2.7% CSS 1.2% JavaScript 0.9% Shell 0.8%
688 B · 22 lines typescript
Raw Blame History
1//  File:    index.ts2//  Path:    packages/db/src/index.ts3//  Project: AI Risk Index — airiskindex.io4//  Author:  Simon-Pierre Boucher5//  Contact: contact@spboucher.ai6//  Copyright © 2026 Simon-Pierre Boucher. All rights reserved.7//8//  Description: Prisma client singleton shared across apps.910import { PrismaClient } from "@prisma/client";1112// Singleton to avoid exhausting connections under Next.js dev hot-reload.13const globalForPrisma = globalThis as unknown as { prisma?: PrismaClient };1415export const prisma = globalForPrisma.prisma ?? new PrismaClient();1617if (process.env.NODE_ENV !== "production") {18  globalForPrisma.prisma = prisma;19}2021export * from "@prisma/client";22