Chirag0123's picture
v2.0 — agent reliability & evaluation layer
a5c1fa0
Raw
History Blame Contribute Delete
407 Bytes
"""Utility functions for the auth module."""
def sanitize_input(text: str) -> str:
"""Remove leading/trailing whitespace and normalize."""
if not isinstance(text, str):
return ""
return text.strip().lower()
def format_response(status: str, data: dict = None) -> dict:
"""Format a standard API response."""
return {
"status": status,
"data": data or {},
}