fix(watsonx.py): fix watson process response

Fixes https://github.com/BerriAI/litellm/issues/4654
This commit is contained in:
Krrish Dholakia 2024-07-11 09:34:46 -07:00
parent b5a00722bc
commit 8fa2cf15ee
2 changed files with 23 additions and 19 deletions

View file

@ -624,10 +624,6 @@ class ModelResponse(OpenAIObject):
# Allow dictionary-style access to attributes
return getattr(self, key)
def __setitem__(self, key, value):
# Allow dictionary-style assignment of attributes
setattr(self, key, value)
def json(self, **kwargs):
try:
return self.model_dump() # noqa