baml-generator

Regenerate BAML client code when .baml files change.

Updated Feb 4, 2026
One-click install
npx skills add https://github.com/orbruno/baml-ccplugin --skill baml-generator
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: baml-generator
Source: https://github.com/orbruno/baml-ccplugin/tree/main/skills/baml-generator
Command: npx skills add https://github.com/orbruno/baml-ccplugin --skill baml-generator

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Automatically regenerates the BAML client code whenever .baml definitions change, ensuring the generated artifacts stay in sync with the source without manual rebuilds.

Core Features & Use Cases

  • Generates typed client code from .baml definitions for Python and TypeScript.
  • Keeps client libraries up to date after edits to functions, types, or scaffolding.
  • Supports watch mode to auto-regenerate on file changes and streamline development workflows.

Quick Start

After editing any .baml file, run the generator to refresh the generated BAML client code.

Frequently Asked Questions about baml-generator

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automatically regenerate BAML client code when .baml files change?

To regenerate BAML client code automatically, use a generation tool that detects changes in your .baml files and executes the build command to refresh the Python or TypeScript client libraries. This keeps your generated artifacts synchronized with the source definitions.

What is the best way to keep BAML generated clients in sync after editing definitions?

Keeping BAML generated clients in sync requires running the generator after you edit functions, types, or scaffolding in your .baml files. You can also use watch mode to auto-regenerate client code on file changes and streamline your development workflow.

Does BAML code generation work for both Python and TypeScript environments?

Yes, BAML code generation works for both Python and TypeScript environments. The generator produces typed client code from .baml definitions, ensuring compatibility with your existing baml_src/ folder and baml_client/ outputs in either language setup.

What project structure do I need to run BAML client generation?

You need an existing BAML project containing a baml_src/ folder with your .baml definitions and an existing baml_client/ directory for outputs. The generator verifies these outputs after running the generation command and provides usage guidance.

Can I use watch mode to auto-regenerate BAML client code during development?

Yes, you can use watch mode to auto-regenerate BAML client code during development. This mode monitors .baml files for changes and automatically executes the generation command, streamlining your workflow without requiring manual rebuilds.

Why are my BAML client libraries out of date after adding new definitions?

Your BAML client libraries are out of date because adding new functions, types, or scaffolding to .baml files requires regenerating the client code. Run the BAML generator to refresh the artifacts and ensure they match your latest source definitions.