Hello everyone,
I’ve been working on Phi, a compile-time ORM for Go that uses the Prisma Schema Language as its source of truth to generate fully typed Go code.
small note:
If raw SQL is your preferred way of working, that’s perfectly fine. Phi isn’t intended to replace it, it’s another option for devs who prefer a Prisma-style workflow.
Unlike prisma-client-go, Phi is completely independent of Prisma’s Node/Rust engines. Everything is written in Go, with the Prisma schema acting as the source of truth.
Some of the current features include:
- Compile-time code generation
- Fully typed query API
- Prisma Schema Language support
- Pure Go implementation
- Integration with Atlas and Goose for migrations
The project started after prisma-client-go was deprecated. Rather than building on top of Prisma’s runtime, I decided to build a standalone implementation with a different architecture.
I just released v0.1.0. It’s still early and far from perfect, but it’s already performing very well against ORMs like GORM, Ent, and Bun
I’d really appreciate it if you could check it out and share any feedback, suggestions, contributions, or even just help spread the word, There’s still a lot of work ahead, and I’d love to build it with the community.
