agentleFS
MicrosoftKnown publishermicrosoft/Sico/labs/AgentStream/exgentic/misc/skills/add-agent/SKILL.md

add-agent

Skill253 starsChanged 5 months agoMITView on GitHub

Use when adding or updating an agent adapter in the Exgentic repository. Follow the repository agent principles, separate lightweight config from heavy execution logic, isolate third-party dependencies behind lazy imports, adapt to any benchmark contract without requiring benchmark changes, and validate the adapter with representative smoke tests before finishing.

9 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use setup.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • VercelSkill

    setup

    Set up Vercel CLI and project configuration. Use when the user says "set up Vercel", "configure Vercel", "link to Vercel", or "vercel init".

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

8 rules. 0 are common, 3 are distinctive, and 5 are very specific to this project.

  • 0

    Common

    Most of the 7 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 5

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill when working on agent adapters in the Exgentic repository.

    line 8
  2. Very specific:

    If the agent depends on heavy third-party libraries (litellm, smolagents, openai SDK, etc.), put the Agent in one file and the …

    line 25
  3. Very specific:

    Add requirements.txt for agent-specific dependencies.

    line 33
  4. Very specific:

    Add setup.sh if non-pip setup is needed.

    line 36
  5. Very specific:

    Place it next to the agent module.

    line 37
  6. Very specific:

    Add a RegistryEntry to the AGENTS dict.

    line 40
  7. Distinctive:

    Check registry loading, dependency isolation, at least one end-to-end benchmark run, cost reporting, and cleanup.

    line 43
  8. Distinctive:

    Before finishing, run at least:

    line 58

“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Add Agent

Use this skill when working on agent adapters in the Exgentic repository.

First read

Start with:

  • docs/adding-agents.md
  • src/exgentic/core/agent.py
  • src/exgentic/core/agent_instance.py
  • src/exgentic/interfaces/registry.py

Then inspect the most relevant existing adapters:

  • src/exgentic/agents/litellm_tool_calling/litellm_tool_calling_agent.py + instance.py (split pattern: heavy deps in separate file)
  • src/exgentic/agents/cli/claude/agent.py (light pattern: everything in one file)

Workflow

  1. Decide whether to split files. If the agent depends on heavy third-party libraries (litellm, smolagents, openai SDK, etc.), put the Agent in one file and the AgentInstance in instance.py. If deps are light, keep both in a single file.
  2. Implement the Agent class first. Subclass Agent. Declare display_name and slug_name as ClassVar[str]. Add user-facing config fields. Implement _get_instance_class() with a lazy import. Implement _get_instance_kwargs() to translate config and the benchmark contract into instance constructor kwargs.
  3. Implement the AgentInstance class. Subclass AgentInstance. Accept session_id plus the kwargs from _get_instance_kwargs(). Call super().__init__(session_id). Implement react() as the core decision loop and close() for cleanup. Optionally override start() and get_cost().
  4. Add requirements.txt for agent-specific dependencies. List only packages not already in the base exgentic install. Place the file in the agent's package directory; RunnerMixin discovers it automatically.
  5. Add setup.sh if non-pip setup is needed. Place it next to the agent module; RunnerMixin discovers it automatically.
  6. Register the agent in src/exgentic/interfaces/registry.py. Add a RegistryEntry to the AGENTS dict. Ensure slug_name and display_name match the class exactly.
  7. Validate the adapter as an agent, not just as code. Check registry loading, dependency isolation, at least one end-to-end benchmark run, cost reporting, and cleanup.

Non-negotiable rules

  • The Agent file must be importable without installing agent-specific packages.
  • _get_instance_class() must use a lazy import to isolate heavy deps.
  • _get_instance_kwargs() must faithfully pass the benchmark contract (task, context, actions, session_id) through to the instance.
  • The instance constructor must call super().__init__(session_id).
  • react() must return None when the agent decides it is done.
  • close() must not raise exceptions.
  • slug_name and display_name in the registry entry must exactly match the class values.
  • The agent must adapt to the benchmark, never the other way around.

Validation

Before finishing, run at least:

  • python -m py_compile on changed agent files
  • pre-commit run --files ...
  • git diff --check

Also confirm:

  • load_agent("slug_name") succeeds from a Python shell
  • The Agent file imports cleanly without agent-specific packages installed
  • At least one benchmark runs end to end with the new agent
  • close() completes without error
  • get_cost() returns a valid report

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.