Skip to content

Commit

Permalink
remove conflict info data in router.py
Browse files Browse the repository at this point in the history
Signed-off-by: sitloboi2012 <[email protected]>
  • Loading branch information
sitloboi2012 committed Feb 13, 2025
1 parent 2df3e8c commit 37f12e7
Showing 1 changed file with 1 addition and 26 deletions.
27 changes: 1 addition & 26 deletions src/vllm_router/router.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,12 +158,7 @@ async def route_general_request(request: Request, endpoint: str):
)


<<<<<<< HEAD
@app.post("/v1/files")
=======
# --- File Endpoints ---
@app.post("/files")
>>>>>>> 2ba572e (run pre-commit for linting)
async def route_files(request: Request):
"""Handle file upload requests that include a purpose and file data."""
form = await request.form()
Expand All @@ -189,11 +184,7 @@ async def route_files(request: Request):
)


<<<<<<< HEAD
@app.get("/v1/files/{file_id}")
=======
@app.get("/files/{file_id}")
>>>>>>> 2ba572e (run pre-commit for linting)
async def route_get_file(file_id: str):
try:
file = await FILE_STORAGE.get_file(file_id)
Expand All @@ -204,11 +195,7 @@ async def route_get_file(file_id: str):
)


<<<<<<< HEAD
@app.get("/v1/files/{file_id}/content")
=======
@app.get("/files/{file_id}/content")
>>>>>>> 2ba572e (run pre-commit for linting)
async def route_get_file_content(file_id: str):
try:
# TODO: Stream file content in chunks to support large files.
Expand All @@ -220,21 +207,12 @@ async def route_get_file_content(file_id: str):
)


<<<<<<< HEAD
@app.post("/v1/chat/completions")
=======
# --- API Endpoints ---
@app.post("/chat/completions")
>>>>>>> 2ba572e (run pre-commit for linting)
async def route_chat_completition(request: Request):
return await route_general_request(request, "/v1/chat/completions")


<<<<<<< HEAD
@app.post("/v1/completions")
=======
@app.post("/completions")
>>>>>>> 2ba572e (run pre-commit for linting)
async def route_completition(request: Request):
return await route_general_request(request, "/v1/completions")

Expand All @@ -245,11 +223,7 @@ async def show_version():
return JSONResponse(content=ver)


<<<<<<< HEAD
@app.get("/v1/models")
=======
@app.get("/models")
>>>>>>> 2ba572e (run pre-commit for linting)
async def show_models():
endpoints = GetServiceDiscovery().get_endpoint_info()
existing_models = set()
Expand Down Expand Up @@ -289,6 +263,7 @@ async def health() -> Response:
async def metrics():
return Response(generate_latest(), media_type="text/plain")


# --- Prometheus Metrics Endpoint (v2 observation/tracking) ---
@app.get("/metrics")
async def metrics():
Expand Down

0 comments on commit 37f12e7

Please sign in to comment.