LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • LangGraph Checkpoint
    Checkpoint Postgres
    Store Postgres
    Checkpoint SQLite
    LangGraph Prebuilt
    LangGraph CLI
    LangGraph SDK
    LangGraph Supervisor
    LangGraph Swarm
    ⌘I

    LangChain Assistant

    Ask a question to get started

    Enter to send•Shift+Enter new line

    Menu

    LangGraph Checkpoint
    Checkpoint Postgres
    Store Postgres
    Checkpoint SQLite
    LangGraph Prebuilt
    LangGraph CLI
    LangGraph SDK
    LangGraph Supervisor
    LangGraph Swarm
    Language
    Theme
    Pythonlanggraph.checkpointbase
    Module●Since v1.0

    base

    Attributes

    attribute
    ERROR: str
    attribute
    INTERRUPT: str
    attribute
    RESUME: str
    attribute
    SCHEDULED: str
    attribute
    V
    attribute
    PendingWrite: tuple[str, str, Any]
    attribute
    logger
    attribute
    ChannelVersions: dict[str, str | int | float]
    attribute
    WRITES_IDX_MAP: dict
    attribute
    EXCLUDED_METADATA_KEYS: set
    attribute
    LATEST_VERSION: int

    Functions

    function
    uuid6

    UUID version 6 is a field-compatible version of UUIDv1, reordered for improved DB locality. It is expected that UUIDv6 will primarily be used in contexts where there are existing v1 UUIDs. Systems that do not involve legacy UUIDv1 SHOULD consider using UUIDv7 instead.

    If 'node' is not given, a random 48-bit number is chosen.

    If 'clock_seq' is given, it is used as the sequence number; otherwise a random 14-bit sequence number is chosen.

    function
    maybe_add_typed_methods

    Wrap serde old serde implementations in a class with loads_typed and dumps_typed for backwards compatibility.

    function
    copy_checkpoint
    function
    get_checkpoint_id

    Get checkpoint ID.

    function
    get_checkpoint_metadata

    Get checkpoint metadata in a backwards-compatible manner.

    function
    get_serializable_checkpoint_metadata

    Get checkpoint metadata in a backwards-compatible manner.

    function
    empty_checkpoint
    function
    create_checkpoint

    Create a checkpoint for the given channels.

    Classes

    class
    SerializerProtocol

    Protocol for serialization and deserialization of objects.

    • dumps_typed: Serialize an object to a tuple (type, bytes).
    • loads_typed: Deserialize an object from a tuple (type, bytes).

    Valid implementations include the pickle, json and orjson modules.

    class
    EncryptedSerializer

    Serializer that encrypts and decrypts data using an encryption protocol.

    class
    JsonPlusSerializer

    Serializer that uses ormsgpack, with optional fallbacks.

    Warning

    Security note: This serializer is intended for use within the BaseCheckpointSaver class and called within the Pregel loop. It should not be used on untrusted python objects. If an attacker can write directly to your checkpoint database, they may be able to trigger code execution when data is deserialized.

    Set the environment variable LANGGRAPH_STRICT_MSGPACK=true to restrict deserialization to a built-in allowlist of safe types. You can also pass an explicit allowed_msgpack_modules to the constructor.

    class
    ChannelProtocol
    class
    CheckpointMetadata

    Metadata associated with a checkpoint.

    class
    Checkpoint

    State snapshot at a given point in time.

    class
    CheckpointTuple

    A tuple containing a checkpoint and its associated data.

    class
    DeltaChannelHistory

    Per-channel result entry from BaseCheckpointSaver.get_delta_channel_history.

    Storage-level view of what one channel contributed across the ancestor chain of a target checkpoint:

    • writes — on-path deltas oldest→newest as PendingWrite tuples. Always present; possibly empty. Already filtered to one channel. Writes stored at the target checkpoint itself are pending for the next super-step and are excluded.
    • seed — the stored value at the nearest ancestor whose channel_values[ch] is populated. Omitted if the walk reached the root without finding any stored value (consumer treats absence as "start empty"). Typically a _DeltaSnapshot for delta channels with finite snapshot frequency, or a plain value for threads migrated from a pre-delta channel type.
    class
    BaseCheckpointSaver

    Base class for creating a graph checkpointer.

    Checkpointers allow LangGraph agents to persist their state within and across multiple interactions.

    When a checkpointer is configured, you should pass a thread_id in the config when invoking the graph:

    config = {"configurable": {"thread_id": "my-thread"}}
    graph.invoke(inputs, config)

    The thread_id is the primary key used to store and retrieve checkpoints. Without it, the checkpointer cannot save state, resume from interrupts, or enable time-travel debugging.

    How you choose thread_id depends on your use case:

    • Single-shot workflows: Use a unique ID (e.g., uuid4) for each run when executions are independent.
    • Conversational memory: Reuse the same thread_id across invocations to accumulate state (e.g., chat history) within a conversation.
    class
    EmptyChannelError

    Raised when attempting to get the value of a channel that hasn't been updated for the first time yet.

    Modules

    module
    id

    Adapted from https://github.com/oittaa/uuid6-python/blob/main/src/uuid6/__init__.py#L95 Bundled in to avoid install issues with uuid6 package

    View source on GitHub