Metadata-Version: 2.4
Name: vllm-grpc-client
Version: 0.1.0
Summary: Lean async gRPC client for the vllm-grpc frontend
Project-URL: Homepage, https://github.com/AncientStudying/vllm-grpc
Project-URL: Repository, https://github.com/AncientStudying/vllm-grpc
Project-URL: Issues, https://github.com/AncientStudying/vllm-grpc/issues
Project-URL: Changelog, https://github.com/AncientStudying/vllm-grpc/blob/main/CHANGELOG.md
Author-email: AncientStudying <bsansom@gmail.com>
License-Expression: MIT
Keywords: client,grpc,inference,llm,vllm
Classifier: Development Status :: 4 - Beta
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Requires-Python: >=3.12
Requires-Dist: grpcio>=1.80
Requires-Dist: vllm-grpc-gen~=0.1.0
Description-Content-Type: text/markdown

# vllm-grpc-client

A lean async gRPC client for the [vllm-grpc](https://github.com/AncientStudying/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

```bash
pip install vllm-grpc-client
```

## Usage

```python
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
