mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-11 08:38:24 +00:00
Fix import ordering in TealTiger guardrail
This commit is contained in:
parent
c63a6d86c1
commit
717d1dd14c
2 changed files with 5 additions and 4 deletions
|
|
@ -14,24 +14,25 @@ from collections.abc import Mapping, Sequence
|
|||
from typing import TYPE_CHECKING, Final, Literal
|
||||
|
||||
from fastapi import HTTPException
|
||||
|
||||
from litellm._logging import verbose_proxy_logger
|
||||
from litellm.integrations.custom_guardrail import (
|
||||
CustomGuardrail,
|
||||
log_guardrail_information, # pyright: ignore[reportUnknownVariableType] # upstream decorator is untyped
|
||||
)
|
||||
from litellm.types.guardrails import GuardrailEventHooks, Mode
|
||||
from litellm.types.utils import GenericGuardrailAPIInputs
|
||||
|
||||
from litellm.types.proxy.guardrails.guardrail_hooks.tealtiger import DEFAULT_POLICIES, Policy, PolicyMode
|
||||
from litellm.types.utils import GenericGuardrailAPIInputs
|
||||
|
||||
from .decision import NO_VIOLATIONS, Action, Decision
|
||||
from .engine import TealEngine
|
||||
from .request import identity_of, tool_name_of
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from pydantic import BaseModel
|
||||
|
||||
from litellm.litellm_core_utils.litellm_logging import Logging as LiteLLMLoggingObj
|
||||
from litellm.types.proxy.guardrails.guardrail_hooks.base import GuardrailConfigModel
|
||||
from pydantic import BaseModel
|
||||
|
||||
|
||||
def _to_event_hook(
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ from unittest.mock import patch
|
|||
|
||||
import pytest
|
||||
from fastapi import HTTPException
|
||||
from litellm.types.guardrails import GuardrailEventHooks
|
||||
from pydantic import ValidationError
|
||||
|
||||
from litellm.proxy.guardrails.guardrail_hooks.tealtiger import budget as budget_module
|
||||
|
|
@ -21,6 +20,7 @@ from litellm.proxy.guardrails.guardrail_hooks.tealtiger.request import (
|
|||
tool_name_of,
|
||||
)
|
||||
from litellm.proxy.guardrails.guardrail_hooks.tealtiger.tealtiger import TealTigerGuardrail, _to_event_hook
|
||||
from litellm.types.guardrails import GuardrailEventHooks
|
||||
from litellm.types.proxy.guardrails.guardrail_hooks.tealtiger import (
|
||||
DEFAULT_POLICIES,
|
||||
CostPolicy,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue