Repository navigation
feat(export,metamodel): a library type the model states completes the inherited family in the element form, and Type::endFeature is completed - #2309
Merged
Conversation
… inherited family in the element form, and Type::endFeature is completed Co-Authored-By: jason.han <hanhuijun@gmail.com>
…n from the inherited family Co-Authored-By: jason.han <hanhuijun@gmail.com>
…defined along one general is not inherited along another Co-Authored-By: jason.han <hanhuijun@gmail.com>
… VariantMembership, not a feature Co-Authored-By: jason.han <hanhuijun@gmail.com>
…rary-base, endFeature and membership-kind changes Co-Authored-By: jason.han <hanhuijun@gmail.com>
…rited-family-complete
…ential ranks Co-Authored-By: jason.han <hanhuijun@gmail.com>
Contributor
Author
|
I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".
|
…subtype Co-Authored-By: jason.han <hanhuijun@gmail.com>
…nal type Co-Authored-By: jason.han <hanhuijun@gmail.com>
…n tests in the derived-properties row Co-Authored-By: jason.han <hanhuijun@gmail.com>
…e subtype's endFeature Co-Authored-By: jason.han <hanhuijun@gmail.com>
Co-Authored-By: jason.han <hanhuijun@gmail.com>
…rited-family-complete Co-Authored-By: jason.han <hanhuijun@gmail.com>
… follow the completed library-typed family Co-Authored-By: jason.han <hanhuijun@gmail.com>
Contributor
Author
There was a problem hiding this comment.
Note
Newer findings are available below. Devin Review posted a newer report on this PR, in addition to the findings presented here.
Devin Review found 4 findings. Devin automatically fixed all 4 findings.
Fixed by Devin (4)
- Private ends inherited by subtypes — Reproduced (B specializes A with a private end listed A::hidden). The end walk now inherits only a supertype's non-private ends; the private end still holds its position for end redefinition.
- Missing ends on conjugated types — Reproduced at evaluator level with a Conjugation in the structure. The end walk now reads Type::supertypes() (original type of a conjugated type) as the membership walk does.
- Private aliases suppress public inherited ends — Reproduced with
end feature shown; private alias shownToo for shown;. Only the owning FeatureMembership's visibility now decides whether a subtype inherits the end. - Helper comment exceeds the repository limit — Comment shortened to two lines.
…rited-family-complete Co-Authored-By: jason.han <hanhuijun@gmail.com>
…ct redefines, an objective inherits from the one it redefines, and an accept's payload is an in parameter KerML 8.3.4.6.4 parameterDirection, SysML 7.17.2 and 8.3.21.9 checkRequirementUsageObjectiveRedefinition; SysML.xtext PayloadParameterMember. An end's inline cross feature is owned through an OwningMembership and is not an end (KerML.xtext OwnedCrossFeatureMember). Re-records the api-json differential, the structure differential and the export goldens that state the accept payload. Co-Authored-By: jason.han <hanhuijun@gmail.com>
… chain inherits from its target, and flow features and conjugated ports state their directions A type inheriting a parameter that redefines a library feature completes its inherited family; an element a library file declares keeps the owning membership the graph declares. A feature chain inherits from the last feature it names (KerML 8.3.3.3.4), a FlowFeature has the direction of the feature it redefines (KerML.xtext FlowFeature), a feature a conjugated port declares keeps its stated direction, then done in a use case is UseCases::UseCase::done, and a constraint referenced by name alone or a bare variant is a reference subsetting in the symbol structure. Re-records the api-json differential fragments, the structure differential and the export goldens that move. Co-Authored-By: jason.han <hanhuijun@gmail.com>
6 tasks done
…rited-family-complete Co-Authored-By: jason.han <hanhuijun@gmail.com> # Conflicts: # docs/project/api-json-differential/examples/analysis-demo/lander.sysml.json # docs/project/api-json-differential/examples/analysis-results-demo/lander-results.sysml.json # docs/project/api-json-differential/examples/data-import-demo/rover.sysml.json # docs/project/api-json-differential/examples/disposal-robot-demo/robot.sysml.json # docs/project/api-json-differential/examples/disposal-team-demo/team.sysml.json # docs/project/api-json-differential/examples/expressions-demo.sysml.json # docs/project/api-json-differential/examples/external-tool-demo/thermal.sysml.json # docs/project/api-json-differential/examples/general-views-demo/vehicle.sysml.json # docs/project/api-json-differential/examples/parser_features_demo_advanced_bodies.kerml.json # docs/project/api-json-differential/examples/parser_features_demo_declarations.kerml.json # docs/project/api-json-differential/examples/parser_features_demo_edge_cases.kerml.json # docs/project/api-json-differential/examples/phase-c-behavioral-bodies.sysml.json # docs/project/api-json-differential/examples/qvts/lander.sysml.json # docs/project/api-json-differential/examples/qvts/queries.sysml.json # docs/project/api-json-differential/examples/relay-probe-demo/mission.sysml.json # docs/project/api-json-differential/examples/runtime-showcase/delta-v-budget.sysml.json # docs/project/api-json-differential/examples/runtime-showcase/mass-rollup.sysml.json # docs/project/api-json-differential/examples/runtime-showcase/reliability.sysml.json # docs/project/api-json-differential/examples/self-check-rules/rules.sysml.json # docs/project/api-json-differential/examples/self-model/behavior.sysml.json # docs/project/api-json-differential/examples/self-model/execution.sysml.json # docs/project/api-json-differential/examples/self-model/identity.sysml.json # docs/project/api-json-differential/examples/self-model/pipeline.sysml.json # docs/project/api-json-differential/examples/self-model/quality.sysml.json # docs/project/api-json-differential/examples/self-model/surfaces.sysml.json # docs/project/api-json-differential/examples/semantic-layer/demo.sysml.json # docs/project/api-json-differential/examples/solver-demo.sysml.json # docs/project/api-json-differential/examples/verdicts-demo/rover.sysml.json # docs/project/api-json-differential/examples/views-demo.sysml.json # docs/project/api-json-differential/index.json # docs/project/api-json-differential/kerml-examples/Behavior Examples/TakePicture.kerml.json # docs/project/api-json-differential/kerml-examples/Individuals Examples/JohnIndividualExample.kerml.json # docs/project/api-json-differential/kerml-examples/KerML Spec Annex A Examples/A-2-ModelingInstances.kerml.json # docs/project/api-json-differential/kerml-examples/KerML Spec Annex A Examples/A-3-2-WithoutConnectors.kerml.json # docs/project/api-json-differential/kerml-examples/KerML Spec Annex A Examples/A-3-3-OneToOneConnectors.kerml.json # docs/project/api-json-differential/kerml-examples/KerML Spec Annex A Examples/A-3-4-OneToUnrestrictedConnectors.kerml.json # docs/project/api-json-differential/kerml-examples/KerML Spec Annex A Examples/A-3-5-TimingForStructures.kerml.json # docs/project/api-json-differential/kerml-examples/KerML Spec Annex A Examples/A-3-6-Sequences.kerml.json # docs/project/api-json-differential/kerml-examples/KerML Spec Annex A Examples/A-3-7-DecisionsAndMerges.kerml.json # docs/project/api-json-differential/kerml-examples/KerML Spec Annex A Examples/A-3-8-ChangingFeatureValues.kerml.json # docs/project/api-json-differential/kerml-examples/Mass Roll-up Example/MassRollup_1.kerml.json # docs/project/api-json-differential/kerml-examples/Mass Roll-up Example/MassRollup_2.kerml.json # docs/project/api-json-differential/kerml-examples/Mass Roll-up Example/Vehicles_1.kerml.json # docs/project/api-json-differential/kerml-examples/Mass Roll-up Example/Vehicles_2.kerml.json # docs/project/api-json-differential/kerml-examples/Mass Roll-up Example/Vehicles_3.kerml.json # docs/project/api-json-differential/kerml-examples/Named Collection Members Example/VehicleTanks.kerml.json # docs/project/api-json-differential/kerml-examples/Simple Tests/Behaviors.kerml.json # docs/project/api-json-differential/kerml-examples/Simple Tests/Expressions.kerml.json # docs/project/api-json-differential/kerml-examples/Simple Tests/FeatureChains.kerml.json # docs/project/api-json-differential/kerml-examples/Simple Tests/Features.kerml.json # docs/project/api-json-differential/kerml-examples/Variable Feature Examples/Enhancements/ExtendedOccurrences.kerml.json # docs/project/api-json-differential/manual-examples/cookbook.sysml.json # docs/project/api-json-differential/manual-examples/trace-2-hierarchy.sysml.json # docs/project/api-json-differential/manual-examples/trace-3-derivation.sysml.json # docs/project/api-json-differential/manual-examples/trace-4-program.sysml.json # docs/project/api-json-differential/manual-examples/traceability.sysml.json # docs/project/api-json-differential/pilot-examples/Analysis Examples/Dynamics.sysml.json # docs/project/api-json-differential/pilot-examples/Analysis Examples/Vehicle Analysis Demo.sysml.json # docs/project/api-json-differential/pilot-examples/Arrowhead Framework Example/AHFNorwayTopics.sysml.json # docs/project/api-json-differential/pilot-examples/Arrowhead Framework Example/AHFSequences.sysml.json # docs/project/api-json-differential/pilot-examples/Flashlight Example/Flashlight Example.sysml.json # docs/project/api-json-differential/pilot-examples/Geometry Examples/CarWithShapeAndCSG.sysml.json # docs/project/api-json-differential/pilot-examples/Geometry Examples/SimpleQuadcopter.sysml.json # docs/project/api-json-differential/pilot-examples/Geometry Examples/VehicleGeometryAndCoordinateFrames.sysml.json # docs/project/api-json-differential/pilot-examples/Individuals Examples/AnalysisIndividualExample.sysml.json # docs/project/api-json-differential/pilot-examples/Individuals Examples/JohnIndividualExample.sysml.json # docs/project/api-json-differential/pilot-examples/Interaction Sequencing Examples/ServerSequenceModelOutside.sysml.json # docs/project/api-json-differential/pilot-examples/Interaction Sequencing Examples/ServerSequenceOutsideRealization-3.sysml.json # docs/project/api-json-differential/pilot-examples/Interaction Sequencing Examples/ServerSequenceRealization-3.sysml.json # docs/project/api-json-differential/pilot-examples/Mass Roll-up Example/MassConstraintExample.sysml.json # docs/project/api-json-differential/pilot-examples/Mass Roll-up Example/MassRollup.sysml.json # docs/project/api-json-differential/pilot-examples/Mass Roll-up Example/Vehicles.sysml.json # docs/project/api-json-differential/pilot-examples/Requirements Examples/VehicleRequirementDerivation.sysml.json # docs/project/api-json-differential/pilot-examples/Room Model/RoomModel.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/ActionTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/AnalysisTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/CalculationTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/ConstraintTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/EnumerationTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/FeaturePathTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/IndividualTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/ItemTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/OccurrenceTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/PartTest.sysml.json # docs/project/api-json-differential/pilot-examples/Simple Tests/VerificationTest.sysml.json # docs/project/api-json-differential/pilot-examples/State Space Representation Examples/EVSample.sysml.json # docs/project/api-json-differential/pilot-examples/State Space Representation Examples/EVSample1.sysml.json # docs/project/api-json-differential/pilot-examples/Timeslice and Snapshot Examples/TimeVaryingAttribute.sysml.json # docs/project/api-json-differential/pilot-examples/Variability Examples/VehicleVariabilityModel.sysml.json # docs/project/api-json-differential/pilot-examples/Vehicle Example/Annex_A_VehicleViews.sysml.json # docs/project/api-json-differential/pilot-examples/Vehicle Example/SysML v2 Spec Annex A SimpleVehicleModel.sysml.json # docs/project/api-json-differential/pilot-examples/Vehicle Example/VehicleIndividuals.sysml.json # docs/project/api-json-differential/pilot-examples/v1 Spec Examples/8.4.5 Constraining Decomposition/Vehicle Decomposition - Updated.sysml.json # docs/project/api-json-differential/pilot-examples/v1 Spec Examples/8.4.5 Constraining Decomposition/Vehicle Decomposition.sysml.json # docs/project/api-json-differential/pilot-examples/v1 Spec Examples/D.4.7.8 Dynamics/HSUVDynamics.sysml.json # docs/project/api-json-differential/pilot-validation/01-Parts Tree/1c-Parts Tree Redefinition.sysml.json # docs/project/api-json-differential/pilot-validation/01-Parts Tree/1d-Parts Tree with Reference.sysml.json # docs/project/api-json-differential/pilot-validation/02-Parts Interconnection/2c-Parts Interconnection-Multiple Decompositions.sysml.json # docs/project/api-json-differential/pilot-validation/03-Function-based Behavior/3c-Function-based Behavior-structure mod-1.sysml.json # docs/project/api-json-differential/pilot-validation/03-Function-based Behavior/3d-Function-based Behavior-item.sysml.json # docs/project/api-json-differential/pilot-validation/03-Function-based Behavior/3e-Function-based Behavior-item.sysml.json # docs/project/api-json-differential/pilot-validation/04-Functional Allocation/4a-Functional Allocation.sysml.json # docs/project/api-json-differential/pilot-validation/05-State-based Behavior/5-State-based Behavior-1.sysml.json # docs/project/api-json-differential/pilot-validation/05-State-based Behavior/5-State-based Behavior-1a.sysml.json # docs/project/api-json-differential/pilot-validation/05-State-based Behavior/5-State-based Behavior-2.sysml.json # docs/project/api-json-differential/pilot-validation/07-Variant Configuration/7b-Variant Configurations.sysml.json # docs/project/api-json-differential/pilot-validation/08-Requirements/8-Requirements.sysml.json # docs/project/api-json-differential/pilot-validation/09-Verification/9-Verification-simplified.sysml.json # docs/project/api-json-differential/pilot-validation/10-Analysis and Trades/10a-Analysis.sysml.json # docs/project/api-json-differential/pilot-validation/10-Analysis and Trades/10b-Trade-off Among Alternative Configurations.sysml.json # docs/project/api-json-differential/pilot-validation/10-Analysis and Trades/10c-Fuel Economy Analysis.sysml.json # docs/project/api-json-differential/pilot-validation/12-Dependency Relationships/12b-Allocation-1.sysml.json # docs/project/api-json-differential/pilot-validation/15-Properties-Values-Expressions/15_03-Value Expression.sysml.json # docs/project/api-json-differential/pilot-validation/15-Properties-Values-Expressions/15_05-Unification of Expression and Constraint Definition.sysml.json # docs/project/api-json-differential/pilot-validation/15-Properties-Values-Expressions/15_19-Materials with Properties.sysml.json # docs/project/api-json-differential/pilot-validation/15-Properties-Values-Expressions/15_19a-Materials with Properties.sysml.json # docs/project/api-json-differential/spec-examples/kerml/7.3.4.2/8.kerml.json # docs/project/api-json-differential/spec-examples/kerml/7.4.10.3/1.kerml.json # docs/project/api-json-differential/spec-examples/kerml/7.4.11/4.kerml.json # docs/project/api-json-differential/spec-examples/kerml/7.4.9.4/3.kerml.json # docs/project/api-json-differential/spec-examples/sysml/7.16.2/3.sysml.json # docs/project/api-json-differential/spec-examples/sysml/7.17.11/3.sysml.json # docs/project/api-json-differential/spec-examples/sysml/7.17.7/1.sysml.json # docs/project/api-json-differential/spec-examples/sysml/7.17.7/3.sysml.json # docs/project/api-json-differential/spec-examples/sysml/7.17.7/4.sysml.json # docs/project/api-json-differential/spec-examples/sysml/7.17.7/5.sysml.json # docs/project/api-json-differential/spec-examples/sysml/7.20.2/1.sysml.json # docs/project/api-json-differential/spec-examples/sysml/7.21.2/5.sysml.json # docs/project/api-json-differential/spec-examples/sysml/7.23.3/1.sysml.json # docs/project/api-json-differential/spec-examples/sysml/8.4.13.3/2.kerml.json # docs/project/api-json-differential/spec-examples/sysml/8.4.17.3/2.sysml.json # docs/project/api-json-differential/spec-examples/sysml/8.4.17.3/4.sysml.json # docs/project/api-json-differential/training/04. Subsetting/Subsetting Example.sysml.json # docs/project/api-json-differential/training/05. Redefinition/Redefinition Example.sysml.json # docs/project/api-json-differential/training/12. Binding Connectors/Binding Connectors Example-2.sysml.json # docs/project/api-json-differential/training/17. Control/Control Structures Example.sysml.json # docs/project/api-json-differential/training/17. Control/Decision Example.sysml.json # docs/project/api-json-differential/training/21. Asynchronous Messaging/Messaging Example.sysml.json # docs/project/api-json-differential/training/21. Asynchronous Messaging/Messaging with Ports.sysml.json # docs/project/api-json-differential/training/27. Occurrences/Interaction Realization-1.sysml.json # docs/project/api-json-differential/training/27. Occurrences/Interaction Realization-2.sysml.json # docs/project/api-json-differential/training/27. Occurrences/Message Payload Example.sysml.json # docs/project/api-json-differential/training/28. Individuals/Individuals and Roles-1.sysml.json # docs/project/api-json-differential/training/28. Individuals/Individuals and Time Slices.sysml.json # docs/project/api-json-differential/training/29. Expressions/Car Mass Rollup Example 1.sysml.json # docs/project/api-json-differential/training/29. Expressions/Car Mass Rollup Example 2.sysml.json # docs/project/api-json-differential/training/29. Expressions/MassRollup1.sysml.json # docs/project/api-json-differential/training/29. Expressions/MassRollup2.sysml.json # docs/project/api-json-differential/training/30. Calculations/Calculation Usages-1.sysml.json # docs/project/api-json-differential/training/30. Calculations/Calculation Usages-2.sysml.json # docs/project/api-json-differential/training/31. Constraints/Derivation Constraints.sysml.json # docs/project/api-json-differential/training/31. Constraints/Time Constraints.sysml.json # docs/project/api-json-differential/training/32. Requirements/Requirement Definitions.sysml.json # docs/project/api-json-differential/training/32. Requirements/Requirement Groups.sysml.json # docs/project/api-json-differential/training/32. Requirements/Requirement Usages.sysml.json # docs/project/api-json-differential/training/33. Analysis/Analysis Case Definition Example.sysml.json # docs/project/api-json-differential/training/33. Analysis/Analysis Case Usage Example.sysml.json # docs/project/api-json-differential/training/33. Analysis/Trade Study Analysis Example.sysml.json # docs/project/api-json-differential/training/34. Verification/Verification Case Definition Example.sysml.json # docs/project/api-json-differential/training/34. Verification/Verification Case Usage Example.sysml.json # docs/project/api-json-differential/training/41. Language Extension/User Keyword Example.sysml.json # internal/doc/queryexec/elementids.go # internal/semantic/metamodel/structure_rules.go # internal/translate/export/api_json_symbol_structure_test.go # internal/translate/export/rdf_out.go # internal/translate/export/testdata/structure_differential_expected.txt # tests/export/testdata/convert/action_nodes.golden.ttl.sha256 # tests/export/testdata/convert/constraints.golden.ttl.sha256 # tests/export/testdata/convert/decision_branches.golden.ttl.sha256 # tests/export/testdata/convert/empty_names_behavior.golden.ttl.sha256 # tests/export/testdata/convert/end_binding_bodies.golden.ttl.sha256 # tests/export/testdata/convert/kind_keyword_synonyms.golden.ttl # tests/export/testdata/convert/quoted_succession_ends.golden.ttl # tests/export/testdata/convert/result_expressions.golden.ttl.sha256 # tests/export/testdata/convert/shadowed_references.golden.ttl.sha256 # tests/export/testdata/convert/shadowing_parameters.golden.ttl.sha256 # tests/export/testdata/convert/then_after_members.golden.ttl.sha256 # tests/export/testdata/convert/views_flows_parameters.golden.ttl.sha256
…rited-family-complete
Co-Authored-By: jason.han <hanhuijun@gmail.com>
…pleted end features Co-Authored-By: jason.han <hanhuijun@gmail.com>
Contributor
Author
There was a problem hiding this comment.
Note
Newer findings are available below. Devin Review posted a newer report on this PR, in addition to the findings presented here.
Devin Review found 6 findings. Devin fixed 4 findings; 2 findings are left for you to triage in Devin Review.
Fixed by Devin (4)
- Shorthand test comment exceeds line limit — Comment shortened to two lines.
- Performed-chain test comment exceeds line limit — Comment shortened to two lines.
- Objective test comment exceeds line limit — Comment shortened to two lines.
- Flow-direction helper comment exceeds line limit — Comment shortened to two lines.
…family-complete Co-Authored-By: jason.han <hanhuijun@gmail.com>
…ner inherits A positional `then` succession targeting any library feature named done read back as `then done;`, which names the done its owner inherits, so a target such as States::StateAction::done in an action changed on a round trip. The rendering is now checked to reach the graph's target and the succession is written by name otherwise. Co-Authored-By: jason.han <hanhuijun@gmail.com>
…chain, not its last feature Co-Authored-By: jason.han <hanhuijun@gmail.com>
…y is still checked by what it reaches Co-Authored-By: jason.han <hanhuijun@gmail.com>
… census and end-binding golden on the merged tree Co-Authored-By: jason.han <hanhuijun@gmail.com>
…ch, not by the succession's position Co-Authored-By: jason.han <hanhuijun@gmail.com>
…rited-family-complete Co-Authored-By: jason.han <hanhuijun@gmail.com> # Conflicts: # internal/semantic/metamodel/structure_rules.go
…rited-family-complete
…rited-family-complete Co-Authored-By: jason.han <hanhuijun@gmail.com> # Conflicts: # docs/project/api-json-differential/examples/self-model/pipeline.sysml.json # docs/project/api-json-differential/index.json # internal/semantic/metamodel/derived_census_records.tsv # internal/translate/export/testdata/structure_differential_expected.txt
…census and structure differential on the merged tree The NPR 7123 example model develop added joins the examples root, and the self-model pipeline moved with it; the rows are this branch's inherited family, endFeature and direction measured over them. Co-Authored-By: jason.han <hanhuijun@gmail.com>
6 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
The compliance row "The element form states the derived properties the graph does not carry" claimed that the properties over a type's inherited members are not completed. On current
developthat is only partly true: the family is inapiJSONCompletedPropertiesand is completed wherever a type's generals are graph types or implied library bases. Measured with the writer's omission hook, what was still withheld or wrong, and what this PR does about each:attribute a : ScalarValues::Integer,part g : Parts::Part): the feature lost the whole family, becausestructureLibraryBaseasked only the symbol structure for a library symbolLibrarySymbolResolverinterface, which the graph structure already implements over the library catalogType::endFeaturenot completed at allinheritedMembership/inheritedFeature/feature/memberMultiplicityRangewas listed as a feature; an inherited enumerated value was listed as a featuremetamodel/types.go(membershipKind,isFeatureMembership): both are members through anOwningMembership/VariantMembership, neither through aFeatureMembershipimportedMembership, and with itmembership/member, withheld (the evaluator derives imports from the syntax tree, not from the graph)The row therefore stays⚠️ Approximate and is restated with exactly what remains (imports in graph mode, unresolved generals, expression elements, and the properties the pilot and the constraint read apart).
Specification basis
Type:deriveTypeInheritedMembership,deriveTypeFeature,deriveTypeFeatureMembership,deriveTypeInheritedFeature,deriveTypeEndFeature,inheritableMemberships/nonPrivateMemberships/removeRedefinedFeatures;Type::multiplicityis anownedMember, held by anOwningMembership. Grammar:OwnedMultiplicity returns OwningMembership(KerML.xtext, SysML.xtext).checkFeatureEndRedefinition: an end of a type redefines the end at the same position of each direct supertype.VariantMembership; grammarEnumerationUsageMember returns VariantMembership(SysML.xtext). AVariantMembershipis anOwningMembership, not aFeatureMembership, so an enumerated value is nofeatureof a type that inherits it.Namespace::membership/member; SysML §8.3.6.4/§8.3.6.2Usage::usage,Definition::usage.Pilot (2026-09.1), as referee only. Probed with the pilot JSON exporter on small models: it lists a stated library general's members in the family; for a type with two generals, one of whose ends it redefines, it states only the non-redefined ends in
endFeature; it lists neither multiplicity ranges nor enumerated values infeature. Each agrees with the clause reading above; none was adopted against it. Where the pilot's lists still differ (order of members inherited through several generals, the multiplicity of an intermediate feature of a subsetting chain) nothing was changed to match it.How it was verified
New tests, failing on
develop:export/api_json_stated_library_base_test.goTestAPIJSONStatedLibraryBaseCompletesTheInheritedFamily,TestAPIJSONEndFeatureCompletesOwnedEndsWithInheritedOnes,TestAPIJSONEndFeatureLeavesOutRedefinedInheritedEnds,TestAPIJSONInheritedEnumeratedValuesAreMembersNotFeatures.Existing tests changed, and why:
TestElementFormRecordsPerElementOmissionsasserted an omission forinheritedFeatureof a feature typed by a library type, which is exactly what is now completed; it now asserts that this omission is gone and checks the omission record on a property that is still withheld.TestAPIJSONNestedUsageInheritsThroughItsImpliedSubsettingcompared the size ofinheritedFeature, which counted multiplicity ranges; the same comparison is kept oninheritedMembershipandmember, andfeature/inheritedFeatureare asserted to hold noMultiplicityRange.evaluator_expression_2_test.go) statesFeature::isEnd = falsefor its parameters, which the end-position masking reads.Gates:
gofmt -l .empty,go vet ./...,go build ./...,make lint,go test ./tests/hygiene,python3 scripts/spec_compliance.py check,make changelog-check,go test ./internal/semantic/... ./internal/translate/export ./tests/exportpass.go test ./tests/corpuswithOPENSYSML_REQUIRE_TRAINING_CORPUS,OPENSYSML_REQUIRE_PILOT_CORPORAandOPENSYSML_REQUIRE_SPEC_EXAMPLESset passes with no ratchet movement, andmake docs-countsis current.Baselines that moved
docs/project/api-json-differential/(718 of 935 fragments,index.jsonreindexed): present-equal +29182, present-different −4281, ours-missing −32406, pilot-missing +64, indeterminate +7505; no element match moves and no row of any file loses a present-equal comparison. Only the family moves (feature,featureMembership,inheritedFeature,inheritedMembership,membership,member,usage,directedUsage,directedFeature,input,output,endFeature,subjectParameter). Adjudicated per property indocs/project/api-json-differential.md(step 6):inheritedMembership/membership/membergo ours-missing → present-different for features with a stated library general: now stated, differing from the pilot by the causes already recorded (member order across several generals, intermediate multiplicities), not by a new one;usageon elements this writer exports as a SysML usage and the pilot as a KerMLFeature(an existing metaclass difference;typeMismatchunchanged);endFeaturepresent-different (15 rows, allFlowUsage, see Not done) and the residue ofdirectedFeature/input/outputwere not classified row by row.internal/translate/export/testdata/structure_differential_expected.txt(symbol structure against graph structure): the graph structure now answers where it was unsupported, so thesymbol-extracolumn of the family falls (Type::feature2274 → 48 on the examples root) and those elements are compared: most land inequal(Type::feature10249 → 12205), the rest indifferent(656 → 926). The newly compared differences are elements the graph holds and the symbol structure does not: the ends a flow owns (Connector::connectorEnd/Type::endFeatureof aFlowUsage: the graph states the flow's own ends, the symbol structure the library'sFlows::flows::source/target) and anonymous owned members. The graph structure is the one the export uses.Connector::connectorEndequal falls 580 → 554 andType::endFeaturedifferent rises 0 → 40 on the examples root; these were sampled (flows and anonymous ends, as above), not classified element by element.tests/export/testdata/convert/*.golden.ttl(.sha256): additive library-member stubs for the newly completed lists;kind_keyword_synonymsloses the stubs ofAllocations::Allocation::source/target, which the usage's own ends redefine by position.tests/corpus/testdata/training_examples_expected.txtis untouched.Dry merge against #2002
git merge-treeof this branch with the head of #2002 (b83ee159da) conflicts instructure_rules.go(the import block only),docs/project/api-json-differential.md,derived_census_baseline.json,structure_differential_expected.txtand the conversion goldens. #2002 conflicts withdevelopitself in the same files; this branch adds two generated goldens (parts.golden.ttl,invariant_references.golden.ttl) to that list and no source conflict. The two changes are independent in code: #2002 gives expression elements an implied base, this PR resolves stated library generals and ends. Whichever lands second re-records the generated baselines.Not done
Namespace::importedMembership(andmembership/memberof an importing namespace).endFeature/directedFeature/input/outputdifferences.developand not changed here: a KerMLassocis written with the typeAssociationUsage, which is no metaclass, so nothing is completed on it (57Association.endFeaturerows ours-missing); amessagewith no ends inheritsFlows::flows::source/targetwhere the pilot statesFlows::messages::source/target(the 15FlowUsage.endFeaturepresent-different rows).Checklist
make testandmake lintpass locally —make lintand the packages listed above; the fullmake testwas not run locallychanges/unreleased/<slug>.<section>.md, not as an edit toCHANGELOG.mdmake docs-countsrunF4,K5) in the body, docs, or changelogReview round 1
endFeature(it is not infeature, andendFeature = feature->select(isEnd)); it still counts as the supertype's end at its position forcheckFeatureEndRedefinition. Test:TestAPIJSONEndFeatureFollowsTheInheritedFeatures.Type::supertypes()— the original type of a conjugated type, else the generals — as the membership walk does. Test:TestStructureEndFeatureOfConjugatedTypeIsTheOriginalTypesEnds(evaluator level: the notation export writes KerMLconjugatesas aSubclassification, an existing limitation, so noConjugationreaches the graph from notation).structure_differential_expected.txtmoves two elements ofType::endFeatureon the spec-examples root from symbol-extra to equal (2865/21 → 2867/19). The api-json differential reproduces unchanged (pilot-apijson-diff -check).Review round 2
FeatureMembershipthat owns an end decides whether a subtype inherits it: a private alias of a public end no longer hides it, and a public alias of a private end does not expose it (Type::featureisfeatureMembership.ownedMemberFeature).TestAPIJSONEndFeatureFollowsTheInheritedFeaturescovers both.TestElementPropertiesReportsWhyAPropertyHasNoAnswer(internal/frontend/grpc) pinnedinheritedFeatureofattribute cmd : ScalarValues::Integeras not derived. It is now derived and asserted so; the per-element refusal is asserted onNamespace::membershipof an importing package, which is still withheld.tests/grpc/testdata/conformance/convert_library_references.expected.jsongains 44 rows and loses none: the members ofISQBase::DurationValueand its supertypes thatattribute period : DurationValuenow references.developmerged;decision_branches.golden.ttl.sha256conflicted and was re-recorded on the merge.go test ./...with the three corpora required, the structure differential andpilot-apijson-diff -checkpass on the merged head.developmerged a second time;structure_differential_expected.txtconflicted and was re-recorded on the merge fromdevelop's side. Againstdevelopit moves the same set of properties as before the merge (the inherited family,Type::endFeature,Connector::connectorEnd,usage/directedUsage, the parameter projections), no new one. The export, metamodel, gRPC and corpus packages with the three corpora required andpilot-apijson-diff -checkpass on the merged head.Follow-up: classification of the end and direction differences
Fixed here (clause text and pilot agree; each has a test that fails without the change)
inparameter (KerML 8.3.4.6.4parameterDirection) and redefines the subject of every general of its owner, an implied base feature included (SysML 7.17.2).TestAPIJSONInheritedSubjectIsAnInputUntilRedefined.checkRequirementUsageObjectiveRedefinition).TestAPIJSONObjectiveInheritsFromTheObjectiveItRedefines.inand listed ininput; it was statedout(SysML.xtextPayloadParameterMember,validateAcceptActionUsageParameters). Movesaccept.golden.ttland six digested goldens.OwningMembershipand is not an end (KerML.xtextOwnedCrossFeatureMember).TestOwnedCrossFeatureIsNotAnEnd. This removes theFeature::isEndrows from the symbol-vs-graph differential.Against the pilot:
directedFeaturepresent-different 1093 → 768,inputours-missing 1439 → 1102,outputpilot-missing 146 → 97. The remaining classes are itemised indocs/project/api-json-differential.md.Symbol-vs-graph
Connector::connectorEnd/Type::endFeaturederiveTypeEndFeature; the pilot agrees). The symbol structure lacks flow-end symbols, which fix(semantics,query): a flow owns its two FlowEnds on the native walk — an EndFeatureMembership each after its payload, the end reference-subsetting the feature before the last it names and owning the ReferenceUsage that redefines that last one — as the conversion mints them and the pilot exports connectorEnd, and the query leg reads the conversion's ids #2266 adds; a dry merge with it removes all of these but one librarymessage. Not duplicated here.inheritedMembership, because one structure does not resolve a general. No differing value.The clause over the pilot: a conjugated port definition, and a port typed by one, take the original's features with directions reversed (KerML 8.3.3.1.10
supertypes); the pilot states[].TransitionUsagepayload: the OCL and the prose ofcheckFeatureParameterRedefinition, and which one is followedKerML 8.4.4.7, prose:
OCL:
SysML 8.4.14.3 (Transition Usages):
The implementation follows the OCL: it reads
supertype.ownedFeatureof the direct general. ATransitionUsage's direct general is the impliedStates::stateTransitionsfeature, which owns no parameters, so nothing is redefined by position and the transition keeps the inheritedStateTransitionAction::payloadandreceiverbeside its own parameters. The SysML prose ("as inherited") and the pilot read the general's inherited parameters instead. The OCL is the constraint as written and the prose asks for more than it does, so behaviour is unchanged here; moving to the prose reading is a change tostructureImplicitParameterRedefinitionsand is left for a maintainer decision.Type::input, symbol structure against graph structure, pilot corpora: the 25 rows that appeared at the previous head (84 → 109 different), each inspectedNow 93 different. 12 of the 25 are fixed (equal); 13 remain and are a defect of the symbol structure, not of the element form.
ConstraintUsage, 2ReferenceUsage): a constraint referenced by name alone (require r;,assume c;) or a barevariant x;. SysML.xtext makes the name anOwnedReferenceSubsetting; the graph had it and so inherited the referenced requirement's subject, the symbol structure had no such relationship. Symbol side wrong, fixed (semantics/reference.goshorthandReference,TestShorthandReferenceIsAReferenceSubsetting).ReferenceUsagerows: thethen done;end of a succession inside a use case. The graph resolveddonetoActions::Action::done, the symbol structure toUseCases::UseCase::done, the member the use case inherits under that name (the redefining feature hides the redefined one, KerML 8.3.3.1.10inheritedMemberships). Graph side wrong, fixed (export/behavior.godoneReference,TestAPIJSONDoneOfAUseCaseIsTheUseCaseLibraryFeature).TransitionUsagerows: a transition with a named accept payload (accept sig : Sig). The graph gives the transition its link and trigger-payload parameters plus the inheritedpayloadandreceiver; the trigger's payload parameter is owned by the triggerAcceptActionUsage(SysML.xtextTriggerAction,AcceptParameterPart). The symbol structure also lists that named payload as an owned feature of the transition, because the symbol table defines it in the transition's scope for name resolution while the reflective layer synthesizes a second, anonymous one under the trigger. Graph right. Not fixed: the repair is in the symbol builder and the reflective transition parts (one payload symbol, owned by the trigger, resolved through the transition scope), an estimated 150–250 lines plus tests, and it moves query-surface element ids. It predates this PR; at the earlier head the same elements differed underType::outputandStep::parameterinstead.The 25 rows
AnalysisModel__FuelEconomyAnalysis__fuelEconomyAnalysisObjective___402AHFNorway_5fLocalCloudDD__APISProducer__APISPbehavior___403AHFNorway_5fLocalCloudDD__MQTTServer__Serve___403AHFNorway_5fLocalCloudDD__MQTTServer__Serve___407AHFNorway_5fLocalCloudDD__TellUConsumer__TellUbehavior___403Configuration__server_5f2__serverBehavior__deliveringConfiguration__server_5f2__serverBehavior__subscribingConfiguration__server_5f2__serverBehavior__deliveringConfiguration__server_5f2__serverBehavior__subscribingUC___4012_pend1HybridSUVSpec___400HybridSUVSpec___401HybridSUVSpec___402HybridSUVSpec___403S__TS___404S___407leStates__Vehicle__vehicleStates__operatingStates__off_5fTo_5fstartinginitions__Vehicle__vehicleStates__operatingStates__off_5fTo_5fstartingtext__ContextDefinitions__TransportPassenger__TransportObjective___401onContext__TransportPassengerScenario__transportPassenger___4010_pend1tyModel__anyVehicleConfig__engineRqtChoice__highPerformanceRequirementModel__anyVehicleConfig__engineRqtChoice__normalPerformanceRequirementAnalysisModel__FuelEconomyAnalysis__fuelEconomyAnalysisObjective___402provide_20transportation___4014_pend1Four further
PerformActionUsagerows appear at this head (perform startVehicle.trigger1;andtrigger2, both Annex A vehicle models). The chain now inherits from the accept it names (below), and that accept,accept x via p, owns a receiver parameter in the graph (SysML.xtextAcceptParameterPart,NodeParameterMember) which the symbol structure lacks, so it listsTransfers::AcceptPerformance::receiverinstead. Graph right; same symbol-layer family as the 13 above, an estimated 150 lines, not fixed.Other fixes that came out of the inspection (each with a test that fails without it)
featureTarget: "The last of the chainingFeatures of this Feature, if it has any. Otherwise, this Feature itself."), so a performed chain takes its parameters from that feature instead of listing its own positional copies beside them.TestAPIJSONParametersOfAPerformedChainRedefineItsTargets,TestAPIJSONFeatureChainInheritsFromItsTarget.FlowFeaturehas the direction of the feature it redefines, read from itsFlowEnd(KerML.xtextFlowFeature), so a flow end statesinput/output.TestAPIJSONFlowFeatureHasTheDirectionOfTheFeatureItRedefines.TestAPIJSONConjugatedPortKeepsTheDirectionOfTheFeatureItDeclares. Against the pilot this addspilot-missingrows of the documented conjugation class (nowdirectedFeature96,input67,output52; the pilot states[]in each).The inherited library family (was "found, not landed"): landed
The fix was right and exposed a second defect. A type inheriting a parameter that redefines a library feature was withheld the family because the graph's library reference row has no relationships to walk; reading such a row from the library model (
structureLibrarySymbol) completes it.TestLibraryFilesComeBackFromTheGraphAlone/Systems_Library/States.sysmlthen failed because, when the converted file is itself a library file, its own declared elements look like library reference rows too, andowningMembershipwas completed with the catalogue's membership id instead of the membership the graph declares, so the element form no longer read back to the same graph.declaredOwningMembershipID(export/api_json_derived.go) takes the membership the graph declares for an element the graph owns and uses the catalogue only for a true reference row. Contained to export completion and the structure evaluator.TestAPIJSONInheritedParameterRedefiningALibraryFeatureCompletes; the library graph-alone test passes for every library file.Withheld rows against the pilot, assigned mechanically
A throwaway script (not committed) assigns every
ours-missingrow of the four properties to a cause from the omission reason the writer records for that element and property. Unclassified: 0.endFeaturedirectedFeatureinputoutputThe last row is a value difference rather than a withheld class, and it is not adjudicated per metaclass:
AssignmentActionUsage113/113/0,AssertConstraintUsage21/0/21,ForLoopActionUsage8/8/0,WhileLoopActionUsage8/8/0,AttributeUsage6/6/2,FlowDefinition2/2/0,FlowEnd2/1/1, and one or two rows each onCalculationUsage,ConstraintUsage,ForkNode,Function,ReferenceUsage.Symbol-vs-graph differential at this head against the previous one
Over the four roots: equal +861, different +858, symbol-missing −1980, symbol-extra −264; rows one structure withheld are now answered by both. Pilot corpora:
Type::inputdifferent 109 → 93,Type::output41 → 19,Type::directedFeature129 → 111, symbol-missing 65 → 4.Type::endFeaturedifferent 75 → 84: the nine are events and performs of a flow through a chain, which now inherit the flow's own ends in the graph and the library ends in the symbol structure (the flow-end difference #2266 addresses).The 196 newly differing
Type::feature/Type::endFeaturerows were grouped by what each side lists that the other does not; they were not adjudicated one by one:Base::DataValue::self/Base::things::thaton a KerML feature exported under a SysML usage metaclass (the existing metaclass defect).Occurrence::localClockagainstsuboccurrences::localClock, 1 use case: not explained.Namespace::member,membership,Type::inheritedMembershipandUsage::usagemove with these, being derived from the same lists.Golden movement, from the undigested output before and after
action_nodes: three lines, the accept payloadout→inand thesysml:inputof the accept.constraints,empty_names_behavior,metadata_prefixes,result_expressions,shadowed_references: library stub rows only. Removed: the library subject (RequirementCheck/Case/AnalysisCase/VerificationCase::subj) and itsSubjectMembership, because an owner with a stated subject no longer inherits the subject it redefines. Added: that library subject's documentation, multiplicity and owning membership, which the stated subject now inherits by redefining it. Every moved line is one of the two.feature_chains,feature_chains_unresolved,payload_declaration_bodies,connector_ends: inherited library stubs removed, because a chain inherits from the feature it names.end_binding_bodies(2 lines),payload_declaration_bodies(2),then_after_members(6),views_flows_parameters(2):sysml:directionadded on flow features.Wasm sizes, gzipped (budgets untouched)
sysml.wasmGraph-mode
importedMembership(KerML 8.3.2.4) is sized, not implemented: the graph carries the import, its target,isRecursive, visibility and filter, but the evaluator needs a graphvisibleMembershipswalk with an exclusion set, a library-target bridge and filter evaluation. Roughly 500–700 lines of evaluator, 150 of bridge and 500 of tests, re-recording the same baselines: a separate stacked PR.Verification at
a0b359eab7:go test -timeout 40m ./...with the training, pilot and specification-example corpora required passes (140 packages);make lint,tests/hygiene,gofmt -l,go vet,go build, the spec-compliance check,make changelog-checkandmake docs-countspass. The wasm sizes above were measured with-von this tree before its last two direction fixes.training_examples_expected.txtis untouched. Not merged withdevelop; the branch conflicts with it and the baselines are to be regenerated on the merged tree.Merge with
developatd86206819ddevelopwas merged twice (398ec40a67, then04b6706991). Four source files conflicted and were resolved by hand; every generated baseline that conflicted was taken fromdevelopand re-recorded with the repository tools (the cell-wise merge driver could not be configured in the environment the merge was made in).training_examples_expected.txtis untouched.Source resolutions
metamodel/structure_rules.go:develop'sstructureDirectionThroughreplaces this branch'sstructureConjugatedOriginal/structureDirectionThroughGenerals;structureGeneralWithFeaturenow readsstructureGeneralTypes(role generals, feature-chain targets and implied bases included), which the flow-feature direction test needs. The compliance row citesstructureDirectionThrough.export/rdf_out.go:flowEndReferencestakes bothdevelop's feature name and this branch's flow-feature direction.queryexec/elementids.go,export/api_json_symbol_structure_test.go: both sides' cases kept (ImplicitShorthandReference; flow-end feature relationships andImplicitMetadataBodyRedefinition).developmade the inherited family opt-in (APIJSONOptions.InheritedMembers); the tests of this PR that assert it callWriteAPIJSONWithOptionswith the option set, assertions unchanged.Baselines re-recorded, against
developusage,directedFeature,directedUsage,input,output,endFeature,direction,subjectParameter,actorParameter,stakeholderParameter. The per-property adjudication above is the pre-merge measurement and was not re-derived row by row on the merged tree.structure_differential_expected.txt,derived_census_baseline.json(implied relationships +6/+25/+7/+2 over four roots, the shorthand references) andderived_census_records.tsv.Occurrences::happensBeforeLinks::earlierOccurrence/laterOccurrence(andAllocations::Allocation::source/targetinkind_keyword_synonyms):developgives those successions and allocations owned ends, and an inherited end an owned end redefines is no inherited member here.Wasm sizes on the merged tree, gzipped (budgets untouched): browser RE 15,764,116 of 16,500,000; engine 10,501,592 of 11,300,000; core 6,824,001 of 7,600,000; combined 11,119,569 of 12,000,000; syntax 1,665,565 of 1,800,000.
Verification:
go test -timeout 40m ./...with the three corpora required passes on the first merge (140 packages). After the second merge (26 files, none underexportormetamodelbut two baseline lines): build, vet,gofmt,make lint, hygiene, the API JSON differential and derived-census checks,make docs-counts, and theinternal/ir,internal/semantic,export,tests/corpus,tests/exportandtests/grpcpackages pass; the whole suite was not re-run on it.Link to Devin session: https://nasa-jpl-demo.devinenterprise.com/sessions/e15c55c14e0546158a5ea1b11739c5a4
Open in Devin Desktop: https://nasa-jpl-demo.devinenterprise.com/desktop/session/e15c55c14e0546158a5ea1b11739c5a4?variant=devin
Requested by: @HuiJun
🟢 Devin Review found nothing to fix · View findings · Follow Devin's work