Context
Sales questions need knowledge, context and practical next steps. This project provides quick answers and four-part sales plans, supported by a WeChat Mini Program and a Vue admin console.
Workflow
- User question
- Access-aware retrieval / RRF
- Agent orchestration
- Plan and references
Implementation
Check access before retrieval
Combined PostgreSQL full-text search and pgvector retrieval using RRF. Filtered knowledge entitlements and publication status in SQL so unauthorized content stays out of model context.
Keep generation within defined limits
Restricted available tools, retrieval calls and execution steps by stage. Delivered answers through structured fields and server-resolved references, with clarification and refusal when appropriate.
Resume unfinished work
Used a PostgreSQL task queue and persisted plan sections for staged recovery. Saved request policy snapshots and rechecked access rights when resuming.
Account for usage and credits
Persisted model usage by call ID, handling fallback-model pricing, cancellation and duplicate accounting. Implemented credit reservation, settlement and refunds.
Delivery and scope
The project has a recorded pass of 753 backend non-live regression tests dated 2026-10-07. This is engineering regression evidence, not a measure of model answer accuracy or a production SLA.
Dianhai Wang · Updated