Optimize Explorer#531
Conversation
|
/unittest-diff |
|
/unittest-diff |
Summary
Skipped
Tests
Github Test Reporter by CTRF 💚 |
|
/unittest-module-trainer |
There was a problem hiding this comment.
Pull request overview
This PR optimizes the Explorer rollout path by keeping the Scheduler and ExperiencePipeline co-located in a new Ray actor (RolloutCoordinator), and by passing pre-serialized experience payloads to reduce Ray object serialization overhead. It also refines dynamic timeout behavior with a step-based warmup.
Changes:
- Introduces
RolloutCoordinatorto own and coordinateScheduler+ExperiencePipeline, providing batch-level finalize APIs. - Switches rollouts to return serialized experience payloads (
bytes) instead of materializedExperiencelists, and adds pipeline support for processing multiple serialized chunks. - Updates Scheduler APIs to return statuses separately from serialized payloads, and adds dynamic-timeout warmup by completed steps.
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| trinity/explorer/workflow_runner.py | Returns serialized experience payloads from run_task and updates debug path accordingly. |
| trinity/explorer/scheduler.py | Reworks result handling to keep payloads serialized; adds get_payload_results/get_statuses; updates dynamic timeout warmup logic. |
| trinity/explorer/rollout_coordinator.py | New actor that owns Scheduler + ExperiencePipeline and exposes batch submission/finalization APIs. |
| trinity/explorer/proxy/service.py | Routes experience submission through RolloutCoordinator.process_experiences. |
| trinity/explorer/explorer.py | Switches exploration/eval finalization flow to use RolloutCoordinator. |
| trinity/explorer/init.py | Exports RolloutCoordinator. |
| trinity/common/config.py | Adds dynamic_timeout.warmup_min_steps. |
| trinity/buffer/pipelines/experience_pipeline.py | Adds process_serialized_chunks to process multiple serialized payload chunks. |
| tests/explorer/workflow_test.py | Adapts tests to deserialize payload bytes into experiences. |
| tests/explorer/scheduler_test.py | Updates tests to use get_payload_results and validates no-deserialization paths. |
| tests/explorer/rollout_coordinator_test.py | New unit tests for coordinator behavior. |
| tests/explorer/explorer_test.py | Adds tests for coordinator-based Explorer path and adjusts serve wait loop. |
| docs/sphinx_doc/source_zh/tutorial/trinity_configs.md | Documents warmup_min_steps and updated dynamic-timeout wording (ZH). |
| docs/sphinx_doc/source/tutorial/trinity_configs.md | Documents warmup_min_steps and updated dynamic-timeout wording (EN). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary
Failed Tests
Skipped
Tests
Github Test Reporter by CTRF 💚 |
|
/unittest-module-trainer |
Summary
Skipped
Tests
Github Test Reporter by CTRF 💚 |
|
/unittest-diff |
|
/unittest-diff |
Summary
Failed Tests
Skipped
Tests
Github Test Reporter by CTRF 💚 |
|
/unittest-module-explorer |
Summary
Tests
Github Test Reporter by CTRF 💚 |
Description
RolloutCoordinatoras a Ray Actor that directly holds theSchedulerandExperiencePipelineobjects, thereby eliminating the overhead previously incurred when theSchedulertransmittedExperiencedata to theExperiencePipelineover the network.WorkflowRunnerpasses pre-serializedExperiencedata to avoid the overhead associated with Ray's built-in serialization and deserialization mechanisms.Checklist
Please check the following items before code is ready to be reviewed.