delete the default model value from langchain and discard the need fo… (#24915)

- description: I remove the limitation of mandatory existence of
`QIANFAN_AK` and default model name which langchain uses cause there is
already a default model nama underlying `qianfan` SDK powering langchain
component.

---------

Co-authored-by: Chester Curme <chester.curme@gmail.com>
This commit is contained in:
Dobiichi-Origami
2024-08-06 22:11:05 +08:00
committed by GitHub
parent 293a4a78de
commit 061ed250f6
4 changed files with 15 additions and 12 deletions

View File

@@ -306,7 +306,10 @@ def test_functions_call() -> None:
def test_rate_limit() -> None:
chat = QianfanChatEndpoint(model="ERNIE-Bot", init_kwargs={"query_per_second": 2}) # type: ignore[call-arg]
assert chat.client._client._rate_limiter._sync_limiter._query_per_second == 2
assert (
chat.client._client._rate_limiter._internal_qps_rate_limiter._sync_limiter._query_per_second
== 1.8
)
responses = chat.batch(
[
[HumanMessage(content="Hello")],