Skip to content

feat(map-explain): respect user language + cut wall-of-text verbosity (#224)#225

Merged
azalio merged 1 commit into
mainfrom
issue-224-map-explain-language-verbosity
Jun 17, 2026
Merged

feat(map-explain): respect user language + cut wall-of-text verbosity (#224)#225
azalio merged 1 commit into
mainfrom
issue-224-map-explain-language-verbosity

Conversation

@azalio

@azalio azalio commented Jun 17, 2026

Copy link
Copy Markdown
Owner

Summary

Fixes the two /map-explain UX defects from #224:

  1. Output language was hardcoded to English — the skill had zero language rules and silently overrode the user's established language. Added an explicit rule: write prose in the user's language; keep code, identifiers, commands, error messages, and file:line refs in English.
  2. Output was a wall of text — the rigid always-emit-all-10-sections + explain-every-line structure produced ~4000 words on a 600-line diff. Replaced with a signal-first output spec.

Implements the LLM-council deliberation (council id in the issue) plus the owner-validated worked template from the issue comment. No re-consultation needed — the design was already settled and validated on a real 600-line Go controller diff.

What changed (both Claude + Codex surfaces)

  • Output-language rule near the top of the skill body.
  • Size tiers with word-budget ceilings and load-bearing-line caps (Tiny→Huge).
  • Front-loaded "Mental model in 60 seconds" ([MUST READ], ≤100 words).
  • Read-tier section tags ([MUST READ] / [READ IF MODIFYING] / [SKIM]).
  • Load-bearing lines replaces line-by-line: mechanical definition + skip list + worked filter; one table merging the old "what every line does" (§6) and "why each line" (§7); repeated shapes explained once; diffs → changed lines only.
  • Before→after first for PR/diff targets.
  • Adaptive sections (menu, not checklist) + single Omitted: footer line.
  • Natural-language follow-up offers (no fake CLI flags).
  • Deleted do not skip "obvious" lines; banned filler openers; tightened the Inferred: rule.

Invariants honored

  • Edited only the .jinja sources in templates_src/; ran make render-templates to propagate to all generated trees (.claude/, .agents/, both templates/ mirrors).
  • make check green: 2511 passed, 3 skipped, render parity ✅.
  • No prod deploy target in the Makefile (release is a manual build + PyPI prompt); this is a skill-content change, no version bump.

Closes #224

🤖 Generated with Claude Code

…#224)

`/map-explain` had two UX defects on real targets: output was hardcoded to
English (ignoring the user's established language in context) and produced an
enormous wall of text from the rigid always-emit-all-10-sections /
explain-every-line structure (~4000 words on a 600-line diff).

Rewrite both surfaces (Claude + Codex) from completeness-first to signal-first,
per the LLM-council deliberation and the owner-validated worked template in the
issue:

- Add an explicit output-language rule near the top: prose in the user's
  established language; code, identifiers, commands, and `file:line` refs stay
  English.
- Replace the 10-section checklist with an adaptive output spec: size tiers
  with word-budget ceilings + load-bearing-line caps, a front-loaded
  "Mental model in 60 seconds" block, read-tier section tags
  ([MUST READ]/[READ IF MODIFYING]/[SKIM]), a single load-bearing-lines table
  (merges old "what every line does" + "why each line"; repeated shapes
  explained once), before->after-first ordering for diffs, adaptive sections
  with an `Omitted:` footer, and natural-language follow-up offers.
- Delete `do not skip "obvious" lines`; define load-bearing mechanically with a
  skip list and a worked filter example; ban filler openers; tighten the
  `Inferred:` rule.

Edited the .jinja sources and re-rendered all generated trees. `make check`
green (2511 passed, render parity ✅).

Closes #224

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@azalio azalio merged commit 89872e2 into main Jun 17, 2026
6 checks passed
@azalio azalio deleted the issue-224-map-explain-language-verbosity branch June 17, 2026 21: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.

map-explain: respect user's language + cut wall-of-text verbosity (adaptive depth)

1 participant