chore: import upstream snapshot with attribution

This commit is contained in:
wehub-resource-sync
2026-07-13 13:17:40 +08:00
commit f1825c8ceb
10096 changed files with 2364182 additions and 0 deletions
@@ -0,0 +1,25 @@
from pydantic import BaseModel
from ray import serve
class TypedArgs(BaseModel):
message: str = "DEFAULT"
@serve.deployment(ray_actor_options={"num_cpus": 0})
class Echo:
def __init__(self, message: str):
print("Echo message:", message)
self._message = message
def __call__(self, *args):
return self._message
def build_echo_app(args):
return Echo.bind(args.get("message", "DEFAULT"))
def build_echo_app_typed(args: TypedArgs):
return Echo.bind(args.message)