How openai/orchard works
Orchard orchestrates Tart-backed VM clusters: users operate a cluster through the CLI or REST API, while workers register with the controller and manage assigned VMs. The graph separates client access, controller coordination and persistence, and worker-side VM execution. The README documents local development mode and cluster management; several API and worker subsystems are represented by their exact directories because their implementation files were not sampled.
Main entry points: worker.go Worker agent · client.go Go client · controller.go Controller · command Orchard CLI
Components 13
User access
- Orchard CLI
internal/command - Go client
pkg/client/client.go - Local dev mode
internal/command/dev
Controller
- REST API
internal/controller - Controller
internal/controller/controller.go - VM scheduler
internal/controller/scheduler - Badger store
internal/controller/store/badger
Worker execution
- Worker agent
internal/worker/worker.go - VM manager
internal/worker/vmmanager/vmmanager.go - VM runtimes
internal/worker/runtime - Tart runtime
internal/worker/vmmanager/tart/tart.go
Cluster resources
- Cluster resources
pkg/resource/v1
Other components
- Operator
Connections 14
- Operator → Orchard CLI: runs commands
README.md - Orchard CLI → Go client: uses API
internal/command/get/worker.go - Go client → REST API: sends HTTP requests
pkg/client/client.go - REST API → Controller: routes requests
internal/controller/controller.go - Controller → Badger store: creates store
internal/controller/controller.go - Controller → VM scheduler: starts scheduler
internal/controller/controller.go - Worker agent → Go client: uses client
internal/worker/worker.go - Worker agent → VM manager: manages VMs
internal/worker/worker.go - Worker agent → VM runtimes: creates VMs
internal/worker/worker.go - VM manager → Cluster resources: stores VM resources
internal/worker/vmmanager/vmmanager.go - Worker agent → Cluster resources: updates cluster state
internal/worker/worker.go - Local dev mode → Operator: starts local cluster
README.md - Operator → Go client: uses programmatically
README.md - VM runtimes → Tart runtime: includes implementation