# Agent Runtime Documentation

## Overview
OpenClaw operates a single embedded agent runtime based on pi-mono, utilizing a workspace directory as the primary working environment for tools and contextual operations.

## Key Components

**Workspace Structure**: The system requires a designated workspace (`agents.defaults.workspace`) serving as the sole working directory. The setup process creates `~/.openclaw/openclaw.json` and initializes necessary files.

**Bootstrap Files**: On initial session startup, OpenClaw injects several user-editable files:
- `AGENTS.md` - operational guidelines
- `SOUL.md` - personality definition
- `TOOLS.md` - tool usage documentation
- `IDENTITY.md` - agent identification
- `USER.md` - user preferences
- `BOOTSTRAP.md` - first-run setup (removed after completion)

## Tools & Skills

Core tools for file operations are built-in and always available. Skills load from three locations with workspace taking precedence: bundled skills, managed local skills, and workspace-specific skills.

## Session Management

Session transcripts are stored as JSONL at `~/.openclaw/agents/<agentId>/sessions/` with stable, OpenClaw-assigned session identifiers.

## Configuration

Model references require `provider/model` formatting. Minimum configuration includes workspace path and WhatsApp channel allowlist settings.
