embodichain.lab.task_program.language#
Task Program source schema, strict decoding, validation, and loading.
Task Program source is represented by executable-free schema values. The same package owns strict JSON/YAML decoding, reference validation, bounded loading, and pathful configuration errors.
|
Validate one articulation joint against an inclusive position interval. |
|
Explicit synchronization boundary owned by one parallel node. |
|
Built-in immutable sequence. |
|
Represent a PEP 604 union type |
|
Finite pose values selected cyclically by the enclosing repeat index. |
|
Declarative request to transfer one held object between resources. |
|
Invoke exactly one semantic call at the current program boundary. |
|
Validate an object's position against one resolved target. |
|
Execute two or more branches concurrently and join at one barrier. |
|
Declarative request to acquire one registered object. |
|
Declarative request to place one held object at one destination. |
|
One declarative Cartesian pose using a WXYZ quaternion. |
|
Safe declarative payload for one catalog-registered semantic call. |
|
Repeat one child node a finite validated number of times. |
|
alias of |
|
Logical program transaction with post-policies and validators. |
|
Execute one non-empty ordered tuple of program nodes. |
|
Reference to one top-level typed target provider. |
|
Strict, executable-free Task Program configuration. |
|
Base pathful diagnostic for Task Program configuration failures. |
|
Raised when untrusted data does not match a supported strict schema. |
|
Static integration references selected by one Task Program. |
|
Provider-free static validation boundary for external references. |
|
Raised when an explicit static integration context rejects a reference. |
|
Wait for one registered entity to satisfy a named stability preset. |
|
Decode untrusted JSON/YAML-shaped values into strict program config. |
|
Safely load and strictly decode one JSON or YAML Task Program file. |
|
Strictly parse and decode one untrusted Task Program JSON document. |
|
Parse one bounded Task Program JSON object without decoding its schema. |
|
Render one configuration path using JSONPath-like notation. |
|
Resolve external references without observing or executing an environment. |
Classes:
|
Validate one articulation joint against an inclusive position interval. |
|
Explicit synchronization boundary owned by one parallel node. |
|
Finite pose values selected cyclically by the enclosing repeat index. |
|
Declarative request to transfer one held object between resources. |
|
Invoke exactly one semantic call at the current program boundary. |
|
Validate an object's position against one resolved target. |
|
Execute two or more branches concurrently and join at one barrier. |
|
Declarative request to acquire one registered object. |
|
Declarative request to place one held object at one destination. |
|
One declarative Cartesian pose using a WXYZ quaternion. |
|
Safe declarative payload for one catalog-registered semantic call. |
|
Repeat one child node a finite validated number of times. |
|
Logical program transaction with post-policies and validators. |
|
Execute one non-empty ordered tuple of program nodes. |
|
Reference to one top-level typed target provider. |
|
Strict, executable-free Task Program configuration. |
|
Static integration references selected by one Task Program. |
|
Provider-free static validation boundary for external references. |
|
Wait for one registered entity to satisfy a named stability preset. |
Exceptions:
|
Base pathful diagnostic for Task Program configuration failures. |
|
Raised when untrusted data does not match a supported strict schema. |
|
Raised when an explicit static integration context rejects a reference. |
Functions:
|
Decode untrusted JSON/YAML-shaped values into strict program config. |
|
Safely load and strictly decode one JSON or YAML Task Program file. |
|
Strictly parse and decode one untrusted Task Program JSON document. |
|
Parse one bounded Task Program JSON object without decoding its schema. |
|
Render one configuration path using JSONPath-like notation. |
|
Resolve external references without observing or executing an environment. |
- class embodichain.lab.task_program.language.ArticulationJointPositionValidatorCfg[source]
Validate one articulation joint against an inclusive position interval.
Methods:
__init__([articulation, joint, ...])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(articulation=<factory>, joint=<factory>, minimum_position=<factory>, maximum_position=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.BarrierCfg[source]
Explicit synchronization boundary owned by one parallel node.
Methods:
__init__([name, timeout_steps, ...])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(name=<factory>, timeout_steps=<factory>, failure_policy=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.CyclicPoseTargetCfg[source]
Finite pose values selected cyclically by the enclosing repeat index.
Methods:
__init__([values, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(values=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.HandOverCfg[source]
Declarative request to transfer one held object between resources.
Methods:
__init__([object, final_target, resources, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(object=<factory>, final_target=<factory>, resources=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.InvokeCfg[source]
Invoke exactly one semantic call at the current program boundary.
Methods:
__init__([call, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(call=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.ObjectNearTargetValidatorCfg[source]
Validate an object’s position against one resolved target.
Methods:
__init__([object, target, ...])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(object=<factory>, target=<factory>, position_tolerance=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.ParallelCfg[source]
Execute two or more branches concurrently and join at one barrier.
Methods:
__init__([branches, barrier, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(branches=<factory>, barrier=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.PickCfg[source]
Declarative request to acquire one registered object.
Methods:
__init__([object, grasp, resources, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(object=<factory>, grasp=<factory>, resources=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.PlaceCfg[source]
Declarative request to place one held object at one destination.
Methods:
__init__([object, at, on, inside, ...])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(object=<factory>, at=<factory>, on=<factory>, inside=<factory>, resources=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.PoseCfg[source]
One declarative Cartesian pose using a WXYZ quaternion.
Methods:
__init__([position, quaternion_wxyz])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(position=<factory>, quaternion_wxyz=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.RegisteredSemanticCallCfg[source]
Safe declarative payload for one catalog-registered semantic call.
Methods:
__init__([call_id, arguments, resources, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(call_id=<factory>, arguments=<factory>, resources=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.RepeatCfg[source]
Repeat one child node a finite validated number of times.
Methods:
__init__([count, body, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(count=<factory>, body=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.SegmentCfg[source]
Logical program transaction with post-policies and validators.
Methods:
__init__([name, steps, post, validators, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(name=<factory>, steps=<factory>, post=<factory>, validators=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.SequenceCfg[source]
Execute one non-empty ordered tuple of program nodes.
Methods:
__init__([items, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(items=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.TargetRefCfg[source]
Reference to one top-level typed target provider.
Methods:
__init__([target, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(target=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.TaskProgramCfg[source]
Strict, executable-free Task Program configuration.
Methods:
__init__([program_id, integration, program, ...])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(program_id=<factory>, integration=<factory>, program=<factory>, targets=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- exception embodichain.lab.task_program.language.TaskProgramConfigError[source]
Base pathful diagnostic for Task Program configuration failures.
Methods:
__init__(code, path, message)Create one stable pathful diagnostic.
- __init__(code, path, message)[source]
Create one stable pathful diagnostic.
- Parameters:
code (
str) – Machine-readable failure code.path (
tuple[str|int,...]) – Exact configuration location.message (
str) – Human-readable explanation.
- exception embodichain.lab.task_program.language.TaskProgramDecodeError[source]
Raised when untrusted data does not match a supported strict schema.
- class embodichain.lab.task_program.language.TaskProgramIntegrationCfg[source]
Static integration references selected by one Task Program.
Methods:
__init__([robot_profile, scene_registry, ...])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(robot_profile=<factory>, scene_registry=<factory>, runtime_preset=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- class embodichain.lab.task_program.language.TaskProgramValidationContext[source]
Provider-free static validation boundary for external references.
Implementations may resolve profile, scene, preset, catalog, affordance, and resource IDs, but must not observe simulation state, construct planners, or execute calls.
Methods:
__init__(*args, **kwargs)validate_integration(integration, *, path)Validate integration references at
path.validate_post_policy(policy, *, path)Validate a post-policy kind and its named preset.
validate_scene_reference(reference, *, role, ...)Validate one canonical scene reference with its semantic role.
validate_semantic_call(call, *, path)Validate catalog identity, schema revision, and resource overrides.
validate_validator(validator, *, path)Validate one registered segment-validator contract.
- __init__(*args, **kwargs)
- validate_integration(integration, *, path)[source]
Validate integration references at
path.- Return type:
None
- validate_post_policy(policy, *, path)[source]
Validate a post-policy kind and its named preset.
- Return type:
None
- validate_scene_reference(reference, *, role, path)[source]
Validate one canonical scene reference with its semantic role.
- Return type:
None
- validate_semantic_call(call, *, path)[source]
Validate catalog identity, schema revision, and resource overrides.
- Return type:
None
- validate_validator(validator, *, path)[source]
Validate one registered segment-validator contract.
- Return type:
None
- exception embodichain.lab.task_program.language.TaskProgramValidationError[source]
Raised when an explicit static integration context rejects a reference.
- class embodichain.lab.task_program.language.WaitStablePostCfg[source]
Wait for one registered entity to satisfy a named stability preset.
Methods:
__init__([entity, preset, kind])copy(**kwargs)Return a new object replacing specified fields with new values.
replace(**kwargs)Return a new object replacing specified fields with new values.
to_dict()Convert an object into dictionary recursively.
validate([prefix])Check the validity of configclass object.
- __init__(entity=<factory>, preset=<factory>, kind=<factory>)
- copy(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- replace(**kwargs)
Return a new object replacing specified fields with new values.
This is especially useful for frozen classes. Example usage:
@configclass(frozen=True) class C: x: int y: int c = C(1, 2) c1 = c.replace(x=3) assert c1.x == 3 and c1.y == 2
- Parameters:
obj (
object) – The object to replace.**kwargs – The fields to replace and their new values.
- Return type:
object- Returns:
The new object.
- to_dict()
Convert an object into dictionary recursively.
Note
Ignores all names starting with “__” (i.e. built-in methods).
- Parameters:
obj (
object) – An instance of a class to convert.- Raises:
ValueError – When input argument is not an object.
- Return type:
dict[str,Any]- Returns:
Converted dictionary mapping.
- validate(prefix='')
Check the validity of configclass object.
This function checks if the object is a valid configclass object. A valid configclass object contains no MISSING entries.
- Parameters:
obj (
object) – The object to check.prefix (
str) – The prefix to add to the missing fields. Defaults to ‘’.
- Return type:
list[str]- Returns:
A list of missing fields.
- Raises:
TypeError – When the object is not a valid configuration object.
- embodichain.lab.task_program.language.decode_task_program(data, *, validation_context=None)[source]
Decode untrusted JSON/YAML-shaped values into strict program config.
The schema contains sequential nodes plus deterministic parallel blocks with explicit barriers.
- Parameters:
data (
object) – Exact JSON-compatible mapping produced by a trusted parser.validation_context (
TaskProgramValidationContext|None) – Optional provider-free static reference validator.
- Return type:
- Returns:
Fully owned and internally validated Task Program configuration.
- Raises:
TaskProgramDecodeError – If data is unsafe or violates the schema.
TaskProgramValidationError – If an explicit context rejects a reference.
- embodichain.lab.task_program.language.load_task_program(path, *, base_dir=None, integration=None, validation_context=None)[source]
Safely load and strictly decode one JSON or YAML Task Program file.
Relative paths are resolved from
base_dirwhen provided. Otherwise, they retain normalpathlib.Pathsemantics and therefore resolve from the process working directory when opened.- Parameters:
path (
str|PathLike[str]) – JSON, YAML, or YML file to load.base_dir (
str|PathLike[str] |None) – Optional directory used to resolve a relativepath.integration (
TaskProgramIntegrationCfg|None) – Optional trusted integration selection injected into an unbound program before strict decoding.validation_context (
TaskProgramValidationContext|None) – Optional provider-free static reference validator applied after decoding either serialized format.
- Return type:
- Returns:
An owned, validated Task Program configuration.
- Raises:
FileNotFoundError – If the resolved path is not a regular file.
ValueError – If the file is too large, has an unsupported extension, or contains ambiguous or invalid serialized data.
TaskProgramValidationError – If
validation_contextrejects an external reference.UnicodeDecodeError – If the file is not valid UTF-8.
- embodichain.lab.task_program.language.loads_task_program_json(text, *, integration=None, validation_context=None, max_bytes=4194304)[source]
Strictly parse and decode one untrusted Task Program JSON document.
The input must be one plain JSON document. Markdown fences, trailing text, multiple documents, duplicate keys, non-finite numbers, and oversized input are rejected before the existing Task Program decoder is called.
- Parameters:
text (
str) – Untrusted JSON response text.integration (
TaskProgramIntegrationCfg|None) – Optional trusted integration selection injected before strict decoding. The source document must omitintegrationwhen this is provided.validation_context (
TaskProgramValidationContext|None) – Optional provider-free static reference validator.max_bytes (
int) – Maximum UTF-8 encoded response size.
- Return type:
- Returns:
Fully owned and internally validated Task Program configuration.
- Raises:
TypeError – If
textormax_byteshas the wrong exact type.ValueError – If
max_bytesis not positive.TaskProgramDecodeError – If parsing or strict decoding fails.
- embodichain.lab.task_program.language.parse_task_program_json(text, *, max_bytes=4194304)[source]
Parse one bounded Task Program JSON object without decoding its schema.
This parse-only boundary lets a host-controlled frontend inspect or inject fields before calling
decode_task_program(). It rejects duplicate keys, non-finite numbers, trailing content, invalid Unicode, excessive nesting, oversized UTF-8 input, and non-object top-level values. It does not validate the Task Program schema.- Parameters:
text (
str) – Untrusted JSON document text.max_bytes (
int) – Maximum accepted UTF-8 encoded input size.
- Return type:
dict[str,object]- Returns:
Exact JSON object mapping ready for explicit schema decoding.
- Raises:
TypeError – If
textormax_byteshas the wrong exact type.ValueError – If
max_bytesis not positive.TaskProgramDecodeError – If strict JSON parsing fails.
- embodichain.lab.task_program.language.render_config_path(path)[source]
Render one configuration path using JSONPath-like notation.
- Parameters:
path (
tuple[str|int,...]) – Tuple of mapping keys and sequence indices.- Return type:
str- Returns:
Stable human-readable path beginning at
$.
- embodichain.lab.task_program.language.validate_task_program(config, context)[source]
Resolve external references without observing or executing an environment.
- Parameters:
config (
TaskProgramCfg) – Fully decoded and internally validated Task Program.context (
TaskProgramValidationContext) – Provider-free static integration/catalog/scene validator.
- Raises:
TypeError – If either argument has the wrong contract.
TaskProgramValidationError – If an external reference is unavailable.
- Return type:
None