One-click install
npx skills add https://github.com/InverterNetwork/hermes-agent --skill guidance-inverternetwork
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: guidance
Source: https://github.com/InverterNetwork/hermes-agent/tree/main/optional-skills/mlops/guidance
Command: npx skills add https://github.com/InverterNetwork/hermes-agent --skill guidance-inverternetwork

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires guidance, transformers, and includes references (resource) components.

What problem does it solve?

This Skill solves the challenge of unpredictable LLM output by enforcing strict syntax, structure, and format constraints, ensuring that generated content is always valid and usable.

Core Features & Use Cases

  • Constrained Generation: Use regex and grammars to force the model to output specific formats like JSON, XML, or custom code.
  • Token Healing: Automatically fixes token boundary issues to ensure natural text flow and perfect spacing.
  • Multi-Step Workflows: Build complex, stateful agentic workflows with Pythonic control flow and tool integration.

Quick Start

Use the guidance skill to generate a valid JSON object representing a user profile with name and age fields.

Frequently Asked Questions about guidance

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

FAQPage Schema
How do I constrain LLM generation to guarantee valid JSON output?

Constrained LLM generation uses regex and grammars to enforce strict syntax and format constraints, guaranteeing valid structured output like JSON or XML. This ensures the generated content is always valid and usable.

What is token healing in large language models?

Token healing automatically fixes token boundary issues during constrained generation. It ensures natural text flow and perfect spacing when using grammars and selection patterns to control model responses.

How do I build stateful multi-step workflows with LLMs?

Build stateful multi-step agentic workflows by using Pythonic control flow and tool integration alongside constrained generation. This combination provides token-level control over model responses and facilitates reliable deterministic data structures.

Does constrained generation work with local and remote model backends?

Constrained generation integrates with both local and remote backends to provide token-level control over model responses. This allows you to enforce strict syntax and structure regardless of your model deployment environment.

Why does my LLM output fail JSON validation?

LLM output fails JSON validation due to unpredictable formatting and syntax errors. Applying grammars and selection patterns enforces strict syntax constraints, guaranteeing that the generated content is always valid and usable.