MD

Architectural Recommendation & Flow

Decision: Yes β€” Separate the Knowledge Base ingestion/retrieval pipeline from the AI agents.

Do not make RAG a normal "tool" owned by srcsingle or srcflow. Make it a first-class platform subsystem:

graph TD A[Agent Runtime] -->|Retrieve Context| B(KB Retrieval Service) B --> C[(Qdrant Vector DB)] B --> D[(MySQL Metadata)] E[Ingestion Workers] -->|Store Vectors| C

Key Implementation Subsystems

  • KB Management API: Clean REST/gRPC endpoints
  • Ingestion Workers: Asynchronous chunking and embedding pipeline
  • Retrieval Service: High-speed hybrid vector search
  • Vector Storage: Scalable Qdrant instance

"Use logical decoupling first, then physical service extraction later."

Component Responsibility Tech Stack
Agent Engine Execution & Tool Calling FastAPI / Python
Vector Index High-dim Similarity Search Qdrant
Metadata Schemas & Versioning MySQL
156 Words1030 Characters~1 min read
Client-side Markdown & Mermaid Engine