mirror of
https://github.com/NousResearch/atropos.git
synced 2026-04-26 17:13:09 +00:00
Merge branch 'main' into sid/verifiers
This commit is contained in:
commit
7f28c52994
18 changed files with 1869 additions and 90 deletions
|
|
@ -12,7 +12,11 @@ from pydantic_cli import FailedExecutionException
|
|||
from transformers import AutoTokenizer
|
||||
|
||||
from atroposlib.envs.constants import NAMESPACE_SEP, OPENAI_NAMESPACE
|
||||
from atroposlib.envs.server_handling.server_baseline import APIServer, APIServerConfig
|
||||
from atroposlib.envs.server_handling.server_baseline import (
|
||||
APIServer,
|
||||
APIServerConfig,
|
||||
ReasoningConfig,
|
||||
)
|
||||
|
||||
|
||||
class VLLMServer(APIServer):
|
||||
|
|
@ -20,14 +24,18 @@ class VLLMServer(APIServer):
|
|||
VLLM server handling.
|
||||
"""
|
||||
|
||||
def __init__(self, config: APIServerConfig):
|
||||
def __init__(
|
||||
self,
|
||||
config: APIServerConfig,
|
||||
reasoning_config: ReasoningConfig = None,
|
||||
):
|
||||
self.openai = openai.AsyncClient(
|
||||
api_key=config.api_key,
|
||||
base_url=config.base_url,
|
||||
timeout=config.timeout,
|
||||
)
|
||||
self.tokenizer = AutoTokenizer.from_pretrained(config.model_name)
|
||||
super().__init__(config)
|
||||
super().__init__(config, reasoning_config=reasoning_config)
|
||||
|
||||
async def check_server_status_task(self, chat_completion: bool = True):
|
||||
while True:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue