-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
architectureArchitecture and design decisionsArchitecture and design decisionsenhancementNew feature or requestNew feature or requesthigh-priorityHigh priorityHigh priority
Description
Summary
Add a LangGraph framework starter that teaches developers how to use LangGraph by building an agent that plays Agent Arena scenarios. This is Phase 2 of the framework adapter system.
Key framing: "Want to learn LangGraph? Build an AI agent that plays a game." This starter is a tutorial for LangGraph, not just a template.
Prerequisites
- Add framework adapter system for LangGraph, Claude Agent SDK, and other agent frameworks #74 (framework adapter foundation + Anthropic starter) — provides the adapter ABC, observation formatter, and canonical tool definitions that this starter builds on
Deliverables
LangGraph Starter (starters/langgraph/)
| File | Purpose |
|---|---|
agent.py |
LangGraph adapter + agent graph with tutorial comments |
run.py |
One-command startup |
requirements.txt |
agent-arena-sdk, langgraph, langchain-anthropic (or langchain-openai) |
README.md |
Learning goals, setup, how to modify, debugging |
What It Teaches
- Graph construction — StateGraph, nodes, edges, conditional routing
- Tool nodes —
StructuredTool.from_function(), ToolNode - State management — LangGraph state schema, message passing
- ReAct pattern — tool calling loop with action detection
- Checkpointing — LangGraph memory (optional section)
Architecture
The LangGraph starter uses the adapter base from #74:
class LangGraphAdapter(FrameworkAdapter):
def decide(self, observation: Observation) -> Decision:
# 1. Format observation as context (inherited from base)
context = self.format_observation(observation)
# 2. Convert action tools to LangChain StructuredTools
tools = [StructuredTool.from_function(...) for t in self.get_action_tools()]
# 3. Build and invoke LangGraph agent
result = self.graph.invoke({"messages": [HumanMessage(context)]})
# 4. Extract action tool call from result, return as Decision
return self._extract_decision(result)Tests
- Unit tests for LangGraph adapter (mock LLM responses)
- Verify tool schema conversion to LangChain format
- Integration test with hand-built Observations
Success Criteria
- Developer can have a LangGraph agent playing foraging in under 15 minutes
- Starter teaches LangGraph core concepts through tutorial-quality comments
- Uses the shared adapter base from Add framework adapter system for LangGraph, Claude Agent SDK, and other agent frameworks #74 (observation formatting, tool schemas)
- Works with at least one LLM provider (Anthropic or OpenAI)
- README includes learning goals, prerequisites, and modification guide
Context
See docs/framework_integration_strategy.md for the full strategic discussion. This is Phase 2 of the framework integration roadmap.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
architectureArchitecture and design decisionsArchitecture and design decisionsenhancementNew feature or requestNew feature or requesthigh-priorityHigh priorityHigh priority
Type
Projects
Status
Backlog