{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/innernet-live/json-schema/innernet-live-agent-memory-schema.json",
  "title": "AgentMemory",
  "description": "One memory of one agent. Its words are sealed at rest; `content` is null only when a sealed row would not open.",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/innernet-live-openapi.json#/components/schemas/AgentMemory",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "agent": {
      "type": "string",
      "description": "The agent's slug."
    },
    "content": {
      "type": [
        "string",
        "null"
      ]
    },
    "kind": {
      "type": "string",
      "enum": [
        "fact",
        "preference",
        "episode",
        "procedure",
        "instruction",
        "note"
      ]
    },
    "subject": {
      "type": "string",
      "enum": [
        "agent",
        "owner",
        "user"
      ],
      "description": "Who it is about: the agent's own knowledge, the person who owns the agent, or one of its users."
    },
    "user_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "Your end user, when `subject` is `user`."
    },
    "run_id": {
      "type": [
        "string",
        "null"
      ]
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "metadata": {
      "type": "object",
      "additionalProperties": true
    },
    "importance": {
      "type": "integer",
      "minimum": 1,
      "maximum": 5
    },
    "confidence": {
      "type": [
        "number",
        "null"
      ]
    },
    "immutable": {
      "type": "boolean"
    },
    "source": {
      "type": "string",
      "enum": [
        "api",
        "extract",
        "dashboard",
        "import"
      ]
    },
    "event_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "expires_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "supersedes": {
      "type": [
        "string",
        "null"
      ],
      "format": "uuid",
      "description": "The memory this one is the next version of."
    },
    "superseded_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "Set once a newer version has replaced this one."
    },
    "about_you": {
      "type": [
        "object",
        "null"
      ],
      "description": "Set when the memory is about the person who owns the agent: where it stands with them.",
      "properties": {
        "state": {
          "type": "string",
          "enum": [
            "held",
            "kept",
            "declined",
            "auto"
          ]
        },
        "dimension": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    },
    "score": {
      "type": "number",
      "description": "Only on recall and context results: 0 to 1."
    }
  }
}