-
Notifications
You must be signed in to change notification settings - Fork 0
Quickstart
rrahimi-uci edited this page Jun 30, 2026
·
1 revision
git clone https://github.com/rrahimi-uci/agentic-context-engineering && cd agentic-context-engineering
pip install -e . # core library (numpy + rich only)For the OpenAI Agents SDK integration and real LLM backends:
pip install "ace-playbook[all]" # adds openai + openai-agents (SDK needs Python 3.10+)
export OPENAI_API_KEY=sk-...The core library needs Python 3.9+; the OpenAI Agents SDK integration needs Python 3.10+.
The bundled SimulatedLLM + TeachingEnvironment make this fully deterministic
and offline:
ace demo --html report.html┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━━━━┓
┃ Method ┃ Accuracy ┃ Playbook ┃ Note ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━━━━┩
│ Base LLM (no context) │ 44.4% │ 0 │ — │
│ ACE (offline → eval) │ 83.3% │ 5 │ +38.9 pts │
│ Monolithic rewrite (online) │ 72.2% │ 4 │ 2 collapses │
│ ACE (online) │ 83.3% │ 6 │ no collapse │
└─────────────────────────────┴──────────┴──────────┴─────────────┘
Watch a run adapt live in your terminal:
ace run # animated dashboard: playbook growth, accuracy, deltasOther CLI subcommands:
ace playbook # inspect a saved playbook
ace version # print the installed versionfrom ace import ACE, SimulatedLLM, TeachingEnvironment, build_teaching_task
from ace.baselines import StaticAgent
env = TeachingEnvironment()
task = build_teaching_task()
train, test = task.split()
base = StaticAgent(SimulatedLLM(env)).run(test) # no learning
ace = ACE(SimulatedLLM(env))
ace.adapt_offline(train) # build a playbook from feedback
result = ace.evaluate(test) # measure on held-out data
print(f"Base {base.accuracy:.0f}% → ACE {result.accuracy:.0f}%")
print(ace.playbook.render()) # human-readable playbook- How It Works — the mechanics of the adaptation loop.
- OpenAI Agents SDK — make a real agent self-improving in one call.
- Custom Tasks and Feedback — point ACE at your own data and signals.
- Cookbook — 10 short recipes, ordered as a learning path.
ACE — Agentic Context Engineering · MIT · Independent open-source reproduction of ICLR 2026 arXiv:2510.04618. All credit for the method belongs to the original authors.