rlmesh::adapters::EnvTags
The semantic tags an env publishes for its observation and action spaces.
struct EnvTagsAssociated functions
Methods
- observation()The authored immutable observation tag tree.
- action()The authored environment action layout.
- to_dict()Validate and serialize to canonical typed metadata.
- to_json()Serialize to canonical compact, sorted UTF-8 JSON.
- to_metadata()The fragment to merge into contract metadata.
- observation_roles()Declared roles grouped by modality, in authored order.
new
associated function[source]fn new(observation: impl Into<ObsNode>, action: Action) -> Result<Self>Construct and validate environment observation and action tags.
from_dict
associated function[source]fn from_dict(data: &Metadata) -> Result<Self>Read and validate a typed metadata representation.
from_json
associated function[source]fn from_json(payload: &str) -> Result<Self>Read and validate a JSON representation.
from_metadata
associated function[source]fn from_metadata(metadata: &Metadata) -> Result<Option<Self>>Read the versioned metadata key; absent or None yields None.
observation
method[source]fn observation(&self) -> &ObsNodeThe authored immutable observation tag tree.
action
method[source]fn action(&self) -> &ActionThe authored environment action layout.
to_dict
method[source]fn to_dict(&self) -> Result<Metadata>Validate and serialize to canonical typed metadata.
to_json
method[source]fn to_json(&self) -> Result<String>Serialize to canonical compact, sorted UTF-8 JSON.
to_metadata
method[source]fn to_metadata(&self) -> Result<Metadata>The fragment to merge into contract metadata.
observation_roles
method[source]fn observation_roles(&self) -> ObservationRolesDeclared roles grouped by modality, in authored order.
Trait implementations
- impl Clone for EnvTags
- impl Debug for EnvTags
- impl StructuralPartialEq for EnvTags
- impl PartialEq for EnvTags
- impl Display for EnvTags