mirror of
https://git.datalinker.icu/vllm-project/vllm.git
synced 2026-04-06 11:17:02 +08:00
run format.sh
Signed-off-by: clark <panf2333@gmail.com>
This commit is contained in:
parent
27c1afe88b
commit
8fa9df7987
@ -61,6 +61,7 @@ async def test_connect_completions(session):
|
||||
except aiohttp.ClientError as e:
|
||||
print(f"Error: {e}")
|
||||
|
||||
|
||||
def is_json(data):
|
||||
try:
|
||||
json.loads(data)
|
||||
@ -68,6 +69,7 @@ def is_json(data):
|
||||
except ValueError:
|
||||
return False
|
||||
|
||||
|
||||
def extract_data(responseText):
|
||||
reply = ""
|
||||
if responseText == "":
|
||||
|
||||
@ -113,6 +113,7 @@ async def generate_stream_response(fisrt_reply: str,
|
||||
async for _, reply in generator:
|
||||
yield reply
|
||||
|
||||
|
||||
async def prefill(route: str, header: dict, original_request_data: dict):
|
||||
logger.info("start prefill")
|
||||
generator = execute_task_async(route, header, original_request_data,
|
||||
@ -124,7 +125,8 @@ async def prefill(route: str, header: dict, original_request_data: dict):
|
||||
response.status_code = 500
|
||||
return response
|
||||
return True
|
||||
|
||||
|
||||
|
||||
async def decode(route: str, header: dict, original_request_data: dict):
|
||||
logger.info("start decode")
|
||||
generator = execute_task_async(route, header, original_request_data,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user