Data storage and management system capable of analyzing user scene and large-scale data

Through the design of the brain-like database system, the abstract access module and access community mechanism are used, combined with human feedback to reinforce learning, the problem of frequent calls of large language models is solved, the system efficiency and adaptability are improved, and the computing power cost is reduced .

CN118964413APending Publication Date: 2024-11-15BEIJING CORE WATER TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410635293.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-21
Publication Date
2024-11-15

AI Technical Summary

Technical Problem

The frequent call of existing large language models when users ask questions leads to waste of computing resources and performance bottlenecks. How to reduce the number of calls of large language models and improve system efficiency while ensuring query accuracy and real-time.

Method used

Design a brain-like database system to dynamically manage user scenarios and data information through abstract access modules, dynamic storage mechanisms based on access communities, structured organization and human feedback reinforcement learning, and reduce the number of calls to big models.

Benefits of technology

A multi-level, dynamic and intelligent query processing system is realized, which improves the system's parallel processing capabilities and efficiency, reduces the cost of computing power, is suitable for various computing devices, and reduces the redundant operation of the data query process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118964413A_ABST
    Figure CN118964413A_ABST
Patent Text Reader

Abstract

The invention provides a data storage and management system capable of analyzing a user scene and large-scale data, and relates to the technical field of large language models. According to the data storage and management system capable of analyzing the user scene and the large-scale data, an operation mechanism and a principle of a cortical column of a human brain are enlighted, and an access module in a calculation device, used for storing and processing data information, of a related system is integrated into an access community form; and redundant operations in an information retrieval process are reduced through a community communication mechanism among access communities. According to the method, improvements are brought to the aspects of improving data storage efficiency, adaptability and intelligence of a query system for complex scenes, computing power, energy efficiency of a data query process and the like, technical support is provided for a new-generation data storage management system based on a large model, the use mode of the large language model in a user scene is optimized, and the user experience is improved. And the parallel processing capability and efficiency of the system are improved, so that the consumption of system resources is reduced on the premise of meeting user requirements.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of large language models, and in particular to a data storage and management system capable of analyzing user scenarios and large-scale data. Background Art

[0002] Large pretrained language models (LLMs) based on Transformer and other model structures use deep learning and natural language processing techniques to build models that can generate natural and fluent text by training large-scale text data. Their training process usually requires a lot of computing resources and massive amounts of text data in order to learn rich language patterns and knowledge. These models perform well in various natural language processing tasks, including text generation, machine translation, question-answering systems, etc. In recent years, due to technological advances and the availability of large-scale datasets, large language model technology has made significant progress and has attracted widespread attention and application in academia and industry.

[0003] RAG (Retrieval Augmented Generation) technology is a method that combines information retrieval and natural language generation. Its background can be simply described as that traditional generation models (such as language models) may be limited by existing corpora when generating text, resulting in the lack of relevance or diversity of the generated text. In order to solve this problem, RAG technology introduces the idea of ​​information retrieval, first obtaining information related to the text to be generated through the retrieval engine, and then generating text based on this information, thereby improving the relevance and diversity of the generated text.

[0004] A database system (DB) is a software system that can store, manage, and retrieve data. The principles of the database system are based on a series of data structures and algorithms, aiming to achieve efficient storage, fast retrieval, and reliable management of data. Among them, relational databases are one of the most common types, which organize data in the form of tables and perform data operations and retrieval through structured query language (SQL). Emerging database technologies such as non-relational databases (NoSQL) also provide more flexible solutions for scenarios of different types and sizes.

[0005] In real-world application scenarios, users often need to connect their private databases to large models, allowing the large models to generate answers to users' questions based on the content in the private databases. RAG technology can effectively improve the large model's ability to access and understand external databases by performing similarity retrieval on data in external databases and reducing the input text size of large models, but this will still result in significant resource waste and performance degradation. Moreover, the RAG-based intelligent query and question-answering system still requires high-frequency calls to large models. Every question asked by the user will trigger a call to a large language model. This process not only consumes a lot of computing resources, but may also lead to system performance bottlenecks. Therefore, how to effectively utilize users' historical query records and generated answers to avoid frequent calls to large language models while ensuring query accuracy and real-time performance is an important research topic in the current field of intelligent query processing.

[0006] To this end, we have developed a new data storage and management system that can analyze user scenarios and large-scale data. Summary of the invention

[0007] 1. Technical issues to be resolved

[0008] In view of the shortcomings of the prior art, the present invention provides a data storage and management system that can analyze user scenarios and large-scale data. It draws on the memory access mechanism of the human brain and designs a brain-like database system that can fully understand user scenarios. It can dynamically reconstruct and organize the user's historical query information and the existing information in the database, and store them together in a more densely structured access community-based form, thereby greatly improving the interoperability between database information and user scenarios, and can effectively reduce the number of actual calls to the large language model while ensuring that the quality of the query information is not affected.

[0009] (II) Technical solution

[0010] To achieve the above objectives, the present invention is implemented through the following technical solutions: a data storage and management system capable of parsing user scenarios and large-scale data, including five data storage modules, the five modules forming a whole, and the overall function is a dynamic intelligent management mechanism capable of efficiently storing and reading data information, wherein the five modules are:

[0011] Module 1: Abstract graph representation of the access module of computing devices;

[0012] Module 2: Dynamic storage mechanism of data information based on access community;

[0013] Module 3: Structuring the stored data information;

[0014] Module 4: Intelligently organize the stored data information, extract information, and assign tasks based on user questions;

[0015] Module 5: Reinforcement learning mechanism based on human feedback to iterate the trainable parameters of this system;

[0016] First, each data access module of the processor involved in data storage and their relationship are expressed as a trainable multi-dimensional vector representation, and combined with the topological relationship of the physical form between each access module to form a specific directed graph representation;

[0017] The representation of each access module should include the access speed, total capacity, occupied capacity, etc. of the access module, and the physical relationship between the access modules should be expressed as a trainable embedded vector representation of a specific dimension;

[0018] Subsequently, the user's data information is encoded using a text encoder to obtain an embedded high-dimensional vector representation of the data information, and clustered according to the semantic similarity between the high-dimensional vectors. The central vectors of each cluster at different positions are then stored one by one in each access module of the computing device.

[0019] Among them, the data information involved is mainly divided into two categories:

[0020] The first type is declarative data used to present facts and information;

[0021] The second category is generated data based on user questions and user scenarios, which includes three parts:

[0022] Part 1: User questions: User questions about specific scenarios;

[0023] Part 2: Generate answers: The answers generated by the system or large model for the question statement;

[0024] Part 3, Expert Rating: An expert group composed of human experts or larger models evaluates the quality of the answers generated by the system in response to user questions.

[0025] Preferably, two nonlinear mappers that can be iteratively trained by supervised learning are constructed to specifically process in which access module new data information to be stored should be stored;

[0026] The inputs of the two mappers are: the semantic relationship between the data information to be stored and the stored data information, the intrinsic properties of a specific access module of the computing device and the topological relationship between it and other access modules;

[0027] The sum of the outputs of the two mappers is equivalent to the probability or rationality that the data information to be stored should be stored in a specific access module.

[0028] Preferably, according to the semantic similarity of data information stored in different access modules of the computing device, the related access modules are merged into an access community, and a dedicated nonlinear mapper is configured for the access community, which are:

[0029] State mapper: obtains the state representation of the current access community;

[0030] Communication mapper: uses the shared access module shared by different access communities as a transfer station to coordinate information communication between adjacent access communities;

[0031] Output mapper: determines which internal access module's data information will be used as output.

[0032] Preferably, the retrieval process for the user query statement does not need to involve all the data information contained in all the access modules, but first takes the access community as a unit, uses the communication mapper of each access community to simulate the communication process between communities, and then uses the output representation generated by each community in the communication process as a judgment basis. If the output representation of a community meets specific conditions, then use the output mapper of each community to perform further query retrieval on the data information of the access module contained in the community;

[0033] Among them, the state representation of the access community is generally calculated in advance by its own state mapper, and the specific composition of the access community, that is, to which access community each access module should be assigned, is determined by the global allocation function. The specific parameters of this function are determined by the expert group's score on the system output results, that is, the trainable parameters of the relevant trainable allocation function are iteratively updated through reinforcement learning based on human feedback;

[0034] The data information within each access community should be organized in real time or regularly by a specific large model to generate a text summary that can cover its basic information. The text summary is stored in the specific access module of the community and supports human experts to verify and modify it.

[0035] Preferably, with the help of a nonlinear mapper that can be iteratively trained through supervised learning, the pre-deployed large models with different attributes are dynamically allocated according to the semantic relevance between user questions and the generative data initially retrieved, and the objective function is to minimize the computing power cost generated during the actual call of the large model.

[0036] Preferably, the obtained nonlinear mapper that can be iteratively trained by supervised learning should have the following allocation strategies including but not limited to:

[0037] If the user's question is extremely relevant to the generated data retrieved initially, and the expert scores corresponding to these generated data exceed a specific threshold, then the generated answers corresponding to these generated data only need to be merged, and then text fusion is performed with the help of small model-based text generation technology to serve as the output of the user's question;

[0038] If the user's question is weakly correlated with the generated data retrieved initially, and the expert scores corresponding to these generated data exceed a certain threshold, then we only need to merge the generated answers corresponding to these generated data, and then combine them with reasonable prompt engineering as the input prompt words of a slightly smaller-scale large model, and finally get the output of the user's question;

[0039] If the user's question does not have a significant correlation with the generative data initially retrieved, a larger model is selected based on the current data to obtain the output of the user's question.

[0040] (III) Beneficial effects

[0041] The present invention provides a data storage and management system capable of analyzing user scenarios and large-scale data. It has the following beneficial effects:

[0042] 1. The present invention proposes a multi-level, dynamic, and intelligent query processing system and method, which effectively utilizes the user's historical query information, reduces the system's dependence on large language models, improves the system's parallel processing capabilities and efficiency, and has high practical value and application prospects.

[0043] 2. The present invention proposes an abstract representation of access modules applicable to various computing devices, thereby improving the applicability and compatibility of the technology involved in the present invention.

[0044] 3. The present invention proposes a social communication mechanism that is more in line with the operating mechanism of the human brain, which can significantly reduce redundant operations in the data query process and improve the energy efficiency of data information storage and query processes.

[0045] 4. The present invention constructs a dynamic and intelligent data information storage allocation mechanism, which can combine the new data information to be stored with its own semantic relevance with other stored information, the current status of available access modules and their topological relationship, to obtain a more reasonable data storage solution, which fully takes into account the storage and reading efficiency of data.

[0046] 5. The present invention implements a dynamic query mechanism for user questions, which can combine relevant factors such as user requests, historical data, user scenarios, etc. to make more reasonable task allocation for query devices (for example, large models) deployed in the query system, thereby significantly reducing computing power costs at the product and scenario application levels.

[0047] 6. The present invention uses reinforcement learning and other technical means to dynamically embed human feedback into various trainable modules in the system, so that the system can be adjusted in real time according to scene changes, with stronger adaptability and robustness. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] Figure 1 It is the operation principle diagram of the five modules of the present invention;

[0049] Figure 2 A simplified schematic diagram of the structure of a brain-like system including three access communities of the present invention;

[0050] Figure 3 It is a schematic diagram of the structure of the directed graph representation of the access module of the present invention. DETAILED DESCRIPTION

[0051] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0052] Embodiment 1:

[0053] like Figure 1 As shown, the embodiment of the present invention provides a data storage and management system capable of parsing user scenarios and large-scale data, including five data storage modules, which constitute a whole, and the overall function is a dynamic intelligent management mechanism capable of efficiently storing and reading data information, wherein the five modules are:

[0054] Module 1: Abstract graph representation of the access module of computing devices;

[0055] Module 2: Dynamic storage mechanism of data information based on access community;

[0056] Module 3: Structuring the stored data information;

[0057] Module 4: Intelligently organize the stored data information, extract information, and assign tasks based on user questions;

[0058] Module 5: Reinforcement learning mechanism based on human feedback to iterate the trainable parameters of this system;

[0059] Specifically, module one: expressing each access module of the computing device in the form of an abstract graph representation, thereby ensuring that the relevant contents of the present invention are not affected to the greatest extent by the design differences of the computing device.

[0060] Given that different types of processors such as CPU, GPU, and TPU rely on different computing architectures, in order to prevent the invention from being limited by a specific computing architecture, we need to first simplify the physical carriers that store data information. We represent the access module of data information in the physical carrier with a D-dimensional vector To express it, the vector can be analogous to the address of the stored data, but it is worth noting that the vector is a trainable embedded representation (analogous to the word vector in the large model, i.e., word embedding). The initial value of the vector is randomly initialized, and the specific value of the vector can be iteratively updated through supervised learning.

[0061] In addition, we agree that the superscript l∈[1,L] of the vector represents the level of the physical location. Generally speaking, as l becomes smaller, The data access speed of the corresponding access module (marked as a positive real number ) tends to be faster, but the storage capacity of the physical location (marked as a positive real number ) tends to be smaller. For example, Can correspond to disk, It can correspond to the register in GPU. It can correspond to the shared memory (Shared Memory) in the GPU, etc., and the expression is not unique.

[0062] For access modules at the same level but with different functions, the subscript i can be used to distinguish them. For example, we can mark the physical location of the first-level cache (L1 Cache) at the same level as the shared memory in the GPU as Obviously, we can interpret the relationship between these vectors as a directed graph. Based on this setting, each vector can also be interpreted as a node. and The relationship between Generally speaking, the relationships between components are pre-set and cannot be changed, but the vector representation of these relationships can be iteratively updated through supervised training.

[0063] We also use the current state of each access module as a D-dimensional vector Abstract representation, the vector contains the status of the current access module, including but not limited to: occupied capacity, remaining capacity, etc.

[0064] With the help of the above-mentioned abstract expression, we can improve the versatility of the present invention for different computing systems.

[0065] Similarly, module two: dynamically allocates newly entered data information to be stored to a designated location based on the data information already stored in each access module of the current computing device, so as to maximize the access efficiency of the data information in a specific user scenario.

[0066] Assume that each access module of the current computing device has stored a series of data information, and the properties, states, relationships between each access module of the computing device and other information can also be obtained by the abstract representation method described in Module 1.

[0067] It is worth noting that the data information involved in the present invention is expressed in the form of a high-dimensional vector (the dimension is temporarily replaced by D. In practical applications, the specific dimension may vary, and the dimensions of the high-dimensional vectors of data information located in different access modules do not need to be exactly the same). Generally speaking, the high-dimensional vector is obtained by a special pre-trained embedding model (EmbeddingModel). The input of such an embedding model (for example, BERT, ACGE, etc.) is the tokens of the data information and its index, and the output is a high-dimensional embedded representation of the data information, that is, a sentence vector.

[0068] Stored in a read module The data information can be marked as

[0069] First, the high-dimensional vector representation of the data information to be stored is calculated (marked as ) and the semantic similarity between the high-dimensional vector representation of the representative data information stored in each access module of the computing device. Module 3 will specifically explain how to select data information that can represent each access module.

[0070] The calculation methods of semantic similarity include but are not limited to: cosine similarity, Minkowski similarity. We mark the semantic similarity between the data information to be stored and the stored data information as

[0071] The data information q to be stored should be stored in a certain access module The probability of is obtained by several nonlinear mappers (e.g., multilayer perceptron, deep neural network, etc.) that can be trained by supervised learning methods. The input of the mapper is: the data information q to be stored, the access module and its related attributes (access speed, current status, etc.), the semantic similarity between the information to be stored and the access module Other access modules associated with this access module, and so on. The specific expression is:

[0072]

[0073] in, and Both are nonlinear mappers that can be trained using supervised learning methods. * Represents the current access module Adjacent or existing relationship The superscript of the access module to which it is associated, i.e. and Through the relationship The remaining symbols are as follows The meaning of has been explained in the above formula.

[0074] The training objective function of the supervised learning of the above expression can be constructed by a series of empirical strategies c with practical significance. The choice of specific empirical strategies is not unique, for example:

[0075] If the data to be stored q is associated with a certain access module If the semantic similarity of a representative data information exceeds a certain threshold and the access module still has sufficient storage space, q can be stored in the access module.

[0076] If the data to be stored q has a high semantic similarity with the representative data information of a series of access modules, it means that data q is a relatively common data information, so we can store q in l m represents the smallest superscript in the aforementioned series of access modules that have a high semantic similarity with q. This strategy can be briefly understood as: the more frequently used data will be stored in the access module that is easier to read.

[0077] If the highest value of the semantic similarity between the data q to be stored and the representative data information of each access module is still lower than a certain threshold, it means that the data q is uncommon data information, and we can preferentially store it in the access module with a larger l value, that is, the less frequently used data will be stored in the access module that is more difficult to read.

[0078] In practical applications, the data information in the access module is divided into two categories: the first category is declarative data used to explain facts and information, which is also the most common data in the database; the second category is generative data combined with user questions and user scenarios. This type of data often contains three parts. The first part is user questions (user question statements for specific scenarios), the second part is generated answers (the answers generated by this system or large model for the question statements), and the third part is expert scores (human experts score the quality of the answers generated by this system for user questions).

[0079] From a vertical perspective, the human cerebral cortex, which is responsible for thinking and memory storage, has about six layers of cortex, each with its own neuronal distribution and neuronal functions. The basic computing unit commonly found in the cerebral cortex is a vertical organization that runs through all six layers, namely, the cortical column, which constitutes the human brain's storage (memory) and reading (recall) of data information. A single cortical column contains 50-100 micro-cortical columns, and a single micro-cortical column contains about 110 neurons, running through the six layers of the cerebral cortex.

[0080] A series of access modules at different levels (distinguished by the superscript l) are classified as an access group, called an access community. A single access community often contains a series of access modules at different levels, but the data information stored in a single access community often has similar or related semantic features. Some access modules may be shared by different access communities, and such access modules are often responsible for community communication between different access communities.

[0081] With this access community mechanism, when we perform data query, we do not need to search each access module one by one. We only need to conduct a broader and macro query on the group (access community) of each access module, and then decide whether to conduct a more in-depth and specific query on the access module within it based on the query results of each community. This can greatly reduce the number of operations in the query process and improve the efficiency of information retrieval.

[0082] With the help of the aforementioned concept of access community, the method described in

[0015] for calculating the probability that new data information is assigned to a specific access module can be expanded to a specific data information query mechanism.

[0083] The concept of access community can also be expanded to a specific data information storage mechanism, by simply adjusting the meaning of the application method of the third mapper pair, that is, the output value for each access module represents the probability or rationality of storing the Query (which should also be adjusted to generative data here) in the access module.

[0084] like Figure 2 As shown in Figure 1, the input of the system is user questions (Query), and the output is retrieval results (Retrievals). Each access community is embedded with three nonlinear mappers (e.g., multilayer perceptron, deep neural network, etc.) that can be trained through supervised learning. The specific functions are:

[0085] The first mapper is used to obtain the state representation of the current access community. It takes the state of each access module within the access community, the relationship between access modules and other information as input, and finally outputs a high-dimensional vector as the state representation of the current access community, thereby representing the state and identity of the current access community. This mapper only performs operations when the data information stored in the access community changes. In other regular queries, there is no need to repeat the operation.

[0086] The second type of mapper is used to coordinate information communication between adjacent communities. Its input is: the high-dimensional representation corresponding to the user's question, the community's own state representation, the adjacent community's state representation, and the adjacent community's output representation. Finally, a high-dimensional vector is obtained as the community's own output representation, and as the input of its adjacent access community, thus forming a dynamic recursive communication behavior. This ensures that each access community can communicate with each other, thereby capturing more comprehensive search dynamics and greatly improving the search accuracy and recall rate.

[0087] The third type of mapper is specifically used to determine which access module in the current access community should use as the output of the data information. It first makes a judgment based on its own output representation obtained above. If the output representation exceeds a specific threshold after a specific regularization operation (for example, obtaining its L1-norm), the mapper will use its own state representation and the user's question as input, and obtain the output probability value of each access module through a nonlinear mapping (the state representation as input is equivalent to the above q). This value represents the probability or rationality that the data information in each access module should be used as the output of the current query. Combined with this value, the data information of each access module is summarized to obtain the community-level retrieval results (Retrievals).

[0088] Module 3: Structural organization of stored data information, including but not limited to: merging duplicate data with extremely high semantic similarity, moving up the hierarchy of commonly used data, moving down the hierarchy of infrequently used data, removing or adding access modules within the access community, etc.

[0089] For larger access communities, a large model should be used regularly to summarize the data information stored internally, generate text summaries, and store them in the community's specific access module, allowing a human expert group to verify and modify the relevant text summaries.

[0090] For access modules that are not allocated reasonably, human intervention is allowed, that is, a specific access module is forcibly allocated to a specific access community.

[0091] Module 4: Summarize and extract the stored data information according to the user's questions to obtain as little data information as possible that is strongly related to the user's questions.

[0092] Referring to the above-mentioned relevant definitions, if the user's question is strongly correlated with the user's question of certain stored generative data (the first part), and the expert score of the set of generative data (the third part) exceeds a certain threshold, the generated answer (the second part) of the generative data can be directly output to the user.

[0093] For relatively new user questions, that is, the user's questions do not have a strong correlation with any user questions in the stored generated data, we need to summarize and extract the data information stored in the database for the user questions.

[0094] Construct a metric function that can be iteratively trained through supervised learning (for example, a multi-layer perceptron, a deep neural network, etc.), input the high-dimensional vector representation of the user's question and the state representation of each access community into the metric function, and the output value represents the potential semantic correlation between the user's question and the data information stored in the access module within the access community.

[0095] If the value output by the metric function exceeds a certain threshold, the high-dimensional vector representation of the data information stored in the access module within the access community is also extracted, and the semantic similarity between them and the high-dimensional representation of the user's question is calculated. The data information whose semantic similarity exceeds a certain threshold is then extracted as input instructions for a billion-level parameter model (for example, LLaMA3-8B, etc.).

[0096] If the output values ​​of the metric functions of each access community do not exceed a certain threshold, then based on the above, a group of access communities with the highest semantic relevance to the user's question are selected, and the data information contained in this group of access communities is extracted as input for a large model with a larger parameter scale (for example, LLaMA3-70B, etc.).

[0097] The above method can be generalized by using a trainable nonlinear mapping to associate the semantic correlation between user questions and the state representation of the access community with the properties of the large model finally selected as the generator. That is, based on the user questions and the state representation of each access community, the system can know which specific large model should be selected to generate an answer to the user question.

[0098] Module 5: A human expert group or a larger large-scale large-model expert group evaluates the output generated by the current large-model, and generates question-answer data pairs that are easy to summarize and organize based on the evaluation results and user questions, and uses them as new data information, combined with the method of module 2, to store them in various access modules. In addition, the entire system will also combine the expert group to conduct reinforcement learning on each generation result of the large model, so as to update the nonlinear mappers involved in the entire system that can be iteratively trained through supervised learning methods (for example, multi-layer perceptrons, deep neural networks).

[0099] First, each data access module of the processor involved in data storage and their relationship are expressed as a trainable multi-dimensional vector representation, and combined with the topological relationship of the physical form between each access module to form a specific directed graph representation;

[0100] The representation of each access module should include the access speed, total capacity, occupied capacity, etc. of the access module, and the physical relationship between the access modules should be expressed as a trainable embedded vector representation of a specific dimension;

[0101] Subsequently, the user's data information is encoded using a text encoder to obtain an embedded high-dimensional vector representation of the data information, and clustered according to the semantic similarity between the high-dimensional vectors. The central vectors of each cluster at different positions are then stored one by one in each access module of the computing device.

[0102] Among them, the data information involved is mainly divided into two categories:

[0103] The first type is declarative data used to present facts and information;

[0104] The second category is generated data based on user questions and user scenarios, which includes three parts:

[0105] Part 1: User questions: User questions about specific scenarios;

[0106] Part 2: Generate answers: The answers generated by the system or large model for the question statement;

[0107] Part 3, Expert Rating: An expert group composed of human experts or larger models evaluates the quality of the answers generated by the system in response to user questions.

[0108] By constructing two nonlinear mappers ("task allocators") that can be iteratively trained through supervised learning, they are specifically used to process which access module the new data information to be stored should be stored in;

[0109] The inputs of the two mappers are: the semantic relationship between the data information to be stored and the stored data information, the intrinsic properties of a specific access module of the computing device and the topological relationship between it and other access modules;

[0110] The sum of the outputs of the two mappers is equivalent to the probability or rationality that the data information to be stored should be stored in a specific access module.

[0111] According to the semantic similarity of the data information stored in different access modules of the computing device, the related access modules are merged into an access community, and a dedicated nonlinear mapper is configured for the access community, which are:

[0112] State mapper: obtains the state representation of the current access community;

[0113] Communication mapper: uses the shared access module shared by different access communities as a transfer station to coordinate information communication between adjacent access communities;

[0114] Output mapper: determines which internal access module's data information will be used as output.

[0115] The retrieval process for user query statements does not need to involve all the data information contained in all access modules. Instead, the communication process between communities is simulated using the communication mapper of each access community, and then the output representation generated by each community during the communication process is used as the basis for judgment. If the output representation of a community meets specific conditions, the output mapper of each community is used to perform further query retrieval on the data information of the access modules contained in the community.

[0116] Among them, the state representation of the access community is generally calculated in advance by its own state mapper. Unless the internal information of the access community changes (addition or removal of access modules, modification of data information within the access module, etc.), the state representation of each access community does not need to be recalculated. The specific composition of the access community, that is, to which access community each access module should be assigned, is determined by the global allocation function. The specific parameters of this function are determined by the expert group's score for the system output results, that is, the trainable parameters of the relevant trainable allocation function are iteratively updated through reinforcement learning based on human feedback;

[0117] The data information within each access community should be organized in real time or regularly by a specific large model to generate a text summary that can cover its basic information. The text summary is stored in the specific access module of the community and supports human experts to verify and modify it. In addition, the specific composition of the access community also supports the customization of a priori or manually intervened allocation strategies.

[0118] With the help of a nonlinear mapper that can be iteratively trained through supervised learning, the pre-deployed large models with different attributes are dynamically allocated according to the semantic relevance between user questions and the generative data initially retrieved. The objective function is to minimize the computing power cost generated during the actual call of the large model.

[0119] The resulting nonlinear mapper that can be iteratively trained through supervised learning should have allocation strategies including but not limited to the following:

[0120] If the user's question is extremely relevant to the generated data retrieved initially, and the expert scores corresponding to these generated data exceed a specific threshold, then the generated answers corresponding to these generated data only need to be merged, and then text fusion is performed with the help of small model-based text generation technology to serve as the output of the user's question;

[0121] If the user's question is weakly correlated with the generated data retrieved initially, and the expert scores corresponding to these generated data exceed a certain threshold, then we only need to merge the generated answers corresponding to these generated data, and then combine them with reasonable prompt engineering as the input prompt words of a slightly smaller-scale large model, and finally get the output of the user's question;

[0122] If the user's question does not have a significant correlation with the generative data initially retrieved, a larger model is selected based on the current data to obtain the output of the user's question.

[0123] Embodiment 2:

[0124] like Figure 3As shown, each specific access module of the basic constituent element SM (Streaming Multiprocessor) of the GPU is expressed in the form of a graph representation.

[0125] The data information involved in the present invention is divided into two categories: the first category is declarative data used to explain facts and information, which is also the most common data in the database; the second category is generative data combined with user questions and user scenarios, which often includes three parts: user questions, generated answers, and expert evaluations.

[0126] Generally speaking, declarative data is expressed in the form of a whole string, and generative data is expressed in the form of a string containing specific key values, for example, {"user question": "xxx", generated answer: "yyy", "expert evaluation": "zzz"}.

[0127] This system pre-deploys several embedding models (i.e., Embedding Model, for example, aspire / acge_text_embedding, infgrad / stella-large-zh-v3-1792d, BAAI / bge-large-zh-v1.5) as text encoders, which are specifically used to convert user data information (mainly in the form of strings) into high-dimensional vectors.

[0128] These high-dimensional vectors are clustered, that is, vectors with a certain degree of similarity are grouped together. The size of each generated cluster (the number of vectors contained in the cluster) and the center vector of the cluster (the vector with the shortest average distance to other vectors in the cluster) are then marked.

[0129] Similarly, the second center vector (the vector with the second shortest average distance to other vectors of the cluster), the third center vector, and so on of each cluster are marked. Generally speaking, in practical applications, only the third center vector needs to be marked. The "first", "second" and "third" mentioned here can also be referred to as the positions of these center vectors.

[0130] The first, second, and third central variables of each cluster are sorted and marked according to the size of the cluster to which they belong. The specific marking strategy is: if the size of the cluster to which a central vector belongs is larger and the ranking of the vector is higher, the central vector should be stored in a higher-level access module; if the semantic similarity between two central vectors is higher (the shorter the distance in high-dimensional space), the access modules to which the two vectors belong should be assigned to the same access community.

[0131] An access module may be assigned to multiple access communities at the same time. An access module with such a feature is also called a shared access module. Each access community has at least one shared access module, which is mainly responsible for the communication process between different access communities.

[0132] For the allocation mechanism of new data information to be stored, in addition to using the formula described in Example 1, a series of empirical strategies are also used. In general, the system will determine which access module in which access community the data information to be stored should be stored in based on factors such as the semantic similarity between the data information to be stored and other stored data information, the intrinsic properties of each access community and the topological relationship between each other, the intrinsic properties of each access module within each access community and the topological relationship between each other, etc.

[0133] The access community, which is composed of a series of access modules, comes with three nonlinear mappers, which are used to: obtain the state representation of the current access community (referred to as "state mapper"); coordinate information communication between adjacent access communities (referred to as "communication mapper"); and decide which access module to use as output for the data information stored (referred to as "output mapper").

[0134] Before the user asks a question, each access community will use its own state mapper to calculate the state representation based on its own access module and pre-store it. Unless the internal information of the access community changes (addition or removal of access modules, modification of data information within the access module, etc.), the state representation of each access community does not need to be recalculated.

[0135] When a user asks a question to this system, the system will first convert the user's question (in the form of a string) into a high-dimensional vector representation using a text encoder. Next, each access community will use the high-dimensional representation corresponding to the user's question as input, and then use the communication mapper to carry out the communication process between communities.

[0136] The input of the communication mapper is: the high-dimensional vector representation corresponding to the user's question, the state representation of the community itself, the state representation of the adjacent community, the output representation of the adjacent community, etc.; the output is a high-dimensional vector as the output representation of the community.

[0137] The output representation of an access community will be temporarily cached in the shared access module within the community, and the output representations from other communities adjacent to the community will also be temporarily cached in the shared access module within the community.

[0138] During the communication between communities, the output mapper within each access community will also determine in real time whether its own output representation meets the specific output standard. For example, it calculates the L2-norm (L2 norm) of the output representation. If the value exceeds a specific threshold, the output mapper of this community will use the state representation of this community and the high-dimensional vector representation corresponding to the user's question as input, and then use the nonlinear mapping described in Example 1 to obtain the output probability value of each access module.

[0139] The higher the output probability value of a certain access module, the higher the relevance of the data information in the access module to the user's question. The data information of each access module is summarized based on this value to obtain the search results at the community level.

[0140] This system pre-deploys several open source pre-trained large models with different attributes, such as LLaMA3-8B-Instruct, LLaMA3-70B-I nstruct, Mixtra l-8x7B-I nstruct, Mixtra l-8x22B-instruct, etc. These large models have different parameter scales, performance (such as their scores on the public test set MMLU), different GPU video memory occupied during the call process, etc.

[0141] Build a nonlinear mapper that can specifically assign specific large models based on user questions and their related attributes (hereinafter referred to as the "task allocator". The allocator can be a generative language model composed of a small-scale billion-level language model such as GPT2 as a benchmark model). Its input is: user questions, community-level retrieval results, and the attributes of each pre-deployed large model. Its output is: the assigned large model and related prompt words.

[0142] The internal trainable parameters of the above-mentioned task allocator can be obtained through reinforcement learning based on human feedback (RLHF), that is, a group of experts composed of humans or larger models will score the final output of the system (i.e., the generated answers of the generated data and the expert scores), and obtain corresponding rewards, which are then used as human feedback for reinforcement learning. For the specific algorithm, please refer to OpenAI's technical documents and academic papers on RLHF (title: "Training Language Models to Follow Instructions with Human Feedback").

[0143] For example, a real-time user asks: "Which is better, Apple or Huawei?" The system finds the three most relevant questions through the social communication mechanism: "Which brand is better, Apple or Huawei?" "Please recommend an Apple computer." "Please recommend a Huawei computer." We can mark the generated answers to these three questions (high-quality answers certified by the expert group) as A1, A2, and A3 respectively.

[0144] Therefore, the task allocator of this system will take these related questions and real-time user questions as input, and the output is: model_id = LLaMA3-8B-instruct, prompt = Given that the attributes of Apple computers are +A2+", the attributes of Huawei computers are "+A3+", and the relationship between Apple and Huawei is "+A1+", which one is better, Apple or Huawei?". Next, the LLaMA3-8B-instruct large model pre-deployed in this system will take this generated prompt as input, obtain the final output, and feedback it to the user.

[0145] Based on a small-scale verification in user scenarios (including 100 real user questions), we tested this system and recorded the average response time (seconds), expert evaluation results (0-100 points), concurrency and other indicators for these user questions. The comparison objects are systems based on the mainstream Vector database and RAG systems based on LLaMA-index. The computing carrier is NVIDIA's eight-card 4090 GPU (single card video memory is 24GB).

[0146] Average response time Generate answersExpert evaluation Concurrency The present invention 5.5 98 20 Vector Database 10.5 95 8 LLaMA-index 12.8 90 8

[0147] According to experimental results, the present invention can significantly reduce the response time of a single query and significantly increase the concurrency while ensuring the query quality, thereby significantly reducing the computing power cost of users.

[0148] To sum up, overall, the present invention uses a hierarchical, dynamic, and intelligent way to process queries based on the relationship between queries and historical queries, thereby realizing the rational use of large language models, improving the processing efficiency of the system, saving computing resources, and meeting the user's real-time and accuracy requirements. In the data storage and management system based on the present invention, query requests for user scenarios will fully draw on and combine historical data pre-stored in the form of access communities in this system, thereby minimizing the computing power cost of calling large language models while ensuring that the user query experience is not affected. The present invention brings improvements in improving data storage efficiency, the adaptability and intelligence of the query system for complex scenarios, and the computing power and energy efficiency of the data query process, providing technical support for a new generation of data storage management systems based on large models.

[0149] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the invention, and that the scope of the invention is defined by the equivalents of the appended claims.

Claims

1. A data storage and management system capable of analyzing user scenarios and large-scale data, including five data storage modules, Features: The five modules constitute a whole, and the overall function is a dynamic intelligent management mechanism that can efficiently store and read data information. The five modules are: Module 1: Abstract graph representation of the access module of computing devices; Module 2: Dynamic storage mechanism of data information based on access community; Module 3: Structuring the stored data information; Module 4: Intelligently organize the stored data information, extract information, and assign tasks based on user questions; Module 5: Reinforcement learning mechanism based on human feedback to iterate the trainable parameters of this system; First, each data access module of the processor involved in data storage and their relationship are expressed as a trainable multi-dimensional vector representation, and combined with the topological relationship of the physical form between each access module to form a specific directed graph representation; The representation of each access module should include the access speed, total capacity, occupied capacity, etc. of the access module, and the physical relationship between the access modules should be expressed as a trainable embedded vector representation of a specific dimension; Subsequently, the user's data information is encoded using a text encoder to obtain an embedded high-dimensional vector representation of the data information, and clustering is performed based on the semantic similarity between the high-dimensional vectors. The central vectors of each cluster at different positions are then stored one by one in each access module of the computing device. Among them, the data information involved is mainly divided into two categories: The first type is declarative data used to present facts and information; The second category is generated data based on user questions and user scenarios, which includes three parts: Part 1: User questions: User questions about specific scenarios; Part 2: Generate answers: The answers generated by the system or large model for the question statement; Part 3, Expert Rating: An expert group composed of human experts or larger models evaluates the quality of the answers generated by the system in response to user questions.

2. A data storage and management system capable of analyzing user scenarios and large-scale data according to claim 1, Features: By constructing two nonlinear mappers that can be iteratively trained through supervised learning, they are specifically used to process which access module the new data information to be stored should be stored in; The inputs of the two mappers are: the semantic relationship between the data information to be stored and the stored data information, the intrinsic properties of a specific access module of the computing device and the topological relationship between it and other access modules; The sum of the outputs of the two mappers is equivalent to the probability or rationality that the data information to be stored should be stored in a specific access module.

3. A data storage and management system capable of analyzing user scenarios and large-scale data according to claim 1, Features: According to the semantic similarity of the data information stored in different access modules of the computing device, the related access modules are merged into an access community, and a dedicated nonlinear mapper is configured for the access community, which are: State mapper: obtains the state representation of the current access community; Communication mapper: uses the shared access module shared by different access communities as a transfer station to coordinate information communication between adjacent access communities; Output mapper: determines which internal access module's data information will be used as output.

4. A data storage and management system capable of analyzing user scenarios and large-scale data according to claim 3, Features: The retrieval process for user query statements does not need to involve all the data information contained in all access modules. Instead, the communication process between communities is simulated using the communication mapper of each access community, and then the output representation generated by each community during the communication process is used as the basis for judgment. If the output representation of a community meets specific conditions, the output mapper of each community is used to perform further query retrieval on the data information of the access modules contained in the community. Among them, the state representation of the access community is generally calculated in advance by its own state mapper, and the specific composition of the access community, that is, to which access community each access module should be assigned, is determined by the global allocation function. The specific parameters of this function are determined by the expert group's score on the system output results, that is, the trainable parameters of the relevant trainable allocation function are iteratively updated through reinforcement learning based on human feedback; The data information within each access community should be organized in real time or regularly by a specific large model to generate a text summary that can include its basic information. The text summary is stored in the specific access module of the community and supports human experts to verify and modify it.

5. A data storage and management system capable of analyzing user scenarios and large-scale data according to claim 2, Features: With the help of a nonlinear mapper that can be iteratively trained through supervised learning, the pre-deployed large models with different attributes are dynamically allocated according to the semantic relevance between user questions and the generative data initially retrieved. The objective function is to minimize the computing power cost generated during the actual call of the large model.

6. A data storage and management system capable of analyzing user scenarios and large-scale data according to claim 5, Features: The resulting nonlinear mapper that can be iteratively trained through supervised learning should have allocation strategies including but not limited to the following: If the user's question is extremely relevant to the generated data retrieved initially, and the expert scores corresponding to these generated data exceed a certain threshold, then it is only necessary to merge the generated answers corresponding to these generated data, and then use the small model-based text generation technology to perform text fusion, so as to serve as the output of the user's question; If the user's question is weakly correlated with the generated data retrieved initially, and the expert scores corresponding to these generated data exceed a certain threshold, then we only need to merge the generated answers corresponding to these generated data, and then combine them with reasonable prompt engineering as the input prompt words of a slightly smaller-scale large model, and finally get the output of the user's question; If the user's question does not have a significant correlation with the generative data initially retrieved, a larger model is selected based on the current data to obtain the output of the user's question.