xml-pipeline/docs/wiki/reference/CLI.md
dullfig 515c738abb Add wiki documentation for xml-pipeline.org
Comprehensive documentation set for XWiki:
- Home, Installation, Quick Start guides
- Writing Handlers and LLM Router guides
- Architecture docs (Overview, Message Pump, Thread Registry, Shared Backend)
- Reference docs (Configuration, Handler Contract, CLI)
- Hello World tutorial
- Why XML rationale
- Pandoc conversion scripts (bash + PowerShell)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-20 20:40:47 -08:00

2.2 KiB

CLI Reference

xml-pipeline provides a command-line interface for running and managing organisms.

Commands

xml-pipeline run

Run an organism from a configuration file.

xml-pipeline run [CONFIG_PATH]

Arguments:

  • CONFIG_PATH — Path to organism.yaml (default: config/organism.yaml)

Examples:

xml-pipeline run config/organism.yaml
xml-pipeline run                        # Uses default path
xp run config/my-organism.yaml          # Short alias

xml-pipeline init

Create a new organism configuration from template.

xml-pipeline init [NAME]

Arguments:

  • NAME — Organism name (default: my-organism)

Creates:

{NAME}/
├── config/
│   └── organism.yaml
├── handlers/
│   └── hello.py
└── .env.example

Examples:

xml-pipeline init my-agent
xml-pipeline init                       # Uses default name

xml-pipeline check

Validate configuration without running.

xml-pipeline check [CONFIG_PATH]

Arguments:

  • CONFIG_PATH — Path to organism.yaml (default: config/organism.yaml)

Output:

Config valid: hello-world
  Listeners: 3
  LLM backends: 1

Examples:

xml-pipeline check config/organism.yaml
xml-pipeline check                      # Uses default path

xml-pipeline version

Show version and installed features.

xml-pipeline version

Output:

xml-pipeline 0.4.0
Python 3.11.5
Features: anthropic, console, redis, search

Short Alias

The xp command is a short alias for xml-pipeline:

xp run config/organism.yaml
xp init my-agent
xp check
xp version

Environment Variables

Variable Description
XAI_API_KEY xAI (Grok) API key
ANTHROPIC_API_KEY Anthropic (Claude) API key
OPENAI_API_KEY OpenAI API key

Create a .env file in your project root:

XAI_API_KEY=xai-...
ANTHROPIC_API_KEY=sk-ant-...

Exit Codes

Code Meaning
0 Success
1 Configuration error
2 Runtime error

See Also