agentleFS
galandogalando/temper/skills/context-engineering/SKILL.md

context-engineering

Skill17 starsChanged 9 months agoMITView on GitHub

Hierarchical context loading for AI coding agents — load what you need, defer what you don't

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

Show its rules and text

We split this skill into the rules it gives an agent

14 rules. 0 are common, 12 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 77 edited versions we read keep these.

  • 12

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Start of every /temper stage (plan, design, build, review, check, fix)

    line 28
  2. Distinctive:

    Before making changes to unfamiliar code

    line 29
  3. Distinctive:

    When resuming a session from saved state

    line 30
  4. Distinctive:

    Before loading anything, answer:

    line 36
  5. Distinctive:

    Start with the file you need to change

    line 52
  6. Very specific:

    If plan.md exists: read the file list section only (not the full plan)

    line 55
  7. Distinctive:

    Read only files listed in tasks.md or plan.md

    line 59
  8. Distinctive:

    Read tests before implementation (TDD discipline)

    line 60
  9. Distinctive:

    Read error logs or test output if fixing a bug

    line 61
  10. Distinctive:

    Test output from the last run

    line 66
  11. Distinctive:

    After loading context, verify:

    line 89
  12. Distinctive:

    Can you name the files you'll modify?: If not, scope is unclear.

    line 91
  13. Distinctive:

    Can you describe the module boundary you're working within?: If not, load architecture.

    line 92
  14. Distinctive:

    Do you know what tests exist for the code you're changing?: If not, load test files.

    line 93

“Common” is measured: kept by at least 6 in 10 of the 77 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Context Engineering

Version: 1.0.0 Last Updated: 2026-05-12

Overview

Context engineering is the discipline of loading the right information, in the right order, at the right time. Context loaded and never used still costs tokens and attention; context skipped and needed shows up as guessed APIs and missed dependencies.

This skill fixes the loading order for a Temper stage. How much to load is your judgment, sized to the change:

Priority 1: rules      → pack rules, stack conventions, guardrails
Priority 2: arch       → module boundaries, dependency graph, entry points
Priority 3: source     → specific files relevant to the current task
Priority 4: errors     → recent failures, test output, runtime errors
Priority 5: conversation → prior decisions, user intent, stakeholder context

When to Use

  • Start of every /temper stage (plan, design, build, review, check, fix)
  • Before making changes to unfamiliar code
  • When resuming a session from saved state

Process

Step 1: Determine Task Scope

Before loading anything, answer:

  1. What am I doing? (fixing a bug, adding a feature, reviewing code)
  2. What files am I likely to touch? (from tasks.md or plan.md)
  3. What do I already know? (from current context or build-state.json)

Step 2: Load Rules (always first)

Load in this order:

  1. .claude/temper.config — enabled packs, stack, review settings
  2. .claude/packs/{enabled-pack}/rules.md — only enabled packs, only those scoped to the current phase
  3. .claude/packs/stacks/{detected-stack}.md — stack-specific patterns (if exists)
  4. .claude/CLAUDE.md — project conventions

Step 3: Load Architecture (if touching unfamiliar code)

  1. Start with the file you need to change
  2. Trace its imports and importers as far as the change's blast radius reaches; grep for imports rather than reading whole files to find them
  3. If plan.md exists: read the file list section only (not the full plan)

Step 4: Load Source (only what's needed)

  1. Read only files listed in tasks.md or plan.md
  2. Read tests before implementation (TDD discipline)
  3. Read error logs or test output if fixing a bug
  4. Skip files you're not modifying and don't need to understand for the change

Step 5: Load Errors (if fixing or debugging)

  1. Test output from the last run
  2. check-context.json or review-context.json (if resuming from feedback loop)
  3. Git diff (if reviewing changes)
  4. Runtime error logs or stack traces

Step 6: Defer Everything Else

Load these only when the task needs them:

  • Full file contents of files not being modified
  • Historical git log beyond the recent commits that touched the files in play
  • Documentation for frameworks you're not currently using
  • Design docs for features you're not currently building

Red Flags

Signs that the loaded context does not match the task:

  • Agent hallucinates APIs — not enough source context. Load the actual module.
  • Agent misses obvious dependencies — architecture context was skipped. Load the import graph.
  • Agent fixes symptoms, not root cause — error context is incomplete. Load the full stack trace.

Verification

After loading context, verify:

  1. Can you name the files you'll modify? If not, scope is unclear.
  2. Can you describe the module boundary you're working within? If not, load architecture.
  3. Do you know what tests exist for the code you're changing? If not, load test files.

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.