feat: add spark v2 support (#885)
This commit is contained in:
parent
c4d759dfba
commit
f42e7d1a61
5 changed files with 31 additions and 7 deletions
|
|
@ -1,5 +1,4 @@
|
|||
import decimal
|
||||
from functools import wraps
|
||||
from typing import List, Optional, Any
|
||||
|
||||
from langchain.callbacks.manager import Callbacks
|
||||
|
|
@ -19,6 +18,7 @@ class SparkModel(BaseLLM):
|
|||
def _init_client(self) -> Any:
|
||||
provider_model_kwargs = self._to_model_kwargs_input(self.model_rules, self.model_kwargs)
|
||||
return ChatSpark(
|
||||
model_name=self.name,
|
||||
streaming=self.streaming,
|
||||
callbacks=self.callbacks,
|
||||
**self.credentials,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue