lg:agent

lg:agent is a command for Claude Code from TheLobbi/claude. It costs 23 tokens per session (3,412 once invoked), scanned A, original, MIT.

A command for creating, changing, and removing agents in LangGraph projects. An agent is an AI-driven workflow component with an instruction set, language-model configuration, and optional tools.

In plain words
What is it for?
Use it to add agents to multi-agent systems, configure their model and tools, set system instructions, connect their routes, or safely remove them and their references.
Why use it?
It keeps agent code, graph routes, state, tests, and documentation aligned when an agent is added or changed.

Command for Claude Code

Written for Claude Code: arguments in frontmatter. Also seen: mentions Claude Code.

Part of the langgraph-architect plugin — 5 commands, 12 agents, 1 MCP server shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/thelobbi/claude/agent
Clone the repo
git clone --depth 1 https://github.com/TheLobbi/claude

Made for: Claude Code.

Or install langgraph-architect, the plugin that ships this one along with the rest of its 5 commands, 12 agents, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for lg:agent

README.md
[![agentmods](https://agentmods.dev/badge/commands/thelobbi/claude/agent.svg)](https://agentmods.dev/commands/thelobbi/claude/agent)
Your own site
<a href="https://agentmods.dev/commands/thelobbi/claude/agent"><img src="https://agentmods.dev/badge/commands/thelobbi/claude/agent.svg" alt="Measured on agentmods" height="20"></a>
Per session 23 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,412 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00023 $0.03412
Opus 5 $0.00012 $0.01706
Sonnet 5 $0.00005 $0.00682
Haiku 4.5 $0.00002 $0.00341

Measured today against content hash a2ae5465baa3, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

lg:agent scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/plugins/langgraph-architect/commands/agent.md · 580 lines

How it starts

The opening of the file, as written. The whole thing — 580 lines — stays where its author put it; the contents beside it link to each section on GitHub.

lg:agent - Agent Management

Manage agents in LangGraph projects including creating, modifying, and organizing multi-agent systems.

Workflow Steps

Add Agent

  1. Validate Input

    • Check project structure exists
    • Verify agent name is unique
    • Validate agent type
  2. Generate Agent Code

    • Create agent class/function
    • Setup LLM configuration
    • Add tool bindings
    • Configure system prompt
  3. Update Graph

    • Add agent node to graph
    • Setup routing logic
    • Add conditional edges (if needed)
    • Update state schema (if needed)
  4. Generate Tests

    • Create agent test file
    • Add unit tests
    • Add integration tests
  5. Update Documentation

    • Add agent to README
    • Document agent capabilities
    • Update architecture diagram

Remove Agent

  1. Analyze Dependencies

    • Find all references to agent
    • Check for dependent edges
    • Identify impacted routes
  2. Remove Components

    • Remove agent node from graph
    • Remove agent file
    • Clean up edges
    • Update routing logic
  3. Update Tests

    • Remove agent tests
    • Update integration tests
  4. Update Documentation

    • Remove from README
    • Update architecture diagram

Modify Agent

  1. Load Current Configuration

    • Read agent definition
    • Parse current settings
  2. Apply Changes

    • Update specified parameters
    • Preserve unchanged settings
    • Validate new configuration
  3. Update Tests

    • Adjust test cases
    • Add new test coverage
  4. Update Documentation

    • Document changes
    • Update examples

Agent Types

ReAct Agent

Reasoning and Acting pattern with tool use.

from langchain_anthropic import ChatAnthropic
from langgraph.prebuilt import create_react_agent

llm = ChatAnthropic(model="claude-sonnet-5")
agent = create_react_agent(
    llm,
    tools=tools,
    state_modifier="You are a helpful assistant."
)

Tool-Calling Agent

Optimized for structured tool usage.

Read the full file on GitHub · 580 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. today First seen · 580 lines · 23 tokens per session scan A a2ae5465baa3

Subscribe to this mod's changes

lg:agent is a command published in the GitHub repository TheLobbi/claude (21 stars, last pushed yesterday), licensed MIT. It adds 23 tokens to every session and 3,412 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-05.