Skip to content

docs: one README capture per viewer, light and dark - #9

Merged
superWorldSavior merged 1 commit into
mainfrom
docs/viewer-gallery
Oct 25, 2026
Merged

superWorldSavior merged 1 commit into
mainfrom
docs/viewer-gallery

Conversation

@superWorldSavior

Copy link
Copy Markdown
Owner

Summary

  • The README Viewers section is now a gallery like mcp-erpnext's: one capture per viewer, each in light and dark, with a caption. The viewers are model explorer, query results, value change, requirements, requirements trace and validation, plus the state machine and interconnection diagram views. The action flow stays the hero image.
  • The documentation harness (docs/fixtures/viewer-preview.html) has a second mode. It delivers a recorded tool result as a host does (ui/notifications/tool-result, serverTools advertised), and answers the viewer's own tools/call requests from recordings, only for the element asked for.
    • A recorded session never calls the provider, so captures used to show "Name not available in this result" and "Browsing is unavailable…".
    • The harness is ready only once those calls are answered. An unreadable recording or an unknown ?view= fails the capture instead of writing a wrong image.
  • deno task docs:viewer-screenshot crops each image to the viewer plus a 24 px margin, and accepts view names, e.g. deno task docs:viewer-screenshot validation. The four diagram PNGs are byte-identical to before.
  • New tool results recorded on the local audit project (mcp-syson 0.9.1) are in tests/fixtures/live-audit, documented in its README and covered by contract tests:
    • syson_element_children on the Batmobile root;
    • syson_query_eval with aql:self.eAllContents(sysml::PartUsage);
    • syson_value_set on Wheel::width, 26 → 28, set back afterwards;
    • syson_element_get on that same attribute;
    • syson_constraint_validate on a new DroneBudget part definition: 3 pass, 1 fail.

Test plan

  • deno task fmt, lint, check, test (278 passed)
  • deno task docs:viewer-screenshot: 18 images written, each one inspected
  • Capture fails with CAPTURE_TOOL_FAILED viewer error:syson_element_get recording: Fixture HTTP 404 when that recording is missing
  • Independent review (Sonnet): findings addressed (silent harness failures, view-name drift, README provenance wording, alt texts, test titles)

Seen while recording, not fixed here

  • The constraint parser rejects a decimal literal inside an expression: thrust / (totalMass * 9.81) >= 2 reports Cannot parse literal value from 'LiteralRational'.
  • syson_query_requirements_trace cannot resolve satisfying features, because SysON returns satisfyingFeature as void even for satisfy massBudget by budget;. Every satisfaction link shows as unresolved.

🤖 Generated with Claude Code

The README viewers section becomes a gallery: model explorer, query
results, value change, requirements, requirements trace, validation and
two diagram views, each with a caption.

The documentation harness can now deliver a recorded tool result as a
host does and answer the viewer's own calls from recordings (only for
the element asked for), so captures show what a host shows instead of
the recorded-session notices. It waits for those answers before it is
ready, and fails the capture when a recording cannot be read or a view
name is unknown.

The capture script crops each image to the viewer and accepts view
names to capture only those. New tool results recorded on the local
audit project live in tests/fixtures/live-audit, with contract tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@superWorldSavior
superWorldSavior merged commit 0897d24 into main Oct 25, 2026
2 checks passed
@superWorldSavior superWorldSavior mentioned this pull request Oct 25, 2026
2 tasks done
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