Skip to content

feat(sim): add semantic runtime effects and parallelism - #496

Open
yuecideng wants to merge 1 commit into
feat/atomic-action-verified-runtimefrom
feat/semantic-skill-runtime
Open

feat(sim): add semantic runtime effects and parallelism#496
yuecideng wants to merge 1 commit into
feat/atomic-action-verified-runtimefrom
feat/semantic-skill-runtime

Conversation

@yuecideng

@yuecideng yuecideng commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Description

Stack

Parallel execution remains fail closed: resource analysis and shared-clock coordination are implemented, but production concurrency still requires an authoritative physical safety validator.

Refs #471
Refs #474

Type of change

  • New feature (non-breaking change which adds functionality)

Screenshots

Not applicable.

Validation

  • Focused coverage: tests/sim/skills, including effects, evidence, runtime, parallel compiler/runtime, and conditional cuRobo recovery coverage
  • Final affected-suite regression on the stack tip: 1215 passed, 2 skipped, 8 deselected
  • Changed Python files pass Black 26.3.1; the Sphinx build and rollout-report drift check pass at the stack tip

Checklist

  • Changed Python files pass Black 26.3.1.
  • Corresponding public/design documentation is included in this stack.
  • Tests cover the affected behavior.
  • No dependency update is required.

@yuecideng yuecideng added atomic action atomic action related functionality enhancement New feature or request labels Aug 11, 2026
@yuecideng
yuecideng marked this pull request as ready for review August 11, 2026 16:46
Copilot AI lite review requested due to automatic review settings August 11, 2026 16:46

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds the canonical semantic-skill runtime layer (effects + evidence collection + runtime traces) and introduces a strict, versioned parallel-execution contract that compiles down to the existing atomic-action engine. This extends the simulation “skills” facade with first-class articulation semantics, effect-monitor configuration via policy presets, and deterministic metadata/tracing for downstream program/runtime layers.

Changes:

  • Extend the scene/registry model to publish canonical articulation joint observations and evidence addresses.
  • Add effect-monitor + evidence-source plumbing into robot skill profiles/presets and semantic integration validation.
  • Introduce deterministic parallel timing/state-merge contracts plus extensive test coverage (including a GPU cuRobo dynamic-collision recovery gate).

Reviewed changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tests/sim/skills/test_scene.py Adds joint-observation registration/snapshot behavior tests and simulation alias semantics coverage.
tests/sim/skills/test_runtime.py New end-to-end tests for SkillRuntime behavior, tracing/metadata, row masking, and parallel factory interactions.
tests/sim/skills/test_profiles.py Validates endpoint effect-source snapshotting and preset effect-monitor behavior.
tests/sim/skills/test_parallel.py New tests for parallel alignment, claim conflicts, timing validation, and deterministic barrier/state merging.
tests/sim/skills/test_integration.py Adds binding-time validation for safe preset dynamic-collision requirements and preset reachability semantics.
tests/sim/skills/test_evidence.py New tests for evidence providers/collector registry, query building, and articulation evidence provider behavior.
tests/sim/skills/test_effects.py New tests for effect contracts, monitor refs/registries, and composite monitor behavior.
tests/sim/skills/test_curobo_semantic_runtime_dynamic_recovery_gpu.py GPU/cuRobo integration test ensuring replanning on dynamic collision-world updates.
tests/sim/skills/test_compiler.py Extends compiler tests for effect monitor selection/validation and dynamic collision policy propagation.
tests/sim/skills/test_calls.py Adds deterministic, JSON-safe semantic-call metadata serialization test.
tests/sim/skills/test_articulation_semantics.py New tests for OperateArticulation call semantics, grounding, and typed articulation effects.
embodichain/lab/sim/skills/scene.py Adds articulation joint evidence address + joint-state providers and integrates joint observations into scene versioning.
embodichain/lab/sim/skills/profiles.py Adds endpoint effect-sources, task-state key plumbing, and preset-owned effect-monitor selections.
embodichain/lab/sim/skills/parallel.py New deterministic parallel execution contracts (claims, timing grid, effect merge, barrier resolution).
embodichain/lab/sim/skills/integration.py Adds OperateArticulation call linking and safe dynamic-collision policy preflight validation.
embodichain/lab/sim/skills/calls.py Adds call metadata serialization and introduces OperateArticulation semantic call type.
embodichain/lab/sim/skills/init.py Exposes new runtime/effects/evidence/parallel APIs through package exports.
docs/source/overview/sim/atomic_actions/robot_skill_profiles.md Documents safe preset dynamic-collision rules and preset-driven effect monitor selection.
docs/source/api_reference/embodichain/embodichain.lab.sim.skills.rst Expands API reference to include semantic runtime, effects/evidence, and parallel execution types.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +1993 to +2002
if not torch.equal(
current_position, previous_position
) or not torch.equal(
current_validity,
previous_validity,
):
changed = True
break
self._store_joint_baseline(states)
return changed
@greptile-apps

greptile-apps Bot commented Aug 11, 2026

Copy link
Copy Markdown

Greptile Summary

This PR adds semantic skill execution through the atomic-action engine, including physical-effect verification, articulation operations, tracing and retries, and a fail-closed parallel runtime.

  • Introduces typed semantic effect specifications, evidence providers, composite monitors, and runtime result traces.
  • Adds articulation-call binding, grounding, recovery, and joint-state verification.
  • Adds parallel resource analysis, clock coordination, command alignment, barrier handling, and verified state merging.
  • Extends public API documentation and focused simulation test coverage.

Confidence Score: 5/5

The PR appears safe to merge because no concrete changed-code failure remained after checking the runtime, effect-verification, articulation, and parallel-execution contracts.

The new paths consistently fail closed, preserve row-local verification boundaries, and align with the underlying atomic-action and transport contracts; the investigated edge cases were either explicitly constrained by those contracts or lacked a reachable incorrect outcome.

Important Files Changed

Filename Overview
embodichain/lab/sim/skills/runtime.py Adds the canonical semantic runtime, row-local execution lifecycle, effect verification, retry handling, and structured traces; no publishable defect was established.
embodichain/lab/sim/skills/compiler.py Extends semantic analysis and grounding with articulation operations, symbolic-write contracts, and versioned effect monitors.
embodichain/lab/sim/skills/effects.py Defines typed semantic effects and composite monitor behavior with batched evidence validation and attempt-local hysteresis.
embodichain/lab/sim/skills/evidence.py Adds versioned evidence queries, providers, collection validation, and simulation adapters for physical postconditions.
embodichain/lab/sim/skills/parallel_runtime.py Adds fail-closed parallel execution, shared-clock coordination, barrier handling, command merging, and verified state consolidation.
embodichain/lab/sim/skills/parallel.py Adds strict resource, timing, command-alignment, state-conflict, and barrier primitives for parallel workflows.
embodichain/lab/sim/skills/calls.py Adds the typed OperateArticulation semantic call and deterministic metadata serialization.
embodichain/lab/sim/skills/integration.py Extends semantic binding and validation for effect-monitor and dynamic-collision contracts.
embodichain/lab/sim/skills/profiles.py Adds immutable preset-level effect-monitor selection and validation.
embodichain/lab/sim/skills/scene.py Adds articulation affordance and joint-evidence scene contracts used by semantic grounding and verification.

Sequence Diagram

sequenceDiagram
    participant Caller
    participant Runtime as SkillRuntime
    participant Compiler as SemanticSkillCompiler
    participant Runner as Atomic ExecutionRunner
    participant Evidence as EvidenceCollector
    participant Monitor as EffectMonitor
    Caller->>Runtime: submit semantic workflow
    Runtime->>Compiler: analyze and ground call
    Compiler-->>Runtime: invocation + effect specification
    Runtime->>Runner: execute invocation
    Runner-->>Runtime: pending physical effect
    Runtime->>Evidence: collect fresh backend evidence
    Evidence-->>Runtime: typed evidence batches
    Runtime->>Monitor: evaluate postcondition
    Monitor-->>Runner: verified / unresolved / failed
    alt verified
        Runner-->>Runtime: commit row-local TaskState effects
    else retryable failure
        Runtime->>Compiler: re-ground from fresh scene state
    end
    opt parallel workflow
        Runtime->>Runtime: align lane commands and resolve barrier
        Runtime-->>Caller: fail closed without safety validator
    end
Loading

Reviews (1): Last reviewed commit: "feat(sim): add semantic runtime effects ..." | Re-trigger Greptile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

atomic action atomic action related functionality enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants