Method and system for realizing device hybrid control based on large language model, and interactive terminal
By combining local lightweight text matching and cloud-based large language models in the smart health kettle, the problem of untimely device response under network latency or network outages is solved, realizing timely response and efficient control of smart home appliances.
Patent Information
- Application Number
- CN202611170399.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-03
- Publication Date
- 2026-11-24
AI Technical Summary
The existing voice control methods for smart health kettles are unresponsive in the event of network latency or outages, affecting the user experience.
A hybrid control method based on a large language model is adopted, which combines a local lightweight text matching model and a cloud-based large language model. The method performs preliminary matching and control command filtering locally, and uploads the data to the cloud for in-depth analysis if the matching rate is low, thereby achieving intelligent traffic splitting between local and cloud.
Even with network latency or outages, it can still respond to user commands promptly, improving user experience, reducing cloud inference times and server load, and enhancing device responsiveness and accuracy.
Smart Images

Figure CN123161561A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of smart home appliance control technology, and in particular to a method, system and interactive terminal for achieving hybrid control of devices based on a large language model. Background Technology
[0002] With the rapid development of artificial intelligence voice technology and large language models (LLM), smart home appliances, such as smart health pots, have been widely equipped with voice recognition modules and are gradually being integrated with large language models to support natural language interaction, thereby improving the ease of use of the devices.
[0003] Currently, voice control methods for smart health kettles are mainly divided into two categories: local voice control and cloud-based large-scale model voice control. Local voice control uses built-in fixed control phrases to recognize and match user input keywords to execute corresponding operations. This method requires no internet connection, has a fast response time, and is low-cost. However, its recognition phrases are fixed, its semantic understanding ability is weak, and it struggles to handle ambiguous spoken language and complex contexts, leading to inaccurate matching of user commands with corresponding control phrases, thus affecting control accuracy. Pure cloud-based LLM control uploads the collected user audio to the cloud, where a cloud-based large-scale language model performs semantic analysis and intent recognition, then calls the corresponding parameters to generate control commands, which are then sent to the device for execution. This method compensates to some extent for the insufficient semantic understanding ability of local voice control, but it is highly dependent on network connectivity, and even simple commands require cloud analysis and processing. In the presence of network latency, audio uploads or command issuance may be delayed, resulting in untimely device responses and impacting the user experience.
[0004] Therefore, there is an urgent need to propose a new control method for smart health pots, so that the device can still respond to user commands in a timely manner even in the event of network latency or even network outage, thereby improving the user experience. Summary of the Invention
[0005] This invention provides a method, system, and interactive terminal for hybrid device control based on a large language model, which enables the device to respond promptly to user commands even in the event of network latency or network outage, thereby improving the user experience.
[0006] The first aspect of this invention discloses a method for implementing hybrid device control based on a large language model. The method is applied to a hybrid control system, which includes smart home appliances and a cloud communicationally connected to the smart home appliances. The method includes: When voice data triggered by a target person targeting the smart home appliance is detected, the smart home appliance analyzes the voice data to obtain the corresponding target text. Based on a local text matching model, the matching rate between the target text and a local control command library is analyzed. The local control command library stores multiple control commands for controlling the smart home appliance, and the local text matching model is a lightweight model. When the matching rate is greater than or equal to a preset matching rate, a first control command corresponding to the matching rate is selected from the local control command library, and a local atomic interface matching the first control command is called. Based on the first control command, the smart home appliance is controlled to perform an operation matching the first control command. When the matching rate is less than the preset matching rate, the target data, including the voice data or the target text, is uploaded to the cloud. The cloud receives the target data, analyzes the target data based on a preset large language model, obtains the analysis results of the target data, and sends the analysis results to the smart home appliance. The smart home appliance receives the analysis results and controls the smart home appliance based on the analysis results.
[0007] As an optional implementation, in a first aspect of the present invention, the cloud platform analyzes the target data based on a preset large language model to obtain the analysis results of the target data, including: If contextual interaction data for the smart home appliance exists, the target data and the contextual interaction data are analyzed based on a preset large language model to obtain the target user's intention to use the smart home appliance. When the target user's intention indicates that the target user needs to control the smart home appliance, the target data and the context interaction data are analyzed based on the preset large language model to obtain a second control command for the smart home appliance, which is used as the analysis result of the target data; When the target user's intention indicates that the target user needs to obtain an audio response from the smart home appliance, the target data and the contextual interaction data are analyzed based on the preset large language model to obtain the response content for the intention. Based on the response content, a target audio that matches the response content is generated as the analysis result of the target data.
[0008] As an optional implementation, in a first aspect of the present invention, the smart home appliance is controlled based on the analysis results, comprising: When the analysis result of the target data is the second control command, the smart home appliance calls the local atomic interface that matches the second control command to control the smart home appliance to perform the operation that matches the second control command; When the analysis result of the target data is the target audio, the smart home appliance plays the target audio to the target person through its corresponding voice player.
[0009] As an optional implementation, in a first aspect of the present invention, the method further includes: When the matching rate is less than the preset matching rate, the cloud generates instruction text that matches the voice data and stores the instruction text in a preset recommendation set; and determines whether the preset recommendation set meets the optimization conditions of the local text matching model. When the optimization conditions are met, the cloud performs optimization training on the local text matching model based on the instruction text in the preset recommendation set to obtain the optimized target text matching model, and performs an update operation on the local text matching model in the smart home appliance based on the target text matching model.
[0010] As an optional implementation, in a first aspect of the present invention, the cloud performs an optimization training operation on the local text matching model based on the instruction text in the preset recommendation set to obtain an optimized target text matching model, including: For any instruction text in the preset recommendation set, determine the third control instruction that matches the instruction text, and establish the association between the instruction text and the third control instruction. For any of the aforementioned instruction texts, the instruction text, the third control instruction of the instruction text, and the corresponding association relationship of the instruction text are determined as an optimized instruction text; Based on all the optimized instruction texts, the local text matching model is optimized and trained to obtain the optimized target text matching model.
[0011] As an optional implementation, in a first aspect of the present invention, the cloud-based determination of whether the preset recommendation set satisfies the optimization conditions of the local text matching model includes: Calculate the target number of all the instruction texts in the preset recommendation set, and determine whether the target number is greater than or equal to the preset number of texts; when it is determined that the target number is greater than or equal to the preset number of texts, determine that the current condition of the preset recommendation set satisfies the optimization condition of the local text matching model; or, The collection duration corresponding to the preset recommendation set is determined, and it is determined whether the collection duration is greater than or equal to the preset collection duration. The cutoff time of the collection duration is determined by the time of the voice interaction data collected this time. When it is determined that the collection duration is greater than or equal to the preset collection duration, it is determined that the current conditions of the preset recommendation set meet the optimization conditions of the local text matching model.
[0012] As an optional implementation, in a first aspect of the present invention, the method further includes: For each time the target user uses the smart home appliance, the cloud acquires usage data for the smart home appliance, and performs usage preference analysis on all the usage data based on the preset large language model to obtain the target user's usage preference data for the smart home appliance; The cloud platform constructs a user profile for the target user regarding the smart home appliances based on the target user's usage preference data; and infers preferred control commands for the smart home appliances based on the target user's usage preference data. The cloud establishes an association control relationship between the target user's usage profile and preference control instructions; wherein, the association control relationship corresponding to the target user serves as the basis for the target user's subsequent control of the smart home appliance.
[0013] A second aspect of this invention discloses a system for hybrid device control based on a large language model. The system includes a smart home appliance and a cloud communication connection to the smart home appliance. The smart home appliance includes a first analysis module, a filtering module, a control module, and a first communication module. The cloud includes a second communication module and a second analysis module, wherein: The first analysis module is used to analyze the voice data triggered by the target person in relation to the smart home appliance when the voice data is detected, obtain the corresponding target text, and analyze the matching rate between the target text and the local control command library based on the local text matching model. The local control command library stores multiple control commands for controlling the smart home appliance, and the local text matching model is a lightweight model. The filtering module is used to filter out the first control instruction corresponding to the matching rate from the local control instruction library when the matching rate is greater than or equal to the preset matching rate. The control module is used to call a local atomic interface that matches the first control instruction, and control the smart home appliance to perform an operation that matches the first control instruction based on the first control instruction; The first communication module is used to upload target data to the cloud when the matching rate is less than the preset matching rate, wherein the target data includes the voice data or the target text; The second communication module is used to receive the target data; The second analysis module is used to analyze the target data based on a preset large language model to obtain the analysis results of the target data; The second communication module is also used to send the analysis results to the smart home appliance; The first communication module is also used to receive the analysis results; The control module is also used to control the smart home appliances based on the analysis results.
[0014] As an optional implementation, in a second aspect of the present invention, the specific method by which the second analysis module analyzes the target data based on a preset large language model to obtain the analysis results of the target data includes: If contextual interaction data for the smart home appliance exists, the target data and the contextual interaction data are analyzed based on a preset large language model to obtain the target user's intention to use the smart home appliance. When the target user's intention indicates that the target user needs to control the smart home appliance, the target data and the context interaction data are analyzed based on the preset large language model to obtain a second control command for the smart home appliance, which is used as the analysis result of the target data; When the target user's intention indicates that the target user needs to obtain an audio response from the smart home appliance, the target data and the contextual interaction data are analyzed based on the preset large language model to obtain the response content for the intention. Based on the response content, a target audio that matches the response content is generated as the analysis result of the target data.
[0015] As an optional implementation, in a second aspect of the present invention, the control module controls the smart home appliance based on the analysis results in the following specific manner: When the analysis result of the target data is the second control command, the smart home appliance calls the local atomic interface that matches the second control command to control the smart home appliance to perform the operation that matches the second control command; When the analysis result of the target data is the target audio, the smart home appliance plays the target audio to the target person through its corresponding voice player.
[0016] As an optional implementation, in a second aspect of the invention, the cloud further includes: The generation module is used to generate instruction text that matches the voice data when the matching rate is less than the preset matching rate, and to store the instruction text in a preset recommendation set; The judgment module is used to determine whether the preset recommendation set meets the optimization conditions of the local text matching model; The optimization module is used to perform optimization training operations on the local text matching model based on the instruction text in the preset recommendation set when it is determined that the optimization conditions are met, to obtain an optimized target text matching model, and to perform an update operation on the local text matching model in the smart home appliance based on the target text matching model.
[0017] As an optional implementation, in a second aspect of the present invention, the optimization module performs optimization training operations on the local text matching model based on the instruction text in the preset recommendation set to obtain the optimized target text matching model, specifically in the following manner: For any instruction text in the preset recommendation set, determine the third control instruction that matches the instruction text, and establish the association between the instruction text and the third control instruction. For any of the aforementioned instruction texts, the instruction text, the third control instruction of the instruction text, and the corresponding association relationship of the instruction text are determined as an optimized instruction text; Based on all the optimized instruction texts, the local text matching model is optimized and trained to obtain the optimized target text matching model.
[0018] As an optional implementation, in a second aspect of the present invention, the specific method by which the judging module judges whether the preset recommendation set satisfies the optimization conditions of the local text matching model includes: Calculate the target number of all the instruction texts in the preset recommendation set, and determine whether the target number is greater than or equal to the preset number of texts; when it is determined that the target number is greater than or equal to the preset number of texts, determine that the current condition of the preset recommendation set satisfies the optimization condition of the local text matching model; or, The collection duration corresponding to the preset recommendation set is determined, and it is determined whether the collection duration is greater than or equal to the preset collection duration. The cutoff time of the collection duration is determined by the time of the voice interaction data collected this time. When it is determined that the collection duration is greater than or equal to the preset collection duration, it is determined that the current conditions of the preset recommendation set meet the optimization conditions of the local text matching model.
[0019] As an optional implementation, in a second aspect of the invention, the cloud further includes: The acquisition module is used to acquire usage data of the smart home appliance each time the target person uses the smart home appliance. The second analysis module is further configured to perform usage preference analysis on all the usage data based on the preset large language model to obtain the target user's usage preference data for the smart home appliance; The construction module is used to build a user profile for the smart home appliances for the target user based on the user preference data of the target user; The second analysis module is further configured to infer preference control instructions for the smart home appliances for the target user based on the user's usage preference data; The construction module is also used to establish an association control relationship between the user profile and preference control instructions of the target user; wherein, the association control relationship corresponding to the target user serves as the basis for the target user to control the smart home appliance when using the smart home appliance in the future.
[0020] A third aspect of the present invention discloses an interactive terminal, the interactive terminal including a smart home appliance or a cloud, the interactive terminal comprising: Memory containing executable program code; A processor coupled to the memory; The processor calls the executable program code stored in the memory to execute some or all of the steps performed by the smart home appliance or the cloud in any of the methods described in the first aspect of the present invention.
[0021] The fourth aspect of the present invention discloses a computer storage medium storing computer instructions, which, when invoked, are used to execute some or all of the steps in any of the methods described in the first aspect of the present invention.
[0022] Compared with the prior art, the present invention has the following beneficial effects: In this embodiment of the invention, when voice data triggered by a target person targeting a smart home appliance is detected, the smart home appliance analyzes the voice data to obtain the corresponding target text. Based on a local text matching model, the matching rate between the target text and the local control command library is analyzed. The local control command library stores multiple control commands for controlling the smart home appliance, and the local text matching model is a lightweight model. When the matching rate is greater than or equal to a preset matching rate, a first control command corresponding to the matching rate is selected from the local control command library, and a local atomic interface matching the first control command is called. Based on the first control command, the smart home appliance is controlled to perform an operation matching the first control command. When the matching rate is less than the preset matching rate, the target data is uploaded to the cloud. The target data includes voice data or target text. The cloud receives the target data and analyzes the target data based on a preset large language model to obtain the analysis result of the target data, and sends the analysis result to the smart home appliance. The smart home appliance receives the analysis result and controls the smart home appliance based on the analysis result. As can be seen, implementing this invention involves deploying a lightweight text matching model in smart home appliances and pre-encapsulating all executable actions of the device into standardized FC atomic operation interfaces. When voice data triggered by the user on the smart home appliance is detected, it is converted into text. The text matching model then analyzes the converted text against the local control command library to obtain the matching rate. If the matching rate is greater than or equal to a preset threshold, the corresponding FC atomic interface is directly called locally to control the smart home appliance for this offline execution. The entire inference and control are completed locally, without occupying the large language model resources in the cloud, and without going through the network round trip process of uploading audio to the cloud for inference and then issuing commands. This ensures the timely response of the smart home appliance even in the event of network latency, packet loss, or disconnection. Users can still complete high-frequency basic operations such as power on / off, mode switching, and temperature control adjustment through natural language. If the matching rate is less than the preset threshold, the detected data is uploaded to the cloud for analysis, achieving intelligent traffic splitting between local and cloud operations. This greatly reduces the number of cloud inference operations, lowers server bandwidth and computing power consumption, and ensures the timely response of the smart home appliance, thereby improving the user experience. Attached Figure Description
[0023] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0024] Figure 1 This is a schematic diagram of a system architecture for implementing hybrid device control based on a large language model, as disclosed in an embodiment of the present invention. Figure 2 This is a flowchart illustrating a method for implementing hybrid control of devices based on a large language model, as disclosed in an embodiment of the present invention. Figure 3 This is a flowchart illustrating another method for implementing hybrid device control based on a large language model, as disclosed in an embodiment of the present invention. Figure 4 This is a schematic diagram of the structure of a system for implementing hybrid control of devices based on a large language model, as disclosed in an embodiment of the present invention. Figure 5 This is a schematic diagram of another system for implementing hybrid device control based on a large language model, as disclosed in an embodiment of the present invention. Figure 6 This is a schematic diagram of the structure of an interactive terminal disclosed in an embodiment of the present invention. Detailed Implementation
[0025] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0026] The terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention 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, apparatus, product, or end 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 ends.
[0027] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of the invention. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0028] This invention discloses a method, system, and interactive terminal for hybrid device control based on a large language model. By deploying a lightweight text matching model on smart home appliances and pre-encapsulating all executable actions of the device into standardized FC (Functional Control) atomic operation interfaces, when voice data triggered by the user on the smart home appliance is detected, it is converted into text. The text matching model then analyzes the converted text against a local control command library to obtain the matching rate. If the matching rate is greater than or equal to a preset threshold, the corresponding FC atomic interface is directly called locally to control the smart home appliance for this offline execution. The entire reasoning and control process is completed locally. This method eliminates the need for large cloud-based language model resources and the network round trip process of audio uploading to the cloud for inference and then issuing commands. This ensures timely response of smart home appliances even in the event of network latency, packet loss, or disconnection. Users can still perform high-frequency basic operations such as powering on / off, switching modes, and adjusting temperature using natural language. If the matching rate is less than a preset threshold, the detected data is uploaded to the cloud for analysis, achieving intelligent data splitting between local and cloud processing. This significantly reduces the number of cloud inference iterations, lowers server bandwidth and computing power consumption, and ensures timely response of smart home appliances, thereby improving the user experience. Detailed explanations follow.
[0029] Example 1 Please see Figure 1 , 2 , Figure 1 This is a schematic diagram of a system architecture for hybrid device control based on a large language model, as disclosed in an embodiment of the present invention. Figure 2 This is a flowchart illustrating a method for implementing hybrid device control based on a large language model, as disclosed in an embodiment of the present invention. Figure 1 , 2 The described method can be applied to any smart home appliance in a smart home scenario. This smart home appliance can be any device in the smart home scenario that involves a large voice language model, such as a smart health pot, smart air fryer, smart oven, smart steam oven, smart rice cooker, smart pressure cooker, smart water dispenser, etc. Figure 1 and Figure 2 Example 1 will be described as follows: Figure 2 As shown, the method may include the following operations: 101. When voice data triggered by a target person targeting a smart home appliance is detected, the smart home appliance analyzes the voice data to obtain the corresponding target text, and analyzes the matching rate between the target text and the local control command library based on the local text matching model. The local control command library stores multiple control commands for controlling smart home appliances, and the local text matching model is a lightweight model.
[0030] In this embodiment of the invention, every executable action of the smart home appliance (such as power on / off, scheduled settings, mode menu switching, water temperature adjustment, timer, and keep-warm) is pre-encapsulated into a corresponding standardized FC (FunctionCalling) atomic operation interface. For any given action, there exists a unique corresponding standardized FC atomic operation function and standardized FC atomic operation interface, both built into the smart home appliance. The standardized FC atomic operation interface is used by the MCU controller of the smart home appliance to call the corresponding standardized FC atomic operation function to execute the corresponding action. By encapsulating all device actions into FC atomic operation functions and unifying the calling interface, it is convenient to add new functions and expand menus later, adapting to different models of smart home appliances, thus improving the versatility of this solution.
[0031] In this embodiment of the invention, optionally, the smart home appliance monitors the wake-up word triggered by the target person in real time. Upon detecting the wake-up word, the smart home appliance is activated, and voice data output by the target person to the smart home appliance is collected through a voice pickup device (such as a microphone). The target person is any individual in a smart home scenario who needs to control the smart home appliance.
[0032] 102. When the matching rate is greater than or equal to the preset matching rate, the first control instruction corresponding to the matching rate is selected from the local control instruction library, and the local atomic interface matching the first control instruction is called. Based on the first control instruction, the smart home appliance is controlled to perform the operation matching the first control instruction.
[0033] 103. When the matching rate is less than the preset matching rate, the target data is uploaded to the cloud. The target data includes voice data or target text.
[0034] In this embodiment of the invention, smart home appliances upload target data to a cloud-based Automatic Speech Recognition (ASR) module via an AI module.
[0035] 104. The cloud receives the target data, analyzes the target data based on the preset large language model, obtains the analysis results of the target data, and sends the analysis results to smart home appliances.
[0036] In this embodiment of the invention, after receiving the target data, the cloud-based text recognition module analyzes the target data using a preset Large Language Model (LLM). Furthermore, the preset LLM can also be embedded in the local chip of an AI module or electronic control chip, allowing for simplified model inference locally.
[0037] 105. The smart home appliances receive the analysis results and control the smart home appliances based on the analysis results.
[0038] It is evident that implementation Figure 1 The described method deploys a lightweight text matching model on smart home appliances and pre-encapsulates all executable actions of the device into standardized FC atomic operation interfaces. When voice data triggered by the user on the smart home appliance is detected, it is converted into text. The text matching model then analyzes the converted text against the local control command library to obtain the matching rate. If the matching rate is greater than or equal to a preset threshold, the corresponding FC atomic interface is directly called locally to control the smart home appliance for this offline execution. The entire inference and control are completed locally, without occupying the large language model resources in the cloud, and without going through the network round trip process of uploading audio to the cloud for inference and then issuing commands. This ensures the timely response of the smart home appliance even in the event of network latency, packet loss, or disconnection. Users can still complete high-frequency basic operations such as power on / off, mode switching, and temperature control adjustment through natural language. If the matching rate is less than the preset threshold, the detected data is uploaded to the cloud for analysis, achieving intelligent traffic splitting between local and cloud operations. This greatly reduces the number of cloud inference operations, lowers server bandwidth and computing power consumption, and ensures the timely response of the smart home appliance, thereby improving the user experience.
[0039] In this embodiment of the invention, optionally, the cloud analyzes the target data based on a preset large language model to obtain the analysis results of the target data, including: If contextual interaction data for this smart home appliance exists, the target data and contextual interaction data are analyzed based on a preset large language model to obtain the target user's intention to use the smart home appliance. When the target user's intention indicates that the target user needs to control smart home appliances, based on the preset large language model, the target data and contextual interaction data are analyzed to obtain a second control command for the smart home appliances, which is used as the analysis result of the target data. When the target user's intention indicates that they need to obtain audio responses (such as consultations, Q&A, or casual conversations) from smart home appliances, the system analyzes the target data and contextual interaction data based on a pre-set large language model to obtain response content tailored to that intention. Based on the response content, the system generates target audio that matches the response content, which serves as the analysis result of the target data.
[0040] In a further optional embodiment of the present invention, the intelligent home appliance device is controlled based on the analysis results, including: When the analysis result of the target data is the second control command, the smart home appliance calls the local atomic interface that matches the second control command to control the smart home appliance to execute the operation that matches the second control command; When the analysis result of the target data is the target audio, the smart home appliance plays the target audio to the target person through its corresponding voice player.
[0041] In this embodiment of the invention, when there is no contextual interaction data, subsequent usage intent, second control commands, or target audio analysis are performed solely based on the target data. Contextual interaction data refers to the voice data output by the target person to the smart home appliance before the current voice data of the target person is collected, as well as the feedback data from the smart home appliance. For example, if Xiao Zhang asked "What are the benefits of rose tea?" two minutes ago, the smart home appliance replied, "Rose tea has the effects of soothing the liver and relieving depression, promoting blood circulation and regulating menstruation."
[0042] In this embodiment of the invention, when the user expresses an intention to control a smart home appliance, such as Xiao Zhang outputting "Make me a warm cup of rose tea, not too hot," the system performs reasoning analysis on the target data and contextual interaction data based on a preset large language model to obtain a second control command for the smart home appliance. For example, the system reasoning analyzes that the rose tea corresponds to a flower tea mode, and "not too hot" corresponds to a temperature that should not be too high, setting it to 65℃. The system then generates corresponding mode control commands and temperature control commands, which are sent to the MCU controller of the smart home appliance via the AI module, controlling the smart home appliance to perform the corresponding operation.
[0043] In this embodiment of the invention, when the user expresses an intention to obtain an audio response from a smart home appliance, such as Xiao Zhang outputting "What temperature is suitable for brewing rose tea?", the system performs reasoning analysis on the target data and contextual interaction data based on a preset large language model to obtain the response content for the smart home appliance, such as "It is generally recommended to brew rose tea with water at 80~85℃ to avoid boiling water destroying the effective components and aroma of the flowers." The system then generates the target audio through a text-to-speech (TTS) module and sends it to the AI module of the smart home appliance, which then outputs the target audio through a speaker.
[0044] In this embodiment of the invention, the preset large language model is trained using the following method: Collect sample home appliance control training data, including various home appliance control phrases and their corresponding standardized FC commands, home appliance usage-related knowledge question-and-answer pairs, such as "How temperature should I brew rose tea?" → "Recommended 80~85℃", and complete dialogue sequences of contextual interaction, such as user asking about efficacy → home appliance replying → user issuing control commands; Based on the above sample home appliance control training data, a general LLM model is trained to obtain the required preset large language model.
[0045] As can be seen, after receiving data sent by smart home appliances, the cloud-based LLM in this embodiment of the invention performs multi-dimensional semantic analysis based on contextual interaction data to accurately identify the user's intent, such as whether it is device control or information acquisition. When the intent is to control the device, the cloud performs semantic understanding of the relevant data based on a preset large language model, infers precise control commands, and sends them to the smart home appliance. The device then executes the commands through a standardized FC atomic interface, ensuring that non-standard spoken language and complex intents can still be accurately parsed and operated. When the intent is to acquire information, the cloud generates natural language responses, which are then synthesized and played by the device. This expands the smart home appliance from a single control terminal into an intelligent interactive terminal with knowledge-based question answering and health consultation capabilities. While ensuring immediate response to high-frequency local control, it fully leverages the deep semantic understanding and contextual memory capabilities of the cloud-based large language model, effectively solving the technical shortcomings of traditional fixed-word matching schemes that cannot handle spoken language variations, complex intents, and consultation-type needs. This greatly improves the semantic generalization ability and user experience of smart home appliances in complex human-computer interaction scenarios.
[0046] In an optional embodiment, the method may further include the following steps: When the matching rate is less than the preset matching rate, the cloud generates instruction text that matches the voice data and stores the instruction text in the preset recommendation set; and determines whether the preset recommendation set meets the optimization conditions of the local text matching model. When the optimization conditions are met, the cloud performs optimization training on the local text matching model based on the instruction text in the preset recommendation set, obtains the optimized target text matching model, and updates the local text matching model in the smart home device based on the target text matching model.
[0047] In this optional embodiment, after obtaining the target text matching model, the cloud silently downloads the target text matching model to the AI module of the smart home device through Over-The-Air (OTA) technology to replace the original local text matching model and achieve model update.
[0048] As can be seen, implementing this optional embodiment automatically accumulates real spoken control command texts that users did not match in the cloud, constructs a recommendation set, and triggers incremental training and OTA silent upgrades of the local text matching model after reaching preset conditions. This eliminates the need for users to manually upgrade the local model, so that as the frequency of use of smart home appliances increases, the local model's ability to recognize personalized spoken language variations of users continues to improve. Unconventional commands that originally needed to be uploaded to the cloud for parsing are gradually accurately matched locally. This reduces the cloud inference load and network dependence, further improves the response efficiency and accuracy of smart home appliances, and further enhances the user experience.
[0049] In this optional embodiment, optionally, the cloud performs optimization training on the local text matching model based on the instruction text in a preset recommendation set to obtain an optimized target text matching model, including: For any instruction text in the preset recommendation set, determine the third control instruction that matches the instruction text and establish the association between the instruction text and its third control instruction; For any instruction text, the instruction text, the third control instruction of the instruction text, and the corresponding association relationship of the instruction text are determined as an optimized instruction text; Based on all optimized instruction texts, the local text matching model is optimized and trained to obtain the optimized target text matching model.
[0050] In this optional embodiment, the third control command is a standard FC control command.
[0051] As can be seen, implementing this optional embodiment constructs a triplet structure for each instruction text, consisting of the instruction text, the standard FC control instruction, and the relationship between the two. This transforms real user speech accumulated in the cloud into structured training samples, enabling incremental training of the local text matching model. Compared to training directly with the original text, this method clarifies the semantic mapping relationship between each spoken phrase and specific device operation. This allows the model to accurately learn the correspondence rules between personalized user expressions and standard control instructions, rather than merely relying on text similarity matching. This further improves the optimization accuracy and reliability of the local text matching model, thereby enhancing the accuracy and efficiency of the text matching model in recognizing spoken language variations, complex intentions, and non-standard sentence structures. Ultimately, this also helps to further improve the local response efficiency and accuracy of smart home appliances.
[0052] In this optional embodiment, optionally, the cloud determines whether the preset recommendation set meets the optimization conditions of the local text matching model, including: Calculate the target number of all instruction texts in the preset recommendation set, and determine whether the target number is greater than or equal to the preset text number; when it is determined that it is greater than or equal to the preset text number, determine that the current conditions of the preset recommendation set meet the optimization conditions of the local text matching model. or, Determine the collection duration corresponding to the preset recommendation set, and determine whether the collection duration is greater than or equal to the preset collection duration; if it is determined that it is greater than or equal to the preset collection duration, determine that the current conditions of the preset recommendation set meet the optimization conditions of the local text matching model.
[0053] In this optional embodiment, the cutoff time of the collection duration is determined by the time of the voice interaction data collected this time. Specifically, it can be understood that the cutoff time of the collection duration is the time of the voice interaction data collected this time, or the time when the interaction with the smart home appliance ends, or any time between the two times.
[0054] In this optional embodiment, optionally, when it is determined that the number of texts is less than a preset number, or when it is determined that the number of texts is less than a preset collection time, it is determined that the current conditions of the preset recommendation set do not meet the optimization conditions of the local text matching model.
[0055] As can be seen, implementing this optional embodiment improves the efficiency and accuracy of judging whether the preset recommendation set meets the optimization conditions of the local text matching model by setting dual threshold trigger conditions for the number of instruction texts and the collection duration, and flexibly determining the model optimization conditions with OR logic. This helps to increase the probability of timely optimization of the local text matching model. The quantity threshold ensures that the local text matching model training is triggered in time after high-frequency users accumulate enough samples, ensuring the sufficiency of the local text matching model iteration. The duration threshold makes up for the deficiency of insufficient sample size of low-frequency users, reducing the situation where they cannot optimize the local text matching model because they cannot reach the quantity threshold for a long time.
[0056] In another optional embodiment, the preset matching rate of the present invention can be a fixed value, such as 90%, or a dynamic value. When it is a dynamic value, the preset matching rate can be dynamically adjusted in the following ways: When a smart home appliance is started for the first time or completes an OTA model update, the cloud sets a basic preset matching rate for the smart home appliance. During the use of smart home appliances, at target intervals (e.g., 7 days), the cloud retrieves operation data for the smart home appliances within the target time period. Based on the operation data within the target time period, the number of times the smart home appliances are triggered by users, the number of local hits, and the number of times local hits are correctly executed are determined. Among them, local hits indicate target texts whose matching rate analyzed by the local text matching model is greater than or equal to the current preset matching rate. Local hits are correctly executed, indicating that the FC atomic operation corresponding to the matching rate greater than or equal to the current preset matching rate matches the user's true intent, that is, the smart home appliances have executed the operation expected by the user. The cloud divides the local hit count by the target count to get the hit rate, and divides the local hit count by the local hit count to get the execution success rate. The cloud compares the hit rate with the preset hit rate to obtain the hit comparison result, and compares the correct execution rate with the preset correct execution rate to obtain the correct execution comparison result. Based on the hit comparison result and the correct execution comparison result, the current preset matching rate is adjusted to obtain the adjusted preset matching rate, and the adjusted preset matching rate is sent to the smart home device, that is, it is built into the smart home device.
[0057] In this optional embodiment, the following example illustrates the process of "adjusting the current preset matching rate based on the hit comparison result and the correct execution comparison result to obtain the adjusted preset matching rate": Specifically, the preset hit rate is 60%, the preset correct execution rate is 95%, and the current preset matching rate is 88%. If the hit rate is 16%, which is less than the preset hit rate, and the correct execution rate is 97%, which is greater than the preset correct execution rate, then the current preset matching rate is too high, and it is adjusted down, for example, to 86%. After the current preset matching rate is reduced, subsequent matching rate analysis between the text and the local control instruction library is performed based on the new preset matching rate.
[0058] It should be noted that the current preset matching rate is dynamically adjusted according to the frequency of use of smart home appliances. During the adjustment process, when the absolute value of the difference between the hit rate and the preset hit rate, and the absolute value of the difference between the correct execution rate and the preset correct execution rate are all less than or equal to the preset values, such as 1%, then there is no need to continue adjusting the current preset matching rate. However, the analysis process of the hit rate and the correct execution rate is a continuous analysis process.
[0059] As can be seen, by introducing a dynamic adjustment mechanism for the preset matching rate, the implementation of this optional embodiment enables the local and cloud-based traffic splitting strategy of smart home appliances to adaptively optimize according to the actual user data, overcoming the technical shortcomings of fixed matching rates being unable to adapt to different user habits and changes in recognition capabilities at various stages of model iteration. Specifically, the cloud system counts the total number of user commands, the number of local hits, and the number of correctly executed local hits within a target time period at preset intervals. It calculates the hit rate and correct execution rate, comparing them to thresholds. When the correct execution rate exceeds the preset correct execution rate but the hit rate is lower, it indicates a high matching rate, and the cloud automatically lowers the matching rate to allow more commands to be executed locally, reducing cloud inference and network dependence. Conversely, when the hit rate exceeds the preset hit rate but the correct execution rate is lower, it indicates a low matching rate, and the cloud automatically raises the matching rate to reduce the risk of false hits. When the absolute value of the difference between both metrics and the preset values does not exceed the preset threshold, the matching rate converges to a stable optimal range, and the cloud stops adjusting. This allows the matching rate to dynamically converge to the optimal value based on actual user usage data without manual intervention. This maximizes the local hit rate while ensuring local execution reliability, effectively reducing cloud computing power consumption and response latency, and improving the adaptability and user experience of the smart home appliance voice control system in complex usage scenarios.
[0060] Example 2 Please see Figure 3 , Figure 3 This is a flowchart illustrating another method for implementing hybrid device control based on a large language model, as disclosed in an embodiment of the present invention. Figure 3 The described method can be applied to any smart home appliance in a smart home scenario. This smart home appliance can be any device in the smart home scenario that involves a large voice language model, such as a smart health pot, smart air fryer, smart oven, smart steam oven, smart rice cooker, smart pressure cooker, smart water dispenser, etc. Figure 3 As shown, the method may include the following operations: 201. When voice data triggered by a target person targeting a smart home appliance is detected, the smart home appliance analyzes the voice data to obtain the corresponding target text, and analyzes the matching rate between the target text and the local control command library based on the local text matching model. The local control command library stores multiple control commands for controlling smart home appliances, and the local text matching model is a lightweight model.
[0061] 202. When the matching rate is greater than or equal to the preset matching rate, the first control instruction corresponding to the matching rate is selected from the local control instruction library, and the local atomic interface matching the first control instruction is called. Based on the first control instruction, the smart home appliance is controlled to perform the operation matching the first control instruction.
[0062] 203. When the matching rate is less than the preset matching rate, the target data is uploaded to the cloud. The target data includes voice data or target text.
[0063] 204. The cloud receives the target data, analyzes the target data based on the preset large language model, obtains the analysis results of the target data, and sends the analysis results to smart home appliances.
[0064] 205. The smart home appliances receive the analysis results and control the smart home appliances based on the analysis results.
[0065] It should be noted that for other related descriptions of steps 201-205, please refer to the detailed description of steps 101-105 in Embodiment 1, which will not be repeated here.
[0066] 206. For each time the target user uses a smart home appliance, the cloud acquires usage data for the smart home appliance. Based on a preset large language model, the cloud performs usage preference analysis on all usage data to obtain the target user's usage preference data for smart home appliances.
[0067] In this embodiment of the invention, optionally, the usage data for each use of the smart home appliance includes one or more of the following: records of the actions performed on the smart home appliance (the type of FC atomic operation called each time (such as power on / off, mode switching, temperature setting, timer setting, start / stop operation, etc.)), operation parameters (specific parameter values (such as mode = herbal tea, temperature = 65℃, timer = 30 minutes)), operation time, voice data, execution results (such as whether the operation was successfully executed, device feedback status), and contextual interaction data. Specifically, all usage data is subjected to pattern analysis to obtain usage data for multiple target modes, such as usage data for herbal tea mode, usage data for boiling water mode, etc.; based on a preset large language model, the usage data of all target modes are sequentially subjected to dimension-by-dimensional semantic reasoning analysis, specifically including: performing pattern preference analysis, parameter preference analysis, usage time period preference analysis, seasonal preference analysis, and voice interaction preference analysis to obtain the corresponding preference analysis results, which are used as usage preference data.
[0068] Analyzing the various preference analyses above, for example, the flower tea mode is used most frequently, and the usage scenario is concentrated in the afternoon, suggesting that the user is an afternoon tea enthusiast, with flower tea being their primary usage scenario; the flower tea mode has the highest temperature selection of 65℃, indicating that the user has a clear temperature preference for flower tea; the medicinal cuisine mode has the highest temperature selection of 120 minutes, indicating that the user is accustomed to long-term stewing; the keep-warm mode has an almost fixed temperature, which is consistent with daily drinking temperature habits; mapping all operations to a 24-hour timeline by timestamps reveals three obvious high-frequency time clusters: 08:00-09:00 → water boiling mode (for breakfast tea / coffee), 14:00 -15:00 → Herbal Tea Mode (Afternoon Tea), 21:00-22:00 → Keep Warm Mode (Keep Warm Before Bed); Grouping operation records by month, it was found that the herbal tea mode accounted for the highest proportion in summer (June-August) (65%), while the medicinal diet mode increased significantly in winter (December-February) (from an average of 10% to 35%), indicating that users have seasonal usage preferences; Extracting commonly used expressions from voice data, it was found that users tend to use colloquial phrases such as "help me," "get a cup," and "get some," and temperature modifiers such as "don't be too hot" and "warm" appear frequently, indicating that users are accustomed to using vague descriptions rather than precise parameters.
[0069] 207. Based on the target user's usage preference data, the cloud platform constructs a user profile for smart home appliances; based on the target user's usage preference data, it infers the target user's preferred control commands for smart home appliances.
[0070] 208. Establish a cloud-based association control relationship between the target user's usage profile and preference control instructions; the association control relationship corresponding to the target user serves as the basis for controlling the smart home appliances when the target user uses them subsequently.
[0071] In this embodiment of the invention, once an association control relationship is established, the relationship can be stored in the cloud or simultaneously embedded in smart home appliances. Furthermore, the preset large language model can be optimized based on the association control relationship corresponding to the target user, resulting in an optimized preset large language model that replaces the current preset large language model, thereby improving the large language model's ability to understand the personalized needs of specific user groups.
[0072] It is evident that implementation Figure 3The described method deploys a lightweight text matching model on smart home appliances and pre-encapsulates all executable actions of the device into standardized FC atomic operation interfaces. When voice data triggered by the user on the smart home appliance is detected, it is converted into text. The text matching model then analyzes the converted text against the local control command library to obtain the matching rate. If the matching rate is greater than or equal to a preset threshold, the corresponding FC atomic interface is directly called locally to control the smart home appliance for this offline execution. The entire inference and control are completed locally, without occupying the large language model resources in the cloud, and without going through the network round trip process of uploading audio to the cloud for inference and then issuing commands. This ensures the timely response of the smart home appliance even in the event of network latency, packet loss, or disconnection. Users can still complete high-frequency basic operations such as power on / off, mode switching, and temperature control adjustment through natural language. If the matching rate is less than the preset threshold, the detected data is uploaded to the cloud for analysis, achieving intelligent traffic splitting between local and cloud operations. This greatly reduces the number of cloud inference operations, lowers server bandwidth and computing power consumption, and ensures the timely response of the smart home appliance, thereby improving the user experience. Furthermore, by using cloud-based LLM to continuously analyze user preferences based on multiple usage data of smart home appliances, personalized user profiles are constructed, and preferred control commands are inferred. This establishes a correlation between the profile and the preferred commands, enabling the cloud to proactively infer user intent and issue appropriate control commands based on this correlation in subsequent interactions, even if the local model misses the exact command. This allows smart home appliances to provide personalized adaptive control strategies for different users, and by embedding the correlation within the smart home appliances, the accuracy and flexibility of user-smart home appliance interactions are further improved. This enhances the control accuracy and efficiency of smart home appliances, ultimately improving the user experience.
[0073] Example 3 Please see Figure 4 , Figure 4 This is a schematic diagram of the structure of a system for implementing hybrid control of devices based on a large language model, as disclosed in an embodiment of the present invention. Figure 4 The described system can be applied to any smart home appliance in a smart home scenario. This smart home appliance can be any device in the smart home scenario that involves a large voice language model, such as a smart health pot, smart air fryer, smart oven, smart steam oven, smart rice cooker, smart pressure cooker, smart water dispenser, etc. Figure 4 As shown, the system controls smart home appliances and a cloud that communicates with the smart home appliances. The smart home appliances include a first analysis module 301, a filtering module 302, a control module 303, and a first communication module 304. The cloud includes a second communication module 305 and a second analysis module 306. The first analysis module 301 is used to analyze the voice data when the target person triggers voice data on the smart home appliance, obtain the corresponding target text, and analyze the matching rate between the target text and the local control command library based on the local text matching model. The local control command library stores multiple control commands for controlling smart home appliances, and the local text matching model is a lightweight model.
[0074] The filtering module 302 is used to filter out the first control instruction corresponding to the matching rate from the local control instruction library when the matching rate is greater than or equal to the preset matching rate.
[0075] The control module 303 is used to call the local atomic interface that matches the first control instruction, and control the smart home appliance to perform the operation that matches the first control instruction based on the first control instruction.
[0076] The first communication module 304 is used to upload target data to the cloud when the matching rate is less than the preset matching rate. The target data includes voice data or target text.
[0077] The second communication module 305 is used to receive target data.
[0078] The second analysis module 306 is used to analyze the target data based on a preset large language model and obtain the analysis results of the target data.
[0079] The second communication module 305 is also used to send the analysis results to smart home appliances.
[0080] The first communication module 304 is also used to receive analysis results.
[0081] The control module 303 is also used to control smart home appliances based on the analysis results.
[0082] It is evident that implementation Figure 4The described system deploys a lightweight text matching model on smart home appliances and pre-encapsulates all executable actions of the devices into standardized FC atomic operation interfaces. When voice data triggered by the user on the smart home appliance is detected, it is converted into text. The text matching model then analyzes the converted text against the local control command library to obtain the matching rate. If the matching rate is greater than or equal to a preset threshold, the corresponding FC atomic interface is directly called locally to control the smart home appliance for this offline execution. The entire inference and control are completed locally, without occupying the large language model resources in the cloud, and without going through the network round trip process of uploading audio to the cloud for inference and then issuing commands. This ensures the timely response of the smart home appliance even in the event of network latency, packet loss, or disconnection. Users can still complete high-frequency basic operations such as powering on / off, switching modes, and adjusting temperature through natural language. If the matching rate is less than the preset threshold, the detected data is uploaded to the cloud for analysis, achieving intelligent traffic splitting between local and cloud operations. This greatly reduces the number of cloud inference operations, lowers server bandwidth and computing power consumption, and ensures the timely response of the smart home appliance, thereby improving the user experience.
[0083] In this embodiment of the invention, optionally, the second analysis module 306 analyzes the target data based on a preset large language model to obtain the analysis results of the target data in the following specific ways: If contextual interaction data for this smart home appliance exists, the target data and contextual interaction data are analyzed based on a preset large language model to obtain the target user's intention to use the smart home appliance. When the target user's intention indicates that the target user needs to control smart home appliances, based on the preset large language model, the target data and contextual interaction data are analyzed to obtain a second control command for the smart home appliances, which is used as the analysis result of the target data. When the target user's intention indicates that they need to obtain an audio response from a smart home appliance, the system analyzes the target data and contextual interaction data based on a pre-set large language model to obtain the response content for that intention. Based on the response content, the system generates a target audio that matches the response content, which serves as the analysis result of the target data.
[0084] In a further optional embodiment of the present invention, the control module 303 controls the smart home appliances based on the analysis results in the following ways: When the analysis result of the target data is the second control command, the smart home appliance calls the local atomic interface that matches the second control command to control the smart home appliance to execute the operation that matches the second control command; When the analysis result of the target data is the target audio, the smart home appliance plays the target audio to the target person through its corresponding voice player.
[0085] It is evident that implementation Figure 4 The described system also enables cloud-based LLM (Limited Language Modeling) to perform multi-dimensional semantic analysis after receiving data from smart home appliances, combining contextual interaction data to accurately identify the user's intent, such as whether it is device control or information retrieval. When the intent is to control the device, the cloud performs semantic understanding of the relevant data based on a preset large language model, infers precise control commands, and issues them to the smart home appliance. The device then executes the commands through a standardized FC (Functional Control Interface) atomic interface, ensuring that non-standard spoken language and complex intents can still be accurately parsed and operated. When the intent is to retrieve information, the cloud generates natural language responses, which are then synthesized and played by the device. This expands smart home appliances from single control terminals into intelligent interactive terminals with knowledge-based question answering and health consultation capabilities. While ensuring immediate response to high-frequency local control, it fully leverages the deep semantic understanding and contextual memory capabilities of the cloud-based large language model, effectively solving the technical shortcomings of traditional fixed-word matching schemes that cannot handle spoken language variations, complex intents, and consultation-type needs. This significantly improves the semantic generalization ability and user experience of smart home appliances in complex human-computer interaction scenarios.
[0086] In an optional embodiment, such as Figure 5 As shown, the cloud can also include: The generation module 307 is used to generate instruction text that matches the voice data when the matching rate is less than the preset matching rate, and to store the instruction text in the preset recommendation set; The judgment module 308 is used to determine whether the preset recommendation set meets the optimization conditions of the local text matching model; The optimization module 309 is used to perform optimization training operations on the local text matching model based on the instruction text in the preset recommendation set when it is determined that the optimization conditions are met, to obtain the optimized target text matching model, and to perform update operations on the local text matching model in the smart home appliance based on the target text matching model.
[0087] It is evident that implementation Figure 5 The described system automatically accumulates real spoken control commands that users did not match in the cloud, builds a recommendation set, and triggers incremental training and OTA silent upgrades of the local text matching model after meeting preset conditions. This eliminates the need for users to manually upgrade the local model, so that as the frequency of use of smart home appliances increases, the local model's ability to recognize personalized spoken language variations of users continues to improve. Unconventional commands that originally needed to be uploaded to the cloud for parsing are gradually accurately matched locally. This reduces the cloud inference load and network dependence, further improves the response efficiency and accuracy of smart home appliances, and further enhances the user experience.
[0088] In this optional embodiment, the optimization module 309 performs optimization training operations on the local text matching model based on the instruction text in the preset recommendation set to obtain the optimized target text matching model. The specific methods include: For any instruction text in the preset recommendation set, determine the third control instruction that matches the instruction text and establish the association between the instruction text and its third control instruction; For any instruction text, the instruction text, the third control instruction of the instruction text, and the corresponding association relationship of the instruction text are determined as an optimized instruction text; Based on all optimized instruction texts, the local text matching model is optimized and trained to obtain the optimized target text matching model.
[0089] It is evident that implementation Figure 5 The described system can also construct a triplet structure for each instruction text, consisting of the instruction text, standard FC control instructions, and their relationship. This transforms real user speech accumulated in the cloud into structured training samples for incremental training of the local text matching model. Compared to training directly with the original text, this method clarifies the semantic mapping relationship between each spoken word and specific device operation. This enables the model to accurately learn the correspondence rules between personalized user expressions and standard control instructions, rather than simply relying on text similarity matching. This further improves the optimization accuracy and reliability of the local text matching model, thereby enhancing the accuracy and efficiency of the text matching model in recognizing spoken language variations, complex intentions, and non-standard sentence structures. Ultimately, this also helps to improve the local response efficiency and accuracy of smart home appliances.
[0090] In this optional embodiment, the specific method by which the judging module 308 judges whether the preset recommendation set meets the optimization conditions of the local text matching model includes: Calculate the target number of all instruction texts in the preset recommendation set, and determine whether the target number is greater than or equal to the preset text number; when it is determined that it is greater than or equal to the preset text number, determine that the current conditions of the preset recommendation set meet the optimization conditions of the local text matching model. or, Determine the collection duration corresponding to the preset recommendation set, and determine whether the collection duration is greater than or equal to the preset collection duration. The end time of the collection duration is determined by the time of the voice interaction data collected this time. When it is determined that the collection duration is greater than or equal to the preset collection duration, it is determined that the current conditions of the preset recommendation set meet the optimization conditions of the local text matching model.
[0091] It is evident that implementation Figure 5The described system can also improve the efficiency and accuracy of judging whether the preset recommendation set meets the optimization conditions of the local text matching model by setting dual thresholds for the number of instruction texts and the collection duration, and flexibly determining the model optimization conditions with OR logic. This is conducive to increasing the probability of timely optimization of the local text matching model. The quantity threshold ensures that the local text matching model training is triggered in time after high-frequency users accumulate enough samples, ensuring the sufficiency of local text matching model iteration. The duration threshold makes up for the deficiency of insufficient sample size of low-frequency users, reducing the situation where they cannot optimize the local text matching model due to the inability to reach the quantity threshold for a long time.
[0092] In another alternative embodiment, such as Figure 5 As shown, the cloud can also include: The acquisition module 310 is used to acquire usage data of smart home appliances every time a target person uses them. The second analysis module 306 is also used to perform usage preference analysis on all usage data based on a preset large language model to obtain the target user's usage preference data for smart home appliances. Module 311 is used to build a user profile for smart home appliances based on the user's usage preference data. The second analysis module 306 is also used to infer the target user's preferred control instructions for smart home appliances based on the target user's usage preference data. The construction module 311 is also used to establish the association control relationship between the user profile and preference control instructions of the target user; wherein, the association control relationship corresponding to the target user serves as the basis for the control of the smart home appliances when the target user uses the smart home appliances in the future.
[0093] It is evident that implementation Figure 5 The described system can also continuously analyze user preferences based on multiple usage data of smart home appliances through cloud-based LLM, build personalized user profiles, and infer preferred control commands. This establishes a correlation between the profile and the preferred commands, enabling the cloud to proactively infer user intent and issue appropriate control commands based on this correlation in subsequent interactions, even if the local model misses the exact command. This allows smart home appliances to provide personalized adaptive control strategies for different users, and the embedded correlation further improves the accuracy and flexibility of user-smart home appliance interactions, thereby enhancing the control accuracy and efficiency of smart home appliances and ultimately improving the user experience.
[0094] Example 4 Please see Figure 6 , Figure 6This is a schematic diagram of the structure of an interactive terminal disclosed in an embodiment of the present invention. Figure 6 The described interactive terminal can be applied to any smart home scenario involving voice interaction. The interactive terminal includes smart home appliances or the cloud. The smart home appliances can be any device in the smart home scenario that involves a large voice language model, such as a smart health pot, smart air fryer, smart oven, smart steam oven, smart rice cooker, smart pressure cooker, smart water dispenser, etc. Figure 6 As shown, the interactive terminal may include: Memory 401 storing executable program code; Processor 402 coupled to memory 401; The processor 402 calls the executable program code stored in the memory 401 to execute the steps performed by the smart home appliance or the cloud in any of the methods for implementing hybrid device control based on a large language model disclosed in Embodiment 1 or Embodiment 2 of the present invention.
[0095] Example 5 This invention discloses a computer storage medium storing computer instructions. When these computer instructions are invoked, they are used to execute some or all of the steps in any of the methods for implementing hybrid device control based on a large language model as disclosed in Embodiment 1 or Embodiment 2 of this invention.
[0096] The system embodiments described above are merely illustrative. The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0097] Through the detailed description of the above embodiments, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, including read-only memory (ROM), random access memory (RAM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), one-time programmable read-only memory (OTPROM), electrically-erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, disk storage, magnetic tape storage, or any other computer-readable medium that can be used to carry or store data.
[0098] Finally, it should be noted that the above embodiments are merely preferred embodiments of the present invention and are only used to illustrate the technical solutions of the present invention, not to limit them. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for implementing hybrid control of equipment based on a large language model, characterized in that, The method is applied to a hybrid control system, which includes smart home appliances and a cloud communicationally connected to the smart home appliances. The method includes: When voice data triggered by a target person targeting the smart home appliance is detected, the smart home appliance analyzes the voice data to obtain the corresponding target text. Based on a local text matching model, the matching rate between the target text and a local control command library is analyzed. The local control command library stores multiple control commands for controlling the smart home appliance, and the local text matching model is a lightweight model. When the matching rate is greater than or equal to a preset matching rate, a first control command corresponding to the matching rate is selected from the local control command library, and a local atomic interface matching the first control command is called. Based on the first control command, the smart home appliance is controlled to perform an operation matching the first control command. When the matching rate is less than the preset matching rate, the target data, including the voice data or the target text, is uploaded to the cloud. The cloud receives the target data, analyzes the target data based on a preset large language model, obtains the analysis results of the target data, and sends the analysis results to the smart home appliance. The smart home appliance receives the analysis results and controls the smart home appliance based on the analysis results.
2. The method according to claim 1, characterized in that, The cloud-based system analyzes the target data based on a preset large language model to obtain the analysis results of the target data, including: If contextual interaction data for the smart home appliance exists, the target data and the contextual interaction data are analyzed based on a preset large language model to obtain the target user's intention to use the smart home appliance. When the target user's intention indicates that the target user needs to control the smart home appliance, the target data and the context interaction data are analyzed based on the preset large language model to obtain a second control command for the smart home appliance, which is used as the analysis result of the target data; When the target user's intention indicates that the target user needs to obtain an audio response from the smart home appliance, the target data and the contextual interaction data are analyzed based on the preset large language model to obtain the response content for the intention. Based on the response content, a target audio that matches the response content is generated as the analysis result of the target data.
3. The method according to claim 2, characterized in that, Based on the analysis results, the smart home appliance is controlled, including: When the analysis result of the target data is the second control command, the smart home appliance calls the local atomic interface that matches the second control command to control the smart home appliance to perform the operation that matches the second control command; When the analysis result of the target data is the target audio, the smart home appliance plays the target audio to the target person through its corresponding voice player.
4. The method according to any one of claims 1-3, characterized in that, The method further includes: When the matching rate is less than the preset matching rate, the cloud generates instruction text that matches the voice data and stores the instruction text in a preset recommendation set; and determines whether the preset recommendation set meets the optimization conditions of the local text matching model. When the optimization conditions are met, the cloud performs optimization training on the local text matching model based on the instruction text in the preset recommendation set to obtain the optimized target text matching model, and performs an update operation on the local text matching model in the smart home appliance based on the target text matching model.
5. The method according to claim 4, characterized in that, The cloud platform performs optimization training on the local text matching model based on the instruction text in the preset recommendation set, to obtain an optimized target text matching model, including: For any instruction text in the preset recommendation set, determine the third control instruction that matches the instruction text, and establish the association between the instruction text and the third control instruction. For any of the aforementioned instruction texts, the instruction text, the third control instruction of the instruction text, and the corresponding association relationship of the instruction text are determined as an optimized instruction text; Based on all the optimized instruction texts, the local text matching model is optimized and trained to obtain the optimized target text matching model.
6. The method according to claim 4, characterized in that, The cloud-based determination of whether the preset recommendation set meets the optimization conditions of the local text matching model includes: Calculate the target number of all the instruction texts in the preset recommendation set, and determine whether the target number is greater than or equal to the preset number of texts; when it is determined that the target number is greater than or equal to the preset number of texts, determine that the current condition of the preset recommendation set satisfies the optimization condition of the local text matching model; or, The collection duration corresponding to the preset recommendation set is determined, and it is determined whether the collection duration is greater than or equal to the preset collection duration. The cutoff time of the collection duration is determined by the time of the voice interaction data collected this time. When it is determined that the collection duration is greater than or equal to the preset collection duration, it is determined that the current conditions of the preset recommendation set meet the optimization conditions of the local text matching model.
7. The method according to claims 1, 2, 3, 5 and 6, characterized in that, The method further includes: For each time the target user uses the smart home appliance, the cloud acquires usage data for the smart home appliance, and performs usage preference analysis on all the usage data based on the preset large language model to obtain the target user's usage preference data for the smart home appliance; The cloud platform constructs a user profile for the target user regarding the smart home appliances based on the target user's usage preference data; and infers preferred control commands for the smart home appliances based on the target user's usage preference data. The cloud establishes an association control relationship between the target user's usage profile and preference control instructions; wherein, the association control relationship corresponding to the target user serves as the basis for the target user's subsequent control of the smart home appliance.
8. A system for hybrid control of devices based on a large language model, characterized in that, The system includes smart home appliances and a cloud communication connection to the smart home appliances. The smart home appliances include a first analysis module, a filtering module, a control module, and a first communication module. The cloud includes a second communication module and a second analysis module, wherein: The first analysis module is used to analyze the voice data triggered by the target person in relation to the smart home appliance when the voice data is detected, obtain the corresponding target text, and analyze the matching rate between the target text and the local control command library based on the local text matching model. The local control command library stores multiple control commands for controlling the smart home appliance, and the local text matching model is a lightweight model. The filtering module is used to filter out the first control instruction corresponding to the matching rate from the local control instruction library when the matching rate is greater than or equal to the preset matching rate. The control module is used to call a local atomic interface that matches the first control instruction, and control the smart home appliance to perform an operation that matches the first control instruction based on the first control instruction; The first communication module is used to upload target data to the cloud when the matching rate is less than the preset matching rate, wherein the target data includes the voice data or the target text; The second communication module is used to receive the target data; The second analysis module is used to analyze the target data based on a preset large language model to obtain the analysis results of the target data; The second communication module is also used to send the analysis results to the smart home appliance; The first communication module is also used to receive the analysis results; The control module is also used to control the smart home appliances based on the analysis results.
9. An interactive terminal, said interactive terminal comprising a smart home appliance or a cloud, characterized in that, The interactive terminal includes: Memory containing executable program code; A processor coupled to the memory; The processor calls the executable program code stored in the memory to execute the steps performed by the smart home appliance or the cloud in the method for implementing hybrid device control based on a large language model as described in any one of claims 1-7.
10. A computer storage medium, characterized in that, The computer storage medium stores computer instructions, which, when invoked, are used to execute the method for implementing hybrid device control based on a large language model as described in any one of claims 1-7.
