# Which client should I use?

**URL:** <https://discuss.vllm.ai/t/which-client-should-i-use/2113>\
**Category:** General\
**Created:** [December 12, 2025, 11:15am UTC](https://discuss.vllm.ai/t/which-client-should-i-use/2113 "2025-12-12T11:15:56Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Septemberlemon](https://yyz2.discourse-cdn.com/flex036/user_avatar/discuss.vllm.ai/septemberlemon/32/915_2.png) [@Septemberlemon](https://discuss.vllm.ai/u/Septemberlemon)\
**Post date:** [December 12, 2025, 11:15am UTC](https://discuss.vllm.ai/t/which-client-should-i-use/2113/1 "2025-12-12T11:15:56Z")

</div>

I used to use langchain as the client, but it does not support looking `stop_reason` field so I had to give up it  
what should I use now, openai python lib?  
r there any recommended clients for vllm?

---

<div class="post-metadata">

**Author:** ![RunLLM](https://yyz2.discourse-cdn.com/flex036/user_avatar/discuss.vllm.ai/runllm/32/233_2.png) [@RunLLM](https://discuss.vllm.ai/u/RunLLM)\
**Post date:** [December 12, 2025, 11:16am UTC](https://discuss.vllm.ai/t/which-client-should-i-use/2113/2 "2025-12-12T11:16:22Z")

</div>

The recommended client for vLLM is the official OpenAI Python client, as vLLM’s OpenAI-compatible server is designed to work seamlessly with it and supports all relevant response fields, including stop\_reason and finish\_reason. You can use the OpenAI client by setting the api\_key and base\_url to your vLLM server; see the [official example](https://docs.vllm.ai/en/latest/getting_started/examples/openai_completion_client.html). LangChain is also supported via its OpenAI-compatible integration, but as you noted, it may not expose all fields like stop\_reason directly in its API ([discussion](https://github.com/vllm-project/vllm/issues/716)).

If you need full access to all OpenAI response fields, including stop\_reason, the OpenAI Python client is the most reliable choice. For benchmarking or advanced usage, you can also use HTTP clients like requests or aiohttp, as shown in vLLM’s [benchmarking scripts](https://github.com/vllm-project/vllm/issues/7935). Would you like more detail or code examples?

Sources:

- [OpenAI Completion Client — vLLM](https://docs.vllm.ai/en/latest/getting_started/examples/openai_completion_client.html)
- [Langchain Support](https://github.com/vllm-project/vllm/issues/716)
- [Performance: 5x slower throughput with openAI client/server than native one](https://github.com/vllm-project/vllm/issues/7935)

Hint: Mention @RunLLM in the post for followups.

---

<div class="post-metadata">

**Author:** ![hackyroot](https://yyz2.discourse-cdn.com/flex036/user_avatar/discuss.vllm.ai/hackyroot/32/647_2.png) [@hackyroot](https://discuss.vllm.ai/u/hackyroot)\
**Post date:** [December 16, 2025, 5:10am UTC](https://discuss.vllm.ai/t/which-client-should-i-use/2113/3 "2025-12-16T05:10:32Z")

</div>

Thanks to it’s wider compatibility, I’d suggest using OpenAI Python SDK. vLLM already comes with OpenAI server so that also helps.
