Repository navigation
[caveman] Optimize instruction verbosity — github-mcp-server-tools.md, index-search.md (2026-11-20) - #79590
Conversation
github-mcp-server-tools.md and index-search.md exceeded the prefix contract; rules and trust boundaries now precede reference tables and examples. Co-Authored-By: Claude <[email protected]>
There was a problem hiding this comment.
🟡 Changes recommended
An active documentation issue remains because the new marker does not explain how to load the matching toolset section, so prefix-limited queries can omit required tool contracts.
1 open issue
What changed in this PR
Optimizes two GitHub Agentic Workflow instruction files by compressing prose and moving mandatory MCP, indexing, cache, and security guidance into the visible prefix while preserving the underlying contracts.
Changes:
- Consolidated GitHub MCP tool restrictions, permissions, feature flags, and remote-mode requirements before the prefix marker.
- Compressed indexing, trust-boundary, cache, and restoration guidance in
index-search.md. - Moved extended reference tables and examples after the contract markers and verified both files with
check-instruction-prefixes.py.
| File | Description |
|---|---|
| .github/aw/index-search.md | Compresses indexing, trust-boundary, cache, and restoration guidance while keeping the required contract within the visible prefix. |
| .github/aw/github-mcp-server-tools.md | Front-loads MCP identity, permission, feature-flag, remote-mode, and tool-specific rules while retaining the complete tool reference tables. |
Review effort: Lite (adaptive)
| - **Permissions**: `copilot` requires `issues` and `pull-requests` write permissions, including its read-only Automation and task-status tools. `governance` org/enterprise operations need suitable token access; enabling the toolset does not grant it. `projects` requires a PAT — not supported by `GITHUB_TOKEN`. | ||
| - **Remote schema**: `copilot` Automation/task-status parameters are defined by the remote GitHub MCP service; their placement under `copilot` is not confirmed against public upstream toolset registration. | ||
|
|
||
| Toolsets: `context`, `code_quality`, `copilot`, `copilot_issue_intents`, `copilot_spaces`, `repos`, `git`, `github_support_docs_search`, `governance`, `issues`, `pull_requests`, `actions`, `code_security`, `dependabot`, `discussions`, `gists`, `labels`, `notifications`, `orgs`, `projects`, `secret_protection`, `security_advisories`, `stargazers`, `users`. |
There was a problem hiding this comment.
Added a pre-marker instruction to load the matching ### <toolset> section for tool and parameter contracts. Commit: e20b7fc9.
|
🍳 A little prep to help this PR along! Copilot assignment requested for the following outstanding work:
Keeping the changes focused; human review and CI get the final taste test. No merging or CI triggering. Structured data{
"completed_task": 0,
"head": "656a67c3d28101fc2509ed36a4f53d98aa8ea2f2",
"kind": "requested",
"schema_version": "1",
"state": "899113e64df84e80a139bec718971ca7622169a36ce72c24251a4f984dac7e07",
"work": [
"1432cb30f169dea298194426a670d73c5c45b9a2f08310a587fd81c538707e95"
],
"workflow": "pr-sous-chef"
}
|
Co-authored-by: copilot-swe-agent[bot] <[email protected]>

Caveman Optimization Run — 2026-11-20
Applies the caveman optimization principle to instruction files:
Two of five batch files failed
scripts/check-instruction-prefixes.py(contract past byte 7,500); both now pass.Files Optimized
.github/aw/github-mcp-server-tools.md.github/aw/index-search.mdView Details
github-mcp-server-tools.md — Scattered mandatory notes (
get_meidentity rule,search_repositoriesrepo:limitation and alternatives,list_code_scanning_alertsbounds, remote-only toolsets, feature-flagged issue tools, copilot/governance/projects permission gates, remote-schema caveat) are consolidated into a## Rulessection plus a toolset index before<!-- instruction-prefix-end -->. Duplicate in-table notes were removed; all tool tables are unchanged (the### copilottable parsed bypermissions_validator_json_test.gois intact).index-search.md — Tightened prose in publisher model, trust boundaries, and cache contract sections (~980 bytes) so every security rule ends by byte 7,209; both
aw/yamlexamples follow the marker unchanged.Batch files needing no change:
github-mcp-server-pagination.md(2737 B),github-mcp-server.md(5927 B),harbor.md(contract 7187/7500).What Was Preserved
All technical accuracy, field names, examples, schema definitions, and security rules were kept intact.
Validation
make check-instruction-prefixesandcheck-instruction-prefixes.pyon the batch: pass.permissions_validator_json_test.gowas replicated in Python and matches all 14 tools.Round-Robin Progress
Processed files 27–31 of 79 total files in the queue.
🤖 Generated with [Claude Code]((claude.com/redacted)