Understanding MCP, Agent, Skill, and Rule: How LLMs Differ from Traditional APIs

This article systematically explains the concepts of MCP, Agent, Skill, and Rule from an engineering viewpoint, highlighting their roles, differences from traditional API calls, and how they enable large language models to safely and autonomously interact with external tools.

Ops Development Stories
Ops Development Stories
Ops Development Stories
Understanding MCP, Agent, Skill, and Rule: How LLMs Differ from Traditional APIs

One‑sentence comparison table

API : remote function, no state, no inference, called by human‑written code.

MCP : tool‑integration protocol that lets LLMs understand and safely invoke external capabilities.

Skill : a single, stateless, idempotent ability (e.g., an API, script, DB query, automation).

Rule : guardrails that constrain an Agent’s actions.

Agent : an autonomous executor combining LLM reasoning, state, goals, and feedback.

Core distinction: API vs. MCP

Traditional API call flow :

业务代码 → SDK / HTTP → API → 返回结果

Characteristics:

Caller is human‑written code.

Parameters are strongly typed.

Invocation timing, order, and retry logic are manually defined.

API cares only about parameters, not semantics.

MCP (Model Context Protocol) is not a function but a protocol that enables LLMs to understand and safely call external tools. It solves three problems:

How does the LLM know what capabilities exist? → tools schema.

How does the LLM construct parameters? → JSON schema.

How to prevent over‑privilege? → sandbox / auth.

One‑line summary: API is for “people‑written programs”, MCP is for “models”.

Skill: the ability unit from the Agent’s perspective

Skill = a one‑time capability that an Agent can invoke. Typical forms include:

An API

A script

A database query

An automation operation

Example mappings: query_order_status → HTTP API restart_pod

kubectl
get_cpu_usage

→ PromQL create_ticket → ITSM API

Key features of a Skill:

Stateless

Idempotent or retryable

Does one thing only

Relationship to MCP:

Skill (ability definition)
   ↓
MCP (exposed to the model)
   ↓
LLM / Agent (consumer)
Skill is the “business abstraction”; MCP is the “technical wrapper”.

Rule: not logic, but a guardrail

Rule does not implement if/else, workflow, or DSL. Its sole purpose is to limit the Agent’s action space.

Typical Rule examples: Disallow access to production databases. Require manual confirmation for refunds. Cap the number of restarts per session. Prohibit changes outside working hours.

What Rule does NOT do:

Task decomposition

Determine call order

Perform reasoning

Handle exception recovery

All of those responsibilities belong to the Agent.

Agent: the only “living” component

Agent = LLM + state + goal + feedback loop

Minimal Agent loop:

while not goal_done:
    observe()
    think()
    plan()
    act()
    verify()

This closed‑loop capability cannot be achieved by traditional APIs, scripts, or static workflows.

Fundamental differences from traditional systems

Control flow : human‑written deterministic vs. model‑generated nondeterministic.

Execution path : fixed vs. dynamic.

Fault tolerance : code‑based vs. reasoning + retry.

Extensibility : add code vs. add Skill.

Handling unknowns : weak vs. strong.

Typical deployment scenarios

Scenario 1 – Operations automation (beyond scripts)

告警 → Agent
  ├─ 查询指标(skill)
  ├─ 分析趋势(LLM)
  ├─ 判断风险(rule)
  ├─ 执行动作(skill)
  └─ 回写结果

Why not just a script?

Root cause is uncertain.

Multiple possible remediation paths.

Combinatorial explosion of exception cases.

Scenario 2 – Business support / SRE Copilot

User submits a request.

Agent decomposes steps.

Skill executes each step.

Rule ensures safety.

MCP handles tool integration.

Scenario 3 – Complex approval / cross‑system operations

Query order.

Detect anomalies.

Check inventory.

Generate plan.

Decide whether to involve a human.

Traditional approach relies on massive if/else or workflow engines, whereas an Agent uses goal‑driven constrained execution.

Engineering conclusion

API = “function” Skill = “ability” MCP = “adaptation layer” Rule = “guardrail” Agent = “executor”

Simply pairing an LLM with a knowledge base yields advanced search; without an Agent providing a closed‑loop, there is no real business value.

LLMMCPAgentAI ArchitectureSkillRule
Ops Development Stories
Written by

Ops Development Stories

Maintained by a like‑minded team, covering both operations and development. Topics span Linux ops, DevOps toolchain, Kubernetes containerization, monitoring, log collection, network security, and Python or Go development. Team members: Qiao Ke, wanger, Dong Ge, Su Xin, Hua Zai, Zheng Ge, Teacher Xia.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.