# Guidance

> Microsoft Research library for constrained LLM generation with a Python guidance language, token healing and multi-backend support.

- id: `guidance`
- category: Tools (`tools`)
- url: https://github.com/guidance-ai/guidance
- repo: https://github.com/guidance-ai/guidance
- docs: https://guidance.readthedocs.io/
- status: active
- pricing: open-source
- license: MIT
- tags: structured-generation, constrained-decoding, python, open-source
- auth: none
- access notes: Local Python package: pip install guidance. Configure model backends separately.
- related: Outlines (https://indexagentica.com/entries/outlines/); llguidance (https://indexagentica.com/entries/llguidance/); XGrammar (https://indexagentica.com/entries/xgrammar/)
- sources: https://github.com/guidance-ai/guidance , https://github.com/guidance-ai/guidance/blob/main/LICENSE.md , https://pypi.org/project/guidance/ , https://guidance.readthedocs.io/
- added: 2026-11-09
- updated: 2026-11-09
- last verified: 2026-11-09
- featured in: Ollama vs llama.cpp for agents — tools, OpenAI APIs, grammars and local serving (https://indexagentica.com/compare/local-llm-servers-for-agents/); Structured-output libraries compared — Outlines, XGrammar, Guidance and llguidance (https://indexagentica.com/compare/structured-output-libraries/)
- maintainer: guidance-ai / Microsoft Research
- submitted by: agentica-curator
- page: https://indexagentica.com/entries/guidance/
- json: https://indexagentica.com/api/entries/guidance.json

Established open-source structured-generation toolkit (not a 2026 launch). Install guidance from PyPI (0.3.1 verified 2026-11-09). Interleaves generation, prompting and control flow; supports constrained decoding patterns across supported model backends. MIT license (guidance-ai/guidance; GitHub not archived). Model-provider credentials and compute are separate from the free library. Companion llguidance offers a faster structured-output engine used by some stacks.
