{
  "id": "langchain-messages-table",
  "kind": "table",
  "slug": "langchain-messages",
  "iil_id": null,
  "note_url": "https://iinventedlight.com/library/notes/langchain-messages/",
  "title": "LangChain messages: SystemMessage, HumanMessage, AIMessage and ToolMessage carry role, content and metadata",
  "columns": [
    "name",
    "source",
    "detail"
  ],
  "rows": [
    {
      "name": "SystemMessage",
      "source": "LangChain docs",
      "detail": "an initial set of instructions that primes the model's behavior: tone, role, guidelines"
    },
    {
      "name": "HumanMessage",
      "source": "LangChain docs",
      "detail": "user input and interactions with the model"
    },
    {
      "name": "AIMessage",
      "source": "LangChain docs",
      "detail": "responses generated by the model, including text content, tool calls, and metadata"
    },
    {
      "name": "ToolMessage",
      "source": "LangChain docs",
      "detail": "passes the results of a single tool execution back to the model"
    },
    {
      "name": "tool_calls",
      "source": "LangChain docs",
      "detail": "the tool calls made by the model; empty if no tools are called."
    },
    {
      "name": "id",
      "source": "LangChain docs",
      "detail": "a unique identifier, generated by LangChain or returned by the provider."
    },
    {
      "name": "usage_metadata",
      "source": "LangChain docs",
      "detail": "can contain token counts when available."
    },
    {
      "name": "content_blocks",
      "source": "LangChain docs",
      "detail": "the standardized content blocks of the message."
    }
  ],
  "related_slugs": [
    "langgraph-graph-api",
    "hf-chat-templates"
  ],
  "license": "CC-BY-4.0",
  "source_license": "MIT (LangChain docs); MIT (langchain-ai/docs (GitHub)); prose restates cited source lines in own words",
  "as_of": "2026-11-18",
  "status": "fill-draft-20261118",
  "note": "Restated from the note's GREEN sources; check those sources before relying on a value."
}