Test method and device based on sandbox platform, storage medium and electronic equipment
By simulating real devices through a sandbox platform to test AI voice-enabled home appliances, the problems of low testing efficiency and high cost in existing technologies have been solved, achieving efficient and low-cost testing of voice interaction links.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- MIDEA GRP (SHANGHAI) CO LTD
- Filing Date
- 2026-03-10
- Publication Date
- 2026-06-12
AI Technical Summary
In testing AI voice-controlled home appliances, existing technologies require coordinating multiple real devices to build a complex engineering process, resulting in low testing efficiency, high costs, and compatibility issues.
By using a sandbox platform, virtual devices are used to simulate real devices, and a voice interaction link is built to enable testing without coordinating a large number of real devices. The dedicated communication channel between the sandbox platform and the voice interaction link allows for isolated operation and flexible access of virtual devices.
Voice interaction link testing can be completed efficiently and at low cost without modifying the existing voice interaction link structure, reducing testing difficulty and improving testing efficiency.
Smart Images

Figure CN122204718A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of equipment testing technology, and in particular to a testing method, apparatus, storage medium and electronic device based on a sandbox platform. Background Technology
[0002] In the testing of AI voice-enabled home appliances, for example, if it is necessary to test the effect of AI voice interaction in a smart home environment (i.e., the test of the voice interaction link), it is necessary to coordinate multiple voice-enabled home appliances to form a network and build an engineering link involving voice-enabled home appliances, IoT platforms and voice interaction platforms. The entire engineering link is long and complex, involving many home appliance models and various special product logics. The construction of the engineering link is difficult and seriously affects the testing efficiency. Summary of the Invention
[0003] This application provides a testing method, apparatus, storage medium, and electronic device based on a sandbox platform. This method enables testing of voice interaction links without requiring the coordination of numerous real device products to construct a complete engineering chain, thus improving testing efficiency. The above technical solution is as follows: In a first aspect, embodiments of this application provide a testing method based on a sandbox platform, applied to a sandbox platform, the method comprising: When a communication connection is established with the target voice interaction link, user interaction information input by the target user for testing the target voice interaction link is obtained through the user interface. The nodes in the target voice interaction link include an Internet of Things platform and a voice interaction platform. The Internet of Things platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. Generate the target link message corresponding to the user interaction information; Send the target link message to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link; The interactive feedback message is displayed through the user interface so that the target user can determine the test result of the target voice interaction link based on the interactive feedback message.
[0004] In conjunction with the first aspect, in some possible implementations, the method further includes: Obtain a user login request for the IoT platform, wherein the user login request carries the identity authentication information of the target user; Send the user login request to the IoT platform so that the IoT platform can authenticate the target user based on the identity authentication information and return login credentials when the identity authentication is successful; Based on the returned login credentials, the basic information corresponding to the target user in the IoT platform is managed. The basic information includes the family information bound to the target user and the device information bound to each room in the family information.
[0005] In conjunction with the first aspect, in some possible implementations, the management of basic information corresponding to the target user in the IoT platform based on the returned login credentials includes: Obtain a device addition request for the target room, wherein the device addition request includes the target device model of the target virtual device; The target virtual device is created based on the preset device configuration template library and the target device model. Based on the returned login credentials, the interface in the IoT platform is called to connect the created target virtual device to the IoT platform, and the target virtual device and the target room are bound together to add device information of the target virtual device to the basic information.
[0006] In conjunction with the first aspect, in some possible implementations, creating the target virtual device based on a preset device configuration template library and the target device model includes: Query the target device configuration template corresponding to the target device model from the preset device configuration template library, which includes preset device configuration templates corresponding to various preset device models; Generate a corresponding device operation state machine based on the target device configuration template, and create a state instance for storing the operation data of the device operation state machine; The device running state machine and the state instance are associated and stored to create the target virtual device.
[0007] In conjunction with the first aspect, in some possible implementations, the step of calling an interface in the IoT platform based on the returned login credentials to connect the created target virtual device to the IoT platform includes: Obtain the network configuration certificate information of the target virtual device created; Based on the returned login credentials, the interface in the IoT platform is invoked to connect the target virtual device to the IoT platform according to the network configuration credentials information.
[0008] In conjunction with the first aspect, in some possible implementations, the management of basic information corresponding to the target user in the IoT platform based on the returned login credentials includes: Obtain management instructions for the family information or the rooms in the family information, the management instructions including delete, add and / or query instructions; Based on the returned login credentials, the interface in the IoT platform is invoked to perform corresponding management operations on the family information or the rooms in the family information according to the management instructions.
[0009] In conjunction with the first aspect, in some possible implementations, the user interaction information includes user interaction text, and the step of obtaining user interaction information for the target voice interaction link input through the user interface includes: The user interaction text input to the target voice interaction link is collected through the text acquisition component in the user interface. The step of generating the target link message corresponding to the user interaction information includes: encapsulating the user interaction text based on the protocol followed by the target voice interaction link to obtain the target link message.
[0010] In conjunction with the first aspect, in some possible implementations, the user interaction information includes user interaction voice, and the step of obtaining user interaction information input by the target user for testing the target voice interaction link through the user interface includes: The user interaction voice input by the target user in response to the test of the target voice interaction link is acquired through the audio acquisition component in the user interface. The generation of the target link message corresponding to the user interaction information includes: The user's interactive speech is converted into text, and the conversion result is encapsulated based on the protocol followed by the target speech interaction link to obtain the target link message.
[0011] In conjunction with the first aspect, in some possible implementations, the step of acquiring the user interaction voice input by the target user in response to testing the target voice interaction link via the audio acquisition component in the user interface includes: When the audio acquisition component is in manual acquisition mode, audio acquisition is performed in response to a first trigger operation of the audio acquisition component, and audio acquisition is terminated in response to a second trigger operation of the audio acquisition component, so as to obtain the user interaction voice input by the target user for testing the target voice interaction link; When the audio acquisition component is in continuous acquisition mode, it performs continuous audio acquisition and determines the user interaction voice input by the target user to the target voice interaction link based on the audio input power during the continuous audio acquisition process.
[0012] In conjunction with the first aspect, in some possible implementations, displaying the interactive feedback message through the user interface includes: Determine the message type of the interactive feedback message; The interactive feedback message is displayed in the user interface according to the rendering strategy corresponding to the message type.
[0013] In conjunction with the first aspect, in some possible implementations, the method further includes: The target voice interaction link is selected from multiple preset voice interaction links based on the user interface. Establish a communication connection with the target voice interaction link.
[0014] In conjunction with the first aspect, in some possible implementations, the method further includes: Based on the user interface, a voice entry device is selected from the at least one target device; A first switching instruction message is generated based on the voice entry device; The first switching instruction message is sent to the target voice interaction link so that the target voice interaction link configures the voice entry device as the input device for the user interaction information according to the first switching instruction message.
[0015] In conjunction with the first aspect, in some possible implementations, the method further includes: Based on the user interface, a second switching instruction message is generated for at least one functional model invoked by the voice interaction platform; The second switching instruction message is sent to the target voice interaction link so that the target voice interaction link switches the corresponding function model invoked by the voice interaction platform.
[0016] Secondly, embodiments of this application provide a testing device based on a sandbox platform, applied to a sandbox platform, the device comprising: The acquisition unit is used to acquire user interaction information input by the target user for testing the target voice interaction link through a user interface when a communication connection is established with the target voice interaction link. The nodes in the target voice interaction link include an Internet of Things platform and a voice interaction platform. The Internet of Things platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. A generation unit is used to generate the target link message corresponding to the user interaction information; The sending unit is used to send the target link message to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link. The display unit is used to display the interactive feedback message through the user interface, so that the target user can determine the test result of the target voice interaction link based on the interactive feedback message.
[0017] Thirdly, embodiments of this application provide an electronic device, including: a processor and a memory; The processor is connected to the memory. The aforementioned memory is used to store executable program code; The processor reads the executable program code stored in the memory to run the program corresponding to the executable program code, so as to execute the method provided by the first aspect of the embodiments of this application or any possible implementation of the first aspect.
[0018] Fourthly, embodiments of this application provide a computer storage medium storing a plurality of instructions, which are adapted to be loaded by a processor and executed by the method steps provided in the first aspect of the embodiments of this application or any possible implementation thereof.
[0019] Fifthly, embodiments of this specification provide a computer program product containing instructions that, when run on a computer, cause the computer to perform the method steps provided by the first aspect of the embodiments of this application or any possible implementation thereof.
[0020] The beneficial effects of the technical solutions provided in some embodiments of this application include at least the following: In one or more embodiments of this application, when a communication connection is established with a target voice interaction link, user interaction information input by the target user for testing the target voice interaction link is obtained through a user interface. Nodes in the target voice interaction link include an IoT platform and a voice interaction platform. The IoT platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. A target link message corresponding to the user interaction information is generated. The target link message is sent to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link. The interaction feedback messages are displayed through the user interface so that the target user determines the test result of the target voice interaction link according to the interaction feedback messages. That is, based on the dedicated communication channel between the sandbox platform and the voice interaction link, the isolated operation of the voice interaction link and the flexible access of virtual devices are realized. Therefore, it is not necessary to coordinate a large number of real device products to build a complete engineering link, nor is it necessary to modify the structure of the existing voice interaction link. The test of the voice interaction link can be completed efficiently and at low cost, effectively reducing the test difficulty and improving the test efficiency.
[0021] The above description is merely an overview of the technical solution of this application. In order to better understand the technical means of this application and to implement it in accordance with the contents of the specification, and in order to make the above and other objects, features and advantages of the present invention more apparent and understandable, specific embodiments of the present invention are described below. Attached Figure Description
[0022] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0023] Figure 1 An exemplary system architecture diagram of a sandbox platform-based testing method provided for an exemplary embodiment of this application; Figure 2 A flowchart illustrating a sandbox platform-based testing method provided for an exemplary embodiment of this application; Figure 3 A schematic diagram of the module structure of a sandbox platform-based testing method provided for an exemplary embodiment of this application; Figure 4 A flowchart illustrating another sandbox platform-based testing method provided for an exemplary embodiment of this application; Figure 5A flowchart illustrating another sandbox platform-based testing method provided for an exemplary embodiment of this application; Figure 6 A schematic diagram of the structure of a sandbox platform-based testing device provided for an exemplary embodiment of this application; Figure 7 This is a schematic diagram of the structure of an electronic device provided as an exemplary embodiment of this application. Detailed Implementation
[0024] To make the features and advantages of this application more apparent and understandable, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0025] The terms "first," "second," "third," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish different objects, not to describe a specific order. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or apparatus that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products, or apparatuses.
[0026] Before introducing this application, the relevant technologies will be introduced first.
[0027] In testing traditional AI voice-enabled home appliances, to test the actual effect of AI voice interaction in a smart home environment (i.e., voice link testing), the following steps must be completed sequentially: device coordination, IoT platform registration and access, and voice interaction platform binding and debugging. This completes the engineering process. The device coordination step requires gathering various types of real home appliances (such as speakers, air conditioners, lights, and robot vacuums) and matching them with corresponding power supplies and communication modules (such as Wi-Fi / Bluetooth, Mesh / ZigBee, and gateways). Subsequently, each device must be manually powered on and initialized to ensure it is configurable and debuggable. In the IoT platform registration and access step, testers must use a mobile app or dedicated configuration tools to configure each real home appliance (e.g., Bluetooth or hotspot configuration) and verify the smooth bidirectional communication link between the IoT platform and the real appliances, ensuring the IoT platform can issue commands correctly and the devices can accurately report their operating status.
[0028] However, this testing method heavily relies on the construction and operation of a complete engineering pipeline, which is not only lengthy but also extremely complex. On the one hand, it requires coordinating a large number of real home appliances of different categories and models to construct a smart home environment with a specified combination of devices, resulting in difficulties in allocating device resources, long scenario construction cycles, and high testing costs. On the other hand, it also involves the adaptation of numerous home appliance models and various special product logics, leading to a significant increase in testing difficulty and frequent compatibility issues.
[0029] To address at least one of the aforementioned technical problems, embodiments of this application provide a testing method, apparatus, electronic device, storage medium, and computer program product based on a sandbox platform.
[0030] Please refer to Figure 1 , Figure 1 This is an exemplary system architecture diagram of a sandbox platform-based testing method provided for an exemplary embodiment of this application. Figure 1 As shown, the system architecture may include a sandbox platform 101, a network 102, an IoT platform 103, and a voice interaction platform 104. The network 102 serves as the medium for providing communication links between the sandbox platform 101 and the IoT platform 103, and between the sandbox platform 101 and the voice interaction platform 104. The network 102 may include various types of wireless and wired communication links. Wireless communication links include Bluetooth and Wi-Fi links, while wired communication links include Controller Area Network (CAN), LIN bus, FlexRay bus, MOST bus, and Ethernet bus.
[0031] The sandbox platform 101 can interact with the IoT platform 103 and the voice interaction platform 104 via network 102. It can receive various messages from the IoT platform 103 and the voice interaction platform 104, and also send relevant instructions and data to the two platforms. Specifically, the IoT platform 103 is mainly responsible for core functions such as managing the device identities bound to each registered user, issuing instructions, and controlling status reporting. The voice interaction platform 104 includes a voice processing module and a device agent. The voice processing module includes core modules such as Automatic Speech Recognition (ASR) and Natural Language Understanding (NLU) to parse and process user interaction voice. The device agent generates device control instructions for at least one device based on the parsing results of the voice processing module and sends the device control instructions to the IoT platform 103. The IoT platform 103 then controls the corresponding device according to the device control instructions and returns the device response control result to the device agent. The device agent can also generate voice reply information based on the device response control result and provide it to the user, thereby completing the voice interaction process. Sandbox platform 101 is used to execute the following processes: When a communication connection is established with the target voice interaction link, the user interaction information input by the target user for testing the target voice interaction link is obtained through the user interface. The nodes in the target voice interaction link include an IoT platform and a voice interaction platform. The IoT platform is connected to a group of interaction devices bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. A target link message corresponding to the user interaction information is generated. The target link message is sent to the target voice interaction link so that the voice interaction platform can control at least one target device in the interaction device group according to the target link message, and obtain the interaction feedback messages output by each node in the target voice interaction link. The interaction feedback messages are displayed through the user interface so that the target user can determine the test result of the target voice interaction link based on the interaction feedback messages.
[0032] Understandably, Figure 1 The number and type of IoT platform 103, voice interaction platform 104, and network 102 in the system architecture shown are only examples. In specific implementations, any number of IoT platforms 103, voice interaction platforms 104, and networks 102 can be included. This specification does not specifically limit this.
[0033] Based on the above system architecture, this application provides a testing method based on a sandbox platform. Please refer to... Figure 2 and Figure 3 , Figure 2This is a flowchart illustrating a sandbox platform-based testing method as an exemplary embodiment of this application. Figure 3 This is a schematic diagram of the module structure of a sandbox platform-based testing method provided for an exemplary embodiment of this application. The sandbox platform-based testing method is applied to a sandbox platform. Specifically, the sandbox platform-based testing method includes the following steps S201-S204, wherein: S201. When a communication connection is established with the target voice interaction link, user interaction information input by the target user for testing the target voice interaction link is obtained through the user interface. The nodes in the target voice interaction link include an Internet of Things platform and a voice interaction platform. The Internet of Things platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device.
[0034] The target voice interaction link is a complete closed-loop link from user voice input to device execution feedback, and it is the part of the engineering link that focuses on the core process of voice interaction. When the sandbox platform establishes a communication connection with the target voice interaction link, the sandbox platform can communicate with it through the original engineering interfaces of each node in the target voice interaction link without changing the existing link structure. The IoT platform can perform fine-grained management of the interactive device groups bound to each registered user, and can also perform core functions such as issuing commands and reporting status to the devices in the interactive device groups. For example, it can receive device control commands from the voice interaction platform, perform protocol parsing, format verification, and permission verification (verifying the user's permission and device reachability when issuing commands), and send the commands to the corresponding devices according to the communication protocols supported by the devices (such as MQTT, HTTP, CoAP, etc.) after confirmation. It can also receive the operating status data reported by the devices (such as device on / off status, operating parameters, fault information, etc.) and feed back the device status to the sandbox platform and the voice interaction platform, providing core feedback data on the device execution response results for link testing.
[0035] Real physical devices are devices that exist in the real world. Once a real physical device completes device registration and network configuration through an IoT platform, it can receive commands from the platform and report its actual operating status. Real physical devices can be combined with virtual devices to obtain the necessary interactive device combinations for testing, thus eliminating the need to coordinate a large number of real devices for voice interaction link testing. Virtual devices are simulated devices built by the sandbox platform based on the model, communication protocol, and product logic of real physical devices. They can accurately simulate the core behaviors of real physical devices, such as network configuration, command response, and status reporting, and can achieve collaborative interaction with the IoT platform without relying on physical hardware. The sandbox platform can manage the entire lifecycle of virtual devices, including device registration, network activation, online status monitoring, firmware upgrades, fault alarms, and device deregistration, synchronizing the device operating status of virtual devices in real time and providing device-level status support for link testing.
[0036] Please continue reading Figure 3 The voice interaction platform enables voice processing and command conversion of user interaction information. It primarily comprises a voice processing module and a device intelligent agent, which establishes communication connections with the voice processing module and the IoT platform. The voice processing module includes core modules such as a voice recognition module and a semantic understanding module. During voice interaction, the voice processing module parses and processes the user's interactive voice. The device intelligent agent generates device control commands for at least one device based on the parsing results from the voice processing module and the bound devices of each registered user in the IoT platform, and sends these commands to the IoT platform. The IoT platform then controls the corresponding device according to the device control commands and returns the device response control result to the device intelligent agent. The device intelligent agent can also generate voice reply information based on the device response control result and provide it to the user, thus completing the voice interaction process.
[0037] The sandbox platform includes several functional modules, including a home device management module, a virtual device module, and a chat interaction module. The home device management module manages the basic information bound to each registered user on the IoT platform. This basic information includes three elements: home / room / device. Management operations involve adding, deleting, modifying, and querying these three elements. The virtual device management module manages the virtual devices connected to the IoT platform, including adding, deleting, querying, and modifying virtual devices. It also provides a separate API interface to control and record the status of virtual devices. The chat interaction module allows interaction with users through dialogue (including voice and text conversations), acquiring user interaction information and transmitting it to the voice interaction platform for processing. The module then displays the voice response information returned by the voice interaction platform to the user.
[0038] The sandbox platform can also be configured with a log management module and a web user interface module. The log management module stores complete session information generated during voice interaction, including but not limited to the original user interaction information, voice responses from the voice interaction platform, session sequence, service response messages, and exception trigger logs. This allows users to review sessions and content, assisting technicians in analyzing the operational status of the target voice interaction link, troubleshooting, and optimizing performance. The log management module provides users with the ability to add sessions, view historical sessions, and delete them. The web user interface module provides a ready-to-use web-based GUI that integrates all the above modules. Users can perform related operations simply by opening a web URL. This GUI allows for the management of basic information of registered users on the IoT platform, such as data management of information related to the user's registered home / room / device information. It also provides text / voice-based AI interaction capabilities, enabling intuitive and convenient testing, data querying, and data recording.
[0039] S202. Generate the target link message corresponding to the user interaction information.
[0040] Please continue to see Figure 3 After obtaining user interaction information, if the chat interaction module is text-based, it can encapsulate it into a target link message based on the protocol followed by the target voice interaction link. If the information is audio-based, it can first call the ASR speech recognition algorithm module to convert it into text, and then encapsulate it into a target link message based on the protocol followed by the target voice interaction link.
[0041] S203. Send the target link message to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link.
[0042] Please continue to see Figure 3After generating the target link message, the chat interaction module can send it to the voice interaction platform via the engineering interface. This allows each node in the target voice interaction link to process the message according to a pre-defined voice interaction flow. The voice processing module in the voice interaction platform performs semantic parsing on the target link message to determine the user's intent. Based on the parsing results and the bound devices of registered users in the IoT platform, the device agent identifies the target device to be controlled and generates a device control command matching the target device. This command is then sent to the IoT platform for subsequent device control operations. Simultaneously, during the execution of the voice interaction flow in the target voice interaction link, the interaction feedback messages from each node are obtained through the existing engineering interfaces. These feedback messages include the semantic parsing results from the voice interaction platform, the device control commands generated by the device agent, the command issuance status from the IoT platform, and the execution status and response results of the target device. This comprehensive coverage of node feedback throughout the entire voice interaction process provides complete data support for subsequent test result analysis and link problem troubleshooting.
[0043] S204. Display the interactive feedback message through the user interface so that the target user can determine the test result of the target voice interaction link based on the interactive feedback message.
[0044] The chat interaction module can render interactive feedback messages on the user interface, and different rendering strategies can be adopted for different types of interactive feedback messages. The specific rendering method can be flexibly set according to actual testing needs. Target users can check each step in the target voice interaction link based on the full-process feedback content (interactive feedback messages) displayed on the user interface, determine whether the operation status of each node is normal, whether the command transmission is smooth, and whether the device response is accurate, thereby clarifying the test results of the target voice interaction link and accurately locating any abnormal problems in the link.
[0045] As described above, the sandbox-based testing method provided in this embodiment is applied to a sandbox platform. When a communication connection is established with a target voice interaction link, the user interaction information input by the target user for testing the target voice interaction link is obtained through the user interface. The nodes in the target voice interaction link include an IoT platform and a voice interaction platform. The IoT platform is connected to an interaction device group bound to the target user, and the interaction device group includes at least one virtual device and / or a real physical device. A target link message corresponding to the user interaction information is generated; the target link message is sent to the target voice interaction link so that the voice interaction platform can perform the test based on the target link message. At least one target device in the device group is controlled, and interactive feedback messages output by each node in the target voice interaction link are acquired. The interactive feedback messages are displayed through the user interface so that the target user can determine the test results of the target voice interaction link based on the interactive feedback messages. That is, based on the dedicated communication channel between the sandbox platform and the voice interaction link, the isolated operation of the voice interaction link and the flexible access of virtual devices are realized. Therefore, it is not necessary to coordinate a large number of real device products to build a complete engineering link, nor is it necessary to modify the structure of the existing voice interaction link. The test of the voice interaction link can be completed efficiently and at low cost, which effectively reduces the test difficulty and improves the test efficiency.
[0046] Based on the sandbox platform-based testing method described in the above embodiments, please refer to... Figure 4 , Figure 4 This is a flowchart illustrating another sandbox-based testing method provided as an exemplary embodiment of this application. The sandbox-based testing method is applied to a sandbox platform and specifically includes the following steps S301-S305, wherein: S301. Select a target voice interaction link from multiple preset voice interaction links based on the user interface, and establish a communication connection with the target voice interaction link. The nodes in the target voice interaction link include an Internet of Things (IoT) platform and a voice interaction platform. The IoT platform is connected to an interactive device group bound to the target user. The interactive device group includes at least one virtual device and / or a real physical device.
[0047] Please continue to see Figure 3The chat interaction module in the sandbox platform provides a configuration function for switching preset voice interaction links, allowing users to flexibly switch between different link operating environments. Different preset voice interaction links correspond to differentiated link operating environments, including but not limited to: test link environments for functional debugging and performance verification, simulated production link environments for simulating real business traffic and service logic, and third-party interface link environments adapted for third-party device / platform access. Specifically, during the establishment of a communication connection, the sandbox platform first verifies the target user's permissions through the existing engineering interfaces of each node in the target voice interaction link. Only after successful verification is the communication connection formally established, ensuring the legality and security of the connection. This permission verification process does not require changing the original permission control logic of each node in the target voice interaction link.
[0048] Meanwhile, during the establishment of a communication connection, the target user can select a suitable preset voice interaction link as the target voice interaction link based on their own needs through the operation on the user interface, and build a dedicated communication channel with the target voice interaction link by reusing the engineering interface in the target voice interaction link. In this way, the voice link can be developed, tested, debugged and configured based on the dedicated communication channel.
[0049] It should be noted that the sandbox platform constructs a dedicated communication channel with the target voice interaction link by reusing the engineering interfaces in the target voice interaction link. That is, the standard interfaces of the original engineering link are reused only in the two core nodes of the device access side (IoT platform) and the voice interaction side (voice interaction platform). Thus, end-to-end testing covering the entire voice interaction link can be carried out without modifying the existing link. This results in a pluggable and highly decoupled engineering testing solution, which significantly reduces the additional development and deployment costs of link testing.
[0050] In some embodiments, please continue to see Figure 3 The chat interaction module in the sandbox platform can also provide a function to simulate and specify input devices for preset voice interaction links. Specifically, the testing method based on the sandbox platform also includes: Based on this user interface, a voice entry device is selected from at least one target device; The first switching instruction message is generated based on the voice input device; The first switching instruction message is sent to the target voice interaction link so that the target voice interaction link configures the voice entry device as the input device for the user interaction information according to the first switching instruction message.
[0051] In this process, the target user can input device selection information for the voice entry device in the user interface, and encapsulate the device selection information into a link message (i.e., the first switching instruction message) that conforms to the protocol of the target voice interaction link through the chat interaction module, and send it to the target voice interaction link for input device configuration. In subsequent voice interaction, the user interaction information collected by the user interface can be regarded as the information collected by the voice entry device.
[0052] In some embodiments, the chat interaction module in the sandbox platform can also provide a function to specify the switching of functional models involved in the target voice interaction link. Specifically, the sandbox platform-based testing method further includes: Based on the user interface, a second switching instruction message is generated for at least one functional model invoked by the voice interaction platform; The second switching instruction message is sent to the target voice interaction link so that the target voice interaction link switches the corresponding function model called by the voice interaction platform.
[0053] Among them, the target user can select on the user interface Figure 3 The underlying LLM model embedded in the speech processing module and the device's intelligent agent is switched to test the effects of different model combinations. For example, a switching command to switch any underlying LLM model to another specified model can be entered in the user interface. The switching command is then encapsulated into a link message (i.e., the second switching command message) that conforms to the protocol of the target speech interaction link through the chat interaction module and sent to the target speech interaction link to configure the switching of the underlying LLM model. In subsequent speech interaction, the speech processing module and the device's intelligent agent call the latest configured underlying LLM model to execute the corresponding process in the speech interaction process.
[0054] S302. When a communication connection is established with the target voice interaction link, user interaction information input by the target user for testing the target voice interaction link is obtained through the user interface.
[0055] Steps S302 and S201 are the same, and will not be repeated here.
[0056] In some embodiments, the user interaction information includes user interaction text. In this case, the above step "obtaining user interaction information input by the target user for testing the target voice interaction link through the user interface" specifically includes: The text capture component in the user interface is used to capture user interaction text input for testing the target voice interaction link.
[0057] in, Figure 3The chat interaction module provides a visual dialogue interface integrating a text capture component. Optionally, this text capture component can be displayed as a text input box, supporting users to input, edit, and submit text content. Simultaneously, this text input box can be configured with basic validation functions such as text length limits and special character filtering to ensure that the input text meets the transmission requirements of the target voice interaction link.
[0058] In some embodiments, the user interaction information includes user interaction voice. In this case, the above step "obtaining user interaction information input by the target user for testing the target voice interaction link through the user interface" specifically includes: The audio capture component in this user interface is used to capture the user interaction voice input from the target user in response to the test of the target voice interaction link.
[0059] in, Figure 3 The chat interaction module provides a visual dialogue interface that can integrate an audio capture component. This audio capture component uses HTML5 technology to call local devices (such as microphones) to capture audio. It can be displayed as a voice recording button, supporting users to trigger one-click recording, pause recording, and preview and submit recording files.
[0060] Furthermore, the above step of "collecting user interaction voice input from the target user for testing the target voice interaction link through the audio acquisition component in the user interface" specifically includes: When the audio acquisition component is in manual acquisition mode, audio acquisition is performed in response to the first trigger operation of the audio acquisition component, and audio acquisition ends in response to the second trigger operation of the audio acquisition component, so as to obtain the user interaction voice input by the target user for testing the target voice interaction link; When the audio acquisition component is in continuous acquisition mode, it performs continuous audio acquisition and determines the user interaction voice input of the target user to the test target voice interaction link from the acquired audio based on the audio input power during the continuous audio acquisition process.
[0061] The audio acquisition component has two working modes: manual acquisition mode and continuous acquisition mode. Specifically, in manual acquisition mode, when the user performs the first trigger operation (i.e., recording start operation, such as clicking once) on the audio acquisition component, the audio acquisition process is started. Then, when the user performs the second trigger operation (i.e., recording stop operation) on the audio acquisition component, the audio acquisition process is terminated. After that, the complete audio data within the acquisition period is used as the user's interactive voice.
[0062] In continuous acquisition mode, the continuous audio acquisition process is started, and based on the real-time monitoring results of audio input power during the continuous audio acquisition process, valid audio data is identified and extracted from the continuously acquired audio stream as user interaction voice. For example, when the voice input power exceeds the signal detection threshold, audio extraction begins, and when the voice input power is lower than the signal detection threshold for a certain period of time (e.g., 1 second), audio extraction ends.
[0063] Furthermore, for continuous acquisition mode, a dynamic configuration process for the aforementioned signal detection threshold can be added. For example, the chat interaction module continuously monitors the real-time input power of the microphone through the audio acquisition component and collects time-series data of the input power according to a preset time window (e.g., 500ms). Subsequently, the lower percentile of the time-series data (empirical value of 10%) is calculated and used as the noise floor threshold in the current environment to characterize the power level of the inherent noise in the environment. Based on this, a fixed multiple of the noise floor threshold (empirical value of 5 times) is set as the signal detection threshold, thereby realizing the dynamic adaptation of the signal detection threshold to changes in environmental noise.
[0064] S303. Generate the target link message corresponding to the user interaction information.
[0065] In some embodiments, when the user interaction information includes user interaction text, step S303 specifically includes: encapsulating the user interaction text based on the protocol followed by the target voice interaction link to obtain the target link message.
[0066] When the user interaction information includes user interaction voice, the above step S303 specifically includes: converting the user interaction voice into text, and encapsulating the conversion result based on the protocol followed by the target voice interaction link to obtain the target link message.
[0067] In other words, if the user interaction information is text-based, no additional format conversion is needed. The target link's protocol encapsulation interface can be directly called to integrate the text content with the message header (including link identifier, data type, timestamp, and other metadata) to generate a target link message that conforms to the protocol. If the user interaction information is audio-based, speech-to-text (ASR) preprocessing must be performed first to decode the audio signal into readable text. Then, the above protocol encapsulation process is followed to integrate the converted text content with metadata into the target link message.
[0068] S304. Send the target link message to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link.
[0069] Steps S304 and S203 are the same as those mentioned above, and will not be repeated here.
[0070] S305. Determine the message type of the interactive feedback message, and display the interactive feedback message in the user interface according to the rendering strategy corresponding to the message type, so that the target user can determine the test result of the target voice interaction link based on the interactive feedback message.
[0071] The interactive feedback messages include semantic parsing results from the voice interaction platform, device control commands generated by the device's intelligent agent, command issuance status from the IoT platform, and execution status and response results of the target device, comprehensively covering the feedback at each node of the entire voice interaction process. Different rendering strategies can be adopted for different types of interactive feedback messages, and the specific rendering method can be flexibly set according to actual testing needs. For example, text commands sent by the user and text information responded by the system can be displayed in the user interface using a speech bubble style to recreate a realistic voice interaction scenario; functional feedback messages such as command issuance status and device execution results can be displayed using pop-up prompts or list displays for easy user identification.
[0072] In this embodiment, different rendering strategies are used to display the real interactive feedback information of the target voice interaction link in the user interface, allowing users to directly perform WYSIWYG interaction. This not only helps users to easily query the link log data based on the content displayed on the user interface, but also makes it easy for users to quickly observe the test effect, lowers the threshold for testing, and greatly facilitates the development and testing teams to perform logic verification, as well as deliver the preview to the business side for experience evaluation.
[0073] Based on the sandbox platform-based testing method described in the above embodiments, please refer to... Figure 5 , Figure 5 This is a flowchart illustrating another sandbox platform-based testing method provided for an exemplary embodiment of this application. The sandbox platform-based testing method is executed by the sandbox platform and specifically includes the following steps S401-S407, wherein: S401. Obtain a user login request for the IoT platform, which carries the identity authentication information of the target user.
[0074] The identity authentication information may include the target user's account information and password information. The sandbox platform can use the account and password provided by the user to call the login interface of the IoT platform to complete a simulated login, thereby obtaining a login credential (Token) issued by the IoT platform. This credential provides authentication for subsequent calls to the IoT platform's home information management interface (such as querying, modifying, and deleting the entire family data bound to the target user).
[0075] S402. Send the user login request to the IoT platform so that the IoT platform can authenticate the target user based on the identity authentication information and return login credentials when the identity authentication is successful.
[0076] The sandbox platform can simulate the login request format and interaction specifications recognized by the IoT platform to initiate a user login request to the IoT platform. The IoT platform then relies on its existing user identity verification rules (such as account password matching verification, permission level verification, etc.) to complete the identity authentication of the target user, and only generates a time-sensitive token as a login credential to return to the sandbox platform when the identity verification result is successful.
[0077] S403. Based on the returned login credentials, manage the basic information corresponding to the target user in the IoT platform. The basic information includes the family information bound to the target user and the device information bound to each room in the family information.
[0078] The family information represents the core attribute information of the target user's family, including but not limited to the family's unique identifier and the rooms included in the family (such as living room, bedroom, kitchen, etc.). The device information bound to each room covers key data such as the device's unique identifier, device type (such as smart lights, air conditioners, sensors, etc.), and device operating status (such as online / offline, on / off, operating parameters, etc.). Please continue reading... Figure 3 , Figure 3 The home device management module provides management functions for the basic information of each registered user in the IoT platform. The management functions include adding, modifying, and querying home information, room information, and device information. All operations require authentication based on a valid login credential to ensure that only the target user can operate the basic information associated with their name.
[0079] In some embodiments, step S403 specifically includes: A1. Retrieve the device add request for the target room, which includes the target device model of the target virtual device.
[0080] Among them, the device addition request can be manually initiated by the target user through the interactive interface of the sandbox platform, and the target device model matches the model in the list of real physical devices supported by the IoT platform.
[0081] A2. Create the target virtual device based on the preset device configuration template library and the target device model.
[0082] The preset device configuration template library is a set of standardized templates pre-built into the sandbox platform. It contains configuration parameters for all types of devices supported by the IoT platform, covering core content such as device communication protocols (e.g., MQTT, WebSocket), functional attribute definitions (e.g., switch control, temperature and humidity acquisition), status reporting frequency thresholds, and default operating parameters. The sandbox platform accurately matches the corresponding template in the preset device configuration template library based on the target device model, automatically fills in the basic attribute fields of the virtual device, and generates a globally unique virtual device identifier for it, ensuring that the created virtual device is completely consistent with the real physical device of the same model in terms of functional logic and interaction protocol.
[0083] Furthermore, step A2 above specifically includes: Search the preset device configuration template library for the target device model to find the target device configuration template corresponding to the target device model. The preset device configuration template library includes preset device configuration templates for various preset device models. Generate the corresponding device operation state machine based on the target device configuration template, and create a state instance to store the operation data of the device operation state machine; The device's running state machine and its state instance are associated and stored to create the target virtual device.
[0084] Please continue to see Figure 3 The virtual device management module can call the device simulator built into the sandbox platform to create virtual devices. This device simulator has the ability to simulate the functional logic, state transitions and interactive behaviors of real physical devices, and generate virtual devices with functions equivalent to real physical devices. For example, when a virtual device generated by the device simulator goes online, it will establish a connection with the IoT platform and simulate the behavior of real physical devices to respond to the instructions of the IoT platform, or actively report its own operating status, parameter data, etc. to the IoT platform, ensuring that the interaction logic of the virtual device is consistent with that of the real physical device.
[0085] Specifically, the device simulator generates a device state machine with functions equivalent to the real device based on the target device configuration template. This state machine defines the virtual device's state transition rules, instruction parsing logic, and parameter calculation model. At the same time, it creates independent state instances to store the dynamic operating data of the device state machine in real time, including the current online status, function parameter values, instruction execution records, etc.
[0086] A3. Based on the returned login credentials, call the interface in the IoT platform to connect the created target virtual device to the IoT platform, and bind the target virtual device to the target room to add the device information of the target virtual device to the basic information.
[0087] Among them, the login credential serves as the core authentication basis for API calls. When the sandbox platform calls the IoT platform API, it will include the login credential (Token) in the API request header. After receiving the request, the IoT platform will first verify the legality and validity of the login credential. Only after confirming that the credential is valid and belongs to the target user will it allow the subsequent device access and binding operations to be executed, thus ensuring the compliance of operation permissions.
[0088] Furthermore, step A3 above specifically includes: Obtain the network configuration certificate information of the target virtual device being created; Based on the returned login credentials, the interface in the IoT platform is called to connect the target virtual device to the IoT platform according to the network configuration credentials information.
[0089] Please continue to see Figure 3 After creating a target virtual device by calling the device simulator, the virtual device management module can automatically generate the network configuration certificate information for the target virtual device. This certificate information can be presented as a network configuration QR code or a network configuration link. The network configuration QR code encapsulates key data such as the virtual device's unique identifier, device model code, IoT platform access address, and temporary network configuration key. The sandbox platform can parse this QR code through the QR code access interface in the IoT platform to complete the rapid access of the virtual device. The network configuration link is a standardized network request address. The sandbox platform can directly call this link to initiate a device access request without additional parsing operations, realizing an automated access process for virtual devices.
[0090] In some embodiments, step S403 specifically includes: Obtain management instructions for the family information or the rooms in the family information, including delete, add and / or query instructions; Based on the returned login credentials, the interface in the IoT platform is invoked to perform corresponding management operations on the family information or the rooms in the family information according to the management instructions.
[0091] Please continue to see Figure 3The home device management module can obtain management commands through the visual interactive interface provided by the sandbox platform. Authentication is completed by including login credentials in the interface request and sending it to the interface in the IoT platform. Only after successful verification can management of home information or rooms within a home be executed. Specifically, home information management operations can include adding a home (submitting home name, address, and other attribute information), deleting a home (unregistering the unique identifier and associated data of the target home), and querying a home (retrieving the complete attributes of the home and a list of rooms). Room management operations can include adding a room (specifying the room name, the home it belongs to, and its function type), deleting a room (removing the association between the room and the home and clearing the device information bound to the room), and querying a room (retrieving the basic information of the room and a list of bound devices).
[0092] S404. When a communication connection is established with the target voice interaction link, user interaction information input by the target user for testing the target voice interaction link is obtained through the user interface. The nodes in the target voice interaction link include an Internet of Things platform and a voice interaction platform. The Internet of Things platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. S405. Generate the target link message corresponding to the user interaction information; S406. Send the target link message to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link; S407. Display the interactive feedback message through the user interface so that the target user can determine the test result of the target voice interaction link based on the interactive feedback message.
[0093] The steps S404-S407 are the same as steps S201-S204, and will not be repeated here.
[0094] Based on the methods described in the above embodiments, this application also provides a sandbox platform-based testing apparatus for performing the steps in the above-described sandbox platform-based testing method. Please refer to... Figure 6 , Figure 6 This is a schematic diagram of a sandbox platform-based testing device provided as an exemplary embodiment of this application. Specifically, the sandbox platform-based testing device 500 is applied to a sandbox platform and includes an acquisition unit 501, a generation unit 502, a sending unit 503, and a display unit 504, wherein: The acquisition unit 501 is used to acquire user interaction information input by the target user for testing the target voice interaction link through a user interface when a communication connection is established with the target voice interaction link. The nodes in the target voice interaction link include an Internet of Things platform and a voice interaction platform. The Internet of Things platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. The generation unit 502 is used to generate the target link message corresponding to the user interaction information; The sending unit 503 is used to send the target link message to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link. The display unit 504 is used to display the interactive feedback message through the user interface so that the target user can determine the test result of the target voice interaction link based on the interactive feedback message.
[0095] In some embodiments, the sandbox-based testing apparatus 500 further includes a management unit for: Obtain the user login request for the IoT platform, which carries the identity authentication information of the target user; Send the user login request to the IoT platform so that the IoT platform can authenticate the target user based on the identity authentication information and return login credentials when the identity authentication is successful; Based on the returned login credentials, the basic information corresponding to the target user in the IoT platform is managed. This basic information includes the family information bound to the target user, as well as the device information bound to each room in the family information.
[0096] In some embodiments, the management unit is specifically used for: Retrieve a device add request for the target room, which includes the target device model of the target virtual device; Create the target virtual device based on the preset device configuration template library and the target device model; Based on the returned login credentials, the interface in the IoT platform is called to connect the created target virtual device to the IoT platform, and the target virtual device is bound to the target room to add the device information of the target virtual device to the basic information.
[0097] In some embodiments, the management unit is specifically used for: Search the preset device configuration template library for the target device model to find the target device configuration template corresponding to the target device model. The preset device configuration template library includes preset device configuration templates for various preset device models. Generate the corresponding device operation state machine based on the target device configuration template, and create a state instance to store the operation data of the device operation state machine; The device's running state machine and its state instance are associated and stored to create the target virtual device.
[0098] In some embodiments, the management unit is specifically used for: Obtain the network configuration certificate information of the target virtual device being created; Based on the returned login credentials, the interface in the IoT platform is called to connect the target virtual device to the IoT platform according to the network configuration credentials information.
[0099] In some embodiments, the management unit is specifically used for: Obtain management instructions for the family information or the rooms in the family information, including delete, add and / or query instructions; Based on the returned login credentials, the interface in the IoT platform is invoked to perform corresponding management operations on the family information or the rooms in the family information according to the management instructions.
[0100] In some embodiments, the user interaction information includes user interaction text, and the acquisition unit 501 is specifically used to: acquire user interaction text input for testing the target voice interaction link through a text acquisition component in the user interface; The generation unit 502 is specifically used to: encapsulate the user interaction text based on the protocol followed by the target voice interaction link to obtain the target link message.
[0101] In some embodiments, the user interaction information includes user interaction voice, and the acquisition unit 501 is specifically used to: acquire user interaction voice input by the target user for testing the target voice interaction link through the audio acquisition component in the user interface; The generation unit 502 is specifically used to: convert the user's interactive speech into text, and encapsulate the conversion result based on the protocol followed by the target speech interaction link to obtain the target link message.
[0102] In some embodiments, the generation unit 502 is specifically used for: When the audio acquisition component is in manual acquisition mode, audio acquisition is performed in response to the first trigger operation of the audio acquisition component, and audio acquisition ends in response to the second trigger operation of the audio acquisition component, so as to obtain the user interaction voice input by the target user for testing the target voice interaction link; When the audio acquisition component is in continuous acquisition mode, it performs continuous audio acquisition and determines the user interaction voice input of the target user to the test target voice interaction link from the acquired audio based on the audio input power during the continuous audio acquisition process.
[0103] In some embodiments, the display unit 504 is specifically used for: Determine the message type of the interactive feedback message; The interactive feedback message is displayed in the user interface according to the rendering strategy corresponding to the message type.
[0104] In some embodiments, the acquisition unit 501 is further configured to: Based on this user interface, the target voice interaction link is selected from multiple preset voice interaction links; Establish a communication connection with the target for voice interaction.
[0105] In some embodiments, the acquisition unit 501 is further configured to: Based on this user interface, a voice entry device is selected from the at least one target device; The first switching instruction message is generated based on the voice input device; The first switching instruction message is sent to the target voice interaction link so that the target voice interaction link configures the voice entry device as the input device for the user interaction information according to the first switching instruction message.
[0106] In some embodiments, the acquisition unit 501 is further configured to: Based on the user interface, a second switching instruction message is generated for at least one functional model invoked by the voice interaction platform; The second switching instruction message is sent to the target voice interaction link so that the target voice interaction link switches the corresponding function model called by the voice interaction platform.
[0107] As described above, the sandbox platform-based testing device 500 provided in this embodiment is applied to a sandbox platform. When a communication connection is established with a target voice interaction link, the acquisition unit 501 acquires user interaction information input by the target user for testing the target voice interaction link through the user interface. The nodes in the target voice interaction link include an IoT platform and a voice interaction platform. The IoT platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. The generation unit 502 generates a target link message corresponding to the user interaction information. The sending unit 503 sends the target link message to the target voice interaction link so that the voice interaction platform can respond according to the target... The link message controls at least one target device in the interactive device group and obtains the interactive feedback messages output by each node in the target voice interaction link. The display unit 504 displays the interactive feedback messages through the user interface so that the target user can determine the test result of the target voice interaction link based on the interactive feedback messages. That is, based on the dedicated communication channel between the sandbox platform and the voice interaction link, the isolated operation of the voice interaction link and the flexible access of virtual devices are realized. Therefore, it is not necessary to coordinate a large number of real device products to build a complete engineering link, nor is it necessary to modify the structure of the existing voice interaction link. The test of the voice interaction link can be completed efficiently and at low cost, which effectively reduces the test difficulty and improves the test efficiency.
[0108] It should be noted that the division of the unit modules in the sandbox platform-based testing device described above is only for illustrative purposes. In other embodiments, the sandbox platform-based testing device can be divided into different unit modules as needed to complete all or part of the functions of the sandbox platform-based testing device. The implementation of each unit module in the sandbox platform-based testing device provided in the embodiments of this specification can be in the form of a computer program. This computer program can run on a terminal or server. The program modules constituted by this computer program can be stored in the memory of the terminal or server. When the computer program is executed by a processor, it implements all or part of the steps of the sandbox platform-based testing method described in the embodiments of this specification.
[0109] Please see below. Figure 7 , Figure 7 This is a schematic diagram of the structure of an electronic device provided for an exemplary embodiment of this application. For example... Figure 7 As shown, the electronic device 600 may include: at least one processor 610, at least one network interface 620, user interface 630, memory 640, and at least one communication bus 650.
[0110] The communication bus 650 is used to enable communication between these components.
[0111] The network interface 620 may include, but is not limited to, a low-power Bluetooth module, a near field communication (NFC) module, a wireless Fidelity (Wi-Fi) module, etc.
[0112] The user interface 630 may include a display screen and a camera. Optionally, the user interface 630 may also include a standard wired interface and a wireless interface.
[0113] The processor 610 may include one or more processing cores. The processor 610 connects to various parts within the electronic device 600 using various interfaces and lines, and performs various functions and processes data by running or executing instructions, programs, code sets, or instruction sets stored in the memory 640, and by calling data stored in the memory 640. Optionally, the processor 610 may be implemented using at least one hardware form of Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), or Programmable Logic Array (PLA). The processor 610 may integrate one or a combination of several of the following: Central Processing Unit (CPU), Graphics Processing Unit (GPU), and modem. The CPU primarily handles the operating system, user interface, and applications; the GPU is responsible for rendering and drawing the content required for display; and the modem handles wireless communication. It is understood that the modem may also not be integrated into the processor 610 and may be implemented as a separate chip.
[0114] The memory 640 may include random access memory (RAM) or read-only memory (ROM). Optionally, the memory 640 may include a non-transitory computer-readable storage medium. The memory 640 can be used to store instructions, programs, code, code sets, or instruction sets. The memory 640 may include a program storage area and a data storage area. The program storage area may store instructions for implementing an operating system, instructions for at least one function (such as voiceprint direction recognition, voice separation, personalized data storage, etc.), and instructions for implementing the various method embodiments described above. The data storage area may store data involved in the various method embodiments described above. Optionally, the memory 640 may also be at least one storage device located remotely from the aforementioned processor 610. Figure 7 As shown, the memory 640, which serves as a computer storage medium, may include an operating system, a network communication module, a user interface module, and program instructions.
[0115] exist Figure 7 In the illustrated electronic device 600, the user interface 630 is mainly used to provide an input interface for the user and to acquire user input data; while the processor 610 can be used to call program instructions stored in the memory 640. The aforementioned electronic device 600 can, but is not limited to, [the following functions / functions]... Figure 6 The sandbox platform-based testing apparatus 500 shown herein, and the sandbox platform-based testing method described in any of the above embodiments.
[0116] This application also provides a computer storage medium storing instructions that, when executed on a computer or processor, cause the computer or processor to perform one or more steps of any of the above methods. If the constituent modules of the aforementioned sandbox platform-based testing device are implemented as software functional units and sold or used as independent products, they can be stored in this storage medium.
[0117] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product. This computer program product includes one or more computer instructions. When these computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in or transmitted through a computer-readable storage medium. The computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. The available media can be magnetic media (e.g., floppy disks, hard disks, magnetic tapes), optical media (e.g., Digital Versatile Discs (DVDs)), or semiconductor media (e.g., solid-state disks (SSDs)).
[0118] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the methods described above. The aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks. Unless otherwise specified, the technical features of this embodiment and its implementation can be combined arbitrarily.
[0119] The above embodiments are merely descriptions of preferred embodiments of this application and are not intended to limit the scope of this application. Any modifications and improvements made by those skilled in the art to the technical solutions of this application without departing from the spirit of this application should fall within the protection scope defined by the claims of this application.
Claims
1. A testing method based on a sandbox platform, characterized in that, Applied to a sandbox platform, the method includes: When a communication connection is established with the target voice interaction link, user interaction information input by the target user for testing the target voice interaction link is obtained through the user interface. The nodes in the target voice interaction link include an Internet of Things platform and a voice interaction platform. The Internet of Things platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. Generate the target link message corresponding to the user interaction information; Send the target link message to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link; The interactive feedback message is displayed through the user interface so that the target user can determine the test result of the target voice interaction link based on the interactive feedback message.
2. The method according to claim 1, characterized in that, The method further includes: Obtain a user login request for the IoT platform, wherein the user login request carries the identity authentication information of the target user; Send the user login request to the IoT platform so that the IoT platform can authenticate the target user based on the identity authentication information and return login credentials when the identity authentication is successful; Based on the returned login credentials, the basic information corresponding to the target user in the IoT platform is managed. The basic information includes the family information bound to the target user and the device information bound to each room in the family information.
3. The method according to claim 2, characterized in that, The management of basic information corresponding to the target user in the IoT platform based on the returned login credentials includes: Obtain a device addition request for the target room, wherein the device addition request includes the target device model of the target virtual device; The target virtual device is created based on the preset device configuration template library and the target device model. Based on the returned login credentials, the interface in the IoT platform is called to connect the created target virtual device to the IoT platform, and the target virtual device and the target room are bound together to add device information of the target virtual device to the basic information.
4. The method according to claim 3, characterized in that, The step of creating the target virtual device based on the preset device configuration template library and the target device model includes: Query the target device configuration template corresponding to the target device model from the preset device configuration template library, which includes preset device configuration templates corresponding to various preset device models; Generate a corresponding device operation state machine based on the target device configuration template, and create a state instance for storing the operation data of the device operation state machine; The device's running state machine and the state instance are associated and stored to create the target virtual device.
5. The method according to claim 3, characterized in that, The step of calling the interface in the IoT platform based on the returned login credentials to connect the created target virtual device to the IoT platform includes: Obtain the network configuration certificate information of the target virtual device created; Based on the returned login credentials, the interface in the IoT platform is invoked to connect the target virtual device to the IoT platform according to the network configuration credentials information.
6. The method according to claim 2, characterized in that, The management of basic information corresponding to the target user in the IoT platform based on the returned login credentials includes: Obtain management instructions for the family information or the rooms in the family information, the management instructions including delete, add and / or query instructions; Based on the returned login credentials, the interface in the IoT platform is invoked to perform corresponding management operations on the family information or the rooms in the family information according to the management instructions.
7. The method according to claim 1, characterized in that, The user interaction information includes user interaction text. The step of obtaining user interaction information input to the target voice interaction link through the user interface includes: The user interaction text input to the target voice interaction link is collected through the text acquisition component in the user interface. The step of generating the target link message corresponding to the user interaction information includes: encapsulating the user interaction text based on the protocol followed by the target voice interaction link to obtain the target link message.
8. The method according to claim 1, characterized in that, The user interaction information includes user interaction voice. The step of obtaining user interaction information input by the target user for testing the target voice interaction link through the user interface includes: The user interaction voice input by the target user in response to the test of the target voice interaction link is acquired through the audio acquisition component in the user interface. The generation of the target link message corresponding to the user interaction information includes: The user's interactive speech is converted into text, and the conversion result is encapsulated based on the protocol followed by the target speech interaction link to obtain the target link message.
9. The method according to claim 8, characterized in that, The step of acquiring user interaction voice input from the target user in response to the test of the target voice interaction link through the audio acquisition component in the user interface includes: When the audio acquisition component is in manual acquisition mode, audio acquisition is performed in response to a first trigger operation of the audio acquisition component, and audio acquisition is terminated in response to a second trigger operation of the audio acquisition component, thereby obtaining the user interaction voice input by the target user for testing the target voice interaction link; When the audio acquisition component is in continuous acquisition mode, it performs continuous audio acquisition and determines the user interaction voice input by the target user for the target voice interaction link during the continuous audio acquisition process based on the audio input power.
10. The method according to any one of claims 1-9, characterized in that, The step of displaying the interactive feedback message through the user interface includes: Determine the message type of the interactive feedback message; The interactive feedback message is displayed in the user interface according to the rendering strategy corresponding to the message type.
11. The method according to any one of claims 1-9, characterized in that, The method further includes: The target voice interaction link is selected from multiple preset voice interaction links based on the user interface. Establish a communication connection with the target voice interaction link.
12. The method according to any one of claims 1-9, characterized in that, The method further includes: Based on the user interface, a voice entry device is selected from the at least one target device; A first switching instruction message is generated based on the voice entry device; The first switching instruction message is sent to the target voice interaction link so that the target voice interaction link configures the voice entry device as the input device for the user interaction information according to the first switching instruction message.
13. The method according to any one of claims 1-9, characterized in that, The method further includes: Based on the user interface, a second switching instruction message is generated for at least one functional model invoked by the voice interaction platform; The second switching instruction message is sent to the target voice interaction link so that the target voice interaction link switches the corresponding function model invoked by the voice interaction platform.
14. A testing device based on a sandbox platform, characterized in that, The device, applied to a sandbox platform, includes: The acquisition unit is used to acquire user interaction information input by the target user for testing the target voice interaction link through a user interface when a communication connection is established with the target voice interaction link. The nodes in the target voice interaction link include an Internet of Things platform and a voice interaction platform. The Internet of Things platform is connected to an interaction device group bound to the target user. The interaction device group includes at least one virtual device and / or a real physical device. A generation unit is used to generate the target link message corresponding to the user interaction information; The sending unit is used to send the target link message to the target voice interaction link so that the voice interaction platform controls at least one target device in the interaction device group according to the target link message and obtains the interaction feedback messages output by each node in the target voice interaction link. The display unit is used to display the interactive feedback message through the user interface, so that the target user can determine the test result of the target voice interaction link based on the interactive feedback message.
15. An electronic device, characterized in that, include: Memory, used to store executable program code; A processor is configured to call and run the executable program code from the memory, causing the electronic device to perform the sandbox-based testing method as described in any one of claims 1 to 13.
16. A computer storage medium, characterized in that, The computer storage medium stores multiple instructions adapted for loading and execution by a processor of the sandbox-based testing method as described in any one of claims 1-13.
17. A computer program product, characterized in that, The computer program product includes computer program code that, when run on a computer, causes the computer to perform the sandbox-based testing method as described in any one of claims 1 to 13.