Skip to content

feat(plugin): add mini bar chart visualization to session summary (#1041)#1055

Merged
JeremyDev87 merged 1 commit into
masterfrom
feat/bar-chart-summary-1041
Mar 28, 2026
Merged

feat(plugin): add mini bar chart visualization to session summary (#1041)#1055
JeremyDev87 merged 1 commit into
masterfrom
feat/bar-chart-summary-1041

Conversation

@JeremyDev87

Copy link
Copy Markdown
Owner

Summary

  • Add render_bar_chart() pure function with Unicode/ASCII/color support
  • Show top 3 tool usage distribution as bar charts in session summary
  • Color-coded by tool type (yellow=Edit, cyan=Bash, blue=Read)
  • ASCII fallback compatible (buddy.asciiMode)

Example output:

  Read         ████████████████████ 20
  Bash         ███████████████░░░░░ 15
  Edit         ██████████░░░░░░░░░░ 10

Test plan

  • 11 tests for render_bar_chart() (full/half/zero/max/ASCII/color)
  • 5 tests for integration in render_session_summary()
  • yarn workspace codingbuddy test — 5308 passed
  • yarn workspace codingbuddy-claude-plugin test — 71 passed

Closes #1041

)

- Add render_bar_chart() pure function with Unicode/ASCII/color support
- Show top 3 tool usage as bar charts in session summary
- Color-coded by tool type (yellow=Edit, cyan=Bash, blue=Read)
- ASCII fallback mode compatible (buddy.asciiMode)
- Add 16 new tests (bar chart + integration)
@JeremyDev87 JeremyDev87 added feat plugin packages/claude-code-plugin labels Mar 28, 2026
@vercel

vercel Bot commented Mar 28, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
codingbuddy-landing Ready Ready Preview, Comment Mar 28, 2026 2:49am

@JeremyDev87 JeremyDev87 merged commit 1e14237 into master Mar 28, 2026
50 of 51 checks passed
@JeremyDev87 JeremyDev87 deleted the feat/bar-chart-summary-1041 branch March 28, 2026 02:56
@JeremyDev87 JeremyDev87 self-assigned this Mar 28, 2026

@JeremyDev87 JeremyDev87 left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Conductor Code Review — #1041 Bar Chart Visualization

✅ Good

  • render_bar_chart() is a clean pure function with proper ASCII fallback
  • Edge cases handled well (zero value, zero max, value exceeds max)
  • Color mapping by tool type is a nice touch
  • Test coverage is solid (12 test cases for render_bar_chart, 5 for integration)
  • ASCII mode integration with existing buddy.asciiMode config — consistent

⚠️ Suggestions (address these)

  1. _render_bar_charts only shows tool distribution, not file changes or tests

    • Issue spec says: "Tool call count + distribution, Files changed, Test count"
    • Currently only tool distribution bars are rendered
    • Add a bar for files_changed and tests if available in stats
  2. render_session_summary signature — tool_names parameter

    • How is tool_names dict populated? The stop.py doesn't seem to pass it.
    • Verify the caller actually provides this data, otherwise bars will never appear.
  3. Magic number width=20

    • Issue spec says "bar width auto-adjusts to terminal width"
    • Currently hardcoded to 20. Consider reading os.get_terminal_size().columns with fallback.
  4. Label width {label:<12} is hardcoded

    • If tool name exceeds 12 chars (e.g., "NotebookEdit"), it won't align properly.
    • Consider computing max label width dynamically from the data.

📝 Minor

  • Top 3 tools limit is reasonable but could be configurable

Verdict

Address items 1-2 (spec compliance + caller integration). Items 3-4 are nice-to-have.

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

Labels

feat plugin packages/claude-code-plugin

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(plugin): add mini bar chart visualization to session summary

1 participant