添加rag置信度判断
Some checks failed
构建并部署 AI Agent 服务 / deploy (push) Failing after 6m31s

This commit is contained in:
2026-05-06 01:15:52 +08:00
parent 3ae9daa01a
commit 1260bef5cb
35 changed files with 335 additions and 221 deletions

View File

@@ -9,7 +9,7 @@ warnings.filterwarnings("ignore", category=DeprecationWarning, module="websocket
warnings.filterwarnings("ignore", category=DeprecationWarning, module="uvicorn.protocols.websockets")
import os
from ..config import DB_URI, BACKEND_PORT
from backend.app.config import DB_URI, BACKEND_PORT
import uuid
import json
from contextlib import asynccontextmanager
@@ -22,18 +22,18 @@ from pydantic import BaseModel
from langgraph.checkpoint.postgres.aio import AsyncPostgresSaver
from .agent.agent_service import AIAgentService, create_serde
from .agent.history import ThreadHistoryService
from ..core.human_review import (
from backend.app.core.human_review import (
ReviewManager,
InMemoryReviewStore,
ReviewStatus,
HumanReview
)
from ..subgraphs.contact.api_client import ContactAPIClient
from ..subgraphs.dictionary.api_client import DictionaryAPIClient
from ..subgraphs.news_analysis.api_client import NewsAPIClient
from backend.app.subgraphs.contact.api_client import ContactAPIClient
from backend.app.subgraphs.dictionary.api_client import DictionaryAPIClient
from backend.app.subgraphs.news_analysis.api_client import NewsAPIClient
from .db.init_db import init_subgraph_tables
from .db.models import ContactRepository, DictionaryRepository, NewsRepository
from ..logger import info, error
from backend.app.logger import info, error
@asynccontextmanager
async def lifespan(app: FastAPI):