Getting started

TypeGlish documentation

TypeGlish compiles plain-English prompts into structured, testable programs — a real type system for English, a checker that proves contradictions before you ship, and tests that live beside the rules they guard.

Write and scale prompts like code.

Start here

Why a compiler for English

Raw prompts are sand: fast to build with, quick to crumble under weight. TypeGlish gives prompts load-bearing structure — the same prompt, graded and proven:

prompt.md → support.tg✗ crumbles✓ holds
// before: vibes
Be helpful and always try to resolve things quickly,
but never promise anything specific.

// after: a policy
# Constraints
- SHOULD resolve a request in one reply.
- NEVER state a delivery date; share a tracking link instead.
Same intent, one reading. The checker flags the before lines (an unmeasurable "be helpful", a "try to" hedge) and reads the after lines as two rules it can hold the model to.
✓Already have a prompt in production? npx typeglish check prompt.md reads plain English as-is — start from the notes it gives you.