langchain-architecture
Design LLM applications using LangChain 1.x and LangGraph for agents, memory, and tool integration. Use when building LangChain applications, implementing AI agents, or creating complex LLM workflows.
By wshobson · 11,975 installs
npx skills add wshobson/agents --skill langchain-architecture
Source repository · Upstream listing
LangChain & LangGraph Architecture
Master modern LangChain 1.x and LangGraph for building sophisticated LLM applications with agents, state management, memory, and tool integration.
When to Use This Skill
Building autonomous AI agents with tool access
Implementing complex multi step LLM workflows
Managing conversation memory and state
Integrating LLMs with external data sources and APIs
Creating modular, reusable LLM application components
Implementing document processing pipelines
Building production grade LLM applications
Package Structure (LangChain 1.x)
Core Concepts
1. LangGraph Agents
LangGraph is the standard for building agents in 2026. It provides:
Key Features:
StateGraph : Explicit state management with typed state
Durable Execution : Agents persist through failures
Human in the Loop : Inspect and modify state at any point
Memory : Short term and long term memory across sessions
Checkpointing : Save and resume agent state
Agent Patterns:
ReAct : Reasoning + Acting with create react agent
Plan and Execute : Separate planning and execution nodes
Multi Agent : Supervisor routing between specialized agents
Tool Calling : Structured tool invocation with Pydantic schemas
2. State Management
LangGraph uses TypedDict for explicit state:
3. Memory Systems
Modern memory implementations:
ConversationBufferMemory : Stores all messages (short conversations)
ConversationSummaryMemory : Summarizes older messages (long conversations)
ConversationTokenBufferMemory : Token based windowing
VectorStoreRetrieverMemory : Semantic similarity retrieval
LangGraph Checkpointers : Persistent state across sessions
4. Document Processing
Loading, transforming, and storing documents:
Components:
Document Loaders : Load from various sources
Text Splitters : Chunk documents intelligently
Vector Stores : Store and retrieve embeddings
Retrievers : Fetch relevant documents
5. Callbacks & Tracing
LangSmith is the standard for observability:
Request/response logging
Token usage tracking
Latency monitoring
Error tracking
Trace visualization
Quick Start
Modern ReAct Agent with LangGraph
Detailed patterns and worked examples
Detailed pattern documentation lives in references/details.md . Read that file when the navigation tier above is insufficient.
Testing Strategies
Performance Optimization
1. Caching with Redis
2. Async Batch Processing
3. Connection Pooling