Guidance
Open Source
Library
Control generation structure with guaranteed output formats
About
Guidance is Microsoft's library for controlling large language models with structured generation. It enables interleaving generation, prompting, and logical control into a single continuous flow, uses context-free grammar (CFG) to guarantee valid output formats like JSON, and achieves 50% faster inference through token healing and prompt caching. Supports all major LLM providers with a simple, intuitive syntax.
Compatibility
Supported Languages
python
Details
- Category
- Library