Skip to content

docs(qvts): runnable QVTS demos, recordings test and handbook chapter - #1822

Merged
HuiJun merged 6 commits into
developfrom
docs/qvts-handbook
Nov 1, 2026
Merged

HuiJun merged 6 commits into
developfrom
docs/qvts-handbook

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

What and why

Runnable demos and a handbook chapter for OpenSysML's native QVTS (Query, View, Transformation for SysML v2) outcomes, used to drive the implementation against QVTS-Core and record where it differs. No query-engine behaviour changes: where a demo hits a deviation it records the current output with a note.

  • examples/qvts/ — self-authored lander.sysml, duplicates.sysml and queries.sysml (package QVTSDemo) plus a README with nine sections: value and empty selection, name path errors, missing-feature path errors with fan-out listing every failing element, an unvalued feature (absent, not missing), model errors, tolerate, views of results (tables, OrderBy, -json, a -render-document table), reflection (WhereType exact, metamodel properties, Differ, -metamodel-table), and the RDF export a SPARQL query would read (-convert ttl). Each section gives the exact command, its output and its exit status, from recordings under examples/qvts/expected/.
  • tests/qvts — builds cmd/sysml, runs every command (CLI, -json, REPL via stdin, -render-document, -convert ttl and -metamodel-table excerpts), compares against the recordings (-update re-records), and checks that each README and guide output block equals its recording, preceded by its command and followed by its exit status.
  • docs/guide/qvts.md — chapter 13: the three outcome kinds, running from the CLI, REPL and gRPC, the outcome record JSON, and current limits; added to the guide index and the MkDocs nav.
  • Regenerated with repo tooling for the three new examples/ files: both corpus round-trip ratchets (53 → 56 committed files, all stable), the pilot differential baseline (only the examples root moved: qvts/duplicates.sysml gains four agreed duplicate-name warnings) and the api-json differential baseline and its doc page (only the examples root moved).

Issues found

Run on a fresh make build of develop and compared with QVTS-Core (qvts-core.md) and the QVTS examples/expected and native/expected recordings.

# Reproducer Actual Expected (qvts-core.md) Class
1 over examples/qvts/lander.sysml: WhereType(source = Descendants(source = Named(qualifiedName = "Lander::lander")), type = "PartUsag"); Project(source = Named(qualifiedName = "Lander::lander::cabin"), properties = ("mas")) and ("isCompositee"); RelatedElements(source = Named(qualifiedName = "Lander::positivePayload"), relationshipKind = "satisfy", direction = "incoming") exit 2 with a message only (references unknown classification PartUsag, references unknown property mas, does not support relationship kind "satisfy"); no outcome record in text, -json checks[].outcome or the gRPC QueryOutcome detail. mas gets no nearest; isCompositee gets "did you mean isComposite?" in the message only path error at OfType/Feature/Related with frontier (nearest metaclass, features, kinds) — §5.5, §5.3, §5.4, §6.2 implementation bug (already noted "native has no record" in the QVTS agreement table)
2 RelatedElements(..., relationshipKind = "satisfaction", direction = "sideways") operation related-elements does not support "sideways", exit 2, no record path error at Related — §5.4 implementation bug (same family as 1)
3 Named(qualifiedName = ("Lander::lander", "Lander::landr", "Lander::lnder")) names no element Lander::landr …: the record lists only the first missing name (Lander::landr), not Lander::lnder fan-out lists every failing element and its frontier — §3.2 implementation bug
4 OrderBy(property = "mass", missing = "error", ...) over a part whose mass is unvalued cannot evaluate feature mass of Lander::lander::scienceBay, exit 2, no record missing = "error" turns an absent key into a model error (multiplicity) — §5.7 implementation bug (misleading diagnostic: the feature is absent, not unevaluable)
5 QVTSDemo::DoubleMassValue (two values for a [1] attribute) value, first value 3.0, exit 0 model error, multiplicity — §2, §6.4 known deviation, documented ("to do" in docs/internals/design/query-outcomes.md)
6 QVTSDemo::ToleratedMassProject, QVTSDemo::ToleratedMassFilter tolerated cells print (none) (-json []), identical to an unvalued cell; tolerated WhereFeature drops rows with no list of what was dropped absent cell marked tolerated / dropped rows listed under the view — §3.3 known deviation, documented
7 any successful -run-query … -json check has status: holds and a table, but no outcome: value record Outcome is value | pathError | modelError — §2 doc gap / spec gap (the QVTS native runner synthesizes the value record)
8 gRPC RunDocumentQuery failure server attaches QueryOutcome as a status detail, but no shipped client (Go, Java, Julia, MATLAB, Node, Python, Rust, Jupyter kernel) decodes it outside generated code the record is the result a client reads — §2, §6 missing surface (clients)
9 QVTSDemo::MissingMassProject frontier features: [] for Lander::lander::cabinEngine, though Project(properties = ("ownedFeature")) shows it owns two end features and inherits about a hundred (Links::BinaryLink::source, …) feature lookup is own-or-inherited (§5.3); what the frontier lists is not specified (§6.3 example shows "features: none") spec gap
10 Differ(..., key = "elementIdd") path error, frontier at left; nearest: elementId — at names a side, not an element Frontier.at is an element — §6.3 spec gap (minor)
11 QVTS examples/expected / native/agreement.txt against develop stale: fan-out now lists both failing connections (agreement says native ×1), WhereFeature over connections now fails closed (recording shows 2 rows), ambiguous names are model errors, name errors carry frontiers, every run prints ✓ package lines — doc gap in the QVTS repo (not changed here)

How it was verified

  • make build; go build ./...; go vet ./...; gofmt -l . (empty); git diff --check
  • go test -count=1 ./tests/qvts/...
  • go test -count=1 ./examples/... ./tests/corpus/... with the training, pilot and spec-example require variables set
  • make lint; python3 scripts/changelog.py check; make docs-counts (README, architecture, pilot-differential and testing-skill figures refreshed for the three new example files)
  • go test -count=1 ./tests/hygiene/...; python3 scripts/check-doc-links.py (0 broken); make docs (strict)
  • go -C tools test -count=1 ./referee/apijson/... ./oracle/baseline/... after regenerating both pilot differential baselines

Checklist

  • make test and make lint pass locally
  • Tests added or updated for the change
  • Documentation extended where it already covers the surface (see CONTRIBUTING.md)
  • Changelog entry added as changes/unreleased/<slug>.<section>.md, not as an edit to CHANGELOG.md
  • baselines regenerated and make docs-counts run if a gate count moved (compliance rows need nothing: the census is counted at docs build)
  • No internal work-item labels (waves, slices, F4, K5) in the body, docs, or changelog

Link to Devin session: https://nasa-jpl-demo.devinenterprise.com/sessions/48fb44615f314413b6e104beee48bb23
Open in Devin Desktop: https://nasa-jpl-demo.devinenterprise.com/desktop/session/48fb44615f314413b6e104beee48bb23?variant=devin
Requested by: @HuiJun

Co-Authored-By: jason.han <hanhuijun@gmail.com>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

Co-Authored-By: jason.han <hanhuijun@gmail.com>
@devin-ai-integration
devin-ai-integration Bot marked this pull request as ready for review November 1, 2026 09:23

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

devin-ai-integration Bot and others added 4 commits November 1, 2026 13:45
Co-Authored-By: jason.han <hanhuijun@gmail.com>

# Conflicts:
#	docs/project/api-json-differential-baseline.json
#	docs/project/api-json-differential.md
Co-Authored-By: jason.han <hanhuijun@gmail.com>
…orded baselines

Co-Authored-By: jason.han <hanhuijun@gmail.com>
@HuiJun
HuiJun merged commit b6fa509 into develop Nov 1, 2026
30 checks passed
@HuiJun
HuiJun deleted the docs/qvts-handbook branch November 1, 2026 17:24
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