Skip to content

feat(plantuml): add plantuml plugin with maintenance layer#6

Merged
MrBogomips merged 11 commits intomainfrom
feature/plantuml-plugin
Apr 25, 2026
Merged

feat(plantuml): add plantuml plugin with maintenance layer#6
MrBogomips merged 11 commits intomainfrom
feature/plantuml-plugin

Conversation

@MrBogomips
Copy link
Copy Markdown
Owner

Summary

  • Adds the plantuml plugin to the marketplace, packaging the existing user-global PlantUML assets into a portable, distributable component.
  • Extends the existing plantuml-authoring and plantuml-convert skills with a maintenance layer: lint, validate, review, advisor, and migrate.
  • Introduces the skill ↔ agent dispatch pattern with three Haiku workers (linter, renderer, migrator) and one Sonnet vision worker (visual-checker, build-time only).

Components

  • 8 skills: plantuml-authoring, plantuml-convert, plantuml-bootstrap, plantuml-lint, plantuml-validate, plantuml-review, plantuml-advisor, plantuml-migrate
  • 4 agents: puml-linter, puml-renderer, puml-migrator, puml-visual-checker
  • 1 command: /plantuml-init (thin wrapper delegating to plantuml-bootstrap)
  • 6 static smoke tests at plantuml/tests/smoke/test-*.sh
  • minimal-project fixture for smoke testing

Process

11 commits, alternating feat (per phase) and fix (post-review polish):

  • Phase 1: scaffold + inherited skills
  • Phase 2: bootstrap skill + command wrapper + policy-schema doc
  • Phase 3: lint skill + linter agent + fixture (+ polish on smoke regex and policy detection)
  • Phase 4: validate skill + renderer + visual-checker agents (+ polish on visual-smoke flow, baseline path collision, renderer fail diff)
  • Phase 5: review + advisor skills (Sonnet, interactive) (+ polish on citation example and no-Task guard)
  • Phase 6: migrate skill + migrator agent (+ hardening: backup/recovery, idempotency, normalization, agent contract)
  • Phase 7: README finalized with concrete examples and known limitations

Implementation followed brainstorming → spec → plan → subagent-driven execution with two-stage review (spec compliance + code quality) per phase. Spec at .docs/specs/2026-04-25-plantuml-plugin-design.md, plan at .docs/plans/2026-04-25-plantuml-plugin.md (both gitignored, working-doc convention).

Test plan

  • bash tests/ci/run-structural-tests.sh — passes
  • All 6 static smoke tests pass (bootstrap, lint, validate, review, advisor, migrate)
  • marketplace.json and plantuml/.claude-plugin/plugin.json versions aligned at 1.0.0
  • Manual end-to-end on a fresh project (owner-private, post-merge): /plantuml-init → authoring → lint → validate (bless) → migrate → validate (check) → review/advisor
  • Manual visual smoke via puml-visual-checker on a sample PNG render
  • Tag plantuml-v1.0.0 after manual verification

Known limitations (v1.0.0)

  • plantuml-validate level=png-perceptual is unimplemented (returns unsupported)
  • plantuml-migrate has no concurrent-edit locking
  • puml-visual-checker is build-time only (not user-facing)
  • Cross-machine level=svg-hash requires pinned fonts; default level=checkonly is the safest option

…ema doc

- plantuml/skills/plantuml-bootstrap/SKILL.md: ports ~/.claude/commands/plantuml-init.md
  to plugin-scoped skill; resolves templates via ${CLAUDE_PLUGIN_ROOT}; dispatches
  mode=bootstrap (default) and mode=reverse
- plantuml/commands/plantuml-init.md: thin command wrapper that delegates to the
  plantuml-bootstrap skill with --reverse flag mapping
- plantuml/docs/policy-schema.md: copy of plantuml-authoring/project-config.md exposed
  as reference doc under docs/ (original left in place for skill progressive disclosure)
- plantuml/tests/smoke/test-bootstrap.sh: TDD red→green static smoke test validating
  SKILL.md frontmatter, ${CLAUDE_PLUGIN_ROOT} reference, and mode argument
Add Phase 4 components for render-aware validation:
- plantuml-validate skill (orchestrator): mode=check|bless, level=checkonly|svg-hash|png-perceptual, parallel Task dispatch to puml-renderer in batches of ≤8, optional puml-visual-checker on bless
- puml-renderer agent (Haiku): handles checkonly and svg-hash levels, returns JSON status per (file, target) cell
- puml-visual-checker agent (Sonnet): vision-capable smoke check for color, font, layout on rendered PNG baselines
- test-validate.sh: static smoke test (TDD red→green)
Add plantuml-review and plantuml-advisor skills with explicit model:sonnet,
no Task dispatch, structured output sections, and static smoke tests (TDD
red→green for both).
…detection

Implements Phase 6:
- plantuml-migrate skill (Sonnet orchestrator): reads Policy from CLAUDE.md,
  computes expected .plantuml/ content in-memory, detects manual edits via
  SHA-256 hash divergence (shasum -a 256, BSD-compatible), presents three
  options on divergence (promote-to-policy / overwrite / abort), dispatches
  puml-migrator per .puml file in parallel, and runs plantuml -checkonly.
- puml-migrator agent (Haiku worker): applies declarative edit plans
  (replace_include, rename_var, update_target_directive) and returns a JSON
  status with applied/skipped arrays.
- Static smoke test (TDD red→green).
@MrBogomips MrBogomips merged commit 1b8e7bf into main Apr 25, 2026
1 check passed
@MrBogomips MrBogomips deleted the feature/plantuml-plugin branch April 25, 2026 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant