disagg_planner.yaml 3.69 KB
Newer Older
1
2
3
4
5
6
7
8
# SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: Apache-2.0

apiVersion: nvidia.com/v1alpha1
kind: DynamoGraphDeployment
metadata:
  name: trtllm-disagg-planner
spec:
9
10
11
  pvcs:
    - name: dynamo-pvc
      create: false
12
13
14
15
16
17
18
  services:
    Frontend:
      dynamoNamespace: trtllm-disagg-planner
      componentType: frontend
      replicas: 1
      extraPodSpec:
        mainContainer:
19
          image: my-registry/trtllm-runtime:my-tag
20
          workingDir: /workspace/examples/backends/trtllm
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
          command:
            - python3
          args:
            - -m
            - dynamo.frontend
            - --http-port
            - "8000"
            - --kv-cache-block-size
            - "128"
            - --router-mode
            - kv
            - --kv-overlap-score-weight
            - "0.0"
            - --router-temperature
            - "0.0"
            - --no-kv-events
    Planner:
      dynamoNamespace: trtllm-disagg-planner
      envFromSecret: hf-token-secret
      componentType: planner
      replicas: 1
42
43
44
      volumeMounts:
        - name: dynamo-pvc # Must be pre-created before deployment and SLA profiler must have been run
          mountPoint: /data
45
46
      extraPodSpec:
        mainContainer:
47
          image: my-registry/trtllm-runtime:my-tag
48
          workingDir: /workspace/components/src/dynamo/planner
49
50
51
52
53
54
55
56
57
58
59
          ports:
            - name: metrics
              containerPort: 9085
          command:
            - python3
          args:
            - -m
            - planner_sla
            - --environment=kubernetes
            - --backend=trtllm
            - --adjustment-interval=60
60
            - --profile-results-dir=/data
61
62
63
64
65
            - --prometheus-port=9085
    TRTLLMDecodeWorker:
      dynamoNamespace: trtllm-disagg-planner
      envFromSecret: hf-token-secret
      componentType: worker
66
      subComponentType: decode
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
      replicas: 1
      livenessProbe:
        httpGet:
          path: /live
          port: 9090
        periodSeconds: 5
        timeoutSeconds: 30
        failureThreshold: 1
      readinessProbe:
        httpGet:
          path: /health
          port: 9090
        periodSeconds: 10
        timeoutSeconds: 30
        failureThreshold: 60
      resources:
        limits:
          gpu: "1"
      extraPodSpec:
        terminationGracePeriodSeconds: 600
        mainContainer:
88
          image: my-registry/trtllm-runtime:my-tag
89
          workingDir: /workspace/
90
91
92
93
94
95
96
97
98
99
          command:
            - python3
          args:
            - -m
            - dynamo.trtllm
            - --model-path
            - Qwen/Qwen3-0.6B
            - --served-model-name
            - Qwen/Qwen3-0.6B
            - --extra-engine-args
100
            - ./recipes/qwen3/trtllm/decode.yaml
101
102
103
104
105
106
107
108
            - --disaggregation-mode
            - decode
            - --disaggregation-strategy
            - decode_first
    TRTLLMPrefillWorker:
      dynamoNamespace: trtllm-disagg-planner
      envFromSecret: hf-token-secret
      componentType: worker
109
      subComponentType: prefill
110
111
112
113
114
115
116
      replicas: 1
      resources:
        limits:
          gpu: "1"
      extraPodSpec:
        terminationGracePeriodSeconds: 600
        mainContainer:
117
          image: my-registry/trtllm-runtime:my-tag
118
          workingDir: /workspace/
119
120
121
122
123
124
125
126
127
128
          command:
            - python3
          args:
            - -m
            - dynamo.trtllm
            - --model-path
            - Qwen/Qwen3-0.6B
            - --served-model-name
            - Qwen/Qwen3-0.6B
            - --extra-engine-args
129
            - ./recipes/qwen3/trtllm/prefill.yaml
130
131
132
133
            - --disaggregation-mode
            - prefill
            - --disaggregation-strategy
            - decode_first