Method for generating configuration file template, method for configuring target system, and device
The method generates configuration file templates with defined items and visual interfaces, addressing the challenge of configuring smart factory edge platforms by reducing learning costs and errors, ensuring efficient system configuration.
Patent Information
- Application Number
- PCT/CN2024/076805
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-02-07
- Publication Date
- 2025-08-14
AI Technical Summary
In smart factories, configuring intelligent applications on edge platforms is challenging due to the lack of standardized configuration file formats, leading to high learning costs and increased errors for inexperienced users.
A method for generating a configuration file template with defined configuration items and file formats, accompanied by a visual configuration interface, allows users to input values and generate a user configuration file, facilitating quick and error-free system configuration.
Enables efficient and user-friendly configuration of target systems by reducing learning costs and minimizing human errors through standardized templates and interfaces.
Smart Images

Figure CN2024076805_14082025_PF_FP_ABST
Abstract
Description
METHOD FOR GENERATING CONFIGURATION FILE TEMPLATE, METHOD FOR CONFIGURING TARGET SYSTEM, AND DEVICETECHNICAL FIELD
[0001] Embodiments of this application mainly relates to the field of system configuration, and in particularly, to a method for generating a configuration file template, a method for configuring a target system, and a device.BACKGROUND
[0002] With the development of science and technology, smart factories have become an important tendency in the manufacturing industry. This transformation not only changes a production method, but also brings unprecedented efficiency improvement to the enterprise. This also improves product quality and production flexibility. The smart factories use digital technologies, and apply sensors, Internet of Things, cloud computing, and other technologies to a production process to achieve real-time monitoring, data collection, data analysis, and optimization control in the production process. An edge platform is a key part of operation of the smart factory because various intelligent applications need to be installed on the edge platform. However, when various intelligent applications are configured on the edge platform, relevant specifications have not been established, and configuration file formats of different smart applications correspond to different configuration operations. As a result, learning costs are undoubtedly required for an inexperienced user, and a configuration error is prone to occur.SUMMARY
[0003] Embodiments of this application provide a method for generating a configuration file template, a method for configuring a target system, and a device. In the embodiments of this application, the configuration file template may be conveniently and quickly generated, and a user may achieve configuration on the target system.
[0004] According to a first aspect, a method for generating a configuration file template is provided, including: establishing a configuration item template, where the configuration item template includes at least one configuration item and at least one file format, and each configuration item in the at least one configuration item includes a plurality of requirements; receiving values of a plurality of requirements of the at least one configuration item inputted by a user into the configuration item template, and a file format required by a target system; generating a configuration file template according to the input by the user; and packaging the configuration file template to the target system.
[0005] According to a second aspect, a method for configuring a target system is provided, including: generating a visual configuration interface during installation and / or use of a target system based on the configuration file template obtained in the first aspect; receiving an input by a user on the visual configuration interface, to generate a user configuration file; and configuring the target system according to the user configuration file.
[0006] According to a third aspect, an electronic device is provided, including: at least one memory, configured to store computer-readable code; and at least one processor, configured to invoke the computer-readable code to perform the steps of the method according to the first aspect or the second aspect.
[0007] According to a fourth aspect, a computer-readable medium is provided, storing computer-readable instructions, the computer-readable instructions, when executed by a processor, enabling the processor to perform the steps of the method according to the first aspect or the second aspect.BRIEF DESCRIPTION OF THE DRAWINGS
[0008] The following accompanying drawings are merely intended to schematically illustrate and explain embodiments of this application, but are not intended to limit the scope of the embodiments of this application. In the drawings:
[0009] FIG. 1 is a method for generating a configuration file template according to an embodiment of this application;
[0010] FIG. 2 is a schematic diagram of a configuration item template according to an embodiment of this application;
[0011] FIG. 3 is a method for configuring a target system according to an embodiment of this application;
[0012] FIG. 4 is a schematic diagram of a visual configuration interface according to an embodiment of this application; and
[0013] FIG. 5 is a schematic diagram of an electronic device according to an embodiment of this application.
[0014] Descriptions of reference numerals: DETAILED DESCRIPTION
[0015] A subject described in this specification is discussed now with reference to exemplary implementations. It should be understood that, discussion of the implementations is merely intended to make a person skilled in the art better understand and implement the subject described in this specification, and is not intended to limit the protection scope of the claims, the applicability, or examples. Changes may be made to the functions and arrangements of the discussed elements without departing from the protection scope of the content of the embodiments of this application. Various processes or components may be omitted, replaced, or added in each example according to requirements. For example, the described method may be performed according to a sequence different from the sequence described herein, and steps may be added, omitted, or combined. In addition, features described in some examples may also be combined in other examples.
[0016] As used in this specification, the term "include" and variants thereof represent open terms, and means "include but is not limited to" . The term "based on" represents "at least partially based on" . The terms "one embodiment" and "an embodiment" represent "at least one embodiment" . The term "another embodiment" represents "at least one another embodiment" . The terms "first" , "second" , and the like may represent different objects or the same object. Other definitions may be included explicitly or implicitly in the following. Unless otherwise clearly specified, the definition of one term is consistent in the entire specification.
[0017] The following describes this embodiment of this application in detail with reference to the accompanying drawings.
[0018] FIG. 1 is a schematic diagram of a method for generating a configuration file template according to an embodiment of this application. As shown in FIG. 1, a method 100 for generating a configuration file template includes the following steps.
[0019] Step 101: Establish a configuration item template, where the configuration item template includes at least one configuration item and at least one file format, and each configuration item in the at least one configuration item includes a plurality of requirements.
[0020] The file format includes JSON, YAML, TXT, WORD, or the like.
[0021] As shown in FIG. 2, the requirement includes a name, a unique identifier, and a visual grouping manner. Optionally, the requirement further includes description information, a serialized grouping manner, a visual element, a verification manner, and a default value.
[0022] The name defines a name readable by human.
[0023] The unique identifier (ID) is used for distinguishing between different configuration items, so that a configuration file template can be in a one-to-one correspondence with configuration items of a configuration file.
[0024] The visual grouping manner defines a visual grouping manner of the configuration items in a visual configuration interface.
[0025] The description information defines detailed information of the configuration items, to help a user to perform configuration.
[0026] The serialized grouping manner defines a grouping manner of the configuration items in the configuration file.
[0027] The visual element is used for visualizing a graphical element of the configuration item.
[0028] The verification manner defines a value configured by a verification user, and prompts and updates invalid configuration.
[0029] The default value defines a value as a default value for a configurable item.
[0030] In addition, a button for switching a file format is further configured at a top position of the configuration item template in FIG. 2.
[0031] In an embodiment, a setting form of the visual element includes one of the following: an input box, a pull-down option, single selection or multiple selection. Optionally, specific content of options may be set by the user, or a corresponding default value may be preset.
[0032] Step 102: Receive values of a plurality of requirements of the at least one configuration item inputted by a user into the configuration item template, and a file format required by a target system.
[0033] The file format required by the target system is a file format that is parsable and available.
[0034] Step 103: Generate a configuration file template according to the input by the user.
[0035] In other words, specific values of the plurality of requirements in the configuration file template, for example, specific names of the configuration items are defined by the user. Optionally, default values may be preset for some requirements.
[0036] Step 104: Package the configuration file template to the target system.
[0037] In this embodiment of this application, one configuration item template is first established, so that the target system develops the user to input a specific value according to each requirement in the template, to generate the configuration file template applicable to the target system, and then the configuration file template is packaged to the target system. In this embodiment of this application, the configuration file template may be conveniently and quickly generated, to prevent the user from spending a large amount of time in studying user manuals and decomposing some predefined file formats.
[0038] FIG. 3 is a schematic diagram of a method for configuring a target system according to an embodiment of this application. As shown in FIG. 3, a method 300 for configuring a target system includes the following steps.
[0039] Step 301: Generate a visual configuration interface during installation and / or use of a target system based on the configuration file template obtained by using the method 100 for generating a configuration file template.
[0040] Specifically, the requirements in the configuration items are traversed in the configuration file template, so that requirements that need to be displayed are determined and used as a bottom-layer attribute of the visual configuration interface, thereby generating the visual configuration interface.
[0041] Optionally, all configuration items in the configuration file template are scanned. Each configuration item in all the configuration items is classified to a corresponding visual group based on a value of a visual grouping manner that is in all the configuration items and that is inputted by the user, and a title corresponding to each visual group is created. A setting form of a visual element selected by the user in a first configuration item in all the configuration items is selected. Association is established between requirements that need to be displayed and that are in all requirements in the first configuration item and the setting form of the visual element. The requirements that need to be displayed and that are in all the requirements in the first configuration item are used as a first group of requirements, and requirements other than the first group of requirements in the first configuration item are used as a bottom-layer attribute corresponding to the setting form of the visual element. The requirements that need to be displayed are added to a corresponding visual group in combination with the setting form of the visual element, to generate the visual configuration interface.
[0042] Optionally, the establishing association between requirements that need to be displayed and the setting form of the visual element may be specifically to use names of all requirements as names corresponding to the setting form of the visual element; use a description in all the requirements as a description corresponding to the setting form of the visual element; and use a default value in all the requirements as a default value corresponding to the setting form of the visual element.
[0043] Optionally, if no specific visual grouping manner is set, all the configuration items may be classified into a root visual group, to facilitate management between different configuration items.
[0044] FIG. 4 is a schematic diagram of a visual configuration interface according to an embodiment of this application. As shown in FIG. 4, the interface includes two visual groups, namely, a visual group 1 and a visual group 2. The visual group 1 includes two configuration items, namely, a configuration item 1-1 and a configuration item 1-2, so that the user may correspondingly fill the input box according to the description information. The visual group 2 includes a configuration item 2-1, so that the user may specifically perform selection according to the description information.
[0045] Step 302: Receive an input by a user on the visual configuration interface, to generate a user configuration file.
[0046] The generated user configuration file may be stored in a file format selected by the user.
[0047] Step 303: Configure the target system according to the user configuration file.
[0048] In this embodiment of this application, a corresponding visual configuration interface is generated based on the configuration file template, and a specific user configuration file is generated with reference to a simple input by the user on the interface, to configure the target system. In this embodiment of this application, the target system is configured by modifying a standardized configuration file, to help the user to match installed application software with an actual application scenario. The embodiments of this application provide the user with a universal configuration method, so that the user may focus on the configuration itself without considering the file format. This reduces a lot of learning costs and duplication of work. In addition, the embodiments of this application provide unified interfaces and specifications to facilitate reduction of human errors, thereby ensuring good operation of the target system.
[0049] An embodiment of this application further provides an electronic device 500. FIG. 5 is a schematic diagram of an electronic device 500 according to an embodiment of this application. As shown in FIG. 5, the electronic device 500 includes a processor 502 and a memory 501. The memory 501 stores an instruction, and the instruction is executed by the processor 502 to implement the method 100 and 300 as described above.
[0050] At least one processor 502 may include a microprocessor, an application-specific integrated circuit (ASIC) , a digital signal processor (DSP) , a central processing unit (CPU) , a graphics processing unit (GPU) , a state machine, and the like. Examples of the computer-readable medium include, but are not limited to, a floppy disk, a CD-ROM, a magnetic disk, a memory chip, a ROM, a RAM, an ASIC, a configured processor, an all-optical medium, all magnetic tapes, or other magnetic media, or any other medium from which a computer processor can read instructions. In addition, the computer-readable media in various other forms can send or carry instructions to computers, including routers, private or public networks, or other wired and wireless transmission devices or channels. The instructions may include code of any computer programming language, including C, C++, C language, Visual Basic, java, and JavaScript.
[0051] In addition, the embodiments of this application further provides a computer-readable medium. The computer-readable medium stores computer-readable instructions thereon, and the computer-readable instructions, when executed by a processor, cause the processor to perform the method 100 and 300 as described above. Examples of the computer-readable medium include a floppy disk, a hard disk, a magneto-optical disk, an optical disk (such as a CD-ROM, a CD-R, a CD-RW, a DVD-ROM, a DVD-RAM, a DVD-RW, or a DVD+RW) , a magnetic tape, a non-volatile storage card, and a ROM. Optionally, the computer-readable instructions may be downloaded from a server computer or a cloud by a communication network.
[0052] It should be noted that, not all steps and modules in the procedures and the diagrams of the system structures are necessary, and some steps or modules may be omitted according to an actual requirement. An execution sequence of the steps is not fixed and may be adjusted according to the requirement. The system structure described in the above embodiments may be a physical structure or a logical structure. That is, some modules may be implemented by the same physical entity, or some modules may be implemented by a plurality of physical entities, or may be jointly implemented by some components in a plurality of independent devices.
[0053] Nouns and pronouns referring to people in this patent application are not limited to specific genders.
Claims
1.A method for generating a configuration file template, comprising:establishing (101) a configuration item template, wherein the configuration item template comprises at least one configuration item and at least one file format, and each configuration item in the at least one configuration item comprises a plurality of requirements;receiving (102) values of a plurality of requirements of the at least one configuration item inputted by a user into the configuration item template, and a file format required by a target system;generating (103) a configuration file template according to the input by the user; andpackaging (104) the configuration file template to the target system.2.The method according to claim 1, wherein the requirement comprises a name, a unique identifier, and a visual grouping manner.3.The method according to claim 1 or 2, whereinthe requirement comprises a visual element; anda setting form of the visual element comprises one of the following: an input box, a pull-down option, single selection or multiple selection.4.A method for configuring a target system, comprising:generating (301) a visual configuration interface during installation and / or use of a target system based on the configuration file template obtained in claim 1;receiving (302) an input by a user on the visual configuration interface, to generate (302) a user configuration file; andconfiguring (303) the target system according to the user configuration file.5.The method according to claim 4, wherein the generating (301) a visual configuration interface based on the configuration file template obtained in claim 1 comprises:scanning all configuration items in the configuration file template;classifying each configuration item in all the configuration items to a corresponding visual group based on a value of a visual grouping manner that is in all the configuration items and that is inputted by the user, and creating a title corresponding to each visual group;determining a setting form of a visual element selected by the user in a first configuration item in all the configuration items;establishing association between requirements that need to be displayed and that are in all requirements in the first configuration item and the setting form of the visual element;using the requirements that need to be displayed and that are in all the requirements in the first configuration item as a first group of requirements, and using requirements other than the first group of requirements in the first configuration item as a bottom-layer attribute corresponding to the setting form of the visual element; andadding the requirements that need to be displayed to a corresponding visual group in combination with the setting form of the visual element, to generate the visual configuration interface.6.The method according to claim 5, wherein the establishing association between requirements that need to be displayed and that are in all requirements in the first configuration item and the setting form of the visual element comprises:using a name in all the requirements as a name corresponding to the setting form of the visual element;using a description in all the requirements as a description corresponding to the setting form of the visual element; andusing a default value in all the requirements as a default value corresponding to the setting form of the visual element.7.An electronic device, comprising:at least one memory (501) , configured to store computer-readable code; andat least one processor (502) , configured to invoke the computer-readable code to perform the steps of the method according to any one of claims 1 to 6.8.A computer-readable medium, storing computer-readable instructions, the computer-readable instructions, when executed by a processor, enabling the processor to perform the steps of the method according to any one of claims 1 to 6.
Citation Information
Patent Citations
Interface generation method and device, electronic equipment and computer readable storage medium
CN113535165A
Configuration file acquisition method and device, electronic equipment and storage medium
CN116775163A
Systems and methods for distributing configuration templates with application containers
US9983891B1