When this decision has to be made
When your enterprise builds multi-turn dialogue applications—including customer service assistants, knowledge base QA Agents, tool-calling workflows, and similar scenarios—this decision becomes a critical consideration. Making this decision too early, such as overly restricting history passing rules during the application prototype phase, can lead to an inability to adapt to complex multi-turn interaction needs later, requiring core logic refactoring. Making it too late can result in issues like missing context, high response latency, or excessive token consumption after launch, forcing emergency adjustments to API parameters and storage configurations, which may cause user experience fluctuations. You must clarify chat history handling when the application needs to support continuous user follow-up questions, referential prompts (such as “What about the second point?”), or generate customized responses based on historical conversations. Additionally, when the application integrates plugins or workflow nodes, you need to distinguish history passing rules across scenarios to avoid parameter conflicts or inconsistent context.
Criteria matrix
| Candidate Approach | Context Completeness | API Request Load | Session Storage Usage | Multi-turn Referential Consistency | Plugin/Workflow Compatibility | Debug Complexity |
|---|---|---|---|---|---|---|
| Pass only the current user message | Only the current question, no context | Lowest, only a single message | Stores only single-request data, no historical storage | Cannot handle referential questions | Compatible with all scenarios, no extra parameters needed | Low |
| Pass a fixed number of historical messages | Determined by the number of passed rounds, configurable | Increases with more rounds, limited by the model’s maximum context window | Application manages historical storage independently | Must ensure passed rounds cover referential needs | Plugins do not require messages; adjust logic as needed | Medium |
| Use chatId to associate session context | Platform automatically manages all history, configurable memory rounds | Lowest, only passes current message and chatId | Platform centrally manages session history | High, platform automatically maintains context | Plugins do not require chatId; distinguish scenarios as needed | Medium |
| Truncate history to a specified token threshold | Retains history with the specified token count after truncation, may lose critical information | Determined by post-truncation token count, limited by model’s maximum context window | Application manages truncated history independently | Must ensure truncated history retains critical context | Consistent with the passed messages approach | Medium |
| Hybrid mode: Pass critical context via variables, manage remaining history via the platform | Balances critical information and platform-managed history | Lower than fixed rounds approach, higher than pass only current message approach | Platform manages most history, variable context requires extra storage | High, critical context is explicitly passed | Compatible with plugin and workflow scenarios | Higher |
Why each criterion matters
Context completeness is the core foundation of multi-turn dialogue. When a user asks a referential question such as “What about the second point?”, the AI cannot identify the referent without sufficient historical context, leading to responses that deviate from requirements. The pass only current message approach cannot support such scenarios, while approaches using chatId or fixed rounds of historical messages can cover most referential needs via configuration. The platform’s default chat history length is 6 rounds; you can adjust the memory rounds based on scenarios, with larger values covering a wider historical range but increasing resource consumption.
API request load directly impacts application response speed and call costs. Passing large volumes of historical messages increases the size of the request payload, prolonging network transmission time, while the model must process more context tokens, increasing call duration and consumption. The pass only current message approach has the lowest load but cannot support multi-turn interaction; the chatId approach only passes the current message and session identifier, resulting in the smallest load, making it suitable for high-concurrency scenarios. Official documentation explicitly requires chatId length to be less than 250; you can generate compliant identifiers via custom system dialog IDs.
Session storage usage relates to system resource consumption and operational costs. The pass only current message approach requires no historical session storage, resulting in minimal storage pressure but no way to recover ended session context. The fixed rounds approach requires the application to independently maintain historical storage, with storage pressure increasing as the number of sessions grows. The chatId approach has the platform centrally manage session storage, but you still need to monitor storage resource scaling needs when session volume is large.
Multi-turn referential consistency determines the user experience of continuous dialogue. When a user follows up with multiple questions, the AI must accurately understand the referent of each question—for example, first asking “Terms of the rental contract” then following up with “Breach of contract terms therein”—which relies on complete historical context. The chatId approach, where the platform automatically maintains context, better ensures consistency. The fixed rounds approach requires ensuring the passed rounds sufficiently cover referential needs, otherwise understanding errors may occur.
Plugin/workflow compatibility is critical for scenario adaptation. In plugin calling scenarios, official documentation explicitly requires no chatId or messages to be passed, only input parameters via variables. Thus, the pass only current message or chatId approaches are better suited for plugin scenarios. For functions like variable references and loop processing in workflow nodes, variable passing is required to retrieve values; historical messages are not useful here, so hybrid or variable-passing approaches better adapt to complex workflow scenarios.
Debug complexity impacts the efficiency of issue troubleshooting. The pass only current message approach requires no history maintenance, so you can directly view single-request content during debugging, resulting in the lowest troubleshooting difficulty. The chatId approach requires viewing session history stored on the platform, so you need to associate session identifiers to retrieve full context during debugging. The fixed rounds approach requires verifying that each passed historical content is correct, resulting in medium debug complexity.
The cost of switching later
Switching chat history passing schemes incurs multi-dimensional costs. When switching from passing only the current message to using chatId to associate session context, you need to migrate existing session data, modify API request parameters to pass chatId, adjust application logic to adapt to the platform’s automatically managed history, and verify multi-turn dialogue consistency. This may require a short downtime window for configuration updates and data migration. If using the authProxy feature in FastGPT >=v4.15.0, you also need to adjust key configurations to support proxy authentication.
When switching from using chatId to passing a fixed number of historical messages, you need to modify application logic to independently maintain and pass historical sessions, calculate token consumption for each request to ensure it does not exceed the model’s maximum context limit, and adjust storage configurations to save historical data. This may lead to increased API request load, requiring optimization of front-end or gateway request processing logic. Additionally, you must ensure the passed messages array conforms to the official documentation’s GPT interface format to avoid parameter errors.
When switching from passing fixed rounds of historical messages to hybrid mode, you need to refactor the application’s context management logic, pass critical context information via variables, and leave the remaining history to the platform. You must verify the accuracy of variable passing to avoid referential errors, adjust plugin and workflow configurations to ensure correct variable parameter passing, resulting in a large amount of validation work. All switching operations require multi-scenario testing, including single-turn dialogue, multi-turn follow-up questions, plugin calls, and workflow execution, to ensure post-switch application functionality and performance meet expectations, avoiding user experience fluctuations or system exceptions.
When this decision can wait
You can delay this decision when the application only supports single-turn dialogue scenarios. For example, simple single-turn QA robots, one-time tool-calling requests, etc.—no session history maintenance is needed, and passing only the current user message meets requirements. You can temporarily avoid clarifying chat history handling rules when the application is in internal testing, only used for function validation, and multi-turn interaction needs have not been considered, adjusting before official launch based on scenario requirements.
You can also delay the decision when the application has an extremely short session lifecycle, such as one-time form filling, temporary consultations, etc.—no session history needs to be saved, and you can directly use the pass only current message approach without extra configuration. If the application already manages session history via an external caching system and does not rely on the platform’s chatId function or independent history passing, you can temporarily skip this decision, adjusting only when you need to optimize resource consumption or simplify logic. Additionally, when the application only targets plugin calling scenarios, and official documentation explicitly requires no chatId or messages to be passed, you can directly use the variable passing approach without extra consideration of chat history passing rules.
Keep reading
- Moving Apps Between Environments: What Export, Templates and Copies Carry Over
- Deployment Architecture: Images and Trade-offs on x86 and ARM Servers
References
Next steps
The criteria above can be checked against public documentation and a test deployment. To decide against a specific workload, data boundary and operations setup, contact sales for an assessment; the cloud service can be used first to validate feasibility before choosing a deployment form.
- Contact sales: assess the choice against your conditions
- Get started: validate feasibility on the cloud service
- Pricing: compare what each form covers
Criteria taken from the open-source repository and community threads, verified 2026-09-28.