mirror of
https://github.com/hwchase17/langchain.git
synced 2026-06-09 10:17:00 +00:00
fix(xai): stream usage metadata by default (#34531)
This commit is contained in:
@@ -526,6 +526,11 @@ class ChatXAI(BaseChatOpenAI): # type: ignore[override]
|
||||
**client_params,
|
||||
**async_specific,
|
||||
)
|
||||
|
||||
# Enable streaming usage metadata by default
|
||||
if self.stream_usage is not False:
|
||||
self.stream_usage = True
|
||||
|
||||
return self
|
||||
|
||||
@model_validator(mode="after")
|
||||
|
||||
Reference in New Issue
Block a user