update openai/trl_vllm server with new fn

This commit is contained in:
Dakota 2025-10-16 13:45:55 -05:00
parent c36ec29656
commit 134cbc09d0
3 changed files with 24 additions and 9 deletions

View file

@ -173,7 +173,7 @@ class SGLangServer(APIServer):
import aiohttp
async with aiohttp.ClientSession() as session:
async with session.post(
f"{self.config.base_url}/generate",
f"{self.config.base_url.replace('/v1', '')}/generate",
json=request_data,
headers={"Authorization": f"Bearer {self.config.api_key}"} if self.config.api_key else {},
timeout=aiohttp.ClientTimeout(total=self.config.timeout)