AI-driven gap cross-equipment seamless debugging and capability calling method and system
By using an AI-driven HarmonyOS cross-device seamless debugging method, a device-capability association map is generated, a combination of debugging devices is matched, and a virtual isolation environment is built. This solves the device adaptation problem in existing technologies and enables efficient and secure cross-device debugging and capability invocation.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- REALAN IND (GUANGDONG) GRP CO LTD
- Filing Date
- 2026-02-03
- Publication Date
- 2026-05-15
AI Technical Summary
Existing technologies lack AI-enabled automated adaptation mechanisms, making it difficult to adapt to the differentiated characteristics of terminals in different fields, posing data security risks, and making it difficult to balance debugging efficiency and security.
The method adopts an AI-driven HarmonyOS cross-device seamless debugging approach. It generates a device-capability association map through AI multimodal perception algorithm, and matches the debugging device combination with AI intent parsing engine to build a virtual isolation environment. This enables automation and precision in cross-device debugging, including device perception, requirement parsing, dynamic environment construction, intelligent pre-diagnosis, collaborative debugging, fault location and iterative optimization.
It achieves dynamic adaptation to multiple terminal devices, reduces debugging complexity and labor costs, improves debugging efficiency and data security, resolves the contradiction between security and efficiency, and achieves a debugging cycle reduction of more than 50% and a labor cost reduction of more than 80%.
Smart Images

Figure CN122044653A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of computer technology, specifically an AI-driven method and system for seamless debugging and capability invocation across devices using HarmonyOS. Background Technology
[0002] With the rapid development of the HarmonyOS full-scenario ecosystem, multi-terminal distributed collaboration has become an industry trend. Cross-device debugging and capability invocation are key links supporting the development and deployment of HarmonyOS applications, and their efficiency, security and adaptability are becoming increasingly important. HarmonyOS's core technologies such as distributed soft bus and device management framework provide the foundation for multi-device interconnection.
[0003] The core of the HarmonyOS operating system covers three major scenarios: consumer electronics, automotive intelligence, and industrial control. Specifically, it includes consumer-end HarmonyOS terminals such as smartphones, tablets, and smart wearable devices; automotive HarmonyOS terminals such as in-vehicle navigation and in-vehicle entertainment devices; and industrial-grade HarmonyOS terminals such as programmable logic controllers and industrial gateways. It also adapts to the cross-scenario debugging and capability call requirements of multi-terminal combinations.
[0004] Existing technologies have significant shortcomings: they lack AI-enabled automated adaptation mechanisms, requiring manual configuration of devices and calling paths, making it difficult to adapt to the differentiated characteristics of terminals in different fields; they lack precise on-demand interface management and isolation design, which can easily lead to data security risks; and they cannot balance security protection and debugging efficiency, either reducing collaborative efficiency due to strict management or weakening system security in pursuit of speed, thus restricting the large-scale deployment of the HarmonyOS ecosystem in multiple fields.
[0005] To this end, the present invention provides an AI-driven method and system for seamless debugging and capability invocation across devices using HarmonyOS. Summary of the Invention
[0006] In order to overcome the shortcomings of the prior art, at least one technical problem raised in the background art is solved.
[0007] The technical solution adopted by this invention to solve its technical problem is as follows: An AI-driven HarmonyOS cross-device seamless debugging and capability invocation method, relying on the HarmonyOS distributed technology framework and AI intelligent engine, automates the debugging process and precisely invokes capabilities in multi-terminal cross-device scenarios. The core steps include: S1. AI-driven device perception and capability modeling: The HarmonyOS distributed device discovery service is launched. By integrating multiple wireless signal features through AI multimodal perception algorithms, it automatically scans and identifies surrounding HarmonyOS devices, extracts the hardware attributes, software information and available capabilities of each device, generates a standardized device-capability association map, and marks the real-time operating status of the devices. S2. Intelligent Demand Analysis and Target Matching: The system receives user input of debugging requirements and capability call requests, transforms unstructured requirements into structured task instructions through an AI intent parsing engine, and intelligently matches debugging device combinations and capability call paths based on the device-capability association graph, automatically selecting compatible devices. S3, AI Dynamic Environment Construction and Resource Scheduling: By adjusting and adapting cross-device communication protocols through an AI scheduling engine, cross-device debugging resources are dynamically allocated, and a virtual debugging isolation environment is built to achieve isolation between the debugging process and the device's native system. S4, Intelligent Pre-diagnosis and Use Case Generation: Based on historical cross-device debugging data, potential risks in the current debugging scenario are pre-diagnosed, and targeted debugging test case sets are automatically generated. S5, Cross-device collaborative debugging and capability invocation: Debugging test cases are executed through the HarmonyOS distributed task scheduling mechanism to call the target device's capabilities in real time. At the same time, the AI monitoring module collects debugging process data and provides visual feedback. S6, AI Fault Location and Intelligent Optimization: If a fault occurs during debugging, the AI fault location module combines debugging data with historical cases to locate the root cause of the fault and automatically generate an optimization plan. S7. Debugging, Verification, and Strategy Consolidation: After the optimization plan is executed, the verification test case set is automatically triggered to complete cross-device verification. If the verification is successful, the optimal plan is solidified as a template and stored in the distributed capability management library. S8, Full Lifecycle AI Iterative Optimization: Based on historical debugging and capability call data, the matching model, pre-diagnosis rules and scheduling strategies are updated through the AI iteration module, and the algorithm parameters are optimized in combination with user feedback.
[0008] Preferably, the wireless signal features fused by the AI multimodal perception algorithm in S1 include, but are not limited to, Bluetooth, Wi-Fi, and NFC signal features; the hardware attributes include the device core processor model, storage capacity, and peripheral module type; the software information includes the HarmonyOS version and application base version; the available capabilities include at least one of data acquisition, computing power output, and peripheral control; and the real-time operating status of the hardware attributes includes CPU utilization and memory usage. A weighted fusion algorithm is used to fuse features from multiple wireless signals, as shown in the following formula: in, : The fused device identification feature value; The number of signal types fused; : No. Weights of the signals; : No. Standardized eigenvalues of a signal; Formulas for device recognition accuracy and map generation efficiency: Device recognition accuracy: Improvement in map generation efficiency: Preferably, the user input method in S2 includes at least one of natural language input and visual interface interactive input; The cross-device communication protocol in S3 is a communication protocol adapted to HarmonyOS distributed technology; the rule for dynamically allocating cross-device debugging resources is: matching device performance according to the computing power requirements and real-time requirements of the debugging task, allocating high computing power requirements to high-performance devices, and allocating high real-time requirements to low-latency devices; the virtual debugging isolation environment is built through HarmonyOS device virtualization technology, and only opens the device interfaces necessary for debugging. Dynamic resource allocation matching formula: The task requirement-equipment performance matching coefficient model is adopted, and the formula is as follows: in, Matching coefficient; : Computing power demand weight; Weighting based on real-time requirements; Available computing power of the equipment; Minimum computing power required for the task; Maximum response speed of the device; Minimum response time required for the task; Formula for resource utilization rate in virtual debugging isolation environment: Preferably, the historical cross-device debugging data in S4 includes device compatibility problem cases, capability call failure records, and debugging parameter configuration records; the potential risks include at least one of device version compatibility risks, data synchronization delay risks, and interface adaptation risks; the debugging case set covers normal operation scenarios, abnormal triggering scenarios, and boundary condition scenarios. Pre-diagnosis risk coverage formula: illustrate: Determined through a risk database of similar historical scenarios and equipment compatibility manuals.
[0009] Formula for improving test case generation efficiency: Preferably, the debugging process data collected by the AI monitoring module in S5 includes device interaction latency, data transmission success rate, capability call response time, and resource usage changes; the visualization feedback method is a dynamic chart display, which supports the linkage query of single device debugging details and cross-device collaborative status. Data acquisition delay formula: Referring to the cross-device latency calculation model, the formula is as follows: in, The total latency from data generation by the device to reception by the monitoring module; The latency of data transmission via the HarmonyOS distributed soft bus; Data verification and format conversion latency between the device and monitoring ends; The latency of data waiting in the transmission queue; constraint: Visualize the update frequency formula: Debugging the collaborative delay formula: Referring to the multi-device time synchronization delay model, the formula is as follows: in, : The time when the device initiates sending debugging commands; : The time it takes for the device to receive debugging commands; The time it takes for the device to respond to a command and then provide the result. : The time when the device initiates receiving feedback results; Synchronization latency of multiple devices performing debugging tasks; Constraints: When coordinating the debugging of 3-8 devices, .
[0010] Preferably, the root causes of the fault in S6 include at least one of communication protocol incompatibility, insufficient resource allocation, mismatched device capability version, and abnormal interface call; the optimization scheme includes at least one of protocol switching, resource reallocation, and capability adaptation plugin update, and supports automated one-click execution. Formula for reducing fault location time: Formula for optimization success rate: The optimal solution in S7 includes device combination scheme, resource allocation parameters, communication protocol type, and capability call interface parameters; the distributed capability management library supports template retrieval, calling, and updating, and the debugging preparation time is shortened after reusing templates in similar scenarios. Formula for reducing debugging preparation time: in, The entire preparation time includes equipment matching, resource configuration, and agreement negotiation. Reuse the preparation time of templates in the distributed capability management library; constraint: .
[0011] Preferably, the update cycle of the AI iteration module in S8 can be configured according to the actual application scenario. After each update, the accuracy of device-capability matching and the false judgment rate of pre-diagnosis risk are improved and reduced, respectively. The user feedback includes fault location accuracy evaluation, optimization effect score, and debugging efficiency feedback. Formula for improving matching accuracy: in, Device-capability matching accuracy before iteration; Matching accuracy after iteration; constraint: and ; Formula for reducing the false positive rate in prediagnosis: in, : The false positive rate of pre-diagnosis before iteration; : The false positive rate of pre-diagnosis after iteration; constraint: and .
[0012] Preferably, an AI-driven HarmonyOS cross-device seamless debugging and capability invocation system is provided. This system is applicable to one of the aforementioned AI-driven HarmonyOS cross-device seamless debugging and capability invocation methods. The system is built on the HarmonyOS distributed technology framework, with an AI intelligent engine as its core, and is compatible with multiple types of HarmonyOS terminals to achieve automated cross-device debugging and precise capability invocation. The system includes three core modules: device perception and demand analysis module, intelligent scheduling and debugging execution module, and fault handling and iterative optimization module. The device perception and demand analysis module is used to start the HarmonyOS distributed device discovery service. The intelligent scheduling and debugging execution module is communicatively connected to the device perception and demand analysis module, and negotiates cross-device communication protocols and dynamically allocates debugging resources through the AI scheduling unit; The fault handling and iterative optimization module is connected to the intelligent scheduling and debugging execution module. The AI fault location unit combines debugging data and historical cases to locate the root cause of the fault and generate an automatic optimization plan.
[0013] Preferably, the three core modules achieve data interaction and command transmission through the HarmonyOS distributed soft bus; the system is adapted to cross-device scenarios composed of different types of HarmonyOS terminals; each terminal supports the HarmonyOS distributed device management framework, and can achieve dynamic access and capability adaptation through the device perception and demand analysis module, and only the device interfaces necessary for debugging are opened during the debugging process to ensure the data security of the native system.
[0014] The beneficial effects of this invention are as follows: 1. The present invention describes an AI-driven HarmonyOS cross-device seamless debugging and capability invocation method and system, which generates a device-capability map through AI multimodal perception, matches the optimal device combination through AI intent parsing, and combines iterative optimization models to achieve dynamic adaptation of all types of HarmonyOS devices, eliminating the need for manual intervention. This solves the problems of existing technologies that rely on manual configuration, are prone to compatibility conflicts, and lack adaptation flexibility, effectively reducing debugging complexity and labor costs.
[0015] 2. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation method and system described in this invention strengthens protection from the root by constructing a virtual isolation environment to open debugging interfaces on demand and prohibit access to core sensitive data, coupled with AI real-time monitoring of interface status. This solves the problems of existing technologies that open all interfaces, are prone to data leakage and system interference, have inaccurate interface control and weak data security, and ensures the stability of the native system.
[0016] 3. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation method and system described in this invention builds a solid security defense through isolated environment and precise interface control, and improves efficiency by combining full-process AI automation (use case generation, fault location, automatic optimization) and solution reuse. This solves the contradiction between security and efficiency that existing technologies cannot balance, and achieves a win-win effect of shortening the debugging cycle by 50%+ and reducing labor costs by 80%+. Attached Figure Description
[0017] The invention will now be further described with reference to the accompanying drawings.
[0018] Figure 1 This is a flowchart illustrating the cross-device debugging and capability invocation process in this invention. Figure 2 This is a flowchart of the AI-driven device adaptation and path matching system in this invention; Figure 3 This is a flowchart of the virtual isolation environment construction and interface management system in this invention; Figure 4 This is a flowchart of the safety and efficiency synergistic optimization system in this invention; Figure 5 This is a flowchart of the multi-domain terminal dynamic access adaptation system in this invention. Detailed Implementation
[0019] To make the technical means, creative features, objectives and effects of this invention easier to understand, the invention will be further described below in conjunction with specific embodiments.
[0020] like Figures 1 to 5 As shown in the embodiment of the present invention, an AI-driven HarmonyOS cross-device seamless debugging and capability invocation method relies on the HarmonyOS distributed technology framework and AI intelligent engine to automate the debugging process and refine the capability invocation in multi-terminal cross-device scenarios. The core steps include: S1. AI-driven device perception and capability modeling: The HarmonyOS distributed device discovery service is launched. By integrating multiple wireless signal features through AI multimodal perception algorithms, it automatically scans and identifies surrounding HarmonyOS devices, extracts the hardware attributes, software information and available capabilities of each device, generates a standardized device-capability association map, and marks the real-time operating status of the devices. S2. Intelligent Demand Analysis and Target Matching: It receives user input of debugging requirements and capability call requests, transforms unstructured requirements into structured task instructions through an AI intent parsing engine, and intelligently matches debugging device combinations and capability call paths based on the aforementioned device-capability association graph, automatically selecting compatible devices. S3, AI Dynamic Environment Construction and Resource Scheduling: By adjusting and adapting cross-device communication protocols through an AI scheduling engine, cross-device debugging resources are dynamically allocated, and a virtual debugging isolation environment is built to achieve isolation between the debugging process and the device's native system. S4, Intelligent Pre-diagnosis and Use Case Generation: Based on historical cross-device debugging data, potential risks in the current debugging scenario are pre-diagnosed, and targeted debugging test case sets are automatically generated. S5, Cross-device collaborative debugging and capability invocation: Debugging test cases are executed through the HarmonyOS distributed task scheduling mechanism to call the target device's capabilities in real time. At the same time, the AI monitoring module collects debugging process data and provides visual feedback. S6, AI Fault Location and Intelligent Optimization: If a fault occurs during debugging, the AI fault location module combines debugging data with historical cases to locate the root cause of the fault and automatically generate an optimization plan. S7. Debugging, Verification, and Strategy Consolidation: After the optimization plan is executed, the verification test case set is automatically triggered to complete cross-device verification. If the verification is successful, the optimal plan is solidified as a template and stored in the distributed capability management library. S8, Full Lifecycle AI Iterative Optimization: Based on historical debugging and capability call data, the matching model, pre-diagnosis rules and scheduling strategies are updated through the AI iteration module, and the algorithm parameters are optimized in combination with user feedback.
[0021] like Figures 1 to 5 As shown, the wireless signal features fused by the AI multimodal perception algorithm in S1 above include, but are not limited to, Bluetooth, Wi-Fi, and NFC signal features; the hardware attributes include the device core processor model, storage capacity, and peripheral module type; the software information includes the HarmonyOS version and application base version; the available capabilities include at least one of data acquisition, computing power output, and peripheral control; and the real-time operating status of the hardware attributes includes CPU utilization and memory usage. Testing shows that the device identification accuracy of this step reaches over 99.5%, and the device-capability map generation efficiency is more than 90% higher than the traditional manual sorting method. A weighted fusion algorithm is used to fuse features from multiple wireless signals, as shown in the following formula: in, : The fused device identification feature value (range: 0-1, the closer to 1, the clearer the feature). Number of signal types fused (in this invention) ≥3 (corresponding to Bluetooth, Wi-Fi, NFC). : No. The weights of the signals (obtained through training with historical data, Bluetooth weights) =0.4, Wi-Fi weight =0.35, NFC weight =0.25, which satisfies the condition. ); : No. The standardized eigenvalues of a signal (derived from signal strength, stability, and transmission rate) - The formula obtained through standardization is: ,in These are the original signal parameters. (This refers to the maximum / minimum value of the signal parameter). Formulas for device recognition accuracy and map generation efficiency: Device recognition accuracy: (Benchmark: The scanning range is within a radius of 10 meters, including 3-8 different types of HarmonyOS devices, in an unobstructed environment.) Improvement in map generation efficiency: (Benchmark: Average time spent manually compiling equipment-capacity maps for 3 devices) This method ).
[0022] like Figures 1 to 5 As shown, the user input method in S2 above includes at least one of natural language input and visual interface interactive input; The cross-device communication protocol in S3 is adapted to HarmonyOS distributed technology; the rules for dynamically allocating cross-device debugging resources are as follows: match device performance according to the computing power and real-time requirements of the debugging task, allocate tasks with high computing power requirements to high-performance devices, and allocate tasks with high real-time requirements to low-latency devices; the virtual debugging isolation environment is built through HarmonyOS device virtualization technology, and only opens the device interfaces necessary for debugging. Dynamic resource allocation matching formula: The task requirement-equipment performance matching coefficient model is adopted, and the formula is as follows: in, Matching coefficient ( (If the system is deemed compatible, resources will be allocated preferentially). Computing power requirement weight (high computing power tasks) High real-time tasks ); Real-time requirement weight ( ); Available computing power of the device (unit: FLOPS); Minimum computing power required for the task (unit: FLOPS); Maximum response speed of the device (unit: times / second); Minimum response time required for the task (unit: times / second); Formula for resource utilization rate in virtual debugging isolation environment: (Note: Resource usage is measured in units of CPU core count × clock speed and memory capacity. The debugging environment only uses idle device resources.) ).
[0023] like Figures 1 to 5 As shown, the historical cross-device debugging data in S4 above includes device compatibility problem cases, capability call failure records, and debugging parameter configuration records; the potential risks include at least one of device version compatibility risks, data synchronization delay risks, and interface adaptation risks; the debugging test case set covers normal operation scenarios, abnormal triggering scenarios, and boundary condition scenarios, and the test case generation efficiency is improved by more than 90% compared with manual writing, and the pre-diagnosis risk coverage rate reaches more than 95%. Pre-diagnosis risk coverage formula: illustrate: The total number of potential risks, such as when debugging three devices across different devices, is determined by using a risk database of similar historical scenarios and equipment compatibility manuals. This method ,Right now .
[0024] Formula for improving test case generation efficiency: (Benchmark: Average time spent manually writing 20 debug test cases covering all scenarios) minutes, this method minute).
[0025] like Figures 1 to 5As shown, the debugging process data collected by the AI monitoring module in S5 includes device interaction latency, data transmission success rate, capability call response time, and resource usage changes; the above visualization feedback method is a dynamic chart display, which supports the linkage query of single device debugging details and cross-device collaborative status, the data collection latency is controlled within 10ms, and the visualization update frequency is not less than 10 frames / second. Data acquisition delay formula: Referring to the cross-device latency calculation model, the formula is as follows: in, Total latency from data generation by the device to reception by the monitoring module (unit: ms); The latency of data transmission via the HarmonyOS distributed soft bus ( (Packet length / bus bandwidth); Data verification and format conversion latency between the device and the monitoring end (≤3ms); : Data waiting time in the transmission queue (≤2ms); constraint: Visualize the update frequency formula: (constraint: Frames per second, i.e. seconds ); Debugging the collaborative delay formula: Referring to the multi-device time synchronization delay model, the formula is as follows: in, : The time when the device initiates sending debugging commands; : The time it takes for the device to receive debugging commands; The time it takes for the device to respond to a command and then provide the result. : The time when the device initiates receiving feedback results; Synchronization delay of multiple devices performing debugging tasks ( 10 ); Constraints: When coordinating the debugging of 3-8 devices, .
[0026] like Figures 1 to 5 As shown, the root causes of the fault in S6 above include at least one of the following: communication protocol incompatibility, insufficient resource allocation, mismatch between device capability versions, and abnormal interface calls; the above optimization solutions include at least one of the following: protocol switching, resource reallocation, and capability adaptation plugin updates, and support automated one-click execution. Formula for reducing fault location time: (Benchmark: Average time spent manually troubleshooting cross-device data synchronization anomalies) minutes, this method minute); Formula for optimization success rate: (constraint: hour, (i.e., success) The optimal solution in S7 mentioned above includes device combination scheme, resource allocation parameters, communication protocol type, and capability call interface parameters; the distributed capability management library mentioned above supports template retrieval, calling, and updating, and the debugging preparation time is shortened after reusing templates in similar scenarios; Formula for reducing debugging preparation time: in, The average preparation time for the entire process, including equipment matching, resource configuration, and protocol negotiation. minute); The preparation time for reusing templates in the distributed capability management library (including only template invocation and parameter fine-tuning) minute); constraint: .
[0027] like Figures 1 to 5 As shown, the update cycle of the AI iteration module in S8 can be configured according to the actual application scenario. After each update, the accuracy of device-capability matching and the misjudgment rate of pre-diagnosis risk are improved and reduced, respectively. The user feedback includes fault location accuracy evaluation, optimization effect score, and debugging efficiency feedback. After optimization based on user feedback, the algorithm's ability to adapt to complex cross-device scenarios is improved by more than 20%. Formula for improving matching accuracy: in, Device-capability matching accuracy before iteration (based on historical data) ); Matching accuracy after iteration ( ); constraint: and ; Formula for reducing the false positive rate in prediagnosis: in, : False positive rate of pre-diagnosis before iteration ( ); : False positive rate of prediagnosis after iteration ( ); constraint: and .
[0028] like Figures 1 to 5 As shown, an AI-driven HarmonyOS cross-device seamless debugging and capability invocation system is described. This system is applicable to one of the aforementioned AI-driven HarmonyOS cross-device seamless debugging and capability invocation methods. The system is built on the HarmonyOS distributed technology framework, with an AI intelligent engine as its core, and is compatible with multiple types of HarmonyOS terminals to achieve automated cross-device debugging and precise capability invocation. The system includes three core modules: device perception and demand analysis module, intelligent scheduling and debugging execution module, and fault handling and iterative optimization module. The aforementioned device perception and demand analysis module is used to launch the HarmonyOS distributed device discovery service. It integrates multiple wireless signal features through AI multimodal perception algorithms to complete the scanning and identification of surrounding HarmonyOS devices, attribute extraction, and generation of device-capability association maps. It is also equipped with an AI intent analysis unit to transform users' unstructured debugging needs and capability call requests into structured task instructions and match the appropriate debugging device combinations and capability call paths. The aforementioned intelligent scheduling and debugging execution module communicates with the device perception and demand analysis module. Through the AI scheduling unit, it negotiates cross-device communication protocols, dynamically allocates debugging resources, and builds a virtual debugging isolation environment to achieve isolation from the device's native system. It also carries a debugging test case generation unit, a cross-device task scheduling unit, and an AI monitoring unit to complete automatic generation of debugging test cases, multi-terminal collaborative debugging execution, real-time capability invocation, and debugging data collection and visualization feedback. The aforementioned fault handling and iterative optimization module is connected to the intelligent scheduling and debugging execution module. The AI fault location unit combines debugging data and historical cases to locate the root cause of the fault and generate an automatic optimization solution. The verification and strategy solidification unit completes the optimization verification and storage of the optimal solution template. At the same time, the AI iteration unit updates the model rules based on historical data and optimizes the algorithm parameters based on user feedback.
[0029] like Figures 1 to 5As shown, the three core modules mentioned above achieve data interaction and command transmission through the HarmonyOS distributed soft bus; the system is adapted to cross-device scenarios composed of different types of HarmonyOS terminals; each terminal supports the HarmonyOS distributed device management framework, and can achieve dynamic access and capability adaptation through the device perception and demand parsing module, and only the device interfaces necessary for debugging are opened during the debugging process to ensure the data security of the native system.
[0030] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely illustrative of the principles of the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the claimed invention.
Claims
1. An AI-driven method for seamless cross-device debugging and capability invocation of HarmonyOS, characterized in that: Leveraging the HarmonyOS distributed technology framework and AI intelligent engine, the system automates the debugging process and precisely calls upon capabilities across multiple terminals and devices, including: S1. AI-driven device perception and capability modeling: The HarmonyOS distributed device discovery service is launched. By integrating multiple wireless signal features through AI multimodal perception algorithms, it automatically scans and identifies surrounding HarmonyOS devices, extracts the hardware attributes, software information and available capabilities of each device, generates a standardized device-capability association map, and marks the real-time operating status of the devices. S2. Intelligent Demand Analysis and Target Matching: The system receives user input of debugging requirements and capability call requests, transforms unstructured requirements into structured task instructions through an AI intent parsing engine, and intelligently matches debugging device combinations and capability call paths based on the device-capability association graph, automatically selecting compatible devices. S3, AI Dynamic Environment Construction and Resource Scheduling: By adjusting and adapting cross-device communication protocols through an AI scheduling engine, cross-device debugging resources are dynamically allocated, and a virtual debugging isolation environment is built to achieve isolation between the debugging process and the device's native system. S4, Intelligent Pre-diagnosis and Use Case Generation: Based on historical cross-device debugging data, potential risks in the current debugging scenario are pre-diagnosed, and targeted debugging test case sets are automatically generated. S5, Cross-device collaborative debugging and capability invocation: Debugging test cases are executed through the HarmonyOS distributed task scheduling mechanism to call the target device's capabilities in real time. At the same time, the AI monitoring module collects debugging process data and provides visual feedback. S6, AI Fault Location and Intelligent Optimization: If a fault occurs during debugging, the AI fault location module combines debugging data with historical cases to locate the root cause of the fault and automatically generate an optimization plan. S7. Debugging, Verification, and Strategy Consolidation: After the optimization plan is executed, the verification test case set is automatically triggered to complete cross-device verification. If the verification is successful, the optimal plan is solidified as a template and stored in the distributed capability management library. S8, Full Lifecycle AI Iterative Optimization: Based on historical debugging and capability call data, the matching model, pre-diagnosis rules and scheduling strategies are updated through the AI iteration module, and the algorithm parameters are optimized in combination with user feedback.
2. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation method according to claim 1, characterized in that: The wireless signal features fused by the AI multimodal perception algorithm in S1 include, but are not limited to, Bluetooth, Wi-Fi, and NFC signal features; The hardware attributes include the device's core processor model, storage capacity, and peripheral module type; the software information includes the HarmonyOS version and application base version; the available capabilities include at least one of data acquisition, computing power output, and peripheral control; and the real-time operating status of the hardware attributes includes CPU utilization and memory usage. A weighted fusion algorithm is used to fuse features from multiple wireless signals, as shown in the following formula: in, : The fused device identification feature value; The number of signal types fused; : No. Weights of the signals; : No. Standardized eigenvalues of a signal; Formulas for device recognition accuracy and map generation efficiency: Device recognition accuracy: Improvement in map generation efficiency:
3. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation method according to claim 1, characterized in that: The user input method in S2 includes at least one of natural language input and visual interface interactive input. The cross-device communication protocol in S3 is a communication protocol adapted to HarmonyOS distributed technology. The rules for dynamically allocating cross-device debugging resources are as follows: Match device performance based on the computing power and real-time requirements of the debugging task, assign high computing power requirements to high-performance devices, and assign low-latency tasks to low-latency devices. The virtual debugging isolation environment is built using HarmonyOS device virtualization technology, providing the necessary device interfaces for debugging; Dynamic resource allocation matching formula: The task requirement-equipment performance matching coefficient model is adopted, and the formula is as follows: in, Matching coefficient; : Computing power demand weight; Weighting based on real-time requirements; Available computing power of the equipment; Minimum computing power required for the task; Maximum response speed of the device; Minimum response time required for the task; Formula for resource utilization rate in virtual debugging isolation environment:
4. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation method according to claim 1, characterized in that: The historical cross-device debugging data in S4 includes device compatibility problem cases, capability call failure records, and debugging parameter configuration records. The potential risks include at least one of the following: device version compatibility risk, data synchronization delay risk, and interface adaptation risk. The set of debugging test cases covers normal operation scenarios, abnormal triggering scenarios, and boundary condition scenarios; Pre-diagnosis risk coverage formula: illustrate: Determined through a risk database of similar historical scenarios and equipment compatibility manuals. Formula for improving test case generation efficiency:
5. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation method according to claim 1, characterized in that: The debugging process data collected by the AI monitoring module in S5 includes device interaction latency, data transmission success rate, capability call response time, and resource usage changes. The visualization feedback method is a dynamic chart display, which supports the linked query of single device debugging details and cross-device collaborative status; Data acquisition delay formula: Referring to the cross-device latency calculation model, the formula is as follows: in, The total latency from data generation by the device to reception by the monitoring module; The latency of data transmission via the HarmonyOS distributed soft bus; Data verification and format conversion latency between the device and monitoring ends; The latency of data waiting in the transmission queue; constraint: Visualize the update frequency formula: Debugging the collaborative delay formula: Referring to the multi-device time synchronization delay model, the formula is as follows: in, : The time when the device initiates sending debugging commands; : The time it takes for the device to receive debugging commands; The time it takes for the device to respond to a command and then provide the result. : The time when the device initiates receiving feedback results; Synchronization latency of multiple devices performing debugging tasks; Constraints: When coordinating the debugging of 3-8 devices, .
6. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation method according to claim 1, characterized in that: The root causes of the fault in S6 include at least one of the following: incompatible communication protocols, insufficient resource allocation, mismatched device capability versions, and abnormal interface calls. The optimization scheme includes at least one of protocol switching, resource reallocation, and capability adaptation plugin updates, and supports automated one-click execution. Formula for reducing fault location time: Formula for optimization success rate: The optimal solution in S7 includes the device combination scheme, resource allocation parameters, communication protocol type, and capability call interface parameters; The distributed capability management library supports template retrieval, invocation, and updating. After reusing templates in similar scenarios, the debugging preparation time is shortened. Formula for reducing debugging preparation time: in, The entire preparation time includes equipment matching, resource configuration, and agreement negotiation. Reuse the preparation time of templates in the distributed capability management library; constraint: .
7. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation method according to claim 1, characterized in that: The update cycle of the AI iteration module in S8 can be configured according to the actual application scenario. After each update, the accuracy of device-capability matching and the misjudgment rate of pre-diagnosis risk are improved and reduced, respectively. The user feedback includes evaluation of fault location accuracy, optimization effect score, and debugging efficiency feedback. Formula for improving matching accuracy: in, Device-capability matching accuracy before iteration; Matching accuracy after iteration; constraint: and ; Formula for reducing the false positive rate in prediagnosis: in, : The false positive rate of pre-diagnosis before iteration; : The false positive rate of pre-diagnosis after iteration; constraint: and .
8. An AI-driven HarmonyOS cross-device seamless debugging and capability recall system, characterized in that: This system is applicable to the AI-driven HarmonyOS cross-device seamless debugging and capability invocation method of claims 1-7 above. The system is built on the HarmonyOS distributed technology framework, with an AI intelligent engine at its core, adapts to multiple types of HarmonyOS terminals, and achieves automated cross-device debugging and precise capability invocation. The system includes: The module includes: equipment perception and demand analysis, intelligent scheduling and debugging execution, and fault handling and iterative optimization. The device perception and demand analysis module is used to start the HarmonyOS distributed device discovery service. The intelligent scheduling and debugging execution module is communicatively connected to the device perception and demand analysis module, and negotiates cross-device communication protocols and dynamically allocates debugging resources through the AI scheduling unit; The fault handling and iterative optimization module is connected to the intelligent scheduling and debugging execution module. The AI fault location unit combines debugging data and historical cases to locate the root cause of the fault and generate an automatic optimization plan.
9. The AI-driven HarmonyOS cross-device seamless debugging and capability invocation system according to claim 1, characterized in that: The three core modules achieve data interaction and command transmission through the HarmonyOS distributed soft bus.