Device adding method and device, system, medium and electronic device
Through the data interaction between the server and the terminal, the network diagram of the smart home account is obtained, and whether the new device can replace the existing device is determined. This solves the problem of high complexity in setting when adding new devices, and realizes the convenient construction and use of smart scenarios.
Patent Information
- Application Number
- CN202210516973.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-12
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2042-05-12
AI Technical Summary
When users add new devices to smart homes, they need to manually configure them, resulting in high settings complexity and limited user awareness, making it difficult to effectively integrate new devices.
Through the data interaction between the server and the terminal, the network diagram of the target account is obtained, and whether there are replaceable devices to be added are determined, and the corresponding link setting response is sent to simplify the setting process of the new device.
It reduces the complexity of users' settings for new devices, improves the convenience of using smart scenarios, and simplifies the construction process of smart scenarios.
Smart Images

Figure CN115167156B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of smart home technology, and in particular to a device adding method and apparatus, a device adding system, a computer-readable storage medium, and an electronic device. Background Art
[0002] Smart home (smart home, home automation) improves home safety, convenience, comfort, artistry, and realizes an environmentally friendly and energy-saving living environment. Therefore, more and more smart devices are being added.
[0003] In the related art, when a user adds a new smart device, he needs to manually configure it. However, based on the user's manual configuration, the construction of the smart scene completely relies on the user's limited knowledge of the device, resulting in a high complexity in the setting of the new device.
[0004] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention
[0005] The purpose of the present disclosure is to provide a device adding method and apparatus, a device adding system, a computer-readable storage medium, an electronic device, and a computer program product containing instructions, which can reduce the complexity of setting up new devices at least to a certain extent.
[0006] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.
[0007] According to one aspect of the present disclosure, a device adding method is provided, which is applied to a server, and the method includes: receiving a link setting request for a device to be added sent by a terminal, the link setting request being sent by the terminal in response to the device to be added being added to a target account, the target account being logged in at the terminal; obtaining a network diagram corresponding to the target account, the network diagram being determined according to the links of the added devices associated with the target account; determining whether there is a device to be replaced among the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; and, in the case that the device to be replaced exists among the added devices, sending a first link setting response regarding a scene link of the device to be added to the terminal; in the case that the device to be replaced does not exist among the added devices, sending a second link setting response regarding the scene link of the device to be added to the terminal.
[0008] According to one aspect of the present disclosure, a device adding method is provided, which is applied to a terminal, and the method includes: sending a link setting request for a device to be added to a server, the link setting request is sent by the terminal in response to the device to be added being added to a target account, and the target account is logged in to the terminal; so that the server obtains a network diagram corresponding to the target account, and the network diagram is: determined according to the links of the added devices associated with the target account; determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; and, in the case that the device to be replaced exists in the added devices, sending a first link setting response for a scene link of the device to be added to the terminal; in the case that the device to be replaced does not exist in the added devices, sending a second link setting response for the scene link of the device to be added to the terminal; and, receiving the first link setting response or the second link setting response sent by the server.
[0009] According to another aspect of the present disclosure, a device adding apparatus is provided, which is configured in a server, and includes: a first receiving module, an acquiring module, a determining module, and a first sending module.
[0010] Among them, the above-mentioned first receiving module is used to: receive a link setting request sent by the terminal regarding the device to be added, the above-mentioned link setting request is sent by the above-mentioned terminal in response to the above-mentioned device to be added being added to the target account, and the above-mentioned target account is logged in to the above-mentioned terminal; the above-mentioned acquisition module is used to: obtain the network diagram corresponding to the above-mentioned target account, and the above-mentioned network diagram is: determined according to the link of the added device associated with the above-mentioned target account; the above-mentioned determination module is used to: determine whether there is a device to be replaced in the above-mentioned added devices according to the characteristic information about the above-mentioned device to be added in the above-mentioned link setting request and the above-mentioned network diagram; and the above-mentioned first sending module is used to: in the case that the above-mentioned device to be replaced exists in the above-mentioned added devices, send a first link setting response regarding the scene link of the above-mentioned device to be added to the above-mentioned terminal; in the case that the above-mentioned device to be replaced does not exist in the above-mentioned added devices, send a second link setting response regarding the scene link of the above-mentioned device to be added to the above-mentioned terminal.
[0011] According to another aspect of the present disclosure, a device adding apparatus is provided, which is configured in a terminal, and includes: a second sending module and a second receiving module.
[0012] The second sending module is used to: send a link setting request for the device to be added to the server, the link setting request is sent by the terminal in response to the device to be added to the target account, and the target account is logged in at the terminal;
[0013] so that the server obtains a network diagram corresponding to the target account, the network diagram being: determined according to the link of the added device associated with the target account; determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; and, in the case that the device to be replaced exists in the added devices, sending a first link setting response about the scene link of the device to be added to the terminal; in the case that the device to be replaced does not exist in the added devices, sending a second link setting response about the scene link of the device to be added to the terminal;
[0014] And, the second receiving module is used to: receive the first link setting response or the second link setting response sent by the server.
[0015] According to one aspect of the present disclosure, a server and a terminal are provided;
[0016] The server is used to execute the device adding method as described in the first aspect, and the terminal is used to execute the device adding method as described in the second aspect.
[0017] According to another aspect of the present disclosure, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the device adding method as described in the first aspect is implemented, and the device adding method as described in the second aspect is executed.
[0018] According to another aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the device adding method as described in the first aspect is implemented, and the device adding method as described in the second aspect is executed.
[0019] According to another aspect of the present disclosure, a computer program product comprising instructions is provided. When the computer program product is executed on a computer or a processor, the computer or the processor executes the device adding method as described in the first aspect and the device adding method as described in the second aspect.
[0020] The device adding method and apparatus, device adding system, computer-readable storage medium, electronic device and computer program product containing instructions provided by the embodiments of the present disclosure have the following technical effects:
[0021] This technical solution is implemented based on data interaction between a server and a terminal. When the server receives a link setting request for a device to be added from a terminal, it obtains a network diagram of the link structure of the added devices associated with the current account. Furthermore, based on the characteristic information of the device to be added and the network diagram, it is determined whether there is a device to be replaced among the added devices. Different link setting responses are determined and sent to the terminal when there is a device to be replaced and when there is no device to be replaced.
[0022] This technical solution is based on the server's hub capabilities in smart scenes and its ability to identify smart devices to match newly added devices with the added devices of the same account to determine whether there are devices to be replaced for the newly added devices. Further, different link setting responses are determined when there are devices to be replaced and when there are no devices to be replaced, which can effectively reduce the user's setting complexity for new devices, lower the user's threshold for using smart scenes, and facilitate the maximum presentation of the convenience of smart scenes. At the same time, the server can quickly identify the user's smart scene needs and implementation, which is conducive to improving the popularity of smart scenes.
[0023] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.
[0025] Figure 1 A schematic diagram of the system architecture of a device addition solution in an exemplary embodiment of the present disclosure is shown.
[0026] Figure 2 A schematic diagram showing information interaction of a method for adding a device in an exemplary embodiment of the present disclosure is shown.
[0027] Figure 3 A schematic diagram of a smart scene link in an exemplary embodiment of the present disclosure is shown.
[0028] Figure 4 A schematic flow chart showing a method for determining a network diagram corresponding to a target account in an exemplary embodiment of the present disclosure.
[0029] Figure 5 A schematic diagram showing a network diagram corresponding to a target account in an exemplary embodiment of the present disclosure.
[0030] Figure 6 A schematic diagram of information interaction of a method for adding a device according to another exemplary embodiment of the present disclosure is shown.
[0031] Figure 7 A schematic diagram showing information interaction of a method for adding a device in another exemplary embodiment of the present disclosure is shown.
[0032] Figure 8 A schematic diagram showing information interaction of a method for adding a device in yet another exemplary embodiment of the present disclosure is shown.
[0033] Fig. 9 A schematic structural diagram of a device adding apparatus according to an embodiment of the present disclosure is shown.
[0034] Fig.10 A schematic structural diagram of a device adding apparatus according to another embodiment of the present disclosure is shown.
[0035] Fig.11 A schematic structural diagram of a device adding apparatus according to another embodiment of the present disclosure is shown.
[0036] Fig.12 A schematic diagram of the structure of a computer system suitable for implementing an electronic device of an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0037] In order to make the objectives, technical solutions and advantages of the present disclosure more clear, the embodiments of the present disclosure will be further described in detail below with reference to the accompanying drawings.
[0038] When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are only examples of devices and methods consistent with some aspects of the present disclosure as detailed in the attached claims.
[0039] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as being limited to the examples set forth herein; on the contrary, these embodiments are provided so that the present disclosure will be more comprehensive and complete, and the concepts of the example embodiments are fully conveyed to those skilled in the art. The described features, structures, or characteristics may be combined in one or more embodiments in any suitable manner. In the following description, many specific details are provided to provide a full understanding of the embodiments of the present disclosure. However, those skilled in the art will appreciate that the technical solutions of the present disclosure may be practiced while omitting one or more of the specific details, or other methods, components, devices, steps, etc. may be adopted. In other cases, known technical solutions are not shown or described in detail to avoid obscuring various aspects of the present disclosure.
[0040] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0041] The following is a detailed description of the device adding method embodiment provided by the present disclosure:
[0042] For example, Figure 1 A schematic diagram of the system architecture of the device addition solution provided in the embodiments of this specification.
[0043] like Figure 1 As shown, the system architecture 100 may include a server 110 , a terminal 120 , a network 130 , and an intelligent device 140 . The terminal 120 , the server 110 , and the intelligent device 140 are connected via the network 130 .
[0044] Exemplarily, the server 110 may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, and big data and artificial intelligence platforms. The terminal 120 may be a device including a display and a network connection function, such as a mobile phone, a computer, a tablet, etc. In this embodiment, the network 130 may be a wide area network or a local area network. The smart device 140 may be a smart speaker, a smart TV, a smart range hood, or a smart stove, etc. In this embodiment, the smart device 140 is a newly added device, also called a target device, which is a device that the user is going to add to the smart scene.
[0045] refer to Figure 1 , the user logs in to his account (referred to as the target account) through the terminal 120. Furthermore, the terminal interface displays the icons of the smart devices associated with the target account. Specifically, the reference display interface includes a display mode column 10 for the smart display device, and a smart display device column 12. Among them, the display mode column 10 includes multiple display modes such as "all", "kitchen", "living room" and "bedroom". In different display modes, the smart device display column 12 displays the smart device icons corresponding to the current display mode. For example, in the "all" display mode, the smart display device column 12 displays the icons of all smart devices connected to the account. Reference Figure 1It can be seen that the smart devices associated with this account include speakers, TVs, air purifiers, and range hoods.
[0046] Furthermore, the user can further add smart devices associated with the account through "Add Control" 14. It should be noted that the "newly added device" described in the embodiments of this specification is a device that is not bound to the current account. After further binding the device, a device originally bound to the account may be replaced. The device can also be added based on the original bound device without replacing any device originally bound to the account.
[0047] In the related art, when users set up new devices through "Add Control" 14, they can only evaluate the user experience and perform manual settings. For example, users replace bound old devices or add new smart scenes based on their purchase intentions. However, based on manual configuration by users, the construction of smart scenes completely relies on the user's limited knowledge of the device, resulting in a high complexity in setting up new devices, which leads to a high threshold for users to use smart scenes, and may also lead to the inability to maximize the convenience of smart scenes.
[0048] In order to solve the problems existing in the related art, a device adding method and apparatus, a device adding system, a computer-readable storage medium, an electronic device and a computer program product containing instructions in the embodiments of this specification are provided.
[0049] in, Figure 2 The figure shows a schematic diagram of information interaction of a device adding method in an exemplary embodiment of the present disclosure. The figure shows a scheme for implementing device adding based on information interaction between a terminal and a server. Figure 2 The method includes:
[0050] S210, the server receives a link setting request for a device to be added sent by a terminal.
[0051] Exemplary, reference Figure 1 , log in to the target account through terminal 120, and the terminal 120 interface displays the smart devices bound to the target account. Further, the user can trigger the "add control" 14 to treat the added device (such as Figure 1 After the terminal 120 completes the network configuration of the device to be added 140, the terminal 120 sends a link setting request to the server 110 for the device to be added, so as to request the recommendation data related to the smart scene link setting of the device to be added.
[0052] S220, the server obtains the network diagram corresponding to the target account.
[0053] In an exemplary embodiment, the server determines the link setting data for the device to be added based on the network diagram corresponding to the target account, wherein the network diagram is determined according to the links of the added devices associated with the target account. In this embodiment, the server 110 identifies the device information of the smart device and the common smart scene link form, thereby determining the link information involved in the smart scene of the device to be added, and then providing the user with recommended data for the scene link setting of the device to be added.
[0054] In an exemplary embodiment, in the solution provided in the embodiment of this specification, a scene link (also called: smart scene link) is a directed link composed of nodes, including at least one trigger node and at least one execution node. Among them, the trigger node is the trigger signal of the device execution node, which triggers the start or end of certain functions of a single smart device, and enters or exits a certain state, while the execution node is the start or end of certain functions of the device, and enters or exits a certain state; further, the new state generated may become a new trigger signal, forming a chain reaction, which is a directed single branch link in form. It can be seen that a scene link has one and only one different starting node and end node, with no nodes or multiple nodes in the middle. The smallest group becomes a starting node and an end node connected by a directed line. Among them, node: generally refers to the initial trigger signal and all triggered execution behaviors on the smart scene link, which has a triggering effect or a triggered execution effect, or both of the former.
[0055] In an exemplary embodiment, in the solution provided by the embodiment of this specification, the network diagram (also called: smart scene network diagram) is a directed multi-intelligent scene branch link in form, which allows multiple different starting nodes and end nodes, no nodes in the middle or multiple nodes. The minimum unit is a smart scene link. Among them, the smart scene branch link refers to a smart scene link with the same starting node but different end nodes.
[0056] In the exemplary embodiments, in the solutions provided by the embodiments of this specification, the starting node generally refers to the first node in a smart scene link, with the initial trigger signal including but not limited to manual, time, device status, technical rules, etc., and only has a triggering effect. The end node generally refers to the last node in a smart scene link, which triggers a single smart device to start or end certain functions, enter or exit a certain state, and only has a triggered execution effect.
[0057] For example, Figure 3A schematic diagram of a scene link in an exemplary embodiment of the present disclosure is shown, showing a scene link about smart device A, including a starting node and an end node; wherein the starting node is the trigger node a2 of the scene link, and the end node is the execution node a4 of the scene link. For example, the scene link is a scene link about a smart speaker, the trigger node a2 is 6:30 in the morning, and the execution node a4 is playing alarm music.
[0058] In an exemplary embodiment, the same smart device may include multiple different scene links, and the same nodes exist between different scene links of the same smart device, and the same nodes exist between scene links belonging to different smart devices (for example, the execution node of a smart stove can be used as the trigger node of a smart range hood). Thus, the scene links of smart devices bound to the same account can form a network diagram.
[0059] In an exemplary embodiment, Figure 4 A schematic diagram showing a flow chart of a method for determining a network diagram corresponding to a target account in an exemplary embodiment of the present disclosure. Figure 4 , the embodiment shown in the figure includes:
[0060] S410, determining the same nodes in the multiple links corresponding to the above-mentioned added devices to obtain the common nodes; and, S420, determining the above-mentioned network diagram based on the directed relationship between the nodes contained in the above-mentioned common nodes and the links corresponding to each device in the above-mentioned added devices.
[0061] For example, Figure 5 A schematic diagram showing a network diagram corresponding to a target account in an exemplary embodiment of the present disclosure includes nodes a2, a4 and a6 related to smart device A, and nodes b2, b4, b6 and b6' related to smart device B.
[0062] Among them, the node a4 related to the smart device A and the node b2 related to the smart device B are the same node, that is, the common node between the smart device A and the smart device B can be determined. Figure 3 As shown, nodes a2 and a4 related to smart device A are a scene link about smart device A. The execution node a4 of the scene link is the trigger node of another scene link about smart device A (the execution node of the link is node a6); then the common node of the two different links about smart device A is node a4.
[0063] Furthermore, the common nodes are taken as the intersection of different links, so that the related links can be connected into the above network graph based on the common nodes.
[0064] Continue to refer Figure 2In S230, based on the characteristic information about the device to be added in the link setting request and the network diagram, it is determined whether there is a device to be replaced among the added devices.
[0065] In an exemplary embodiment, the following combination Figure 6 For a detailed description of the specific implementation of S230, refer to Figure 6 :
[0066] In S2302, according to the characteristic information of the device to be added, a target trigger node and a target execution node corresponding to the device to be added are determined.
[0067] Exemplarily, the characteristic information of the device to be added includes the function of the device and possible trigger conditions of different functions, etc. In this embodiment, at least one execution node (recorded as a target execution node) is determined according to the function of the device to be added in the characteristic information, and at least one trigger node (recorded as a target trigger node) is determined according to possible trigger conditions of different functions.
[0068] In S2304, a first similarity between the target trigger node and the nodes included in the network diagram is calculated, and a second similarity between the target execution node and the nodes included in the network diagram is calculated;
[0069] In this embodiment, based on the first similarity and the second similarity, it is determined whether there is a device to be replaced in the added devices. Specifically:
[0070] In S2306, it is determined whether there is an added device that satisfies the first similarity of the preset condition and the second similarity of the preset condition. If there is no added device that satisfies the first similarity of the preset condition and the second similarity of the preset condition, S2308 is executed: determining whether there is a device to be replaced among the added devices; if there is no first similarity that satisfies the preset condition and / or there is no second similarity that satisfies the preset condition, S2308' is executed: determining whether there is no device to be replaced among the added devices.
[0071] In an exemplary embodiment, a similarity comparison may be performed between the name of the device to be added and the name of the bound device. If the similarity between the name of the device to be added and the name of a bound device is greater than a preset value, the bound device may be determined as the device to be replaced.
[0072] In an exemplary embodiment, continue to refer to Figure 2 In S240, if the device to be replaced exists in the added devices, a first link setting response regarding the scene link of the device to be added is sent to the terminal. Figure 6 For a detailed description of the specific implementation of S240, refer to Figure 6 :
[0073] In S2402, when it is determined that there is a device to be replaced among the added devices, an added device that satisfies the first similarity and the second similarity is obtained to obtain the device to be replaced. And, in S2404, when there is the device to be replaced among the added devices, a link related to the device to be replaced is obtained in the network diagram.
[0074] For example, if the device to be added is a second-generation smart speaker, and the bound devices of the target account include a first-generation smart speaker (the second-generation smart speaker is an upgraded version of the first-generation smart speaker), then the above embodiment can determine that the device to be replaced by the device to be added is the first-generation smart speaker. It can be seen that the user may want to replace the low-profile smart speaker. In this embodiment, the scene links related to the first-generation smart speaker are extracted from the above network diagram.
[0075] In S2406, a first link setup response regarding the scene link of the device to be added is generated based on the link related to the device to be replaced, and / or the link related to the device to be replaced is determined as the first link setup response regarding the scene link of the device to be added; and, in S2408, the first link setup response is sent to the terminal.
[0076] Exemplarily, after extracting the scene link related to the first-generation smart speaker in the above network diagram, the obtained scene link about the first-generation smart speaker can be directly used as the recommended information about the link setting of the second-generation smart speaker (i.e., the first link setting response). It can also be based on the new functions that distinguish the second-generation smart speaker from the first-generation smart speaker. After adding or modifying the scene link about the first-generation smart speaker, it is used as the recommended information about the link setting of the second-generation smart speaker (i.e., the first link setting response). For example, compared with the first-generation smart speaker, the second-generation smart speaker contains new functions. The scene link of the first-generation smart speaker is modified according to the new functions, or the link corresponding to the new functions is added on the basis of the scene link of the first-generation smart speaker, so as to determine the recommended information for the link setting of the second-generation smart speaker (i.e., the first link setting response). It can be seen that the device addition solution based on server implementation provided in the embodiment of this specification is conducive to the maximum presentation of the convenience of smart scenes.
[0077] In an exemplary embodiment, Figure 7 A schematic diagram showing information interaction of a device adding method in another exemplary embodiment of the present disclosure is shown. Figure 2The specific implementation of S210-S240 and S240' is the same as that of the above embodiment.
[0078] Exemplarily, after sending the first link setup response to the terminal (S240), the solution further includes: S710 and S720.
[0079] In S710, first response information regarding the first link setup response sent by the terminal is received, where the first response information includes: receiving the first link setup response, or modifying the first link setup response.
[0080] Exemplarily, after receiving the first link setup response sent by the server, the terminal displays it, so as to facilitate user viewing and operation. Exemplarily, after the user receives the first link setup response displayed by the terminal, the user can directly accept the first link setup response (if the first link setup response contains multiple scene link recommendations, one or more of them can be received), and can also modify it based on the first link setup response.
[0081] After the user triggers the "OK" control, the terminal returns the user's operation information in response to the first link setting (recorded as first response information) to the server.
[0082] In S720, the link of the device to be added is determined according to the first response information, and the link of the device to be added is added to the network diagram to update the network diagram.
[0083] Exemplarily, the first response information is the scene link setting information of the device to be added. After receiving the first response information, the server adds the link of the device to be added to the network diagram to update the network diagram. Furthermore, the updated network diagram is saved to be used for the target account to add a device next time to determine the setting information recommendation for the scene link of the device to be added.
[0084] In an exemplary embodiment, continue to refer to Figure 2 In S240', if the device to be replaced does not exist in the added devices, a second link setting response regarding the scene link of the device to be added is sent to the terminal. Figure 6 For a detailed description of the specific implementation of S240', refer to Figure 6 :
[0085] In S2402', when it is determined that there is no device to be replaced in the added devices, the added devices satisfying the first similarity or satisfying the second similarity are obtained to obtain the related devices of the setting to be added.
[0086] In this embodiment, in order to provide users with as much recommended information as possible on the settings of the scene link of the device to be added, when it is determined that there is no bound device that can be used as a replacement device among the devices currently bound to the target account, a device with a higher similarity is determined as the related device of the above-mentioned setting to be added. Exemplarily, when it is determined that there is no device to be replaced among the above-mentioned added devices, an added device that meets the above-mentioned first similarity or meets the above-mentioned second similarity is obtained as the related device of the above-mentioned setting to be added.
[0087] In an exemplary embodiment, if the above-mentioned device to be replaced cannot be obtained and the above-mentioned related devices to be added do not exist in the network map corresponding to the target account, the server can obtain related devices from other devices based on the name of the device to be added and other features if allowed by other accounts, and return the scene links of the related devices as recommendation information to the user terminal for the user's reference.
[0088] In S2404', obtain the link related to the above-mentioned related device in the above-mentioned network diagram; generate a second link setting response about the scene link of the above-mentioned device to be added according to the link related to the above-mentioned related device; and in S2406', send the above-mentioned second link setting response to the above-mentioned terminal.
[0089] Exemplarily, after extracting the scene link of the relevant device in the above network diagram, the obtained relevant scene link can be directly used as the recommended information for the link setting of the device to be added (i.e., the second link setting response). Further, the above second link setting response is sent to the terminal, so that the setting recommendation information for the scene link of the device to be added is displayed through the terminal, so that the user can refer to it when setting the scene link of the device to be added.
[0090] In an exemplary embodiment, reference Figure 7 After sending the second link setup response to the terminal (S240'), the solution further includes: S710' and S720'.
[0091] In S710', receiving the second response information about the second link setup response sent by the terminal, the second response information includes: receiving the second link setup response, or modifying the second link setup response. And, in S720', determining the link about the device to be added according to the second response information, and adding the link of the device to be added to the network diagram to update the network diagram.
[0092] Exemplarily, after the user receives the second link setup response displayed by the terminal, the user can directly accept the second link setup response (if the second link setup response includes multiple scene link recommendations, one or more of them can be received), and can also make modifications based on the second link setup response.
[0093] After the user triggers the "OK" control, the terminal returns the user's operation information (recorded as the second response information) in response to the second link setting to the server. The above second response information is the scene link setting information for the device to be added. After receiving the second response information, the server adds the link of the device to be added to the above network diagram to update the above network diagram.
[0094] In the solution provided by the embodiments of this specification, users can obtain effective smart scene optimization solutions after adding smart devices. During the optimization process, they are only responsible for decision-making and leading the completion of smart scene optimization that is more suitable for user needs. At the same time, the addition of smart scene devices can effectively lower the threshold for using smart scenes through this solution and improve the scale of setting smart scenes.
[0095] In an exemplary embodiment, Figure 8 A schematic diagram showing information interaction of a method for adding a device in another exemplary embodiment of the present disclosure is shown. Figure 8 , the embodiment shown in the figure includes:
[0096] Through the user's operation between terminals, S80: network configuration of the device 140 to be added is implemented.
[0097] After completing the network configuration, the terminal 120 sends a request message to the server 110 to request setting recommendation information about the scene link of the device 140 to be added.
[0098] On the server 110 side, the bound devices of the target account determine the device set corresponding to the current smart scene, and determine the network diagram according to the device set corresponding to the current smart scene. Further, in S84: traverse the network diagram, determine the use of devices with similar status or functions to generate replacement solutions. And, in S86: the server generates a recommended new link solution in time, space, and device association based on the functional characteristics of the device to be added.
[0099] The server 110 pushes the relevant information to the terminal, so that the terminal 120 executes S88: displaying the recommended replacement and the recommended solution. Further, in S810: the user chooses to enable and modify part or all of the recommended smart scene link solutions.
[0100] The terminal 120 returns relevant information to the server 110, and the server executes S812: replacing the corresponding smart scene link according to the user selection. Finally, the server updates the smart scene according to the information returned by the user.
[0101] Among them, smart scene refers to including but not limited to multiple space-based or time-based smart scene network diagrams, and its smallest unit is a smart scene network diagram.
[0102] It should be noted that the above figures are only schematic illustrations of the processes included in the method according to an exemplary embodiment of the present invention, and are not intended to be limiting. It is easy to understand that the processes shown in the above figures do not indicate or limit the time sequence of these processes. In addition, it is also easy to understand that these processes can be performed synchronously or asynchronously, for example, in multiple modules.
[0103] The following are embodiments of the device disclosed herein, which can be used to execute the method embodiments disclosed herein. For details not disclosed in the device embodiments disclosed herein, please refer to the method embodiments disclosed herein.
[0104] in, Fig. 9 The schematic diagram of the structure of the device adding device of an embodiment of the present disclosure is shown. Fig. 9 The device adding apparatus shown in the figure can be implemented as all or part of the server through software, hardware or a combination of both, and can also be integrated into the server as an independent module.
[0105] The device adding apparatus 900 in the embodiment of the present disclosure includes: a first receiving module 910 , an acquiring module 920 , a determining module 930 , and a first sending module 940 .
[0106] Among them, the above-mentioned first receiving module 910 is used to: receive a link setting request for the device to be added sent by the terminal, the above-mentioned link setting request is sent by the above-mentioned terminal in response to the above-mentioned device to be added being added to the target account, and the above-mentioned target account is logged in to the above-mentioned terminal; the above-mentioned acquisition module 920 is used to: obtain the network diagram corresponding to the above-mentioned target account, and the above-mentioned network diagram is: determined according to the link of the added device associated with the above-mentioned target account; the above-mentioned determination module 930 is used to: determine whether there is a device to be replaced in the above-mentioned added devices according to the characteristic information about the above-mentioned device to be added in the above-mentioned link setting request and the above-mentioned network diagram; and the above-mentioned first sending module 940 is used to: in the case that the above-mentioned device to be replaced exists in the above-mentioned added devices, send a first link setting response about the scene link of the above-mentioned device to be added to the above-mentioned terminal; in the case that the above-mentioned device to be replaced does not exist in the above-mentioned added devices, send a second link setting response about the scene link of the above-mentioned device to be added to the above-mentioned terminal.
[0107] In an exemplary embodiment, Fig.10 Schematically shows a structural diagram of a device adding apparatus according to another exemplary embodiment of the present disclosure. Fig.10 :
[0108] In an exemplary embodiment, based on the above scheme, the determination module 930 is further used to: before determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram, determine the network diagram according to the links corresponding to each device in the added devices;
[0109] Among them, the target link corresponding to the target device includes at least one trigger node and at least one execution node, the trigger node in the above target link corresponds to the trigger condition for the above target device to start, end, enter or exit the target function, and the execution node in the above target link corresponds to the above target device to start, end, enter or exit the target function.
[0110] In an exemplary embodiment, based on the aforementioned scheme, the above-mentioned determination module 930 is specifically used to: determine the same nodes in the multiple links corresponding to the above-mentioned added devices to obtain the common nodes; and determine the above-mentioned network diagram based on the directed relationship between the nodes contained in the links corresponding to the above-mentioned common nodes and each device in the above-mentioned added devices.
[0111] In an exemplary embodiment, based on the above-mentioned solution, the above-mentioned determination module 930 includes: a node determination unit 9301, a similarity calculation unit 9302 and a to-be-replaced device determination unit 9303.
[0112] Among them, the above-mentioned node determination unit 9301 is used to: determine the target trigger node and target execution node corresponding to the above-mentioned device to be added according to the characteristic information of the above-mentioned device to be added; the above-mentioned similarity calculation unit 9302 is used to: calculate the first similarity between the above-mentioned target trigger node and the node included in the above-mentioned network diagram, and calculate the second similarity between the above-mentioned target execution node and the node included in the above-mentioned network diagram; and the above-mentioned device to be replaced determination unit 9303 is used to: determine whether there is a device to be replaced in the above-mentioned added devices according to the above-mentioned first similarity and the above-mentioned second similarity.
[0113] In an exemplary embodiment, based on the aforementioned scheme, the above-mentioned device to be replaced determination unit 9303 is specifically used to: determine that there is a device to be replaced in the above-mentioned added devices when there is a first similarity that satisfies a preset condition and there is a second similarity that satisfies the preset condition; and, determine that there is no device to be replaced in the above-mentioned added devices when there is no first similarity that satisfies the preset condition and / or there is no second similarity that satisfies the preset condition.
[0114] In an exemplary embodiment, based on the above solution, the determination module 930 further includes: a to-be-replaced device acquisition unit 9304 .
[0115] The device to be replaced acquiring unit 9304 is used to: when it is determined that there is a device to be replaced among the added devices, acquire an added device that satisfies the first similarity and the second similarity to obtain the device to be replaced.
[0116] In an exemplary embodiment, based on the above-mentioned solution, the first sending module 940 includes: a link acquisition unit 9401 , a first response determination unit 9402 , and a first sending unit 9403 .
[0117] Among them, the above-mentioned link acquisition unit 9401 is used to: in the case that the above-mentioned device to be replaced exists in the above-mentioned added devices, obtain the link related to the above-mentioned device to be replaced in the above-mentioned network diagram; the above-mentioned response determination unit 9402 is used to: generate a first link setting response regarding the scene link of the above-mentioned device to be added according to the link related to the above-mentioned device to be replaced, and / or determine the link related to the above-mentioned device to be replaced as the first link setting response regarding the scene link of the above-mentioned device to be added; and the above-mentioned first sending unit 9403 is used to: send the above-mentioned first link setting response to the above-mentioned terminal.
[0118] In an exemplary embodiment, based on the above solution, the upper device adding apparatus 900 further includes an updating module 950 .
[0119] Among them, the above-mentioned first receiving module 910 is also used to: after sending the above-mentioned first link setting response to the above-mentioned terminal, receive the first response information about the above-mentioned first link setting response sent by the above-mentioned terminal, and the above-mentioned first response information includes: receiving the above-mentioned first link setting response, or modifying it based on the first link setting response; and the above-mentioned updating module 950 is used to: determine the link about the above-mentioned device to be added according to the above-mentioned first response information, and add the link of the above-mentioned device to be added to the above-mentioned network diagram to update the above-mentioned network diagram.
[0120] In an exemplary embodiment, based on the above-mentioned solution, the first sending module 940 further includes: a related device acquisition unit 9404 , a second response determination unit 9405 , and a second sending unit 9406 .
[0121] Among them, the above-mentioned related device acquisition unit 9404 is used for: when the above-mentioned device to be replaced does not exist in the above-mentioned added devices, obtaining the added devices that satisfy the above-mentioned first similarity or satisfy the above-mentioned second similarity, and obtaining the above-mentioned related devices to be added; the above-mentioned link acquisition unit 9401 is also used for: obtaining the links related to the above-mentioned related devices in the above-mentioned network diagram; the above-mentioned second response determination unit 9405 is used for: generating a second link setting response regarding the scene link of the above-mentioned device to be added according to the links related to the above-mentioned related devices; and the above-mentioned second sending unit 9406 is used for: sending the above-mentioned second link setting response to the above-mentioned terminal.
[0122] In an exemplary embodiment, based on the aforementioned scheme, the above-mentioned first receiving module 910 is also used to: after sending the above-mentioned second link setting response to the above-mentioned terminal, receive the second response information sent by the above-mentioned terminal regarding the above-mentioned second link setting response, and the above-mentioned second response information includes: receiving the above-mentioned second link setting response, or modifying it based on the second link setting response; the above-mentioned update module 950 is also used to: determine the link about the above-mentioned device to be added according to the above-mentioned second response information, and add the link of the above-mentioned device to be added to the above-mentioned network diagram to update the above-mentioned network diagram.
[0123] In an exemplary embodiment, based on the above-mentioned solution, the server, the terminal and the device to be added are connected based on a wide area network.
[0124] in, Fig.11 The schematic diagram of the structure of the device adding device of an embodiment of the present disclosure is shown. Fig.11 The device adding apparatus shown in the figure can be implemented as all or part of the terminal through software, hardware or a combination of both, and can also be integrated into the terminal as an independent module.
[0125] The device adding apparatus 1100 in the embodiment of the present disclosure includes: a second sending module 1110 and a second receiving module 1120 .
[0126] The second sending module 1110 is used to: send a link setting request for the device to be added to the server, the link setting request is sent by the terminal in response to the device to be added to the target account, and the target account is logged in at the terminal;
[0127] so that the server obtains a network diagram corresponding to the target account, the network diagram being: determined according to the link of the added device associated with the target account; determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; and, in the case that the device to be replaced exists in the added devices, sending a first link setting response about the scene link of the device to be added to the terminal; in the case that the device to be replaced does not exist in the added devices, sending a second link setting response about the scene link of the device to be added to the terminal;
[0128] And, the second receiving module 1120 is used to: receive the first link setting response or the second link setting response sent by the server.
[0129] It should be noted that the device adding apparatus provided in the above embodiment only uses the division of the above functional modules as an example when executing the device adding method. In actual applications, the above functional distribution can be completed by different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the device adding apparatus provided in the above embodiment and the device adding method embodiment belong to the same concept. Therefore, for details not disclosed in the device embodiment of the present disclosure, please refer to the above-mentioned device adding method embodiment of the present disclosure, which will not be repeated here.
[0130] The embodiment of the present specification also provides a device adding system, which includes: a server and a terminal; wherein the above-mentioned device adding method is implemented through information interaction between the server and the terminal.
[0131] The embodiments of information interaction between the server and the terminal have been described in detail in the above specification and will not be repeated here.
[0132] The serial numbers of the above-mentioned embodiments of the present disclosure are only for description and do not represent the advantages or disadvantages of the embodiments.
[0133] The embodiments of the present disclosure also provide a computer-readable storage medium on which a computer program is stored, and when the program is executed by a processor, the steps of the method of any of the above embodiments are implemented. The computer-readable storage medium may include, but is not limited to, any type of disk, including a floppy disk, an optical disk, a DVD, a CD-ROM, a micro drive, and a magneto-optical disk, a ROM, a RAM, an EPROM, an EEPROM, a DRAM, a VRAM, a flash memory device, a magnetic card or an optical card, a nanosystem (including a molecular memory IC), or any type of medium or device suitable for storing instructions and / or data.
[0134] The present disclosure also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of any of the above-mentioned method embodiments when executing the program.
[0135] Fig.12 Schematically shows a structural diagram of an electronic device according to an exemplary embodiment of the present disclosure. Fig.12 As shown, the electronic device 1200 includes: a processor 1201 and a memory 1202 .
[0136] In the embodiment of the present disclosure, the processor 1201 is the control center of the computer system, which can be the processor of a physical machine or the processor of a virtual machine. The processor 1201 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 1201 may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). The processor 1201 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in the standby state.
[0137] In the embodiment of the present disclosure, when the processor 1201 is configured in a server, the processor 1201 is specifically used for:
[0138] A link setting request regarding a device to be added is received from a terminal, wherein the link setting request is sent by the terminal in response to the device to be added being added to a target account, and the target account is logged in at the terminal; a network diagram corresponding to the target account is obtained, wherein the network diagram is determined based on the links of the added devices associated with the target account; based on the characteristic information regarding the device to be added in the link setting request and the network diagram, it is determined whether there is a device to be replaced among the added devices; and, in the case that the device to be replaced exists among the added devices, a first link setting response regarding a scene link of the device to be added is sent to the terminal; in the case that the device to be replaced does not exist among the added devices, a second link setting response regarding the scene link of the device to be added is sent to the terminal.
[0139] Furthermore, before determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram, the method further includes: determining the network diagram according to the links corresponding to each device in the added devices;
[0140] Among them, the target link corresponding to the target device includes at least one trigger node and at least one execution node, the trigger node in the above target link corresponds to the trigger condition for the above target device to start, end, enter or exit the target function, and the execution node in the above target link corresponds to the above target device to start, end, enter or exit the target function.
[0141] Furthermore, the above-mentioned network diagram is determined based on the links corresponding to each device in the above-mentioned added devices, including: determining the same nodes in the multiple links corresponding to the above-mentioned added devices to obtain common nodes; and determining the above-mentioned network diagram based on the directed relationship between the nodes contained in the above-mentioned common nodes and the links corresponding to each device in the above-mentioned added devices.
[0142] Furthermore, the above-mentioned determining whether there is a device to be replaced among the above-mentioned added devices based on the characteristic information about the above-mentioned device to be added in the above-mentioned link setting request and the above-mentioned network diagram includes: determining the target trigger node and the target execution node corresponding to the above-mentioned device to be added based on the characteristic information of the above-mentioned device to be added; calculating the first similarity between the above-mentioned target trigger node and the node included in the above-mentioned network diagram, and calculating the second similarity between the above-mentioned target execution node and the node included in the above-mentioned network diagram; and, based on the above-mentioned first similarity and the above-mentioned second similarity, determining whether there is a device to be replaced among the above-mentioned added devices.
[0143] Further, the determining whether there is a device to be replaced among the added devices based on the first similarity and the second similarity includes: determining that there is a device to be replaced among the added devices when there is a first similarity that satisfies a preset condition and there is a second similarity that satisfies the preset condition; and determining that there is no device to be replaced among the added devices when there is no first similarity that satisfies the preset condition and / or there is no second similarity that satisfies the preset condition.
[0144] Furthermore, the processor 1201 is further specifically configured to:
[0145] In the case where it is determined that there is a device to be replaced among the added devices, an added device that satisfies the first similarity and the second similarity is obtained to obtain the device to be replaced.
[0146] Furthermore, in the case that the device to be replaced exists among the added devices, the first link setting response regarding the scene link of the device to be added is sent to the terminal, including: in the case that the device to be replaced exists among the added devices, obtaining the link related to the device to be replaced in the network diagram; generating the first link setting response regarding the scene link of the device to be added according to the link related to the device to be replaced, and / or determining the link related to the device to be replaced as the first link setting response regarding the scene link of the device to be added; and, sending the first link setting response to the terminal.
[0147] Furthermore, the processor 1201 is further specifically configured to:
[0148] After sending the above-mentioned first link setting response to the above-mentioned terminal, receiving the first response information about the above-mentioned first link setting response sent by the above-mentioned terminal, and the above-mentioned first response information includes: receiving the above-mentioned first link setting response, or modifying it based on the first link setting response; and determining the link about the above-mentioned device to be added according to the above-mentioned first response information, and adding the link of the above-mentioned device to be added to the above-mentioned network diagram to update the above-mentioned network diagram.
[0149] Furthermore, in the case that the device to be replaced does not exist in the added devices, a second link setting response regarding the scene link of the device to be added is sent to the terminal, including: in the case that the device to be replaced does not exist in the added devices, obtaining the added devices that satisfy the first similarity or satisfy the second similarity to obtain the related devices to be added; obtaining the links related to the related devices in the network diagram; generating a second link setting response regarding the scene link of the device to be added according to the links related to the related devices; and sending the second link setting response to the terminal.
[0150] Furthermore, the processor 1201 is further specifically configured to:
[0151] After sending the above-mentioned second link setting response to the above-mentioned terminal, receiving second response information about the above-mentioned second link setting response sent by the above-mentioned terminal, and the above-mentioned second response information includes: receiving the above-mentioned second link setting response, or modifying it based on the second link setting response; and determining the link about the above-mentioned device to be added according to the above-mentioned second response information, and adding the link of the above-mentioned device to be added to the above-mentioned network diagram to update the above-mentioned network diagram.
[0152] Furthermore, the server, the terminal and the device to be added are connected based on a wide area network.
[0153] In the embodiment of the present disclosure, when the processor 1201 is configured in a terminal, the processor 1201 is specifically configured to:
[0154] Sending a link setting request for the device to be added to the server, the link setting request is sent by the terminal in response to the device to be added to the target account, and the target account is logged in at the terminal;
[0155] so that the server obtains a network diagram corresponding to the target account, the network diagram being: determined according to the link of the added device associated with the target account; determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; and, in the case that the device to be replaced exists in the added devices, sending a first link setting response about the scene link of the device to be added to the terminal; in the case that the device to be replaced does not exist in the added devices, sending a second link setting response about the scene link of the device to be added to the terminal;
[0156] And, receiving the first link setting response or the second link setting response sent by the server.
[0157] The memory 1202 may include one or more computer-readable storage media, which may be non-transitory. The memory 1202 may also include a high-speed random access memory and a non-volatile memory, such as one or more disk storage devices and flash memory storage devices. In some embodiments of the present disclosure, the non-transitory computer-readable storage medium in the memory 1202 is used to store at least one instruction, which is used to be executed by the processor 1201 to implement the method in the embodiment of the present disclosure.
[0158] In some embodiments, the electronic device 1200 further includes: a peripheral device interface 1203 and at least one peripheral device. The processor 1201, the memory 1202 and the peripheral device interface 1203 may be connected via a bus or a signal line. Each peripheral device may be connected to the peripheral device interface 1203 via a bus, a signal line or a circuit board. Specifically, the peripheral device includes: at least one of a display screen 1204, a camera 1205 and an audio circuit 1206.
[0159] The peripheral device interface 1203 may be used to connect at least one peripheral device related to I / O (Input / Output) to the processor 1201 and the memory 1202. In some embodiments of the present disclosure, the processor 1201, the memory 1202, and the peripheral device interface 1203 are integrated on the same chip or circuit board; in some other embodiments of the present disclosure, any one or two of the processor 1201, the memory 1202, and the peripheral device interface 1203 may be implemented on a separate chip or circuit board. The embodiments of the present disclosure are not specifically limited to this.
[0160] The display screen 1204 is used to display a UI (User Interface). The UI may include graphics, text, icons, videos, and any combination thereof. When the display screen 1204 is a touch display screen, the display screen 1204 also has the ability to collect touch signals on the surface or above the surface of the display screen 1204. The touch signal can be input to the processor 1201 as a control signal for processing. At this time, the display screen 1204 can also be used to provide virtual buttons and / or virtual keyboards, also known as soft buttons and / or soft keyboards. In some embodiments of the present disclosure, the display screen 1204 can be one, and the front panel of the electronic device 1200 is set; in other embodiments of the present disclosure, the display screen 1204 can be at least two, which are respectively set on different surfaces of the electronic device 1200 or are folded; in some other embodiments of the present disclosure, the display screen 1204 can be a flexible display screen, which is set on the curved surface or folded surface of the electronic device 1200. Even, the display screen 1204 can also be set to a non-rectangular irregular shape, that is, a special-shaped screen. The display screen 1204 can be made of materials such as LCD (Liquid Crystal Display) and OLED (Organic Light-Emitting Diode).
[0161] Camera 1205 is used to capture images or videos. Optionally, camera 1205 includes a front camera and a rear camera. Usually, the front camera is arranged on the front panel of the electronic device, and the rear camera is arranged on the back of the electronic device. In some embodiments, there are at least two rear cameras, which are any one of a main camera, a depth of field camera, a wide-angle camera, and a telephoto camera, so as to realize the fusion of the main camera and the depth of field camera to realize the background blur function, the fusion of the main camera and the wide-angle camera to realize the panoramic shooting and VR (Virtual Reality) shooting function or other fusion shooting functions. In some embodiments of the present disclosure, camera 1205 may also include a flash. The flash can be a monochrome temperature flash or a dual-color temperature flash. A dual-color temperature flash refers to a combination of a warm light flash and a cold light flash, which can be used for light compensation at different color temperatures.
[0162] The audio circuit 1206 may include a microphone and a speaker. The microphone is used to collect sound waves from the user and the environment, and convert the sound waves into electrical signals and input them into the processor 1201 for processing. For the purpose of stereo sound collection or noise reduction, there may be multiple microphones, which are respectively arranged at different parts of the electronic device 1200. The microphone may also be an array microphone or an omnidirectional collection microphone.
[0163] The power supply 1207 is used to power various components in the electronic device 1200. The power supply 1207 can be an alternating current, a direct current, a disposable battery, or a rechargeable battery. When the power supply 1207 includes a rechargeable battery, the rechargeable battery can be a wired rechargeable battery or a wireless rechargeable battery. A wired rechargeable battery is a battery that is charged through a wired line, and a wireless rechargeable battery is a battery that is charged through a wireless coil. The rechargeable battery can also be used to support fast charging technology.
[0164] The electronic device structure block diagram shown in the embodiment of the present disclosure does not constitute a limitation on the electronic device 1200. The electronic device 1200 may include more or fewer components than shown in the figure, or combine certain components, or adopt a different component arrangement.
[0165] In the description of this specification, it should be understood that the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. For those of ordinary skill in the art, the specific meanings of the above terms in this specification can be understood according to specific circumstances. In addition, in the description of this specification, unless otherwise specified, "multiple" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the previously associated objects are in an "or" relationship.
[0166] The embodiments of this specification also provide a computer-readable storage medium, which stores instructions, and when the instructions are executed on a computer or a processor, the computer or the processor executes one or more steps in the above embodiments. If the components of the above-mentioned device adding device are implemented in the form of software functional units and sold or used as independent products, they can be stored in the above-mentioned computer-readable storage medium.
[0167] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The above computer program product includes one or more computer instructions. When the above computer program instructions are loaded and executed on a computer, the above process or function according to the embodiment of this specification is generated in whole or in part. The above computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The above computer instructions can be stored in a computer-readable storage medium or transmitted by the above computer-readable storage medium. The above computer instructions can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (Digital Subscriber Line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The above computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server, data center, etc. that contains one or more available media integrated. The above-mentioned available media can be magnetic media (for example, floppy disks, hard disks, tapes), optical media (for example, digital versatile discs (DVD)), or semiconductor media (for example, solid state drives (SSD)), etc.
[0168] It should be noted that the above description is of a specific embodiment of the present specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0169] The above is only a specific implementation of this specification, but the protection scope of this specification is not limited to this. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in this specification, which should be included in the protection scope of this specification. Therefore, equivalent changes made according to the claims of this specification are still within the scope covered by this specification.
Claims
1. A method for adding a device, characterized in that: Applied to a server, the method comprises: Receiving a link setting request for a device to be added sent by a terminal, wherein the link setting request is sent by the terminal in response to adding the device to be added to a target account, and the target account is logged in at the terminal; Obtaining a network diagram corresponding to the target account, wherein the network diagram is determined according to a link of an added device associated with the target account; Determining whether there is a device to be replaced among the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; In the case that the device to be replaced exists in the added devices, sending a first link setting response about the scene link of the device to be added to the terminal; in the case that the device to be replaced does not exist in the added devices, sending a second link setting response about the scene link of the device to be added to the terminal; The determining, based on the characteristic information about the device to be added in the link setting request and the network diagram, whether there is a device to be replaced in the added devices includes: Determine the target trigger node and the target execution node corresponding to the device to be added according to the characteristic information of the device to be added; Calculating a first similarity between the target trigger node and the nodes included in the network graph, and calculating a second similarity between the target execution node and the nodes included in the network graph; It is determined whether there is a device to be replaced in the added devices according to the first similarity and the second similarity.
2. The method according to claim 1, characterized in that Before determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram, the method further includes: Determine the network diagram according to the links respectively corresponding to each device in the added devices; Among them, the target link corresponding to the target device includes at least one trigger node and at least one execution node, the trigger node in the target link corresponds to the trigger condition for the target device to start, end, enter or exit the target function, and the execution node in the target link corresponds to the target device to start, end, enter or exit the target function.
3. The method according to claim 2, characterized in that The determining the network diagram according to the links respectively corresponding to each device in the added devices includes: Determine the same nodes in the multiple links corresponding to the added devices to obtain the common nodes; The network graph is determined based on the directed relationships between nodes contained in the links corresponding to the common nodes and each of the added devices.
4. The method according to claim 1, characterized in that: The determining, according to the first similarity and the second similarity, whether there is a device to be replaced in the added devices includes: When there is a first similarity that satisfies a preset condition and there is a second similarity that satisfies a preset condition, determining that there is a device to be replaced in the added devices; In the case that there is no first similarity satisfying the preset condition and / or there is no second similarity satisfying the preset condition, it is determined that there is no device to be replaced in the added devices.
5. The method according to claim 4, characterized in that The method further comprises: When it is determined that there is a device to be replaced among the added devices, an added device that satisfies the first similarity and satisfies the second similarity is obtained to obtain the device to be replaced.
6. The method according to any one of claims 1 to 5, characterized in that When the device to be replaced exists in the added devices, sending a first link setting response about the scene link of the device to be added to the terminal includes: In a case where the device to be replaced exists in the added devices, acquiring a link related to the device to be replaced in the network diagram; generating a first link setup response for a scenario link of the device to be added according to the link associated with the device to be replaced, and / or determining the link associated with the device to be replaced as the first link setup response for the scenario link of the device to be added; The first link setup response is sent to the terminal.
7. The method according to claim 6, characterized in that After sending the first link setup response to the terminal, the method further includes: Receiving first response information about the first link setting response sent by the terminal, wherein the first response information includes: receiving the first link setting response, or modifying the first link setting response; A link about the device to be added is determined according to the first response information, and the link of the device to be added is added to the network diagram to update the network diagram.
8. The method according to any one of claims 1 to 5, characterized in that When the device to be replaced does not exist in the added devices, sending a second link setting response about the scene link of the device to be added to the terminal includes: In the case that the device to be replaced does not exist in the added devices, acquiring the added devices that meet the first similarity or the second similarity, and obtaining the related devices of the setting to be added; Acquire links related to the related devices in the network diagram; generating a second link setting response regarding the scene link of the device to be added according to the link related to the related device; The second link setup response is sent to the terminal.
9. The method according to claim 8, characterized in that After sending the second link setup response to the terminal, the method further includes: Receiving second response information about the second link setting response sent by the terminal, the second response information including: receiving the second link setting response, or modifying the second link setting response on the basis of the second link setting response; A link about the device to be added is determined according to the second response information, and the link of the device to be added is added to the network diagram to update the network diagram.
10. The method according to any one of claims 1 to 5, characterized in that The server, the terminal and the device to be added are connected based on a wide area network.
11. A method for adding a device, characterized in that: Applied to a terminal, the method comprises: Sending a link setting request for a device to be added to a server, wherein the link setting request is sent by the terminal in response to adding the device to be added to a target account, and the target account is logged in at the terminal; so that the server obtains a network diagram corresponding to the target account, the network diagram being: determined according to the link of the added device associated with the target account; determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; and, in the case that the device to be replaced exists in the added devices, sending a first link setting response about the scene link of the device to be added to the terminal; in the case that the device to be replaced does not exist in the added devices, sending a second link setting response about the scene link of the device to be added to the terminal; the determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram comprises: determining a target trigger node and a target execution node corresponding to the device to be added according to the characteristic information of the device to be added; calculating a first similarity between the target trigger node and a node included in the network diagram, and calculating a second similarity between the target execution node and a node included in the network diagram; determining whether there is a device to be replaced in the added devices according to the first similarity and the second similarity; The first link setup response or the second link setup response sent by the server is received.
12. A device for adding equipment, characterized in that: Configured on a server, the device includes: A first receiving module is used to: receive a link setting request for a device to be added sent by a terminal, wherein the link setting request is sent by the terminal in response to adding the device to be added to a target account, and the target account is logged in at the terminal; An acquisition module, configured to: acquire a network diagram corresponding to the target account, wherein the network diagram is determined according to a link of an added device associated with the target account; A determination module, used to: determine whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; the determination of whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram, including: determining a target trigger node and a target execution node corresponding to the device to be added according to the characteristic information of the device to be added; calculating a first similarity between the target trigger node and a node included in the network diagram, and calculating a second similarity between the target execution node and a node included in the network diagram; determining whether there is a device to be replaced in the added devices according to the first similarity and the second similarity; The first sending module is used to: when the device to be replaced exists in the added devices, send a first link setting response about the scene link of the device to be added to the terminal; when the device to be replaced does not exist in the added devices, send a second link setting response about the scene link of the device to be added to the terminal.
13. A device for adding equipment, characterized in that: Configured in a terminal, the device includes: The second sending module is used to: send a link setting request for the device to be added to the server, wherein the link setting request is sent by the terminal in response to the device to be added being added to the target account, and the target account is logged in at the terminal; so that the server obtains a network diagram corresponding to the target account, the network diagram being: determined according to the link of the added device associated with the target account; determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram; and, in the case that the device to be replaced exists in the added devices, sending a first link setting response about the scene link of the device to be added to the terminal; in the case that the device to be replaced does not exist in the added devices, sending a second link setting response about the scene link of the device to be added to the terminal; the determining whether there is a device to be replaced in the added devices according to the characteristic information about the device to be added in the link setting request and the network diagram comprises: determining a target trigger node and a target execution node corresponding to the device to be added according to the characteristic information of the device to be added; calculating a first similarity between the target trigger node and a node included in the network diagram, and calculating a second similarity between the target execution node and a node included in the network diagram; determining whether there is a device to be replaced in the added devices according to the first similarity and the second similarity; The second receiving module is configured to receive the first link setting response or the second link setting response sent by the server.
14. A device adding system, characterized in that: The system comprises: a server and a terminal; The server is used to execute the device adding method according to any one of claims 1 to 10, and the terminal is used to execute the device adding method according to claim 11.
15. A computer-readable storage medium, wherein instructions are stored in the computer-readable storage medium. When the instructions are executed on a computer or a processor, the computer or the processor executes the device adding method as described in any one of claims 1 to 10, or executes the device adding method as described in claim 11.
16. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, it implements the device adding method according to any one of claims 1 to 10, or executes the device adding method according to claim 11.
Citation Information
Patent Citations
Smart home system and control method thereof
CN104898449A
Intelligent equipment network access method and device and intelligent equipment control system and method
CN111711698A