CN117389541B - Configuration system and device for generating template based on dialogue retrieval - Google Patents

Configuration system and device for generating template based on dialogue retrieval Download PDF

Info

Publication number
CN117389541B
CN117389541B CN202311704059.4A CN202311704059A CN117389541B CN 117389541 B CN117389541 B CN 117389541B CN 202311704059 A CN202311704059 A CN 202311704059A CN 117389541 B CN117389541 B CN 117389541B
Authority
CN
China
Prior art keywords
rule
template
configuration
configuration file
component
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202311704059.4A
Other languages
Chinese (zh)
Other versions
CN117389541A (en
Inventor
王涛
沈大勇
张忠山
姚锋
杜永浩
闫俊刚
王沛
陈英武
吕济民
何磊
陈宇宁
陈盈果
刘晓路
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
National University of Defense Technology
Original Assignee
National University of Defense Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by National University of Defense Technology filed Critical National University of Defense Technology
Priority to CN202311704059.4A priority Critical patent/CN117389541B/en
Publication of CN117389541A publication Critical patent/CN117389541A/en
Application granted granted Critical
Publication of CN117389541B publication Critical patent/CN117389541B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/34Graphical or visual programming
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/332Query formulation
    • G06F16/3329Natural language query formulation or dialogue systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/3331Query processing
    • G06F16/334Query execution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/335Filtering based on additional data, e.g. user or group profiles
    • G06F16/337Profile generation, learning or modification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/38Creation or generation of source code for implementing user interfaces
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Human Computer Interaction (AREA)
  • Mathematical Physics (AREA)
  • Artificial Intelligence (AREA)
  • Stored Programmes (AREA)

Abstract

The invention provides a configuration system and equipment for generating a template based on dialogue retrieval. The system comprises: rule template definition, which is used for defining the logic relationship between entities; a visual editor, a user graphically operating a design rule template; template retrieval and question answering, and a user queries a rule template library according to task requirements; the rule template analysis engine analyzes the rule template into a configuration file; configuration file generation, configuration file compiling and service online.

Description

Configuration system and device for generating template based on dialogue retrieval
Technical Field
The invention relates to the field of data processing and computer data template generation, in particular to a configuration system and device for generating a template based on dialogue retrieval.
Background
Along with the acceleration of informatization and digitalization processes, various information control systems play an increasingly important role in the fields of industry, traffic, security, military and the like. These systems require processing large amounts of data and implementing complex control strategies. In order to meet the changing business demands, the information control system needs to have high flexibility and expandability.
In particular, for the current information control system, dynamic generation and updating of rule templates are becoming key problems in optimization in the industry, but existing rule management methods, such as "a method and system for automatically generating codes through classification configuration" (CN 102722372B), a method and system for generating configuration item setting interfaces (CN 102122245A), and the like, still require professionals to write complex configuration files or programming codes, which is difficult for users with non-technical backgrounds.
With the rapid development of artificial intelligence technology in recent years, a method based on dialogue retrieval has shown great potential in many scenes. For example, by generating a large model of the language, a user may interact with the system using natural language to accomplish various tasks. However, in the field of rule template generation and configuration, only a small portion of the visualization rule engines support the drag-type rule configuration, but these engines still face certain challenges in terms of rule template retrieval and multiplexing.
At least the following technical problems exist in the prior art:
the rule writing difficulty is high: existing rule configuration methods typically rely on programming languages or specialized configuration files and are not user friendly to non-technical contexts. This makes the creation and updating of rule templates cumbersome and inefficient.
Insufficient flexibility and extensibility: existing methods have limited flexibility and extensibility due to reliance on fixed profile formats or programming languages. This makes the existing methods unable to quickly adapt and meet the needs in the face of diverse and dynamic needs.
Rule template retrieval and multiplexing are difficult: although some visualization rule engines provide a pull-type rule configuration approach, these engines still face challenges in terms of the retrieval and multiplexing of rule templates. It is difficult for users to quickly find existing rule templates that match their needs, thereby reducing the efficiency of rule configuration.
Lack of natural language interaction capabilities: the existing rule configuration method generally lacks the capability of natural language interaction with a user, rules defined by different rule engines are huge in difference, the user cannot intuitively understand the corresponding relation between actual requirements and rules, and the rule configuration process is not intuitive and friendly enough.
Disclosure of Invention
At least partially in view of the above-mentioned shortcomings in the prior art, the present invention provides a configuration system and device for generating templates based on a dialog, so as to improve the efficiency and accuracy of template configuration, and make the configuration process more intuitive and friendly. Specifically, the invention discloses the following technical scheme:
In one aspect, the present invention provides a system for configuring a template based on dialogue retrieval, the system comprising:
the retrieval query rule template module is used for obtaining a rule template by a user for the first time, and is based on a language model of an attention mechanism;
the rule template definition module is used for setting a rule template and storing the rule template; the rule template comprises configuration parameters, variables and control structure data;
the visual editor is used for creating or modifying the rule template by a user and is realized based on a Web end;
the dynamic configuration management module is used for dynamically loading and updating the rule templates and the configuration files; the configuration file at least comprises configuration parameters;
the template searching and generating module is used for realizing the searching of the rule templates based on the pre-training language model and combining the fine tuning method, and obtaining the generating rules based on the searched rule templates;
and the rule template analysis engine module is used for receiving the generation rule and mapping the generation rule to the visual rule template.
Preferably, in the search query rule template module, the attention mechanism is set as follows:
the method comprises the steps of mapping the characteristic X of each input lexical unit to three vector spaces Q, K, V through a weight matrix, wherein Q represents a query vector space, K represents a key space and V represents a value space;
Calculating attention weight: softmax (q·kt/sqrt (d_k)), where d_k represents the dimension of the K vector, sqrt () represents the square root, and softmax represents the normalization function;
multiplying the attention weight by V to obtain a weighted value;
and taking the sum of the weighted values as output.
Preferably, the search query rule template module performs fine tuning on the language model:
firstly, the language model learns and builds a mapping relation between keyword texts and rule component templates;
secondly, the model migrates the mapping relationship between the user's demand description and the rule templates.
Preferably, the visual editor data execution flow is:
initializing an editor and receiving user input;
updating the editing area in real time based on user input;
and synchronizing the user operation to the configuration file of the rule template to complete the data binding.
Preferably, the visual editor further supports exporting rule templates as or importing rule templates from configuration files; and supporting revocation and preview of the user and publishing the rule templates to the specified target system.
Preferably, the dynamic configuration management module establishes an API interface between the visual editor and the back end, and the rule templates and the configuration files are stored in the back end; the visual editor sends a loading or updating request to the back end through an API interface, and after the back end processes the request, the loading or updating rule template and/or configuration file data are sent through the API interface; the back end refers to other modules except a visual editor in the system;
The method comprises the steps that persistent communication is established between the visual editor and the back end, and when the back end detects that a rule template and/or a configuration file is updated, update data is actively pushed to the visual editor through an API interface;
when the rule templates and/or the configuration files change, monitoring the change, and updating interface elements associated with the rule templates and/or the configuration files.
Preferably, the listening is implemented in an event-driven manner
Preferably, the rule template definition module further comprises: a business model unit, a rule assembly unit and an expression editor unit;
the business model unit is used for standardizing various definitions of the rule template, wherein the various definitions comprise entities, attributes, relationships, data types and using conditions;
the rule assembly unit is used for forming a reusable rule assembly, and the rule assembly comprises conditions, operations, triggers, connectors and configurable super parameters; the rule components form a rule component library;
the expression editor unit is used for customizing mathematical, logical or comparison expression type rule components.
Preferably, in the rule component unit, the single component is constructed in the following manner: defining a basic rule component class, wherein the basic rule component class comprises passing attributes and methods; subclasses are created for different types of rule components, respectively, and basic rule component classes are integrated.
Preferably, the template retrieval and generation module selects the pre-trained language model based on computational power of the deployment facility.
Preferably, the fine tuning method of the template searching and generating module comprises the following steps:
rule fine tuning, establishing a training method for transition from component level fine tuning to template level fine tuning, and forming keyword-rule template generating capacity;
and (5) searching and trimming, and forming the search text-rule generating capability through a mixed prompt trimming mode.
Preferably, after fine tuning, the search text-rule generating capability is established, and then the configuration file of the rule template is mapped to the rule template through the rule template parsing engine module.
Preferably, the rule fine tuning is performed in the following manner:
step 101, extracting a template component configuration file-keyword pair, which comprises the following steps: selecting a component in a rule template library, wherein the component covers all keywords and operations; extracting corresponding configuration codes of the selected components from a rule template library, wherein the configuration codes comprise types, parameter settings and logic relations of the components; forming selected ones of the components into a component micro-sample library;
step 102, training the fine adjustment of a template component configuration file-key words;
Step 103, extracting a template configuration file-keyword pair, including: acquiring a typical template and a template configuration code, labeling keywords associated with the typical template, and performing keyword-template configuration file fine tuning training;
the number of template component configuration file-keyword fine tuning training samples N1 and the number of keyword-template configuration file fine tuning training samples N2 satisfy the following:
N2 ≈ 0.1N1。
preferably, the fine tuning mode of the mixing prompt is as follows:
step 201, a training set of a search text, a keyword and an instruction mixed sample and the same template configuration file is established, wherein the search text, the keyword and the instruction mixed sample are taken as input, and the template configuration file is taken as output;
step 202, the training mode adopts a mode of randomly extracting the search text, the key words and the instructions until all the extraction is completed;
in training, the mixed weight updating mode of the search text, the key words and the instructions is as follows: setting the retrieval text weight to 1, and setting the keyword and instruction weight to: 1-current iteration number/total iteration number.
Preferably, the rule template analysis engine module comprises a lexical analysis unit, a grammar analysis unit and a semantic analysis unit;
the lexical analysis unit is used for analyzing the configuration file of the generation rule into a series of lexical units;
The grammar analysis unit is used for analyzing the lexical unit sequence into an abstract grammar tree and traversing the abstract grammar tree to form an executable configuration file;
the semantic parsing unit is used for mapping the executable configuration file to the visualization component instance, parsing the parameters and the attributes of the visualization component instance and executing data type check.
Preferably, the rule template parsing engine module performs mapping in the following manner:
step 301, analyzing a configuration file of a generation rule, and creating a visual component instance based on the configuration file;
step 302, setting the component relation among the visualized component examples based on the component relation data in the configuration file;
step 303, integrating the visual component instance and the component relation among the visual component instances into a visual rule template, and outputting the visual rule template.
Preferably, the semantic parsing unit performs a data type check, checking, for each visualization component instance, whether its parameters, attributes are consistent with a predefined type.
Preferably, the rule template parsing engine module further performs optimization of rules of the generated visualized rule template:
step 401, traversing the abstract syntax tree, identifying redundant components or identical components, and marking the positions of the redundant components and the identical components; identical components refer to conditional components having identical expressions and parameters; redundant components refer to nodes that do not affect the execution of rule logic;
Step 402, checking whether the redundant component has an actual influence on rule logic, and if not, deleting the redundant component from the abstract syntax tree;
step 403, traversing the marked identical components, deleting one of the identical components for each pair of identical components, and taking the reserved identical components as the condition components after combination;
traversing the input ports of the deleted identical components, and connecting all the components connected with the input ports to the corresponding input ports of the combined conditional components; traversing the output ports of the deleted identical components, and connecting all the components connected with the output ports to the corresponding output ports of the combined conditional components;
and 404, regenerating a visualization rule template for the optimized abstract syntax tree.
In addition, the invention also provides a configuration device for generating the template based on dialogue retrieval, which comprises a server and front-end user interaction equipment; the server is configured to be data interactive with the front-end user interaction device and is loaded with a configuration system that generates templates based on dialogue retrieval as described above.
Compared with the prior art, the dialogue mode is used for generating the template directly according to the requirement of the user for adjusting the system rule, so that the necessity of the user for learning a script type configuration language or editing a complex visual template is basically eliminated. Meanwhile, the scheme utilizes a template learning mechanism, and after each template update, the mapping relation between the user demand text and the template is learned, so that the system can continuously adapt to new demands of users, and the situation that the traditional static example template is difficult to adapt to demands of different downstream users and system operation stages is avoided. The scheme can be widely applied to information control systems in the fields of industry, traffic, security, military and the like, the technical threshold of users is reduced, and the flexibility and usability of the system are improved. The concrete steps are as follows:
1. Personalized customization: the configuration method based on the dialogue generation template can fully know the requirements and preferences of the user, and generates the template which has stronger pertinence and meets the specific requirements of the user. This will help to improve the user experience and satisfaction.
2. Real-time feedback: through real-time interaction with the user, the system can timely acquire comments and suggestions of the user on the template so as to adjust in the subsequent generation process. This will help to reduce the iteration cycle and improve the development efficiency of the system.
3. Automatic optimization: by using a template learning mechanism, the system can automatically optimize the generated template, reduce redundancy and improve execution efficiency. This will help reduce the running cost of the system and improve performance.
4. Easy maintenance and upgrade: the configuration method based on the dialogue generating template can separate the template from the bottom layer, and is convenient for maintenance and upgrading. When the system needs to be updated, only the module needs to be adjusted, and the bottom layer implementation does not need to be modified.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, it being obvious that the drawings in the following description are only some embodiments of the invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic flow chart of an embodiment of the present invention;
FIG. 2 is a logic flow diagram of a stencil parsing engine in accordance with an embodiment of the present invention;
fig. 3 is a schematic diagram of a system structure according to an embodiment of the invention.
Detailed Description
Embodiments of the present invention will be described in detail below with reference to the accompanying drawings. It should be understood that the described embodiments are only some, but not all, of the embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
It will be appreciated by those of skill in the art that the following specific embodiments or implementations are provided as a series of preferred arrangements of the present invention for further explanation of the specific disclosure, and that the arrangements may be used in conjunction or association with each other, unless it is specifically contemplated that some or some of the specific embodiments or implementations may not be associated or used with other embodiments or implementations. Meanwhile, the following specific examples or embodiments are merely provided as an optimized arrangement, and are not to be construed as limiting the scope of the present invention.
In a specific embodiment, with reference to fig. 1 and 3, the scheme of the invention designs a dialogue type search query rule template method, and combines rule template definition, a visual editor, dynamic configuration management and other modes to realize decoupling of requirements and rules and decoupling of rules and codes, thereby greatly improving the problems in the prior art.
Conversational search query rule templates: and the question-answering system technology of keyword matching inquiry and fine tuning based on a large-scale generation type pre-training language model is integrated, so that a primary user can acquire a relevant rule template according to task requirements to conduct secondary design.
In this embodiment, the large-scale generation type pre-training language model is preferably designed as follows: the language model taking the attention mechanism as a core, such as BERT, T5, GPT3 and the like, and the implementation steps of the attention mechanism mainly comprise:
1. computing Query (Q), key (K), and Value (V): each Token (i.e., lexical unit) of the input sequence is mapped to three different vector spaces, respectively, to obtain Query, key and Value. This mapping is achieved by a matrix multiplication operation using different weight matrices w_q, w_k, and w_v, respectively.
Q = X * W_Q
K = X * W_K
V = X * W_V
Where X is the input sequence and w_ Q, W _k and w_v are weight matrices, respectively, where Q represents the query vector space, K represents the key space, and V represents the value space.
2. Calculating attention weight: the dot product between Query and Key is calculated and then divided by the scaling factor (square root of the dimension of the Key vector), and finally the result is normalized to between 0-1 using the softmax function.
Attention weight = softmax (Q x K T/sqrt (d_k))
Where d_k is the dimension of the Key vector.
3. Calculating a weighted value: the attention weight is multiplied by Value to obtain a weighted Value.
Weight = attention weight V
4. And (3) outputting: the weighted values are added to obtain an output sequence.
Output =∑{[softmax((X * W_Q) * (X * W_K)^T / sqrt(d_k))] * (X * W_V)}
The main fine tuning steps comprise: the first stage, the model learns the mapping relation between the text of the weak abstract keyword and the templates of the rule components, the abstract degree of the input text is low, the information content is high, the number of the rule components is more than that of the rule templates, and the model is easier to quickly form basic rule understanding capability; and in the second stage, the model transfers the rule generating capability to the complete description requirement and rule template of the user, and particularly, the generating capability from the requirement text to the final template is gradually formed by using a smaller learning rate in the first stage and the requirement text, instruction and keyword mixed training input mode.
Rule template definition module: in this embodiment, a visual graphic element is adopted at the upper layer of the system, so as to construct a rule representation method such as a user-friendly business model, a rule component, an expression editor and the like, and a rule template is stored at the bottom layer by adopting a universal data format (JSON, XML and YAML) so as to facilitate subsequent analysis and processing. The rule template contains configurable parameters, variables and control structures, and meets the requirements of different scenes.
Visual editor: in this embodiment, a visual editor based on a Web terminal is designed, which allows a user to intuitively create and modify rule templates through interaction modes such as drag-and-drop and attribute panels. The editor supports functions of undo/redo, import/export, preview, etc., and improves user experience. The visual editor based on the Web terminal comprises the following components:
1. menu bar: including common menu items such as files, edits, views, help, etc., provide basic function operations, and additionally provide a search box for user demand input.
2. Tool bar: shortcuts for common operations are provided, such as new creation, opening, saving, undoing, redoing, etc.
3. Rule component library: contains a series of predefined rule components, such as conditions, actions, loops, etc., for the user to make secondary modification edits to the generated template, which may be dragged or otherwise added to the edit area.
4. Editing area: visual structure for exposing and editing rule templates. The user can perform operations such as adding, deleting, modifying components in this area.
5. Attribute panel: after right clicking on the selected item in the editing area, the user exposes and edits properties of the selected component, such as conditional expressions, action parameters, and the like.
6. An information panel: for exposing state information of the editor, such as operation prompts, error information, etc.
The working process mainly comprises the following steps:
1. initializing an editor: loading a component library, initializing a template generation model, setting the size of an editing area, creating a menu bar, a tool bar and the like.
2. User operation: the user inputs the requirements, generates a template, and can secondarily modify the template, and add, delete and modify components in the template in the editing area through operations such as dragging, clicking and the like.
3. Updating in real time: the editor updates the visual structure of the editing area in real time according to the user operation, and updates the contents of the attribute panel and the information panel.
4. Data binding: the editor synchronizes the user operation to the configuration file of the internal rule template to ensure the consistency of the data.
5. Data import and export: the editor supports exporting the visualization rule templates as a configuration file or importing the visualization rule templates from a configuration file.
6. Undoing and redoing: the editor implements an operation history record supporting user undo and redo operations.
7. Previewing and publishing: the editor allows a user to preview the running effects of rule templates and supports publishing templates to specified target systems.
Dynamic configuration management: the invention realizes integration with the existing information control system, and realizes dynamic loading and updating of rule templates and configuration files in the modes of API, file monitor and the like. This ensures that the information control system performs the corresponding operation at run-time based on the latest configuration file. The specific implementation technology comprises the following steps:
1. front-rear end separation: a clear API interface is established between a front end (a visual editor based on Web) and a back end (a rule template analysis engine module and each service execution module), the rule template and the configuration file are stored in a file system or a database of the back end (the specific storage position can be adjusted based on the system design), and the front end requests data through the API; the front end may be understood as a user end, which is well known to those skilled in the art, and in this embodiment, the front end may be, for example, a visual editor (e.g., a visual editor implemented based on Web, etc.) used by the user, and the back end may be understood as a back end functional module for performing each core data processing in this solution, which is also well known to those skilled in the art, and in this embodiment, the back end may refer to a rule template parsing engine module and each service execution module (except for the visual editor). When the rule templates and the configuration files need to be loaded or updated, the front end can send corresponding requests to the back end, and the back end returns relevant rule template data and/or configuration file data after processing. Therefore, the separation of responsibilities at the front end and the rear end can be ensured, and the maintenance and the expansion are convenient.
2. Real-time communication: a persistent connection may be established between the front-end and the back-end using WebSocket or other real-time communication techniques. When the back end detects that the rule template or the configuration file is updated, the data can be actively pushed to the front end. After the front end receives the data, the interface can be updated in real time, and the user experience is improved.
3. Data binding and listening: at the front end, rule templates and configuration files may be associated with interface elements using a data binding framework (e.g., vue. Js, react, etc.). When the data changes, the interface element is automatically updated. By monitoring the data changes, dynamic loading and updating of rule templates and configuration files can be achieved.
4. Version control: the rule templates and configuration files are stored in a version control system (such as Git, SVN, etc.), and when an update is required, synchronization can be performed by the version control system. Thus, consistency of the rule templates and the configuration files can be ensured, and rollback and historical change tracking are facilitated.
5. Caching and storing: to improve performance, cache and storage techniques (e.g., browser cache, redis, etc.) are used at the front-end and back-end to store rule templates and profile-related data. When the data is required to be loaded or updated, the data can be preferentially acquired from the cache and the storage, for example, the cache can be arranged at the front end, the storage can be arranged at the rear end, the updated data can be stored in the rear-end storage when the data is updated, the updated data is prestored in the cache at the front end, and when the data is required to be updated, the updated data is preferentially acquired from the cache at the front end, so that the network delay and the server pressure are reduced.
6. Event-driven: at the front end, event driven approaches may be used to monitor the rule templates and configuration files for loading and updating events. When triggered by an event, corresponding processing logic, such as requesting data, updating an interface, etc., may be executed. This may improve the readability and maintainability of the code.
The dialogue type retrieval rule template technology can be widely applied to information control systems in the fields of industry, traffic, security, military and the like, the technical threshold of users is reduced, and the flexibility and usability of the system are improved.
The present solution is further developed and illustrated in conjunction with fig. 1.
First aspect: the scheme includes a rule template definition module that further includes the following:
business model unit: the business model is an abstract representation of the business module in the visual template, and in order to ensure that the template rules form correct and reliable data processing flows, the rule template definition needs to execute the definition of the business model, including entities, attributes, relationships, data types, use conditions and the like, so that the rule template analysis can be correctly realized. In a preferred embodiment, the business model tool consists of:
1. entity manager: for creating, editing and deleting entities. An entity is a core concept in a business model that represents an object in a business system, such as an order, customer, etc.
2. Attribute manager: attributes for creating, editing, and deleting entities. Attributes represent characteristics of the entity, such as the order amount data involved, the customer's name, etc.
3. Data type manager: data types for defining attributes. The data type may be a simple type (e.g., string, number, etc.) or a complex type (e.g., list, dictionary, etc.).
4. Relationship manager: for creating, editing, and deleting relationships between entities. Relationships represent connections between entities, such as associations of orders with customers, and the like.
5. Using a condition manager: the service rule setting method is used for setting the service rule using conditions, such as judging the transaction level of the service rule according to the order amount, and the configurable actual transaction amount value.
The processing flow comprises the following steps:
1. creation entity: the user creates a new entity in the visual editor, and the tool adds the entity information to the entity manager and generates a unique identifier for the entity.
2. Defining attributes: the tool adds the attribute to the entity, adds the attribute information to the attribute manager, and generates a unique identifier for the attribute. Meanwhile, the user needs to select the data type of the attribute, and the tool can generate corresponding interface elements such as an input box, a drop-down list and the like according to the data type.
3. Creating a relation: the user defines relationships between entities, such as one-to-one, one-to-many, etc. The tool adds the relationship information to the relationship manager and generates a unique identifier for the relationship.
4. Setting use conditions: the usage conditions are set for the business rules, such as comparisons based on attribute values, logical operations, and the like. The tool adds the condition information to the usage condition manager and generates a corresponding condition expression.
5. Automatically generating an entity and an attribute: the tools may automatically create entities and attributes from existing data sources (e.g., database tables, API responses, etc.). This requires parsing structural information of the data source by writing an adapter and then mapping the parsing result to entities and attributes of the business model.
Rule component unit: the rule template contains a series of reusable rule components: conditions, operations, triggers, connectors, etc. By dragging and combining these components to define rules, the rule set-up contains configurable hyper-parameters such as thresholds, time intervals and weights, etc., and the user can adjust the behavior of the rules according to actual needs. Single rule component construction: and constructing by adopting an object-oriented design method. First, a basic rule component class is defined that contains some generic properties and methods. Then, for different types of rule components (e.g., conditions, operations, triggers, connectors, etc.), sub-classes are created and inherited, respectively, from the base rule component classes.
And (3) constructing a rule component library:
1. component registry (Component Registry): type information and instantiation methods for maintaining rule components. When a user needs to create a new component, the corresponding type information and instantiation method can be looked up from the registry.
2. Component store (Component Storage): for storing instances of rule components. This may be a memory data structure (e.g., dictionary or list, etc.) or a persistent store (e.g., database or file system, etc.).
3. Component factory (Component Factory): for creating rule component instances based on the user's needs and configuration parameters. The factory may obtain component type information and instantiation methods from the component registry and then create component instances from the configuration parameters and add to the component store.
The rule component invokes:
1. the user selects a rule component type in the visual editor and configures the relevant parameters.
2. The editor sends the component types and configuration parameters to the backend service.
3. The back-end service creates a component instance through the component factory based on the component type and configuration parameters.
4. The component factory obtains component type information and instantiation methods from the component registry and then creates component instantiations based on the configuration parameters.
5. Component instances are added to the component store and combined with other components to form a complete rule execution flow.
6. When the trigger condition is satisfied, the trigger class listens for the corresponding event and starts executing the rule.
7. The trigger transmits the input data to the condition class for judgment according to the definition of the connector class.
8. The condition class calculates a condition result based on the input data and the condition expression.
9. If the condition results in true, the trigger passes the data to the operation class.
10. The operation class performs corresponding actions, such as updating data, sending notifications, etc., according to the configuration parameters.
11. After the operation is completed, the trigger continues to monitor the subsequent events and waits for the next trigger.
Expression editor unit: for portions other than common rules, the user may customize the rule components using an expression editor to define complex mathematical, logical, and comparative expression type rule constructs. The expression editor creates expressions using a friendly graphical interface, which can be zero-coded.
Specific structure and design of the expression editor:
1. user interface: in the visual editor, clicking on the expression editor additionally provides a graphical drag interface, which allows the user to easily create and modify expressions. The interface includes a component library, canvas, and property panel, among other parts.
2. Component library: the component library contains a variety of basic components that can be used for expressions, such as constants, variables, operators, functions, and the like. The user may drag the components onto the canvas as desired to compose an expression.
3. Canvas: the canvas is the work area of the user's combined expression. On the canvas, the user may connect the components and adjust their order and hierarchical relationships to form the desired expression.
4. Attribute panel: the property panel is used to display and edit properties of selected components, such as values of constants, names of variables, types of operators, and the like.
The operation flow is as follows:
1. the user selects a desired component in the component library and drags onto the canvas.
2. The user connects the components on the canvas to form the expression. The connection may represent a data flow or a function call relationship.
3. After the user selects the component, the properties of the component are modified in the properties panel.
4. When the expression is complete, the editor serializes the expression into an executable code or data structure.
5. The rules engine performs the corresponding calculations based on the serialized expressions at run-time.
Core algorithm:
1. expression construction: an expression tree is formed on the canvas by the drag and connect component.
2. Expression optimization: the expression tree is optimized, such as merging adjacent constants, eliminating redundant computations, etc.
3. The expression serialization: the expression tree is serialized into an executable code or data structure, such as an Abstract Syntax Tree (AST).
4. Expression evaluation: the results are calculated at run-time from the serialized expressions. The evaluation process may employ recursive traversal, stack evaluation, and the like.
In a second aspect, the present solution further includes a conversational template retrieval and generation module that employs a multi-level fine tuning approach to fast learning on a small-scale rule template for a pre-trained language model, comprising:
1. selecting a pre-trained language model
A generative pre-trained deep learning language model (BERT, T5, LLaMa, etc.) is selected based on deployment facilities and computational effort, and the model is pre-trained on a large amount of text data to capture grammar and semantic information in natural language.
The model is selected based on hardware computing power, and can be specifically divided into:
tens to hundreds of GPUs: small models (e.g., BERT-Base, GPT-2) have 1 to 3 hundred million parameters and training time is several weeks.
Hundreds to thousands of GPUs: medium models (e.g., BERT-Larget, GPT-3 medium scale submodels) have hundreds of millions to billions of parameters, training time months.
Thousands of GPUs: large models (e.g., GPT-3, megatron-LM), hundreds of billions of parameters, training time from months to one year.
Tens of thousands of GPUs: ultra-large models (e.g., GPT-4,Switch Transformer), trillion parameters. Training time is more than one year.
2. Rule fine tuning
Aiming at the problem that the large-scale pre-training language model parameter is not matched with the small sample size of the rule template library, a training method for transitioning from component-level fine tuning to template-level fine tuning is designed to enable the model to form primary keyword-rule template generation capability:
(1) The template component configuration file-keyword pairs are extracted, typical template components and configuration codes thereof are selected, related rule keywords are marked, and a component-level fine tuning sample library is formed, wherein the sample library is marked as N1 in order. In this section, keywords are used as inputs and tags are used as template component configuration files. The method comprises the following specific steps of;
a. and (3) selecting a component: in the rule template library, representative components are selected according to actual service requirements and scenes, and all keywords and operations are required to be covered by the components. The selection of the components can be comprehensively considered based on factors such as frequency, service value, coverage and the like.
b. Selecting a corresponding configuration code: for the selected component, its corresponding configuration code is extracted from the template library. The configuration code should contain information such as the type of component, parameter settings, and logical relationships so that the model can generate the corresponding component configuration from the keywords.
c. Forming a micro sample library: both the component-level and template-level micro-sample libraries are stored using JSON, and at the backend servers using file systems or databases.
(2) Keyword-component profile trimming training: training a small sample with a learning rate of 10% of the pre-training model, wherein the learning rate is marked as L1, so that the model forms the matching generation capability between keywords and components.
Preferably, the training parameters are set as follows:
sample number: n1 (N1 is much smaller than the pre-training sample size)
Learning rate: l1 (e.g., l1=0.1. Pre-training learning rate)
(3) Extracting a template configuration file-keyword pair, selecting a typical template and a template configuration code thereof, and labeling related rule keywords to form a template-level fine-tuning sample library, wherein the sample library is marked as N2, N2 to 0.1N1. In this section, the input is a keyword and the tag is a template profile. Template-level fine-tuning sample library:
a. and (3) data storage: the micro sample library may use file storage or database storage. The file store may choose to use a local file system or cloud storage service to save each sample in the form of a file. Database storage each sample may be kept in records using a relational database (e.g., mySQL, postgreSQL, etc.) or a non-relational database (e.g., mongoDB, cassandra, etc.).
b. Data format: JSON format is used.
c. In distinction to the component-level sample library: from the component level up to the template level, a single input sample type in the sample library changes from keyword only to retrieve text or keywords or instructions, and a single tag sample expands into the entire template profile.
(4) Keyword-template profile trimming training: the learning rate is recorded as L2, and L2 to 0.1L1, and further fine tuning training is carried out to enable the model to form the matching generation capacity between keywords and templates.
Preferably, the training parameters are set as follows: sample order of magnitude: n2 (N2≡ 0.1N1);
learning rate: l2 (e.g., l2≡ 0.1L1).
3. Retrieval fine tuning
After the pre-training language model forms basic keyword-rule template generating capability, the generating capability from the search text to the rule needs to be further improved, and a mixed prompt fine-tuning training method is designed, which specifically comprises the following steps:
(1) And constructing a training set of the retrieval text, the keywords, the instruction mixed sample and the same rule label. In the step, the input is a mixed sample of a search text, a keyword and an instruction, the same template configuration file is used as a rule tag, the input text file and the tag are respectively provided with an input and tag folder, the files of the same group of training samples are named by the same number, the text file is stored by txt, and the rule tag is kept in a JSON format.
(2) And executing a training mode from random extraction of the three to complete extraction of the search text. The training parameters were set as follows:
sample order of magnitude: n3, N3 should be significantly larger than the design component level and template level trim links (e.g., N3≡10×N1);
learning rate: l3 (e.g., l3≡l2);
sample mix weights: setting training weights of a search text, a keyword and an instruction, wherein the specific setting mode is that in a loss function, sample weight coefficients of the three are newly added, the weight of the search text is set to be 1, and the weights of the instruction and the keyword are set to be 1-the current iteration times/the total iteration times.
Training process:
2/3 of all data is divided into training sets and 1/3 into validation sets to monitor model performance during training.
And fine tuning the pre-training language model by using a training set, inputting a mixed sample of search text, keywords and instructions, and taking a label as a template configuration file.
In each training batch, sample training is randomly drawn from the training set.
And evaluating the performance of the model, and recording performance indexes (such as accuracy, F1 score and the like) output by each verification in training.
When a given number of training rounds is reached or other stopping conditions (such as performance convergence) are met, training is stopped and the model is saved.
4. And (3) generating a result:
after the fine tuning training is performed, the model gradually forms the generation capability from the retrieval text of the requirement level to the final rule, and the rule template analysis engine is combined to realize the further mapping from the rule configuration file to the visualized rule template.
In this section, the generated rules are output to a rule template parsing engine module, which maps to a visualized rule template. The mapping is the inverse process of template analysis, and the final template is returned to the user so that the user can edit for the second time or directly use the template. Meanwhile, a feedback mechanism can be further preferably provided, so that a user evaluates the search result to continuously optimize the search method.
Mapping flow:
1. configuration file: analyzing the generated rule configuration file, extracting information such as component types, attributes, parameters and the like, and analyzing the information into objects by using a JSON analysis library.
2. Build component instance: and creating a corresponding visualized component instance according to the analyzed component type, attribute and parameter information. For example, if there is a conditional component in the configuration file, a conditional component may be created on the visual interface and its properties and parameters set.
3. Setting component relation: resolving the component relation (such as a connector or a trigger) in the configuration file, and setting the corresponding component relation on the visual interface. For example, if there is one connector in the configuration file that connects two conditional components, the two conditional components may be connected on the visual interface.
4. Generating a visual template: and integrating the created component instance and the set component relationship into a visual rule template for secondary modification or direct use by a user.
User evaluation optimization mechanism: errors in rule components are secondarily trained using the correct samples and poor correlation of templates to user requirements can be achieved by optimizing training input text and adding related template fine tuning training.
In a third aspect, the present solution further includes a visual editor, specifically including the following parts:
graphical interface: the visual editor uses a graphical interface to facilitate easy creation and modification of rules by a user. In particular, a series of predefined graphical elements are used that represent the business model, rule components, and expression editors of the rule template definition portion. Meanwhile, the graphical interface supports clicking, dragging, placing and shortcut key operation, and the menu panel is utilized to call the rule template engine to realize the functions of previewing, verifying, canceling, redoing, importing and exporting rule templates and the like.
Help support documents: the editor provides help support documents, including various functions and problem feedback of the visual editor.
In a fourth aspect, the present solution further includes a rule template parsing engine module, as shown in fig. 2, specifically including the following parts:
lexical analyzer: the input of the lexical analyzer can be a configuration file of a template rule or an input rule template, and the lexical analyzer is responsible for analyzing the input rule template text or rule template configuration file into a series of lexical units (tokens). Using Finite Automata (finish automation). The lexical analyzer includes an input buffer, a state transition table, an output buffer, and an action table. The input buffer is used for storing template texts to be analyzed, the state conversion table is used for representing the state conversion relation of the finite automaton, the output buffer is used for storing lexical units generated by analysis, and the action table is used for defining actions executed when the lexical units are generated.
Syntax analysis: and analyzing all the visualized graphic elements into pairs of dependent variables and logical names by using a lexical analyzer, analyzing the grammar structure of the rule template, including components such as conditions, operations, triggers, custom rules and the like, and verifying whether grammar errors exist in the overall rule. The analysis process comprises the following steps: parsing the template text into lexical unit sequences, parsing the lexical unit sequences into Abstract Syntax Trees (AST) using top-down or bottom-up syntax analysis methods (such as LL or LR analysis), traversing the AST, parsing and processing information such as entity parameters, attributes, component relationships, and the like, generating Intermediate Representations (IR), and converting the IR into executable configuration files. The verification method comprises the following steps: including static authentication and dynamic authentication. Static verification mainly checks the grammar and semantic correctness of rule templates, such as data type checking, variable use checking, etc. Dynamic verification verifies that the rules meet expectations at the actual run time by executing the compiled executable configuration file. Dynamic verification may be performed using unit testing, integrated testing, and the like.
Semantic parsing: the conditions, components, connectors, etc. in the templates are mapped to the corresponding entities. And executing data type checking, analyzing entity parameters and attributes in the template, replacing rules by using an entity internal representation and conversion method, converting rule contents into executable objects, and finally generating an executable configuration file. The semantic analysis specifically comprises the following steps:
1. mapping elements in the template to entities: elements such as conditions, components, connectors and the like in the traversing templates are mapped to corresponding entity objects according to the types and the attributes of the elements. This may be accomplished by looking up a predefined entity class mapping table, matching the types and attributes of the template elements with the entity class.
2. Data type checking: for each entity object (i.e., visualization component instance), it is necessary to check whether the data type of its parameters and attributes is consistent with the expected type. By comparing the parameters and attributes of the entity objects with predefined types one by one, the consistency and correctness of the data types is checked, in particular using a type derivation algorithm, such as the Hindley-Milner type derivation algorithm.
3. Resolving entity parameters and attributes: and analyzing the entity parameters and attributes according to the entity internal representation and conversion method. This can be achieved by defining parsing methods in the entity class that will read the entity parameters and attributes and convert them into an internal representation.
4. Rule replacement: and applying the analyzed entity parameters and attributes to the rule content to complete rule replacement. This may be accomplished by traversing the parts of the rule content that relate to the parameters and attributes of the entity and replacing those parts with an internal representation of the entity.
5. Generating an executable configuration file: the rule content is converted into executable objects and executable configuration files are generated, thereby generating a visualized rule template. This may be achieved by encoding the rule content into a specific format (e.g., JSON, XML, etc.), which may be parsed and executed by the rule engine.
Rule validation and error handling: and calling the executable configuration file to perform compiling execution test, and returning test results and possible error information to the visual editor. Compiling and executing a testing step:
1. compiling the generated executable configuration file into an executable program or script.
2. Input data and expected output data are prepared for the test case.
3. An executable program or script is executed and the actual output is compared to the expected output.
4. If the output does not meet the expectations, recording error information and returning to the visual editor; otherwise, the test is considered to be successful.
Rule optimization: and executing rule optimization on the configuration file which is successfully tested and the compiled executable file, wherein the rule optimization comprises the steps of deleting redundant components, merging the same conditions and the like, so that the rule execution efficiency is improved. The rule optimizing method comprises the following steps:
1. the AST is traversed to find the component nodes where redundancy may exist. Redundant components typically appear as nodes that do not affect the execution of rule logic, such as conditional components that do not have any output ports connected, useless data conversion, etc. Identifying the same component: the AST is traversed to find conditional components with the same expressions and parameters. For each pair of identical conditions, they are marked as combinable and their position in the AST is recorded.
2. For redundant components, it is checked whether it has an actual impact on the rule logic (non-executing nodes, nodes that adjust the output without affecting the result, etc.). If not, it is deleted from the AST.
3. For the same components: all condition components marked as combinable are traversed, one of the condition components is deleted and the other condition component is reserved as a combined condition for each pair. At the same time, the location of the reserved conditional component in the AST is recorded. For the merged conditional component, the logical relationship connected with it needs to be readjusted: traversing the input ports of the deleted conditional components, and connecting all the components connected with the input ports to the corresponding input ports of the reserved conditional components; the output ports of the deleted conditional components are traversed and all components connected to them are connected to the corresponding output ports of the reserved conditional components.
4. And regenerating the optimized AST into an executable configuration file to form an optimized visualization rule template.
Rule storage: and importing a rule template library into the visual rule template which is successfully tested and executing fine tuning training of the template retrieval and question-answering system, so that a subsequent user can optimize iteration on the rule template conveniently.
In addition, the scheme of the invention can be realized in a device mode, namely, the electronic device is provided. The device comprises a server and front-end user interaction equipment; the server is configured to be data-interactive with the front-end user interaction device and is loaded with a configuration for generating templates based on dialogue retrieval as described in the above embodiments.
Any process or method descriptions in flow charts or otherwise described herein may be understood as representing modules, segments, or portions of code which include one or more executable instructions for implementing specific logical functions or steps of the process, and further implementations are included within the scope of the preferred embodiment of the present invention in which functions may be executed out of order from that shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved, as would be understood by those reasonably skilled in the art of the embodiment of the present invention. The processor performs the various methods and processes described above. For example, method embodiments in the present solution may be implemented as a software program tangibly embodied on a machine-readable medium, such as a memory. In some embodiments, part or all of the software program may be loaded and/or installed via memory and/or a communication interface. One or more of the steps of the methods described above may be performed when a software program is loaded into memory and executed by a processor. Alternatively, in other embodiments, the processor may be configured to perform one of the methods described above in any other suitable manner (e.g., by means of firmware).
Logic and/or steps represented in the flowcharts or otherwise described herein may be embodied in any readable storage medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions.
The foregoing is merely illustrative of the present invention, and the present invention is not limited thereto, and any changes or substitutions easily contemplated by those skilled in the art within the scope of the present invention should be included in the present invention. Therefore, the protection scope of the invention is subject to the protection scope of the claims.

Claims (9)

1. A configuration system for generating templates based on dialogue retrieval, the system comprising:
the retrieval query rule template module is used for obtaining a rule template by a user for the first time, and is based on a language model of an attention mechanism; the search query rule template module performs fine tuning on the language model: firstly, the language model learns and builds a mapping relation between keyword texts and rule component templates; secondly, the model migrates the mapping relation between the requirement description of the user and the rule template;
The rule template definition module is used for setting a rule template and storing the rule template; the rule template comprises configuration parameters, variables and control structure data;
the visual editor is used for creating or modifying the rule template by a user and is realized based on a Web end;
the dynamic configuration management module is used for dynamically loading and updating the rule templates and the configuration files; the configuration file at least comprises configuration parameters;
the template searching and generating module is used for realizing the searching of the rule templates based on the pre-training language model and combining the fine tuning method, and obtaining the generating rules based on the searched rule templates;
the rule template analysis engine module receives the generation rule and maps the generation rule to the visual rule template;
in the search query rule template module, the attention mechanism is set as follows:
the method comprises the steps of mapping the characteristic X of each input lexical unit to three vector spaces Q, K, V through a weight matrix, wherein Q represents a query vector space, K represents a key space and V represents a value space;
calculating attention weight: softmax (q·kt/sqrt (d_k)), where d_k represents the dimension of the K vector, sqrt () represents the square root, and softmax represents the normalization function;
Multiplying the attention weight by V to obtain a weighted value;
and taking the sum of the weighted values as output.
2. The system of claim 1, wherein the visual editor data execution flow is:
initializing an editor and receiving user input;
updating the editing area in real time based on user input;
and synchronizing the user operation to the configuration file of the rule template to complete the data binding.
3. The system of claim 1, wherein the dynamic configuration management module establishes an API interface between the visual editor and the back-end, the rule templates and the configuration file being stored at the back-end; the visual editor sends a loading or updating request to the back end through an API interface, and after the back end processes the request, the loading or updating rule template and/or configuration file data are sent through the API interface; the back end refers to other modules except a visual editor in the system;
the method comprises the steps that persistent communication is established between the visual editor and the back end, and when the back end detects that a rule template and/or a configuration file is updated, update data is actively pushed to the visual editor through an API interface;
when the rule templates and/or the configuration files change, monitoring the change, and updating interface elements associated with the rule templates and/or the configuration files.
4. The system of claim 1, wherein the rule template definition module further comprises: a business model unit, a rule assembly unit and an expression editor unit;
the business model unit is used for standardizing various definitions of the rule template, wherein the various definitions comprise entities, attributes, relationships, data types and using conditions;
the rule assembly unit is used for forming a reusable rule assembly, and the rule assembly comprises conditions, operations, triggers, connectors and configurable super parameters; the rule components form a rule component library;
the expression editor unit is used for customizing mathematical, logical or comparison expression type rule components.
5. The system of claim 1, wherein the method of fine tuning the template retrieval and generation module comprises:
rule fine tuning, establishing a training method for transition from component level fine tuning to template level fine tuning, and forming keyword-rule template generating capacity;
and (5) searching and trimming, and forming the search text-rule generating capability through a mixed prompt trimming mode.
6. The system of claim 5, wherein the rule fine-tuning is performed by:
Step 101, extracting a template component configuration file-keyword pair, which comprises the following steps: selecting a component in a rule template library, wherein the component covers all keywords and operations; extracting corresponding configuration codes of the selected components from a rule template library, wherein the configuration codes comprise types, parameter settings and logic relations of the components; forming selected ones of the components into a component micro-sample library;
step 102, training the fine adjustment of a template component configuration file-key words;
step 103, extracting a template configuration file-keyword pair, including: acquiring a typical template and a template configuration code, labeling keywords associated with the typical template, and performing keyword-template configuration file fine tuning training;
the number of template component configuration file-keyword fine tuning training samples N1 and the number of keyword-template configuration file fine tuning training samples N2 satisfy the following:
N2 ≈ 0.1N1。
7. the system of claim 5, wherein the hybrid hint fine tuning is:
step 201, a training set of a search text, a keyword and an instruction mixed sample and the same template configuration file is established, wherein the search text, the keyword and the instruction mixed sample are taken as input, and the template configuration file is taken as output;
Step 202, the training mode adopts a mode of randomly extracting the search text, the key words and the instructions until all the extraction is completed;
in training, the mixed weight updating mode of the search text, the key words and the instructions is as follows: setting the retrieval text weight to 1, and setting the keyword and instruction weight to: 1-current iteration number/total iteration number.
8. The system of claim 1, wherein the rule template parsing engine module comprises a lexical parsing unit, a grammatical parsing unit, a semantic parsing unit;
the lexical analysis unit is used for analyzing the configuration file of the generation rule into a series of lexical units;
the grammar analysis unit is used for analyzing the lexical unit sequence into an abstract grammar tree and traversing the abstract grammar tree to form an executable configuration file;
the semantic parsing unit is used for mapping the executable configuration file to the visualization component instance, parsing the parameters and the attributes of the visualization component instance and executing data type check.
9. Configuration equipment for generating templates based on dialogue retrieval, which is characterized in that the equipment comprises a server and front-end user interaction equipment; the server is configured to be data-interactive with the front-end user interaction device and is loaded with a configuration system for generating templates based on dialogue retrieval as claimed in any of claims 1-8.
CN202311704059.4A 2023-12-13 2023-12-13 Configuration system and device for generating template based on dialogue retrieval Active CN117389541B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311704059.4A CN117389541B (en) 2023-12-13 2023-12-13 Configuration system and device for generating template based on dialogue retrieval

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311704059.4A CN117389541B (en) 2023-12-13 2023-12-13 Configuration system and device for generating template based on dialogue retrieval

Publications (2)

Publication Number Publication Date
CN117389541A CN117389541A (en) 2024-01-12
CN117389541B true CN117389541B (en) 2024-02-23

Family

ID=89465314

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311704059.4A Active CN117389541B (en) 2023-12-13 2023-12-13 Configuration system and device for generating template based on dialogue retrieval

Country Status (1)

Country Link
CN (1) CN117389541B (en)

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6473896B1 (en) * 1998-10-13 2002-10-29 Parasoft, Corp. Method and system for graphically generating user-defined rules for checking language quality
WO2008095787A1 (en) * 2007-02-09 2008-08-14 Nokia Corporation Template-based rule generation
CN106126221A (en) * 2016-06-21 2016-11-16 浪潮电子信息产业股份有限公司 A kind of list generates methods, devices and systems
CN108984679A (en) * 2018-06-29 2018-12-11 北京百度网讯科技有限公司 Dialogue generates the training method and device of model
CN109669678A (en) * 2018-10-25 2019-04-23 平安科技(深圳)有限公司 Template engine integration method, device, electronic equipment and storage medium
CN110333856A (en) * 2019-07-08 2019-10-15 政采云有限公司 Serviceization can layout online template generating system and method
CN111078846A (en) * 2019-11-25 2020-04-28 青牛智胜(深圳)科技有限公司 Multi-turn dialog system construction method and system based on business scene
CN111176650A (en) * 2018-11-09 2020-05-19 阿里巴巴集团控股有限公司 Parser generation method, search method, server, and storage medium
WO2021243706A1 (en) * 2020-06-05 2021-12-09 中山大学 Method and apparatus for cross-language question generation
CN114780587A (en) * 2022-03-28 2022-07-22 科大国创云网科技有限公司 Method for realizing dynamic deployment of visual configuration of scheduling rules based on droos rule engine
CN116048610A (en) * 2022-12-30 2023-05-02 浙江工业大学 Flow-driven conversation system implementation method and workflow engine-based conversation robot
CN116450787A (en) * 2023-03-27 2023-07-18 浙江大学 Multi-modal knowledge enhancement-based generation type dialogue method and system
CN117032668A (en) * 2023-08-08 2023-11-10 中国联合网络通信集团有限公司 Processing method, device, system and platform of visual rule engine

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7302383B2 (en) * 2002-09-12 2007-11-27 Luis Calixto Valles Apparatus and methods for developing conversational applications
US10379844B2 (en) * 2017-03-29 2019-08-13 Ca, Inc. Validating user interface templates for software probe configuration
US10860298B2 (en) * 2018-03-21 2020-12-08 Dspace Digital Signal Processing And Control Engineering Gmbh Method and system for editing a block diagram model

Patent Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6473896B1 (en) * 1998-10-13 2002-10-29 Parasoft, Corp. Method and system for graphically generating user-defined rules for checking language quality
WO2008095787A1 (en) * 2007-02-09 2008-08-14 Nokia Corporation Template-based rule generation
CN106126221A (en) * 2016-06-21 2016-11-16 浪潮电子信息产业股份有限公司 A kind of list generates methods, devices and systems
CN108984679A (en) * 2018-06-29 2018-12-11 北京百度网讯科技有限公司 Dialogue generates the training method and device of model
CN109669678A (en) * 2018-10-25 2019-04-23 平安科技(深圳)有限公司 Template engine integration method, device, electronic equipment and storage medium
CN111176650A (en) * 2018-11-09 2020-05-19 阿里巴巴集团控股有限公司 Parser generation method, search method, server, and storage medium
CN110333856A (en) * 2019-07-08 2019-10-15 政采云有限公司 Serviceization can layout online template generating system and method
CN111078846A (en) * 2019-11-25 2020-04-28 青牛智胜(深圳)科技有限公司 Multi-turn dialog system construction method and system based on business scene
WO2021243706A1 (en) * 2020-06-05 2021-12-09 中山大学 Method and apparatus for cross-language question generation
CN114780587A (en) * 2022-03-28 2022-07-22 科大国创云网科技有限公司 Method for realizing dynamic deployment of visual configuration of scheduling rules based on droos rule engine
CN116048610A (en) * 2022-12-30 2023-05-02 浙江工业大学 Flow-driven conversation system implementation method and workflow engine-based conversation robot
CN116450787A (en) * 2023-03-27 2023-07-18 浙江大学 Multi-modal knowledge enhancement-based generation type dialogue method and system
CN117032668A (en) * 2023-08-08 2023-11-10 中国联合网络通信集团有限公司 Processing method, device, system and platform of visual rule engine

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于模板匹配的搜索引擎粗糙集特征检索;王学军;《物联网技术》;20230928;第第13卷卷(第第9期期);全文 *

Also Published As

Publication number Publication date
CN117389541A (en) 2024-01-12

Similar Documents

Publication Publication Date Title
US20190129712A1 (en) Methods, systems, and computer program products for an integrated platform for continuous deployment of software application delivery models
US20060242180A1 (en) Extracting data from semi-structured text documents
EP3671526B1 (en) Dependency graph based natural language processing
EP2557499A1 (en) A system and method for automatic impact variable analysis and field expansion in mainframe systems
US20070033212A1 (en) Semantic model development and deployment
US11301643B2 (en) String extraction and translation service
CN110502227A (en) The method and device of code completion, storage medium, electronic equipment
US11537799B2 (en) Creating apps from natural language descriptions
Kessentini et al. Automated metamodel/model co-evolution using a multi-objective optimization approach
CN106484389B (en) Action stream segment management
US7958073B2 (en) Software and methods for task method knowledge hierarchies
CN115964273A (en) Spacecraft test script automatic generation method based on deep learning
JP2022019524A (en) Modeling parameter configuration method, apparatus, device, computer storage medium, and computer program
Batot et al. Heuristic-based recommendation for metamodel—ocl coevolution
Jones et al. Case studies in systematic software development
CN108932225B (en) Method and system for converting natural language requirements into semantic modeling language statements
CN115469860B (en) Method and system for automatically generating demand-to-software field model based on instruction set
CN117389541B (en) Configuration system and device for generating template based on dialogue retrieval
CN117940890A (en) Collaborative industrial integrated development and execution environment
CN114676155A (en) Code prompt information determining method, data set determining method and electronic equipment
Fill Semantic evaluation of business processes using SeMFIS
Castaldo A conceptual modeling approach for the rapid development of chatbots for conversational data exploration
Zhou et al. MiniDB: A Teaching Oriented Lightweight Database
Manto Conversational access to structured knowledge exploiting large models
Veizaga Campero Model-based Specification and Analysis of Natural Language Requirements in the Financial Domain

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant