langgraph-trajectory

Record, export, and replay LangGraph execution trajectories with checkpoint history.

2|Updated Mar 7, 2026
One-click install
npx skills add https://github.com/Lincyaw/AgentM --skill langgraph-trajectory
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: langgraph-trajectory
Source: https://github.com/Lincyaw/AgentM/tree/main/.claude/skills/langgraph-trajectory
Command: npx skills add https://github.com/Lincyaw/AgentM --skill langgraph-trajectory

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill addresses the challenge of understanding, debugging, and reusing complex LangGraph execution flows by providing robust methods for capturing, exporting, and replaying execution trajectories.

Core Features & Use Cases

  • Hierarchical Tracing: Captures parent-child relationships in multi-agent systems.
  • Checkpointing & Replay: Records state snapshots for post-hoc analysis and resuming from failures.
  • RL-Ready Export: Structures trajectory data for reinforcement learning training.
  • Use Case: Debug a multi-agent LangGraph application by replaying its execution from a specific point of failure, or export a full trajectory for training a reinforcement learning agent to optimize its decision-making process.

Quick Start

Use the langgraph-trajectory skill to export the complete execution trajectory from checkpoint history for a given configuration.

Frequently Asked Questions about langgraph-trajectory

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I record and replay LangGraph execution trajectories for debugging?

You can replay LangGraph executions from a specific point of failure by recording checkpoint history and hierarchical traces. This allows post-hoc analysis and debugging of multi-agent systems by resuming from the exact failed state.

What is the best way to export LangGraph trajectories for RL training?

Exporting LangGraph trajectories for RL training involves serializing execution traces and checkpoint history into structured data. This prepares the recorded state snapshots directly for reinforcement learning agent optimization.

Can I capture parent-child relationships in multi-agent LangGraph systems?

Yes, hierarchical tracing captures parent-child relationships in multi-agent LangGraph systems. It records the execution flows and interactions between agents to provide a complete view of the multi-agent architecture.

How do I monitor LangGraph execution flows in real-time?

Monitor LangGraph execution flows in real-time using stream(stream_mode="debug"). This provides live visibility into the execution trajectory and state changes as they happen during the run.

Does langgraph-trajectory work with checkpoint history for post-hoc analysis?

Yes, it works with checkpoint history for post-hoc analysis by retrieving state snapshots via get_state_history(). This allows you to inspect and analyze execution flows after the LangGraph run has completed.

Why should I serialize checkpoint history when a LangGraph execution fails?

Serialize checkpoint history when a LangGraph execution fails to enable replay from the exact point of failure. This allows you to resume execution and debug the specific failed state without restarting the entire process.