Guided weapon knowledge graph construction method and system based on large language model

Through hierarchical recursive prompt engineering design based on large language models, templates are generated dynamically and logical rule verification, the efficiency and accuracy of knowledge graph construction in the field of air-to-ground guided weapons is solved, and efficient and accurate knowledge graph construction is achieved.

CN120297397APending Publication Date: 2025-07-11BEIJING INST OF TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510456730.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-12
Publication Date
2025-07-11

AI Technical Summary

Technical Problem

In the absence of domain data, how to efficiently and accurately build a domain knowledge map, especially in the field of air-to-ground guided weapons, the existing technology has problems of insufficient accuracy and robustness caused by data diversity and complexity.

Method used

The guided weapon knowledge graph construction method based on large language models is adopted, and through layered recursive prompt engineering design, the recognition prompt information and pre-built template library are used to dynamically generate extraction templates, combining logical rules and physical law verification, to achieve accurate extraction and verification of entities and relationships.

Benefits of technology

It improves the efficiency and accuracy of the construction of domain knowledge graphs, avoids the inefficiency of manual writing rules, ensures that the extracted knowledge conforms to tactical logic and scientificity, and improves the reliability and maintainability of the knowledge graphs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120297397A_ABST
    Figure CN120297397A_ABST
Patent Text Reader

Abstract

The invention relates to a guided weapon knowledge graph construction method and system based on a large language model, and the method comprises the steps: inputting source data and recognition prompt information into the large language model, enabling the large language model to generate and output an ontology conceptual model containing entity data, calling a plurality of corresponding sub-templates from a pre-built template library, and carrying out the recognition of the ontology conceptual model, combining and adapting the plurality of sub-templates to obtain an extraction template, inputting extraction prompt information and the extraction template into the large language model, so that the large language model generates knowledge information data and outputs the knowledge information data, verifying the knowledge information data, and if the verification is passed, correspondingly generating a knowledge graph and outputting the knowledge graph. Otherwise, generating a verification report and backtracking the corresponding steps. According to the guided weapon knowledge graph construction method and system based on the large language model, the knowledge graph can be efficiently and accurately obtained in the field of air-to-ground guided weapons.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the cross - field of military intelligence and knowledge engineering technology, and in particular to a method and system for constructing a knowledge graph of guided weapons based on large language models. Background Art

[0002] There are different knowledge graphs in different fields, such as financial knowledge graphs, medical knowledge graphs, etc. Currently, in the field of common natural language, there are various knowledge graph construction technologies. However, in terms of domain knowledge, the construction of knowledge graphs is just in its infancy. When constructing a domain knowledge graph, difficulties such as the lack of domain data in this industry and the need for experts to annotate often occur. Therefore, how to construct a domain knowledge graph in the absence of domain data is an urgent problem to be solved. The powerful semantic understanding ability demonstrated by large models can provide a new exploration direction for the application of domain knowledge. However, the problems of lacking domain expertise and being prone to hallucinations hinder the application of large models in vertical fields.

[0003] In the process of constructing a knowledge graph in a specific field, usually two technical approaches are adopted: manually writing rule templates and training a model using annotated data. The former involves manually designing and writing a series of rule templates for extracting entities, attributes, and relationships from text or structured data. These rule templates can be designed based on domain knowledge, language rules, and experimental experience, etc., aiming to capture key information in the data and transform it into a structured knowledge representation. Manually writing and defining rule templates requires a deep understanding of the language and knowledge in the field, and it is difficult to accurately identify professional terms such as "millimeter - wave radar seeker". The domain adaptability is insufficient and cannot adapt to the rapid iterative update of new weapon systems. Existing systems adopt a fixed data parsing mode. When facing multi - source heterogeneous information such as technical manuals, battlefield reports, and sensor data, it is necessary to manually re - design extraction rules, lacking dynamic processing capabilities; considering the diversity and complexity of data, it is more difficult to ensure the accuracy and robustness of the rules. The latter work involves collecting, annotating, and preparing a large amount of data, and then training a model using these annotated data, which requires a large amount of human and time costs, has low efficiency, and the quality and reliability of the annotated data cannot be guaranteed. Summary of the Invention

[0004] To solve the deficiencies of the existing technology, the present invention provides a method and system for constructing a knowledge graph of guided weapons based on large language models, which can efficiently and accurately obtain a knowledge graph in the field of air - to - ground guided weapons.

[0005] According to an embodiment of the present invention, on the one hand, a method for constructing a knowledge graph of guided weapons based on large language models is provided, which is characterized by including the following steps:

[0006] S1: Input the source data and recognition prompt information into a large language model, enabling the large language model to identify entities from the source data based on the recognition prompt information, generate and output an ontology concept model containing entity data;

[0007] S2: Obtain the feature information of the source data. Based on the feature information and the ontology concept model, call a corresponding plurality of sub-templates from a pre-built template library, combine and adapt the plurality of sub-templates to obtain an extraction template; extract information containing entity relationship data from the source data based on the extraction template and the input extraction prompt information, and generate and output knowledge information data based on the extracted information;

[0008] S3: Verify the knowledge information data, generate and output a verification report based on the verification result; if the verification passes, execute step S4, otherwise trace back to the corresponding step according to the error type information in the verification report;

[0009] S4: Generate and output a knowledge graph corresponding to the knowledge information data.

[0010] Further, in step S1, the source data is pre-processed multi-modal data.

[0011] Further, in step S1, after generating the ontology concept model, it further includes sub-step S101: Input the generated ontology concept model into the large language model, enabling the large language model to identify entities from the source data based on the recognition prompt information and the ontology concept model, generate a new ontology concept model and make a judgment. If the newly generated ontology concept model meets the preset conditions, terminate the loop, output the newly generated ontology concept model as the final ontology concept model and execute step S2, otherwise continue to execute sub-step S101 until an ontology concept model that meets the preset conditions is obtained.

[0012] Further, in step S2, after obtaining the knowledge information data, it further includes sub-step S201: Optimize the template library based on the knowledge information data and save the optimized template library.

[0013] Further, in step S1, the recognition prompt information includes reference data information, classification method information, and ontology definition information. The generating and outputting an ontology concept model containing entity data based on the recognition prompt information from the source data includes: calling the corresponding reference data in the pre-stored guided weapon database according to the reference data information; identifying entities from the source data according to the reference data and classifying the entities according to the classification method information to obtain a classification matrix; processing the classification matrix according to the ontology definition information to obtain the ontology concept model.

[0014] Further, in step S2, the extraction prompt information uses prompt engineering to limit the extracted entity relationship data.

[0015] Further, the knowledge information data includes one or more triples.

[0016] Further, the extraction prompt information further includes data conversion information. When generating the triples from the source data according to the extraction prompt information, the corresponding data in the triples is converted based on the data conversion information.

[0017] Further, in step S3, the verification of the knowledge information data includes: calling the pre-stored verification rule library to verify the knowledge information data; the verification rule library includes a logical rule library containing military rule information and a physical law library containing parameter association information.

[0018] Further, in step S3, when the verification fails, record the corresponding information in the verification rule library, identify one or more entities with verification errors in the knowledge information data, generate corresponding correction prompts and write them into the verification report; the correction prompts contain error type information. If the error type information is an ontology error, go back to step S1. If the error type information is a data error, go back to step S2.

[0019] According to an embodiment of the present invention, on the other hand, a guidance weapon knowledge graph construction system based on a large language model is provided. The construction system includes an interface for docking with the large language model, and the construction system further includes the following modules:

[0020] A storage module, which is used to obtain and save the source data; a guidance weapon database, a template library, and a verification rule library are pre-stored in the storage module. The guidance weapon database contains one or more guidance weapon data files, and the verification rule library includes a logical rule library containing military rule information and a physical law library containing parameter association information;

[0021] A concept layer module, which can obtain identification prompt information. The identification prompt information includes reference data information, classification method information, and ontology definition information. The concept layer module calls the corresponding guidance weapon data file from the guidance weapon database based on the identification prompt information, and inputs the identification prompt information and the guidance weapon data file into the large language model, so that the large language model outputs the ontology concept model correspondingly;

[0022] Data layer module, which can obtain the source data and the feature information of the source data, and can obtain the ontology concept model from the concept layer module; the data layer module can call the corresponding sub-template from the template library based on the feature information and the ontology concept model, combine and adapt the called sub-template to obtain an extraction template; the data layer module can also extract the information containing entity relationship data from the source data based on the extraction template and the input extraction prompt information, generate knowledge information data according to the extracted information and output it;

[0023] Verification layer module, which can call the verification rule library to verify the knowledge information data and generate a verification report correspondingly. If the verification passes, the knowledge information data will be output to the output module, otherwise, it will backtrack to the corresponding step according to the error type information in the verification report.

[0024] Output module, which can generate and output a knowledge graph based on the knowledge information data.

[0025] The technical solutions provided by the embodiments of the present disclosure may include the following beneficial effects:

[0026] Through the hierarchical recursive prompt engineering design, the effective guidance and standardized extraction of domain knowledge are realized, avoiding a large number of customization tasks of manually writing rules, and improving the efficiency and maintainability. Due to the dynamic template generation and adaptive adjustment mechanism, the template structure can be automatically selected, optimized and corrected according to the characteristics of the input data, improving the accuracy and robustness of extraction. By creating a two-dimensional verification system (logical rule verification + physical law verification), it is ensured that the extracted knowledge not only conforms to the tactical logic but also has scientificity and integrity, avoiding simply relying on the black box characteristics of the model, and improving the reliability and accuracy of the knowledge graph.

[0027] It should be understood that the above general description and the following detailed description are only exemplary and explanatory, and cannot limit the present disclosure. Brief Description of the Drawings

[0028] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings required for the description of the embodiments or the prior art. Obviously, the following drawings are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.

[0029] Figure 1 It is a schematic flowchart of a method for constructing a knowledge graph of guided weapons based on a large language model provided by an embodiment of the present application;

[0030] Figure 2 It is a partial process schematic diagram of a method for constructing a knowledge graph of guided weapons based on a large language model provided by an embodiment of the present application;

[0031] Figure 3 It is a partial process schematic diagram of a method for constructing a knowledge graph of guided weapons based on a large language model provided by an embodiment of the present application;

[0032] Figure 4 It is a schematic diagram of task decomposition of a method for constructing a knowledge graph of guided weapons based on a large language model provided by an embodiment of the present application;

[0033] Figure 5 It is a partial module schematic diagram of a system for constructing a knowledge graph of guided weapons based on a large language model provided by an embodiment of the present application. Detailed implementation manners

[0034] Next, the technical solutions in the embodiments of the present application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present application without making creative efforts belong to the scope of protection of the present application.

[0035] See Figure 1 , an embodiment of the present invention proposes a method for constructing a knowledge graph of guided weapons based on a large language model, which is characterized by including the following steps:

[0036] S1: Input the source data and recognition prompt information into the large language model, so that the large language model identifies entities from the source data based on the recognition prompt information, and generates and outputs an ontology concept model containing entity data;

[0037] S2: Obtain the feature information of the source data, based on the feature information and the ontology concept model, call a corresponding plurality of sub-templates from a pre-built template library, combine and adapt the plurality of sub-templates to obtain an extraction template; based on the extraction template and the input extraction prompt information, extract information containing entity relationship data from the source data, and generate and output knowledge information data according to the extracted information;

[0038] S3: Verify the knowledge information data, generate and output a verification report based on the verification result; if the verification is passed, execute step S4, otherwise trace back to the corresponding step according to the error type information in the verification report;

[0039] S4: Correspondingly generate and output a knowledge graph based on the knowledge information data.

[0040] The recognition hint information is used to guide the large language model to recognize entities in the source data, and the extraction hint information is used to guide the large language model to extract relationship information between entities. This embodiment establishes a hierarchical recursive hint architecture, see Figure 1 , Figure 4 and Figure 5 , step S1 implements the concept layer function, step S2 implements the data layer function, and step S3 implements the verification layer function. Through three-level progressive processing, the reliable construction of the knowledge graph in the field of air-to-ground guided weapons is achieved.

[0041] In step S1, the source data is pre-processed multimodal data, for example, it can be in the form of military field text, so as to remove contextual noise irrelevant to the target field as much as possible, so as to facilitate processing by the large language model. The recognition prompt information includes reference data information, classification method information, and ontology definition information. The identification of entities from the source data based on the recognition prompt information and the generation of an ontology concept model containing entity data include: calling corresponding reference data in a pre-stored guided weapon database according to the reference data information; identifying entities from the source data according to the reference data, and classifying the entities according to the classification method information to obtain a classification matrix; processing the classification matrix according to the ontology definition information to obtain the ontology concept model. The recognition prompt information is obtained with the assistance of a prompt engineering method guided by pre-designed domain knowledge, and a structured prompt template is constructed through a military terminology constraint mechanism to limit the scope of entity recognition. For example, in a specific embodiment, the following recognition prompt information is input to the large language model:

[0042] "As a weapons systems expert, please take from the following text:

[0043] 1. Strictly refer to the "Air-to-Ground Guided Weapon Terminology Standard" to identify entities;

[0044] 2. Establish a classification matrix based on launch platform, guidance method, and warhead type;

[0045] 3. Output the main structure that meets the weapon engineering specifications. "

[0046] Among them, "Air-to-Ground Guided Weapon Terminology Standard" is the reference data information, "Launch Platform, Guidance Method, Warhead Type" is the classification information, and "Weapon Engineering Specification" is the entity definition information; "The following text" is the source data, for example, input weapon technical documents, combat regulations and other files, perform text standardization on them, and the resulting text is the "following text" prompted in the recognition prompt information.

[0047] The recognition prompt information can be a pre-edited template, including multi-level prompt statements. The reference data information, classification method information, and ontology definition information included in each level of the prompt can be replaced as needed for convenient and flexible use. In a specific embodiment, the input recognition prompt information includes a first-level prompt statement:

[0048] "According to the <Guided Weapon Classification Standard>, identify entities belonging to the <Air-to-Ground Strike> category from the text",

[0049] The second-level prompt statement:

[0050] "Establish a three-dimensional classification matrix for the identified entities according to <Launch Platform>-<Guidance Mode>-<Damage Effectiveness>",

[0051] The third-level prompt statement:

[0052] "Convert the classification matrix into an <OWL ontology that defines class hierarchies and property constraints>".

[0053] In the above multi-level prompt statements, the content in "<>" can be replaced as needed.

[0054] See Figure 2 , in one embodiment, in step S1, after generating the ontology concept model, it further includes sub-step S101: input the generated ontology concept model into the large language model, so that the large language model identifies entities from the source data based on the recognition prompt information and the ontology concept model, generates a new ontology concept model and makes a judgment. If the newly generated ontology concept model meets the preset conditions, the loop is terminated, and the newly generated ontology concept model is output as the final ontology concept model and step S2 is executed. Otherwise, sub-step S101 is continued until an ontology concept model that meets the preset conditions is obtained.

[0055] Through iterative optimization, sub-step S101 can correct the classification hierarchy of the ontology concept model. The preset conditions can be pre-input logical conditions, or a comparison and evaluation with the previous iteration result (such as whether the result consistency before and after iteration reaches 95%), or the number of iterations can be used as the preset condition. In a specific embodiment, see Figure 2 , select DeepSeek-V3 as the large language model. After initially obtaining the ontology concept model, perform ontology recursive optimization, input the generated ontology as a new prompt, perform logical consistency checking and hierarchical structure adjustment to form a closed-loop optimization, and output the final ontology concept model after optimizing to meet the preset conditions. DeepSeek-V3 can also be replaced by other large language models.

[0056] In one embodiment, the pre-stored template library is a parameterized template library, which is pre-set with metadata templates for typical scenarios such as technical manuals, technical parameter tables, battlefield events, operation reports, etc.; the template structure is automatically selected and adjusted according to the feature information of the input source data for context-aware adaptation. The feature information includes one or more types of data in file format (PDF / JSON) features and content features (parameter table / operation record).

[0057] In a specific embodiment, the classification method of the parameterized template library is as follows in the table:

[0058] Template type Core field Technical parameter table Range / CEP / anti-jamming index Battlefield event Engagement time / tactical formation / damage assessment

[0059] See Figure 1 In one embodiment, in step S2, a context adaptation algorithm is used to adapt multiple combined sub-templates to obtain an extraction template. In a specific embodiment, the following Python code is used in step S2 to implement part of the context-aware adaptation function:

[0060] def dynamic_field_generation(data_features):

[0061] if "anti-interference" in data_features.keywords:

[0062] add_field("frequency agility range", validation_rule=xxx)

[0063] add_field("interference recognition delay", unit="ms")

[0064] if "tactical formation" in data_features.entity_set:

[0065] activate_branch_template("air-ground coordinated operation framework")

[0066] In one embodiment, step S2 further includes sub-step S201: optimizing the template library based on the knowledge information data and saving the optimized template library.

[0067] In one embodiment, in step S2, the extraction prompt information uses prompt engineering to limit the extracted entity relationship data; the knowledge information data includes structured data representing the association between entities, and the data includes one or more triples. By using prompt engineering to limit the extraction scope and performing triple (subject, predicate, object) constraint extraction, irrelevant knowledge generation can be avoided. The extraction prompt information also includes data conversion information. When generating the triples from the source data according to the extraction prompt information, the corresponding data in the triples is converted based on the data conversion information. For example, in a specific embodiment, the prompt statement for limiting the extraction scope by prompt engineering in step S2 is

[0068] "Extract triples from the current paragraph according to the above template, with the following requirements:

[0069] - Only retain parameters with a numerical accuracy of ≥ 90%.

[0070] - Exclude unvalidated experimental data.

[0071] - Uniformly convert the units to the International System of Units."

[0072] In one embodiment, after obtaining the triples, the triples can also be verified, and the verified triples are fed back into the large language model and the template library to correct the ontology concept model and the basic template library in the data layer. See Figure 3 , in a specific embodiment, first classify the source data, automatically classify it based on the file format (PDF / JSON) and content features (parameter table / operation record), select the corresponding template from the basic template library, and fill in the fields of the template selected from the basic template library through the context adaptation mechanism algorithm written in Python to better extract information from the source data. Use the filled paragraph as a DeepSeek-V3 prompt word extraction template, feedback the quality of the extracted triples and import them into the Protégé software, and then correct the basic template library for the next generation of dynamic templates in the data layer.

[0073] See Figure 1 , in one embodiment, in step S3, the verification of the knowledge information data includes: calling the pre-stored verification rule library to verify the knowledge information data; the verification rule library includes a logical rule library containing military rule information and a physical law library containing parameter association information. Further, when the verification fails, record the corresponding information in the verification rule library, identify one or more entities with verification errors in the knowledge information data, generate a corresponding correction prompt and write it into the verification report; the correction prompt contains error type information. If the error type information is an ontology error, go back to step S1, and if the error type information is a data error, go back to step S2. The output knowledge graph can be in the form of a picture after visualization processing.

[0074] See Figure 1, in a specific embodiment, the method for constructing the knowledge graph can be decomposed into multiple sub-steps according to the processing layer. The conceptual layer part, corresponding to the above-mentioned step S1 and sub-step S101, includes step 1: input military domain text; step 2: perform hint generation with term constraints - generate an initial ontology framework; step 3: recursively optimize the ontology - generate a domain ontology library; step 4: output to the data layer. The data layer part, corresponding to the above-mentioned step S2 and sub-step S201, includes step 5: identify the data source type; step 6: dynamically generate extraction templates; step 7: perform constrained extraction; step 8: output to the verification layer. The verification layer part, corresponding to the above-mentioned step S3, includes step 9: logical rule verification; step 10: physical law verification; step 11: generate a verification report; step 12: feedback for correction. And there is also step 13 corresponding to the above-mentioned step S4: generate the final knowledge graph and output.

[0075] At step 12, according to the error type and the pre-configured association information between errors and steps, accurately trace back to the corresponding step in the above. Military rule information such as: "Anti-radiation missiles must be equipped with electromagnetic sensors"; the corresponding verification code is used to check whether the entity relationship conforms to the tactical regulations (example rules), such as:

[0076] IF weapon type: laser guidance

[0077] THEN there must exist a [atmospheric transmittance] parameter

[0078] The form of the parameter association information can be a parameter association equation, such as the relationship equation between the range R and the propellant mass M: R = k·ln(M / M0). When the extracted entity range R and the propellant mass M do not satisfy this relationship within the error range, corresponding to the situation where the propellant dose is insufficient but the nominal range is too large, record the conflicting data and generate a corresponding correction hint. See Figure 1 and Figure 4 , as follows:

[0079] "It is detected that the range (150km) of [Missile X] conflicts with the propellant dose (200kg):

[0080] Suggested operations:

[0081] 1. Check the accuracy of the source data

[0082] 2. Adjust the coefficient of the power parameter calculation formula

[0083] 3. Re-execute steps 6 - 7"

[0084] When outputting the correction hint, also output an instruction according to the error type

[0085] "Select the backtracking level (data error → return to step 6, ontology error → return to step 2)"

[0086] In the above example, the contradiction between the range and the propulsion dose may stem from an error in extracting the corresponding relationship of the entity time, rather than an error in extracting the entity. Therefore, it is prompted to re-execute steps 6-7 to correct possible errors in the extraction template or randomly generated error relationships during extraction. The backtracking can be automatic backtracking or backtracking after manual confirmation.

[0087] In a specific embodiment, the following three paragraphs of Python code are successively used in step S3 to implement warhead logic verification, guidance mode parameter dependency verification, and power system physical rule verification. Code 1 is

[0088]

[0089] Code 2 is

[0090]

[0091] Code 3 is

[0092]

[0093]

[0094] The embodiment of the present invention also provides a guidance weapon knowledge graph construction system based on a large language model. The construction system includes an interface for docking with the large language model. The construction system further includes the following modules. See Figure 5 :

[0095] A storage module, which is used to obtain source data and save it; a guidance weapon database, a template library, and a verification rule library are pre-stored in the storage module. The guidance weapon database contains one or more guidance weapon data files. The verification rule library includes a logic rule library containing military rule information and a physical law library containing parameter association information;

[0096] A concept layer module, which can obtain recognition prompt information. The recognition prompt information includes reference data information, classification method information, and ontology definition information. The concept layer module calls the corresponding guidance weapon data file from the guidance weapon database based on the recognition prompt information, and inputs the recognition prompt information and the guidance weapon data file into the large language model, so that the large language model outputs the ontology concept model correspondingly;

[0097] The data layer module can obtain the source data and the feature information of the source data, and can obtain the ontology concept model from the concept layer module; the data layer module can call the corresponding sub-template from the template library based on the feature information and the ontology concept model, combine and adapt the called sub-template to obtain an extraction template; the data layer module can also extract the information containing entity relationship data from the source data based on the extraction template and the input extraction prompt information, generate knowledge information data according to the extracted information and output it;

[0098] The verification layer module can call the verification rule library to verify the knowledge information data and generate a verification report accordingly. If the verification is passed, the knowledge information data will be output to the output module, otherwise, it will backtrack to the corresponding step according to the error type information in the verification report.

[0099] The output module can generate and output a knowledge graph based on the knowledge information data.

[0100] From the perspective of the knowledge graph construction task, in the embodiments of the present invention, the entire process of constructing a knowledge graph is decomposed into multiple sub-tasks. In a specific embodiment, see Figure 4 , this process mainly includes ontology construction, knowledge processing, knowledge verification, and knowledge visualization. Ontology modeling, as the concept layer of the knowledge graph, is used to describe the model of information and data at the semantic and knowledge levels. Its core is to define a clear concept framework, such as weapon types or attributes. Knowledge processing acts on the data layer of the knowledge graph, aiming to extract key information from structured, semi-structured, and unstructured texts, process it into a structured form, and then perform knowledge filling to match the data with the concept layer model. This can be a set of triples (subject, predicate, object), constructing the basic structure of the knowledge graph. Knowledge verification, as the verification layer of the knowledge graph, compares the processed model with the existing rule logic to complete the verification of the accuracy and precision of the knowledge graph. If it is lower than a certain value, it will feedback to the ontology modeling and knowledge processing for correction. Knowledge visualization, for example, imports the model assembled in the Protégé software into the Neo4j graph database to draw the knowledge graph network.

[0101] In the embodiments of the present invention, through hierarchical recursive prompt engineering design, effective guidance and standardized extraction of domain knowledge are realized. It avoids a large amount of customization work of manually writing rules, and improves efficiency and maintainability. Due to the dynamic template generation and adaptive adjustment mechanism, it can automatically select, optimize and correct the template structure according to the characteristics of the input data, improving the accuracy and robustness of extraction, and facilitating the long-term operation, maintenance and use of the system, and accumulating to form a more accurate and reliable knowledge graph. Moreover, by creating a two-dimensional verification system (logical rule verification + physical law verification), it is ensured that the extracted knowledge not only conforms to tactical logic but also has scientificity and integrity. This multi-dimensional verification mechanism avoids simply relying on the black-box characteristics of the model and improves the reliability and accuracy of the knowledge graph.

[0102] In several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the modules is only a logical function division. In actual implementation, there may be other division methods. For example, multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point, the indirect coupling or communication connection of the device or module can be electrical, mechanical or other forms.

[0103] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical modules. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0104] In addition, in each embodiment of the present application, the functional modules can be integrated in a processing unit, or each module can exist physically alone, or two or more modules can be integrated in a unit. The above integrated unit can be implemented in the form of hardware or in the form of a hardware plus software functional unit.

[0105] It should be noted that in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, such that a process, method, article or device comprising a series of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article or device. Without further limitation, an element defined by the statement "comprising an..." does not exclude the presence of additional identical elements in the process, method, article or device comprising said element.

Claims

1. A method for constructing a knowledge graph of guided weapons based on large language models, characterized in that, It includes the following steps: S1: Input the source data and recognition prompt information into the large language model, so that the large language model identifies entities from the source data based on the recognition prompt information, generates and outputs an ontology concept model containing entity data; S2: Obtain the feature information of the source data. Based on the feature information and the ontology concept model, call multiple corresponding sub-templates from the pre-built template library, combine and adapt the multiple sub-templates to obtain an extraction template; Extract information containing entity relationship data from the source data based on the extraction template and the input extraction prompt information, and generate and output knowledge information data according to the extracted information; S3: Verify the knowledge information data, generate and output a verification report based on the verification result; if the verification passes, execute step S4, otherwise trace back to the corresponding step according to the error type information in the verification report; S4: Generate and output a knowledge graph based on the knowledge information data.

2. The method for constructing a knowledge graph of guided weapons based on a large language model according to claim 1, wherein In step S1, after generating the ontology concept model, it further includes sub-step S101: Input the generated ontology concept model into the large language model, so that the large language model identifies entities from the source data based on the recognition prompt information and the ontology concept model, generates a new ontology concept model and makes a judgment. If the newly generated ontology concept model meets the preset conditions, terminate the loop, output the newly generated ontology concept model as the final ontology concept model and execute step S2, otherwise continue to execute sub-step S101 until an ontology concept model that meets the preset conditions is obtained.

3. The method for constructing a knowledge graph of guided weapons based on a large language model according to claim 1, wherein In step S2, after obtaining the knowledge information data, it further includes sub-step S201: Optimize the template library based on the knowledge information data and save the optimized template library.

4. The method for constructing a knowledge graph of guided weapons based on a large language model according to claim 1, wherein In step S1, the recognition prompt information includes reference data information, classification method information, and ontology definition information. The generating and outputting an ontology concept model containing entity data based on the recognition prompt information from the source data includes: calling the corresponding reference data in the pre-stored guided weapon database according to the reference data information; identifying entities from the source data according to the reference data, and classifying the entities according to the classification method information to obtain a classification matrix; processing the classification matrix according to the ontology definition information to obtain the ontology concept model.

5. The method for constructing a knowledge graph of guided weapons based on a large language model according to claim 1, wherein In step S2, the extraction prompt information uses prompt engineering to limit the extracted entity relationship data.

6. The method for constructing a knowledge graph of guided weapons based on a large language model according to claim 5, wherein The knowledge information data includes one or more triples.

7. The method for constructing a knowledge graph of guided weapons based on a large language model according to claim 6, wherein The extraction prompt information also includes data conversion information. When extracting and generating the triples from the source data according to the extraction prompt information, the corresponding data in the triples is converted based on the data conversion information.

8. The method for constructing a knowledge graph of guided weapons based on a large language model according to claim 1, wherein In step S3, the verification of the knowledge information data includes: calling the pre-stored verification rule library to verify the knowledge information data; the verification rule library includes a logical rule library containing military rule information and a physical law library containing parameter association information.

9. The method for constructing a knowledge graph of guided weapons based on a large language model according to claim 8, wherein, In step S3, when the verification fails, record the corresponding information in the verification rule library, identify one or more entities with verification errors in the knowledge information data, generate corresponding correction prompts and write them into the verification report; The correction prompt contains error type information. If the error type information is an ontology error, go back to step S1. If the error type information is a data error, go back to step S2.

10. A knowledge graph construction system for guided weapons based on large language models, characterized in that, The construction system includes an interface for docking with a large language model, and the construction system further includes the following modules: A storage module, which is used to obtain and save source data; a guidance weapon database, a template library, and a verification rule library are pre-stored in the storage module. The guidance weapon database contains one or more guidance weapon data files, and the verification rule library includes a logical rule library containing military rule information and a physical law library containing parameter association information; A concept layer module, which can obtain identification prompt information. The identification prompt information includes reference data information, classification method information, and ontology definition information. The concept layer module calls the corresponding guidance weapon data file from the guidance weapon database based on the identification prompt information, and inputs the identification prompt information and the guidance weapon data file into the large language model, so that the large language model outputs the ontology concept model correspondingly; A data layer module, which can obtain the source data and the characteristic information of the source data, and can obtain the ontology concept model from the concept layer module; the data layer module can call the corresponding sub-template from the template library based on the characteristic information and the ontology concept model, combine and adapt the called sub-template to obtain an extraction template; the data layer module can also extract information containing entity relationship data from the source data based on the extraction template and the input extraction prompt information, generate knowledge information data according to the extracted information and output it; A verification layer module, which can call the verification rule library to verify the knowledge information data and generate a verification report correspondingly. If the verification passes, the knowledge information data is output to the output module, otherwise, it goes back to the corresponding step according to the error type information in the verification report. An output module, which can generate and output a knowledge graph based on the knowledge information data.