What the data for this use case looks like
Data for this use case comes from advertising platform backends, customer qualification systems, contract systems, and publicly available regulatory rules. Daily processed documents include advertising review forms, qualification attachments, delivery records, and rectification notices. Data update cycles follow individual marketing campaigns or monthly periods. Each entry is linked to specific delivery behaviors, compliance review steps, and rectification matters, and includes fields such as delivery time periods, review numbers, qualification validity periods, and rectification status. Qualification attachments use individual files as the basic unit, while delivery records use individual delivery behaviors as the basic unit.
Constraints imposed by these characteristics on deployment and upgrade
Data sources for this use case are scattered and linked to core compliance processes. Stability of data storage and service calls must be prioritized during deployment and upgrade. Data volume updates follow individual campaigns or monthly cycles, leading to fluctuations. Reasonable database connection pool parameters must be configured to adapt to peak loads, preventing connection exhaustion that causes failed writes of compliance data. Compliance logging data cannot be lost. Database connection interruptions must be avoided during deployment and upgrades, and connectivity to storage services must be verified in advance. Internal tickets and operations Q&A rely on the AI Proxy service. The App/Admin server must be configured with AIPROXY_API_ENDPOINT (the root address of the AI Proxy service, for example http://aiproxy:3000, do not append paths such as /v1) and a non-empty AIPROXY_API_TOKEN (AI Proxy admin token, must match the configuration on the AI Proxy server). Missing these configurations will cause startup verification failures. Storage of qualification attachments must meet compliance traceability requirements. Relevant file storage parameters must be correctly configured to ensure normal access and retention of data.
How to set configurations
These configurations apply to FastGPT v4.17.0.
| Configuration Item | Recommended Setting | Rationale |
|---|---|---|
MONGODB_URI | mongodb://admin:securepass@db-host:27017/fastgpt_compliance?authSource=admin | Stores structured compliance data such as advertising review forms and delivery records, requires specifying an authentication source and dedicated business database |
DB_MAX_LINK | 20–30 connections | Adapts to peak data write requests during monthly or campaign cycles, prevents connection pool exhaustion from impacting compliance data storage |
REDIS_URL | redis://:redispass@redis-host:6379/0 | Caches ticket Q&A context and compliance rules, reduces repeated query load on structured databases |
STORAGE_S3_ENDPOINT | http://internal-storage.example.com:9000 | Stores unstructured files such as qualification attachments and rectification notices, must match the root address of the internal compliance file storage service |
FILE_TOKEN_KEY | Determined via actual testing | Used to generate access tokens for qualification attachments, must match the signature key of the file storage service to ensure traceable access to compliance data |
FE_DOMAIN | https://compliance-ops.your-domain.com | Configures the access domain for internal operations and ticket interfaces, ensures correct routing for compliance-related operations |
Three common mistakes
- Troubleshooting item: If startup errors indicate missing
AIPROXY_API_ENDPOINTorAIPROXY_API_TOKEN, verify whether these two required environment variables have not been configured on the App/Admin server, or if they were incorrectly entered in non-server deployment configuration locations such as the model management page or workflow global variables. - Symptom: Custom compliance Q&A configuration content does not appear after local packaging and deployment. Cause: Environment variable placeholders were not correctly replaced during packaging, or the latest environment variable configuration file was not loaded during deployment.
- Symptom: Configuration incompatibility errors occur after attempting version downgrade. Cause: Gradual downgrade was not performed according to official version notes, and direct overwriting deployment caused environment variables to mismatch the validation rules of the older version.
How to confirm configurations are correct
- Check the App/Admin server startup logs to confirm there are no validation failure errors related to database connections or AI Proxy connections.
- Upload a test qualification attachment to confirm the file can be stored normally and accessed normally via the generated access token link.
- Submit an internal ticket to test compliance-related Q&A to confirm the service can normally call upstream models to return compliance-related responses.
- View database connection pool monitoring metrics to confirm the current active connection count does not exceed the threshold set by the
DB_MAX_LINKconfiguration.
The values provided are common starting points and should be evaluated against local deployment samples.
Question material comes from public community discussions. Configuration values are common starting points and should be measured against your own samples. Verified on 2026-10-19.