Subtask-aware retrieval
Match what the agent is trying to do—not just the title of the task—against successful and failed prior attempts.
Open source · MIT-0
Agent Experience Graph turns sanitized execution traces into reusable skills, tools, workflow patterns, and failure warnings—so the next agent starts with evidence, not an empty slate.
Build markdown API docs ingestion
The vision
Today, agents repeatedly rediscover the same decomposition, tool choices, guardrails, and dead ends. AEG makes those lessons retrievable across tasks and runtimes.
Think of it as workplace memory for agents: “Who has solved something like this before, and what worked?”
Core capabilities
Small, inspectable building blocks that fit the agent stack you already use.
Match what the agent is trying to do—not just the title of the task—against successful and failed prior attempts.
Recommend skills, tools, lessons, and warnings with outcome context. The agent decides what fits its current constraints.
Store compact lessons and execution structure—not secrets, customer content, proprietary code, or raw conversations.
Architecture overview
Portable markdown instructions, a neutral manifest, and a small local recommender.
Task, subtasks, outcomes, skills, tools, constraints, and reusable lessons.
Rank related attempts using task and subtask overlap, with outcome context.
Surface proven tools, workflow patterns, local lessons, and failed paths.
After execution, record a redacted summary so future agents improve.
Example
This interaction mirrors the repository’s bundled trace recommender.
Ready to search sanitized traces
No network requiredDecomposing current task
Comparing 3 example traces
Ranking outcome evidence
“Preserve headings, code blocks, auth hints, and endpoint metadata before chunking.”
Quick start
Clone the project and run the recommender against the bundled trace library. Python 3.9+ is the only runtime requirement.
Installation options for every runtime# Clone the portable capability
git clone https://github.com/yao23/agent-experience-graph.git
cd agent-experience-graph
# Retrieve experience for a new task
python3 scripts/recommend_traces.py \
--traces assets/example_traces.json \
--query '{"task":"Build markdown API docs ingestion","subtasks":[{"description":"parse markdown into sections"}]}'
Contribute
The most useful graph includes what worked, what failed, and why. Contributions should stay portable, testable, and privacy-safe.
Explore the repositoryAdd compact examples with clear outcomes and lessons—never raw private work.
Experiment with ranking, evaluation, negative evidence, and trace quality signals.
Make the same capability easy to load from more agent environments.
Measure whether experience lowers retries, latency, token cost, and failure rates.