Skip to content
Memory
AGH RuntimeMemory

agh memory write

Write or update a persistent memory file

Audience
Operators running durable agent work
Focus
Memory guidance shaped for scanability, day-two clarity, and operator context.

agh memory write

Write or update a persistent memory file

agh memory write <filename> --type <type> --description <description> [flags]

Examples

  # Write workspace-scoped project memory from a flag
  agh memory write runtime-notes.md --type project --description "Runtime docs live in the site package" --content "Runtime docs are authored under packages/site/content/runtime."

  # Write global user memory from stdin
  printf "Prefer concise PR summaries.\n" | agh memory write review-style.md --type user --description "User wants concise PR summaries"

Options

      --content string       Memory body content (alternative to stdin)
      --description string   One-line durable memory description
  -h, --help                 help for write
      --scope string         Memory scope: global or workspace
      --type string          Memory type: user, feedback, project, or reference

Options inherited from parent commands

      --json            Emit JSON output
  -o, --output string   Output format: human, json, jsonl, or toon (default "human")

Output Formats

Every AGH command supports -o, --output:

  • human for interactive terminal use
  • json for scripts and other machine-readable consumers
  • jsonl for wait or streaming commands that emit one JSON record per line
  • toon for compact agent-readable summaries

Example:

agh memory write <filename> --type <type> --description <description> -o json

On this page