Skip to main content

ironclaw memory

Query and manage the workspace memory system. The workspace provides persistent storage for documents, notes, and context that the agent can access during conversations.

Subcommands

  • search - Search workspace memory (hybrid full-text + semantic)
  • read - Read a file from the workspace
  • write - Write content to a workspace file
  • tree - Show workspace directory tree
  • status - Show workspace status and statistics

Search workspace memory using hybrid full-text and semantic search.

Syntax

Arguments

<QUERY> Search query string.

Flags

--limit, -l <NUMBER> Maximum number of results to return.
  • Default: 5
  • Maximum: 50

Examples

Output

Score indicators:
  • =====> - Very relevant (score > 0.8)
  • ====> - Relevant (score > 0.5)
  • ===> - Somewhat relevant (score > 0.3)
  • ==> - Marginally relevant (score > 0.1)
  • => - Low relevance (score ≤ 0.1)

ironclaw memory read

Read a file from the workspace.

Syntax

Arguments

<PATH> File path relative to workspace root (e.g., MEMORY.md, daily/2024-01-15.md).

Examples

Output

The file content is printed to stdout:

Error Handling


ironclaw memory write

Write content to a workspace file.

Syntax

Arguments

<PATH> File path to write to (e.g., notes/idea.md). [CONTENT] Content to write. If omitted, reads from stdin.

Flags

--append, -a Append to file instead of overwriting.

Examples

Write Inline Content

Write from Stdin

Append to File

Output

or

ironclaw memory tree

Display the workspace directory structure.

Syntax

Arguments

[PATH] Root path to start from.
  • Default: “ (workspace root)

Flags

--depth, -d <NUMBER> Maximum depth to traverse.
  • Default: 3

Examples

Output


ironclaw memory status

Show workspace status and statistics.

Syntax

Examples

Output

Markers:
  • [+] - File exists
  • [-] - File does not exist

Key Identity Files

The workspace includes several important identity files:
  • MEMORY.md - Core facts and context about the user
  • HEARTBEAT.md - Regular updates about agent state and activities
  • IDENTITY.md - Agent personality and behavior guidelines
  • SOUL.md - Deeper values and philosophical grounding
  • AGENTS.md - Agent-to-agent communication protocols
  • USER.md - User preferences and interaction style

Workspace Structure

The workspace is organized hierarchically:

Search Capabilities

The search command uses hybrid search combining:
  1. Full-text search - Keyword matching in content
  2. Semantic search - Meaning-based similarity (requires embeddings)
Results are ranked by relevance score (0.0 - 1.0) and limited by the --limit flag.

Content Indexing

Files are automatically indexed when:
  • Written through ironclaw memory write
  • Created by the agent during conversations
  • Modified through the workspace API
Indexing includes:
  • Full-text indexing for keyword search
  • Vector embeddings for semantic search (if configured)

Working with Stdin/Stdout

Pipe to Write

Read to Pipe

Chain Commands

Database Backends

Memory commands work with both PostgreSQL and libSQL backends. The backend is determined by environment variables:

Troubleshooting

”Database connection required”

Memory commands require a database:
Check that DATABASE_URL or LIBSQL_PATH is set.

”No results found”

The query may be too specific, or the workspace may be empty:

“File not found”

Verify the file exists:
  • config - Configure workspace settings
  • doctor - Check database connectivity