mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-05 02:41:56 +00:00
lint
This commit is contained in:
parent
f2cae338a1
commit
3a9f8ce14a
1 changed files with 8 additions and 2 deletions
|
|
@ -772,11 +772,17 @@ def _extract_chain_output(
|
|||
field_value = response_obj_dict.get(field)
|
||||
text = _coerce_text(field_value)
|
||||
if text:
|
||||
return text, ("application/json" if isinstance(field_value, (list, dict)) else None)
|
||||
return text, (
|
||||
"application/json"
|
||||
if isinstance(field_value, (list, dict))
|
||||
else None
|
||||
)
|
||||
|
||||
content = response_obj_dict.get("content")
|
||||
if content:
|
||||
return _coerce_text(content), ("application/json" if isinstance(content, (list, dict)) else None)
|
||||
return _coerce_text(content), (
|
||||
"application/json" if isinstance(content, (list, dict)) else None
|
||||
)
|
||||
|
||||
# 4. Reranker results
|
||||
results = response_obj_dict.get("results")
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue