An instrument software co-configuration development method and system

By employing a layered canvas architecture, metadata-driven and semantically aware scene template engine, combined with a multi-layered verification mechanism, the problems of high coupling and verification lag in instrument software development are solved, enabling efficient and reliable configuration generation and maintenance.

CN122111412APending Publication Date: 2026-05-29MICROCYBER CORP

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
MICROCYBER CORP
Filing Date
2026-03-02
Publication Date
2026-05-29

Smart Images

  • Figure CN122111412A_ABST
    Figure CN122111412A_ABST
Patent Text Reader

Abstract

The application provides an instrument software collaborative configuration development method and system, including the following steps: S1, a visual arrangement engine is constructed, graphical intelligent interactive configuration is realized through magnetic attraction alignment and a double buffering mechanism; S2, a metadata driven component system is established, interface contractualization and version compatibility are completed, function cohesion and low coupling are realized; S3, a semantic perception template engine is established, multi-scene adaptive combination evolution is realized through a knowledge graph and a parameter inheritance tree; and S4, through a multi-level constraint verification system, configuration closed loop verification guarantee is realized on a constraint propagation network and a rule engine.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of software control, and in particular to a method and system for collaborative configuration development of instrument software. Background Technology

[0002] Traditional software development and configurable development represent two distinct software construction paradigms. Traditional development is code-centric, requiring developers to start from the underlying architecture and implement business logic by writing extensive amounts of code. While this approach offers high flexibility and deep customization, it also results in long development cycles, high technical barriers, and significant maintenance costs; any change in requirements can trigger a chain reaction of code-level modifications. In contrast, configurable development uses abstraction and modularization to transform business logic into configurable parameters, rules, or visual components. Developers and even business personnel can quickly build and adjust system functionality simply by modifying configuration files, adjusting parameters, or dragging and dropping components. This approach significantly lowers the technical barrier, improves development efficiency, and enables rapid response to business changes. This necessitates that those skilled in the art address the corresponding technical challenges. Summary of the Invention

[0003] This invention aims to at least solve the technical problems existing in the prior art, and in particular, it innovatively proposes a method and system for collaborative configuration development of instrument software.

[0004] To achieve the above-mentioned objectives of the present invention, the present invention provides a method for collaborative configuration development of instrument software, comprising the following steps:

[0005] S1 builds a visual orchestration engine, achieving graphical intelligent interactive configuration through magnetic alignment and double buffering mechanisms;

[0006] S2 establishes a metadata-driven component system, achieving functional cohesion and low coupling through interface contractualization and version compatibility.

[0007] S3 constructs a semantic-aware template engine, which achieves multi-scenario adaptive combination and evolution based on knowledge graphs and parameter inheritance trees.

[0008] S4 establishes a multi-level constraint verification system, and achieves closed-loop verification and assurance of configuration through constraint propagation network and rule engine.

[0009] In a preferred embodiment of the above technical solution, S1 includes:

[0010] S1-1, Construct a visual orchestration engine based on a layered canvas architecture. The engine includes a logical view layer, a data flow layer, and a physical mapping layer. In the logical view layer, the geometric positional relationship of component icons in the canvas coordinate system is monitored in real time. When the distance between the center points of two adjacent component icons falls within a preset magnetic alignment threshold range, the system automatically generates horizontal or vertical auxiliary guide lines and forces the central axis of the dragged component icon to be offset to a coordinate position aligned with the target component icon.

[0011] In a preferred embodiment of the above technical solution, S1 includes:

[0012] S1-2, Integrate a context-aware intelligent recommendation component into the graphical interface. This component collects and analyzes the component selection sequence and parameter configuration habits of developers in historical projects to build a behavioral feature tag library. When it is detected that the current configuration scenario has a feature overlap of more than a preset proportion with a certain type of scenario in the historical successful case library in terms of component combination mode, parameter configuration dimension and business process topology, it dynamically pushes the corresponding high matching component type and preset parameter template in the sidebar of the interface according to the feature overlap.

[0013] S1-3, the graphical interface operation specifically includes: loading a predefined business blueprint through a scene template selector; in the parameter configuration panel, a dual buffering mechanism is adopted, separating the front-end display buffer and the back-end calculation buffer. Parameter changes input by the developer are first written to the back-end calculation buffer for legality pre-check. After the pre-check is passed, they are synchronized to the front-end display buffer in an atomic operation manner to avoid interface rendering flicker; defining the data relationship between components through a visual connection tool, which supports dynamically drawing Bézier curves and overlaying data flow transmission status indicators in the middle of the lines; after configuration, a configuration description file containing a component topology graph adjacency list is generated.

[0014] In a preferred embodiment of the above technical solution, step S2 includes:

[0015] S2-1, Design an independent component for instrument functions based on a metadata model. The metadata model includes a component identity identifier, a set of functional semantic tags, a resource dependency vector, and a version compatibility matrix. The component adopts a layered architecture to ensure that all algorithm logic and resource entities required to complete a specific function are encapsulated within the component, so that its functional cohesion reaches a preset high cohesion standard.

[0016] In a preferred embodiment of the above technical solution, step S2 includes:

[0017] S2-2, Components interact through declarative interface contracts, which include input and output parameter specifications and service quality levels; a coupling strength evaluation mechanism between components is established, and the ratio of the number of shared parameters required for interaction between two components to the total number of parameters in their respective interfaces is calculated. When this ratio is lower than a preset low coupling threshold, the two components are determined to meet the loose coupling requirements; an interface splitting strategy is adopted to reconstruct bloated interfaces with excessive functional aggregation into a set of fine-grained interfaces, so that the ratio of the number of methods contained in each subdivided interface, the average number of parameters, and the functional relevance of the methods within the interface is maintained below a preset complexity threshold;

[0018] S2-3. Establish an interface version compatibility determination mechanism. Based on the weighted sum of the syntax matching degree, behavior consistency coefficient and data backward compatibility rate of the new and old versions of the interface, when the comprehensive compatibility index reaches the preset interchangeability standard, it is determined that the two versions of the interface can be dynamically replaced at runtime.

[0019] In a preferred embodiment of the above technical solution, step S3 includes:

[0020] S3-1, Establish a scene template knowledge graph. Nodes include business scene entities, component type entities, and constraint rule entities, and edges represent the combination and applicability relationships between entities. Based on the knowledge graph, develop a template recommendation engine. When a developer selects a target scene, the engine extracts the functional requirement tag set for that scene, calculates the similarity between the functional semantic vector of each candidate component and each tag in the requirement tag set, and performs weighted summation according to preset tag weight coefficients to generate a semantic matching score between the component and the scene. Components ranked in descending order of matching score are selected to form the recommended component set for that scene.

[0021] In a preferred embodiment of the above technical solution, step S3 includes:

[0022] S3-2, the scene template is organized using a parameter inheritance tree structure. Child nodes inherit parameters from parent nodes and allow partial overriding to form the final effective parameters. The overriding operation follows the principle of proximity priority. A transformation mapping matrix is ​​established between scene templates to record the set of components and parameter change vectors that need to be adjusted when switching from the source scene to the target scene. When an application scene switching request is detected, the configuration state differences between the target scene and the current scene are automatically compared, and a minimum migration path containing only the difference components and related parameter adjustment items is generated. Reusable configuration fragments are retained to achieve smooth evolution of scene templates.

[0023] In a preferred embodiment of the above technical solution, step S4 includes:

[0024] S4-1 establishes a layered validation architecture, consisting of a syntax validation layer, a semantic consistency validation layer, and a business rule validation layer, from bottom to top. In the syntax validation layer, a finite state machine is used to verify the format validity of the configuration description file. When an undefined state transition event occurs during parsing, a syntax error alarm is triggered.

[0025] In S4-2, at the semantic consistency verification layer, a constraint propagation network is constructed, where nodes represent configuration parameters and edges represent the constraint relationships between parameters. The arc consistency algorithm is used to iteratively prune the legal value range of each parameter. When the value range of any parameter is pruned to an empty set, a parameter conflict is determined, and a conflict location report containing the location of the conflicting parameter, the associated constraint set, and repair suggestions is generated.

[0026] In a preferred embodiment of the above technical solution, step S4 includes:

[0027] In S4-3, a rule engine is established in the business rule validation layer, with a built-in set of business rules. Each rule is represented as a logical implication. During validation, the current configuration instance is matched with the rule's predecessor to calculate the degree to which the configuration instance satisfies the predecessor's condition. When the matching degree reaches a complete match and the configuration instance does not satisfy the consequent's conclusion, a business rule violation alarm is triggered. A validation result feedback channel is established to back-map configuration defects to the corresponding visual elements in the graphical interface and highlight them, blocking the configuration file generation operation until all validation items pass, forming a closed-loop quality control in the configuration development process.

[0028] The present invention also discloses a computer system, comprising:

[0029] processor;

[0030] Memory used to store processor-executable instructions;

[0031] The processor is configured to implement the application based on the instrument software collaborative configuration development method when executing the executable instructions.

[0032] In summary, due to the adoption of the above technical solution, the beneficial effects of the present invention are:

[0033] By introducing a similarity-based intelligent recommendation algorithm and a double-buffered rendering mechanism, the problems of low efficiency and error-proneness in traditional graphical interface configuration are solved, realizing intelligent assistance and real-time feedback in the configuration process; a quantitative coupled metric model is established. and interface complexity metrics The abstract design principle of "low coupling and high cohesion" is transformed into computable engineering constraints, and the version compatibility index Compat is introduced to ensure the reliability of dynamic component replacement, significantly improving the maintainability and scalability of the component system. It innovatively adopts knowledge graph-driven scene template recommendation, combined with parameter inheritance tree and transformation mapping matrix, to break through the limitations of traditional static templates, realize the semantic awareness and adaptive evolution of scene templates, and support the smooth migration of cross-scene configurations. It constructs a three-layer verification system from syntax to business rules, and introduces constraint propagation network and rule engine, which not only realizes automatic location of configuration errors, but also forms a closed-loop quality control of configuration development through feedback channels, greatly reducing the risk of runtime failures caused by configuration errors.

[0034] This invention aims to solve the technical problems of excessive component coupling, static and rigid scene templates, and lagging configuration verification in existing configuration-based development. By constructing a layered and decoupled component system, introducing a semantically aware dynamic template engine, and establishing a real-time verification mechanism for multi-dimensional constraints, it achieves high-efficiency and high-reliability configuration generation for instrument software.

[0035] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description

[0036] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which: Figure 1 This is a schematic diagram of the overall invention; Figure 2 This is a schematic diagram of the graphical interface operation of the present invention; Figure 3 This is a schematic diagram of the verification process of the present invention. Detailed Implementation

[0042] Embodiments of the present invention are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.

[0043] like Figure 1 As shown, this invention discloses a method and system for collaborative configuration development of instrument software, comprising the following steps:

[0044] S1: Fine-grained control of the multimodal visual orchestration engine;

[0045] S1-1, Construct a visual orchestration engine based on a layered canvas architecture. The engine includes a logical view layer, a data flow layer, and a physical mapping layer. In the logical view layer, the geometric positional relationship of component icons in the canvas coordinate system is monitored in real time. When it is detected that the projection distance between the dragged component icon and the adjacent component icon in the horizontal or vertical direction is less than a preset pixel threshold, a magnetic alignment command is triggered, forcibly shifting the current component icon along that direction to a coordinate position coinciding with the central axis of the target component icon.

[0046] S1-2, integrate a context-aware intelligent recommendation component into the graphical interface. This component collects and analyzes the component selection sequence and parameter configuration habits of developers in historical projects to build a behavioral feature tag library. When it is detected that the current configuration scenario has a feature similarity of more than a preset ratio with a certain type of scenario in the historical successful case library in terms of component combination mode, parameter configuration dimension and business process topology, it dynamically pushes the corresponding high matching component type and preset parameter template in the sidebar of the interface according to the similarity.

[0047] S1-3, the graphical interface operation specifically includes: loading a predefined business blueprint through a scene template selector; in the parameter configuration panel, a dual buffering mechanism is adopted, separating the front-end display buffer and the back-end calculation buffer. Parameter changes input by the developer are first written to the back-end calculation buffer for legality pre-check. After the pre-check is passed, they are synchronized to the front-end display buffer in an atomic operation manner to avoid interface rendering flicker; defining the data relationship between components through a visual connection tool, which supports dynamically drawing Bézier curves and overlaying data flow transmission status indicators in the middle of the lines; after configuration, a configuration description file containing a component topology graph adjacency list is generated.

[0048] S2: Metadata-driven component system and contract decoupling;

[0049] S2-1, Design an independent component for instrument functions based on a metadata model. The metadata model includes a component identity identifier, a set of functional semantic tags, a resource dependency vector, and a version compatibility matrix. The component adopts a layered architecture to ensure that all algorithm logic and resource entities required to complete a specific function are encapsulated within the component, so that its functional cohesion reaches a preset high cohesion standard.

[0050] S2-2, Components interact through declarative interface contracts, which include input / output parameter specifications and service quality levels; a coupling strength evaluation mechanism between components is established, which calculates the ratio of the number of shared parameters required for interaction between two components to the total number of parameters in their respective interfaces. When this ratio is lower than a preset low coupling threshold, the two components are deemed to meet the loose coupling requirement; an interface splitting strategy is adopted to reconstruct bloated interfaces with excessive functional aggregation into a set of fine-grained interfaces, so that the ratio of the number of methods, the average number of parameters, and the functional relevance of the methods within each subdivided interface is maintained below a preset complexity threshold.

[0051] S2-3. Establish an interface version compatibility determination mechanism. Based on the weighted sum of the syntax matching degree, behavior consistency coefficient and data backward compatibility rate of the new and old versions of the interface, when the comprehensive compatibility index reaches the preset interchangeability standard, it is determined that the two versions of the interface can be dynamically replaced at runtime.

[0052] S3: A semantically aware scene template engine with adaptive evolution;

[0053] S3-1, Establish a scene template knowledge graph. Nodes include business scene entities, component type entities, and constraint rule entities, and edges represent the combination and applicability relationships between entities. Based on the knowledge graph, develop a template recommendation engine. When a developer selects a target scene, the engine extracts the functional requirement tag set for that scene, calculates the similarity between the functional semantic vector of each candidate component and each tag in the requirement tag set, and performs weighted summation according to preset tag weight coefficients to generate a semantic matching score between the component and the scene. Components ranked in descending order of matching score are selected to form the recommended component set for that scene.

[0054] S3-2, the scene template is organized using a parameter inheritance tree structure. Child nodes inherit parameters from parent nodes and allow partial overriding to form the final effective parameters. The overriding operation follows the principle of proximity priority. A transformation mapping matrix is ​​established between scene templates to record the set of components and parameter change vectors that need to be adjusted when switching from the source scene to the target scene. When an application scene switching request is detected, the configuration state differences between the target scene and the current scene are automatically compared, and a minimum migration path containing only the difference components and related parameter adjustment items is generated. Reusable configuration fragments are retained to achieve smooth evolution of scene templates.

[0055] S4: Multi-level constraint verification system and closed-loop feedback;

[0056] S4-1 establishes a layered validation architecture, consisting of a syntax validation layer, a semantic consistency validation layer, and a business rule validation layer, from bottom to top. In the syntax validation layer, a finite state machine is used to verify the format validity of the configuration description file. When an undefined state transition event occurs during parsing, a syntax error alarm is triggered.

[0057] In S4-2, at the semantic consistency verification layer, a constraint propagation network is constructed, where nodes represent configuration parameters and edges represent the constraint relationships between parameters. The arc consistency algorithm is used to iteratively prune the legal value range of each parameter. When the value range of any parameter is pruned to an empty set, a parameter conflict is determined, and a conflict location report containing the location of the conflicting parameter, the associated constraint set, and repair suggestions is generated.

[0058] In S4-3, a rule engine is established in the business rule validation layer, with a built-in set of business rules. Each rule is represented as a logical implication. During validation, the current configuration instance is matched with the rule's predecessor to calculate the degree to which the configuration instance satisfies the predecessor's condition. When the matching degree reaches a complete match and the configuration instance does not satisfy the consequent's conclusion, a business rule violation alarm is triggered. A validation result feedback channel is established to back-map configuration defects to the corresponding visual elements in the graphical interface and highlight them, blocking the configuration file generation operation until all validation items pass, forming a closed-loop quality control in the configuration development process.

[0059] The preferred technical solution described above is...

[0060] S1: Build a multimodal visual orchestration engine to achieve intelligent interactive configuration in a graphical interface;

[0061] A visual orchestration engine based on a layered canvas architecture is established. This engine comprises a logical view layer, a data flow layer, and a physical mapping layer. In the logical view layer, a grid gravity alignment algorithm is used for automatic layout of component icons. When a component drag operation is detected, the topological distance *dij* between the current component icon and its adjacent components is calculated in real time. , , Let x and y be the horizontal and vertical coordinates of the i-th component icon on the canvas. , Let x and y be the x and y coordinates of the j-th adjacent component icon; if , If the preset gravity threshold distance is 10 pixels, the magnetic alignment guideline is triggered, forcibly shifting the current component icon by Δx or Δy in the horizontal or vertical direction, so that the deviation between the center axes of the two component icons is [value missing]. , Minimum alignment precision;

[0062] Integrate a context-aware intelligent recommendation component into the graphical interface. This component collects the developer's historical configuration behavior sequences. ,in Represents the component type identifier and parameter configuration vector corresponding to the k-th operation; calculates the current incomplete configuration state. With historical successful configuration case library Chinese cases similarity coefficient , ,in This represents the magnitude of the feature vector of the current state. Represents the magnitude of the feature vector of the m-th historical case; when , When the similarity threshold is set, the sidebar of the graphical interface will dynamically push suggestions for draggable component types and pre-configured parameter combinations.

[0063] The similarity threshold It is not a fixed constant, but rather determined based on the statistical characteristics of historical configuration big data. In one embodiment, the co-occurrence frequency of component combinations in all cases in the historical success case library is statistically analyzed, a similarity distribution histogram is constructed, and the similarity value corresponding to a cumulative frequency of 80% is taken as the similarity value. The optimal value is 0.82 to ensure that the pushed component combinations have statistically high reliability. In another embodiment, for industrial control instrumentation scenarios with stringent real-time requirements, [the following is omitted as it is not relevant to the main text]. The value was increased to 0.9 to reduce the number of recommendations and lower decision-making delays; for laboratory testing instrument scenarios where configuration flexibility is prioritized, the value will be increased. The value was lowered to 0.7 to provide more candidate solutions.

[0064] The graphical interface operation specifically includes: loading predefined business blueprints through a scene template selector, which displays template categories based on a tree-like hierarchical structure, with each leaf node corresponding to a configuration prototype for a specific instrument application scenario; and in the parameter configuration panel, using a double-buffering mechanism to render parameter modification effects in real time, i.e., maintaining a front-end display buffer. With background computation buffer The changes to component parameters entered by the developer in the interface are first written to... After passing the legality pre-check, it is synchronized to using atomic operations. To avoid interface flickering, a visual connection tool is used to define the data relationships between components. This tool supports dynamic drawing of Bézier curves and overlays data flow identifiers in the middle of the lines to display the transmission status of the data channel in real time. Where 0 indicates the channel is idle, and 1 indicates data is being transmitted; after configuration, a configuration description file conforming to the JSON Schema specification is generated. This file contains an adjacency list representation of the component topology graph G=(V,E), where the vertex set V corresponds to the set of component instances and the edge set E corresponds to the data flow dependencies between components.

[0065] S2: Build a metadata-driven component system to achieve functional cohesion and interface contractualization;

[0066] Design based on metadata model The instrumentation function is an independent component, and the metadata model contains component identity identifiers. Functional semantic tag set Resource dependency vector Version compatibility matrix ,in This represents the p-th semantic markup tag. This represents the system resource quota required for the q-th item; the component adopts a layered architecture, from bottom to top: hardware abstraction layer, functional logic layer, and interface adaptation layer. The functional logic layer encapsulates the set of algorithms required to complete the specific instrument function. Ensure the functional cohesion index of components , The calculation is the average similarity between methods within a component. This is a preset cohesion threshold;

[0067] The component's functional cohesion index The mean Jaccard similarity is calculated for the set of functional semantic labels of each method within a component. Where M is the total number of methods within a component. , Let be the functional semantic label sets for the i-th and j-th methods, respectively, and || represent the number of elements in the set; the cohesion threshold Based on the instrument's functional safety level, a safety-critical component value of 0.85 is used, while a non-safety-critical component value of 0.70 is used. The components are pre-classified according to their instrument functional safety level or real-time requirements, with safety-critical or high-real-time components... Higher than non-safety-critical or low-real-time-responsive components.

[0068] For the battery management component, it includes a high-voltage sampling method, a SOC estimation method, and an anomaly diagnosis method. The functional semantic tag sets for these three components are {battery capacity, high voltage, sampling}, {battery capacity, range, calculation}, and {fault, diagnosis, alarm}, respectively. The pairwise Jaccard similarities are 0.25, 0.20, and 0.15, respectively, with a mean of [missing value]. =0.20, which is lower than the safety-critical category threshold. The system prompts the developer to refactor the method division, decoupling high-voltage sampling and anomaly diagnosis into independent components.

[0069] Components communicate through declarative interface contracts. To enable interaction, the interface contract includes a set of input parameter specifications. , Enter the name parameter. Input type parameter, Input parameters, output parameter specification set and service quality level ; Output name parameter, Output type parameter, Output parameters are used to evaluate the coupling strength between components using a data coupling metric model. ,in This indicates the number of parameters shared between component i and component j. Let i be the total number of input parameters for component i. The total number of output parameters for component j; through an interface splitting strategy, bloated interfaces are reduced. Refactor into a fine-grained interface set This makes each sub-interface Interface complexity metrics Below the complexity threshold ,in Let k be the number of methods contained in interface k. The average number of parameters, The correlation coefficient between the functions of the methods within the interface;

[0070] Establish an interface version compatibility determination mechanism for interface versions. Compared with historical versions Calculate the version compatibility index ,in For syntax matching degree, The coefficient for behavioral consistency. For backward compatibility of data, α, β, and γ are weighting coefficients and satisfy α+β+γ=1; only when Compat≥0.8 is it determined that the two versions of the interface are interchangeable, ensuring the system stability when components are dynamically replaced.

[0071] S3: Build a semantically aware scene template engine to achieve adaptive combination of multiple scenes;

[0072] Establish a knowledge graph for scene templates , where the set of nodes Includes business scenario entities Component type entity and constraint rule entities edge set This represents the compatibility relationships between entities; based on the knowledge graph, a template recommendation engine is developed, which recommends templates when a developer selects a target scenario. At that time, the engine calculates each candidate component. Semantic matching score with the target scene ,in For the scene Functional requirement tag set The weight of label t, For label t and component Cosine similarity of functional semantic vectors; by Sort the components in descending order and select the top N components to form the recommended component set for this scene. ;

[0073] The scene template uses a parameter inheritance tree structure. Organize the data; the root node defines global default parameters. Child nodes inherit parameters from their parent nodes and allow partial overwriting. This forms the final effective parameters. ,in The parameter overwrite operator follows the nearest-first-come, first-served principle; a transformation mapping matrix is ​​established between scene templates. ,element This represents the set of components and parameter change vectors that need to be adjusted when switching from scene a to scene b. When an application scenario switching request is detected, the differential configuration is automatically calculated. ,in Configure the state vector for the target scenario. Given the current configuration state vector, a minimum migration path is generated based on ΔC. Only the different components are replaced and the associated parameters are adjusted, while reusable configuration fragments are retained, thus achieving a smooth evolution of the scene template.

[0074] S4: Construct a multi-level constraint verification system to achieve closed-loop guarantee of configuration correctness;

[0075] Establish a layered validation architecture, with the syntax validation layer at the bottom and the syntax validation layer at the top. Semantic consistency verification layer and business rule validation layer In the syntax validation layer, a finite state machine is used. Verify the format and validity of the configuration description file, and the state transition function. The rules for transitioning to state q′ after reading symbol σ in state q are defined. If an undefined state transition occurs during the configuration parsing process, a syntax error alarm will be triggered.

[0076] At the semantic consistency verification layer, a constraint propagation network is constructed. The node represents the configuration parameters. Edges represent the constraints between parameters. Where f is the constraint function and ϵ is the allowable error; the arc consensus algorithm AC−3 is used for constraint propagation, and the range of values ​​of each parameter is iteratively pruned. until a globally consistent state is reached. If a certain parameter The range of values Pruned to an empty set If a parameter conflict is detected, a conflict location report will be generated. ,in To and The relevant set of constraints, These are repair suggestions generated based on the rule base.

[0077] In the business rule validation layer, a rule engine is established. Built-in business rule set Each rule Represented as logical implication During verification, the current configuration instance will be used. With the antecedent of the rule Perform pattern matching and calculate the matching degree. ;like and The consequent is not satisfied If this occurs, a business rule violation alert will be triggered; a verification result feedback channel will be established to report detected configuration defects. The process is reverse-mapped to the corresponding visual elements in the graphical interface, highlighting abnormal components or parameter input boxes, and blocking the generation of configuration files until all verification items pass, thus forming a closed-loop quality control for the configuration development process.

[0078] The preferred embodiment of the above technical solution is as follows:

[0079] S1: Developers enter the graphical interface and select the "Basic Sensor Data Template" from the scene template library as the starting point. They drag the "Sensor Battery Graph Component" to the left display area on the canvas. When the offset between the component icon and the horizontal centerline of the already placed "Pressure Data Component" is less than 10 pixels, the system automatically triggers magnetic alignment, forcibly adjusting the centerline of the battery graph to align with the pressure data. Developers connect the "Battery Management ECU Data Interface" and the input port of the "Battery Graph Component" using a connection tool. The interface uses a dual-buffering mechanism for real-time rendering: the background buffer receives 0-100% battery data from the ECU and verifies its validity (0 ≤ battery ≤ 100%). After successful verification, the data is atomically synchronized to the foreground display buffer, and the battery graph refreshes in real-time without flickering. Based on the developer's historical behavior, such as frequent combinations of pressure and temperature data, the system pushes suggestions for data output monitoring components in the sidebar.

[0080] S2: Define the metadata of the battery status monitoring component: the identifier is BAT_MON_V2, the functional semantic tags are {battery monitoring, high voltage warning, battery life calculation}, and the resource dependency vector is {CAN bus channel 2, video memory area A}. This component internally encapsulates the high voltage sampling algorithm and the SOC estimation algorithm, and its functional cohesion meets the requirements for independent operation. The component declares its interface contract externally: the input port receives battery messages conforming to the J1939 protocol (data length 8 bytes, period 10ms), and the output port provides standardized battery percentage (0-100 integers) and abnormal status codes (0x00 normal / 0x01 undervoltage / 0x02 overvoltage). It interacts with the display control component through data coupling, only transmitting battery values ​​and status codes, and does not share internal computing resources. Interface version compatibility assessment: When upgrading from V1.0 to V2.0, the syntax matching degree is 100%, the original input parameter structure is preserved, the behavior consistency is 95%, the new battery life calculation function is added but the original battery display is not affected, the backward compatibility rate of data is 100%, the overall compatibility index reaches 98%, and the two versions are allowed to be dynamically replaced at runtime.

[0081] S3: Establish a scene knowledge graph. Economic mode nodes are associated with {low-power data display components, battery life priority ranking algorithm, blue theme color scheme}; working mode nodes are associated with {pressure data highlight components, real-time power curve rendering, red theme color scheme}. When developers switch from economic mode to working mode, the template engine calculates the configuration differences: the battery life priority ranking algorithm needs to be replaced with a power response optimization algorithm, and the theme color parameters need to be adjusted from blue RGB(0,100,200) to red RGB(200,0,0), while retaining the battery power graph components and their data associations. Through a parameter inheritance tree, child nodes in working mode inherit the alarm threshold parameters from the parent node's pressure data collection and partially override them: the battery low-temperature alarm threshold is adjusted from -20℃ to -10℃, as battery performance requirements are more stringent in working mode; other parameters, such as the high-temperature threshold (55℃), remain unchanged.

[0082] S4: After configuration, start layered validation: Syntax layer validation of the JSON in the configuration description file. The schema format verifies that the coordinate attribute values ​​of the battery power graph component are numeric and located within the canvas boundary; the semantic consistency layer constructs a constraint network: nodes include the power refresh period, for example, a value range of [50, 1000] ms, and the bus load rate, for example, a value range of [0, 80]%. The constraint edge defines that when the power refresh period is <100ms, the bus load rate must be <60%. Through arc consistency algorithm iteration, when the developer sets the refresh period to 50ms, the system automatically trims the bus load rate to the value range of [0, 60]. If the current load rate is 70% in the current configuration, a conflict report is triggered, locating the CAN bus channel configuration node, and it is recommended to increase the bus bandwidth or reduce the refresh frequency; the business rule layer verifies: if the battery status is abnormal, for example, the status code ≠ 0x00, the alarm light must be triggered to light up within 3 seconds. The system matches the current configuration and finds that the abnormal status processing flow is delayed by 5 seconds, triggering a rule violation alarm. The graphical interface highlights the alarm logic connection line and blocks configuration generation. After the developer modifies the delay parameter to 2 seconds, the verification passes and the final configuration description file is generated.

[0083] like Figures 2-3 As shown, a collaborative configuration development method and system for instrument software is presented. Data-coupled and functionally cohesive components focus on a specific functional domain. Smaller interfaces are designed based on component specifications to provide specific functions. By selecting scenario templates, component parameters are modified based on business processes and default configuration parameters. Business processes and interaction logic are connected based on interface descriptions and possible interface relationships. Data associations and event triggering between components are configured to achieve complete instrument functionality. A configuration description file is generated for easy modification and maintenance. After configuration, required fields, data formats, and their value ranges are validated, and a configuration description file is generated.

[0084] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.

Claims

1. A method for collaborative configuration development of instrument software, characterized in that, Includes the following steps: S1 builds a visual orchestration engine, achieving graphical intelligent interactive configuration through magnetic alignment and double buffering mechanisms; S2, by establishing a metadata-driven component system, completes interface contractualization and version compatibility, achieving functional cohesion and low coupling; S3 establishes a semantic-aware template engine, which achieves multi-scenario adaptive combination and evolution based on knowledge graphs and parameter inheritance trees; S4, through a multi-level constraint verification system, achieves closed-loop verification and assurance of configuration for the constraint propagation network and rule engine.

2. The instrument software collaborative configuration development method according to claim 1, characterized in that, S1 includes: S1-1, Construct a visual orchestration engine based on a layered canvas architecture. The engine includes a logical view layer, a data flow layer, and a physical mapping layer. In the logical view layer, the geometric positional relationship of component icons in the canvas coordinate system is monitored in real time. When the distance between the center points of two adjacent component icons falls within a preset magnetic alignment threshold range, the system automatically generates horizontal or vertical auxiliary guide lines and forces the central axis of the dragged component icon to be offset to a coordinate position aligned with the target component icon.

3. The instrument software collaborative configuration development method according to claim 1, characterized in that, S1 includes: S1-2, Integrate a context-aware intelligent recommendation component into the graphical interface. This component collects and analyzes the component selection sequence and parameter configuration habits of developers in historical projects to build a behavioral feature tag library. When it is detected that the current configuration scenario has a feature overlap of more than a preset proportion with a certain type of scenario in the historical successful case library in terms of component combination mode, parameter configuration dimension and business process topology, it dynamically pushes the corresponding high matching component type and preset parameter template in the sidebar of the interface according to the feature overlap. S1-3, the graphical interface operation specifically includes: loading a predefined business blueprint through a scene template selector; in the parameter configuration panel, a dual buffering mechanism is adopted, separating the front-end display buffer and the back-end calculation buffer. Parameter changes input by the developer are first written to the back-end calculation buffer for legality pre-check. After the pre-check is passed, they are synchronized to the front-end display buffer in an atomic operation manner to avoid interface rendering flicker; defining the data relationship between components through a visual connection tool, which supports dynamically drawing Bézier curves and overlaying data flow transmission status indicators in the middle of the lines; after configuration, a configuration description file containing a component topology graph adjacency list is generated.

4. The instrument software collaborative configuration development method according to claim 1, characterized in that, S2 includes: S2-1, Design an independent component for instrument functions based on a metadata model. The metadata model includes a component identity identifier, a set of functional semantic tags, a resource dependency vector, and a version compatibility matrix. The component adopts a layered architecture to ensure that all algorithm logic and resource entities required to complete a specific function are encapsulated within the component, so that its functional cohesion reaches a preset high cohesion standard.

5. The instrument software collaborative configuration development method according to claim 1, characterized in that, S2 includes: S2-2, Components interact through declarative interface contracts, which include input and output parameter specifications and service quality levels; a coupling strength evaluation mechanism between components is established, and the ratio of the number of shared parameters required for interaction between two components to the total number of parameters in their respective interfaces is calculated. When this ratio is lower than a preset low coupling threshold, the two components are determined to meet the loose coupling requirements; an interface splitting strategy is adopted to reconstruct bloated interfaces with excessive functional aggregation into a set of fine-grained interfaces, so that the ratio of the number of methods contained in each subdivided interface, the average number of parameters, and the functional relevance of the methods within the interface is maintained below a preset complexity threshold; S2-3. Establish an interface version compatibility determination mechanism. Based on the weighted sum of the syntax matching degree, behavior consistency coefficient and data backward compatibility rate of the new and old versions of the interface, when the comprehensive compatibility index reaches the preset interchangeability standard, it is determined that the two versions of the interface can be dynamically replaced at runtime.

6. The instrument software collaborative configuration development method according to claim 1, characterized in that, S3 includes: S3-1, Establish a scene template knowledge graph. Nodes include business scene entities, component type entities, and constraint rule entities, and edges represent the combination and applicability relationships between entities. Based on the knowledge graph, develop a template recommendation engine. When a developer selects a target scene, the engine extracts the functional requirement tag set for that scene, calculates the similarity between the functional semantic vector of each candidate component and each tag in the requirement tag set, and performs weighted summation according to preset tag weight coefficients to generate a semantic matching score between the component and the scene. Components ranked in descending order of matching score are selected to form the recommended component set for that scene.

7. The instrument software collaborative configuration development method according to claim 1, characterized in that, S3 includes: S3-2, the scene template is organized using a parameter inheritance tree structure. Child nodes inherit parameters from parent nodes and allow partial overriding to form the final effective parameters. The overriding operation follows the principle of proximity priority. A transformation mapping matrix is ​​established between scene templates to record the set of components and parameter change vectors that need to be adjusted when switching from the source scene to the target scene. When an application scene switching request is detected, the configuration state differences between the target scene and the current scene are automatically compared, and a minimum migration path containing only the difference components and related parameter adjustment items is generated. Reusable configuration fragments are retained to achieve smooth evolution of scene templates.

8. The instrument software collaborative configuration development method according to claim 1, characterized in that, S4 includes: S4-1 establishes a layered validation architecture, consisting of a syntax validation layer, a semantic consistency validation layer, and a business rule validation layer, from bottom to top. In the syntax validation layer, a finite state machine is used to verify the format validity of the configuration description file. When an undefined state transition event occurs during parsing, a syntax error alarm is triggered. In S4-2, at the semantic consistency verification layer, a constraint propagation network is constructed, where nodes represent configuration parameters and edges represent the constraint relationships between parameters. The arc consistency algorithm is used to iteratively prune the legal value range of each parameter. When the value range of any parameter is pruned to an empty set, a parameter conflict is determined, and a conflict location report containing the location of the conflicting parameter, the associated constraint set, and repair suggestions is generated.

9. The instrument software collaborative configuration development method according to claim 1, characterized in that, S4 includes: In S4-3, a rule engine is established in the business rule validation layer, with a built-in set of business rules. Each rule is represented as a logical implication. During validation, the current configuration instance is matched with the rule's predecessor to calculate the degree to which the configuration instance satisfies the predecessor's condition. When the matching degree reaches a complete match and the configuration instance does not satisfy the consequent's conclusion, a business rule violation alarm is triggered. A validation result feedback channel is established to back-map configuration defects to the corresponding visual elements in the graphical interface and highlight them, blocking the configuration file generation operation until all validation items pass, forming a closed-loop quality control in the configuration development process.

10. A computer system, characterized in that, include: processor; Memory used to store processor-executable instructions; The processor is configured to implement the application-based instrument software collaborative configuration development method according to any one of claims 1 to 9 when executing the executable instructions.