"vscode:/vscode.git/clone" did not exist on "54ab90dd132253631bbabe9eb89babccab6312a2"
Unverified Commit bcfdadb1 authored by Flora Feng's avatar Flora Feng Committed by GitHub
Browse files

[Refactor] Relocate chat completion and anthropic tests (#36919)


Signed-off-by: default avatarsfeng33 <4florafeng@gmail.com>
parent 236de72e
...@@ -34,7 +34,7 @@ steps: ...@@ -34,7 +34,7 @@ steps:
- tests/entrypoints/test_chat_utils - tests/entrypoints/test_chat_utils
commands: commands:
- export VLLM_WORKER_MULTIPROC_METHOD=spawn - export VLLM_WORKER_MULTIPROC_METHOD=spawn
- pytest -v -s entrypoints/openai --ignore=entrypoints/openai/test_chat_with_tool_reasoning.py --ignore=entrypoints/openai/test_oot_registration.py --ignore=entrypoints/openai/test_tensorizer_entrypoint.py --ignore=entrypoints/openai/correctness/ --ignore=entrypoints/openai/tool_parsers/ --ignore=entrypoints/openai/responses - pytest -v -s entrypoints/openai --ignore=entrypoints/openai/chat_completion/test_chat_with_tool_reasoning.py --ignore=entrypoints/openai/test_oot_registration.py --ignore=entrypoints/openai/test_tensorizer_entrypoint.py --ignore=entrypoints/openai/correctness/ --ignore=entrypoints/openai/tool_parsers/ --ignore=entrypoints/openai/responses
- pytest -v -s entrypoints/test_chat_utils.py - pytest -v -s entrypoints/test_chat_utils.py
mirror: mirror:
amd: amd:
......
...@@ -334,7 +334,7 @@ pull_request_rules: ...@@ -334,7 +334,7 @@ pull_request_rules:
- or: - or:
- files~=^tests/tool_use/ - files~=^tests/tool_use/
- files~=^tests/entrypoints/openai/tool_parsers/ - files~=^tests/entrypoints/openai/tool_parsers/
- files=tests/entrypoints/openai/test_chat_with_tool_reasoning.py - files=tests/entrypoints/openai/chat_completion/test_chat_with_tool_reasoning.py
- files~=^vllm/entrypoints/openai/tool_parsers/ - files~=^vllm/entrypoints/openai/tool_parsers/
- files=docs/features/tool_calling.md - files=docs/features/tool_calling.md
- files~=^examples/tool_chat_* - files~=^examples/tool_chat_*
......
...@@ -14,13 +14,12 @@ import requests ...@@ -14,13 +14,12 @@ import requests
import torch import torch
from openai import BadRequestError from openai import BadRequestError
from tests.utils import RemoteOpenAIServer
from vllm.entrypoints.openai.chat_completion.protocol import ( from vllm.entrypoints.openai.chat_completion.protocol import (
ChatCompletionRequest, ChatCompletionRequest,
) )
from vllm.sampling_params import SamplingParams from vllm.sampling_params import SamplingParams
from ...utils import RemoteOpenAIServer
# any model with a chat template should work here # any model with a chat template should work here
MODEL_NAME = "HuggingFaceH4/zephyr-7b-beta" MODEL_NAME = "HuggingFaceH4/zephyr-7b-beta"
......
...@@ -7,10 +7,9 @@ import openai # use the official client for correctness check ...@@ -7,10 +7,9 @@ import openai # use the official client for correctness check
import pytest import pytest
import pytest_asyncio import pytest_asyncio
from tests.utils import RemoteOpenAIServer
from vllm.config import ModelConfig from vllm.config import ModelConfig
from ...utils import RemoteOpenAIServer
# # any model with a chat template should work here # # any model with a chat template should work here
MODEL_NAME = "Qwen/Qwen2-1.5B-Instruct" MODEL_NAME = "Qwen/Qwen2-1.5B-Instruct"
......
...@@ -5,10 +5,9 @@ import openai ...@@ -5,10 +5,9 @@ import openai
import pytest import pytest
import pytest_asyncio import pytest_asyncio
from tests.utils import RemoteOpenAIServer
from vllm.config import ModelConfig from vllm.config import ModelConfig
from ...utils import RemoteOpenAIServer
MODEL_NAME = "Qwen/Qwen2.5-1.5B-Instruct" MODEL_NAME = "Qwen/Qwen2.5-1.5B-Instruct"
......
...@@ -5,7 +5,7 @@ import openai # use the official client for correctness check ...@@ -5,7 +5,7 @@ import openai # use the official client for correctness check
import pytest import pytest
import pytest_asyncio import pytest_asyncio
from ...utils import RemoteOpenAIServer from tests.utils import RemoteOpenAIServer
# a reasoning and tool calling model # a reasoning and tool calling model
MODEL_NAME = "Qwen/QwQ-32B" MODEL_NAME = "Qwen/QwQ-32B"
......
...@@ -10,7 +10,7 @@ import pytest ...@@ -10,7 +10,7 @@ import pytest
import pytest_asyncio import pytest_asyncio
# downloading lora to test lora requests # downloading lora to test lora requests
from ...utils import ROCM_ENV_OVERRIDES, ROCM_EXTRA_ARGS, RemoteOpenAIServer from tests.utils import ROCM_ENV_OVERRIDES, ROCM_EXTRA_ARGS, RemoteOpenAIServer
# any model with a chat template should work here # any model with a chat template should work here
MODEL_NAME = "Qwen/Qwen3-0.6B" MODEL_NAME = "Qwen/Qwen3-0.6B"
......
...@@ -4,7 +4,7 @@ import openai ...@@ -4,7 +4,7 @@ import openai
import pytest import pytest
import pytest_asyncio import pytest_asyncio
from ...utils import RemoteOpenAIServer from tests.utils import RemoteOpenAIServer
@pytest.fixture(scope="module") @pytest.fixture(scope="module")
......
...@@ -10,6 +10,12 @@ import pytest ...@@ -10,6 +10,12 @@ import pytest
import pytest_asyncio import pytest_asyncio
from openai import OpenAI from openai import OpenAI
from tests.entrypoints.openai.utils import (
accumulate_streaming_response,
verify_chat_response,
verify_harmony_messages,
)
from tests.utils import RemoteOpenAIServer
from vllm._aiter_ops import is_aiter_found_and_supported from vllm._aiter_ops import is_aiter_found_and_supported
from vllm.config import MultiModalConfig from vllm.config import MultiModalConfig
from vllm.entrypoints.openai.chat_completion.protocol import ( from vllm.entrypoints.openai.chat_completion.protocol import (
...@@ -39,13 +45,6 @@ from vllm.tokenizers.registry import tokenizer_args_from_config ...@@ -39,13 +45,6 @@ from vllm.tokenizers.registry import tokenizer_args_from_config
from vllm.tool_parsers import ToolParserManager from vllm.tool_parsers import ToolParserManager
from vllm.v1.engine.async_llm import AsyncLLM from vllm.v1.engine.async_llm import AsyncLLM
from ...utils import RemoteOpenAIServer
from .utils import (
accumulate_streaming_response,
verify_chat_response,
verify_harmony_messages,
)
GPT_OSS_MODEL_NAME = "openai/gpt-oss-20b" GPT_OSS_MODEL_NAME = "openai/gpt-oss-20b"
GPT_OSS_SPECULATOR_NAME = "RedHatAI/gpt-oss-20b-speculator.eagle3" GPT_OSS_SPECULATOR_NAME = "RedHatAI/gpt-oss-20b-speculator.eagle3"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment