Skip to content

Post-termchart compositor layer (beautify + extend) — parked design #6

@ivanmkc

Description

@ivanmkc

Summary

A deterministic ASCII compositor that sits on top of termchart: it takes termchart's clean grid renders as components and arranges / annotates / decorates them into expressive, multi-column "explain-this-system" diagrams — while preserving termchart's exact alignment guarantees.

This reaches the kind of artifact people hand-draw to explain systems (parallel labeled columns, annotation banners, a box spanning columns, branch/merge flow between blocks, inline notes) — none of which Mermaid/termchart can express today.

📄 Full design (parked spec): docs/superpowers/specs/2026-06-02-post-termchart-compositor-layer-design.md

Status

🅿️ Parked — future feature. Design captured during brainstorming; not scheduled for implementation. No code until explicitly picked up.

Locked decisions

  • termchart stays the base renderer (component renderer); not rewritten, beautiful-mermaid not replaced.
  • Deterministic compositor — alignment guaranteed by construction (not LLM freehand, not generate-validate-repair).
  • Beautify and extend, equally.
  • One source of truth for width — reuses termchart's exact isFullwidth ranges + ANSI-aware maxLineWidth (ANSI = 0, box-drawing = 1, emoji/CJK = 2).
  • Layout: grid of cells + constrained connectors (vertical drop-arrows; branch/merge into a column-spanning cell). No arbitrary routing in v1.
  • Decoration palette (all routed through the width model): banner/figlet fonts · curated Unicode pseudo-fonts · box/line styles & weights · glyphs/icons/shading · color & text attributes.
  • Language: TypeScript core in the monorepo (working name packages/compose), importing termchart's width/render functions directly. Optional Python front-end later (LLM spec-authoring / harness) that shells out to the TS binary.
  • LLM role (optional, later): authors a declarative composition spec, never raw ASCII.

Open questions (decide when scheduled)

  • Spec format — leaning YAML + JSON Schema (vs JSON-only vs a custom DSL).
  • Connector anchor/merge semantics for unequal-width cells.
  • Pseudo-font whitelist (which Unicode style ranges are width-stable) + verification method.
  • Packaging — compose subcommand vs separate bin; shared flag parsing.

Out of scope (future extensions)

  • Free-canvas + arbitrary routed connectors (extending the A* router).
  • The cross-industry act+CI harness that runs this across many codebases (separate spec).
  • The LLM spec-authoring front-end itself (separate spec).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions