Agent Apprenticeship CLI

A CLI for training agents: your agent works on a task, and a mentor model reviews the result and sends back remarks

  • 1,603 ★ on the repository
  • Last commit
  • MIT
CLI

Broad access

Why this level

  • Launches local agent CLIs that run commands and change files in the working folder
  • Stores model provider keys in ~/.agent-apprenticeship/.env.local and sends task context to those providers
  • In the public mode shares learning signals with the shared ecosystem
All reasons and checks
Needs a VPN

ray-r-ren/agent-apprenticeship

Install

In your terminal, with SkillFoxx CLI

npx skillfoxx add cli/agent-apprenticeship

Detects the agents on your machine, shows the access level and pins the version.

Other ways to install

Access and checks

How we review

Broad accessThe tool can change data, run commands or handle secrets.

  • Launches local agent CLIs that run commands and change files in the working folder
  • Stores model provider keys in ~/.agent-apprenticeship/.env.local and sends task context to those providers
  • In the public mode shares learning signals with the shared ecosystem

This is third-party code. Review the repository files before installing.

What it does

Agent Apprenticeship installs as an npm package and adds the apprentice command. You give it a task, for example "create a short market map for AI procurement tools". The apprentice, your local agent, performs the task while a mentor reviews the result and sends back remarks. The loop repeats until the work passes review or the iteration limit runs out. The apprentice is an agent CLI on your machine, and the mentor is a model reached through a provider API. There are three working modes: Autonomous, Expert-Led and Organization Custom. Each run builds an Experience Compilation: traces, lessons and training data. It can be installed as Runtime Training so later runs start with the accumulated lessons.

Who it is for. For developers and researchers who run Claude Code, Codex or another agent on repeating tasks and want to build lessons and data out of those runs.

Good fit when

  • An agent handles a task unreliably and you want to run it through a loop checked by a mentor model and not accept the first answer
  • You need execution traces and structured lessons for later tuning or training of your own agent
  • You want to install previously gathered experience and see whether later runs get better
  • A team needs a private mode where experience stays inside the organization and review follows its own set of rules
  • You need to run several different agents on one task and compare the results

Not a fit when

  • You only want a one-off task done fast: the mentor loop spends tokens and time on every iteration
  • Task context must not go to outside model providers: the mentor works only through their APIs
  • You need a ready skill or MCP server for a specific service: the project offers infrastructure for training agents

Example request

Run apprentice run with the task "create a release checklist for an AI agent project", show the mentor iterations and the path to the Experience Compilation

Limitations

  • It needs Node.js for the npx command and Python: the core is written in Python and installed through pyproject.
  • The mentor needs a key from at least one provider. The OpenAI and Anthropic APIs are unavailable from Russia.
  • Every loop iteration spends tokens of both the mentor model and your agent.
  • The datasets live on Hugging Face apart from the package.
  • Install the apprentice agent first: the setup wizard picks only from CLIs it finds on the machine.
  • The license is MIT.

How to disable. Remove the global package with npm uninstall -g agent-apprenticeship and the ~/.agent-apprenticeship directory with settings and mentor keys. Installed Runtime Training is stored there too. If you ran it via npx there is nothing to uninstall except the data directory.

FAQ

How do I install Agent Apprenticeship and connect it to Claude Code?

Run npx agent-apprenticeship init. The wizard detects installed agent CLIs and asks you to pick the apprentice, Claude Code included. Then apprentice configure and apprentice doctor set up and check the agent and the mentor model.

What is an Experience Compilation in Agent Apprenticeship?

It is the outcome of a run: execution traces, lessons and structured training records. apprentice bundle check validates it, apprentice ecosystem export with the --full flag exports it in full, and apprentice learn install installs it as Runtime Training.

What data does Agent Apprenticeship send to the shared ecosystem?

It depends on the mode. In Public Ecosystem a run shares learning signals with the community, and in Private Internal Only experience stays inside. You pick the mode with apprentice settings; the full list of transmitted fields is not published.

Which agents and models can I use with Agent Apprenticeship?

As the apprentice: Codex, Cursor, Claude Code, OpenClaw, OpenCode, Hermes Agent and your own command template. The mentor is an OpenAI, Anthropic, Gemini or OpenRouter model.

How do I limit the number of loop iterations in Agent Apprenticeship?

Set the maximum loop depth in apprentice settings. For a single terminal session the AA_MAX_ITERATIONS environment variable works, for example export AA_MAX_ITERATIONS=3.

Discussion

No questions or reviews yet.

CLI tools

A CLI installer and package manager for coding agent skills: one command installs skills into many runtimes and helps build your own

CLIExtended access1.2KRepository stars

A CLI that detects your project's stack and installs matching agent skills from a vetted registry in one command

CLIExtended access7KRepository stars

An open coding agent for the terminal, browser and desktop that works with models from OpenAI and Claude to Ollama

CLIBroad access359Repository stars

A portable .agent folder with memory, skills and protocols that plugs into many coding agents and keeps its knowledge when you switch tools

CLIBroad access2.3KRepository stars

A CLI that packs local AI skills into ready-to-run agents for a team: create, zip and run with one command

CLIExtended access1.2KRepository stars

A tool that builds tested skills from a real workflow and governs their lifecycle through your own marketplace

PluginExtended access2.4KRepository stars

Comparison with similar tools

Entries that share the main search query, and how they differ.

EntryOfficialRepository starsMain difference
Agent Apprenticeship (this entry)no1,603
Autocontextno1,314runs an agent task through evaluation and saves traces, reports and a playbook
claude-smartno789a plugin that turns user corrections into rules for later sessions
Self-Improving Agentno782a skill for OpenClaw that records errors and corrections into .learnings files

README in short

The idea: agents work on tasks in loops, mentors grade them, and finished work becomes reusable experience and data. A starter dataset comes with the package, and a version of it is published on Hugging Face.

README badge

Report a problem

Foxx AIAgent Apprenticeship
Foxx AI

I am Foxx AI and I have already vetted this tool. Ask about install, setup or anything else, and I will keep it simple.