agentleFS
tranhieutttranhieutt/software_development_department/.claude/skills/context-engineering/SKILL.md

context-engineering

Skill72 starsChanged 7 months agoMITView on GitHub

82 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use using-agent-skills, constraint-driven-development and 9 more.

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.
  • LLl0k0laDSkill

    using-agent-skills

    Use when starting a session or when you need to discover which skill applies to the current task. This is the meta-skill that governs how all other skills are discovered and invoked.

    Also in 24 projects that use this

  • vinvcnSkill

    constraint-driven-development

    把一个项目的质量线确立为书面契约,并阻止 agent 悄悄降低它。通过访谈确定用户在意哪些维度,当用户心里没有数字时提供合理的默认阈值,把一切记录进 CONSTRAINTS.md,并盯住 diff 中质量线被削弱的迹象——新增的 @ts-ignore 或 eslint-disable 抑制注释、被跳过或删除的测试、被剥掉的断言、未实现的 stub、被调低的阈值。当没有任何质量线被写下来时使用;当用户说 "set up constraints" 或 "define our standards" 时;当用户希望把他们在意的维度——无障碍性、Web 性能、覆盖率——设置成被强制执行的约束时;当 agent 为了变绿不断静默检查或跳过测试时;当你需要一个覆盖率或性能阈值却不知道该选什么数字时;或者当 agent 写下的代码超出任何人会读的体量时。

    Also in 4 projects that use this

  • LLl0k0laDSkill

    shipping-and-launch

    Use when preparing to deploy to production. Use when you need a pre-launch checklist, when setting up monitoring, when planning a staged rollout, or when you need a rollback strategy.

    Also in 26 projects that use this

  • az9713Skill

    deprecation-and-migration

    Manages deprecation and migration. Use when removing old systems, APIs, or features. Use when migrating users from one implementation to another. Use when deciding whether to maintain or sunset existing code.

    Also in 22 projects that use this

  • +7 more from LLl0k0laD

The file

We found no rules to list in this file: it reads as prose or reference rather than instructions.

Files
SKILL.md

1. Overview

Context engineering bridges the gap between static training data and dynamic reality. Context Stuffing (jamming volume without intent) degrades reasoning, increases noise, and leads to hallucinations. Context Engineering treats AI attention as a scarce resource and allocates it deliberately through structure, bounded contexts, and intelligent memory retrieval (RAG / MCP Supermemory). Without this skill, the AI suffers from "Context Hoarding Disorder," leading to goal drift, high latency, and poor execution quality.

2. When to Use

Activate this skill immediately upon detecting the following signs:

  • Sign 1: User pastes a massive block of uncurated documents entirely into the context window (e.g., full PRDs, full codebases, thousands of lines of logs).
  • Sign 2: The AI's outputs start to become vague, hedged, or inconsistent despite having "all the context", or when the context window is clearly overflowing.
  • Sign 3: The user wants to start a multi-step complex workflow spanning many files and iterations.
  • Implicit Command: User types /context or /memory.

3. Strict Process

ULTIMATUM: You are an Agent. You DO NOT have the right to ignore, truncate, or alter the order of these steps, even if you think "the model has a 1 million token context limit anyway."

  1. [Step 1 - Intent & Boundary Falsification]: Identify exactly what decision the provided context supports. Apply the falsification test: "If I exclude [context element X], what specific failure will occur in [decision Y]?" If there is no concrete failure, the context must be rejected or removed from the active window.
  2. [Step 2 - Persist vs. Retrieve Classification]: Separate the information. Core constraints and glossary definitions remain in active context. Episodic, project-specific, or historical data must be offloaded and retrieved only when queried. Use mcp_supermemory_recall for historical lookups instead of keeping them in the prompt.
  3. [Step 3 - The R-P-R-I Cycle Execution]:
    • Research: Gather necessary information.
    • Plan: Synthesize findings into a high-density PLAN.md or SPEC.md.
    • Reset: Save crucial lessons to memory using mcp_supermemory_memory and explicitly ask the user to clear the context window (start a new chat) or summarize everything to drop the past context rot.
    • Implement: Execute purely based on the dense plan.
  4. [Step 4 - Storage & Consolidation]: Upon finishing a milestone, write the generalized knowledge or operational principles into mcp_supermemory_memory.

4. Anti-Rationalizations

These are lazy thoughts that Agents (like you) commonly fall prey to. If an idea in your head matches the Left Column, you MUST immediately obey the Right Column:

Agent's Lazy RationalizationRefutation & Mandatory Action
"I have a massive context window; I can just read all 50 files the user provided without complaining."Volume != Quality. Context is an attention economy. You MUST explicitly tell the user that "Context Stuffing" dilutes attention. Limit the working context to only the files strictly needed for the immediate decision.
"I'll just try again and rewrite the code if it hallucinates."Retries mask bad information architecture. Do not normalize retries. Stop and fix the context structure, break down the problem, or refine the retrieved memory BEFORE writing another line of code.
"I'll keep all the research logs and failed attempts in the chat history so I remember what I tried.""Context Rot" kills reasoning. Once a plan is synthesized, the previous dead ends become pure noise. You MUST instruct the user to flush the context or start fresh with a clean SPEC.md.

5. Verification Gates

You are NOT allowed to end your turn and respond "Context established" or proceed to implementation until the following checks pass:

  • You have successfully filtered out unnecessary broad context and kept only the decision-critical context.
  • You have explicitly called mcp_supermemory_memory to commit important established facts, or mcp_supermemory_recall to fetch past facts instead of asking the user to paste them.
  • You have synthesized the current sprawling context into a dense artifact (e.g. PLAN.md or SPEC.md) and proposed a Context Reset.

6. Red Flags

Immediately STOP and request User intervention if:

  • The user demands that you process more than 35k tokens of unstructured, mixed-domain text in a single prompt without allowing you to summarize and discard the noise.
  • You detect that the current context window is bloated with >3 failed attempts of the same task. You must halt and enforce a Reset.
  • Memory retrieval tools (like mcp_supermemory) fail repeatedly, meaning you are operating blind on historical context.

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.