TypeMaid - Turn mermaid diagrams into typed ai automations

by•
"Diagram is the Program!" - Us TypeMaid runs AI workflows drawn as simple Mermaid flowcharts. Each box is a typed TypeScript step checked with Zod. Run agents with any model through the Vercel AI SDK, pause for human approval, retry steps, and resume saved runs. Leave a Star on Github if you like the Idea!

Add a comment

Replies

Best
Maker
📌

Hi Product Hunt, I'm Hitesh, and I built TypeMaid.

You draw the flow in a Mermaid file, and each box in the diagram is a TypeScript function with a Zod schema. The diagram decides what runs next, so no model picks the next step.

What it does today:

  • Agent steps through the Vercel AI SDK, so you can use OpenAI, Anthropic, Gemini, Ollama, LiteLLM and others.

  • Human approval steps. A run pauses, is saved, and resumes later.

  • Branches, loops, parallel steps and retries, all written in the diagram.

  • Saved runs in SQLite, Postgres or libSQL, plus a local viewer.

The repo has a full AI example: a planner, two searches in parallel, an AI judge that loops until the draft scores well, and an editor approval step.

Docs and quickstart:

I'd like to hear what workflows you would build with it, and where the diagram format gets in your way.

How does your product turn technology into positive change? Share the cause you're supporting, the people you're helping, and the impact you hope to make. Tell us what you deployed on Cloud Run and how it works together. Which of these did you use? - Deploy and host a web app - Host LLMs with Cloud Run GPUs - Host AI agents - Build microservices - Data processing
Maker
TypeMaid, Free on Github&NPM, turns a simple Mermaid flowchart into a AI workflow. Each box in the diagram is a typed TypeScript step, checked with Zod. The diagram decides what runs next, so no model chooses the next step. Steps can call AI models through the Vercel AI SDK, pause for a person to approve, retry on failure, and save runs so they can resume later. The playground is a web app for trying this out. It has two files, a diagram (flow.mmd) and the steps (tools.ts), and three actions: - Check reports problems in the diagram with line numbers and a suggested fix. - Run executes the diagram with the input you give it. - Write with AI takes a plain-language description and writes both files. The AI's code is shown first and only runs when you click Run. How we use Cloud Run: We deploy the playground as a single Cloud Run service: a Bun server that serves the page and the check, run!