Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] SAMM-CLI aas generation: Mapping of Set Characteristics #481

Closed
mhmmi opened this issue Nov 8, 2023 · 4 comments · Fixed by #597
Closed

[BUG] SAMM-CLI aas generation: Mapping of Set Characteristics #481

mhmmi opened this issue Nov 8, 2023 · 4 comments · Fixed by #597
Labels
acknowledged Has been viewed by one of the maintainers and is ready for further work, discussion or other steps. bug Something isn't working

Comments

@mhmmi
Copy link

mhmmi commented Nov 8, 2023

How: List of performed steps
I modeled the following in SAMM

  • SAMM Property "myRoles"
  • with SAMM Set Characteristic "RoleSet"
  • with SAMM Enum Characteristic "RoleEnum"

and then applied SAMM-CLI to derive an AAS

What: Actual result vs expected result
SAMM CLI currently maps this to an AAS SubmodelElementList (SML) plus AAS Property elements inside. Good. Yet, the SML has no semanticId while the AAS properties inside use the id of the SAMM property. Furthermore, both use the same idShort.

IMHO I'd expect the following outcome

  • AAS SubmodelElementList (SML) with idShort "myRoles" and semanticId ...
    • my suggestion: "urn:samm:com.example.roles:0.0.1#myRoles"
  • IMHO the AAS SML directly represents the SAMM Property
  • with many child AAS Properties with empty(*) idShort and each with the same semanticId ...
    • my suggestion 1: "urn:samm:com.example.roles:0.0.1#RoleEnum" (i.e. the Set characteristic's element characteristic)
    • my suggestion 2: or sth. like "urn:samm:com.example.roles:0.0.1#myRoles.element"

(*) "Constraint AASd-120: idShort of submodel elements being a direct child of a SubmodelElementList shall not be specified."

Where: (e.g. component, version, url, your system info)

Input (files/screenshots)

Output (files/screenshots)

Additional context (e.g. references)

@mhmmi mhmmi added the bug Something isn't working label Nov 8, 2023
@chris-volk
Copy link
Contributor

Thanks very much for your input, we will look into the details how we can improve the mapping.

@chris-volk chris-volk added the acknowledged Has been viewed by one of the maintainers and is ready for further work, discussion or other steps. label Jan 16, 2024
@BirgitBoss
Copy link
Contributor

your point "the SML has no semanticId" is reflected in
#522 add semanticId to all elements

@BirgitBoss
Copy link
Contributor

may you please provide your .ttl file and the generated aasx file? It is not completely clear to me how you modelled it. Is it

:Aspect3 a samm:Aspect ;
   samm:properties ( :myRoles ) ;
   samm:operations ( ) ;
   samm:events ( ) .

:myRoles a samm:Property ;
   samm:characteristic :RoleSet .


:RoleSet a samm-c:Enumeration ;
   samm-c:values ( "role2" "role1" ) .

or


:Aspect3 a samm:Aspect ;
   samm:properties ( :myRoles ) ;
   samm:operations ( ) ;
   samm:events ( ) .

:myRoles a samm:Property ;
   samm:characteristic :RoleSet .

:RoleSet a samm-c:Set ;
   samm:dataType :Roles .

:Roles a samm:Entity ;
   samm:properties ( :role ) .

:role a samm:Property ;
   samm:characteristic :MyRolesEnum .

:RolesEnum a samm-c:Enumeration ;
   samm-c:values ( "role 2" "role1" ) .

Copy link

Release v2.9.6 addresses this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
acknowledged Has been viewed by one of the maintainers and is ready for further work, discussion or other steps. bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants