Skip to content

feat: v0.6.0 — inline context injection, 13→5 tools#23

Merged
rushikeshmore merged 2 commits intomainfrom
v0.6.0-context-injection
Mar 13, 2026
Merged

feat: v0.6.0 — inline context injection, 13→5 tools#23
rushikeshmore merged 2 commits intomainfrom
v0.6.0-context-injection

Conversation

@rushikeshmore
Copy link
Owner

Summary

  • Inline context injection — replaces indirect 3-line CLAUDE.md pointer with rich ~60-80 line inline section (architecture, risk map, directives) between <!-- codecortex:start/end --> markers
  • Tool reduction — 13 MCP tools → 5 proven, irreplaceable ones (get_project_overview, get_dependency_graph, lookup_symbol, get_change_coupling, get_edit_briefing)
  • MCP Resources (3) — project/overview, project/hotspots, module/{name} (ResourceTemplate)
  • MCP Prompts (2) — start_session, before_editing
  • Coupling noise filter — filters go.mod↔go.sum, Cargo.toml↔Cargo.lock, golden file clusters
  • Static fallback — "Before Editing" section guides agents to .codecortex/ files when MCP not connected
  • New CLI commandcodecortex inject regenerates inline context
  • Static hotspots.md — pre-computed risk-ranked file table

Test plan

  • 279 tests passing (22 test files)
  • tsc clean, build clean
  • E2E tested on 3 repos: Hono (TS, 363 files), bubbletea (Go, 109 files), OpenClaw (multi, 6403 files)
  • Fresh agent usability testing (3 agents)
  • TypeScript expert code review — 0 any, 0 @ts-ignore, clean codebase
  • README.md update (pending)
  • Site update (pending)
  • npm publish (after merge)

🤖 Generated with Claude Code

rushikeshmore and others added 2 commits March 13, 2026 17:07
…prompts

Replace indirect 3-line CLAUDE.md pointer with rich inline context injection
(architecture, risk map, directives) between <!-- codecortex:start/end --> markers.
Reduces MCP tools from 13 to 5 proven, irreplaceable ones. Adds 3 MCP resources
and 2 MCP prompts. Includes coupling noise filter, static fallback paths, and
new `inject` CLI command.

Changes:
- NEW: src/core/context-injection.ts — generates ~60-80 line inline Markdown
- NEW: src/cli/commands/inject.ts — standalone CLI command
- NEW: src/mcp/resources.ts — 3 MCP resources (overview, hotspots, module/{name})
- NEW: src/mcp/prompts.ts — 2 MCP prompts (start_session, before_editing)
- NEW: generateHotspotsMarkdown() in temporal.ts — static hotspots.md generation
- NEW: coupling noise filter (go.mod↔go.sum, Cargo pairs, golden clusters)
- REMOVED: 8 MCP tools (5 read + 3 write) — agents use static files instead
- REMOVED: src/mcp/tools/write.ts (0 organic usage)
- 279 tests passing, tsc clean

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Update tool count (13→5), add MCP resources/prompts sections, inline
context injection docs, inject CLI command, coupling noise filter.
Rewrote "What makes it unique" and "How It Works" sections.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@rushikeshmore rushikeshmore merged commit e680c49 into main Mar 13, 2026
0 of 2 checks passed
@rushikeshmore rushikeshmore deleted the v0.6.0-context-injection branch March 13, 2026 11:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant