Skill, MCP, Workflow, Rules, and Memory: Drawing the Boundaries with Real Tasks
When AI coding tools join development work, rules, skills, tools, workflows, and memory often appear together in configuration. They all seem to tell the assistant how to work, but they serve different jobs. This article uses four real tasks to show what each concept owns, how they should be split, and how to resolve conflicts when they disagree.
When AI coding tools take part in development, configuration often contains rules, tools, processes, skills, and historical preferences at the same time. They all look like instructions about how the assistant should work, but they carry completely different responsibilities.
If the boundaries are unclear, several problems tend to appear:
- External tool access is written as a task process, so many tools exist but are not called correctly.
- One-off operating steps are written as long-term rules, and later tasks are disrupted by unrelated limits.
- User preferences are treated as mandatory standards, which leads to unreasonable automatic decisions.
- A complex methodology is packed into the prompt. The configuration grows longer but still cannot be executed reliably.
- The setup only says what can be done, not when to do it or when to stop and ask for confirmation.
A clearer split is:
| Concept | Core question | Typical responsibility |
|---|---|---|
| Rules | What must be followed | Permission boundaries, quality requirements, safety constraints |
| Skill | How a class of tasks should be completed | Page implementation, troubleshooting, test writing, report organization |
| MCP | How to access external tools and data | Browser, design files, knowledge bases, API services |
| Workflow | In what order a task should proceed | Analyze, execute, verify, confirm, deliver |
| Memory | Which information is worth keeping for later | User preferences, confirmed decisions, environment limits |
These five capabilities can work together, but they cannot replace one another.
1. Distinguish the five concepts in one sentence each
1. Rules: define boundaries that must not be crossed
Rules are constraints, not tutorials. They answer: whenever this rule applies, what must be followed no matter which task is running?
Examples:
- Do not change production configuration without explicit authorization.
- Do not commit code or release a version without user confirmation.
- When tests fail, report the failure honestly.
- When an API returns an error, do not disguise success by changing page copy.
- When sensitive data is involved, do not write the full content into logs.
- Before changing a shared module, check callers and regression tests.
Rules are usually stable and high priority. They may apply to multiple projects, or only to a directory, a repository, or a class of tasks.
A rule should not be written as a highly specific operating manual. “Open this file, then run this command” is a process, not a rule. A rule should describe required outcomes, prohibited behavior, and authorization boundaries.
2. Skill: define the method for a class of tasks
A skill is a reusable set of methods. It does not solve one specific task. It captures how to handle a type of task.
A “page issue investigation” skill might include:
- Confirm the reproduction conditions first.
- Separate layout, style, data, and interaction problems.
- Check the browser console and network requests.
- Narrow the failure to the smallest possible scope first.
- After the change, run local verification and a broader regression check.
- Report the cause, the change, and the remaining risk.
A “design-to-page” skill might include:
- Analyze page hierarchy and component boundaries.
- Distinguish content images, decorative images, and background images.
- Identify layout differences between desktop and mobile.
- Establish base variables for color, spacing, and type size.
- Finish structure before details.
- Verify visually with actual sizes or proportions.
A skill should be general enough to reuse. It is not a one-time answer for “build this page.” It is the working method to use the next time a similar page appears.
3. MCP: define how external capabilities are connected
MCP can be understood as a unified protocol for connecting tools and data. Its focus is not the task goal or the execution order. It lets the assistant access external resources in a structured way.
Resources that can be connected include:
- Design files or design annotations
- Browser pages and screenshots
- Project documents and knowledge bases
- API test environments
- Logs, monitoring, and defect systems
- The file system or a code repository
In page development, MCP might provide the ability to read design nodes, fetch image assets, and view page screenshots. It does not decide whether the header or the form should be built first, and it does not replace a rule such as “do not release without confirmation.”
MCP answers whether a tool exists and how to call it. It does not answer how the task should be completed.
4. Workflow: define what happens first and when to pause
A workflow is an ordered, conditional, staged task process. It fits work that needs multiple collaborative steps, stage confirmation, or risk control.
A typical flow can be written as:
Understand the goal↓Check whether the inputs are complete↓Define the implementation plan↓Execute low-risk steps↓Verify the result↓Ask for confirmation or continue to the next stage↓Organize the deliverables
For batch generation of marketing pages, the process can require:
- Read the requirements and assets first.
- Generate one representative sample.
- Show the sample and wait for confirmation.
- Generate the rest only after confirmation.
- Check links, styles, and content across all results.
- Output a change list at the end.
A workflow controls pace. For batch work, irreversible actions, or expensive tasks, it stops the assistant from expanding the scope before confirmation.
5. Memory: define which information is worth keeping
Memory is selected historical information, not a full chat log. It should store content that is still likely to be useful later and is relatively stable.
Suitable items include:
- The user prefers a certain code style.
- The project uses a default directory layout.
- A system must remain compatible with an older runtime.
- Confirmed field names and page terminology.
- The team’s mapping between test files and implementation files.
- An environment where high-risk operations are forbidden.
Unsuitable items include:
- A draft from a one-off task
- An unconfirmed guess
- A local detail that applies only to the current page
- Version information that may change soon
- Full credentials or personal data
Memory should also be updatable and revocable. If the user changes a preference, the old memory must be replaced. Two contradictory memories should not stay active at the same time.
2. Real task 1: implement a page from a design
This is the task where the five concepts are easiest to mix together.
Step 1: MCP obtains design information
After a design file is connected through an external tool, the assistant can read:
- Page structure
- Component hierarchy
- Size and spacing
- Color and type annotations
- Image assets
- States at different screen sizes
The point here is to obtain facts. The tool supplies input data. It does not choose the implementation strategy for the developer.
Step 2: Skill guides the implementation method
A page-implementation skill can require:
- Split the page into regions before identifying reusable components.
- Handle the main layout before shadows, corner radius, and motion.
- Prefer original image assets instead of leaving placeholders in place.
- Define breakpoints and overflow behavior for responsive layout.
- Compare visually with screenshots or a browser preview.
- Focus each change on one class of problem so regressions are easier to locate.
The benefit is that the assistant does not stop at “the page renders.” It implements the page in a way that can be maintained and verified.
Step 3: Workflow controls the order of execution
A reasonable workflow can be:
- Check that the design file, assets, and project entry point are complete.
- Output the page structure and component split.
- Implement the static skeleton.
- Complete the main styles.
- Connect real data.
- Verify desktop and mobile.
- Summarize differences and ask whether to continue refining.
If the design can be interpreted in more than one way, raise the question before large-scale coding. Do not guess and then change many files at once.
Step 4: Rules cover safety and quality
Common rules for a page task include:
- Do not change unrelated business modules.
- Do not delete existing tests.
- Do not hard-code bad data into a success state.
- Do not upgrade dependencies without authorization.
- Do not commit an unverified build result.
- If an asset cannot be obtained, say so explicitly.
Step 5: Memory stores lasting decisions
If the user confirms “this project defaults to mobile-first layout” or “images are always read from a specified asset directory,” those decisions can be saved as memory. The next time the same project is handled, they do not need to be asked again.
3. Real task 2: investigate an API error
API problems show the boundaries more clearly.
MCP provides observation points
Tools can help read request information, response content, service logs, and monitoring data. They answer where to look for evidence.
Skill provides the investigation method
An API investigation skill should emphasize the evidence chain:
- Reproduce the problem.
- Record the request path, method, parameters, and response status.
- Judge whether the problem is in the client, gateway, server, or data layer.
- Match the request identifier in the logs.
- Check recent changes.
- After the fix, re-verify the normal, error, and boundary cases.
Do not change the front-end message as soon as the page shows an error, and do not conclude from a single log line.
Workflow sets pause points
If the issue may require data repair or a production change, the process should include an explicit human confirmation point:
Collect evidence → locate possible causes → propose a fix↓Wait for authorization↓Apply the fix and verify it
Rules prevent incorrect handling
Rules should explicitly require:
- Do not delete original logs.
- Do not forge a successful response.
- Do not expose complete sensitive fields.
- Do not modify live data directly.
- If the root cause cannot be confirmed, mark it as a hypothesis pending verification.
Memory records environment characteristics
If a test environment has a stable limitation—for example, it can only be reached through a specific entry point, or a class of requests needs extra authentication—that long-lived information can be saved. A temporary failure should not be written into long-term memory.
4. Real task 3: generate content or files in batches
The main risk in batch work is loss of scope control, so workflow and rules matter especially.
Split the process into four stages.
Stage 1: confirm the inputs
Check the template, data source, output directory, naming rules, and overwrite scope. If the inputs are incomplete, ask first.
Stage 2: generate a sample
Generate one sample, or a small number of samples, to confirm field mapping, layout, tone, and file structure.
Stage 3: run the batch only after confirmation
Expand the scope only after confirmation. At that point, the skill owns the generation method, MCP reads data and writes files, and the workflow controls the batch boundary.
Stage 4: run quality checks
Check whether the count matches, whether files are missing, whether links work, and whether the format is consistent. Output a failure list.
In this task, “generate a sample first, then batch after confirmation” should not live only in a skill, because it is process control. It also should not be written only as a rule, because it applies to batch tasks rather than every task.
5. Real task 4: prepare a project delivery report
A delivery report looks simple, but it needs several capabilities together.
- MCP: read change records, test results, build logs, and file lists.
- Skill: organize the problem, solution, verification result, and risk in a consistent template.
- Workflow: collect facts first, draft second, then check consistency.
- Rules: do not overstate the test scope, and do not describe unverified work as complete.
- Memory: keep the report structure and terminology the team uses over time.
A reliable report should at least separate:
- What is finished
- What has been verified
- What has not been verified
- Known limitations
- Follow-up suggestions
- Items that need human confirmation
That is more useful in engineering work than simply saying “the feature is done.”
6. How to design the five configurations without mixing them
Use the following split.
Rules state “must” and “must not”
Use them for permissions, compliance, safety, and quality floors. Rules should be short, stable, and checkable.
Skills state methods and checklists
Use them for experience with a task type, steps, common traps, and acceptance criteria. A skill should be reusable across similar tasks.
Tool connections state capabilities and data sources
Describe only what a tool can access, what it returns, and its permission boundaries. Do not hard-code the business process into the tool connection.
Workflows state stages, order, and conditions
State when to continue, pause, roll back, or ask for confirmation, especially for high-risk and irreversible actions.
Memory states long-lived context
Save only stable, confirmed information that will actually be useful later, and provide a way to update or delete it.
7. How to handle conflicts
In practice, the five kinds of information can conflict. A workable priority is:
- Safety and permission rules
- The user’s current explicit instruction
- Project-level rules
- The task workflow
- A specialized skill
- Historical memory
- Default behavior
For example, if memory says “modify files automatically by default,” but the current rule requires confirmation before a change, follow the current rule. If a skill suggests batch processing, but the current workflow requires a sample first, run the sample stage first.
The essential point is that historical memory must not override a current explicit requirement, and a skill must not bypass a safety rule.
8. Final judgment: five different dimensions
Five questions can place a piece of configuration:
- Is this a boundary that must be followed over time? It is a rule.
- Is this a method for completing a class of tasks? It is a skill.
- Is this the ability to access an external system? It is MCP.
- Is this the order of a task and its pause conditions? It is a workflow.
- Is this historical information that may be reused later? It is memory.
A mature AI development environment is not better because it has more configuration. It is better when responsibilities are clearer. Rules hold the floor, skills reuse experience, MCP connects the assistant to real systems, workflows control the process, and memory carries context forward. When the five are combined correctly, an assistant can move beyond generating code and complete engineering tasks reliably inside explicit boundaries.
