CN-121983342-A - Epidemic disease prediction method and device based on large language model
Abstract
The invention provides a epidemic prediction method and a device based on a large language model, and relates to the technical field of artificial intelligence, wherein the method comprises the steps of acquiring initial environment data in a preset simulation environment and initial state data of a plurality of preset intelligent agents; generating initial context information based on initial environment data and initial state data, generating initial prompt words by combining a thinking chain action prompt strategy, inputting the initial prompt words into a large language model to obtain initial action instructions, repeatedly executing iteration steps for preset times to update the initial environment data, the initial state data and the initial action instructions to obtain corresponding intermediate environment data, intermediate state data and intermediate action instructions, and carrying out nonlinear fitting on epidemic propagation states in a preset time period based on the intermediate environment data to obtain epidemic prediction results. According to the epidemic disease prediction method and device based on the large language model, the accuracy of predicting the epidemic disease propagation state is improved.
Inventors
- WANG SHANRUI
- LIU HUIYONG
Assignees
- 北京信息科技大学
Dates
- Publication Date
- 20260505
- Application Date
- 20251224
Claims (10)
- 1. An epidemic prediction method based on a large language model, comprising the steps of: acquiring initial environment data in a preset simulation environment and initial state data of a plurality of preset agents, wherein the preset agents are used for representing organization units or individual units in a real physical world; generating initial context information based on the initial environment data and the initial state data; generating an initial prompt word based on the initial context information and a thinking chain action prompt strategy; Inputting the initial prompt word into a large language model to obtain an initial action instruction output by the large language model, wherein the initial action instruction is used for controlling the plurality of preset intelligent agents to act in the preset simulation environment; repeatedly executing iteration steps for preset times to update the initial environment data, the initial state data and the initial action instructions, and respectively obtaining intermediate environment data, intermediate state data and intermediate action instructions after each round of iteration; Based on the intermediate environment data, performing nonlinear fitting on epidemic propagation states in a preset time period to obtain an epidemic prediction result; wherein the preset time period is determined based on the preset number of times.
- 2. The large language model based epidemic prediction method according to claim 1, wherein the iterating step includes: Generating intermediate context information after the previous iteration based on the intermediate environment data and intermediate state data after the previous iteration and the intermediate action instruction after each iteration before the current iteration; Generating an intermediate prompt word after the previous iteration based on the intermediate context information after the previous iteration and the thinking chain action prompt strategy; Inputting the intermediate prompt word after the previous iteration into the large language model to obtain an intermediate action instruction after the present iteration output by the large language model; controlling the plurality of preset agents to execute the intermediate action instruction after the current round of iteration in the preset simulation environment to obtain an intermediate action result after the current round of iteration; based on the intermediate action result after the current iteration, updating the intermediate environment data and the intermediate state data after the previous iteration to obtain the intermediate environment data and the intermediate state data after the current iteration; the intermediate environment data used in the first round of iteration are the initial environment data, and the intermediate state data used in the first round of iteration are the initial state data.
- 3. The large language model based epidemic prediction method according to claim 2, wherein the initial environmental data comprises at least one of: Current time type data; statistics of the number of people currently infected with epidemic disease; statistics of the number of people currently not infected with epidemic disease; Infection rate of current epidemic; Mortality of current epidemic infected persons; Current epidemic prevention and control policies; Current medical consumption data; Current consumer data.
- 4. The large language model based epidemic prediction method according to claim 2, wherein the initial state data includes at least one of: Current age data; Current identity data; current health status data; Current professional status data; current financial state data.
- 5. The method for predicting epidemic based on large language model according to claim 2, wherein the large language model is any one model of DeepSeek-V3, GPT-4o-mini, qwen2.5 and gemini 2.0.
- 6. The method for predicting epidemic based on a large language model according to claim 1, wherein the nonlinear fitting of the epidemic propagation state in a preset time period based on the intermediate environmental data, to obtain an epidemic prediction result, comprises: Determining epidemic propagation states corresponding to each time node based on the intermediate environment data after each iteration; and carrying out the nonlinear fitting on the epidemic propagation state of each time node to obtain the epidemic prediction result in the preset time period.
- 7. An epidemic prediction apparatus based on a large language model, comprising: The system comprises an acquisition module, a simulation module and a simulation module, wherein the acquisition module is used for acquiring initial environment data in a preset simulation environment and initial state data of a plurality of preset agents, wherein the preset agents are used for representing organization units or individual units in a real physical world; the first generation module is used for generating initial context information based on the initial environment data and the initial state data; the second generation module is used for generating an initial prompt word based on the initial context information and the thinking chain action prompt strategy; The instruction control module is used for inputting the initial prompt word into a large language model to obtain an initial action instruction output by the large language model, wherein the initial action instruction is used for controlling the plurality of preset intelligent agents to act in the preset simulation environment; the iteration loop module is used for repeatedly executing iteration steps of preset times to update the initial environment data, the initial state data and the initial action instruction, and respectively obtaining intermediate environment data, intermediate state data and intermediate action instruction after each round of iteration; The prediction module is used for carrying out nonlinear fitting on the epidemic propagation state in a preset time period based on the intermediate environment data to obtain an epidemic prediction result; wherein the preset time period is determined based on the preset number of times.
- 8. An electronic device comprising a memory, a processor and a computer program stored on the memory and running on the processor, wherein the processor implements the large language model based epidemiological prediction method of any of claims 1 to 6 when the computer program is executed.
- 9. A non-transitory computer readable storage medium having stored thereon a computer program, wherein the computer program when executed by a processor implements the large language model based epidemic prediction method according to any one of claims 1 to 6.
- 10. A computer program product comprising a computer program which, when executed by a processor, implements a large language model based epidemiological prediction method as claimed in any one of claims 1 to 6.
Description
Epidemic disease prediction method and device based on large language model Technical Field The invention relates to the technical field of artificial intelligence, in particular to a epidemic prediction method and device based on a large language model. Background For epidemic prediction, the prior art mainly includes a method relying on mathematical models and a method based on rule-based agent models. The method based on the rule intelligent body model generates macroscopic social phenomena from bottom to top by creating a plurality of intelligent bodies (agents) and presetting static rules (such as fixed mask compliance rate) for the intelligent bodies, so that the prediction of the epidemic propagation state is carried out, however, the behavior of the intelligent bodies is driven by the stiff predefined static rules, lacks reality and adaptability, is difficult to truly reflect common sense reasoning and complex trade-off of human beings, cannot accurately simulate the behavior of the individual, and causes the prediction of the epidemic propagation state to be inaccurate. Disclosure of Invention The invention provides a epidemic disease prediction method and device based on a large language model, which are used for solving the technical problem of inaccurate prediction of a epidemic disease transmission state in the prior art. The invention provides a epidemic prediction method based on a large language model, which comprises the following steps: acquiring initial environment data in a preset simulation environment and initial state data of a plurality of preset agents, wherein the preset agents are used for representing organization units or individual units in a real physical world; generating initial context information based on the initial environment data and the initial state data; generating an initial prompt word based on the initial context information and a thinking chain action prompt strategy; Inputting the initial prompt word into a large language model to obtain an initial action instruction output by the large language model, wherein the initial action instruction is used for controlling the plurality of preset intelligent agents to act in the preset simulation environment; repeatedly executing iteration steps for preset times to update the initial environment data, the initial state data and the initial action instructions, and respectively obtaining intermediate environment data, intermediate state data and intermediate action instructions after each round of iteration; Based on the intermediate environment data, performing nonlinear fitting on epidemic propagation states in a preset time period to obtain an epidemic prediction result; wherein the preset time period is determined based on the preset number of times. According to the epidemic prediction method based on the large language model, the iteration steps comprise: Generating intermediate context information after the previous iteration based on the intermediate environment data and intermediate state data after the previous iteration and the intermediate action instruction after each iteration before the current iteration; Generating an intermediate prompt word after the previous iteration based on the intermediate context information after the previous iteration and the thinking chain action prompt strategy; Inputting the intermediate prompt word after the previous iteration into the large language model to obtain an intermediate action instruction after the present iteration output by the large language model; controlling the plurality of preset agents to execute the intermediate action instruction after the current round of iteration in the preset simulation environment to obtain an intermediate action result after the current round of iteration; based on the intermediate action result after the current iteration, updating the intermediate environment data and the intermediate state data after the previous iteration to obtain the intermediate environment data and the intermediate state data after the current iteration; the intermediate environment data used in the first round of iteration are the initial environment data, and the intermediate state data used in the first round of iteration are the initial state data. According to the epidemic prediction method based on the large language model, the initial environmental data comprises at least one of the following: Current time type data; statistics of the number of people currently infected with epidemic disease; statistics of the number of people currently not infected with epidemic disease; Infection rate of current epidemic; Mortality of current epidemic infected persons; Current epidemic prevention and control policies; Current medical consumption data; Current consumer data. According to the epidemic prediction method based on the large language model, the initial state data comprises at least one of the following: Current age data; Current identity data; current h