---
title: An internal agent must follow about 40 specialised procedures (expense rules, incident runbooks, report formats)…
url: https://gurkanozkan.ai/learn/questions/recent-b-prompting-03/
markdown: https://gurkanozkan.ai/learn/questions/recent-b-prompting-03.md
kind: question
role: Applied LLM
stage: System design
difficulty: Medium
json: https://gurkanozkan.ai/api/learn/questions/recent-b-prompting-03.json
robots: noindex
---

# An internal agent must follow about 40 specialised procedures (expense rules, incident runbooks, report formats). Compare one large system prompt with a skills-style design that loads procedures on demand. How do you keep the context small, make the right procedure trigger, and manage the risks?

Applied LLM · System design · Medium

## Answer

*Model answer, written in a candidate's voice*

### In short

- Large static prompt pays full context every call and dilutes attention; skills keep only names and descriptions resident.
- Progressive disclosure: load full instructions and files only when relevant; run bundled scripts without loading their source into context.
- Descriptions are the trigger: write precise trigger and non-trigger wording and test with an eval set for misses and over-triggering.
- Long runs: compaction, notes outside the window, and sub-agents returning short summaries.
- Supply-chain risk: trusted skills only, review bundled scripts and network calls, permissions enforced outside the model.

### In full

I would not put all 40 procedures into one static system prompt: every call would pay the full token cost and the model would spend attention on rules that are irrelevant most of the time, which is the context-rot problem. I would keep only the skill names and short descriptions in the system prompt, then load the full procedure, templates, or reference files only when the task matches, and run bundled scripts through tools without ingesting their source code into context. The descriptions are the trigger, so I would write them precisely, including what the procedure is for and what it is not for, and test them with an eval set of real tasks to catch both missed triggers and over-triggering. For long runs I would rely on compaction, notes and artifacts outside the window, and sub-agents that return short summaries rather than dumping raw logs back into the main context. I would also treat skills as supply-chain inputs: allow only trusted skills, review bundled scripts and any network calls before enabling them, and enforce permissions outside the model so the agent cannot exceed what the environment allows.

*Checked against sources by an independent AI reviewer.*

## What a strong answer covers

- Explains context cost and context rot: a huge static prompt wastes tokens on every call and dilutes attention.
- Describes progressive disclosure: only names and descriptions in the system prompt, full instructions and files loaded when relevant, scripts run without loading their source.
- Treats descriptions as the trigger: writes them precisely and tests triggering and over-triggering with an eval set of tasks.
- Covers long runs: compaction, notes outside the window and sub-agents returning short summaries.
- Addresses supply-chain risk: only trusted skills, review of bundled scripts and network calls, permissions enforced outside the model.

## Common mistakes

- Assuming more instructions always help, or installing third-party procedures without auditing their code.

## Follow-ups

- How would you measure that the agent picked the wrong procedure, and fix it?

## Topic guides

- [Agents and tool use](https://gurkanozkan.ai/learn/topics/agents.md)
- [Prompting, few-shot and structured output](https://gurkanozkan.ai/learn/topics/prompting.md)
- [Security for LLM applications and agents](https://gurkanozkan.ai/learn/topics/security.md)
---

*Study material compiled with AI: drafted by a local model (Inkling 2 Mini) from public sources, then checked against those sources by independent AI reviewers (Claude) in November 2026. Not reviewed line by line by a person.*
