Agent Design logo

Agent Design

Community
nimadorostkar
agent-design

Use when building an LLM agent that uses tools over multiple steps. Covers tool design, the agent loop, error recovery, termination, human checkpoints, and knowing when an agent is the wrong architecture. Trigger on "my agent keeps looping", "agent calls the wrong tool", "build an agent that can use our api". Do not use for delegating work to a subagent — see the subagents skill; for building the MCP server that exposes tools, see the mcp-server skill.

Overview

Publishernimadorostkar
RepositoryClaude-Skills-collection
Skill nameagent-design
Stars
34
Forks
4
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by nimadorostkar on GitHub. Read the source before you install it.

Installation

Install the Agent Design AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/nimadorostkar/Claude-Skills-collection/tree/main/skills/ai/agent-design
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/nimadorostkar/Claude-Skills-collection.git /tmp/Claude-Skills-collection
mkdir -p .claude/skills
cp -r /tmp/Claude-Skills-collection/skills/ai/agent-design .claude/skills/agent-design
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Agent Design in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Agent Design on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Agent Design is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Agent Design

Purpose

Build LLM agents that complete tasks reliably and fail safely. The two failure modes that define bad agents are looping forever without progress, and taking a destructive action confidently and wrongly.

When to Use

  • Building an agent that uses tools to accomplish multi-step tasks.
  • An agent that loops, stalls, or takes wrong actions.
  • Designing the tool surface an agent will use.
  • Deciding whether an agent is warranted at all.

Capabilities

  • Tool design: granularity, naming, descriptions, and error returns.
  • The agent loop: planning, acting, observing, and terminating.
  • Error recovery and retry.
  • Human-in-the-loop checkpoints for irreversible actions.
  • Guardrails: budgets, timeouts, and permission boundaries.

Inputs

  • The task, and how it decomposes.
  • The tools available, and which of them are destructive.
  • The acceptable cost and latency per task.

Outputs

  • A tool surface designed for a model, not lifted from an API.
  • An agent with a termination condition and a budget.
  • Checkpoints before anything irreversible.

Workflow

  1. Ask whether you need an agent — If the steps are known in advance, write the workflow. A deterministic pipeline with one LLM call per step is cheaper, faster, more debuggable, and more reliable than an agent. Agents earn their cost only when the path genuinely cannot be known in advance.
  2. Design tools for the model — Each tool does one thing, has a name that says what it does, and a description that says exactly when to use it and when not to. This description is the most important text in the system.
  3. Return useful errors — A tool that fails should say what went wrong and what to try instead. Error: 400 teaches the model nothing; Error: 'status' must be one of [open, closed]. You passed 'active'. lets it recover on the next step.
  4. Bound the loop — A maximum step count, a token budget, and a wall-clock timeout. Every agent will eventually loop; the question is whether it stops.
  5. Checkpoint the irreversible — Deleting data, sending a message, moving money, deploying. The agent proposes; a human confirms.
  6. Make it observable — Log every step: the reasoning, the tool call, the result. An agent you cannot trace is an agent you cannot debug.

Best Practices

  • The tool description is the prompt. Most agent misbehavior is a tool whose description does not clearly say when it applies.
  • Fewer, well-chosen tools beat many overlapping ones. An agent with thirty tools spends its reasoning deciding between them.
  • An agent with no termination condition will loop. Detect "no progress" explicitly: the same tool call with the same arguments twice means it is stuck, not persevering.
  • Do not give an agent a destructive tool without a confirmation step. Confidence is not competence, and the model has plenty of the former.
  • Return structured, pruned tool results. A tool that dumps 50 KB of JSON burns the context budget the agent needs to think.
  • Prefer a small, verifiable step to a large, plausible one. An agent that writes one function and runs the test is more reliable than one that writes the whole module and declares success.

Examples

A tool designed for a model rather than lifted from an API:

python
@tool
def search_orders(
    customer_email: str | None = None,
    status: Literal["open", "paid", "shipped", "cancelled"] | None = None,
    placed_after: date | None = None,
    limit: int = 20,
) -> str:
    """Search for orders. Use this to find an order when you do not know its ID.

    You must provide at least one filter. If you already have an order ID,
    use `get_order` instead — it is faster and returns full detail.

    Returns a compact list: order ID, status, total, and customer email.
    To see line items or the refund history, call `get_order` with an ID
    from these results.
    """
    if not any([customer_email, status, placed_after]):
        # An error the model can actually act on.
        return "Error: provide at least one of customer_email, status, or placed_after."

    orders = db.search(...)[:limit]
    if not orders:
        return "No orders matched. Try widening the date range or removing the status filter."

    # Compact: four fields, not the full object. The agent can fetch detail if it needs it.
    return "\n".join(
        f"{o.id} | {o.status} | {o.total_cents / 100:.2f} {o.currency} | {o.customer_email}"
        for o in orders
    )

A loop that terminates, with a checkpoint before anything irreversible:

python
async def run(task: str, max_steps: int = 25, token_budget: int = 200_000) -> Result:
    history, tokens_used, recent_calls = [], 0, deque(maxlen=3)

    for step in range(max_steps):
        response = await model.complete(task, history, tools=TOOLS)
        tokens_used += response.usage.total

        if tokens_used > token_budget:
            return Result.halted("token budget exhausted", history)

        if response.is_final:
            return Result.done(response.text, history)

        call = response.tool_call

        # No-progress detection: the same call twice in a row means it is stuck.
        signature = (call.name, json.dumps(call.args, sort_keys=True))
        if recent_calls.count(signature) >= 2:
            return Result.halted(f"looping on {call.name} with identical arguments", history)
        recent_calls.append(signature)

        # Irreversible actions require a human. The agent proposes; it does not decide.
        if call.name in DESTRUCTIVE_TOOLS:
            approval = await request_approval(call, reason=response.reasoning)
            if not approval.granted:
                history.append(tool_result(call, f"Denied by operator: {approval.reason}"))
                continue

        result = await execute(call)
        history.append(tool_result(call, result))

    return Result.halted(f"step limit ({max_steps}) reached without completing", history)

Notes

  • The single most common agent failure is repeating an identical tool call because the result did not contain what it expected. Detecting a repeated call with identical arguments catches this in one extra line of code.
  • An agent that can read but not write is dramatically safer and covers more use cases than most people assume. Start read-only and add write tools one at a time, each with a checkpoint.
  • Cost per task is the metric that determines whether an agent is viable. Measure it early — a task that takes 40 tool calls at $0.30 each is not a product feature, it is a demo.

Frequently asked questions

What does the Agent Design AI skill do?

Use when building an LLM agent that uses tools over multiple steps. Covers tool design, the agent loop, error recovery, termination, human checkpoints, and knowing when an agent is the wrong architecture. Trigger on "my agent keeps looping", "agent calls the wrong tool", "build an agent that can use our api". Do not use for delegating work to a subagent — see the subagents skill; for building the MCP server that exposes tools, see the mcp-server skill.

Why use Agent Design on TypingMind?

Because you install it once and use it with any model. Agent Design is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Agent Design in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/nimadorostkar/Claude-Skills-collection/tree/main/skills/ai/agent-design. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Agent Design?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Agent Design?

As many as you like. As long as a model supports skills, you can use Agent Design with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Agent Design AI skill free?

Yes. It is published on GitHub by nimadorostkar under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇