The invention discloses an accurate formula calculation method and device based on a large
language model, and the method comprises the steps: receiving a
mathematical formula image inputted by a user and a calculation request described by a
natural language, carrying out the recognition of the
mathematical formula image, generating a standard LaTeX expression, carrying out the grammar and semantic
verification, employing the large
language model to analyze the calculation request, and carrying out the analysis of the calculation request. The method comprises the steps of identifying a calculation type, a target variable and a parameter, outputting a structured operation instruction, converting a standard LaTeX expression into a mathematical object compatible with a symbol calculation
library according to the structured operation instruction, dynamically declaring a symbol variable according to the operation instruction, and executing symbol operation based on a parameter extraction result to obtain a symbol calculation result. A symbol calculation result is converted into a readable format to be output, LaTeX mathematical expressions and
natural language description are supported, a large
language model and a multi-
modal model are used for accurately recognizing a formula and analyzing a user
natural language problem, complex symbol calculation and equation solving are automatically completed, tasks can be automatically completed through
natural language interaction, and the use threshold is lowered.