Lean async gRPC client for the vllm-grpc frontend
Project description
vllm-grpc-client
A lean async gRPC client for the vllm-grpc
frontend. It speaks the project's protobuf ChatService and CompletionsService
directly over gRPC — no web-server stack, no fastapi/uvicorn pulled in. The
generated stubs (vllm-grpc-gen) install transitively.
Affiliation: vllm-grpc is an independent, community project and is not affiliated with, endorsed by, or sponsored by the vLLM project. "vLLM" is used here only to identify the inference engine this project works with.
Install
pip install vllm-grpc-client
Usage
import asyncio
from vllm_grpc_client import VllmGrpcClient
async def main() -> None:
async with VllmGrpcClient("localhost:50051") as client:
result = await client.chat.complete(
messages=[{"role": "user", "content": "Hello!"}],
model="Qwen/Qwen3-0.6B",
max_tokens=64,
)
print(result.content)
asyncio.run(main())
client.completions.complete(...) and the streaming variants
(client.chat.complete_stream(...), client.completions.complete_stream(...))
follow the same shape.
Links
- Repository: https://github.com/AncientStudying/vllm-grpc
- Changelog: https://github.com/AncientStudying/vllm-grpc/blob/main/CHANGELOG.md
- Issues: https://github.com/AncientStudying/vllm-grpc/issues
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file vllm_grpc_client-0.1.0.tar.gz.
File metadata
- Download URL: vllm_grpc_client-0.1.0.tar.gz
- Upload date:
- Size: 6.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b8c7d3d6109cf659ca5560438594497a9dfa81d7bdbb32b0ffda5f342f06f13a
|
|
| MD5 |
1fe029e8f2b78cd3a50f9cf46c8a7289
|
|
| BLAKE2b-256 |
53e3771889868b307496886950f2bc1fa39d4dd6c81dae0a071e0d1a7871d3e9
|
File details
Details for the file vllm_grpc_client-0.1.0-py3-none-any.whl.
File metadata
- Download URL: vllm_grpc_client-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d373fc5c7c5e480b4aea38cb85d5d401c867fa0efd47daa506ca0625c511436b
|
|
| MD5 |
f71d9777f2fc7ebf6354102c2b9c7339
|
|
| BLAKE2b-256 |
a6699752b451aa677c3f94e730bc8a6879542129b79525d0facca3e3bc077285
|