Import ClientFlow production v4928.1.5.132.4

This commit is contained in:
plx
2026-07-29 13:11:01 +00:00
parent 6445044ac6
commit 261d342057
405 changed files with 48373 additions and 1401 deletions

View File

@@ -1,6 +1,6 @@
from typing import Any, Dict, Optional
from pydantic import BaseModel, Field
from pydantic import BaseModel, Field, field_validator
class CurrentState(BaseModel):
@@ -19,11 +19,23 @@ class AnalyzeRequest(BaseModel):
conversation_id: Optional[str] = None
contact_id: Optional[str] = None
@field_validator("last_customer_message")
@classmethod
def _non_blank_customer_message(cls, value: str) -> str:
if not str(value or "").strip():
raise ValueError("last_customer_message não pode estar vazio")
return value
class ActionDecision(BaseModel):
action_code: str
note: str = ""
confidence: float = Field(ge=0.0, le=1.0, default=0.0)
customer_intent: str = ""
evidence: str = ""
needs_human_review: bool = False
history_used: bool = False
payment_intent: Optional[str] = None
class ActionResult(BaseModel):