Data Characteristics
Infectious disease regulations and SOPs primarily originate from national health commissions and disease control centers, including diagnostic guidelines and prevention plans. Hospital-internal infection control manuals and emergency plans also contribute. These documents update frequently, especially with new pathogens or outbreaks. Document structures typically include chapters, specific clauses, definitions, flowcharts, and tables. Fields often cover pathogen names, diagnostic criteria, treatment plans, isolation measures, reporting deadlines, and disinfection methods. Data units include time (e.g., "hours," "days"), concentration (e.g., "mg/L"), quantity (e.g., "cases"), and frequency (e.g., "times/day").
Constraints on Tool Calling and Plugins
The high update frequency of infectious disease regulations requires tool calling to support dynamic data source integration, ensuring information retrieval is current. The extensive use of specialized medical terminology, diagnostic criteria, and treatment protocols in documents makes accurate understanding of user intent and corresponding tool invocation critical. For example, queries about "antibiotic sensitivity" may require calling a specific tool to query resistance profiles. Highly normative content, such as reporting deadlines and isolation measures, requires tools to accurately extract and present specific numerical values, avoiding vague answers. The presence of flowcharts and tables means tools need some ability to parse structured information to cite or explain complex information in responses.
Configuration Settings
| Configuration Item | Recommended Value | Rationale |
|---|---|---|
maxContext | 3000 characters | Infectious disease SOP texts are long; ensure context completeness. |
Recall count | 8 entries | Increase recall to cover more relevant regulatory clauses. |
Similarity threshold | 0.75 | Ensure recalled regulatory clauses are highly relevant to user queries. |
Rerank result count | 5 entries | Optimize ranking results to prioritize the most matching regulatory content. |
PARSE_FILE_TIMEOUT_SECONDS | 600 seconds | Parsing large regulatory documents takes time; prevent timeout interruptions. |
Chunk size | 800–1200 characters | Balance semantic completeness and retrieval efficiency, adapting to long texts. |
Common Pitfalls
- Symptom: The system fails to accurately identify diagnostic criteria for specific pathogens in user queries, even when relevant regulatory documents are imported. Reason: The tokenizer's ability to recognize specialized medical terms is insufficient, leading to loss of key information during index creation.
- Symptom: A user asks about "isolation measures for a certain disease," but the returned result does not provide specific isolation days or conditions for discharge. Reason: Tool calling fails to accurately parse structured data in tables or lists within regulatory documents, leading to the omission of key numerical information.
- Symptom: After a user query, FastGPT does not call any plugins, directly providing a generic answer. Reason: The
tool_codedefinition's trigger conditions are too broad or do not match user intent well enough to trigger specific plugin execution.
Verification
- For core disease types, simulate user queries about diagnosis, treatment, and isolation. Check if the system accurately cites original regulatory text.
- Test regulatory documents containing complex structured information like tables and flowcharts. Verify if tools can parse and extract key numerical values and steps.
- Create queries strongly related to plugin functionality. Observe if FastGPT successfully triggers and executes corresponding tools and returns expected results.
- Check log output to confirm if
tool_codetrigger logic works as expected for specific queries and if tool-returned data is processed correctly.
The values provided are common starting points and should be measured against specific 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-09-21.