A knowledge graph generation method based on vector database

By identifying and quantizing entities based on the BERT-Base language model and GloVe word embedding technology, and combining adaptive entity embedding adjustment and graph attention relationship reasoning mechanism, the entity representation in the vector database is optimized, solving the problem of low data processing efficiency, realizing real-time updates and revealing complex relationships, and improving the accuracy and analytical capabilities of the knowledge graph.

CN120930761BActive Publication Date: 2026-05-26CHINA NAT BUILDING MATERIALS TECH CO LTD +2
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA NAT BUILDING MATERIALS TECH CO LTD
Filing Date
2024-06-17
Publication Date
2026-05-26

AI Technical Summary

Technical Problem

Existing knowledge graph generation methods suffer from low data processing efficiency, prolonged response time, and delayed knowledge graph updates when processing data in vector databases due to the high dimensionality and query complexity of vector databases.

Method used

By collecting knowledge data from social media, professional articles, and databases, we use the BERT-Base language model and GloVe word embedding technology to identify and quantize entities. We then combine adaptive entity embedding adjustment technology and graph attention-based relational reasoning mechanism to optimize entity vector representation and generate a knowledge graph, which is then stored in a vector database.

Benefits of technology

It enables real-time updating and adjustment of entity vectors, improving data accuracy and response speed, revealing and strengthening complex relationships between entities, and enhancing the semantic richness and advanced analytical capabilities of the knowledge graph.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120930761B_ABST
    Figure CN120930761B_ABST
Patent Text Reader

Abstract

This invention relates to the field of knowledge graph generation technology, specifically to a knowledge graph generation method based on a vector database. It includes the following steps: S1, collecting knowledge data and preprocessing the data; S2, identifying and quantizing entities in the text data using the BERT-Base language model and GloVe word embedding technology, and storing them in a vector database; S3, updating and adjusting the entity vectors stored in the vector database in real time using adaptive entity embedding adjustment technology; S4, analyzing and learning the vector representations of entities and their relationships using a graph attention-based relational reasoning mechanism to generate a knowledge graph; S5, storing the knowledge graph in the vector database. This knowledge graph generation method based on a vector database, through adaptive entity embedding adjustment technology and a graph attention-based relational reasoning mechanism, achieves knowledge graph generation and real-time updating of entity vectors, improving the accuracy of the knowledge graph.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of knowledge graph generation technology, and more specifically, to a knowledge graph generation method based on a vector database. Background Technology

[0002] A knowledge graph generation method based on vector database aims to generate knowledge graphs through efficient vector processing technology, and achieve high-precision entity relationship representation and intelligent data analysis by utilizing adaptive entity embedding adjustment technology and graph attention-based relational reasoning mechanism.

[0003] Existing knowledge graph generation methods suffer from low data processing efficiency, prolonged response time, and delayed knowledge graph updates when processing data from vector databases due to the high dimensionality and query complexity of vector databases. Therefore, this paper proposes a knowledge graph generation method based on vector databases. Summary of the Invention

[0004] The purpose of this invention is to provide a knowledge graph generation method based on vector databases, so as to solve the problems mentioned in the background art, which are caused by the high-dimensionality and query complexity of vector databases, resulting in low data processing efficiency, long response time and delayed knowledge graph updates.

[0005] To achieve the above objectives, the present invention aims to provide a knowledge graph generation method based on a vector database, comprising the following steps:

[0006] S1. Collect knowledge data from social media, professional articles, and databases, and preprocess the knowledge data;

[0007] S2. Utilize the BERT-Base language model and GloVe word embedding technology to identify and quantize entities in text data, and store them in a vector database;

[0008] S3. The entity vectors stored in the vector database are updated and adjusted in real time by using adaptive entity embedding adjustment technology;

[0009] S4. Use a graph attention-based relational reasoning mechanism to analyze and learn the vector representations of entities and their relationships, optimize the relation vectors through the graph attention mechanism, and generate a knowledge graph.

[0010] S5. Store the generated and optimized knowledge graph in a vector database.

[0011] As a further improvement to this technical solution, the preprocessing of knowledge data in step S1 is used to improve data quality, enhance data consistency and standardization, and extract features and information from the knowledge data. The specific steps involved are as follows:

[0012] S1.1 For social media data, use regular expressions to remove irrelevant elements, including advertisements, HTML tags, and special characters. For professional articles and databases, check and correct typos and formatting issues in the knowledge data.

[0013] S1.2 Use the chardet library to convert all knowledge data to UTF-8 encoding format, and use the datetime module to convert all timestamp data to ISO 8601 format;

[0014] S1.3 Use database queries to check and remove duplicate records in the knowledge data, and extract the date, author, and location information fields;

[0015] S1.4 Use the spaCy tool to identify personal names, locations and organizational entities in the knowledge data, and use machine learning models to process ambiguous words in the knowledge data.

[0016] S1.5. Use a numerical processing library to normalize the numerical data, and use the Wikifier tool to link the identified entities with the corresponding entities in the existing knowledge base.

[0017] As a further improvement to this technical solution, in S2, the BERT-Base language model is implemented based on the Transformer architecture and is used for named entity recognition, to identify and understand entities and their context in text; GloVe word embedding technology is used to generate a global word vector space.

[0018] The specific steps involved in identifying and quantizing entities in text data using the BERT language model and GloVe word embedding technology, and storing them in a vector database, are as follows:

[0019] S2.1 Input the preprocessed knowledge data into the BERT-Base language model, and identify the names, locations and organizational entities in the knowledge data based on the output of the BERT-Base language model;

[0020] S2.2 Use GloVe word embedding technology to convert entities and other words in the knowledge data into pre-trained word vectors provided by GloVe;

[0021] S2.3 Create a vector database, define the dimensions and index types of the vectors, upload the vectors of all entities and other words to the vector database, and assign a unique identifier to each vector;

[0022] S2.4 Test the response time and accuracy of the vector database, and optimize the vector database.

[0023] As a further improvement to this technical solution, in S3, the adaptive entity embedding adjustment technology is implemented based on online learning, deep learning, and gradient descent, and is used to continuously optimize the vector representation of entities in the knowledge graph. The specific steps involved in the adaptive entity embedding adjustment technology to continuously optimize entity vectors in the vector database are as follows:

[0024] S3.1 Initialization of entity vectors: The vector representation of each entity e at the initial time t=0 is v0(e);

[0025] S3.2, Receive new data D at time t t ;

[0026] S3.3, Define the loss function L(v) t (e), D t This is used to measure the error between the entity's current vector and the new data;

[0027] S3.4 Calculate the loss function relative to the entity vector v t gradient of (e) Update the entity vector and normalize the updated entity vector.

[0028] As a further improvement to this technical solution, the loss function L(v) in S3.3 t (e), D t ) is a composite loss function that includes mean squared error, regularization term, and structured loss of inter-entity relationships. The mathematical expression involved is as follows:

[0029]

[0030] Among them, y i From data D t The target vector value derived from ; λ is the L2 regularization parameter, used to prevent overfitting; γ is the parameter that adjusts the entity relationship loss weights; It is a loss term concerning the relationships between entities, which can be defined as a function of the distance between an entity vector and its related entity vectors;

[0031] Wherein, the definition The specific mathematical formula is as follows:

[0032]

[0033] in, v represents the set of entities associated with entity e; t (e′) is the vector representation of the entity associated with e.

[0034] As a further improvement to this technical solution, in step S3.4, the loss function is calculated relative to the entity vector v. tgradient of (e) The mathematical expressions involved in updating the entity vectors are as follows:

[0035] Calculate the loss function relative to the entity vector v t The gradient formula for (e) is:

[0036]

[0037] Update entity vector formula:

[0038]

[0039] in, Let v be the vector of the loss function L with respect to entity e at time t. t The gradient of (e); N is the number of samples in the dataset; Represents the relational loss R with respect to v t The gradient of (e); v t+1 (e) is the vector representation of entity e after the update at time t+1; η is the learning rate;

[0040] The mathematical expression involved in normalizing the updated entity vector is as follows:

[0041]

[0042] As a further improvement to this technical solution, in step S4, the graph attention-based relational reasoning mechanism, implemented using graph neural network technology and attention mechanisms, is used to optimize and deepen the representation of relationships between entities, and the specific steps involved in generating the knowledge graph are as follows:

[0043] S4.1 Load the entity vectors updated by the adaptive entity embedding adjustment technique into the graph network;

[0044] S4.2. Establish a graph structure G = (V, E) based on entities and their relationships, where the set of nodes V represents the set of entities and the set of edges E represents the relationships between entities;

[0045] S4.3 Apply a graph attention-based relational reasoning mechanism to analyze and learn the relationships between entities, and update the entity vector representation of each node;

[0046] S4.4 Use graph neural network technology to aggregate information of adjacent nodes and update the vector representation of entities;

[0047] S4.5 Generate and update the knowledge graph based on the updated vectors, and continuously maintain its accuracy and timeliness.

[0048] As a further improvement to this technical solution, the mathematical model formula involved in S4.3 updating the entity vector representation of each node is as follows:

[0049]

[0050] α vu =softmax u (LeakyReLU(a T [Wh v ][Wh u ]));

[0051]

[0052] Where σ is the activation function, h u Let be the entity vector of node u; Let W be the set of neighboring nodes of node v; W be the weight matrix; α be the weight matrix. vu This represents the attention coefficient.

[0053] As a further improvement to this technical solution, the mathematical model formula involved in aggregating the information of adjacent nodes and updating the vector representation of the entity in S4.4 is as follows:

[0054]

[0055] in, σ represents the final vector representation of node v after aggregating neighbor information; σ represents the activation function, used to introduce nonlinearity.

[0056] As a further improvement to this technical solution, the specific steps involved in storing the knowledge graph in the vector database in step S5 are as follows:

[0057] S5.1 Assign a unique identifier to each entity and relation, and upload the vector data to the vector database;

[0058] S5.2 Verify data integrity and accuracy, and verify the efficiency of the index;

[0059] S5.3 Implement data security measures and regularly back up the data in the vector database;

[0060] S5.4 Continuously monitor the database and adjust indexing strategies and storage configurations according to actual usage.

[0061] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0062] 1. In this knowledge graph generation method based on vector database, the entity vectors stored in the vector database are updated and adjusted in real time by using adaptive entity embedding adjustment technology. This ensures that the entity vectors always reflect the latest data and context information, thereby achieving higher data accuracy and response speed.

[0063] 2. In this knowledge graph generation method based on vector database, the vector representation of entities and their relationships is analyzed and learned using a graph attention-based relational reasoning mechanism to generate a knowledge graph. This method can effectively reveal and strengthen the implicit complex relationships between entities, not only improving the accuracy of relational expression but also enhancing the semantic richness of the graph, enabling the knowledge graph to better support advanced analysis tasks. Attached Figure Description

[0064] Figure 1 This is a flowchart of the overall method of the present invention. Detailed Implementation

[0065] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0066] Example:

[0067] Please see Figure 1 As shown, this embodiment provides a knowledge graph generation method based on a vector database, including the following steps:

[0068] S1. Collect knowledge data from social media, professional articles, and databases, and preprocess the knowledge data;

[0069] The preprocessing of knowledge data in step S1 is used to improve data quality, enhance data consistency and standardization, and extract features and information from the knowledge data. The specific steps involved are as follows:

[0070] S1.1 For social media data, use regular expressions to remove irrelevant elements, including advertisements, HTML tags, and special characters. For professional articles and databases, check and correct typos and formatting issues in the knowledge data.

[0071] S1.2 Use the charder library to convert all knowledge data to UTF-8 encoding format, and use the daterime module to convert all timestamp data to ISO 8601 format;

[0072] S1.3 Use database queries to check and remove duplicate records in the knowledge data, and extract the date, author, and location information fields;

[0073] S1.4 Use the spaCy tool to identify personal names, locations and organizational entities in the knowledge data, and use machine learning models to process ambiguous words in the knowledge data.

[0074] S1.5. Use a numerical processing library to normalize the numerical data, and use the Wikifier tool to link the identified entities with the corresponding entities in the existing knowledge base.

[0075] The chardet library is a Python library used to automatically detect character encoding.

[0076] The datetime module is one of Python's standard libraries, providing date and time processing functions. In data processing, it is often used to standardize and convert time formats, converting time strings of different formats into a unified ISO 8601 format.

[0077] The spaCy tool is an open-source natural language processing (NLP) library that focuses on providing high-performance entity recognition, syntactic analysis and other functions. It is suitable for entity recognition tasks and can extract information such as names, locations and organizations from text.

[0078] Among them, the numerical processing libraries include Python libraries such as NumPy or Pandas, which provide extensive mathematical and numerical processing functions to help with data cleaning, transformation and analysis, such as statistical analysis or data normalization.

[0079] S2. Utilize the BERT-Base language model and GloVe word embedding technology to identify and quantize entities in text data, and store them in a vector database;

[0080] In S2, the BERT-Base language model, implemented based on the Transformer architecture, is used for named entity recognition, identifying and understanding entities and their context in text; GloVe word embedding technology is used to generate a global word vector space.

[0081] The specific steps involved in identifying and quantizing entities in text data using the BERT language model and GloVe word embedding technology, and storing them in a vector database, are as follows:

[0082] S2.1 Input the preprocessed knowledge data into the BERT-Base language model, and identify the names, locations and organizational entities in the knowledge data based on the output of the BERT-Base language model;

[0083] S2.2 Use GloVe word embedding technology to convert entities and other words in the knowledge data into pre-trained word vectors provided by GloVe;

[0084] S2.3 Create a vector database, define the dimensions and index types of the vectors, upload the vectors of all entities and other words to the vector database, and assign a unique identifier to each vector;

[0085] S2.4 Test the response time and accuracy of the vector database, and optimize the vector database.

[0086] S3. The entity vectors stored in the vector database are updated and adjusted in real time by using adaptive entity embedding adjustment technology;

[0087] In S3, the adaptive entity embedding adjustment technique is implemented based on online learning, deep learning, and gradient descent, and is used to continuously optimize the vector representation of entities in the knowledge graph. The specific steps involved in the adaptive entity embedding adjustment technique to continuously optimize entity vectors in the vector database are as follows:

[0088] S3.1 Initialization of entity vectors: The vector representation of each entity e at the initial time t=0 is v0(e);

[0089] S3.2, Receive new data D at time t t ;

[0090] S3.3, Define the loss function L(v) t (e), D t This is used to measure the error between the entity's current vector and the new data;

[0091] S3.4 Calculate the loss function relative to the entity vector v t gradient of (e) Update the entity vector and normalize the updated entity vector.

[0092] The loss function L(v) in S3.3 t (e), D t ) is a composite loss function that includes mean squared error, regularization term, and structured loss of inter-entity relationships. The mathematical expression involved is as follows:

[0093]

[0094] Among them, y i From data D t The target vector value derived from ; λ is the L2 regularization parameter, used to prevent overfitting; γ is the parameter that adjusts the entity relationship loss weights; It is a loss term concerning the relationships between entities, which can be defined as a function of the distance between an entity vector and its related entity vectors;

[0095] Wherein, the definition The specific mathematical formula is as follows:

[0096]

[0097] in, v represents the set of entities associated with entity e; t (e′) is the vector representation of the entity associated with e.

[0098] In S3.4, the loss function is calculated relative to the entity vector v. t gradient of (e) The mathematical expressions involved in updating the entity vectors are as follows:

[0099] Calculate the loss function relative to the entity vector v t The gradient formula for (e) is:

[0100]

[0101] Update entity vector formula:

[0102]

[0103] in, Let v be the vector of the loss function L with respect to entity e at time t. t The gradient of (e); N is the number of samples in the dataset; Represents the relational loss R with respect to v t The gradient of (e); v t+1 (e) is the vector representation of entity e after the update at time t+1; η is the learning rate;

[0104] The mathematical expression involved in normalizing the updated entity vector is as follows:

[0105]

[0106] S4. Use a graph attention-based relational reasoning mechanism to analyze and learn the vector representations of entities and their relationships, optimize the relation vectors through the graph attention mechanism, and generate a knowledge graph.

[0107] In step S4, the graph attention-based relational reasoning mechanism, implemented using graph neural network technology and attention mechanisms, is used to optimize and deepen the representation of relationships between entities. The specific steps involved in generating the knowledge graph are as follows:

[0108] S4.1 Load the entity vectors updated by the adaptive entity embedding adjustment technique into the graph network;

[0109] S4.2. Establish a graph structure G = (V, E) based on entities and their relationships, where the set of nodes V represents the set of entities and the set of edges E represents the relationships between entities;

[0110] S4.3 Apply a graph attention-based relational reasoning mechanism to analyze and learn the relationships between entities, and update the entity vector representation of each node;

[0111] S4.4 Use graph neural network technology to aggregate information of adjacent nodes and update the vector representation of entities;

[0112] S4.5 Generate and update the knowledge graph based on the updated vectors, and continuously maintain its accuracy and timeliness.

[0113] The mathematical model formula involved in S4.3 updating the entity vector representation of each node is as follows:

[0114]

[0115] α vu =softmax u (LeakyReLU(a T [Wh v ][Wh u ]));

[0116]

[0117] Where σ is the activation function, h u Let be the entity vector of node u; Let W be the set of neighboring nodes of node v; W be the weight matrix; α be the weight matrix. vu This represents the attention coefficient.

[0118] The mathematical model formula involved in aggregating the information of adjacent nodes and updating the vector representation of the entity in S4.4 is as follows:

[0119]

[0120] in, σ represents the final vector representation of node v after aggregating neighbor information; σ represents the activation function used to introduce nonlinearity.

[0121] Wherein, the αv uThe attention coefficient is an important parameter used to determine the importance of each neighbor's contribution when aggregating neighbor information; LeakyReLU is a linear rectified function, typically used to add non-linear elements to neural networks to avoid the vanishing gradient problem. Compared to standard ReLU, LeakyReLU allows for a small positive slope when the input is negative; [Wh v ][Wh u ] is to combine two node vectors h v and h u By concatenating (chaining) the results after transformation using the weight matrix W, the features of both the current node and its neighbors can be considered simultaneously; a T It is a learnable parameter vector used to transform the concatenated node vectors to produce a scalar output representing the unnormalized attention weights between nodes.

[0122] S5. Store the generated and optimized knowledge graph in a vector database.

[0123] The specific steps involved in storing the knowledge graph in the vector database in S5 are as follows:

[0124] S5.1 Assign a unique identifier to each entity and relation, and upload the vector data to the vector database;

[0125] S5.2 Verify data integrity and accuracy, and verify the efficiency of the index;

[0126] S5.3 Implement data security measures and regularly back up the data in the vector database;

[0127] S5.4 Continuously monitor the database and adjust indexing strategies and storage configurations according to actual usage.

[0128] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely preferred examples and are not intended to limit the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the present invention as claimed. The scope of protection of the present invention is defined by the appended claims and their equivalents.

Claims

1. A knowledge graph generation method based on a vector database, characterized in that: Includes the following steps: S1. Collect knowledge data from social media, professional articles, and databases, and preprocess the knowledge data; S2. Utilize the BERT-Base language model and GloVe word embedding technology to identify and quantize entities in text data, and store them in a vector database; S3. The entity vectors stored in the vector database are updated and adjusted in real time by using adaptive entity embedding adjustment technology; S4. Use a graph attention-based relational reasoning mechanism to analyze and learn the vector representations of entities and their relationships, optimize the relation vectors through the graph attention mechanism, and generate a knowledge graph. S5. Store the generated and optimized knowledge graph in a vector database; In S2, the BERT-Base language model, implemented based on the Transformer architecture, is used for named entity recognition, identifying and understanding entities and their context in text; GloVe word embedding technology is used to generate a global word vector space. The specific steps involved in identifying and quantizing entities in text data using the BERT-Base language model and GloVe word embedding technology, and storing them in a vector database, are as follows: S2.1 Input the preprocessed knowledge data into the BERT-Base language model, and identify the names, locations and organizational entities in the knowledge data based on the output of the BERT-Base language model; S2.2 Use GloVe word embedding technology to convert entities and other words in the knowledge data into pre-trained word vectors provided by GloVe; S2.3 Create a vector database, define the dimensions and index types of the vectors, upload the vectors of all entities and other words to the vector database, and assign a unique identifier to each vector; S2.4 Test the response time and accuracy of the vector database, and optimize the vector database; In S3, the adaptive entity embedding adjustment technique is implemented based on online learning, deep learning, and gradient descent, and is used to continuously optimize the vector representation of entities in the knowledge graph. The specific steps involved in the adaptive entity embedding adjustment technique to continuously optimize entity vectors in the vector database are as follows: S3.1 Entity vector initialization, for each entity Initial time vector representation ; S3.2, in time Receive new data ; S3.3, Define the loss function To measure the error between the entity's current vector and the new data; S3.4 Calculate the loss function relative to the entity vector gradient Update the entity vector and normalize the updated entity vector. In step S4, the graph attention-based relational reasoning mechanism, implemented using graph neural network technology and attention mechanisms, is used to optimize and deepen the representation of relationships between entities. The specific steps involved in generating the knowledge graph are as follows: S4.1 Load the entity vectors updated by the adaptive entity embedding adjustment technique into the graph network; S4.2 Building a graph structure based on entities and their relationships , where the set of nodes Represents the set of entities and the set of edges. Represents the relationships between entities; S4.3 Apply a graph attention-based relational reasoning mechanism to analyze and learn the relationships between entities, and update the entity vector representation of each node; S4.4 Use graph neural network technology to aggregate information of adjacent nodes and update the vector representation of entities; S4.

5. Generate and update the knowledge graph based on the updated vectors, and continuously maintain its accuracy and timeliness; The loss function in S3.3 It is a composite loss function that includes mean squared error, regularization term, and structured loss of relationships between entities. The mathematical expression involved is as follows: ; in, From the data The target vector value derived from it; It is the L2 regularization parameter, used to prevent overfitting; It is a parameter for adjusting the loss weight of entity relationships; This is a loss term related to the relationships between entities, defined as a function of the distance between an entity vector and its related entity vectors. This represents the number of samples in the dataset. Among them, the The specific mathematical formula is as follows: ; in, Representation and entity The related set of entities; Is with Vector representation of related entities.

2. The knowledge graph generation method based on a vector database according to claim 1, characterized in that: The preprocessing of knowledge data in step S1 is used to improve data quality, enhance data consistency and standardization, and extract features and information from the knowledge data. The specific steps involved are as follows: S1.1 For social media data, use regular expressions to remove irrelevant elements, including advertisements, HTML tags, and special characters. For professional articles and databases, check and correct typos and formatting issues in the knowledge data. S1.2 Use the chardet library to convert all knowledge data to UTF-8 encoding format, and use the datetime module to convert all timestamp data to ISO 8601 format; S1.3 Use database queries to check and remove duplicate records in the knowledge data, and extract the date, author, and location information fields; S1.4 Use the spaCy tool to identify personal names, locations and organizational entities in the knowledge data, and use machine learning models to process ambiguous words in the knowledge data. S1.

5. Use a numerical processing library to normalize the numerical data, and use the Wikifier tool to link the identified entities with the corresponding entities in the existing knowledge base.

3. The knowledge graph generation method based on a vector database according to claim 1, characterized in that: In S3.4, the loss function is calculated relative to the entity vector. gradient The mathematical expressions involved in updating the entity vectors are as follows: Calculate the loss function relative to the entity vector Gradient formula: ; Update entity vector formula: ; in, loss function Regarding entities In time vector The gradient; This represents the number of samples in the dataset. Indicates relationship loss about The gradient; For entities In time The updated vector representation; The learning rate; The mathematical expression involved in normalizing the updated entity vector is as follows: 。 4. The knowledge graph generation method based on a vector database according to claim 1, characterized in that: The mathematical model formula involved in S4.3 updating the entity vector representation of each node is as follows: ; ; ; in, For activation function, For nodes entity vectors; For nodes The set of neighboring nodes; This is the weight matrix; This represents the attention coefficient.

5. The knowledge graph generation method based on a vector database according to claim 1, characterized in that: The mathematical model formula involved in aggregating the information of adjacent nodes and updating the vector representation of the entity in S4.4 is as follows: ; in, Represents a node The final vector representation after aggregating neighbor information; This represents the activation function, used to introduce nonlinearity.

6. The knowledge graph generation method based on a vector database according to claim 1, characterized in that: The specific steps involved in storing the knowledge graph in the vector database in S5 are as follows: S5.1 Assign a unique identifier to each entity and relation, and upload the vector data to the vector database; S5.2 Verify data integrity and accuracy, and verify the efficiency of the index; S5.3 Implement data security measures and regularly back up the data in the vector database; S5.4 Continuously monitor the database and adjust indexing strategies and storage configurations according to actual usage.