INNER CODE UNIT · Python

EchoRequest

awslabs/awsome-distributed-ai · architectures/sagemaker-hyperpod-eks/nvidia-cloud-functions/nvcf/sample-function/server.py:22

class EchoRequest(BaseModel):
    """Echo request model."""

    message: str
    delay: float = 0.0
    repeats: int = 1
    stream: bool = False


# ---------------------------------------------------------------------------
# Health endpoint (required by NVCF)
# Must return HTTP 200 when the container is ready for inference.
# ---------------------------------------------------------------------------
@app.get(
    "/health",
    tags=["healthcheck"],
    summary="Health Check",
    response_description="Return HTTP 200 (OK)",

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…