Control method and system of smart home appliance device
By verifying user identifiers, parsing control requests, querying object model information, and using a large language model to output device control commands, combined with identity authentication and access control, the security and user experience issues of smart home appliances are solved, achieving higher security and stability.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HANGZHOU ROBAM APPLIANCES CO LTD
- Filing Date
- 2026-05-08
- Publication Date
- 2026-06-05
AI Technical Summary
Existing smart home appliances lack effective client authentication mechanisms and access control, posing a risk of data leakage or unauthorized control, which affects the security of the overall smart home system and the protection of user data.
By receiving control requests from user terminals, verifying the legitimacy of user identifiers, calling the intelligent agent configured by smart home appliances to parse control requests, querying the object model information of target home appliances, and using a large language model to output device control commands, the system combines long-term and window memory mechanisms to improve interaction efficiency, and uses the ByteBuddyAgent tool for strict identity authentication and access control.
It effectively reduces the risk of unauthorized control of smart home appliances, improves the security and stability of the control system, and enhances user experience, device operation flexibility, and intelligence.
Smart Images

Figure CN122151575A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the technical field of large language models, and in particular to a control method and system for intelligent home appliances. Background Technology
[0002] With the rapid development of artificial intelligence and the Internet of Things (IoT) technologies, smart home appliances are gradually integrating into people's daily lives. More and more smart home appliances are equipped with network connectivity, supporting remote control and intelligent interaction. For example, they can be operated through intelligent question-and-answer mechanisms, significantly improving the level of intelligence in the kitchen.
[0003] However, security is paramount during the interconnected interaction of IoT devices. Existing smart device platforms often present security risks when exposing their interfaces, particularly smart home appliances which lack effective client authentication mechanisms and access control. This poses a significant risk of data leakage or unauthorized control, severely challenging the security of the overall smart home system and the protection of user data. Summary of the Invention
[0004] In view of this, the purpose of the present invention is to provide a control method and system for intelligent home appliances to alleviate the above-mentioned technical problems.
[0005] In a first aspect, embodiments of the present invention provide a control method for smart home appliances, the method comprising: in response to receiving a control request sent by a user terminal, extracting a user identifier carried in the control request; if verifying that the user corresponding to the user identifier is a legitimate user, invoking an intelligent agent configured in the smart home appliance to parse the control request, obtaining a user intent contained in the control request, and at least one target home appliance corresponding to the user intent; querying object model information corresponding to each target home appliance; inputting the object model information and the user intent into a preset large language model, and outputting a device control command corresponding to each target home appliance through the large language model; and sending the device control command to the corresponding target home appliance to control the target home appliance.
[0006] In conjunction with the first aspect, the present invention provides a first possible implementation of the first aspect, wherein the step of querying the object model information corresponding to each of the target home appliances includes: calling a model context protocol server and querying the object model information corresponding to at least one of the target home appliances through the model context protocol server.
[0007] In conjunction with the first possible implementation of the first aspect, this embodiment of the invention provides a second possible implementation of the first aspect, wherein the method further includes: verifying whether the user identifier has the authority to control the target home appliance before sending the device control command to at least one of the target home appliances; if so, sending the device control command to the target home appliance.
[0008] In conjunction with the first possible implementation of the first aspect, this embodiment of the invention provides a third possible implementation of the first aspect, wherein the step of querying the object model information corresponding to each of the target home appliances includes: querying simplified object model information corresponding to each of the target home appliances, the simplified object model information including preset attribute fields and control fields; the step of inputting the object model information and the user intent into a preset large language model includes: adding descriptive information to the attribute fields and control fields of the simplified object model information, and then inputting the simplified object model information, the descriptive information and the user intent into the preset large language model.
[0009] In conjunction with the first aspect, this invention provides a fourth possible implementation of the first aspect, wherein the aforementioned smart home appliance communicates with a backend server; the smart agent is a smart agent running on the backend server; the step of calling the smart agent configured on the smart home appliance to parse the control request includes: calling the smart agent running on the backend server that communicates with the smart home appliance, so as to parse the control request through the smart agent running on the backend server.
[0010] In conjunction with the first aspect, or the fourth possible implementation of the first aspect, this embodiment of the invention provides a fifth possible implementation of the first aspect, wherein the step of calling the intelligent agent configured by the intelligent home appliance to parse the control request includes: obtaining memory information through the intelligent agent; wherein the memory information includes window memory information and long-term memory information; parsing the control request based on the memory information to obtain the user intent and determining at least one target home appliance.
[0011] In conjunction with the first aspect, this embodiment of the invention provides a sixth possible implementation of the first aspect, wherein the above method further includes: statistically analyzing the understanding accuracy of the object model corresponding to the large language model based on the interaction records of the large language model; if the understanding accuracy of the object model corresponding to the large language model is lower than a preset accuracy threshold, then switching the large language model according to a preset adjustment strategy.
[0012] In conjunction with the sixth possible implementation of the first aspect, this embodiment of the invention provides a seventh possible implementation of the first aspect, wherein the step of statistically analyzing the understanding accuracy of the object model corresponding to the large language model based on the interaction records of the large language model includes: calculating the accuracy score of the large language model based on the interaction records of the large language model, wherein the accuracy score is used to characterize the understanding accuracy of the large language model of the object model; if the accuracy score is lower than a preset score threshold, then it is determined that the understanding accuracy of the object model corresponding to the large language model is lower than the preset accuracy threshold.
[0013] In conjunction with the seventh possible implementation of the first aspect, this embodiment of the invention provides an eighth possible implementation of the first aspect, wherein the method further includes: determining the score range to which the accuracy score belongs; determining the level of object model comprehension accuracy of the large language model based on the score range, the level being used to optimize the large language model.
[0014] Secondly, embodiments of the present invention also provide a control system for a smart home appliance, used to execute the control method for the smart home appliance described in the first aspect; the control system includes a smart home appliance and a back-end server; wherein the smart home appliance is configured with an intelligent agent, and both the smart home appliance and the back-end server are used to establish communication with a user terminal, and the back-end server is also used to establish communication with the smart home appliance.
[0015] The embodiments of the present invention bring the following beneficial effects: This invention provides a control method and system for smart home appliances. Upon receiving a control request from a user terminal, the system extracts the user identifier carried in the control request and verifies the user. If the user identifier is verified as a legitimate user, the system invokes the intelligent agent configured in the smart home appliance to parse the control request, obtaining the user intent contained in the control request and at least one target home appliance corresponding to the user intent. The system then queries the object model information corresponding to each target home appliance, inputs the object model information and the user intent into a preset large language model, outputs the device control command corresponding to each target home appliance through the large language model, and sends the device control command to the corresponding target home appliance to control it. Because the parsing process of the control request is performed after verifying that the user identifier is a legitimate user, the risk of unauthorized control of smart home appliances can be effectively reduced, thereby improving the security and stability of the entire control system.
[0016] Other features and advantages of the invention will be set forth in the description which follows, and will be apparent in part from the description, or may be learned by practicing the invention. The objects and other advantages of the invention are realized and obtained in accordance with the structures particularly pointed out in the description, claims and drawings.
[0017] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description
[0018] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0019] Figure 1 A flowchart illustrating a control method for a smart home appliance provided in an embodiment of the present invention; Figure 2 A control timing flowchart for a smart home appliance is provided as an embodiment of the present invention. Figure 3 This is a schematic diagram of the architecture of a control device for a smart home appliance provided in an embodiment of the present invention; Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation
[0020] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, 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.
[0021] Traditional smart home appliances are mostly controlled through human-computer interaction methods based on pre-set commands and semantic training. They haven't yet effectively supported flexible natural language control using large models, which not only limits the device's operational flexibility but also fails to provide a more natural and fluid user experience. Especially when users obtain cooking instructions or device operation commands through intelligent question-and-answer services, such as various AI platforms, these commands are often general or abstract text descriptions, lacking direct executableness or device compatibility. In such cases, traditional platform processing mechanisms typically require users to perform secondary operations manually or develop specialized conversion tools or adaptation modules, a complex and inflexible process that hinders users from achieving a truly intelligent operating experience. Furthermore, most existing smart home appliances lack effective mechanisms for combining long-term and short-term memory, failing to maintain and understand users' historical usage habits or device usage environments. This results in insufficient fluency in intelligent dialogue interaction, often requiring users to repeatedly provide similar information or context, significantly reducing interaction efficiency. Moreover, during the network interaction of smart home appliances, there is a lack of effective identity authentication mechanisms and access control, posing risks of data leakage or unauthorized control, and even posing serious challenges to the security of the overall control system and the protection of user data.
[0022] Based on this, the control method and system for smart home appliances provided by the embodiments of the present invention can improve user experience and intelligence level while meeting the market's urgent demand for higher security, better compatibility and smarter operation experience.
[0023] To facilitate understanding of this embodiment, a control method for a smart home appliance disclosed in this embodiment of the invention will first be described in detail.
[0024] In one possible implementation, this invention provides a control method for smart home appliances. Specifically, the control method provided in this embodiment can be executed within a control system of the smart home appliance. Typically, the control system includes the smart home appliance and a backend server. The smart home appliance is equipped with an intelligent agent, and both the smart home appliance and the backend server are used to establish communication with a user terminal. The backend server is also used to establish communication with the smart home appliance. The backend server, also known as the cloud, provides device control services and model invocation services. The smart home appliance refers to a smart device with network connectivity, and the user terminal is a smart terminal used by the user. This smart terminal typically has an application program (APP) corresponding to the smart home appliance installed, allowing the user to control the smart home appliance through the user terminal.
[0025] Specifically, such as Figure 1 The flowchart shown illustrates a control method for a smart home appliance, which includes the following steps: Step S102: In response to receiving a control request sent by a user terminal, extract the user identifier carried in the control request; In practical use, this control request is a request sent by the user through a user terminal to a backend server or to a smart home appliance to control the smart home appliance. Typically, the user logs into a pre-installed application (APP) on their user terminal to input the control request via text or voice, such as "start the oven baking mode." The user terminal then recognizes the user's input text or voice, converts it into natural language, and sends it to the smart home appliance or its backend server, thereby executing the smart home appliance control method described in this embodiment. After receiving the control request from the user terminal, the smart home appliance or backend server responds and extracts the user's identifier to verify the user's legitimacy.
[0026] Step S104: If the user corresponding to the verified user identifier is a legitimate user, then the intelligent agent configured by the smart home appliance is invoked to parse the control request to obtain the user intent contained in the control request, and at least one target home appliance corresponding to the user intent. In practical use, the smart home appliances in this embodiment of the invention can be smart kitchen appliances or smart home devices, depending on the actual usage. This embodiment of the invention does not impose any limitations on this. Furthermore, the intelligent agent configured with the smart home appliance can be an intelligent agent running on the controller of the smart home appliance itself, or it can be an intelligent agent running on a backend server. When the intelligent agent runs on the controller of the smart home appliance itself, it places higher demands on the performance and computing power of the controller. Therefore, the intelligent agents configured with the smart home appliance mostly run on the backend server that establishes communication with the smart home appliance.
[0027] Therefore, in step S104, taking the example of a smart home appliance communicating with a backend server and the smart agent being an agent running on the backend server, the smart agent running on the backend server communicating with the smart home appliance can be called to parse the control request through the smart agent running on the backend server.
[0028] Step S106: Query the object model information corresponding to each target home appliance; Step S108: Input the object model information and user intent into the preset large language model, and output the device control command corresponding to each target home appliance through the large language model; Step S110: Send the device control command to the corresponding target home appliance to control the target home appliance.
[0029] This invention provides a control method for smart home appliances. Upon receiving a control request from a user terminal, the method extracts the user identifier carried in the control request and verifies the user. If the user identifier is verified as a legitimate user, an intelligent agent is invoked to parse the control request, obtaining the user intent contained in the control request and at least one target home appliance corresponding to the user intent. The method then queries the object model information corresponding to each target home appliance; inputs the object model information and the user intent into a preset large language model; outputs the device control command corresponding to each target home appliance through the large language model; and sends the device control command to the corresponding target home appliance to control it. Since the parsing process of the control request is performed after verifying that the user identifier is a legitimate user, the risk of unauthorized control of smart home appliances can be effectively reduced, thereby improving the security and stability of the entire control system.
[0030] In practical use, the control method for smart home appliances in this embodiment of the invention is actually the interaction between smart home appliances and the Internet of Things. When the intelligent agent runs on the backend server, the backend server also runs multiple servers related to the object model. The object model refers to the digital abstraction representation of the smart home appliance on the backend server. Since the large language model cannot directly operate the actual hardware devices such as smart home appliances, the smart home appliance can be controlled through the object model. That is, the control request instruction is converted into a structured API call that conforms to the object model standard definition, so that the smart home appliance can recognize the control request instruction and thus control the smart home appliance. Therefore, after the backend server receives the control request sent by the user terminal, the intelligent agent and the multiple servers related to the object model can start running.
[0031] For ease of understanding, Figure 1 On this basis, Figure 2 A control timing flowchart for a smart home appliance is also shown, such as... Figure 2 As shown, the client and backend server are illustrated respectively. Correspondingly, in Figure 2 The image shows the user icon, as well as the backend server's agent icon, the Model Context Protocol Server (MCP Server) icon, and the Internet of Things Model Service (RIOT) icon, based on... Figure 2 In this embodiment of the invention, taking the intelligent agent running on a background server as an example, the control and interaction process of intelligent home appliances is described, including the following steps: Step S202: The user terminal sends a control request to the backend server; In practice, after the control request is sent to the backend server, the backend server calls the Agent to parse it. For details, please refer to the following steps.
[0032] Step S204: Obtain memory information through the intelligent agent, parse the control request based on the memory information to obtain the user's intent, and identify at least one target home appliance; In this embodiment of the invention, the memory information includes window memory information and long-term memory information. Specifically, the agent invokes window memory information (such as short-term context cached in Redis) and long-term memory information (such as a list of home appliances and attribute information provided by the MCPServer) to parse the user's intent and determine the target home appliance. Furthermore, by combining long-term memory and window memory mechanisms, this embodiment significantly improves the accuracy and response efficiency of multi-turn dialogue models in kitchen appliance control scenarios. The window memory information is cached in Redis and delayed in synchronization to the database, ensuring data security, preventing data loss, and improving the speed of context retrieval. In addition, this embodiment can extract key summary information from historical records, such as the user's home appliance information and personal information, and store it in the long-term memory. When the user initiates a new dialogue request, the long-term memory information is concatenated with the window memory information to form a complete context. Simultaneously, the system's prompt enhancement mechanism provides example information about the device object model, further strengthening the understanding of the object model and improving the user's interactive experience.
[0033] Furthermore, after identifying the target home appliance in the above steps, the intelligent agent requests the object model information corresponding to the target home appliance from the Model Context Protocol Server (hereinafter referred to as the MCP Server). During this process, the intelligent agent sends a request to the MCP Server to obtain the object model information, carrying a user identifier, also known as the user terminal's identity token. At this point, the MCP Server can initiate authentication, for example, using an authentication module implemented based on dynamic bytecode modification of ByteBuddyAgent, to extract and verify the token from the request header. If the verification is valid, the request can continue to be processed. Typically, users can register as legitimate users when purchasing smart home appliances, or register as legitimate users when first logging into the corresponding application (APP) of the smart home appliance, so that the authentication process can be performed when controlling the smart home appliance. Typically, the MCP Server can extract the user identifier to verify whether the user is a registered legitimate user with operating permissions. If so, authentication is successful, and subsequent operations can proceed. If authentication fails, a prompt message is issued, and subsequent operations are prohibited.
[0034] Step S206: Call the Model Context Protocol Server and query the object model information corresponding to at least one target home appliance through the Model Context Protocol Server; After the above authentication is successful, the MCP Server queries the object model information corresponding to the target home appliance. Specifically, in this embodiment of the invention, the MCP Server queries the simplified object model information corresponding to each target home appliance. This simplified object model information includes preset attribute fields and control fields. Typically, only the necessary attribute fields and control fields are retained, and natural language descriptions are added to each field before returning it to the intelligent agent.
[0035] In practical use, in this embodiment of the invention, at the object model level, the object models of smart home appliances that need to support intelligent control are typically simplified in advance, retaining only the necessary attribute fields and control fields of the smart home appliances. Natural language description fields are added to each object model field, and accurate natural language descriptions help the large language model better understand the meaning of the object model. Secondly, on the Agent side, example object models and example control commands are provided through system prompt word injection.
[0036] Specifically, based on Figure 2 The process in step S206 corresponds to Figure 2 The three processes in the process are 206a, 206b, and 206c. Specifically, 206a: The MCP Server requests the IoT Model Service to obtain the simplified object model information corresponding to each target home appliance; 206b: The IoT Model Service returns the simplified object model information corresponding to each target home appliance to the MCP Server; and 206c: The MCP Server obtains the simplified object model information corresponding to each target home appliance.
[0037] After obtaining the simplified object model information, the following steps are performed to understand the simplified object model information.
[0038] Step S208: Input the object model information and user intent into the preset large language model, and output the device control command corresponding to each target home appliance through the large language model; Specifically, in this process, after adding descriptive information to the attribute fields and control fields of the simplified object model information, the simplified object model information, descriptive information and user intent are input into the preset large language model. At the same time, the example object model and example operation instruction combination are also input, so that the large language model can perform logical reasoning based on the example object model and example operation instruction combination, and finally output the device control instruction corresponding to each target home appliance for this control request.
[0039] In practical use, the aforementioned large language model can also call the corresponding intelligent agent. After the intelligent agent of the large language model outputs device control commands, it can further call the device control tool interface of the MCP Server to send them to the target home appliance. Before sending, the MCP Server can perform a fallback verification of legality. That is, in this embodiment of the invention, before sending the device control command to at least one target home appliance, it can also verify whether the user identifier has the authority to control the target home appliance; if so, the device control command is sent to the target home appliance; if not, sending the device control command is prohibited, and a prompt message is generated. This process corresponds to... Figure 2 Step S210 in the process.
[0040] In step S210, the MCP Server verifies the Token permission information again to ensure the legality of the device control command call.
[0041] In practical use, the existing official MCP protocol does not define authentication specifications between the client and server, resulting in a lack of effective authentication mechanisms in existing MCP Server frameworks. However, the control process in this embodiment of the invention pertains to a home appliance control scenario, which has extremely high security requirements, especially strict control over the access permissions of device control tools. Therefore, this embodiment of the invention explicitly requires that the Agent accessing the MCP Server carry an identity identifier (e.g., a Token) for authentication. Specifically, this embodiment of the invention innovatively employs the ByteBuddyAgent tool (a tool that dynamically inserts bytecode during code compilation). By dynamically modifying the underlying bytecode of the framework, an authentication interceptor is set up when the user terminal sends a control request, i.e., before the user terminal establishes a connection with the backend server. This interceptor extracts and verifies the Token information from the request header. If the Token is invalid, the connection is prohibited; if the Token is valid, the permission information is parsed and extracted, and stored in the context. When the Agent invokes a specific tool, it obtains permission information from the context to determine whether to allow the tool invocation, thereby effectively improving system security and stability. For example, after extracting the user identifier carried in the control request, it verifies the legitimacy of the user corresponding to the user identifier, and further determines the legitimacy of the device control command before sending the device control command to the corresponding target home appliance.
[0042] Step S212: Send the device control command to the corresponding target home appliance to control the target home appliance.
[0043] Once the device control command is determined to be valid in step S210, the MCP Server forwards the device control command to the underlying IoT (Internet of Things) platform during step S212, and the IoT platform sends the device control command to the target home appliance for execution.
[0044] Furthermore, after the target home appliance completes its execution, it can also send the execution result back to the MCP Server, such as sending a success or failure result and status data. The MCP Server then sends the execution result back to the Agent, which presents the result to the user in natural language. Figure 2 The process of step S214 in the process.
[0045] Step S214: Return the execution result.
[0046] Furthermore, the backend server can also record data such as the accuracy score, execution result, and network status of this interaction process to the log system and store them in a long-term memory for subsequent optimization of model understanding and control strategies.
[0047] Furthermore, in this embodiment of the invention, the understanding level of the large language model can also be evaluated. Specifically, the accuracy of understanding the object model corresponding to the large language model can be statistically analyzed based on the interaction records of the large language model. If the accuracy of understanding the object model corresponding to the large language model is lower than a preset accuracy threshold, the large language model is switched according to a pre-configured adjustment strategy. Here, the accuracy of understanding the object model corresponding to the large language model refers to the accuracy of the large language model in outputting device control commands based on object model information and user intent, and is used to evaluate the understanding level of the large language model.
[0048] In practice, the accuracy score of the large language model can be calculated based on the interaction records of the large language model. This accuracy score is used to characterize the accuracy of the large language model's understanding of the object model. If the accuracy score is lower than the preset score threshold, it is determined that the understanding accuracy of the object model corresponding to the large language model is lower than the preset accuracy threshold.
[0049] Typically, the backend server can periodically analyze the accuracy score of the currently used large language model. Data such as the accuracy score, execution result, and network status of each interaction recorded in the long-term memory can serve as interaction logs. By periodically analyzing interaction logs over a period of time, the understanding accuracy of the large language model can be determined. If the understanding accuracy is low, the large language model can be improved or switched to enhance the control accuracy of smart home appliances and improve their intelligence.
[0050] In practice, the scoring model used to calculate the accuracy score can be designed according to actual needs and specific scenarios. A preferred simple calculation method in this embodiment of the invention is as follows:
[0051] Where MUA represents the accuracy score. This is the weighting coefficient, with a value of 0 < <1, used to control the ratio of structural accuracy to semantic understanding. This indicates the number of object model fields correctly identified by the large language model (Correct fields). Total fields represent the total number of fields in the object model. This represents the similarity score of the large language model to the semantic description of the i-th field, which is usually between 0 and 1; n represents the total number of fields being evaluated.
[0052] The above calculation method is also known as the MUA scoring model. This MUA scoring model combines the accuracy of large language models in structural recognition and semantic understanding of object model fields, and belongs to a dual-positive index comprehensive model. This represents the accuracy of the large language model in recognizing structured fields; the closer the value is to 1, the more complete the large language model's understanding of the object model's structure. This is used to measure the semantic closeness of a large language model to natural language descriptions, reflecting its ability to understand the meaning of fields. Parameters are used to control and The weight of both factors in the overall score can be increased when the device structure is complex and field recognition is particularly critical. Strengthen structural accuracy; if natural language adaptation is emphasized, then reduce... The weighting of semantic understanding in the scoring is emphasized.
[0053] because and Both scores fall within the range of [0, 1], therefore, the accuracy score (MUA) also remains stable within this range. When the MUA approaches 1, it indicates that the large language model possesses high-level adaptability in both structural recognition and semantic understanding; when the MUA is below 0.5, it indicates that the large language model has a significant weakness in at least one aspect. Therefore, the aforementioned MUA scoring model comprehensively reflects the generalization ability and application adaptability of the large language model to device models, providing a quantitative reference for the effect evaluation and dynamic optimization of the embodiments of this invention.
[0054] Furthermore, in this embodiment of the invention, the accuracy score obtained above can be further determined to belong to a score range; based on the score range, the level of object model comprehension accuracy of the large language model can be determined, and this level is used to optimize the large language model.
[0055] That is, in this embodiment of the invention, the accuracy score MUA can be divided into several levels, such as excellent (0.90-1.00), good (0.75-0.89), average (0.6-0.74), poor (0.40-0.59), and very poor (0.00-0.39).
[0056] Typically, an accuracy score (MUA) can be calculated during each round of interaction, and the results of each MUA calculation are collected in real time. When the model score is below "good", the underlying model service can dynamically switch the large language model. For example, if model A is currently being used, and the accuracy score (MUA) of model A is below "good" for several consecutive times, it means that model A is not suitable for use in the current smart home appliance control scenario. Therefore, model A can be switched to model B, and in subsequent control processes, model B can be used to output the device control commands corresponding to each target home appliance.
[0057] In practical use, considering that most of the large open language models currently on the market follow the OpenAI protocol, this embodiment of the invention can abstract the OpenAI protocol and adopt an interface-oriented programming approach to design and implement a pluggable model base service. Users only need to quickly configure the basic information of various vendors' models through a visual page to quickly achieve compatibility and provide corresponding model services, such as choosing to use model A or model B, etc., which can achieve rapid adaptation.
[0058] In summary, the smart home appliance control method provided in this invention, by abstracting the OpenAI protocol, can achieve a pluggable model base service. Users can configure the basic information of the large language model they use on a visual page, enabling rapid compatibility with model services from different manufacturers. Simultaneously, the combination of long-term memory and window memory mechanisms significantly improves the accuracy and response efficiency of multi-turn dialogue models. By simplifying object model fields and enhancing natural language descriptions, the large language model's ability to understand device object models is improved. Furthermore, by innovatively employing the ByteBuddyAgent tool to achieve dynamic bytecode modification and introducing a token mechanism for strict client identity authentication and access control, the security and stability of the kitchen appliance control process are effectively guaranteed.
[0059] Furthermore, based on the above embodiments, this invention also provides a control device for smart home appliances, such as... Figure 3The diagram shows the architecture of a control device for a smart home appliance, which includes: The parsing module 30 is used to extract the user identifier carried in the control request in response to receiving a control request sent by the user terminal. The module 32 is used to call the intelligent agent configured by the smart home appliance to parse the control request if the user corresponding to the user identifier is verified to be a legitimate user, so as to obtain the user intent contained in the control request, and at least one target home appliance corresponding to the user intent; Query module 34 is used to query the object model information corresponding to each of the target home appliances; Instruction module 36 is used to input the object model information and the user intent into a preset large language model, and output the device control instructions corresponding to each target home appliance through the large language model; The control module 38 is used to send the device control command to the corresponding target home appliance to control the target home appliance.
[0060] Furthermore, this embodiment of the invention also provides a control system for a smart home appliance, used in the aforementioned control method for the smart home appliance; The control system includes smart home appliances and a backend server. The smart home appliances are equipped with intelligent agents, and both the smart home appliances and the backend server are used to establish communication with user terminals. The backend server is also used to establish communication with the smart home appliances. The interaction process between the smart home appliances and the backend server in the control system can be referenced... Figure 2 The corresponding process will not be repeated here.
[0061] The control device and system for smart home appliances provided in this embodiment of the invention have the same technical features as the control method for smart home appliances provided in the above embodiments, so they can also solve the same technical problems and achieve the same technical effects.
[0062] Furthermore, embodiments of the present invention also provide an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the above-described method.
[0063] This invention also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the steps of the above-described method.
[0064] Furthermore, embodiments of the present invention also provide a schematic diagram of the structure of an electronic device, such as... Figure 4The diagram shows the structure of the electronic device, which includes a processor 41 and a memory 40. The memory 40 stores computer-executable instructions that can be executed by the processor 41, and the processor 41 executes the computer-executable instructions to implement the above-described method.
[0065] exist Figure 4 In the illustrated embodiment, the electronic device further includes a bus 42 and a communication interface 43, wherein the processor 41, the communication interface 43, and the memory 40 are connected via the bus 42.
[0066] The memory 40 may include high-speed random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Communication between this system network element and at least one other network element is achieved through at least one communication interface 43 (which can be wired or wireless), such as the Internet, wide area network, local area network, metropolitan area network, etc. The bus 42 may be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. The bus 42 can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 4 The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.
[0067] Processor 41 may be an integrated circuit chip with signal processing capabilities. In implementation, each step of the above method can be completed by the integrated logic circuitry in the hardware of processor 41 or by software instructions. Processor 41 can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this invention can be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. The storage medium is located in the memory, and the processor 41 reads the information in the memory and uses its hardware to complete the aforementioned method.
[0068] The computer program product of the control method and system for smart home appliances provided in this embodiment of the invention includes a computer-readable storage medium storing program code. The instructions included in the program code can be used to execute the methods described in the preceding method embodiments. For specific implementation, please refer to the method embodiments, which will not be repeated here.
[0069] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the system and apparatus described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0070] Furthermore, in the description of the embodiments of the present invention, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in the present invention based on the specific circumstances.
[0071] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this invention, essentially, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0072] In the description of this invention, it should be noted that the terms "center," "upper," "lower," "left," "right," "vertical," "horizontal," "inner," and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are used only for the convenience of describing the invention and for simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on the invention. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and should not be construed as indicating or implying relative importance.
[0073] Finally, it should be noted that the above embodiments are merely specific implementations of the present invention, used to illustrate the technical solutions of the present invention, and not to limit it. The scope of protection of the present invention is not limited thereto. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments within the technical scope disclosed in the present invention, or make equivalent substitutions for some of the technical features; and these modifications, changes, 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, and should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. A control method for intelligent home appliances, characterized in that, The method includes: In response to receiving a control request from a user terminal, the user identifier carried in the control request is extracted; If the user corresponding to the user identifier is verified to be a legitimate user, then the intelligent agent configured by the smart home appliance is invoked to parse the control request, and the user intent contained in the control request, and at least one target home appliance corresponding to the user intent; Query the object model information corresponding to each of the target home appliances; The object model information and the user intent are input into a preset large language model, and the device control command corresponding to each target home appliance is output through the large language model. The device control command is sent to the corresponding target home appliance to control the target home appliance.
2. The method according to claim 1, characterized in that, The steps for querying the object model information corresponding to each of the target home appliances include: The model context protocol server is invoked to query the object model information corresponding to at least one of the target home appliances.
3. The method according to claim 2, characterized in that, The method further includes: Before sending the device control command to at least one of the target home appliances, verify whether the user identifier has the authority to control the target home appliance; If so, the device control command is sent to the target home appliance.
4. The method according to claim 2, characterized in that, The steps for querying the object model information corresponding to each of the target home appliances include: Query the simplified object model information corresponding to each of the target home appliances, wherein the simplified object model information includes preset attribute fields and control fields; The steps of inputting the object model information and the user intent into a preset large language model include: After adding descriptive information to the attribute fields and manipulation fields of the simplified object model information, the simplified object model information, the descriptive information, and the user intent are input into a preset large language model.
5. The method according to claim 1, characterized in that, The smart home appliances communicate with the backend server; The intelligent agent is the intelligent agent running on the backend server; The step of invoking the intelligent agent configured in the smart home appliance to parse the control request includes: The system invokes an intelligent agent running on the backend server that communicates with the smart home appliance to parse the control request.
6. The method according to claim 1 or 5, characterized in that, The step of invoking the intelligent agent configured in the smart home appliance to parse the control request includes: The intelligent agent acquires memory information, including window memory information and long-term memory information. Based on the memory information, the control request is parsed to obtain the user intent and identify at least one target home appliance.
7. The method according to claim 1, characterized in that, The method further includes: Based on the interaction records of the large language model, the accuracy of understanding the object model corresponding to the large language model is statistically analyzed; If the understanding accuracy of the object model corresponding to the large language model is lower than the preset accuracy threshold, the large language model will be switched according to the preset adjustment strategy.
8. The method according to claim 7, characterized in that, The steps for statistically analyzing the understanding accuracy of the object model corresponding to the large language model based on the interaction records of the large language model include: The accuracy score of the large language model is calculated based on the interaction records of the large language model. The accuracy score is used to characterize the accuracy of the large language model in understanding the object model. If the accuracy score is lower than a preset score threshold, then the understanding accuracy of the object model corresponding to the large language model is determined to be lower than the preset accuracy threshold.
9. The method according to claim 8, characterized in that, The method further includes: Determine the score range to which the accuracy score belongs; The accuracy level of the object model comprehension of the large language model is determined based on the score range, and the level is used to optimize the large language model.
10. A control system for a smart home appliance, characterized in that, A control method for performing any one of claims 1 to 9 of the intelligent home appliance; The control system includes smart home appliances and a back-end server; The smart home appliance is equipped with an intelligent agent, and both the smart home appliance and the backend server are used to establish communication with the user terminal. The backend server is also used to establish communication with the smart home appliance.