ax-playbook
Installation
SKILL.md
Playbook Codegen Rules (@ax-llm/ax)
Use this skill to generate context-playbook code. A playbook grows an evolving body of task knowledge and renders it into a program's context. The evolution engine (ACE — Agentic Context Engineering) is hidden behind playbook(...), exactly as optimize(...) hides its optimizer. Prefer the playbook(...) concept; only reach for AxACE directly when the user explicitly wants the low-level engine.
Use These Defaults
- Create with
playbook(program, { studentAI, teacherAI? }); it returns anAxPlaybookhandle. - Grow offline with
await pb.evolve(examples, metric)— returns{ bestScore, playbook }. - Grow online with
await pb.update({ example, prediction, feedback })— no metric needed. - Apply with
pb.applyTo(program)(defaults to the bound program). - Persist with
pb.toJSON()and restore withplaybook(program, opts).load(snapshot). - Inspect with
pb.render()(markdown) andpb.getState()({ playbook, artifact }). - For agents use
agent.playbook({ target: 'actor' | 'responder' }); default target is'actor'. - Use a cheaper
studentAIto run the program and an optional strongerteacherAIto reflect/curate. - Prefer
ai(),ax(), andagent()for new code.