OpenClaw

ClicheFactory skill for the OpenClaw agent framework — extraction tools with agent-level instructions.

What is OpenClaw

OpenClaw is an open-source framework for building AI agent workflows. The ClicheFactory skill gives an OpenClaw agent the ability to extract structured data from documents and convert them to markdown, with built-in instructions for handling errors and choosing the right extraction strategy.

Skill Installation

Install the ClicheFactory skill from the skill registry:

openclaw skills install clichefactory

Or install from source:

cp -r /path/to/cliche-mcp/integrations/openclaw ~/.openclaw/skills/clichefactory

The skill bundles agent instructions and the MCP server configuration. It is not a repeat of the MCP setup — it adds a layer of agent guidance on top.

Configuration

The skill needs the ClicheFactory MCP server registered with OpenClaw. If you haven't already:

openclaw mcp set clichefactory '{
  "command": "uvx",
  "args": ["clichefactory-mcp"],
  "env": {
    "LLM_MODEL_NAME": "gemini/gemini-3-flash-preview",
    "LLM_API_KEY": "your-key"
  }
}'

See MCP Server → OpenClaw Setup for details on local vs. service mode configuration.

Usage

Once installed, the agent follows a structured workflow when asked to extract data from documents:

  1. Inspect the document — the agent calls to_markdown to understand the document structure and content.
  2. Build a schema — based on the document content and the user's request, the agent constructs a JSON schema describing the fields to extract.
  3. Extract — the agent calls extract with the document and schema, choosing the appropriate extraction mode.
  4. Handle errors — if extraction fails or returns validation errors, the agent adjusts the schema or mode and retries.
  5. Diagnose — if repeated failures occur, the agent calls doctor to check the configuration and reports findings to the user.

The skill instructions guide the agent through this workflow automatically — you just ask for what you need in natural language.

Supported File Types

The ClicheFactory skill supports PDF, images (PNG, JPG, WebP, GIF, BMP), DOCX, XLSX, CSV, EML, TXT, and more — see Supported File Types for the full list.