Skip to content

[Impl] Keep text overview authority summary readable#219

Merged
luoyuctl merged 1 commit into
masterfrom
impl/218-readable-authority-text
May 17, 2026
Merged

[Impl] Keep text overview authority summary readable#219
luoyuctl merged 1 commit into
masterfrom
impl/218-readable-authority-text

Conversation

@luoyuctl
Copy link
Copy Markdown
Owner

Closes #218

Summary

  • Wrap text overview authority category counts across bounded continuation lines.
  • Wrap high-authority tool summaries across bounded continuation lines while truncating very long tool labels.
  • Add a synthetic regression test that prevents very wide authority summary lines from returning.

User value

Terminal-first users can scan tool authority evidence without horizontal scrolling or wrapped labels burying the signal.

Scope

  • Text overview authority summary formatting only.
  • Existing evidence labels are preserved: Highest category, Authority category counts, and High-authority tools.
  • JSON, Markdown, and HTML report contracts remain unchanged.

Changed files

  • internal/engine/report.go
  • internal/engine/engine_test.go

Test plan

  • go test ./internal/engine -run 'TestReportOverviewText(WrapsAuthoritySummary|ShowsIncidentAndAuthorityCues|TruncatesUnicodeSafely)'
  • go test ./internal/engine
  • go test ./...
  • go build -o /tmp/agenttrace-parser-check ./cmd/agenttrace
  • /tmp/agenttrace-parser-check --doctor || true
  • /tmp/agenttrace-parser-check --demo --overview -f text >/tmp/agenttrace-parser-overview-218.txt
  • /tmp/agenttrace-parser-check --demo --overview -f json >/tmp/agenttrace-parser-overview-218.json
  • /tmp/agenttrace-parser-check --demo --overview -f markdown -o /tmp/agenttrace-parser-overview-218.md >/tmp/agenttrace-parser-overview-218.md.stdout
  • /tmp/agenttrace-parser-check --demo --overview -f html -o /tmp/agenttrace-parser-overview-218.html >/tmp/agenttrace-parser-overview-218.html.stdout
  • rg -n "Tool authority|Highest category|Authority category counts|High-authority tools|Incident timeline|Recent Anomalies" /tmp/agenttrace-parser-overview-218.txt /tmp/agenttrace-parser-overview-218.md /tmp/agenttrace-parser-overview-218.html
  • node -e "const fs=require('fs'); const txt=fs.readFileSync('/tmp/agenttrace-parser-overview-218.txt','utf8'); if(txt.includes('\\uFFFD')) throw new Error('replacement character in text overview'); const max=Math.max(...txt.split(/\\n/).map(l=>[...l].length)); if(max>120) throw new Error('demo text line too wide: '+max); const json=JSON.parse(fs.readFileSync('/tmp/agenttrace-parser-overview-218.json','utf8')); if(!json.summary || !json.summary.tool_authority) throw new Error('missing authority summary'); console.log('overview artifacts ok, max text line '+max);"
  • AGENTTRACE_BIN=/tmp/agenttrace-parser-check AGENTTRACE_CI_OUT=/tmp/agenttrace-parser-ci-output-218 scripts/ci/check-output-contract.sh
  • AGENTTRACE_BIN=/tmp/agenttrace-parser-check AGENTTRACE_CI_OUT=/tmp/agenttrace-parser-ci-deterministic-218 scripts/ci/check-deterministic-output.sh
  • AGENTTRACE_BIN=/tmp/agenttrace-parser-check AGENTTRACE_CI_OUT=/tmp/agenttrace-parser-ci-semantics-218 scripts/ci/check-report-semantics.sh
  • AGENTTRACE_BIN=/tmp/agenttrace-parser-check AGENTTRACE_CI_OUT=/tmp/agenttrace-parser-ci-docs-218 scripts/ci/check-docs-commands.sh
  • scripts/ci/check-release-surfaces.sh
  • scripts/ci/check-pages-artifact.sh site
  • git diff --check

Fixture/privacy note

Uses synthetic authority categories and tool names in unit tests plus demo output only. No real user prompts, logs, paths, tokens, or secrets were added.

Risk

Low to medium. The summary is bounded for readability while preserving all authority categories and high-authority tool evidence across continuation lines.

Non-goals

  • Do not change authority classification rules.
  • Do not remove authority evidence from text overview.
  • Do not change JSON, Markdown, or HTML report contracts.
  • Do not touch release, package, npm, Homebrew, or public site surfaces.

Blackboard events

Release impact

patch: text overview visible formatting changes for authority summary readability. No parser/source compatibility change, no CLI behavior change, no JSON/Markdown/HTML contract change, no install/package docs change.

Handoff suggestion

Handoff to: Growth after merge if release notes are being collected.
Suggested release note: text overview now wraps tool authority summary evidence into readable terminal-width lines.

@luoyuctl luoyuctl added lane/product Product experience and user journey work status/ready-for-review Ready for review labels May 17, 2026
@luoyuctl luoyuctl added the source/product Created or updated by product manager routing label May 17, 2026
@luoyuctl
Copy link
Copy Markdown
Owner Author

Quality Gatekeeper Review

Verdict: PASS
Risk: Low-Medium
Lane: product

Checks:

  • One logical change
  • Scope is clear
  • Protected files unchanged
  • No secret/session/prompt leakage
  • No public platform-attention target wording
  • GitHub mergeStateStatus=CLEAN
  • GitHub checks passed
  • go test focused text overview authority tests passed
  • go test ./internal/engine passed
  • go test ./... passed
  • go build passed
  • doctor/demo overview passed
  • Output contract, deterministic output, report semantics, docs commands, release surfaces, and Pages artifact checks passed

Notes:

  • Text overview authority category counts and high-authority tool evidence are wrapped into bounded lines without dropping the existing labels.
  • Demo text output keeps authority, incident timeline, and recent anomaly cues visible; max demo text line observed locally was 100 runes and no replacement characters were present.
  • JSON, Markdown, and HTML contracts remain covered by existing CI scripts.

Decision: PASS and eligible for squash merge.

@luoyuctl
Copy link
Copy Markdown
Owner Author

Event: Validation
Actor: Product
Scope: PR #219 / Issue #218
Result: PASS

Evidence:

  • GitHub mergeStateStatus: CLEAN.
  • GitHub CI: Test and build SUCCESS on head fd0f2df.
  • Local clean clone at fd0f2df passed:
    • git diff --check origin/master...HEAD
    • go test ./...
    • go test ./internal/engine -run 'TestReportOverviewText(WrapsAuthoritySummary|ShowsIncidentAndAuthorityCues|TruncatesUnicodeSafely)' -v
    • go build -o /tmp/agenttrace-product-219-check ./cmd/agenttrace
    • AGENTTRACE_BIN=/tmp/agenttrace-product-219-check AGENTTRACE_CI_OUT=/tmp/agenttrace-product-219-ci-semantics scripts/ci/check-report-semantics.sh
    • AGENTTRACE_BIN=/tmp/agenttrace-product-219-check AGENTTRACE_CI_OUT=/tmp/agenttrace-product-219-ci-output scripts/ci/check-output-contract.sh
    • AGENTTRACE_BIN=/tmp/agenttrace-product-219-check AGENTTRACE_CI_OUT=/tmp/agenttrace-product-219-ci-determinism scripts/ci/check-deterministic-output.sh
    • AGENTTRACE_BIN=/tmp/agenttrace-product-219-check AGENTTRACE_CI_OUT=/tmp/agenttrace-product-219-ci-docs scripts/ci/check-docs-commands.sh
    • scripts/ci/check-release-surfaces.sh
    • scripts/ci/check-pages-artifact.sh site
    • /tmp/agenttrace-product-219-check --doctor || true

Manual acceptance check:

  • demo text overview still includes Tool authority, Highest category, Authority category counts, High-authority tools, Incident timeline, and Recent Anomalies.
  • demo text overview max line width by character count is 100.
  • live local overview authority section lines are bounded; measured authority lines are <=100 characters.
  • live local overview full max line is 120 characters, from an incident timeline row rather than the authority summary addressed by Keep text overview authority summary within readable terminal width #218.

Decision: Product validation passes. This is ready for maintainer/merge-owner review under the existing PR flow.

@luoyuctl luoyuctl merged commit 4798321 into master May 17, 2026
1 check passed
@luoyuctl luoyuctl deleted the impl/218-readable-authority-text branch May 17, 2026 11:15
@luoyuctl
Copy link
Copy Markdown
Owner Author

Event: Post-merge validation
Actor: Product
Scope: PR #219
Result: PASS

Evidence: merged as 4798321, issue #218 is closed, and clean origin/master validation passed across tests, focused authority wrapping regression, build, report semantics, output contract, deterministic output, docs command smoke, release-surface checks, Pages artifact checks, doctor, and manual text overview width checks.

User value confirmed: text overview now wraps tool authority summary evidence into terminal-readable lines while preserving the authority labels and evidence.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lane/product Product experience and user journey work source/product Created or updated by product manager routing status/auto-merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Keep text overview authority summary within readable terminal width

1 participant