[ 
https://issues.apache.org/jira/browse/CAMEL-26353?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Claus Ibsen updated CAMEL-26353:
--------------------------------
    Fix Version/s: 4.25.0
                       (was: 4.24.0)

> camel-diagram - zoom levels for route diagrams (image and text), as in the 
> diagram of the Camel CLI
> ---------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-26353
>                 URL: https://issues.apache.org/jira/browse/CAMEL-26353
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-diagram, camel-jbang
>            Reporter: Claus Ibsen
>            Priority: Minor
>             Fix For: 4.25.0
>
>
> The PNG of a route diagram (camel cmd route-diagram, the 
> camel_render_route_diagram MCP tool, the route-diagram developer console with 
> format=png) draws each step as a card with an icon, its kind and its detail 
> (CAMEL-26348). A card is taller than the old box, so a large route makes a 
> tall image, and it reaches the size limit of an image (16384 pixels) sooner, 
> where the command says to narrow the routes with --filter. The ASCII and 
> Unicode diagrams have one level only too: a box per step.
> The diagram of the Camel CLI in the terminal (camel tui, the Diagram tab) has 
> zoom levels for this, see "Zoom and Folding" in 
> docs/user-manual/modules/ROOT/pages/camel-jbang-tui-diagram.adoc, and 
> RouteDensity / RouteDiagramZoom in camel-jbang-plugin-tui:
> * detailed: a box per step, with up to three lines of text
> * compact: a box per step with one line of text, the steps closer together 
> (about twice as many steps fit)
> * bare: no boxes, each step a mark and its text on one row, the branches side 
> by side
> * overview: each step a cell in the colour of its EIP, to see the shape of a 
> large route
> * fit: the most detailed level in which the whole route fits
> Today these levels are only in the terminal UI. Make them available from the 
> command line as well, for the image and for the text diagrams: camel cmd 
> route-diagram --zoom=detailed|compact|bare|overview|fit, the same option for 
> the camel_render_route_diagram MCP tool, and a zoom query parameter for the 
> route-diagram developer console.
> The text diagrams matter for AI agents: an agent runs camel cmd route-diagram 
> (or calls the MCP tool) with --theme=unicode or ascii and shows the diagram 
> in its answer. A bare or compact text diagram of a large route fits a chat 
> answer where the detailed one of today does not, and the agent can pick the 
> level with fit, or zoom in on the part it talks about.
> * Image: detailed is the card of today, compact a card of one line (the kind 
> and its detail on one line, a smaller icon), bare a mark and its text, 
> overview cells. Fit picks the most detailed level whose image is not taller 
> than a given height (or the size limit).
> * ASCII and Unicode: the same levels as the terminal UI draws them (bare and 
> overview are text already there), with fit to a given number of rows or 
> columns.
> The levels are worked out in camel-jbang-plugin-tui today (RouteDensity, 
> RouteDiagramWidget). Moving what decides a level (the room per step, the 
> gaps, the text per step) into camel-diagram, beside RouteDiagramLayoutEngine, 
> lets the terminal UI, the CLI and the MCP tool share it, so the three show 
> the same diagram at the same level.
> What each level keeps of the body types on the arrows (CAMEL-26351) and the 
> problems of the steps (CAMEL-26352): at compact the labels and callouts as 
> they are; at bare and overview the warning marks, with the problems in the 
> numbered list below the route.
> _Filed by Claude Code on behalf of davsclaus_



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

Reply via email to