Skip to content

camel-jbang: Add tui_draw MCP tool for on-screen drawing overlay#23716

Merged
davsclaus merged 1 commit into
mainfrom
feature/tui-mcp-draw
Jun 2, 2026
Merged

camel-jbang: Add tui_draw MCP tool for on-screen drawing overlay#23716
davsclaus merged 1 commit into
mainfrom
feature/tui-mcp-draw

Conversation

@davsclaus
Copy link
Copy Markdown
Contributor

Summary

  • Add tui_draw and tui_draw_clear MCP tools that let AI agents draw characters at specific screen coordinates as an overlay on top of the TUI
  • AI can highlight areas, annotate the screen for humans, draw shapes, or create fun emoji art (e.g. camel emojis)
  • All cells sent in a single MCP call (no chatty networking) with support for auto-dismiss via duration parameter and append mode for composing drawings
  • Drawing is a pure overlay -- tui_draw_clear restores the screen to its normal state instantly

New files

  • DrawOverlay.java -- overlay that stores positioned cells and renders them on top of the TUI buffer, with auto-dismiss timer and color parsing

Modified files

  • CamelMonitor.java -- integrate DrawOverlay into the render pipeline (after content, before captions)
  • TuiMcpServer.java -- register tui_draw and tui_draw_clear tool definitions and handlers

Test plan

  • Build: cd dsl/camel-jbang/camel-jbang-plugin-tui && mvn install -DskipTests
  • Run camel tui monitor --mcp with an integration running
  • Call tui_draw with cells at known positions and verify they appear
  • Call tui_draw with emoji characters
  • Call tui_draw_clear and verify drawing disappears
  • Call tui_draw with duration and verify auto-dismiss
  • Call tui_draw with append=true to add to existing drawing
  • Verify tui_show_caption still renders on top of drawings

Claude Code on behalf of Claus Ibsen

🤖 Generated with Claude Code

Add tui_draw and tui_draw_clear MCP tools that let AI agents draw
characters at specific screen coordinates as an overlay on the TUI.
Useful for highlighting areas, annotating the screen, or drawing
emoji art. All cells sent in a single call to avoid chatty networking.
Supports auto-dismiss via duration parameter.

Co-Authored-By: Claude <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 2, 2026

🌟 Thank you for your contribution to the Apache Camel project! 🌟
🤖 CI automation will test this PR automatically.

🐫 Apache Camel Committers, please review the following items:

  • First-time contributors require MANUAL approval for the GitHub Actions to run
  • You can use the command /component-test (camel-)component-name1 (camel-)component-name2.. to request a test from the test bot although they are normally detected and executed by CI.
  • You can label PRs using skip-tests and test-dependents to fine-tune the checks executed by this PR.
  • Build and test logs are available in the summary page. Only Apache Camel committers have access to the summary.

⚠️ Be careful when sharing logs. Review their contents before sharing them publicly.

@github-actions github-actions Bot added the dsl label Jun 2, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 2, 2026

🧪 CI tested the following changed modules:

  • dsl/camel-jbang/camel-jbang-plugin-tui
All tested modules (2 modules)
  • Camel :: JBang :: Plugin :: TUI
  • Camel :: Launcher :: Container

⚙️ View full build and test results

@davsclaus davsclaus merged commit 50df432 into main Jun 2, 2026
6 checks passed
@davsclaus davsclaus deleted the feature/tui-mcp-draw branch June 2, 2026 21:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant