Network configuration method and apparatus

By generating network configuration results through configuration requests written in natural language and language models, and combining configuration models and vector database verification, the problems of high complexity and difficulty in network configuration and operation and maintenance are solved, and efficient and accurate network configuration is achieved.

WO2025246500A9PCT designated stage Publication Date: 2026-02-19HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2025/079509
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-05-30
Filing Date
2025-02-27
Publication Date
2026-02-19

AI Technical Summary

Technical Problem

Network configuration is complex and cumbersome, especially in enterprise campuses where equipment is diverse and there are multiple vendors, making network maintenance difficult, requiring a large amount of manpower, and resulting in low configuration efficiency.

Method used

A network configuration method and apparatus are provided, which generate configuration requests written in natural language, generate configuration results that match the intent using a language model, including information describing the configuration function, operation or scenario, verify the configuration by combining the configuration model and vector database, and output a visual interface to improve the accuracy and efficiency of configuration.

Benefits of technology

It eliminates the need for manual network parameter configuration, improving the efficiency and accuracy of network configuration, simplifying network operation and maintenance processes, and reducing configuration difficulty and manpower requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025079509_19022026_PF_FP_ABST
    Figure CN2025079509_19022026_PF_FP_ABST
Patent Text Reader

Abstract

The present application discloses a network configuration method and apparatus. The method comprises: acquiring a configuration generation request, wherein the configuration generation request is information that is written in natural language and comprises an intent; on the basis of the configuration generation request and a language model, obtaining a configuration result that matches the information comprising the intent, wherein the configuration result is a configuration that is expressed in a preset language and corresponds to the information comprising the intent; and outputting the configuration result. In the present application, on the basis of a configuration generation request, a network configuration apparatus generates a configuration result matching information that is in the configuration generation request and comprises an intent, without the need for users to manually configure network configuration parameters, thereby improving network configuration efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Network configuration method and device

[0001] The present application claims priority to the Chinese Patent Application No. 202410693935.6, filed on May 30, 2024, and entitled "Network Configuration Method and Device", the content of which is incorporated herein by reference in its entirety. TECHNICAL FIELD

[0002] The present application relates to the field of communication technology, and in particular, to a network configuration method and device. BACKGROUND

[0003] Network configuration refers to setting parameters of network devices such as computers, routers, switches, servers or mobile devices, so that these network devices can perform network communication, resource sharing, network security management and fault troubleshooting in a network environment. Network configuration is the basis of network management. Correct network configuration not only helps effective communication between network devices, but also improves network performance, ensures network security and simplifies operation and maintenance management.

[0004] With increasing network demand, network service automation design, issuance and frequent changes, slow online of new features, large human input, and increasing requirements for network operation and maintenance, especially in enterprise park scenarios, there are problems such as multiple scenarios, multiple sites, multiple device types, and multiple devices from multiple manufacturers, making network operation and maintenance difficult. SUMMARY

[0005] The present application provides a network configuration method and device for improving the efficiency of network configuration.

[0006] In a first aspect, the present application provides a network configuration method. A network configuration device obtains a configuration generation request, wherein the configuration generation request is information including an intent written based on natural language. The network configuration device obtains a configuration result matched with the information including the intent based on the configuration generation request and a language model, the configuration result being a configuration corresponding to the information including the intent expressed in a preset language. Then, the network configuration device outputs the configuration result.

[0007] In the present application, the network configuration device generates a configuration result matched with the information including the intent based on the configuration generation request, so as to eliminate the need for manual configuration of each network configuration parameter (also referred to as network configuration feature) by the user, thereby improving the efficiency of network configuration.

[0008] Based on the first aspect, in an optional implementation, the information including the intent in the configuration generation request is used to describe a configuration function, to describe a configuration operation, or to describe a configuration scenario.

[0009] In an optional implementation based on the first aspect, the network configuration apparatus receives a command line input by the user through the visualization interface, where the command line is used to describe the configuration generation request as illustrated in the embodiments of the present application; or the network configuration apparatus receives a sentence input by the user through the visualization interface, where the sentence is used to describe the configuration generation request as illustrated in the embodiments of the present application. The user can write the entire content of the configuration generation request based on the natural language, or can write part of the content of the configuration generation request based on the natural language, which is not limited here.

[0010] In an optional implementation based on the first aspect, the network configuration apparatus obtains a task list including at least one task based on the information including the intent in the configuration generation request. The network configuration apparatus obtains the configuration result based on the at least one task and the language model.

[0011] In an optional implementation based on the first aspect, the task list includes a configuration generation task. In this scenario, the information including the intent in the configuration generation request includes first information and second information, where the first information is used to determine a configuration model, and the second information is used to obtain a configuration parameter. The configuration model describes a data structure of a configuration corresponding to the information including the intent in the configuration generation request, and the configuration parameter is a value of the configuration corresponding to the information including the intent in the configuration generation request. If the configuration result does not meet the requirements of the data structure corresponding to the configuration model, the configuration result can not be applied by the network device, resulting in a network configuration failure.

[0012] Therefore, the network configuration apparatus takes the configuration parameter obtained based on the second information and the configuration model obtained based on the first information as input of the language model to obtain the configuration result. In the embodiments of the present application, the content form of the configuration result is not limited, and the configuration result can be a data structure obtained by adding the configuration parameter to the configuration model by the network configuration apparatus, or can be a text obtained by adding the configuration parameter to the configuration model by the network configuration apparatus. In the present application, the configuration model describes a data structure of a configuration corresponding to the information including the intent in the configuration generation request, and the configuration model is used as a guide or constraint in the process of generating the configuration result to guide the language model to generate a more expected configuration result, thereby improving the accuracy of network configuration.

[0013] In an optional implementation based on the first aspect, the task list includes a retrieval model task and a configuration generation task. In this scenario, the information including the intent in the configuration generation request includes first information and second information, where the first information is used to determine the configuration model, and the second information is used to obtain the configuration parameter. The configuration model describes the data structure of the configuration corresponding to the information including the intent in the configuration generation request, and the configuration parameter is the value of the configuration corresponding to the information including the intent in the configuration generation request. If the configuration result does not meet the requirements of the data structure corresponding to the configuration model, the configuration result may not be applied by the network device, resulting in network configuration failure.

[0014] Therefore, the network configuration apparatus stores a vector database including a plurality of optional configuration models, each of which is used to describe the data structure of one or more network configuration parameters. As known from the above, the configuration generation request includes first information used to determine the configuration model. Therefore, the network configuration apparatus can index the configuration model matching the first information from the vector database based on the first information, and the configuration model is expressed as a vector set in the vector database.

[0015] The network configuration apparatus obtains the configuration result by taking the configuration parameter obtained based on the second information and the configuration model obtained based on the first information as the input of the language model. The content of the configuration result is not limited in the embodiments of the present application. Optionally, the configuration result can be the data structure obtained by adding the configuration parameter to the configuration model, or can be the text obtained by adding the configuration parameter to the configuration model. In the present application, the configuration model describes the data structure of the configuration corresponding to the information including the intent in the configuration generation request. The configuration model serves as a guide or constraint in the process of generating the configuration result, guiding the language model to generate a configuration result that meets the expectations, thereby improving the accuracy of network configuration.

[0016] In an optional implementation based on the first aspect, the task list includes a retrieval model task, a configuration generation task, and a configuration verification task. In this scenario, the information including the intent in the configuration generation request includes first information and second information, where the first information is used to determine the configuration model, and the second information is used to obtain the configuration parameter. The configuration model describes the data structure of the configuration corresponding to the information including the intent in the configuration generation request (such as attribute, behavior, and syntax rule constraint conditions), and the configuration parameter is the value of the configuration corresponding to the information including the intent in the configuration generation request (such as the value of an IP address or a port value). If the configuration result does not meet the requirements of the data structure corresponding to the configuration model, the configuration result may not be applied by the network device, resulting in network configuration failure.

[0017] Therefore, the network configuration apparatus stores a vector database including a plurality of optional configuration models, each of which is used to describe a data structure of one or more network configuration parameters. As described above, the first information used to determine the configuration model is included in the configuration generation request. Therefore, the network configuration apparatus can index the configuration model matching the first information from the vector database based on the first information, and the configuration model is expressed as a vector set in the vector database.

[0018] The network configuration apparatus obtains the configuration result by taking the configuration parameters obtained based on the second information and the configuration model obtained based on the first information as inputs of the language model. In the embodiments of the present application, the content form of the configuration result is not limited. Optionally, the configuration result can be a data structure obtained by adding the configuration parameters to the configuration model, or can be a text obtained by adding the configuration parameters to the configuration model. In the present application, the configuration model describes the data structure of the configuration corresponding to the information intended in the configuration generation request. The configuration model is used as a guide or constraint in the process of generating the configuration result, so as to guide the language model to generate a configuration result more in line with expectations, thereby improving the accuracy of network configuration.

[0019] Next, the network configuration apparatus performs a verification configuration task, that is, the network configuration apparatus verifies the configuration result based on the constraint conditions about configuration syntax or configuration semantics included in the configuration model. Specifically, after the language model generates the configuration result, the network configuration apparatus compares the configuration result with the configuration model. If it is found that the configuration result does not satisfy the constraint of the data structure described in the configuration model, the configuration result can be modified so that the modified configuration result can satisfy the constraint of the configuration model, thereby improving the correctness of the configuration result.

[0020] Based on the first aspect, in an optional implementation, the network configuration apparatus outputs a visual interface based on the configuration generation request and the configuration result. The visual interface includes a first area and a second area. The first area is used to display the configuration result, and the second area is used for a user to input the configuration generation request. Therefore, the user can understand and check the configuration result generated by the configuration generation request from the visual interface. In order to facilitate the user to understand, increase the readability and understandability of the configuration result, the network configuration apparatus can convert the configuration result into a natural language and / or an icon content form. Therefore, the first area of the visual interface displays the configuration result in the form of natural language and / or icon.

[0021] Based on the first aspect, in an optional implementation, as known from above, the first area of the visual interface of the network configuration apparatus displays the configuration result, the user can view and check the configuration result through the first area of the visual interface, and the user can update the configuration result displayed in the first area. Specifically, the user issues an update instruction through the visual interface, the update instruction being used to update the configuration result displayed in the visual interface. After receiving the update instruction, the network configuration apparatus updates the configuration result according to the indication of the update instruction. Thus, the user can further check and correct the configuration result, and the correctness of the configuration result is improved.

[0022] Based on the first aspect, in an optional implementation, if the configuration model is a YANG data model, the configuration result is expressed in a data structure form; if the configuration model is a CLI data model, the configuration result is expressed in a text form.

[0023] The second aspect provides a network configuration apparatus, including:

[0024] An obtaining unit is configured to obtain a configuration generation request, the configuration generation request being information including an intention written based on a natural language;

[0025] A processing unit is configured to obtain a configuration result matched with the information including the intention based on the configuration generation request and a language model, the configuration result being a configuration corresponding to the information including the intention expressed in a preset language;

[0026] The processing unit is further configured to output the configuration result.

[0027] Based on the second aspect, in an optional implementation, the information including the intention is used to describe a configuration function, used to describe a configuration operation, or used to describe a configuration scenario.

[0028] Based on the second aspect, in an optional implementation, the obtaining unit is specifically configured to:

[0029] receive a command line input by a user through an interface, the command line being used to describe the configuration generation request; or

[0030] receive a sentence input by the user through the interface, the sentence being used to describe the configuration generation request.

[0031] Based on the second aspect, in an optional implementation, the processing unit is specifically configured to:

[0032] obtain a task list based on the information including the intention, the task list including at least one task;

[0033] obtain the configuration result based on the task list and the language model.

[0034] In an optional implementation based on the second aspect, the task list comprises a generation configuration task, the information comprising the intent comprises first information used for determining a configuration model and second information used for obtaining a configuration parameter, and the processing unit is specifically used for:

[0035] inputting the configuration parameter obtained based on the second information and the configuration model determined based on the first information as inputs of the language model, and obtaining a configuration result, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model.

[0036] In an optional implementation based on the second aspect, the task list comprises a retrieval model task and a generation configuration task, the information comprising the intent comprises first information used for determining a configuration model and second information used for obtaining a configuration parameter, and the processing unit is specifically used for:

[0037] indexing a vector database with the first information, and obtaining the configuration model, the configuration model being expressed as a set of vectors in the vector database;

[0038] inputting the configuration parameter obtained based on the second information and the configuration model determined based on the first information as inputs of the language model, and obtaining a configuration result, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model.

[0039] In an optional implementation based on the second aspect, the task list comprises a retrieval model task, a generation configuration task and a verification configuration task, the information comprising the intent comprises first information used for determining a configuration model and second information used for obtaining a configuration parameter, and the processing unit is specifically used for:

[0040] indexing a vector database with the first information, and obtaining the configuration model;

[0041] inputting the configuration parameter obtained based on the second information and the configuration model determined based on the first information as inputs of the language model, and obtaining a configuration result, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model.

[0042] verifying the configuration result based on the configuration model comprising constraint conditions on configuration syntax or configuration semantics.

[0043] In an optional implementation based on the second aspect, the output configuration result comprises:

[0044] based on the configuration generation request and the configuration result, outputting a visual interface, the visual interface comprising a first area used for displaying the configuration result and a second area used for inputting the configuration generation request.

[0045] In an optional implementation based on the second aspect, the visual interface further comprises a third area for confirming the configuration result, and the processing unit is further configured to:

[0046] obtain a configuration confirmation response based on the third area;

[0047] convert the configuration result into configuration information and send the configuration information to the network device.

[0048] In an optional implementation based on the second aspect,

[0049] if the configuration model is a next-generation data modeling YANG data model, the configuration result is an expression in the form of a data structure;

[0050] if the configuration model is a command line interface (CLI) data model, the configuration result is an expression in the form of text.

[0051] In a third aspect, the embodiments of the present application provide a controller, comprising: a processor coupled with a memory, the memory being configured to store instructions, when the instructions are executed by the processor, the controller implements the method in the first aspect or any possible implementation manner of the first aspect.

[0052] In a fourth aspect, the embodiments of the present application provide a computer readable storage medium, which stores instructions, when the instructions are executed, the computer executes the method in the first aspect or any possible implementation manner of the first aspect.

[0053] In a fifth aspect, the embodiments of the present application provide a computer program product, which comprises computer program codes, when the computer program codes are run on a computer, the computer executes the method in the first aspect or any possible implementation manner of the first aspect.

[0054] In a sixth aspect, the embodiments of the present application provide a chip, comprising: a processor coupled with a memory, the memory being configured to store instructions, when the instructions are executed by the processor, the chip implements the method in the first aspect or any possible implementation manner of the first aspect.

[0055] The technical effects brought by any implementation manner of the second aspect to the sixth aspect can refer to the technical effects brought by the implementation manners of the first aspect, which will not be repeated here. BRIEF DESCRIPTION OF DRAWINGS

[0056] FIG. 1 is a schematic diagram of a scenario in which a user configures a network through a network configuration interface;

[0057] FIG. 2 is a schematic diagram of a possible scenario of a network configuration interface;

[0058] FIG. 3 is a schematic diagram of another possible scenario of a network configuration interface;

[0059] FIG. 4 is a schematic diagram of a possible, non-limiting system architecture for a communication method according to an embodiment of the present application;

[0060] FIG. 5 is a schematic diagram of a flow of a communication method according to an embodiment of the present application;

[0061] FIG. 6 is a schematic diagram of a possible scenario of an access interface according to an embodiment of the present application;

[0062] FIG. 7 is a schematic diagram of a possible processing flow of a language model according to an embodiment of the present application;

[0063] FIG. 8 is a schematic diagram of a possible scenario of verifying a configuration result;

[0064] FIG. 9 is a schematic diagram of a possible processing flow of a configuration result according to an embodiment of the present application;

[0065] FIG. 10 is a schematic diagram of a visualization interface;

[0066] FIG. 11 is another schematic diagram of a visualization interface;

[0067] FIG. 12 is another schematic diagram of a visualization interface;

[0068] FIG. 13 is another schematic diagram of a visualization interface;

[0069] FIG. 14 is a schematic diagram of a possible structure of a network configuration apparatus according to an embodiment of the present application;

[0070] FIG. 15 is a schematic diagram of a processing flow of a plurality of functional modules in a network configuration apparatus;

[0071] FIG. 16 is another schematic diagram of a structure of a network configuration apparatus according to an embodiment of the present application;

[0072] FIG. 17 is a schematic diagram of a logical structure of a network configuration apparatus according to an embodiment of the present application. DETAILED DESCRIPTION

[0073] The embodiments of the present application are described below with reference to the accompanying drawings. The terms used in the embodiments section of the present application are only used to explain the embodiments of the present application, and are not intended to limit the embodiments of the present application. It is known to those skilled in the art that, as technology develops and new scenarios appear, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.

[0074] In the embodiments of this application, "at least one" means one or more, and "multiple" means two or more. The "and / or" describes the association relationship of the associated objects, which means that there can be three kinds of relationships, for example, A and / or B can represent: A exists alone, A and B exist together, and B exists alone, where A and B can be singular or plural. "At least one of the following" or similar expressions means any combination of these items, including any combination of single or multiple items. For example, at least one of a, b, or c can represent: a, b, c, a-b, a-c, b-c, or a-b-c, where a, b, and c can be single or multiple.

[0075] The terms "first", "second", "third", "fourth" and the like in the description and claims of this application and above-mentioned drawings, if any, are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the use of the terms so construed can be interchanged, such that, for example, embodiments of the present application described herein could operate in other sequences than illustrated or described herein. Further, the terms "comprise", "comprising", "include", "including", and "has", "having" and variants thereof are intended to cover a non-exclusive inclusion, such that a process, method, system, product, or apparatus that comprises, includes, or has a list of steps or units can not necessarily disclose all of those steps or units, but can include additional steps or units not expressly listed or inherent to such process, method, system, product, or apparatus.

[0076] Some terms or terminologies used in the embodiments of the present application are explained below, which are also part of the invention.

[0077] Domain-Specific Language (DSL): A DSL is a computer programming language designed for a specific domain or problem area. The main feature and advantage of a DSL is its high specificity and conciseness, which makes it easier for users to understand and use the DSL to express domain-specific concepts and logic. Compared to general-purpose programming languages, DSLs focus more on the problems and requirements within a domain, providing higher-level abstractions and more intuitive expressions, thus improving development efficiency and code quality. DSLs are usually classified into two types: External DSL and Internal DSL. External DSL is a language independent of general-purpose programming languages, usually used by domain experts or developers, and can use custom syntax to describe specific domain problems. External DSL can be converted into code that can be understood and executed by the underlying programming language (such as Java, Python, etc.) through a parser; Internal DSL is a language based on general-purpose programming languages, using the syntax and features of the programming language to create expressions and statements specific to a domain. The purpose of designing an internal DSL is to make it easier for domain experts and developers to express domain-specific concepts and logic in general-purpose programming languages. In summary, DSL is a language designed for a specific domain, which can better meet the needs of the domain and improve the efficiency and maintainability of software development.

[0078] Command Line Interface (CLI): CLI is a user interface for interacting with a computer, where users can input text commands to perform operations and access system functions. CLI commands are instructions entered by users in the CLI environment, usually composed of command names, options (flags or switches), arguments, and possibly pipe symbols (|) and redirection symbols, used to perform specific operations or query system status. CLI commands are widely used in computer system management, software development, network configuration, and data processing, etc. CLI commands provide a fast, flexible, and efficient way to interact with and control computers, especially suitable for scenarios that require automation or remote management.

[0079] Large Language Models (LLM): LLM refers to deep learning models with a large number of parameters, usually used for Natural Language Processing (NLP) tasks. These LLM models use large-scale text datasets during training to learn the statistical rules and semantic information of language, generating text, performing text classification, translation and summary generation, etc. LLM has a large-scale dataset and a large number of parameters, making LLM models more fine-grained and more in-depth understanding of the complexity of natural language. The pre-training process allows LLM to solve common language problems such as text classification, question answering and document summarization. The fine-tuning process allows the model to be customized to solve specific problems in different fields, such as retail, finance and entertainment. The characteristics of LLM are its huge size and versatility, which uses a hierarchical node network to work, with an encoder and decoder with self-attention function to extract meaning from a series of texts and understand the relationship between words and phrases. This allows LLM to be trained unsupervised and understand basic grammar, language and knowledge through autonomous learning.

[0080] Prompt engineering is an important concept in the field of artificial intelligence, especially in Natural Language Processing (NLP). The basic idea of prompt engineering is to provide some information or context to neural network models to guide them to generate expected output. These prompts can be questions, descriptive text, keywords, or even the output of the neural network model. In this way, the neural network model can better understand the background and requirements of the task, and generate more accurate and relevant results.

[0081] Next, the possible scenarios involved in the embodiments of the present application are introduced.

[0082] Network configuration refers to a series of parameters and settings set for network devices such as computers, routers, switches, servers, or mobile devices, so that these network devices can effectively participate in the network environment, conduct network communication, resource sharing, network security management, and fault troubleshooting, etc. Network configuration refers to the setting and layout of network devices or communication systems. For example, network configuration includes network topology, Internet Protocol (IP) address allocation, routing configuration, security settings, etc. The purpose of network configuration is to ensure that the network can operate normally and meet specific needs, such as providing stable connections, ensuring data security, optimizing network performance, etc. Network configuration is the basis of network management, and correct network configuration can not only facilitate effective communication between network devices, but also improve network performance, ensure network security, and simplify operation and maintenance management. With the development of network technology and changes in business needs, network configuration work also needs to be continuously updated and optimized.

[0083] The development of Software Defined Networking (SDN) architecture simplifies the process of network configuration. Although SDN brings many advantages, network configuration still requires frequent manual intervention, which increases costs and risks. The complexity and error-prone nature of manual configuration requires specialized network administrators to be familiar with various APIs and protocols. Therefore, there is a need for a more efficient, simpler, and safer way to configure networks.

[0084] For network operations, network configuration remains a difficult, complex, and expensive task. In addition, the abstraction and composition of networks force these configuration tools to adopt custom specifications or languages to succinctly describe network intent. These approaches present network operators with another challenge, as they must become proficient in a new Domain-Specific Language (DSL) that may not be widely used and can have flaws.

[0085] On the other hand, as network demands increase (big data, intelligentization), network business automation design, issuance, and frequent changes, new features are slow to go online, manpower is large, and the skills of network administrators are high. In particular, in enterprise park scenarios, there are many scenarios, many sites, many types of equipment, many devices, and low personnel skills. Maintenance equipment has multiple vendor devices. Network administrators need to view command lines or manuals one by one to find the configuration of the automation interface, design and combine. As can be seen, the current network configuration work of network administrators is relatively cumbersome and requires a large amount of human resources.

[0086] FIG. 1 is a schematic diagram of a scenario in which a user configures a network through a network configuration interface. As shown in FIG. 1, the controller provides a visual network configuration interface for the user, such as shown in FIG. 2 or FIG. 3. However, the operation modes of the network configuration interfaces provided by different controllers are quite different, and the user needs to complete complex configuration design and combination on the network configuration interface, which requires the user to have high configuration skills, resulting in great configuration difficulty and tedious configuration, which seriously affects the network configuration efficiency.

[0087] To solve the problems of the above-mentioned general solutions, the embodiments of the present application provide a network configuration method and device, which helps to improve the network configuration efficiency and reduce the configuration difficulty.

[0088] FIG. 4 is a possible, non-limiting system architecture for implementing the network configuration method in the embodiments of the present application. In the scenario shown in FIG. 4, the network configuration device can configure at least one network device (for example, network device 1, network device 2 and network device 3 shown in FIG. 4). The network configuration device can be a control device, a network management device or other device with network configuration function. The network configuration device sends the configuration result to the network device, and then the network device updates the network configuration according to the indication of the configuration result. FIG. 5 is a schematic diagram of the processing flow of the network configuration device in FIG. 4. The network configuration device in FIG. 5 can be a chip, a chip system or a processor for implementing the method; or the network configuration device can also be a logic node, a logic module or software for implementing all or part of the functions. As shown in FIG. 5, the network configuration method in the embodiments of the present application includes but is not limited to steps 101 to 105.

[0089] 101. The network configuration device obtains a configuration generation request.

[0090] The network configuration device obtains the configuration generation request based on the input of the user, and the configuration generation request is based on a request written in natural language and includes information of an intent. The configuration generation request is used to generate or update at least one network configuration parameter, which includes network topology, address allocation, routing configuration or security settings, etc. Wherein, the configuration generation request is used to generate a network configuration parameter, which means that the configuration generation request is used to add one or more network configuration parameters; and the configuration generation request is used to update a network configuration parameter, which means that the configuration generation request is used to modify the configured network configuration parameter.

[0091] In the embodiments of the present application, the network configuration apparatus is a logic node, a logic module or software for performing the network configuration method. It should be understood that the "network configuration apparatus" is only a general term for the device performing the network configuration method, and does not specifically refer to one or more devices, and the device performing the network configuration method can also not be called "network configuration apparatus", but can be called by other names, such as "network management device", "scheduling device", "controller", "control device" or "server", etc. The specific name is not limited here. In the embodiments of the present application, only "network configuration apparatus" is taken as an example for description.

[0092] The network device in the embodiments of the present application is an entity for transmitting a signal, or receiving a signal, or transmitting and receiving a signal. Optionally, the network device can be a router, a switch or a bridge, a computer device, a server or a mobile device, etc. The specific name is not limited here.

[0093] Optionally, the network configuration apparatus can provide a visual interface for the user, such as the visual interface shown in FIG. 6. The visual interface includes a second area for the user to input a configuration generation request. The second area includes a text input box. The user can input information expressing his intention through the text input box in the second area, so that the network configuration apparatus obtains the configuration generation request.

[0094] In a possible implementation, the network configuration apparatus obtains the configuration generation request based on a command line input by the user through the visual interface. The command line is used to describe the configuration generation request. Alternatively, the network configuration apparatus obtains the configuration generation request based on a sentence input by the user through the visual interface. The sentence is used to describe the configuration generation request. The user can write all the content of the configuration generation request based on natural language, or can write part of the content of the configuration generation request based on natural language. The specific name is not limited here.

[0095] Optionally, the intention information included in the configuration generation request is used to describe a configuration function, to describe a configuration operation or to describe a configuration scenario. Specifically, the dialogue capability supported by the language model of the network configuration apparatus can be divided into multiple capability types. The network configuration apparatus determines the capability type of the language model accessed by the configuration generation request through the intention information included in the configuration generation request, so as to obtain a configuration result matched with the intention information in the configuration generation request.

[0096] The capability types supported by the language model include capability A, capability B, and capability C. The capability A is to configure a function of a network device, for example, a configuration generation request is "please design the network configuration of the router". If the information of the intent included in the configuration generation request is used to describe the configuration function, it means that the configuration generation request accesses the capability A of the language model. The capability B is to operate an existing network configuration characteristic template, for example, a configuration generation request is "copy the network configuration characteristics 100 times and send them to 100 network devices". If the information of the intent included in the configuration generation request is used to describe the configuration operation, it means that the configuration generation request accesses the capability B of the language model. The capability C is to generate a configuration result for a network configuration in a certain scenario, for example, a configuration generation request is "please configure a small network", and the controller takes the configuration template of the small network as the first data model. If the information of the intent included in the configuration generation request is used to describe the configuration scenario, it means that the configuration generation request accesses the capability C of the language model.

[0097] 102. The network configuration apparatus obtains a configuration result matched with the information of the intent based on the configuration generation request and the language model.

[0098] The language model can be deployed on the network configuration apparatus, and can also be deployed on other devices in communication with the network configuration apparatus. The embodiments of the present application take the language model deployed on the network configuration apparatus as an example for description, and the implementation mode of the language model deployed on other devices in communication with the network configuration apparatus can refer to the implementation mode of the language model deployed on the network configuration apparatus, and will not be described one by one. The language model belongs to a kind of neural network model, and the language model can be a large language model (Large Language Models, LLM). The language model can analyze the configuration generation request and take the information of the intent obtained by analysis as the input of the language model, and the language model obtains a configuration result based on the above information of the intent, and the configuration result is a configuration corresponding to the information of the intent expressed in a preset language.

[0099] In a possible implementation, the preset language can be a Yet Another Next Generation (YANG) language, that is, the configuration result is a configuration corresponding to the information including the intent expressed in the YANG language; or the preset language can be a Command Line Interface (CLI) language, that is, the configuration result is a configuration corresponding to the information including the intent expressed in the CLI language; or the preset language can also be another Domain-Specific Language (DSL), which is not limited herein. For example, the DSL language can be a Topology and Orchestration Specification for Cloud Applications (TOSCA), a Web Ontology Language (OWL), or a Terraform language. The configuration result based on the DSL has good Atomicity, Consistency, Isolation, and Durability, and the like, transaction capabilities, thereby improving the efficiency and performance of network configuration.

[0100] In a possible implementation, the specific process in which the network configuration apparatus obtains the configuration result includes: obtaining, by the network configuration apparatus, a task list based on the information including the intent in the configuration generation request, the task list including at least one task; and obtaining, by the network configuration apparatus, the configuration result based on the at least one task and the language model. The task list includes a configuration generation task, and the task list further includes one or more of a model retrieval task and a configuration verification task. In this scenario, the information including the intent in the configuration generation request includes first information and second information, where the first information is used to determine a configuration model, and the second information is used to obtain a configuration parameter. The configuration model describes a data structure of the configuration corresponding to the information including the intent in the configuration generation request, for example, a constraint condition such as an attribute, a behavior, and a syntax rule. The configuration parameter is a value of the configuration corresponding to the information including the intent in the configuration generation request, for example, a value of an IP address or a port value. If the configuration result does not meet the requirement of the data structure corresponding to the configuration model, the configuration result can not be applied by the network device, resulting in a network configuration failure. In the embodiment of the present application, the configuration model describes the data structure of the configuration corresponding to the information including the intent in the configuration generation request, and the configuration model serves as a guide or a constraint in the process of generating the configuration result, guiding the language model to generate a more expected configuration result, thereby improving the accuracy of network configuration.

[0101] For example, if the configuration generation request is "please help design the network configuration of router 1", the configuration generation request can involve the configuration of multiple network configuration parameters of the router 1, such as clock synchronization, gateway, subnet mask, and routing rules. The router 1 is one of the network devices managed by the network configuration apparatus, for example, the network device 1 shown in FIG. 4. Accordingly, the configuration model obtained by the network configuration apparatus based on the first information is a data structure describing the clock synchronization, gateway, subnet mask, and routing rules.

[0102] FIG. 7 is a schematic diagram of a possible processing flow of the language model in the embodiment of the present application. As shown in FIG. 7, the language model obtains a task list based on the received configuration generation request, the task list including a retrieval model task, a configuration generation task, and a configuration verification task. The network configuration apparatus sequentially performs the retrieval model task, the configuration generation task, and the configuration verification task. The configuration generation task and the configuration verification task can be a process that is executed multiple times in a loop.

[0103] The retrieval model task: determining the configuration model based on the first information and obtaining the configuration parameter based on the second information.

[0104] In a possible implementation, the network configuration apparatus stores a vector database, the vector database including multiple selectable configuration models, each of which is used to describe a data structure of one or more network configuration parameters. As described above, the configuration generation request includes the first information used to determine the configuration model. Therefore, the network configuration apparatus can index the configuration model matching the first information from the vector database based on the first information, the configuration model being expressed as a vector set in the vector database.

[0105] Alternatively, the network configuration apparatus parses the keywords in the configuration generation request, and then matches the keywords with the keywords associated with each configuration model in the vector database, so as to index the configuration model matching the configuration generation request in the vector database. Specifically, each configuration model in the vector database has at least one keyword associated therewith. The first information in the embodiment of the present application includes one or more keywords in the configuration generation request. If the keyword in the configuration generation request matches the keyword associated with a certain data model, the configuration model is determined as the configuration model matching the first information. The matching between the keywords can be that the keyword in the configuration generation request is the same as the keyword associated with the data model, or the similarity between the keyword in the configuration generation request and the keyword associated with the data model satisfies a threshold.

[0106] The configuration task of generating is to take the configuration parameters obtained based on the second information and the configuration model obtained based on the first information as inputs of the language model, and obtain a configuration result. Embodiments of the present application do not limit the content form of the configuration result. Optionally, the configuration result can be a data structure obtained after the network configuration device adds the configuration parameters to the configuration model, or the configuration result can be text obtained after the network configuration device adds the configuration parameters to the configuration model. If the configuration model is a YANG data model, the above configuration result is expressed in the form of a data structure. If the configuration model is a CLI data model, the above configuration result is expressed in the form of text.

[0107] The configuration task of checking is to check the configuration result based on the constraint conditions about the configuration syntax or the configuration semantics included in the configuration model. Specifically, after the language model generates the configuration result, the network configuration device compares the configuration result with the configuration model. If it is found that the configuration result does not satisfy the constraint of the data structure described by the configuration model, the configuration result can be modified so that the modified configuration result can satisfy the constraint of the configuration model, thereby improving the correctness of the configuration result. Optionally, after the network configuration device performs the configuration task of generating and obtains the configuration result generated by the language model, the network configuration device can directly output the configuration result without performing the above configuration task of checking, that is, the network configuration device performs step 103.

[0108] Please refer to FIG. 8, which is a schematic diagram of a possible scenario of checking the configuration result. In the scenario shown in FIG. 8, the left side is the configuration model used for checking the configuration result, and the right side is the configuration result output by the language model. Then, the network configuration device checks the configuration result according to the configuration model as a specification or a standard.

[0109] Optionally, different network device manufacturers often have their own DSL rules, and even the DSL rules of different series of network devices of the same manufacturer can also be different. In view of this, please refer to FIG. 9, which is a schematic diagram of a possible processing flow of the configuration result in embodiments of the present application. As shown in FIG. 9, after the language model outputs the configuration result or the checking of the configuration result is completed, the network configuration device can update the configuration result adaptively according to several DSL rules (for example, DSL rule 1 and DSL rule 2 shown in FIG. 9) of other network devices, so that the updated configuration result can satisfy the DSL rules of each network device.

[0110] 103. The network configuration device outputs the configuration result through a visual interface.

[0111] The network configuration device obtains a visualization interface based on the configuration generation request and the configuration result and outputs the visualization interface. The visualization interface includes a first area and a second area. The first area is configured to display the configuration result, and the second area is configured to receive information used to obtain the configuration generation request.

[0112] For example, refer to FIG. 10, which is a schematic diagram of a visualization interface. In the example shown in FIG. 10, a user inputs a configuration generation request in the second area of the visualization interface. The configuration generation request is used to generate or update network configuration parameters of a network device. In the example of FIG. 10, the first information in the configuration generation request includes keywords of multiple network configuration parameters, such as “device name (sysname)”, “super user password (super password)”, “time zone (clock timezone)”, “date and time (clock datetime)”, “management interface (interface)”, and “IP address (ip address)”, and the second information in the configuration generation request includes values of the network configuration parameters. The network configuration device obtains configuration templates of the network configuration parameters based on the keywords, and obtains the configuration result shown in FIG. 10 by taking the configuration templates and the values of the network configuration parameters as inputs of a language model. The network configuration device outputs the configuration result obtained based on the configuration generation request in the first area of the visualization interface. The entire network configuration process can be automatically implemented, and the execution efficiency of network configuration is high.

[0113] Exemplarily, refer to FIG. 11, which is another schematic diagram of the visualization interface. In the example scenario shown in FIG. 11, the user inputs a configuration generation request through the second area in the visualization interface, and the configuration generation request is used to generate or update the network configuration parameters of the network device. In the existing network configuration scheme shown in FIG. 1, it is difficult for the user to be familiar with the configuration operations corresponding to various network configuration parameters and the jumps between multiple operation pages, resulting in low efficiency of network configuration. In the network configuration method of the embodiment of the present application, the user inputs the configuration generation request as shown in FIG. 11 through the second area in the visualization interface, and the configuration generation request describes “please design the network configuration of the router”. The configuration generation request does not describe a specific network configuration parameter that needs to be configured and the value of the network configuration parameter, and the keywords of the configuration generation request can be “router” and “network configuration”. Therefore, the network configuration apparatus obtains the configuration template matched with the keywords, which can be a general and default configuration template of the router for example, and sets the default configuration parameter value. The network configuration apparatus takes the configuration template and the default configuration parameter value as the input of the language model, and obtains the configuration result as shown in FIG. 11 for example. The network configuration apparatus outputs and displays the obtained configuration result in the first area of the visualization interface, facilitating the user to understand and check the configuration result. The entire network configuration process can be automatically implemented, and the execution efficiency of network configuration is high.

[0114] Exemplarily, refer to FIG. 12, which is another schematic diagram of the visualization interface. In the example scenario shown in FIG. 12, the user needs to configure multiple network configuration characteristics in batches. For example, the user needs to add 10 interfaces, add 10 network configurations for each interface, and perform 10 operation events for each interface, so that the network configuration requirement of the user needs to spend 1000 operation events in total. In the communication method of the embodiment of the present application, the user inputs the configuration generation request as shown in FIG. 12 through the second area in the visualization interface, and the configuration generation request expresses the above network configuration requirement through natural language, that is, the configuration generation request is “please copy 10 interfaces according to the above interface characteristics, and name the XX field of the interface in the manner of number+1 to generate the corresponding configuration”. Then, the network configuration apparatus obtains the configuration template associated with the interface characteristics indicated by the configuration generation request, and takes the naming manner indicated by the configuration generation request as the configuration parameter value of the interface. The network configuration apparatus takes the above configuration template and configuration parameter value as the input of the language model, and obtains the configuration result as shown in FIG. 12 for example. The network configuration apparatus outputs and displays the obtained configuration result in the first area of the visualization interface, facilitating the user to understand and check the configuration result. Therefore, the controller automatically performs multiple repeated operation events in batches, greatly improving the execution efficiency of network configuration.

[0115] For example, refer to FIG. 13, which is another schematic diagram of the visualization interface. In the example scenario shown in FIG. 13, the user inputs a configuration generation request (e.g., the configuration generation request is "please configure a small network") through the second region of the visualization interface, as shown in FIG. 13. In this example, the keyword in the configuration generation request is "small network", and the network configuration apparatus retrieves a configuration template for a small network and sets default values for the configuration parameters. The network configuration apparatus inputs the configuration template and the default values for the configuration parameters into the language model to obtain a configuration result, as shown in the example of FIG. 13. The network configuration apparatus outputs and displays the obtained configuration result in the first region of the visualization interface, so as to facilitate the user to understand and check the configuration result.

[0116] 104. The network configuration apparatus receives feedback information from the user through the visualization interface.

[0117] The network configuration apparatus receives feedback information from the user through the visualization interface, and the feedback information can be an update instruction or an approval response.

[0118] As described above, the first region of the visualization interface of the network configuration apparatus displays the configuration result, so that the user can view and check the configuration result through the first region of the visualization interface, and the user can update the configuration result displayed in the first region. Specifically, the user issues an update instruction through the visualization interface, and the update instruction is used to update the configuration result displayed in the visualization interface. After receiving the update instruction, the network configuration apparatus updates the configuration result according to the indication of the update instruction. Thus, the user can further check and correct the configuration result, and the correctness of the configuration result is improved.

[0119] In a possible implementation, the visualization interface includes a third region, and the third region is used for the user to approve the configuration result. For example, the third region of the visualization interface can include an "approve" button or a "modify" button in the visualization interface. When the user confirms that the configuration result displayed in the first region of the current visualization interface is correct, the user can issue an approval response (e.g., the user clicks the "approve" button) through the third region of the visualization interface, and the approval response indicates that the configuration result has been approved by the user. After receiving the approval response, the network configuration apparatus converts the configuration result into configuration information and sends the configuration information to the network device (i.e., step 106 is performed). Thus, the incorrect configuration result is avoided from being sent to the network device and executed.

[0120] 105. The controller sends the configuration information to the network device.

[0121] After the network configuration device receives the confirmation response, the network configuration device converts the configuration result into configuration information and sends the configuration information to the network device. After the network device receives the configuration information, the network device executes the configuration information, thereby completing the generation or update of the network configuration parameters.

[0122] In a possible implementation, the number of network devices is N, where N is an integer greater than 1. That is, the configuration generation request can be used to configure N network devices, and the configuration information generated by the network configuration device can be sent to the N network devices. The configuration information received by the N network devices can be the same or can be different. Each network device updates the network configuration parameters of the network device according to the configuration information received by the network device, thereby achieving batch generation or batch update of the network configuration parameters of the N network devices and improving the efficiency of network configuration.

[0123] To better implement the scheme of the embodiments of the present application, a plurality of functional modules can be deployed in the network configuration device, and the plurality of functional modules work cooperatively, thereby implementing at least one of the steps 101 to 105. Please refer to FIG. 14, which is a possible structural schematic diagram of the network configuration device in the embodiments of the present application. In the scenario shown in FIG. 14, the network configuration device includes a language model, a model retrieval module, a configuration verification module, a visual interface, and the like. Please refer to FIG. 15, which is a processing flow schematic diagram of the plurality of functional modules in the controller. As shown in FIG. 15, the processing flow of the plurality of functional modules in the controller includes but is not limited to steps 201 to 206.

[0124] 201. The user inputs a configuration generation request to the network configuration device, and the configuration generation request is input to the language model of the network configuration device. For details, please refer to the description of step 101.

[0125] 202. The model retrieval module obtains a configuration model corresponding to the configuration generation request. The configuration generation request includes first information used to determine the configuration model. Therefore, the network configuration device can index the first information to obtain a configuration model matched with the first information, and the configuration model describes the data structure of the network configuration parameters requested by the configuration generation request.

[0126] 203. The configuration generation request and the configuration model are input to the language model to obtain a configuration result. For details of step 203, please refer to the description of step 102.

[0127] 204. The configuration verification module verifies the configuration result based on the constraint condition about the configuration syntax or the configuration semantics included in the configuration model. Specifically, after the language model generates the configuration result, the network configuration apparatus compares the configuration result with the configuration model. If it is found that the configuration result does not satisfy the constraint of the data structure described in the configuration model, the configuration result can be modified so that the modified configuration result can satisfy the constraint of the configuration model, thereby improving the correctness of the configuration result.

[0128] Optionally, the configuration generation request is used to update multiple network configuration parameters, and the network configuration apparatus needs to generate corresponding configuration results for the multiple network configuration parameters. Therefore, the network configuration apparatus repeatedly performs steps 203 to 204 for each network configuration parameter until the configuration result of each network configuration parameter is obtained.

[0129] 205. The verified configuration result is displayed in the visualization interface. For details, refer to the description of the foregoing step 103, which will not be repeated here.

[0130] 206. The user confirms the configuration result displayed in the visualization interface, and the network configuration apparatus converts the configuration result into configuration information, and sends the configuration information to the network device. For details, refer to the description of the foregoing steps 104 to 105, which will not be repeated here.

[0131] The embodiment of the present application also provides a related apparatus for implementing the above scheme. Specifically, refer to FIG. 16, which is a structural schematic diagram of a network configuration apparatus provided by the embodiment of the present application. The network configuration apparatus in FIG. 16 can be a chip, a chip system, or a processor for supporting the network configuration apparatus to implement the method; or the network configuration apparatus can also be a logic node, a logic module, or software for implementing all or part of the network configuration apparatus functions. As shown in FIG. 16, the network configuration apparatus includes:

[0132] The obtaining unit 301 is configured to obtain a configuration generation request, the configuration generation request being information including an intention written based on a natural language;

[0133] The processing unit 302 is configured to obtain a configuration result corresponding to the information including the intention expressed in a preset language based on the configuration generation request and a language model, the configuration result being a configuration corresponding to the information including the intention.

[0134] The processing unit 302 is configured to output the configuration result.

[0135] In a possible design, the information including the intention is used to describe a configuration function, used to describe a configuration operation, or used to describe a configuration scenario.

[0136] In a possible design, the obtaining unit 301 is specifically configured to:

[0137] receive a command line input by the user through the interface, the command line being used to describe the configuration generation request; or

[0138] receive a statement input by the user through the interface, the statement being used to describe the configuration generation request.

[0139] In a possible design, the processing unit 302 is specifically configured to:

[0140] obtain a task list based on the information including the intention, the task list including at least one task;

[0141] obtain a configuration result based on the task list and the language model.

[0142] In a possible design, the task list includes a configuration generation task, the information including the intention includes first information used to determine a configuration model and second information used to obtain a configuration parameter, and the processing unit 302 is specifically configured to:

[0143] obtain the configuration result by taking the configuration parameter obtained based on the second information and the configuration model obtained based on the first information as input of the language model, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model.

[0144] In a possible design, the task list includes a configuration retrieval task and a configuration generation task, the information including the intention includes first information used to determine a configuration model and second information used to obtain a configuration parameter, and the processing unit 302 is specifically configured to:

[0145] index a vector database with the first information to obtain the configuration model, the configuration model being expressed as a set of vectors in the vector database;

[0146] obtain the configuration result by taking the configuration parameter obtained based on the second information and the configuration model determined based on the first information as input of the language model, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model.

[0147] In a possible design, the task list includes a configuration retrieval task, a configuration generation task and a configuration verification task, the information including the intention includes first information used to determine a configuration model and second information used to obtain a configuration parameter, and the processing unit 302 is specifically configured to:

[0148] index the vector database with the first information to obtain the configuration model;

[0149] The configuration result is obtained by taking the configuration parameter acquired based on the second information and the configuration model determined based on the first information as input of the language model, and the configuration result is a data structure obtained by adding the configuration parameter to the configuration model or text obtained by adding the configuration parameter to the configuration model.

[0150] The configuration result is verified based on the constraint condition about the configuration syntax or the configuration semantics included in the configuration model.

[0151] In a possible design, the output configuration result includes:

[0152] Based on the configuration generation request and the configuration result, a visual interface is output, and the visual interface includes a first area for displaying the configuration result and a second area for inputting the configuration generation request.

[0153] In a possible design, the visual interface further includes a third area for confirming the configuration result, and the processing unit 302 is further configured to:

[0154] The configuration confirmation response is acquired based on the third area;

[0155] The configuration result is converted into configuration information and sent to the network device.

[0156] In a possible design,

[0157] If the configuration model is a next-generation data modeling YANG data model, the configuration result is expressed in the form of a data structure;

[0158] If the configuration model is a command line interface CLI data model, the configuration result is expressed in the form of text.

[0159] It should be noted that the information interaction and execution process between the modules / units in the network configuration apparatus are based on the same concept as the method embodiments corresponding to FIG. 5 or FIG. 15, and the specific content can be referred to the description of the method embodiments in the foregoing method embodiments of the present application, which will not be described here.

[0160] Please refer to FIG. 17, which is a logical structure diagram of the network configuration apparatus 40 provided by an embodiment of the present application. The network configuration apparatus in FIG. 17 can be the network configuration apparatus described in the embodiment corresponding to FIG. 16, and is configured to implement the functions of the network configuration apparatus in the embodiment corresponding to FIG. 5 or FIG. 15. The network configuration apparatus 40 includes a memory 401, a processor 402, a communication interface 403, and a bus 404. The memory 401, the processor 402, and the communication interface 403 are in communication connection with each other through the bus 404.

[0161] The memory 401 can be a read only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 401 can store a program, and when the program stored in the memory 401 is executed by the processor 402, the processor 402 and the communication interface 403 are configured to perform steps 101-105 of the network configuration method embodiment described above.

[0162] The processor 402 can be a central processing unit (CPU), a microprocessor, an application specific integrated circuit (ASIC), a graphics processing unit (GPU), a digital signal processing (DSP), a field programmable gate array (FPGA), or other programmable logic device, a discrete gate or transistor logic device, a discrete hardware component, or any combination thereof, configured to execute a related program to implement one or more steps of steps 101-105 of the network configuration method embodiment. The steps of the data processing method disclosed in the embodiments of the present application can be executed by a compiler and an executor, which can be executed by a hardware decoding processor or a combination of hardware and software modules in the decoding processor. The software module can be located in a random access memory, a flash memory, a read only memory, a programmable read only memory, an electrically erasable programmable memory, a register, or other mature storage medium in the art. The storage medium is located in the memory 401, and the processor 402 reads the information in the memory 401 and executes one or more steps of steps 101-105 of the network configuration method embodiment in combination with the hardware.

[0163] The communication interface 403 uses a transceiver device such as, but not limited to, a transceiver to realize the communication between the network configuration device 40 and other devices or communication networks.

[0164] The bus 404 can implement a path for conveying information among the various components of the network configuration apparatus 40 (e.g., the memory 401, the processor 402, and the communication interface 403). The bus 404 can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is shown in FIG. 17, but it does not mean that there is only one bus or only one type of bus.

[0165] It should be noted that the information interaction and execution process between the modules / units in the network configuration apparatus 40 are based on the same concept as the method embodiments corresponding to FIG. 5 or FIG. 15, and the specific content can be referred to the description of the method embodiments in the foregoing embodiments of the present application, which will not be described here.

[0166] The embodiments of the present application further provide a computer program product containing instructions. The computer program product can be a software or program product containing instructions, which can run on a computing device or be stored in any available medium. When the computer program product runs on at least one computer device, the at least one computer device is caused to execute the method described in the foregoing embodiments of FIG. 5 or FIG. 15.

[0167] The embodiments of the present application further provide a computer readable storage medium. The computer readable storage medium can be any available medium that the computing device can store or a data storage device such as a data center containing one or more available media. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state disk), etc. The computer readable storage medium includes instructions, which instruct the computing device to execute the method described in the foregoing embodiments of FIG. 5 or FIG. 15.

[0168] The communication device provided by the embodiments of the present application can be a chip, which comprises a processing unit, for example, a processor, and a communication unit, for example, an input / output interface, a pin, a circuit or the like. The processing unit can execute computer execution instructions stored in a storage unit, so that the chip executes the method described in the embodiments shown in FIG. 5 or FIG. 15. Alternatively, the storage unit is a storage unit in the chip, such as a register, a cache or the like, and the storage unit can also be a storage unit outside the chip in the wireless access device, such as a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a random access memory (RAM) or the like.

[0169] It should be additionally noted that the apparatus embodiments described above are merely illustrative, wherein the units illustrated as separate components can or can not be physically separated, and the components illustrated as units can or can not be physical units, that is, they can be located in one place or distributed on multiple network units. Part or all of the modules can be selected to achieve the purpose of the embodiments of the present application according to actual needs. In addition, in the apparatus embodiments provided by the embodiments of the present application, the connection relationship between the modules indicates that there is a communication connection between them, which can be implemented as one or more communication buses or signal lines.

[0170] Through the above description of the embodiments, those skilled in the art can clearly understand that the embodiments of the present application can be realized by means of software and necessary general hardware, and of course, can also be realized by special hardware including special integrated circuits, special CPUs, special memories, special components and the like. Generally, functions completed by computer programs can be easily realized by corresponding hardware, and specific hardware structures for realizing the same function can also be various, such as analog circuits, digital circuits or special circuits. However, for the embodiments of the present application, software program implementation is a better implementation mode in most cases. Based on such understanding, the technical solutions of the embodiments of the present application can be embodied in the form of a software product, which is stored in a readable storage medium, such as a computer soft disk, a U disk, a mobile hard disk, a ROM, a RAM, a magnetic disk or an optical disk, and includes a plurality of instructions to make a computer device (which can be a personal computer, a training device or a network device) execute the methods described in the embodiments of the present application.

[0171] In the above embodiments, all or part of the embodiments can be implemented by software, hardware, firmware or any combination thereof. When implemented by software, all or part of the embodiments can be implemented in the form of a computer program product.

[0172] The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of the present application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another, for example, the computer instructions can be transmitted from one website, computer, training device or data center to another website, computer, training device or data center through wired (such as coaxial cable, optical fiber) or wireless (such as infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be stored by the computer or a data storage device such as a training device, a data center, etc. integrated with one or more available media sets. The available media can be a magnetic medium (for example, a floppy disk, a hard disk, a magnetic tape), an optical medium (for example, a DVD), or a semiconductor medium (for example, a solid state disk (SSD)) and the like.

[0173] In various embodiments of the present application, if there is no special description and logical conflict, the terms between different embodiments, and / or the description is consistent and can be referred to each other, and the technical features in different embodiments can be combined to form new embodiments according to their inherent logical relationship.

Claims

1. A network configuration method characterized by, The method comprises: obtaining a configuration generation request, the configuration generation request being information including an intention written in a natural language; obtaining a configuration result matched with the information including the intention based on the configuration generation request and a language model, the configuration result being a configuration corresponding to the information including the intention expressed in a preset language; outputting the configuration result.

2. The method of claim 1, wherein, The information including the intention is used for describing a configuration function, used for describing a configuration operation, or used for describing a configuration scenario.

3. The method according to claim 1 or 2, characterized in that, The obtaining of the configuration generation request comprises: receiving a command line input by a user through an interface, the command line being used for describing the configuration generation request; or receiving a sentence input by the user through the interface, the sentence being used for describing the configuration generation request.

4. The method according to any one of claims 1 to 3, characterized in that, The obtaining of the configuration result matched with the information including the intention based on the configuration generation request and the language model comprises: obtaining a task list based on the information including the intention, the task list including at least one task; obtaining the configuration result based on the task list and the language model.

5. The method of claim 4, wherein, The task list includes a configuration generation task, the information including the intention includes first information used for determining a configuration model and second information used for obtaining a configuration parameter, and the obtaining of the configuration result based on the task list and the language model comprises: taking the configuration parameter obtained based on the second information and the configuration model obtained based on the first information as inputs of the language model, to obtain the configuration result, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model.

6. The method of claim 4, wherein, The task list includes a model retrieval task and a configuration generation task, the information including the intention includes first information used for determining a configuration model and second information used for obtaining a configuration parameter, and the obtaining of the configuration result based on the task list and the language model comprises: indexing a vector database with the first information to obtain the configuration model, the configuration model being expressed as a set of vectors in the vector database; taking the configuration parameter obtained based on the second information and the configuration model determined based on the first information as inputs of the language model, to obtain the configuration result, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model.

7. The method of claim 4, wherein, The task list includes a model retrieval task, a configuration generation task and a configuration verification task, the information including the intention includes first information used for determining a configuration model and second information used for obtaining a configuration parameter, and the obtaining of the configuration result based on the task list and the language model comprises: indexing a vector database with the first information to obtain the configuration model; obtaining the configuration result by taking the configuration parameter obtained based on the second information and the configuration model determined based on the first information as input of the language model, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or text obtained by adding the configuration parameter to the configuration model; verifying the configuration result based on the configuration model including constraint conditions on configuration syntax or configuration semantics.

8. The method according to any one of claims 1 to 7, characterized in that, The outputting the configuration result includes: outputting a visual interface based on the configuration generation request and the configuration result, the visual interface including a first area for displaying the configuration result and a second area for inputting the configuration generation request.

9. The method of claim 8, wherein, The visual interface further includes a third area for confirming the configuration result, and the method further includes: obtaining a configuration confirmation response based on the third area; converting the configuration result into configuration information and sending the configuration information to a network device.

10. The method of any one of claims 5-7, wherein: if the configuration model is a next-generation data modeling YANG data model, the configuration result is an expression in the form of a data structure; if the configuration model is a command line interface CLI data model, the configuration result is an expression in the form of text.

11. A network configuration apparatus characterized by comprising: includes: an obtaining unit, configured to obtain a configuration generation request, the configuration generation request being information including an intention written based on a natural language; a processing unit, configured to obtain a configuration result corresponding to the information including the intention expressed in a preset language based on the configuration generation request and a language model, the configuration result being a configuration corresponding to the information including the intention; the processing unit is further configured to output the configuration result.

12. The network configuration apparatus according to claim 11, wherein, The information including the intention is used to describe a configuration function, a configuration operation, or a configuration scenario.

13. The network configuration apparatus according to claim 11 or 12, characterized by The obtaining unit is specifically configured to: receive a command line input by a user through an interface, the command line being used to describe the configuration generation request; or receive a sentence input by a user through an interface, the sentence being used to describe the configuration generation request.

14. The network configuration apparatus according to any one of claims 11 to 13, wherein The processing unit is specifically configured to: obtain a task list based on the information including the intention, the task list including at least one task; obtain the configuration result based on the task list and the language model.

15. The network configuration apparatus according to claim 14, wherein The task list includes a configuration generation task, and the information including the intention includes first information used to determine a configuration model and second information used to obtain a configuration parameter, and the processing unit is specifically configured to: obtain the configuration result by taking the configuration parameter obtained based on the second information and the configuration model determined based on the first information as input of the language model, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or text obtained by adding the configuration parameter to the configuration model.

16. The network configuration device of claim 14, wherein, The task list includes a retrieval model task and a configuration generation task, and the information including the intention includes first information used to determine a configuration model and second information used to obtain a configuration parameter, and the processing unit is specifically configured to: obtain the configuration model based on the first information indexing the vector database, the configuration model being expressed as a set of vectors in the vector database; obtain the configuration result by taking the configuration parameter obtained based on the second information and the configuration model determined based on the first information as input of the language model, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model.

17. The network configuration device of claim 14, wherein, The task list includes a retrieval module task, a configuration generation task and a configuration verification task, the information including an intent includes first information used for determining a configuration model and second information used for obtaining a configuration parameter, and the processing unit is specifically configured to: index the vector database based on the first information to obtain the configuration model; obtain the configuration result by taking the configuration parameter obtained based on the second information and the configuration model determined based on the first information as input of the language model, the configuration result being a data structure obtained by adding the configuration parameter to the configuration model or a text obtained by adding the configuration parameter to the configuration model; verify the configuration result based on the configuration model including constraint conditions about configuration syntax or configuration semantics.

18. The network configuration apparatus according to any one of claims 11 to 17, characterized by, The output of the configuration result includes: output a visual interface based on the configuration generation request and the configuration result, the visual interface including a first area for displaying the configuration result and a second area for inputting the configuration generation request.

19. The network configuration device of claim 18, wherein, The visual interface further includes a third area for confirming the configuration result, and the processing unit is further configured to: obtain a configuration confirmation response based on the third area; convert the configuration result into configuration information and send the configuration information to a network device.

20. The network configuration apparatus according to any one of claims 15 to 17, wherein if the configuration model is a next-generation data modeling YANG data model, the configuration result is an expression in a data structure form; if the configuration model is a command line interface CLI data model, the configuration result is an expression in a text form.