Large model-based opinion generation method, device and equipment and storage medium
By constructing a fact base and an opinion base, and using large model reasoning to generate new opinions, the problem of generating new opinions in existing technologies has been solved, and efficient and accurate opinion generation has been achieved in a 6G network environment.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- CHINA MOBILE COMM LTD RES INST
- Filing Date
- 2025-11-05
- Publication Date
- 2026-07-10
AI Technical Summary
Existing technologies struggle to generate new viewpoints based on existing articles, and require 6G networks to connect articles located in different places.
By acquiring the target text input by the user, new opinions are generated based on a pre-built fact base and opinion base using large model reasoning. The fact base and opinion base are associated through target identifiers, and novel opinions are generated by judging and fusing them using similarity thresholds.
It enables the accurate generation of novel viewpoints in articles located in different places, improving the accuracy and efficiency of viewpoint generation, and is suitable for 6G network environments.
Smart Images

Figure CN122366643A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a method, apparatus, device and storage medium for generating viewpoints based on large models. Background Technology
[0002] Currently, the relevant technology mainly extracts viewpoints from existing articles, where the extracted viewpoints are conventional and inherent. Furthermore, these existing articles may be stored in different locations, requiring a 6G network connection.
[0003] Therefore, how to generate new viewpoints based on existing articles is a technical problem that urgently needs to be solved. Summary of the Invention
[0004] This application provides a method, apparatus, device, and storage medium for generating viewpoints based on a large model, in order to solve the problem of how to generate new viewpoints based on existing articles.
[0005] This application provides a viewpoint generation method based on a large model, including: Get the target text input by the user; Based on the first fact represented by the target text, a pre-built fact base, and a pre-built opinion base, at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion are determined; the fact base includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion base includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact base and the opinions in the opinion base are associated with target identifiers. Based on each second fact, each first viewpoint, and the information corresponding to each first viewpoint, a large model inference is used to generate the second viewpoint.
[0006] According to the opinion generation method based on a large model provided in this application, the step of determining at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion based on the first fact represented by the target text, a pre-built fact base, and a pre-built opinion base includes: Based on the first fact represented by the target text, at least one second fact corresponding to the first fact and information corresponding to each second fact are determined from the pre-built fact base; Based on each second fact, the first viewpoint corresponding to each second fact and the information corresponding to each first viewpoint are determined from the pre-built viewpoint library.
[0007] According to the opinion generation method based on a large model provided in this application, the step of determining at least one second fact corresponding to the first fact and information corresponding to each second fact from the pre-built fact base based on the first fact represented by the target text includes: Based on the first vector corresponding to the first fact represented by the target text, calculate the first similarity value between the first vector and the vectors corresponding to each of the facts included in the fact base; At least one fact whose first similarity value is greater than a first preset threshold and the information corresponding to each of the facts are determined as at least one second fact corresponding to the first fact and the information corresponding to each of the second facts.
[0008] According to the opinion generation method based on a large model provided in this application, the step of determining the first opinion corresponding to each second fact and the information corresponding to each first opinion from the pre-built opinion library based on each second fact includes: For each target identifier of the second fact, the viewpoint corresponding to the target identifier and the information corresponding to the viewpoint in the pre-built viewpoint library are respectively determined as the first viewpoint and the information corresponding to the first viewpoint for the second fact.
[0009] According to the viewpoint generation method based on a large model provided in this application, the method further includes: Based on the second vector corresponding to the second viewpoint, calculate the second similarity value between the second vector and the vectors corresponding to each viewpoint included in the viewpoint library; If each of the second similarity values is less than or equal to the second preset threshold, the second viewpoint is determined to be a new viewpoint; If any one of the second similarity values is greater than the second preset threshold, it is determined that the second viewpoint is not a new viewpoint.
[0010] According to the viewpoint generation method based on a large model provided in this application, the method further includes: If it is determined that the second viewpoint is not a new viewpoint, the second viewpoint is added to the viewpoint list composed of each of the first viewpoints, and the second viewpoint is used as the first viewpoint. The step of generating the second viewpoint using a large model based on each of the first viewpoints and the information corresponding to each of the first viewpoints is repeated until the generated second viewpoint is a new viewpoint.
[0011] According to the viewpoint generation method based on a large model provided in this application, the method further includes: In the absence of the pre-built fact base, a third opinion is generated based on the first fact.
[0012] According to the opinion generation method based on a large model provided in this application, the fact base is constructed based on the vectors corresponding to at least one fact in the text descriptions of multiple existing articles and the information corresponding to each of the facts.
[0013] According to the viewpoint generation method based on a large model provided in this application, the method further includes: For each of the facts described in the text of each of the articles, the text of the article is segmented into a sequence of sentences; Calculate the third similarity value between each sentence in the sentence sequence and the fact; If the third similarity value is greater than or equal to the third preset threshold, it is determined that the fact originates from the article; If the third similarity value is less than the third preset threshold, it is determined that the fact does not originate from the article.
[0014] According to the opinion generation method based on a large model provided in this application, the opinion library is constructed based on multiple existing articles, using the vectors corresponding to the opinions generated by opinion generation prompts and the information corresponding to each opinion.
[0015] According to the viewpoint generation method based on a large model provided in this application, the method further includes: After the opinion generation prompts generate an opinion, it is determined whether an opinion exists in the opinion library; If opinions exist in the opinion library, calculate a fourth similarity value between the vector corresponding to the opinion generated by the opinion generation prompt and the vector corresponding to the opinion existing in the opinion library; If the fourth similarity value is greater than or equal to the fourth preset threshold, the information corresponding to the viewpoint generated based on the viewpoint generation prompt word is retrieved from the fact base to find the facts corresponding to the information. If the fifth similarity value between the vector corresponding to the viewpoint generated by the viewpoint generation prompt and the vector corresponding to the retrieved fact is greater than or equal to the fifth preset threshold, the viewpoint generated by the viewpoint generation prompt is determined to be an existing viewpoint.
[0016] According to the viewpoint generation method based on a large model provided in this application, the information includes subject information, industry information, and focus information.
[0017] According to the viewpoint generation method based on a large model provided in this application, the method further includes: Collect the subject information, the industry information, and the focus information, and generate corresponding lists based on the subject information, the industry information, and the focus information.
[0018] This application also provides a viewpoint generation device based on a large model, including: The acquisition module is used to acquire the target text input by the user; A first determining module is configured to determine, based on the first fact represented by the target text, a pre-built fact base, and a pre-built opinion base, at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion; the fact base includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion base includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact base and the opinions in the opinion base are associated with target identifiers. The opinion generation module is used to generate second opinions based on each second fact, each first opinion, and the information corresponding to each first opinion, using large model reasoning.
[0019] This application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the viewpoint generation method based on the large model as described above.
[0020] This application also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the viewpoint generation method based on a large model as described above.
[0021] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the viewpoint generation method based on any of the above-described methods.
[0022] The method, apparatus, device, and storage medium for generating viewpoints based on a large model provided in this application acquire target text input by a user; based on a first fact represented by the target text, a pre-built fact library, and a pre-built viewpoint library, at least one second fact corresponding to the first fact, a first viewpoint corresponding to each second fact, and information corresponding to each first viewpoint are determined; the fact library includes vectors corresponding to multiple facts and information corresponding to each fact; the viewpoint library includes vectors corresponding to multiple viewpoints and information corresponding to each viewpoint; the facts in the fact library and the viewpoints in the viewpoint library are associated using target identifiers; and a second viewpoint is generated by large model reasoning based on each second fact, each first viewpoint, and the information corresponding to each first viewpoint. Through the pre-built fact library and the pre-built viewpoint library, at least one second fact corresponding to the first fact, the first viewpoint corresponding to each second fact, and the information corresponding to each first viewpoint can be accurately determined, thereby enabling the generation of novel second viewpoints using a large model, improving the accuracy and efficiency of new viewpoint generation. Attached Figure Description
[0023] To more clearly illustrate the technical solutions in this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0024] Figure 1 This is one of the flowcharts of the viewpoint generation method based on a large model provided in this application.
[0025] Figure 2 This is the second flowchart of the viewpoint generation method based on a large model provided in this application.
[0026] Figure 3 This is a schematic diagram of the viewpoint generation device based on a large model provided in this application.
[0027] Figure 4 This is a schematic diagram of the structure of the electronic device provided in this application. Detailed Implementation
[0028] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0029] To provide a clear understanding of the various embodiments of this application, relevant technical knowledge will first be introduced.
[0030] 1. The ability to reason about large models With the open-source release of DeepSeek, the large-scale reasoning model has gradually become known to everyone. Its core effect is that you simply ask a question to the large-scale reasoning model, and the model can answer the question according to the Chain of Thought (COT) logic (that is, the user's question is broken down into multiple steps for detailed consideration before answering).
[0031] 2. Mind Chain (COT) A method of thinking that involves breaking down a problem into multiple steps and reasoning step by step to arrive at the answer.
[0032] The following is combined with Figures 1-2 This application describes a viewpoint generation method based on a large model.
[0033] Figure 1 This is one of the flowcharts illustrating the viewpoint generation method based on a large model provided in this application, such as... Figure 1 As shown, the method includes steps 101-103.
[0034] Step 101: Obtain the target text input by the user.
[0035] It should be noted that the opinion generation method based on a large model provided in this application is applied to scenarios where articles stored in different locations are connected via 6G networks, and fact and opinion bases are constructed based on these articles. Novel opinions are then generated based on these fact and opinion bases. The executing entity of this method can be a large-model-based opinion generation device, such as an electronic device, or a control module within that device for executing the large-model-based opinion generation method. Opinion generation consists of the following parts: extracting the subject from which the opinion needs to be generated; extracting the focus of the opinion; extracting the industry from which the opinion needs to be generated; and extracting the facts from which the opinion needs to be generated. Through the subject, focus, industry, and facts, the method answers the question: From whose perspective (the subject) are the facts (extracted from the article) analyzed, using the perspective of (industry + focus, such as economic development), to obtain an opinion? For example, from the perspective of the subject, analyzing the fact that a subject faces restrictions on the purchase of high-end chips (such as chip bottlenecks) from the angle of threats in the artificial intelligence industry, the opinion is that chip innovation and development need to be strengthened.
[0036] When generating opinions in practice, the first step is to obtain the target text input by the user. The target text can be one or more sentences describing specific facts. The target text includes subject information, industry information, focus information, and facts. Subject information represents specific entities, such as hospitals, enterprises, developers, ordinary people, and society. Industry information represents information representing industries, such as finance, agriculture, healthcare, education, and artificial intelligence. Focus information represents the perspective from which the facts are observed, such as people's livelihood, safety, development, security, sustainability, innovation, cost, and benefits. Facts represent a concise description of specific, true, and objective information.
[0037] Step 102: Based on the first fact represented by the target text, the pre-built fact library, and the pre-built opinion library, determine at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion; the fact library includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion library includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact library and the opinions in the opinion library are associated with each other using target identifiers.
[0038] Specifically, based on multiple existing articles, a fact base and an opinion base are pre-built. The fact base includes vectors corresponding to each fact and information (i.e., meta-information) for each fact; the opinion base includes vectors corresponding to each opinion and information for each opinion. Facts in the fact base and opinions in the opinion base are associated using target identifiers, which are unique IDs. This ensures that one fact is associated with one opinion. The information includes subject information, industry information, and focus information.
[0039] Based on the first fact represented by the target text, a pre-built fact base, and a pre-built opinion base, it is possible to determine at least one second fact corresponding to the first fact, the first opinion corresponding to each second fact, and the information corresponding to each first opinion.
[0040] Step 103: Based on each second fact, each first viewpoint, and the information corresponding to each first viewpoint, generate a second viewpoint using large model reasoning.
[0041] Specifically, each second fact, each first viewpoint, and the information corresponding to each first viewpoint are input into the large model. The large model merges each second fact and each first viewpoint, and combines the information corresponding to each first viewpoint with the reasoning ability of the large model to generate the second viewpoint.
[0042] It should be noted that similar facts can be merged to a certain extent, but facts that do not describe the same thing cannot be merged. Merged content must be based on given facts and cannot be fabricated. The generated viewpoint can involve one or two steps of reasoning. Note that the generated viewpoint cannot overlap with previous viewpoints and must be entirely based on the underlying factual information.
[0043] For example, a specific prompt for viewpoint integration would take the following form: "You are an opinion generation expert, skilled at summarizing multiple opinions and generating new opinions through one or two steps of reasoning. First, you define an opinion: an opinion is a subjective analysis and judgment based on facts, taken from the perspective of the subject, focusing on the industry and key aspects."
[0044] Subject: Specific entities, such as hospitals, businesses, developers, ordinary citizens, and society; Industry: Information representing industries such as finance, agriculture, healthcare, education, and artificial intelligence. Focus: The perspective from which facts are observed, such as people's livelihood, security, development, protection, sustainability, threats, innovation, costs, and benefits; Fact: A brief description of true and objective information extracted from the article content.
[0045] Please summarize and merge the following viewpoints. Based on the given multiple existing viewpoints, subjects, facts, industries, and focuses, generate a new viewpoint. Similar facts can be merged to a certain extent, but facts that do not describe the same thing cannot be merged. The merged content must be based on the given facts and cannot be fabricated. Generating a viewpoint can involve one or two steps of reasoning. Note that the generated viewpoint cannot overlap with previous viewpoints and must be entirely based on the factual information it is based on.
[0046] The existing facts, viewpoints, subjects, focus, and industry information are as follows: ``` {content} ``` Generation format: {{ "main_body":"The main body that generates this viewpoint", "field":"The industry that generated this viewpoint", "emphasis":"The focus of generating this viewpoint", "fact": "A new factual statement generated after integrating the above facts", "point": "A new perspective generated based on the aforementioned subjects, industries, focuses, and facts." }} Please begin generating.
[0047] The opinion generation method based on a large model provided in this application obtains target text input by the user; based on the first fact represented by the target text, a pre-built fact library, and a pre-built opinion library, it determines at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion; the fact library includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion library includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact library and the opinions in the opinion library are associated with target identifiers; based on each second fact, each first opinion, and the information corresponding to each first opinion, a second opinion is generated through large model inference. By using the pre-built fact library and the pre-built opinion library, at least one second fact corresponding to the first fact, the first opinion corresponding to each second fact, and the information corresponding to each first opinion can be accurately determined. Therefore, the large model can be used to infer and generate novel second opinions, realizing the generation of new opinions and improving the accuracy and efficiency of new opinion generation.
[0048] The process of building the fact base and opinion base will be explained next.
[0049] Optionally, the fact base is constructed based on the vectors corresponding to at least one fact in the textual descriptions of multiple existing articles and the information corresponding to each of the facts.
[0050] Specifically, multiple existing articles may reside in the same or different geographical locations. This application connects these multiple existing articles to a 6G network. Based on these multiple existing articles, a hash value is calculated for each fact described in the text of each article. This hash value is then used as the target identifier (i.e., unique ID) of the fact. The fact is then converted into a vector using an embedding model, and the corresponding vector is stored in a fact base. Furthermore, the target identifier, subject information, industry information, and focus information included in the fact are also stored in the fact base as information corresponding to the fact.
[0051] Optionally, the method further includes: For each fact described in the text of each article, the text of the article is segmented into a sequence of sentences; a third similarity value is calculated between each sentence in the sentence sequence and the fact; if the third similarity value is greater than or equal to a third preset threshold, the fact is determined to originate from the article; if the third similarity value is less than the third preset threshold, the fact is determined not to originate from the article.
[0052] Specifically, for each fact described in the text of each article, the article text is segmented into a sequence of sentences, for example, by segmenting the article text into a sequence of sentences using punctuation. A third similarity value is calculated between each sentence in the sentence sequence and the fact using a semantic similarity algorithm (such as TextTiling) or by vectorizing the data using an embedding model. This third similarity value can be a cosine similarity value. The third similarity value is then compared with a third preset threshold, for example, 0.7. If the third similarity value is greater than or equal to the third preset threshold, it can be determined that the fact originates from the article and is a true fact rather than a hallucination, and the fact can be stored in the fact database. If the third similarity value is less than the third preset threshold, it can be determined that the fact does not originate from the article and is not a true fact; therefore, the fact is not stored in the fact database and needs to be regenerated.
[0053] Optionally, the opinion library is constructed based on multiple existing articles, using the vectors corresponding to the opinions generated by opinion generation prompts and the information corresponding to each opinion.
[0054] Specifically, based on at least one fact described in the text of multiple existing articles, an opinion can be generated for each fact using opinion generation prompts; the opinion is converted into a vector through an embedding model to obtain the vector corresponding to the opinion, and the vector corresponding to the opinion is stored in the opinion library. The target identifier of the fact corresponding to the opinion is also used as the target identifier of the opinion, and the subject information, industry information, and focus information included in the opinion are stored in the opinion library as the information corresponding to the opinion.
[0055] The prompts for generating opinions are in the following format: "First, let's define a viewpoint. A viewpoint is a subjective analysis and judgment based on facts, taken from the perspective of the subject, focusing on the industry and key aspects."
[0056] Subject: Specific entities, such as enterprises, developers, ordinary people, and society; Industry: Information representing industries such as finance, agriculture, healthcare, education, and artificial intelligence; Focus: The perspective from which facts are observed, such as people's livelihood, security, development, protection, sustainability, threats, innovation, costs, and benefits; Fact: A brief description of true and objective information extracted from the article content.
[0057] The following is an excerpt: ``` {content} ``` Please generate {num} opinion pieces based on the above definitions of subject, industry attribute, focus, fact, and opinion. The format for generating opinion pieces is as follows: [ {{ "main_body":"The main body that generates this viewpoint", "field":"The industry that generated this viewpoint", "emphasis": "The focus of generating this viewpoint", "fact": "the facts that led to this viewpoint", "point": "Viewpoint 1 generated based on the aforementioned subject, industry, focus, and facts" }}, ... {{ "main_body":"The main body that generates this viewpoint", "field":"The industry that generated this viewpoint", "emphasis":"The focus of generating this viewpoint", "fact":"The facts that support this viewpoint", "point": "Viewpoints generated based on the aforementioned subjects, industries, focuses, and facts {num}" }} ] Please begin generating.
[0058] Optionally, the method further includes: After the opinion generation prompt word generates an opinion, it is determined whether an opinion exists in the opinion library. If an opinion exists in the opinion library, a fourth similarity value is calculated between the vector corresponding to the opinion generated by the opinion generation prompt word and the vector corresponding to the opinion existing in the opinion library. If the fourth similarity value is greater than or equal to a fourth preset threshold, facts corresponding to the information generated by the opinion generation prompt word are retrieved from the fact library based on the information. If the fifth similarity value between the vector corresponding to the opinion generated by the opinion generation prompt word and the fact whose corresponding vector is retrieved is greater than or equal to a fifth preset threshold, the opinion generated by the opinion generation prompt word is determined to be an existing opinion.
[0059] Specifically, after generating an opinion using opinion generation prompts, it is determined whether the opinion exists in the opinion database. If the opinion exists in the database, a fourth similarity value is calculated between the vector corresponding to the opinion generated by the opinion generation prompts and the vector corresponding to the existing opinion in the database, using a semantic similarity algorithm (such as TextTiling) or vectorization using an embedding model. This fourth similarity value can be a cosine similarity value. The fourth similarity value is then compared with a fourth preset threshold, for example, 0.7. If the fourth similarity value is greater than or equal to the fourth preset threshold, facts corresponding to the information of the opinion generated by the opinion generation prompts are retrieved from the fact database, i.e., facts consistent with the main information, industry information, and focus information of the opinion. A fifth similarity value is calculated between the vector corresponding to the opinion generated by the opinion generation prompts and the vector corresponding to the retrieved facts, using a semantic similarity algorithm (such as TextTiling) or vectorization using an embedding model. This fifth similarity value is then compared with a fifth preset threshold. If the fifth similarity value between the vector corresponding to the viewpoint generated by the viewpoint generation prompt and the vector corresponding to the retrieved fact is greater than or equal to the fifth preset threshold, that is, if the generated viewpoint is similar to the fact retrieved in the fact base, it can be determined that the viewpoint generated by the viewpoint generation prompt is an existing viewpoint and needs to be regenerated.
[0060] Optionally, the method further includes: Collect the subject information, the industry information, and the focus information, and generate corresponding lists based on the subject information, the industry information, and the focus information.
[0061] Specifically, subject information, industry information, and the aforementioned focus information are collected, and based on the subject information, industry information, and focus information, their respective corresponding lists can be generated, i.e., three lists are generated.
[0062] Currently, the opinion generation prompts do not restrict the main body information, industry information, and focus information. However, as existing articles are gradually added, a list of optional main body information, industry information, and focus information will be provided in subsequent optimized opinion prompts. It will be noted that this is optional; if the main body information, industry information, and focus information of the supplementary article are unrelated to the content in the above-mentioned lists, they can be generated manually. In this case, the newly generated list of main body information, industry information, and focus information will be added to the newly generated list for supplementation.
[0063] Optionally, the specific implementation of step 102 above includes: Based on the first fact represented by the target text, at least one second fact corresponding to the first fact and information corresponding to each second fact are determined from the pre-built fact base; based on each second fact, the first opinion corresponding to each second fact and information corresponding to each first opinion are determined from the pre-built opinion base.
[0064] Specifically, since the fact base includes vectors corresponding to multiple facts and information corresponding to each fact, including subject information, industry information and focus information, based on the first fact represented by the target text, at least one second fact similar to the first fact and information corresponding to each second fact can be determined from the pre-built fact base; then, based on each second fact, the first opinion associated with each second fact and information corresponding to each first opinion can be determined from the pre-built opinion base.
[0065] In this embodiment, based on a first fact represented by a target text, at least one second fact corresponding to the first fact and information corresponding to each second fact are determined from a pre-built fact base. Based on each second fact, a first opinion corresponding to each second fact and information corresponding to each first opinion are determined from a pre-built opinion base. The pre-built fact base enables the determination of multiple second facts similar to the first fact and information corresponding to each second fact. Furthermore, the pre-built opinion base enables the determination of first opinions associated with each second fact and information corresponding to each first opinion. This achieves the determination of the second fact, the associated first opinion, and the corresponding information. Subsequently, a large model can be used to infer and generate novel second opinions, thereby improving the accuracy and efficiency of new opinion generation.
[0066] Optionally, determining at least one second fact corresponding to the first fact and information corresponding to each second fact from the pre-built fact base based on the first fact represented by the target text includes: Based on the first vector corresponding to the first fact represented by the target text, a first similarity value is calculated between the first vector and the vectors corresponding to each of the facts included in the fact base; at least one fact whose first similarity value is greater than a first preset threshold and the information corresponding to each of the facts are determined as at least one second fact corresponding to the first fact and the information corresponding to each of the second facts.
[0067] Specifically, based on customer needs, the query scope can be limited according to the information (industry information, subject information, and focus information) corresponding to the first fact represented by the target text. The industry information, subject information, and focus information are stored in the fact base as fact-related information (meta-information). Based on the first vector corresponding to the first fact represented by the target text, a first similarity value is calculated between the first vector and the vectors corresponding to each fact included in the fact base after vectorization using a semantic similarity algorithm or an embedding model. The first similarity value can be a cosine similarity value, and the information corresponding to each fact included in the fact base is the same as the information corresponding to the first fact.
[0068] A first similarity value is compared with a first preset threshold, for example, the first preset threshold is 0.7. At least one fact whose first similarity value is greater than the first preset threshold, and the information corresponding to each fact, can be identified as at least one second fact corresponding to the first fact and the information corresponding to each second fact. That is, at least one second fact similar to the first fact and the information corresponding to each second fact are identified as at least one second fact corresponding to the first fact and the information corresponding to each second fact. The at least one second fact and the information corresponding to each second fact can be combined into a fact list.
[0069] Optionally, determining the first opinion corresponding to each second fact and the information corresponding to each first opinion from the pre-built opinion library based on each second fact includes: For each target identifier of the second fact, the viewpoint corresponding to the target identifier and the information corresponding to the viewpoint in the pre-built viewpoint library are determined as the first viewpoint and the information corresponding to the first viewpoint corresponding to the second fact.
[0070] Specifically, since the facts in the fact base and the opinions in the opinion base are associated with target identifiers, for each target identifier of the second fact, the opinion and the information corresponding to the target identifier in the pre-built opinion base can be determined as the first opinion and the information corresponding to the first opinion.
[0071] Optionally, the method further includes: Based on the second vector corresponding to the second viewpoint, a second similarity value is calculated between the second vector and the vectors corresponding to each viewpoint included in the viewpoint library; if all the second similarity values are less than or equal to a second preset threshold, the second viewpoint is determined to be a new viewpoint; if any of the second similarity values is greater than the second preset threshold, the second viewpoint is determined not to be a new viewpoint.
[0072] Specifically, this application can also determine whether the second viewpoint generated by the large model is a new viewpoint. The second viewpoint is transformed into a vector through the embedding model to obtain the second vector corresponding to the second viewpoint; then, the second similarity value between the second vector and the vectors corresponding to each viewpoint included in the viewpoint library is calculated. The second similarity value can be a cosine similarity value.
[0073] If all second similarity values are less than or equal to the second preset threshold, that is, the second viewpoint is not similar to any of the viewpoints included in the viewpoint library, the second viewpoint can be determined to be a new viewpoint; if any of the second similarity values is greater than the second preset threshold, that is, the second viewpoint is similar to a certain viewpoint included in the viewpoint library, the second viewpoint can be determined not to be a new viewpoint.
[0074] Optionally, the method further includes: If it is determined that the second viewpoint is not a new viewpoint, the second viewpoint is added to the viewpoint list composed of each of the first viewpoints, and the second viewpoint is used as the first viewpoint. The step of generating the second viewpoint using a large model based on each of the first viewpoints and the information corresponding to each of the first viewpoints is repeated until the generated second viewpoint is a new viewpoint.
[0075] Specifically, if it is determined that the second viewpoint is not a new viewpoint, the second viewpoint is added to the viewpoint list composed of the first viewpoints, and the second viewpoint is used as the first viewpoint. The process of generating the second viewpoint using a large model based on the information corresponding to each first viewpoint is repeated. Based on the viewpoints included in the viewpoint library, it is determined whether the generated viewpoint is a new viewpoint, until the final generated second viewpoint is a new viewpoint.
[0076] Optionally, the method further includes: In the absence of the pre-built fact base, a third opinion is generated based on the first fact.
[0077] Specifically, after obtaining the target text input by the user and acquiring the first fact represented by the target text, it is also possible to determine whether a pre-built fact base exists. If no pre-built fact base exists, a third opinion can be directly generated based on the first fact.
[0078] Figure 2 This is the second flowchart of the viewpoint generation method based on a large model provided in this application, as shown below. Figure 2 As shown, the method includes steps 201-215.
[0079] Step 201: Obtain the target text input by the user.
[0080] Step 202: Determine if a fact base exists. If a fact base exists, proceed to step 203; if a fact base does not exist, proceed to step 214.
[0081] Step 203: Based on the first vector corresponding to the first fact represented by the target text, calculate the first similarity value between the first vector and the vectors corresponding to each fact included in the fact base.
[0082] Step 204: Determine whether the first similarity value is greater than the first preset threshold. If the first similarity value is greater than the first preset threshold, proceed to step 205; if the first similarity value is not greater than the first preset threshold, proceed to step 214.
[0083] Step 205: Determine at least one fact with a first similarity value greater than a first preset threshold and the information corresponding to each fact as at least one second fact corresponding to the first fact and the information corresponding to each second fact.
[0084] Step 206: For each target identifier of the second fact, determine the viewpoint and the information corresponding to the viewpoint in the pre-built viewpoint library as the first viewpoint and the information corresponding to the first viewpoint for the second fact.
[0085] Step 207: Combine the second fact, the first opinion corresponding to the second fact, and the information corresponding to the first opinion into an opinion list. Each element in the opinion list includes the first opinion, the second fact, and information. The information includes subject information, industry information, and focus information.
[0086] Step 208: Based on each second fact, each first viewpoint, and the information corresponding to each first viewpoint, use large model reasoning to generate second viewpoints.
[0087] Step 209: Based on the second vector corresponding to the second viewpoint, calculate the second similarity value between the second vector and the vectors corresponding to each viewpoint included in the viewpoint library.
[0088] Step 210: Determine whether each second similarity value is less than or equal to the second preset threshold. If each second similarity value is less than or equal to the second preset threshold, proceed to step 211; if any one of the second similarity values is greater than the second preset threshold, proceed to step 212.
[0089] Step 211: Determine the second viewpoint as the new viewpoint and output the second viewpoint.
[0090] Step 212: Determine that the second viewpoint is not a new viewpoint.
[0091] Step 213: Add the second viewpoint to the viewpoint list composed of each first viewpoint.
[0092] Step 214: Based on the first fact, generate a third viewpoint and output the third viewpoint.
[0093] Step 215, End.
[0094] The following is a specific example.
[0095] For example, if the goal is to generate a new perspective from the banking sector on the gradual improvement of the financial industry, the following operations will be performed during the generation of this solution: (1) Retrieve based on existing factual information and restrict meta information.
[0096] 1) The industry information is set to finance, the focus information is set to active, and the subject information is set to banking. The knowledge base search is limited, and the knowledge base includes content from different industries, different focuses, and different subjects.
[0097] 2) Based on existing facts, such as the central bank's reduction of the reserve requirement ratio, search the fact database to obtain some facts related to the existing facts.
[0098] (2) Associate the retrieved facts with the opinion base. The associated opinions may be as follows: 1) Subject: Bank; Focus: Positive; Industry: Finance; Fact: China Construction Bank's stock price has recently surged. Viewpoint: China Construction Bank has experienced rapid growth recently.
[0099] 2) Subject: Bank; Focus: Positive; Industry: Finance; Fact: The loan volume of ICBC has been steadily increasing in recent months.
[0100] (3) Integrating to generate new perspectives.
[0101] 1) Generate new viewpoints by reasoning through large models based on the above facts and viewpoints, such as: the central bank's reduction of the reserve requirement ratio is beneficial to major banks.
[0102] 2) Determine whether the generated new viewpoint is a new viewpoint by checking the viewpoint library. If it is not a new viewpoint, add the generated viewpoint to the viewpoint list composed of related viewpoints, and repeat the operation of generating new viewpoints through large model inference. If it is a new viewpoint, then generate a new viewpoint.
[0103] The method provided in this application generates viewpoints with clearly defined format information. It can use the same large model; by adjusting the model's temperature and other parameters to zero and then applying the large model for inference, if the generated viewpoints are highly repetitive, it indicates that the large model is suitable for the scheme proposed in this application. This method, combined with 6G networks, analyzes previous articles from different perspectives and locations, quickly generating novel viewpoints and providing new ideas for article writing.
[0104] The viewpoint generation apparatus based on a large model provided in this application is described below. The viewpoint generation apparatus based on a large model described below and the viewpoint generation method based on a large model described above can be referred to in correspondence.
[0105] Figure 3 This is a schematic diagram of the viewpoint generation device based on a large model provided in this application, such as... Figure 3 As shown, the viewpoint generation device 300 based on a large model includes: an acquisition module 301, a first determination module 302, and a first viewpoint generation module 303; wherein, Module 301 is used to acquire the target text input by the user; The first determining module 302 is configured to determine, based on the first fact represented by the target text, a pre-built fact library, and a pre-built opinion library, at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion; the fact library includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion library includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact library and the opinions in the opinion library are associated with target identifiers. The first viewpoint generation module 303 is used to generate second viewpoints based on each second fact, each first viewpoint, and the information corresponding to each first viewpoint, using large model reasoning.
[0106] The opinion generation apparatus based on a large model provided in this application obtains target text input by a user; based on the first fact represented by the target text, a pre-built fact library, and a pre-built opinion library, it determines at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion; the fact library includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion library includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact library and the opinions in the opinion library are associated with target identifiers; based on each second fact, each first opinion, and the information corresponding to each first opinion, a second opinion is generated through large model reasoning. By using the pre-built fact library and the pre-built opinion library, at least one second fact corresponding to the first fact, the first opinion corresponding to each second fact, and the information corresponding to each first opinion can be accurately determined, thereby enabling the generation of novel second opinions through large model reasoning, achieving the generation of new opinions, and improving the accuracy and efficiency of new opinion generation.
[0107] Optionally, the first determining module 302 is specifically used for: Based on the first fact represented by the target text, at least one second fact corresponding to the first fact and information corresponding to each second fact are determined from the pre-built fact base; Based on each second fact, the first viewpoint corresponding to each second fact and the information corresponding to each first viewpoint are determined from the pre-built viewpoint library.
[0108] Optionally, the first determining module 302 is further configured to: Based on the first vector corresponding to the first fact represented by the target text, calculate the first similarity value between the first vector and the vectors corresponding to each of the facts included in the fact base; At least one fact whose first similarity value is greater than a first preset threshold and the information corresponding to each of the facts are determined as at least one second fact corresponding to the first fact and the information corresponding to each of the second facts.
[0109] Optionally, the first determining module 302 is further configured to: For each target identifier of the second fact, the viewpoint corresponding to the target identifier and the information corresponding to the viewpoint in the pre-built viewpoint library are determined as the first viewpoint and the information corresponding to the first viewpoint corresponding to the second fact.
[0110] Optionally, the viewpoint generation device 300 based on a large model further includes: The first calculation module is used to calculate a second similarity value between the second vector corresponding to the second viewpoint and the vectors corresponding to each viewpoint included in the viewpoint library, based on the second vector corresponding to the second viewpoint. The second determining module is used to determine the second viewpoint as a new viewpoint when all of the second similarity values are less than or equal to the second preset threshold. The third determining module is used to determine that the second viewpoint is not a new viewpoint if any one of the second similarity values is greater than the second preset threshold.
[0111] Optionally, the viewpoint generation device 300 based on a large model further includes: An addition module is used to add the second viewpoint to the viewpoint list composed of each of the first viewpoints when it is determined that the second viewpoint is not a new viewpoint, and to repeatedly execute the step of generating the second viewpoint using a large model based on each of the first viewpoints and the information corresponding to each of the first viewpoints, until the generated second viewpoint is a new viewpoint.
[0112] Optionally, the viewpoint generation device 300 based on a large model further includes: The second opinion generation module is used to generate a third opinion based on the first fact in the absence of a pre-built fact base.
[0113] Optionally, the fact base is constructed based on the vectors corresponding to at least one fact in the textual descriptions of multiple existing articles and the information corresponding to each of the facts.
[0114] Optionally, the viewpoint generation device 300 based on a large model further includes: A segmentation module is used to segment the text of the article into a sequence of sentences for each of the facts described in the text of each article; The second calculation module is used to calculate a third similarity value between each sentence in the sentence sequence and the fact; The fourth determining module is used to determine that the fact originates from the article when the third similarity value is greater than or equal to the third preset threshold. The fifth determining module is used to determine that the fact does not originate from the article if the third similarity value is less than the third preset threshold.
[0115] Optionally, the opinion library is constructed based on multiple existing articles, using the vectors corresponding to the opinions generated by opinion generation prompts and the information corresponding to each opinion.
[0116] Optionally, the viewpoint generation device 300 based on a large model further includes: The judgment module is used to determine whether an opinion exists in the opinion library after the opinion generation prompt words generate an opinion; The third calculation module is used to calculate a fourth similarity value between the vector corresponding to the viewpoint generated by the viewpoint generation prompt and the vector corresponding to the viewpoint existing in the viewpoint library, when the viewpoint exists in the viewpoint library. The retrieval module is used to retrieve information corresponding to the viewpoint generated based on the viewpoint generation prompt words when the fourth similarity value is greater than or equal to the fourth preset threshold, and retrieve facts corresponding to the information from the fact base; The sixth determining module is used to determine that the viewpoint generated by the viewpoint generation prompt is an existing viewpoint if the fifth similarity value between the vector corresponding to the viewpoint generated by the viewpoint generation prompt and the vector corresponding to the retrieved fact is greater than or equal to a fifth preset threshold.
[0117] Optionally, the information includes subject information, industry information, and focus information.
[0118] Optionally, the viewpoint generation device 300 based on a large model further includes: The collection module is used to collect the subject information, the industry information, and the focus information, and generate corresponding lists based on the subject information, the industry information, and the focus information.
[0119] Figure 4 This is a schematic diagram of the physical structure of an electronic device provided in this application, such as... Figure 4 As shown, the electronic device 400 may include: a processor 410, a communications interface 420, a memory 430, and a communication bus 440, wherein the processor 410, the communications interface 420, and the memory 430 communicate with each other through the communication bus 440. The processor 410 can call logical instructions in the memory 430 to execute a large-model-based opinion generation method, which includes: acquiring target text input by a user; determining at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion based on a first fact represented by the target text, a pre-built fact base, and a pre-built opinion base; the fact base includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion base includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact base and the opinions in the opinion base are associated with target identifiers; and a second opinion is generated using large-model reasoning based on each second fact, each first opinion, and the information corresponding to each first opinion.
[0120] Furthermore, the logical instructions in the aforementioned memory 430 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0121] On the other hand, this application also provides a computer program product, which includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the large-model-based opinion generation method provided by the above methods. The method includes: acquiring target text input by a user; determining at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion based on a first fact represented by the target text, a pre-built fact base, and a pre-built opinion base; the fact base includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion base includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact base and the opinions in the opinion base are associated with target identifiers; and generating a second opinion using large-model reasoning based on each second fact, each first opinion, and the information corresponding to each first opinion.
[0122] In another aspect, this application also provides a non-transitory computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the large-model-based opinion generation method provided by the above methods. This method includes: acquiring target text input by a user; determining at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion based on a first fact represented by the target text, a pre-built fact base, and a pre-built opinion base; the fact base includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion base includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact base and the opinions in the opinion base are associated using target identifiers; and generating a second opinion using large-model reasoning based on each second fact, each first opinion, and the information corresponding to each first opinion.
[0123] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0124] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0125] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application.
Claims
1. A viewpoint generation method based on a large model, characterized in that, include: Get the target text input by the user; Based on the first fact represented by the target text, a pre-built fact base, and a pre-built opinion base, at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion are determined; the fact base includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion base includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact base and the opinions in the opinion base are associated with target identifiers. Based on each second fact, each first viewpoint, and the information corresponding to each first viewpoint, a large model inference is used to generate the second viewpoint.
2. The viewpoint generation method based on a large model according to claim 1, characterized in that, The process of determining at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion, based on the first fact represented by the target text, a pre-built fact base, and a pre-built opinion base, includes: Based on the first fact represented by the target text, at least one second fact corresponding to the first fact and information corresponding to each second fact are determined from the pre-built fact base; Based on each second fact, the first viewpoint corresponding to each second fact and the information corresponding to each first viewpoint are determined from the pre-built viewpoint library.
3. The viewpoint generation method based on a large model according to claim 2, characterized in that, The step of determining at least one second fact corresponding to the first fact and information corresponding to each second fact from the pre-built fact base based on the first fact represented by the target text includes: Based on the first vector corresponding to the first fact represented by the target text, calculate the first similarity value between the first vector and the vectors corresponding to each of the facts included in the fact base; At least one fact whose first similarity value is greater than a first preset threshold and the information corresponding to each of the facts are determined as at least one second fact corresponding to the first fact and the information corresponding to each of the second facts.
4. The viewpoint generation method based on a large model according to claim 2, characterized in that, The step of determining the first opinion corresponding to each second fact and the information corresponding to each first opinion from the pre-built opinion library based on each second fact includes: For each target identifier of the second fact, the viewpoint corresponding to the target identifier and the information corresponding to the viewpoint in the pre-built viewpoint library are determined as the first viewpoint and the information corresponding to the first viewpoint corresponding to the second fact.
5. The viewpoint generation method based on a large model according to claim 1, characterized in that, The method further includes: Based on the second vector corresponding to the second viewpoint, calculate the second similarity value between the second vector and the vectors corresponding to each viewpoint included in the viewpoint library; If each of the second similarity values is less than or equal to the second preset threshold, the second viewpoint is determined to be a new viewpoint; If any one of the second similarity values is greater than the second preset threshold, it is determined that the second viewpoint is not a new viewpoint.
6. The viewpoint generation method based on a large model according to claim 1, characterized in that, The method further includes: If it is determined that the second viewpoint is not a new viewpoint, the second viewpoint is added to the viewpoint list composed of each of the first viewpoints, and the second viewpoint is used as the first viewpoint. The step of generating the second viewpoint using a large model based on each of the first viewpoints and the information corresponding to each of the first viewpoints is repeated until the generated second viewpoint is a new viewpoint.
7. The viewpoint generation method based on a large model according to claim 1, characterized in that, The method further includes: In the absence of the pre-built fact base, a third opinion is generated based on the first fact.
8. The viewpoint generation method based on a large model according to claim 1, characterized in that, The fact base is constructed based on the vectors corresponding to at least one fact in the textual descriptions of multiple existing articles and the information corresponding to each fact.
9. The viewpoint generation method based on a large model according to claim 8, characterized in that, The method further includes: For each of the facts described in the text of each of the articles, the text of the article is segmented into a sequence of sentences; Calculate the third similarity value between each sentence in the sentence sequence and the fact; If the third similarity value is greater than or equal to the third preset threshold, it is determined that the fact originates from the article; If the third similarity value is less than the third preset threshold, it is determined that the fact does not originate from the article.
10. The viewpoint generation method based on a large model according to claim 1, characterized in that, The opinion database is constructed based on multiple existing articles, using vectors corresponding to the opinions generated by opinion generation prompts and information corresponding to each opinion.
11. The viewpoint generation method based on a large model according to claim 10, characterized in that, The method further includes: After the opinion generation prompts generate an opinion, it is determined whether an opinion exists in the opinion library; If opinions exist in the opinion library, calculate a fourth similarity value between the vector corresponding to the opinion generated by the opinion generation prompt and the vector corresponding to the opinion existing in the opinion library; If the fourth similarity value is greater than or equal to the fourth preset threshold, the information corresponding to the viewpoint generated based on the viewpoint generation prompt word is retrieved from the fact base to find the facts corresponding to the information. If the fifth similarity value between the vector corresponding to the viewpoint generated by the viewpoint generation prompt and the vector corresponding to the retrieved fact is greater than or equal to the fifth preset threshold, the viewpoint generated by the viewpoint generation prompt is determined to be an existing viewpoint.
12. The viewpoint generation method based on a large model according to any one of claims 1 to 11, characterized in that, The information includes subject information, industry information, and focus information.
13. The viewpoint generation method based on a large model according to claim 12, characterized in that, The method further includes: Collect the subject information, the industry information, and the focus information, and generate corresponding lists based on the subject information, the industry information, and the focus information.
14. A viewpoint generation device based on a large model, characterized in that, include: The acquisition module is used to acquire the target text input by the user; A first determining module is used to determine, based on the first fact represented by the target text, a pre-built fact library, and a pre-built opinion library, at least one second fact corresponding to the first fact, a first opinion corresponding to each second fact, and information corresponding to each first opinion; the fact library includes vectors corresponding to multiple facts and information corresponding to each fact; the opinion library includes vectors corresponding to multiple opinions and information corresponding to each opinion; the facts in the fact library and the opinions in the opinion library are associated with target identifiers. The opinion generation module is used to generate second opinions based on each second fact, each first opinion, and the information corresponding to each first opinion, using large model reasoning.
15. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the viewpoint generation method based on a large model as described in any one of claims 1 to 13.
16. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the viewpoint generation method based on a large model as described in any one of claims 1 to 13.
17. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the viewpoint generation method based on a large model as described in any one of claims 1 to 13.