-
Notifications
You must be signed in to change notification settings - Fork 29
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
This RFC proposes two changes:
- Makes what are currently singleton services as actors
- APIs on how to spawn actors
Services => Actors
Everything in Forge is currently a service, but maybe this should only be restricted to:
- vLLM generators
- any environments, i.e. coding env etc.
Pros:
- More accurate conceptually - singletons as services is overkill
Cons:
- Introduces more concepts (user has to reason about the fact that there are actors, and there are services which are composed of multiple actors)
How to spawn Actors
Currently, services are spawned as
service = await MyActor.options(replicas=1, procs_per_replica=4, hosts_per_replica=2).as_service()
To maintain consistency, we could spawn singletons as:
actor = await MyActor.options(procs=4, hosts=2).as_actor()
Pros:
- Consistency with how we're reasoning about services
Cons:
- Hides Monarch APIs (i.e. hides away proc_meshes/etc.)
If we like this, then I'd also propose that services drop the _per_replica suffix, so it would then become:
service = await MyActor.options(replicas=1, procs=4, hosts=2).as_service()
Jack-Khuu and vidhyav
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request