litellm-mirror/litellm/proxy/_experimental/post_call_rules.py
2023-12-25 14:11:20 +05:30

4 lines
170 B
Python

def my_custom_rule(input): # receives the model response
# if len(input) < 5: # trigger fallback if the model response is too short
return False
return True