Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 1 addition & 8 deletions scripts/kind-dev-env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,7 @@ EPP_IMAGE="${EPP_IMAGE:-${IMAGE_REGISTRY}/llm-d-router-endpoint-picker:${EPP_TAG
export EPP_IMAGE

# Set the model name to deploy.
# When Encode disaggregation is enabled (multimodal pipeline), default to a
# multimodal model. Otherwise use the standard text-only model.
# Note: DISAGG_E/DISAGG_P are set later in this script, so read the raw env vars here.
if [ "${DISAGG_E:-false}" == "true" ] || [ "${EPD_ENABLED:-false}" == "true" ] || [ "${EPD_ENABLED:-false}" == "\"true\"" ]; then
export MODEL_NAME="${MODEL_NAME:-Qwen/Qwen3-VL-2B-Instruct}"
else
export MODEL_NAME="${MODEL_NAME:-TinyLlama/TinyLlama-1.1B-Chat-v1.0}"
fi
export MODEL_NAME="${MODEL_NAME:-Qwen/Qwen3-VL-2B-Instruct}"
# Extract model family (e.g., "meta-llama" from "meta-llama/Llama-3.1-8B-Instruct")
export MODEL_FAMILY="${MODEL_NAME%%/*}"
# Extract model ID (e.g., "Llama-3.1-8B-Instruct")
Expand Down
8 changes: 6 additions & 2 deletions test/e2e/configs_test.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
package e2e

import (
"github.com/llm-d/llm-d-router/test/utils"
)

// Simple EPP configuration for running without P/D
const simpleConfig = `apiVersion: llm-d.ai/v1alpha1
kind: EndpointPickerConfig
Expand Down Expand Up @@ -185,7 +189,7 @@ kind: EndpointPickerConfig
plugins:
- type: token-producer
parameters:
modelName: Qwen/Qwen2.5-1.5B-Instruct
modelName: ` + utils.ModelName + `
vllm:
url: http://localhost:8000
- type: precise-prefix-cache-scorer
Expand Down Expand Up @@ -217,7 +221,7 @@ kind: EndpointPickerConfig
plugins:
- type: token-producer
parameters:
modelName: Qwen/Qwen2.5-1.5B-Instruct
modelName: ` + utils.ModelName + `
vllm:
url: http://localhost:8000
- type: precise-prefix-cache-scorer
Expand Down
20 changes: 10 additions & 10 deletions test/e2e/disruption_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ var disruptionClient = &http.Client{Timeout: 10 * time.Second}

// sendRawCompletion sends a completion request and returns the HTTP status code.
func sendRawCompletion() (int, error) {
body := fmt.Sprintf(`{"model":"%s","prompt":"%s","max_tokens":10}`, simModelName, simplePrompt)
body := fmt.Sprintf(`{"model":"%s","prompt":"%s","max_tokens":10}`, testutils.ModelName, simplePrompt)
req, err := http.NewRequest(http.MethodPost, fmt.Sprintf("http://localhost:%s/v1/completions", port), strings.NewReader(body))
if err != nil {
return 0, err
Expand Down Expand Up @@ -99,7 +99,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup
gomega.Expect(decodePods).Should(gomega.HaveLen(2))

ginkgo.By("Verifying requests route successfully before disruption")
nsHdr, _, _ := runCompletion(simplePrompt, simModelName)
nsHdr, _, _ := runCompletion(simplePrompt)
gomega.Expect(nsHdr).Should(gomega.Equal(nsName))

targetPod := decodePods[0]
Expand All @@ -112,7 +112,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup

ginkgo.By("Verifying new requests eventually route to a pod other than the killed one")
gomega.Eventually(func() error {
nsHdr, podHdr, _, err := tryCompletion(simplePrompt, simModelName)
nsHdr, podHdr, _, err := tryCompletion(simplePrompt)
if err != nil {
return err
}
Expand All @@ -133,7 +133,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup

ginkgo.By("Verifying requests succeed after recovery")
for range 3 {
nsHdr, _, _ = runCompletion(simplePrompt, simModelName)
nsHdr, _, _ = runCompletion(simplePrompt)
gomega.Expect(nsHdr).Should(gomega.Equal(nsName))
}
})
Expand Down Expand Up @@ -185,7 +185,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup

ginkgo.By("Verifying requests succeed after recovery")
for range 3 {
nsHdr, _, _ := runCompletion(simplePrompt, simModelName)
nsHdr, _, _ := runCompletion(simplePrompt)
gomega.Expect(nsHdr).Should(gomega.Equal(nsName))
}
})
Expand All @@ -205,7 +205,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup
gomega.Expect(decodePods).Should(gomega.HaveLen(1))

ginkgo.By("Verifying requests succeed before disruption")
nsHdr, _, _ := runCompletion(simplePrompt, simModelName)
nsHdr, _, _ := runCompletion(simplePrompt)
gomega.Expect(nsHdr).Should(gomega.Equal(nsName))

ginkgo.By("Scaling deployment to zero")
Expand All @@ -231,7 +231,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup

ginkgo.By("Verifying requests succeed after recovery")
gomega.Eventually(func() string {
nsHdr, _, _ := runCompletion(simplePrompt, simModelName)
nsHdr, _, _ := runCompletion(simplePrompt)
return nsHdr
}, eppRecoveryTimeout, 2*time.Second).Should(gomega.Equal(nsName))
})
Expand All @@ -248,7 +248,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup
ginkgo.DeferCleanup(testutils.DeleteObjects, testConfig, epp)

ginkgo.By("Verifying requests succeed before EPP disruption")
nsHdr, _, _ := runCompletion(simplePrompt, simModelName)
nsHdr, _, _ := runCompletion(simplePrompt)
gomega.Expect(nsHdr).Should(gomega.Equal(nsName))

ginkgo.By("Finding EPP pod")
Expand Down Expand Up @@ -297,7 +297,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup
ginkgo.DeferCleanup(testutils.DeleteObjects, testConfig, epp)

ginkgo.By("Verifying requests succeed before disruption")
nsHdr, _, _ := runCompletion(simplePrompt, simModelName)
nsHdr, _, _ := runCompletion(simplePrompt)
gomega.Expect(nsHdr).Should(gomega.Equal(nsName))

ginkgo.By("Starting background traffic")
Expand Down Expand Up @@ -341,7 +341,7 @@ var _ = ginkgo.Describe("Disruption tests", ginkgo.Ordered, ginkgo.Label("Disrup

func sendStreamingCompletion(connected chan<- string) error {
longPrompt := strings.Repeat("This is a longer prompt to keep the stream open. ", 20)
body := fmt.Sprintf(`{"model":"%s","prompt":"%s","max_tokens":100,"stream":true}`, simModelName, longPrompt)
body := fmt.Sprintf(`{"model":"%s","prompt":"%s","max_tokens":100,"stream":true}`, testutils.ModelName, longPrompt)
req, err := http.NewRequest(http.MethodPost, fmt.Sprintf("http://localhost:%s/v1/completions", port), strings.NewReader(body))
if err != nil {
connected <- ""
Expand Down
6 changes: 1 addition & 5 deletions test/e2e/e2e_suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,6 @@ const (
crdKustomizePath = "../../config/crd"
// inferExtManifest is the manifest for the inference extension test resources.
inferExtManifest = "../../deploy/components/inference-gateway/inference-pools.yaml"
// simModelName is the test model name.
simModelName = "food-review"
// kvModelName is the model name used in KV tests.
kvModelName = "Qwen/Qwen2.5-1.5B-Instruct"
// envoyManifest is the manifest for the envoy proxy test resources.
envoyManifest = "../../deploy/environments/dev/e2e-infra/envoy.yaml"
// eppManifest is the manifest for the deployment of the EPP
Expand Down Expand Up @@ -303,7 +299,7 @@ func createEnvoy() {
}

func createInferencePool(numTargetPorts int, toDelete bool) []string {
poolName := simModelName + "-inference-pool"
poolName := testutils.ModelServerName + "-inference-pool"

if toDelete {
objName := []string{"inferencepool/" + poolName}
Expand Down
Loading
Loading