Skip to main content
Glama

export_skill

Package rule-level patterns into a SKILL.md file compatible with skills-aware agent runtimes. Builds YAML frontmatter and Markdown body from observed patterns.

Instructions

Package rule-level patterns as a SKILL.md file (anthropics/skills format).

    Builds a complete Skill document: YAML frontmatter (name,
    description) followed by a Markdown body grouping each rule-level
    pattern by category, with confidence and explain text. The returned
    string is ready to write to disk as SKILL.md and install into a
    skills-aware agent runtime (e.g. agentskills.io). Read-only.

    For human-readable CLAUDE.md output use export_claude_md(). For
    editor-specific formats (.cursorrules, AGENTS.md) use
    export_platform(target). For raw JSON use export_rules().

    Args:
        name: Skill identifier written into the YAML frontmatter.
            Becomes the Skill's name on disk. Default "instinct-rules".
        description: One-sentence description in the frontmatter.
            Empty string auto-generates "Learned patterns from N
            observations" using the current rule count.
        category: Filter rules by type. One of "sequence",
            "preference", "fix_pattern", "combo". Empty string (default)
            includes every category.

    Returns:
        On success: {"skill_md": str, "rule_count": int, "hint": str}.
        "skill_md" is the full file content ready to write. "rule_count"
        is parsed from the rendered body (number of rule bullets).

        On empty store: {"skill_md": "", "rule_count": 0, "hint": str}.
        "hint" explains the promoted >= 2 prerequisite and directs the
        caller to run consolidate() first so mature patterns can cross
        the threshold.
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameNoinstinct-rules
descriptionNo
categoryNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description carries full burden. It declares 'Read-only', details return values for success and empty store, and explains the hint about prerequisites. No contradictions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well-structured with purpose first, then alternative guidance, parameter docs, and return value. Slightly verbose but every sentence adds value. Could be tightened slightly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 3 params, no nested objects, and existence of output schema, the description covers all necessary context: parameters, usage, prerequisites, return values, and edge cases. Complete for effective use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but description provides detailed explanations for all 3 parameters (name, description, category) including default behavior and allowed values, going well beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb 'Package' and resource 'rule-level patterns' outputting a SKILL.md file. It clearly distinguishes from siblings by naming alternative tools (export_claude_md, export_platform, export_rules).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states when to use this tool vs alternatives with references to other functions. Also describes behavior on empty store, directing user to consolidate() as prerequisite.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/WRG-11/instinct'

If you have feedback or need assistance with the MCP directory API, please join our Discord server