Artificial intelligence-based large language model question and answer method and system

By constructing a structured preprocessing and hybrid index for heterogeneous knowledge sources, combined with a multi-factor scoring model and adaptive truncation threshold, the problems of semantic recall errors and rigid fixed thresholds in existing technologies are solved, enabling accurate question answering in enterprise marketing and customer management.

CN123178409APending Publication Date: 2026-11-27WESHINE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611697695.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-10-30
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

Existing search enhancement generation technologies have problems in enterprise marketing and customer management scenarios, such as semantic similarity recalling incorrect answers and fixed thresholds failing to adapt to queries of varying difficulty, leading to business risks and incomplete information retrieval.

Method used

By performing structured preprocessing on heterogeneous knowledge sources, constructing a hybrid index, and combining a multi-factor scoring model and an adaptive truncation threshold, the system comprehensively considers business timeliness and keyword matching, dynamically adjusts the truncation threshold, and generates accurate question-and-answer results.

Benefits of technology

It automatically reduces the weight of expired documents at the algorithm level, improving sorting accuracy and recall comprehensiveness, reducing illusion rate, and adapting to query needs of varying difficulty.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123178409A_ABST
    Figure CN123178409A_ABST
Patent Text Reader

Abstract

The present application relates to the field of artificial intelligence and natural language processing technology, in particular to a large language model question and answer method and system based on artificial intelligence. The method comprises the following steps: firstly, structuring and slicing the heterogeneous knowledge source and constructing a mixed index, binding time limit and keyword metadata; secondly, responding to user questions, obtaining an initial candidate set through vector and keyword double-path parallel retrieval; then constructing a multi-factor scoring model containing time limit decay and keyword density, scoring the comprehensive relevance of the candidate set, and isolating outdated knowledge by data age; finally, dynamically calculating an adaptive truncation threshold according to the statistical distribution characteristics of the candidate set score, accurately filtering out long-tail noise, and inputting the retained high-quality slices into a large language model to generate answers. Through multi-dimensional scoring and dynamic truncation, the present application significantly improves the accuracy and robustness of intelligent question answering.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the fields of artificial intelligence and natural language processing. More specifically, this invention relates to a question-answering method and system based on a large language model using artificial intelligence. Background Technology

[0002] With the rapid development of large language model technology, more and more enterprises are beginning to use search-enhanced generation technology to build intelligent customer service systems. In the actual business system of enterprises, massive amounts of unstructured data are usually accumulated, including product manuals, sales scripts, standard operating procedures, and massive historical conversation archives.

[0003] The current mainstream approach is to slice and quantize this private domain knowledge and store it in a vector database. When a user asks a question, the system retrieves the most similar knowledge fragments as context and inputs them into a large model to generate an answer.

[0004] However, in practical enterprise marketing and customer management applications, the aforementioned existing retrieval enhancement generation technologies have significant limitations. On one hand, vector retrieval primarily relies on semantic similarity. However, in marketing scenarios, the semantics of promotional rules from different periods (such as Double 11 discounts and regular discounts) are extremely similar, but their business logic is completely mutually exclusive. If recall is based solely on vector similarity, the system is highly susceptible to recalling outdated rules as high-scoring fragments, leading to incorrect answers generated by the large model, creating a "false impression," and posing business risks. On the other hand, existing technologies typically set a fixed similarity threshold or a fixed number of recalls. Moreover, the complexity of user queries varies greatly. For simple and clear questions, only a few precise fragments may be needed; for complex and ambiguous questions, more fragments may be required for synthesis. A fixed threshold can lead to "truncating what should be recalled" or "introducing noise that shouldn't be recalled," failing to flexibly adapt to query needs of varying difficulty. Summary of the Invention

[0005] The purpose of this invention is to propose a question-answering method and system based on a large language model using artificial intelligence. This method comprehensively considers business timeliness and keyword matching, and dynamically adjusts the truncation threshold according to the distribution of current search results, achieving accurate and efficient intelligent question answering. This invention provides solutions in the following two aspects.

[0006] In a first aspect, the artificial intelligence-based large language model question-answering method provided by the present invention includes the following steps: Heterogeneous knowledge sources undergo structured preprocessing, dividing unstructured data into text slices. The time stamp and business keyword set corresponding to each text slice are extracted, and a hybrid index containing dense vector indexes and sparse inverted indexes is constructed. In response to user query requests, parallel retrieval is performed based on the hybrid index, obtaining vector retrieval results based on semantic similarity and keyword retrieval results based on keyword matching. These two results are then combined to generate an initial candidate set. A constructed multi-factor scoring model is used to re-rank each text slice in the initial candidate set, including: obtaining the vector cosine similarity between the text slice and the query request; and statistically analyzing the keywords in the query request within the text slice. The frequency of occurrence of keywords in the text slice is used to calculate the normalized keyword density, which is then combined with the character length of the text slice. The data age is calculated based on the current time and the expiration timestamp, and an expiration decay factor is calculated based on the data age. A comprehensive relevance score is obtained by weighting the above parameters using a semantic weight balance coefficient. The multi-factor scoring model calculates the comprehensive relevance score based on the semantic similarity, keyword density, and expiration decay factor of the text slice. Based on the statistical distribution characteristics of the comprehensive relevance scores of all text slices in the initial candidate set, an adaptive truncation threshold is dynamically calculated. Text slices with a comprehensive relevance score greater than or equal to the adaptive truncation threshold are retained as context and input into the large language model to generate question-and-answer results.

[0007] Thus, through refined preprocessing and hybrid index construction of heterogeneous knowledge sources, not only is the generalization capability of semantic retrieval preserved, but a precise keyword matching mechanism is also introduced, ensuring comprehensiveness in the recall phase. Simultaneously, the introduction of a multi-factor scoring model and an adaptive truncation mechanism effectively solves the problems of semantic conflict and rigid fixed thresholds. By introducing a time-lapse factor, the system can automatically reduce the weight of expired documents at the algorithm level, preventing old knowledge from interfering with new business; at the same time, combined with keyword density, it corrects the shortcomings of simple vector retrieval in proper noun matching, improving the accuracy of ranking.

[0008] Preferably, the structured preprocessing of heterogeneous knowledge sources includes: for document-type data, using a sliding window strategy for segmentation, setting the slice length and overlap rate; for table-type standard operating procedure data, segmenting according to question-and-answer pairs, and concatenating applicable scenario fields to the slice header; for conversation archive data, aggregating according to conversation sequences and extracting multi-turn dialogue fragments; and while segmenting, using the publication time or last update time as a time stamp, and using a text weighting algorithm to extract proper nouns as a set of business keywords.

[0009] Preferably, the expression for the comprehensive relevance score is: ;in, To achieve a comprehensive relevance score, This is the semantic weight balancing coefficient. For vector cosine similarity, This represents the number of times the query keywords are contained in a text slice. The length of the text slice. This is the time-related decay coefficient. The data age for the text slice.

[0010] Preferably, the expression for the age of the data is: ;in, The age of the data in the text slice. The current system time. The expiration timestamp for the text slice.

[0011] Preferably, the step of dynamically calculating the adaptive truncation threshold based on the statistical distribution characteristics of the comprehensive relevance scores of all text slices in the initial candidate set includes: calculating the arithmetic mean and standard deviation of the scores of the first preset number of text slices in the initial candidate set; obtaining the highest and lowest scores in the initial candidate set; and calculating the adaptive truncation threshold by combining the adjustment coefficient and the numerical stability constant.

[0012] In this way, by dynamically calculating the cutoff threshold using statistical features, the system gains adaptive capabilities. When the quality of search results varies, the system automatically raises the threshold to "strictly reject" results and filter out noise; when the quality of search results is generally high, the system automatically lowers the threshold to "widen" results and retain more effective information, adapting to changing query scenarios without manual intervention.

[0013] Preferably, the expression for the adaptive truncation threshold is as follows: ;in, For adaptive truncation threshold, The arithmetic mean of the scores of the candidate set. The standard deviation of the candidate set scores. For adjustment coefficients, The highest score in the candidate set. The lowest score in the candidate set. is the numerical stability constant.

[0014] Preferably, it also includes a boundary protection step: if the calculated adaptive truncation threshold is greater than the highest score in the candidate set, the adaptive truncation threshold is adjusted to the highest score in the candidate set minus a preset small amount, so as to ensure that at least the text slice with the highest score is retained.

[0015] Preferably, the process of generating question-and-answer results by inputting the large language model includes: sorting the text slices retained after adaptive truncation threshold filtering according to the comprehensive relevance score from high to low; concatenating the sorted text slices into the context of the prompt words; inputting the prompt words containing the context into the pre-trained large language model, and receiving the natural language answer output by the model.

[0016] In the second aspect, the large language model question-answering system based on artificial intelligence includes: The processor; the memory storing computer instructions for AI-based large language model question answering, which, when executed by the processor, cause the system to perform the aforementioned AI-based large language model question answering method.

[0017] The beneficial effects of this invention are as follows: By mapping the keyword count index to the [0,1] interval through logarithmic ratio transformation, strict dimensional alignment with the vector similarity index is achieved, avoiding semantic matching failure caused by abnormal amplification of keyword weights in long texts or keyword stuffing. This ensures the fairness and robustness of the scoring model across documents of different lengths. Simultaneously, by introducing data age and decay factors, this invention can automatically reduce the weight of a large number of outdated phrases and expired activity rules in the system, effectively isolating the misleading effect of expired knowledge on the large model at the algorithm level, and significantly reducing the illusion rate of the retrieval enhancement generation system. Attached Figure Description

[0018] Figure 1 This is a flowchart illustrating the steps of the AI-based large language model question-answering method in this embodiment; Figure 2 This is a schematic diagram comparing the effects of multi-factor scoring denoising and recall optimization in an embodiment of the present invention; Figure 3 This is a schematic diagram comparing the effects of adaptive dynamic truncation and fixed threshold in an embodiment of the present invention. Detailed Implementation

[0019] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.

[0020] like Figure 1 As shown, the AI-based large language model question-answering method in this embodiment includes the following steps: Step S1: Perform structured preprocessing on heterogeneous knowledge sources, divide unstructured data into text slices, extract the time stamp and business keyword set corresponding to each text slice, and construct a hybrid index containing dense vector index and sparse inverted index.

[0021] In real-world applications, such as enterprise SCRM systems, data sources are complex and diverse, including PDF product manuals, Excel scripts, and historical conversation archives. This step aims to transform this heterogeneous data into a structured form that can be efficiently retrieved by computers.

[0022] Specifically, for PDF or Word documents, a sliding window segmentation strategy based on paragraph and semantic integrity is adopted, with the slice length set to 300-500 characters and the overlap rate set to 10%-20% to ensure semantic continuity.

[0023] For SOP scripts in Excel format, they are segmented according to "question-answer" pairs, preserving the original question-and-answer structure, and the content of the "applicable scenarios" field is appended to the segment header to enhance the semantic context of the segments.

[0024] For the session archive, it is aggregated by session, extracting multi-turn dialogue fragments between salesperson and customer, and removing meaningless interjections.

[0025] While performing text slicing, the system extracts and binds metadata for each slice. Specifically, it extracts time stamps: for SOP documents, it retrieves the publication time or last update time; for session archives, it retrieves the message sending time. It also extracts a set of business keywords, using TF-IDF or TextRank algorithms to extract proper nouns from the slices, such as "Enterprise Micro-Manager" and "Viral Poster".

[0026] Finally, a hybrid index is constructed by using a fine-tuned embedding model (such as BGE-M3) to convert text slices into high-dimensional vectors and storing them in a vector database to build a dense vector index. At the same time, an inverted index from keywords to slice IDs is built for precise keyword matching.

[0027] In this way, by standardizing the slicing and binding of metadata of multi-source heterogeneous data and building a hybrid index, we can provide underlying data support with both semantic depth and keyword precision for subsequent retrieval, thereby effectively solving the problem of incomplete recall from a single data source or a single indexing method.

[0028] Step S2: In response to the user's query request, perform parallel retrieval based on the hybrid index, obtain vector retrieval results based on semantic similarity and keyword retrieval results based on keyword matching, and perform union processing on the two to generate an initial candidate set.

[0029] When a user submits a question, the system executes a multi-path retrieval strategy in parallel. For example, suppose the question is: "How do I get a refund for the latest Double Eleven discounts?" The retrieval strategy would be as follows: Vector retrieval path: The user's query request is input into the Embedding model in step S1, transformed into a query vector, and an approximate nearest neighbor search is performed in the vector database to recall the Top-N slices with the highest semantic similarity. For example, slice IDs containing the semantics of "refund process" are recalled. 001 and ID 002 For example, N is 100.

[0030] Keyword retrieval path: The user query is segmented to extract core keywords such as "Double Eleven" and "refund." The inverted index is then used to retrieve slices containing these core keywords, recalling the top-M slices. For example, the slice IDs that precisely contain the keyword "Double Eleven" are retrieved. 003 For example, the value of M is 50.

[0031] Union processing: The results from the two searches above are combined, and duplicate slice IDs are removed to form an initial candidate set. Assume the union result is {ID}. 001 ID 002 ID 003 At this point, the candidate set contains both semantically related segments and segments that precisely match the keywords, ensuring the coverage of the recall rate.

[0032] Thus, by adopting a hybrid retrieval strategy that combines vector and keyword searches, we can maximize the coverage of knowledge fragments related to user questions, avoid missed recalls due to a single retrieval method, and provide sufficient candidate data for subsequent accurate ranking.

[0033] Step S3: The constructed multi-factor scoring model is used to re-rank each text slice in the initial candidate set. The multi-factor scoring model calculates a comprehensive relevance score based on the semantic similarity of the text slices, keyword density, and timeliness decay factor.

[0034] To address the issue of old documents interfering with new business, this step does not directly use vector similarity as the final score. Instead, it constructs a multi-factor scoring model to re-score each slice in the initial candidate set.

[0035] For example, suppose there are two slices, where: Slice A (new document): Slightly lower semantic similarity, but more recent and contains key business terms; Slice B (old document): Semantically highly similar to the query, i.e., high vector similarity, but older.

[0036] The system defines the expression for the overall relevance score of a slice relative to a query as follows: ; in, To achieve a comprehensive relevance score, This is the semantic weight balancing coefficient. For vector cosine similarity, This represents the number of times the query keywords are contained in a text slice. The length of the text slice. This is the time-related decay coefficient. The data age for the text slice is expressed in days.

[0037] In a multi-factor scoring model, the log ratio is introduced. To characterize keyword density, this design essentially borrows the word frequency saturation and text length penalty mechanism from the classic BM25 algorithm, mathematically avoiding the scoring distortion problem caused by long texts or excessive keyword stuffing. Furthermore, the construction of the time-related decay factor accurately maps the objective law of the decay of knowledge base information value over time. In this embodiment, the preset empirical value of the semantic weight balance coefficient is 0.7, the vector cosine similarity is returned from the vector database and takes values ​​[0,1], and the preset control parameter of the time-related decay factor is 0.01, with its dimension being days. -1 The data age in the text slice is in days, and its expression is: ;in, The age of the data in the text slice. The current system time. The expiration timestamp for the text slice.

[0038] In the example above, for slice A, assuming the vector cosine similarity is 0.85, the number of elements containing the query keyword is 3, the character length is 100, and the data age is 10 days, then its final score can be calculated using the expression for the comprehensive relevance score. For slice B, assuming a vector cosine similarity of 0.92, 1 instance containing the query keyword, a character length of 100, and a data age of 730 days, its final score can be calculated using the above expression for comprehensive relevance scoring. .

[0039] The comparison shows that the old slice B, which originally had a very high vector similarity, had a significantly lower score after time decay, and was overtaken by slice A.

[0040] Figure 2 This paper illustrates the differences in scoring five typical document slices using existing techniques (relying solely on vector similarity) and the present invention, demonstrating the effectiveness of multi-factor scoring for denoising and recall optimization. In the figure, each row represents a document type, and the position of the scores from the existing technique and the present invention, along with the length of the connecting line, reflects the magnitude of score variation. The figure shows that the present invention, by introducing time-sensitivity decay and keyword weighting, can identify expired, highly similar documents as noise (significantly reducing their scores), while simultaneously improving the scores of documents containing key information.

[0041] Thus, by constructing a multi-factor scoring model that includes time-sensitivity decay and keyword density, we can achieve physical isolation between new and old knowledge at the algorithm level, prioritize recommending knowledge fragments that are timely and contain key information, and significantly reduce the interference of outdated information on the answers of large models.

[0042] Step S4: Based on the statistical distribution characteristics of the comprehensive relevance scores of all text slices in the initial candidate set, dynamically calculate the adaptive truncation threshold, retain text slices with comprehensive relevance scores greater than or equal to the adaptive truncation threshold as context, and input them into the large language model to generate question-answering results.

[0043] To address the limitation of fixed thresholds in adapting to varying problem complexities, this step analyzes the score distribution characteristics of the current query recall and dynamically calculates the truncation threshold.

[0044] The expression for the adaptive truncation threshold is as follows: ; in, For adaptive truncation threshold, The arithmetic mean of the scores of the candidate set (taking the top-N candidates). The standard deviation of the candidate set scores. For adjustment coefficients, The highest score in the candidate set. The lowest score in the candidate set. is the numerical stability constant.

[0045] Unlike traditional static Top-K recall strategies, adaptive truncation thresholds... The design introduces a distribution span factor based on the score range (i.e., the square root term in the formula). By dynamically coupling this factor with the local standard deviation, the system can effectively perceive the topological characteristics of the candidate set score distribution. Specifically, when the candidate set score exhibits a step drop (i.e., a significant quality discontinuity), this nonlinear factor adaptively amplifies the truncation penalty, thereby achieving precise isolation of low signal-to-noise ratio documents at the algorithm's underlying level. This model, as a heuristic strategy, is derived from verification and deduction based on massive heterogeneous document retrieval logs. In this embodiment, the adjustment coefficient is a preset constant with a value of 0.5, and the numerical stability constant is a fixed value of 0.1.

[0046] For example, suppose that after sorting in step S3, the scores of the first 5 slices are , Based on the above expression, the adaptive truncation threshold is calculated to be 0.844.

[0047] Based on the calculated adaptive truncation threshold, the system will retain slices with scores greater than or equal to 0.844, i.e., 0.95, 0.92, and 0.90, while discarding slices with scores of 0.65 and 0.60. This reflects the "strict exit" logic, because the score shows a drop (from 0.90 to 0.65), which the system automatically truncates upon identification.

[0048] If calculated Then a mandatory order ,in, For small quantities, ensure that at least the highest-scoring document is retained.

[0049] Finally, the retained slices are concatenated into a context of the prompt words and input into a large language model to generate the final answer.

[0050] Figure 3 The figure shows the distribution curves of candidate documents sorted in descending order of score during a retrieval recall, comparing the effects of adaptive dynamic truncation and a fixed threshold. The figure includes two horizontal lines, representing the fixed threshold of the prior art and the adaptive threshold of this invention, respectively. As can be seen from the figure, the adaptive truncation threshold of this invention can keenly detect the "cliff-like" drop in the score curve, accurately retaining high-quality documents at the top and removing noise at the bottom.

[0051] Thus, the adaptive truncation mechanism based on statistical distribution characteristics can dynamically adjust the filtering threshold according to the quality distribution of each query result, ensuring high-quality information input while minimizing noise interference, thereby enabling the question-answering system to adapt to questions of varying difficulty.

[0052] This invention also provides a large language model question-answering system based on artificial intelligence. The system includes a processor and a memory, the memory storing computer program instructions. When the processor executes the computer program instructions, it implements the large language model question-answering method based on artificial intelligence according to the present invention.

[0053] The system also includes other components well known to those skilled in the art, such as communication buses and communication interfaces, the settings and functions of which are known in the art and therefore will not be described in detail here.

[0054] In this invention, the aforementioned memory can be any tangible medium containing or storing a program that can be used or combined with an instruction execution system, apparatus, or device. For example, a computer-readable storage medium can be any suitable magnetic or magneto-optical storage medium, such as Resistive Random Access Memory (RRAM), Dynamic Random Access Memory (DRAM), Static Random Access Memory (SRAM), Enhanced Dynamic Random Access Memory (EDRAM), High-Bandwidth Memory (HBM), Hybrid Memory Cube (HMC), etc., or any other medium that can be used to store desired information and can be accessed by an application, module, or both. Any such computer storage medium can be part of a device or accessible to or connected to a device. Any application or module described in this invention can be implemented by computer-readable / executable instructions stored or otherwise maintained on such a computer-readable medium.

[0055] In the description of this specification, "multiple" means at least two, such as two, three or more, etc., unless otherwise expressly and specifically defined.

[0056] While various embodiments of the invention have been shown and described in this specification, it will be apparent to those skilled in the art that such embodiments are provided by way of example only. Many modifications, alterations, and alternatives will occur to those skilled in the art without departing from the spirit and essence of the invention.

Claims

1. A question-answering method based on a large language model using artificial intelligence, characterized in that, Includes the following steps: The heterogeneous knowledge source is preprocessed in a structured manner, the unstructured data is divided into text slices, the time stamp and business keyword set corresponding to each text slice are extracted, and a hybrid index containing dense vector index and sparse inverted index is constructed. In response to the user's query request, parallel retrieval is performed based on the hybrid index to obtain vector retrieval results based on semantic similarity and keyword retrieval results based on keyword matching. The two are then combined to generate an initial candidate set. The constructed multi-factor scoring model is used to re-rank each text slice in the initial candidate set, including: obtaining the vector cosine similarity between the text slice and the query request; counting the number of times the keywords in the query request appear in the text slice, and calculating the normalized keyword density in combination with the character length of the text slice; calculating the data age based on the current time and the time-effect timestamp, and calculating the time-effect decay factor based on the data age; and weighting the above parameters in combination with the semantic weight balance coefficient to obtain a comprehensive relevance score. The multi-factor scoring model calculates a comprehensive relevance score based on the semantic similarity of text slices, keyword density, and time-related decay factor. Based on the statistical distribution characteristics of the comprehensive relevance scores of all text slices in the initial candidate set, an adaptive truncation threshold is dynamically calculated. Text slices with comprehensive relevance scores greater than or equal to the adaptive truncation threshold are retained as context and input into the large language model to generate question-answering results.

2. The question-answering method based on a large language model using artificial intelligence according to claim 1, characterized in that, The structured preprocessing of heterogeneous knowledge sources includes: For document-type data, a sliding window strategy is used for segmentation, with the slice length and overlap rate set. For tabular standard operating procedure data, the data is segmented according to question and answer pairs, and the applicable scenario fields are appended to the segment header; For the session archive data, aggregate it according to the session sequence and extract multi-turn dialogue fragments; While slicing, the publication time or last update time is used as a time stamp, and a text weighting algorithm is used to extract proper nouns as a set of business keywords.

3. The question-answering method based on a large language model using artificial intelligence according to claim 1, characterized in that, The expression for the comprehensive relevance score is: ; in, To achieve a comprehensive relevance score, This is the semantic weight balancing coefficient. For vector cosine similarity, This represents the number of times the query keywords are contained in a text slice. The length of the text slice. This is the time-related decay coefficient. The data age for the text slice.

4. The question-answering method based on a large language model using artificial intelligence according to claim 3, characterized in that, The expression for the age of the data is: ; in, The age of the data in the text slice. The current system time. The expiration timestamp for the text slice.

5. The question-answering method based on a large language model using artificial intelligence according to claim 1, characterized in that, The step of dynamically calculating the adaptive truncation threshold based on the statistical distribution characteristics of the comprehensive relevance scores of all text slices in the initial candidate set includes: Calculate the arithmetic mean and standard deviation of the scores of the first preset number of text slices in the initial candidate set; Obtain the highest and lowest scores in the initial candidate set; The adaptive cutoff threshold is calculated by combining the adjustment coefficient and the numerical stability constant.

6. The question-answering method based on a large language model using artificial intelligence according to claim 5, characterized in that, The expression for the adaptive truncation threshold is as follows: ; in, For adaptive truncation threshold, The arithmetic mean of the scores of the candidate set. The standard deviation of the candidate set scores. For adjustment coefficients, The highest score in the candidate set. The lowest score in the candidate set. is the numerical stability constant.

7. The question-answering method based on a large language model using artificial intelligence according to claim 6, characterized in that, It also includes a boundary protection step: if the calculated adaptive truncation threshold is greater than the highest score in the candidate set, the adaptive truncation threshold is adjusted to the highest score in the candidate set minus a preset small amount, so as to ensure that at least the text slice with the highest score is retained.

8. The question-answering method based on a large language model using artificial intelligence according to claim 1, characterized in that, The input large language model generates question-and-answer results, including: The text slices retained after adaptive truncation threshold filtering are sorted from high to low according to the comprehensive relevance score; The sorted text slices are then concatenated to form the context of the prompt words; Input context-sensitive prompts into a pre-trained large language model and receive the natural language response output by the model.

9. A large language model question-answering system based on artificial intelligence, characterized in that, include: processor; A memory storing computer instructions for large language model question answering based on artificial intelligence, which, when executed by the processor, cause the system to perform the large language model question answering method based on artificial intelligence according to any one of claims 1-8.