Embedded-representation-based vehicle control method and apparatus, and electronic device and medium
By generating and searching embedded vectors combined with knowledge graph analysis, the contradiction between the arbitrary nature of user spoken expression and the normative nature of machine expression in speech interaction is solved, and the accurate understanding and response of intelligent vehicles to omit word commands is achieved, improving interaction accuracy sex.
Patent Information
- Application Number
- PCT/CN2024/092947
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-05-23
- Filing Date
- 2024-05-13
- Publication Date
- 2024-11-28
AI Technical Summary
In voice interaction, there is a contradiction between the arbitraryness that can be omitted when the user expresses orally and the strong normative expression of the machine, which makes it impossible for the intelligent vehicle to accurately understand the user's omitted word commands.
By generating embedded vectors corresponding to vehicle control commands, and finding the most similar embedded vectors in the standard vector library, combined with preset knowledge graph analysis processing, accurate understanding of user commands and vehicle action control is achieved.
It effectively resolves the contradiction between the arbitrary nature of user oral expression and the normative nature of machine expression, ensures that intelligent vehicles can accurately understand and respond to user omitted word commands, and improves the accuracy and user experience of voice interaction.
Smart Images

Figure CN2024092947_28112024_PF_FP_ABST
Abstract
Description
Vehicle control method, device, electronic device and medium based on embedded representation
[0001] This application claims priority to the Chinese patent application filed with the China Patent Office on May 23, 2023, with application number 202310596307.1 and application name “Vehicle control method, device, electronic device and medium based on embedded representation”, the entire contents of which are incorporated by reference into this application. Technical Field
[0002] The present application relates to voice interaction technology, and in particular to a vehicle control method, device, electronic device and medium based on embedded representation. Background Art
[0003] With the development of technology and changes in market demand, voice interaction has become an important way of interaction in current smart cars.
[0004] In practical applications, when users interact with speech, they may need to omit some words in certain scenarios to still convey a complete semantic expression. However, machine language expressions require strong standardization and strong logic, resulting in a contradiction between the strong standardization of machine expressions and the arbitrary omission of user spoken language. This application aims to resolve this contradiction.
[0005] Summary of the Invention
[0006] The present application provides a vehicle control method, device, electronic device and medium based on embedded representation, which are used to resolve the contradiction between the optional randomness of user oral expression and the strong normative expression of the machine.
[0007] In one aspect, the present application provides a vehicle control method based on embedded representation, the method comprising:
[0008] When a vehicle control command is obtained, generating a first embedded vector corresponding to the vehicle control command according to a preset model;
[0009] Searching for a second embedded vector having the highest similarity to the first embedded vector in a standard vector library, and using the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector; the standard vector library includes a plurality of second embedded vectors, each of the second embedded vectors being generated from the first sentence or a second sentence corresponding to the first sentence according to the preset model;
[0010] The target embedded vector is parsed according to a preset knowledge graph to obtain a parsing result, and the vehicle is controlled to complete the target action according to the parsing result.
[0011] In another possible implementation, before obtaining the vehicle control command, the method further includes:
[0012] Acquire vehicle control corpus, and construct the preset knowledge graph based on the vehicle control corpus;
[0013] The first sentence and the second sentence are generated according to the preset knowledge graph, and a standard corpus is updated according to the first sentence and the second sentence; the first sentence includes words used to represent entities, operations, features, and feature values; the second sentence is an unambiguous sentence obtained by omitting at least one of the entities, operations, features, and feature values from the first sentence;
[0014] The standard corpus is input into the preset model to obtain a second embedded vector corresponding to the first sentence and a second embedded vector corresponding to the second sentence.
[0015] In another possible implementation, generating the second statement according to the preset knowledge graph includes:
[0016] Determine, based on the preset knowledge graph, a first document and a second document for each entity, wherein the first document includes a first term within a two-hop range corresponding to the entity, and the second document includes a second term within a one-hop range corresponding to a feature of the entity, and the number of the second documents is equal to the number of features included in the entity;
[0017] Calculating a first reverse file frequency value for the first term, and calculating a second reverse file frequency value for the second term, wherein the first reverse file frequency value is related to a number of first documents containing the first term, and the second reverse file frequency value is related to a number of second documents containing the second term;
[0018] The second statement is generated according to the first reverse file frequency value and / or the second reverse file frequency value and the first statement.
[0019] In another possible implementation, searching a standard vector library for a second embedded vector having the highest similarity to the first embedded vector, and using the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector, includes:
[0020] calculating a cosine distance between the first embedded vector and the second embedded vector;
[0021] According to the cosine distance, a second embedded vector having the highest similarity to the first embedded vector is searched, and the second embedded vector having the highest similarity to the first embedded vector is used as a target embedded vector.
[0022] In another possible implementation, searching for a second embedded vector having the highest similarity to the first embedded vector based on the cosine distance, and using the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector, includes:
[0023] Obtaining a second embedded vector whose cosine distance is greater than a first preset threshold, where the first preset threshold is obtained by calculating the cosine distance of embedded vectors of a large number of positive example sentences with the same meaning and negative example sentences with different meanings;
[0024] A sorting queue is obtained according to the cosine distance of each second embedded vector, and the second embedded vector at the first position of the sorting queue is used as the target embedded vector; the second embedded vectors in the sorting queue are sorted according to the rule of the cosine distance from large to small.
[0025] In another possible implementation, the method further includes:
[0026] Acquire target corpus, update the preset knowledge graph according to the target corpus, and obtain an updated first sentence;
[0027] If there is an updated second statement corresponding to the updated first statement, updating the standard corpus and the standard vector library according to the updated first statement and the updated second statement;
[0028] Otherwise, the standard corpus and the standard vector library are updated according to the first update statement.
[0029] In another possible implementation, before obtaining the target corpus, the method further includes:
[0030] When receiving an error prompt instruction fed back by the user, the text corresponding to the vehicle control command is used as the target corpus;
[0031] When the cosine distances are all less than a second preset threshold, the text corresponding to the vehicle control command is used as the target corpus, and the second preset threshold is obtained by calculating the cosine distance based on the embedded vectors of a large number of positive sentences with the same meaning and negative sentences with different meanings.
[0032] In a second aspect, the present application provides a vehicle control device based on embedded representation, the device comprising a generation module, a search module and a control module, wherein:
[0033] The generating module is configured to generate a first embedded vector corresponding to the vehicle control command according to a preset model when the vehicle control command is acquired;
[0034] The search module is configured to search a standard vector library for a second embedded vector having the highest similarity to the first embedded vector, and use the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector; the standard vector library includes a plurality of second embedded vectors, each of the second embedded vectors being generated from the first sentence or a second sentence corresponding to the first sentence according to the preset model;
[0035] The control module is used to parse the target embedded vector according to a preset knowledge graph to obtain a parsing result, and control the vehicle to complete the target action according to the parsing result.
[0036] In another possible implementation, the generating module is further configured to:
[0037] Acquire vehicle control corpus, and construct the preset knowledge graph based on the vehicle control corpus;
[0038] The first sentence and the second sentence are generated according to the preset knowledge graph, and a standard corpus is updated according to the first sentence and the second sentence; the first sentence includes words used to represent entities, operations, features, and feature values; the second sentence is an unambiguous sentence obtained by omitting at least one of the entities, operations, features, and feature values from the first sentence;
[0039] The standard corpus is input into the preset model to obtain a second embedded vector corresponding to the first sentence and a second embedded vector corresponding to the second sentence.
[0040] In another possible implementation, the generating module is specifically configured to:
[0041] Determine, based on the preset knowledge graph, a first document and a second document for each entity, wherein the first document includes a first term within a two-hop range corresponding to the entity, and the second document includes a second term within a one-hop range corresponding to a feature of the entity, and the number of the second documents is equal to the number of features included in the entity;
[0042] Calculating a first reverse file frequency value for the first term, and calculating a second reverse file frequency value for the second term, wherein the first reverse file frequency value is related to a number of first documents containing the first term, and the second reverse file frequency value is related to a number of second documents containing the second term;
[0043] The second statement is generated according to the first reverse file frequency value and / or the second reverse file frequency value and the first statement.
[0044] In another possible implementation, the search module is specifically configured to:
[0045] calculating a cosine distance between the first embedded vector and the second embedded vector;
[0046] According to the cosine distance, a second embedded vector having the highest similarity to the first embedded vector is searched, and the second embedded vector having the highest similarity to the first embedded vector is used as a target embedded vector.
[0047] In another possible implementation, the search module is specifically configured to:
[0048] Obtaining a second embedded vector whose cosine distance is greater than a first preset threshold, where the first preset threshold is obtained by calculating the cosine distance of embedded vectors of a large number of positive example sentences with the same meaning and negative example sentences with different meanings;
[0049] A sorting queue is obtained according to the cosine distance of each second embedded vector, and the second embedded vector at the first position of the sorting queue is used as the target embedded vector; the second embedded vectors in the sorting queue are sorted according to the rule of the cosine distance from large to small.
[0050] In another possible implementation, the generating module is further configured to:
[0051] Acquire target corpus, update the preset knowledge graph according to the target corpus, and obtain an updated first sentence;
[0052] If there is an updated second statement corresponding to the updated first statement, updating the standard corpus and the standard vector library according to the updated first statement and the updated second statement;
[0053] Otherwise, the standard corpus and the standard vector library are updated according to the first update statement.
[0054] In another possible implementation, the generating module is further configured to:
[0055] When receiving an error prompt instruction fed back by the user, the text corresponding to the vehicle control command is used as the target corpus;
[0056] When the cosine distances are all less than a second preset threshold, the text corresponding to the vehicle control command is used as the target corpus, and the second preset threshold is obtained by calculating the cosine distance based on the embedded vectors of a large number of positive sentences with the same meaning and negative sentences with different meanings.
[0057] In a third aspect, the present application provides an electronic device, comprising: at least one processor and a memory;
[0058] The memory stores computer-executable instructions;
[0059] The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor performs the method as described in any one of the first aspects above.
[0060] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method as described in any one of the first aspects above.
[0061] The present application provides a vehicle control method, device, electronic device and medium based on embedded representation. The method of the present application is applied to intelligent vehicles. Based on this method, when a vehicle control command for instructing an intelligent vehicle to complete a target action is obtained, the vehicle control command is first input into a preset model to obtain its corresponding first embedded vector. Secondly, a second embedded vector with the highest similarity to the first embedded vector is searched in the standard vector library, and the second embedded vector is used as a target embedded vector. Finally, the target embedded vector is parsed according to a preset knowledge graph in the field of vehicle control to obtain a parsing result, thereby completing the understanding of the vehicle control command, so that the intelligent vehicle can control the intelligent vehicle to complete the target action according to the parsing result.
[0062] In this application, the standard vector library includes the second embedded vector generated by the first sentence and the second embedded vector generated by the second sentence. Therefore, during the use of the smart vehicle, as long as the vehicle control command input by the user is a sentence that is unambiguous and can be directly and clearly understood after omitting some words, the smart vehicle can accurately understand it and provide corresponding feedback. The method of this application effectively resolves the contradiction between the arbitrary omission of users' spoken expressions and the strong standardization of machine expression. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0064] FIG1 is a schematic diagram of a scenario of human-vehicle voice interaction provided by an embodiment of the present application;
[0065] FIG2 is a flow chart of a vehicle control method based on embedded representation according to an embodiment of the present application;
[0066] FIG3 is a second flow chart of a vehicle control method based on embedded representation provided in an embodiment of the present application;
[0067] FIG4a is a schematic diagram of a flow chart of a method for acquiring a standard vector library provided in an embodiment of the present application;
[0068] FIG4 b is a schematic diagram of the structure of a vehicle control field knowledge graph provided in an embodiment of the present application;
[0069] FIG5 is a third flow chart of a vehicle control method based on embedded representation provided in an embodiment of the present application;
[0070] FIG6 is a schematic structural diagram of a vehicle control device based on embedded representation according to an embodiment of the present application;
[0071] FIG7 is an electronic device provided in an embodiment of the present application.
[0072] The above drawings illustrate specific embodiments of the present application, which will be described in more detail below. These drawings and the textual description are not intended to limit the scope of the present application in any way, but rather to illustrate the concepts of the present application to those skilled in the art by reference to specific embodiments. DETAILED DESCRIPTION
[0073] Exemplary embodiments will be described in detail herein, with examples illustrated in the accompanying drawings. In the following description, when referring to the drawings, identical numerals in different figures represent identical or similar elements, unless otherwise indicated. The embodiments described in the following exemplary embodiments are not intended to represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present application, as detailed in the appended claims.
[0074] With the rise of connected vehicles and artificial intelligence (AI), smart vehicles are increasingly equipped with more and more features. These numerous features and increasingly complex interfaces compete for the driver's attention. In this era of human-machine co-driving, voice interaction technology offers a unique advantage, reducing drivers' reliance on manual operation of in-vehicle devices and thus increasing driving safety.
[0075] FIG1 is a schematic diagram of a human-vehicle voice interaction scenario provided by an embodiment of the present application. As shown in FIG1 , the human-vehicle interaction system generally includes an electronic device 10 and a controlled vehicle device 20 communicatively connected to the electronic device 10. Specifically, the electronic device 10 is used to collect vehicle control commands issued by the user, parse the vehicle control commands after obtaining them, obtain a parsing result, and control the corresponding controlled vehicle device 20 based on the parsing result. The controlled vehicle device 20 includes an air conditioner, a refrigerator, etc.
[0076] In the above process, the vehicle control command input by the user may be a sentence that is clearly understandable to the user even after omitting one or more words. However, the electronic device 10 cannot clearly understand it, and thus cannot accurately control the vehicle controlled device 20. In other words, there is a contradiction between the arbitrariness of omission in the user's oral expression and the strong standardization of the machine's expression. For example, when the smart vehicle only includes one vehicle controlled device 20 that can set humidity, such as an air conditioner, the vehicle control command input by the user is: "Lower the humidity to 25", which is already clearly expressed. However, the electronic device 10 cannot promptly and accurately determine which vehicle controlled device 20 the user needs to control.
[0077] The present application provides a vehicle control method, device, electronic device and medium based on embedded representation to solve the above problems. The present application first generates a knowledge graph based on the vehicle control corpus in the field of vehicle control, and secondly, generates a first sentence and a second sentence based on the knowledge graph, wherein the first sentence should include the vehicle controlled device 20 and the action that needs to be completed by it. The second sentence is a sentence that can still be clearly expressed after omitting the words used to represent the vehicle controlled device 20 or the action. Finally, when the vehicle control command is obtained, the first sentence or the second sentence that matches the vehicle control command is searched from the standard corpus containing the first sentence and the second sentence, and the corresponding vehicle controlled device 20 is controlled based on the first sentence or the second sentence.
[0078] The method of the present application generates a first sentence and a second sentence based on a preset knowledge graph, so that when a clearly expressed omitted sentence input by the user is received, the second sentence that is most similar to the sentence can be accurately found, which is conducive to quickly and accurately understanding the user command, so as to accurately make corresponding feedback actions.
[0079] It is worth noting that the method of the present application is performed by an electronic device 10. The electronic device 10 can be independently mounted on a smart vehicle and communicatively connected to the vehicle controlled device 20. Alternatively, the electronic device 10 can be directly embedded in each vehicle controlled device 20, which is not limited in this application. In the embodiment of the present application, the electronic device 10 is independently mounted on a smart vehicle, and the communication method between the electronic device 10 and the vehicle controlled device 20 is not limited in this embodiment, as long as communication can be achieved.
[0080] Specifically, the method of this embodiment includes:
[0081] S1, when a vehicle control command is obtained, a first embedded vector corresponding to the vehicle control command is generated according to a preset model.
[0082] Among them, the vehicle control command is used to instruct the current vehicle to complete the target operation. Specifically, it is used to instruct any vehicle controlled device of the current vehicle to complete the target operation. For example, the vehicle control command can be used to instruct the air-conditioning equipment in the vehicle to adjust the temperature to 25°C, and can also be used to instruct the vehicle's shifting device to adjust the current gear to the target gear.
[0083] The preset model is used to convert the text corresponding to the vehicle control command into a vector expression. It is obtained by training the corresponding original model based on similar corpus pairs in the vehicle control field. Specifically, similar corpus pairs are used to instruct the current vehicle to complete the same operation.
[0084] It is understandable that the preset model can be a word embedding model, a bag-of-words model, or a bidirectional encoder representation from Transformer (BERT) model, as long as the first embedded vector expressing the vehicle control command can be obtained.
[0085] S2, searching for the second embedded vector with the highest similarity to the first embedded vector in the standard vector library, and taking the second embedded vector with the highest similarity to the first embedded vector as the target embedded vector.
[0086] It is understood that the standard vector library includes multiple second embedded vectors, each of which is a vector representation of a first statement or a second statement corresponding to the first statement. The first statement includes a user-indicated vocabulary for a controlled subject, a controlled behavior, a controlled characteristic, and a characteristic value. Specifically, the controlled subject can be any vehicle controlled device, the controlled behavior includes any vocabulary used to indicate adjustment, such as increase, raise, lower, etc., and the controlled characteristic is the characteristic of the corresponding vehicle controlled device. For example, for a vehicle's air conditioning equipment, its characteristics may include temperature, humidity, etc., and correspondingly, the characteristic value is used to represent a specific temperature value or a specific humidity value. The second statement is an unambiguous statement obtained by omitting at least one of the above-mentioned controlled subject, controlled behavior, controlled characteristic, and characteristic value from the first statement. For example, "air conditioning 25°C" is a second statement corresponding to the first statement "adjust the air conditioning temperature to 25°C."
[0087] Based on this, when the first embedded vector corresponding to the current vehicle control command is obtained, the second embedded vector with the highest similarity to the first embedded vector is searched in the above-mentioned standard vector library to obtain the target embedded vector for representing any first sentence or the first sentence.
[0088] Specifically, the similarity between the first embedded vector and the second embedded vector can be calculated using a cosine similarity algorithm. In practical applications, the similarity between the first embedded vector and the second embedded vector can also be calculated using any algorithm for calculating vector similarity, such as Euclidean distance and Manhattan distance. This embodiment is not limited to this.
[0089] S3, parses the target embedded vector according to the preset knowledge graph to obtain the parsing result, and controls the vehicle to complete the target action based on the parsing result.
[0090] It can be understood that the preset knowledge graph is composed of control corpus in the field of vehicle control. By parsing the target embedded vector based on the preset knowledge graph, the corresponding parsing results can be obtained, so that the vehicle can be controlled to complete the target action according to the parsing results.
[0091] Through the method of this embodiment, for any vehicle control command input by the user, regardless of whether it belongs to the first sentence or the second sentence corresponding to the first sentence, the electronic device can obtain the target embedded vector with the highest similarity to the first embedded vector based on the first embedded vector corresponding to the current vehicle control command. It then parses the target embedded vector based on the preset knowledge graph and controls the vehicle to complete the corresponding target action based on the target embedded vector. Therefore, in actual applications, even if the user enters a sentence that omits some words but still needs to be accurately understood, the electronic device can respond to these sentences and make accurate controls, effectively resolving the contradiction between the arbitrary omissions in user oral expression and the strong standardization of machine expression.
[0092] The following describes some embodiments of the present application in detail with reference to the accompanying drawings. In the event that the embodiments do not conflict with each other, the following embodiments and features therein may be combined with each other.
[0093] In one possible implementation, FIG2 is a flow chart of a vehicle control method based on embedded representation provided in an embodiment of the present application. As shown in FIG2 , the method provided in this embodiment includes:
[0094] S201: When a vehicle control command is obtained, a first embedded vector corresponding to the vehicle control command is generated according to the simBERT model.
[0095] Among them, vehicle control commands are used to instruct the vehicle to complete the target action. The simBERT model is obtained by training the original simBERT model based on similar corpus pairs in the vehicle control field. The sentences in the similar corpus pairs are used to instruct the vehicle to complete the same action.
[0096] Specifically, the vehicle control command is input by the user. In this embodiment, the vehicle control command is obtained after the electronic device is awakened. The electronic device can be awakened by the user inputting a wake-up command preset in the electronic device through voice, or by the user pressing a button preset on the electronic device.
[0097] For example, in this embodiment, a wake-up command "Hello, Mr. X" is preset in the electronic device. When the user inputs "Hello, Mr. X" by voice, the electronic device is awakened. At this time, if the user needs to control the air conditioner of the vehicle to turn on, the user can input the vehicle control command "Turn on the air conditioner".
[0098] In this embodiment, the electronic device pre-trains the simBERT original model based on similar corpus in the field of vehicle control to obtain a trained simBERT model, so that the simBERT model can obtain a more accurate first embedded vector when generating a first embedded vector based on the vehicle control command.
[0099] S202: Searching for a second embedded vector having the highest similarity to the first embedded vector in a standard vector library, and using the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector.
[0100] The standard vector library includes multiple second embedded vectors, and the second embedded vectors are generated by the first sentence or the second sentence according to the simBERT model.
[0101] Specifically, the first statement includes words representing entities, operations, features, and feature values. The second statement is the unambiguous version of the first statement obtained by omitting at least one of the entities, operations, features, and feature values. An entity is any controlled entity, i.e., a controlled device in a vehicle; an operation is any controlled behavior, i.e., any adjustment behavior; a feature is a characteristic of the corresponding controlled entity; and a feature value is the characteristic value corresponding to the corresponding feature.
[0102] It can be understood that, in this embodiment, the electronic device obtains the first sentence and the second sentence in advance, and inputs the first sentence and the second sentence into the simBERT model to obtain a standard vector library including multiple second embedded vectors.
[0103] In this embodiment, the electronic device can directly compare the first embedded vector with each second embedded vector in the standard vector library one by one to find the second embedded vector that is most similar to it. Alternatively, the electronic device can calculate the cosine distance between the first embedded vector and each second embedded vector in the standard vector library one by one, and then use the cosine distance to find the second embedded vector that is most similar to the first embedded vector. In actual applications, other methods can also be used to determine the target embedded vector corresponding to the first embedded vector, and this embodiment of the present application is not limited to this method.
[0104] S203: Analyze the target embedded vector according to the knowledge graph in the field of vehicle control to obtain an analysis result, and control the vehicle to complete the target action according to the analysis result.
[0105] In this embodiment, the knowledge graph is constructed based on the vehicle control corpus in the field of vehicle control. The refined knowledge data model stored in its pattern layer can be expressed as entity-feature-relationship-feature value, or as feature-feature value-relationship-entity, which is not limited in this embodiment.
[0106] For example, if represented as entity-feature-relationship-feature value, when parsing the target embedded vector, the four slots corresponding to the entity, feature, relationship, and feature value are obtained. Furthermore, if the vehicle control command is to set the air conditioning temperature to 25°C, the final parsing result obtained by the electronic device based on the knowledge graph includes the slot values corresponding to each slot: air conditioning; temperature; set to; 25°C.
[0107] In the method provided in this embodiment, upon receiving a vehicle control command, the electronic device generates a first embedded vector corresponding to the vehicle control command based on the simBERT model. It then searches a standard vector library for a second embedded vector that is most similar to the first embedded vector and uses this second embedded vector as the target embedded vector. The electronic device then parses the target embedded vector based on the knowledge graph to understand the vehicle control command input by the user and controls the vehicle to complete the target action based on the command.
[0108] In the method of the present application, the standard vector library includes second embedded vectors corresponding to the first and second sentences, wherein the second sentence is a sentence that can be clearly understood by the user but cannot be clearly understood by the electronic device. In the present application, the electronic device pre-generates the second sentence and generates the corresponding second embedded vector through the simBERT model, so that in actual use, if the user inputs such a second sentence, the electronic device can accurately understand it and then accurately control the vehicle controlled device.
[0109] FIG3 is a second flow chart of a vehicle control method based on embedded representation provided by an embodiment of the present application. This embodiment, based on the above embodiment, defines the method for searching for a target embedded vector in a standard vector library. Specifically, as shown in FIG3 , the method provided by this embodiment includes:
[0110] S301: When a first embedded vector is obtained, a cosine distance between the first embedded vector and a second embedded vector is calculated.
[0111] Among them, the calculation formula of cosine distance is Specifically, A is used to represent the first embedded vector, and B is used to represent the second embedded vector.
[0112] S302: Obtain a second embedded vector whose cosine distance is greater than a first preset threshold.
[0113] The first preset threshold is obtained by calculating the cosine distance between the embedded vectors of a large number of positive example sentences with the same meaning and negative example sentences with different meanings.
[0114] Exemplarily, if the calculated first preset threshold is 0.8, it is necessary to obtain a second embedded vector having a cosine distance greater than 0.8.
[0115] S303 , sorting the second embedded vectors according to the cosine distance from large to small to obtain a sorting queue, and taking the second embedded vector at the first position in the sorting queue as the target embedded vector.
[0116] In practical applications, the cosine distances may be sorted in ascending order to obtain a sorted queue. In this case, the second embedded vector at the end is used as the target embedded vector.
[0117] The method provided in this embodiment uses the cosine distance between the first embedded vector and the second embedded vector to find the second embedded vector that is most similar to the first embedded vector, which is conducive to obtaining a more accurate target embedded vector, and further helps the vehicle to accurately complete the target action according to the vehicle control command.
[0118] FIG4a is a flow chart of a method for obtaining a standard vector library provided in an embodiment of the present application. This embodiment, based on the previous embodiment, defines the method for obtaining the standard vector library. Specifically, as shown in FIG4a, the method provided in this embodiment includes:
[0119] S401a, obtain vehicle control corpus and construct a knowledge graph based on the vehicle control corpus.
[0120] The vehicle control corpus includes multiple sentences, each of which is used to instruct any feature of any entity in the vehicle to complete any operation.
[0121] It's understandable that the entity in this embodiment is the vehicle controlled device described in the previous embodiments—that is, any controllable smart device on the vehicle. Features are the characteristics of an entity. For example, if the entity is an air conditioner, its corresponding features include temperature, humidity, air volume, wind speed, circulation mode, and so on. "Set the air conditioner temperature to 25°C" is a sentence in the vehicle control corpus that indicates that the temperature of the vehicle's air conditioner has been set to 25°C.
[0122] Furthermore, after obtaining the vehicle control corpus, a knowledge graph is constructed based on each entity in the vehicle control corpus, each feature corresponding to the entity, and each feature value corresponding to the feature. For example, Figure 4b is a structural diagram of a vehicle control field knowledge graph provided in an embodiment of the present application. Specifically, based on the vehicle control corpus, it is analyzed that the entities contained in the vehicle are: air conditioner, refrigerator, speaker, and window. The operations, features, and feature values corresponding to each entity can be found in Figure 4b. For example, in Figure 4b, for the air conditioner, it includes three features: mode, temperature, and humidity. Furthermore, the operation between the entity and the temperature can be increase / decrease, and the feature value corresponding to the temperature is X degrees.
[0123] S402a, generating a first sentence based on the knowledge graph.
[0124] The first sentence includes words used to represent entities, operations, features, and feature values.
[0125] Specifically, the template is used to generate the first sentence based on the entities, operations, features, and feature values in the knowledge graph. For example, for the entity "air conditioner," the corresponding feature is "temperature," the operation is "set," and the feature value is "XX degrees." The first sentence generated is "The air conditioner temperature is set to XX degrees." For the entity "car window," the corresponding feature is "height," the operation is "raise," and the feature value is "XX centimeters." The first sentence generated is "The car window height is raised by XX centimeters."
[0126] S403a: Determine the first document and the second document of each entity based on the knowledge graph.
[0127] The first document includes the first word within two hops corresponding to the entity, the second document includes the second word within one hop corresponding to the feature of the entity, and the number of the second documents is equal to the number of features included in the entity.
[0128] Specifically, in this embodiment, we first identify the entities in the knowledge graph. Then, for each entity, we generate a first document based on the terms within a two-hop range of the entity, and a second document based on the terms within a one-hop range corresponding to the entity's features. That is, each entity corresponds to a first document, and each feature of the entity corresponds to a second document. It is understood that a term in the first document is referred to as a first term, and a term in the second document is referred to as a second term. The first and second terms may be the same term.
[0129] For example, for the knowledge graph shown in Figure 4b, we first determine that it contains four entities: air conditioner, refrigerator, stereo, and car window. Therefore, there are four first documents. For air conditioner, the corresponding first terms within the two-hop range include temperature, X degrees, humidity, X value, mode, cooling, heating, and ventilation. Therefore, the first document for air conditioner includes "temperature, X degrees, humidity, X value, mode, cooling, heating, ventilation." Similarly, the first document for refrigerator includes "temperature, X degrees, mode, energy saving, freezing, refrigeration"; the first document for stereo includes "volume, X value, track, Xth, sound effects, high range, mid-range, low range"; and the first document for car window includes "height, X centimeters, eye color, X color."
[0130] For air conditioning, it includes three characteristics, namely mode, temperature, and humidity. Therefore, there are three second documents for air conditioning. Among them, the second document corresponding to the mode includes "cooling, heating, ventilation", the second document corresponding to the temperature includes "X degrees", and the second document corresponding to the humidity includes "X value".
[0131] For a refrigerator, it includes two features, namely temperature and mode. Therefore, there are two second documents for the refrigerator. The second document corresponding to the temperature includes "X degrees", and the second document corresponding to the mode includes "energy saving, freezing, and refrigeration".
[0132] For audio, it includes three features, namely volume, track, and sound effect. Therefore, there are three second documents for audio. Among them, the secondary entity feature corresponding to the volume includes "X value", the second document corresponding to the track includes "Xth", and the second document corresponding to the sound effect includes "high-end, mid-range, and low-end".
[0133] The car window includes two features, namely height and color. Therefore, there are two second documents for the car window, wherein the secondary entity feature corresponding to the height includes "X centimeters" and the secondary entity feature corresponding to the color includes "X color".
[0134] S404a, calculating a first inverse document frequency value of the first word, and calculating a second inverse document frequency value of the second word.
[0135] The first inverse document frequency value is related to the number of first documents containing the first word, and the second inverse document frequency value is related to the number of second documents containing the second word.
[0136] It is understandable that the reverse file frequency is used to indicate the prevalence of a certain word within a certain range. In this embodiment, the first reverse file frequency value and the second reverse file frequency value are calculated according to the calculation formula of the reverse file frequency value.
[0137] Specifically, the calculation formula for the reverse file frequency value is: Where i represents the number of the first word or the second word, |D| represents the number of the first document or the second document, |j∶t i ∈d j | indicates that the word t is included i The data of the first document or the second document, 1 is to prevent the word t i If the number of documents is 0, the operation will fail.
[0138] For the knowledge graph shown in FIG4b, when calculating the first inverse document frequency value of the first word "temperature", the number of first documents |D| is determined to be 4, and the number of first documents where "temperature" appears |j:t i ∈d j | is 2, so the first inverse file frequency value of "temperature" is
[0139] Furthermore, after determining that the entity is sound, when calculating the second inverse document frequency value of the second word "the Xth", it is first determined that the corresponding entity is sound. The number of second documents of sound |D| is 3, and the number of second documents with "the Xth" |j:t i ∈d j | is 1, so the frequency value of the second reverse file of "the Xth" is
[0140] In this embodiment, after obtaining the knowledge graph, the electronic device determines the first document and the second document in advance based on the knowledge graph, and calculates the first inverse file frequency value of each first word and the second inverse file frequency value of each second word.
[0141] S405a: Generate a second statement according to the first reverse file frequency value, the second reverse file frequency value, and the first statement.
[0142] The second statement is an unambiguous statement obtained by omitting at least one of the entity, operation, feature and feature value from the first statement.
[0143] Specifically, through the limitation of S404a in this embodiment, it can be seen that the first reverse file frequency value is calculated based on the first document of each entity and the first document containing the first word, and the second reverse file frequency value is calculated based on the second document of a certain entity and the second document containing the second word, that is, the second reverse file frequency value is calculated for a certain entity, and the premise for calculating the second reverse file frequency value is that the entity has been determined.
[0144] It is understandable that if only one first document contains the first word, it means that the first word can make the corresponding entity have disambiguation. That is to say, as long as the first word appears, it can be confirmed without a doubt that it is associated with the entity. Therefore, for the first sentence containing the first word, the words used to represent the entity can be omitted. At this time, the first reverse document frequency value of the first word is is the maximum first inverse document frequency value, where |D1| is the number of first documents.
[0145] If only one second document contains the second word, it means that the second word can make the corresponding feature have disambiguation. In other words, as long as the second word appears, it can be confirmed without a doubt that it is associated with a certain feature of the entity. Therefore, for the first sentence containing the second word, the feature it contains can be omitted. At this time, the second reverse document frequency value of the second word is is the maximum second reverse document frequency value, where |D2| is the number of second documents.
[0146] Furthermore, in this embodiment, for each first sentence, it is determined whether entities and / or features in the first sentence can be omitted based on the first inverse file frequency value and / or the second inverse file frequency value of each word in the first sentence, thereby obtaining a second sentence.
[0147] Specifically, the electronic device first obtains the first reverse file frequency value corresponding to the words other than the entity in the first sentence, and if there is a word with a second reverse file frequency value, obtains the second reverse file frequency value at the same time.
[0148] The electronic device determines whether there is a first reverse file frequency value in each word other than the entity in the first sentence. to determine whether the entity in the first sentence can be omitted. If so, the entity in the first sentence can be omitted to obtain the second sentence.
[0149] The electronic device determines whether there is a second reverse file frequency value in the first sentence. The word is used to determine whether the feature in the first sentence can be omitted. If so, the feature in the first sentence can be omitted to obtain the second sentence.
[0150] It is understandable that if in the first statement, there is a first reverse file frequency value of There is a second reverse file with a frequency value of , it means that the entities and features in the first sentence can be omitted.
[0151] For example, for the knowledge graph shown in Figure 4b, if a first sentence is "The car window color is adjusted to X color," the electronic device first obtains the first reverse file frequency values of the terms "color," "adjust," and "X color." If the first reverse file frequency values of both "color" and "X color" are the maximum first reverse file frequency values, then the entity "car window" and the feature "color" in the first sentence can be omitted. At this point, the second sentence generated based on this standard sentence includes: "The car window is adjusted to X color," "The color is adjusted to X color," and "Adjust to X color."
[0152] Alternatively, for the second sentence generated in the above example, if the feature values corresponding to the features included in it are determined, the words representing the operation included in it can also be omitted. That is, the second sentence of the above first sentence also includes "window X color", "color X color", and "X color".
[0153] In this embodiment, the electronic device calculates the first reverse file frequency value of each word in the knowledge graph and the second reverse file frequency value of some words, and generates a second sentence based on the first reverse file frequency value and / or the second reverse file frequency value and the first sentence.
[0154] Through the method of this embodiment, even when the electronic device receives a vehicle control command input by the user that omits some words but is still clearly understood by the user, it can accurately understand the vehicle control command and provide accurate feedback. Furthermore, the electronic device pre-generates the second sentence, facilitating a timely response from the vehicle.
[0155] FIG5 is a flow chart of a vehicle control method based on embedded representation provided in an embodiment of the present application. This embodiment further defines the method for obtaining a standard vector library based on the previous embodiment. Specifically, as shown in FIG5 , the method provided in this embodiment includes:
[0156] S501: When an error prompt instruction fed back by the user is received and the cosine distance is less than a second preset threshold, the text corresponding to the vehicle control command is used as the target corpus.
[0157] The second preset threshold is obtained by calculating the cosine distance between the embedded vectors of a large number of positive example sentences with the same meaning and negative example sentences with different meanings. It can be understood that when the cosine distance is less than the second preset threshold, it indicates that the two vectors are completely unrelated. This may indicate that the previously collected vehicle control corpus in the vehicle control field does not contain the sentence corresponding to the vector, nor does it contain sentences that are close or similar to the sentence.
[0158] In this embodiment, the user feedback error prompt instruction may be determined to have been received by the electronic device after the electronic device collects the user's dissatisfied statement online, or may be determined to have received the user feedback error prompt instruction when the user inputs a trigger statement pre-set in the electronic device. In actual applications, other methods may also be used to determine whether the user feedback error prompt instruction has been received, which are not limited in this embodiment.
[0159] S502, obtaining the target corpus, updating the knowledge graph according to the target corpus, and obtaining the updated first sentence.
[0160] Specifically, if the target corpus contains entities, features, operations, and feature values that originally exist in the vehicle but do not exist in the original knowledge graph, the original knowledge graph is updated according to the target corpus to obtain an updated knowledge graph.
[0161] Furthermore, an updated first statement is generated in addition to the original first statement based on the updated knowledge graph.
[0162] S503: If there is an updated second statement corresponding to the updated first statement, then the standard corpus and the standard vector library are updated according to the updated first statement and the updated second statement.
[0163] S504: If there is no updated second statement corresponding to the updated first statement, then update the standard corpus and the standard vector library according to the updated first statement.
[0164] It is understandable that the electronic device determines whether there is an updated second statement corresponding to the updated first statement by judging whether there is a word with the largest first reverse file frequency value and / or whether there is a word with the largest second reverse file frequency value in the updated first statement.
[0165] Optionally, the electronic device may acquire the target corpus in real time, and update the standard corpus and the standard vector library each time the target corpus is acquired. Alternatively, the electronic device may periodically acquire the target corpus and, after the period ends, update the standard corpus and the standard vector library based on the acquired target corpus, although this embodiment is not limited thereto.
[0166] In this embodiment, the electronic device captures the target corpus and updates the standard corpus and standard vector library based on the target corpus, so that the electronic device can understand the vehicle control commands in a timely and accurate manner when obtaining the vehicle control commands that the user can clearly understand, thereby improving the user experience.
[0167] The above embodiment introduces a vehicle control method based on embedded representation from the perspective of method flow. The following embodiment introduces a vehicle control device based on embedded representation from the perspective of virtual module or virtual unit. Please refer to the following embodiment for details.
[0168] The embodiment of the present application provides a vehicle control device based on embedded representation, as shown in FIG6 , the device includes a generation module 61 , a search module 62 and a control module 63 , wherein:
[0169] A generating module 61 is configured to generate a first embedded vector corresponding to the vehicle control command according to a preset model when a vehicle control command is obtained;
[0170] a search module 62 configured to search a standard vector library for a second embedded vector having the highest similarity to the first embedded vector, and to use the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector; the standard vector library includes a plurality of second embedded vectors, each second embedded vector being generated from a first statement or a second statement corresponding to the first statement according to a preset model;
[0171] The control module 63 is used to parse the target embedded vector according to the preset knowledge graph to obtain a parsing result, and control the vehicle to complete the target action according to the parsing result.
[0172] In another possible implementation of the embodiment of the present application, the generating module 61 is further configured to:
[0173] Obtain vehicle control corpus and build a preset knowledge graph based on the vehicle control corpus;
[0174] Generate a first sentence and a second sentence based on a preset knowledge graph, and update a standard corpus based on the first sentence and the second sentence; the first sentence includes words used to represent entities, operations, features, and feature values; the second sentence is an unambiguous sentence obtained by omitting at least one of the entities, operations, features, and feature values from the first sentence;
[0175] The standard corpus is input into the preset model to obtain a second embedded vector corresponding to the first sentence and a second embedded vector corresponding to the second sentence.
[0176] In another possible implementation of the embodiment of the present application, the generation module 61 is specifically configured to:
[0177] Determine the first document and the second document for each entity based on the preset knowledge graph. The first document includes the first word within two hops corresponding to the entity, and the second document includes the second word within one hop corresponding to the feature of the entity. The number of the second documents is equal to the number of features included in the entity.
[0178] Calculating a first reverse file frequency value for the first term, and calculating a second reverse file frequency value for the second term, wherein the first reverse file frequency value is related to a number of first documents containing the first term, and the second reverse file frequency value is related to a number of second documents containing the second term;
[0179] A second statement is generated according to the first reverse file frequency value and / or the second reverse file frequency value and the first statement.
[0180] In another possible implementation of the embodiment of the present application, the search module 62 is specifically configured to:
[0181] Calculating a cosine distance between the first embedded vector and the second embedded vector;
[0182] According to the cosine distance, the second embedded vector with the highest similarity to the first embedded vector is found, and the second embedded vector with the highest similarity to the first embedded vector is used as the target embedded vector.
[0183] In another possible implementation of the embodiment of the present application, the search module 62 is specifically configured to:
[0184] Obtaining a second embedded vector whose cosine distance is greater than a first preset threshold, where the first preset threshold is obtained by calculating the cosine distance of embedded vectors of a large number of positive example sentences with the same meaning and negative example sentences with different meanings;
[0185] According to the cosine distance of each second embedded vector, a sorting queue is obtained, and the second embedded vector at the first position in the sorting queue is used as the target embedded vector; the second embedded vectors in the sorting queue are sorted according to the rule of cosine distance from large to small.
[0186] In another possible implementation of the embodiment of the present application, the generating module 61 is further configured to:
[0187] Obtain the target corpus, update the preset knowledge graph according to the target corpus, and obtain the updated first sentence;
[0188] If there is an updated second statement corresponding to the updated first statement, updating the standard corpus and the standard vector library according to the updated first statement and the updated second statement;
[0189] Otherwise, the standard corpus and the standard vector library are updated according to the first update statement.
[0190] In another possible implementation of the embodiment of the present application, the generating module 61 is further configured to:
[0191] When receiving error prompt instructions from users, the text corresponding to the vehicle control command is used as the target corpus;
[0192] When the cosine distances are all less than a second preset threshold, the text corresponding to the vehicle control command is used as the target corpus. The second preset threshold is obtained by calculating the cosine distance based on the embedded vectors of a large number of positive sentences with the same meaning and negative sentences with different meanings.
[0193] An embodiment of the present application provides a vehicle control device based on embedded representation, which is applicable to the above-mentioned method embodiment and will not be described in detail here.
[0194] An embodiment of the present application provides an electronic device, as shown in FIG7 . The electronic device shown in FIG7 includes a processor 71 and a memory 72 . The processor 71 and the memory 72 are connected, for example, via a bus 73 . Optionally, the electronic device may further include a transceiver 74 . It should be noted that in actual applications, the number of transceivers 74 is not limited to one, and the structure of the electronic device does not constitute a limitation on the embodiments of the present application.
[0195] The processor 71 may be a central processing unit (CPU), a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It may implement or execute the various exemplary logic blocks, modules, and circuits described in conjunction with the disclosure of this application. The processor 71 may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, and the like.
[0196] Bus 73 may include a pathway for transmitting information between the aforementioned components. Bus 73 may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, for example. Bus 73 may be classified as an address bus, a data bus, a control bus, or the like. For ease of illustration, FIG7 shows a single bold line, but this does not imply that there is only one bus 73 or only one type of bus 73.
[0197] The memory 72 can be a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a random access memory (RAM) or other type of dynamic storage device that can store information and instructions, or an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compact disc, laser disc, optical disc, digital versatile disc, Blu-ray disc, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited to these.
[0198] The memory 72 is used to store application code for executing the solution of the present application, and the execution is controlled by the processor 71. The processor 71 is used to execute the application code stored in the memory 72 to implement the content shown in the above method embodiment.
[0199] The present application also provides a computer-readable storage medium, which may include: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, and other media that can store program code. Specifically, the computer-readable storage medium stores program instructions, and the program instructions are used to implement the methods in the above embodiments.
[0200] A computer program product is also provided in an embodiment of the present application, including a computer program. When the computer program is executed by a processor, the technical solution of the above-mentioned method embodiment is implemented. Its implementation principle and technical effect are similar and will not be repeated here.
[0201] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the present application that follow the general principles of the present application and include common knowledge or customary techniques in the art not disclosed herein. The description and examples are to be considered merely as exemplary, and the true scope and spirit of the present application are indicated by the claims.
[0202] It should be understood that the present application is not limited to the exact structure described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.
Claims
1. A vehicle control method based on embedded representation, characterized in that: The method comprises: When a vehicle control command is obtained, a first embedded vector corresponding to the vehicle control command is generated according to a preset model; Searching for a second embedded vector having the highest similarity to the first embedded vector in a standard vector library, and using the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector; the standard vector library includes a plurality of second embedded vectors, and the second embedded vector is generated by the first sentence or the second sentence corresponding to the first sentence according to the preset model; The target embedded vector is parsed according to a preset knowledge graph to obtain a parsing result, and the vehicle is controlled to complete the target action according to the parsing result.
2. The method according to claim 1, characterized in that Before obtaining the vehicle control command, the method further includes: Acquire vehicle control corpus, and construct the preset knowledge graph according to the vehicle control corpus; The first sentence and the second sentence are generated according to the preset knowledge graph, and a standard corpus is updated according to the first sentence and the second sentence; the first sentence includes words used to represent entities, operations, features, and feature values; the second sentence is an unambiguous sentence obtained by omitting at least one of the entities, operations, features, and feature values from the first sentence; The standard corpus is input into the preset model to obtain a second embedded vector corresponding to the first sentence and a second embedded vector corresponding to the second sentence.
3. The method according to claim 2, characterized in that The generating the second sentence according to the preset knowledge graph includes: Determine, according to the preset knowledge graph, a first document and a second document for each entity, wherein the first document includes a first word within a two-hop range corresponding to the entity, and the second document includes a second word within a one-hop range corresponding to a feature of the entity, and the number of the second documents is equal to the number of features included in the entity; Calculating a first reverse file frequency value for the first term, and calculating a second reverse file frequency value for the second term, wherein the first reverse file frequency value is related to the number of first documents containing the first term, and the second reverse file frequency value is related to the number of second documents containing the second term; The second statement is generated according to the first reverse file frequency value and / or the second reverse file frequency value and the first statement.
4. The method according to claim 2, characterized in that: The step of searching the standard vector library for a second embedded vector having the highest similarity to the first embedded vector, and taking the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector, comprises: Calculating a cosine distance between the first embedded vector and the second embedded vector; According to the cosine distance, a second embedded vector having the highest similarity to the first embedded vector is searched, and the second embedded vector having the highest similarity to the first embedded vector is used as a target embedded vector.
5. The method according to claim 4, characterized in that The step of searching, according to the cosine distance, a second embedded vector having the highest similarity to the first embedded vector, and taking the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector comprises: Obtain a second embedded vector whose cosine distance is greater than a first preset threshold, wherein the first preset threshold is calculated based on a large number of embedded vectors of positive example sentences with the same meaning and negative example sentences with different meanings. obtained later; According to the cosine distance of each of the second embedded vectors, a sorting queue is obtained, and the second embedded vector at the first position of the sorting queue is used as the target embedded vector; the second embedded vectors in the sorting queue are sorted according to the rule of the cosine distance from large to small.
6. The method according to claim 4, characterized in that The method further comprises: Acquire a target corpus, update the preset knowledge graph according to the target corpus, and obtain an updated first sentence; If there is an updated second statement corresponding to the updated first statement, updating the standard corpus and the standard vector library according to the updated first statement and the updated second statement; Otherwise, the standard corpus and the standard vector library are updated according to the first update statement.
7. The method according to claim 6, characterized in that Before obtaining the target corpus, the method further includes: When receiving an error prompt instruction fed back by the user, taking the text corresponding to the vehicle control command as the target corpus; When the cosine distances are all less than a second preset threshold, the text corresponding to the vehicle control command is used as the target corpus, and the second preset threshold is obtained by calculating the cosine distance based on the embedded vectors of a large number of positive example sentences with the same meaning and negative example sentences with different meanings.
8. A vehicle control device based on embedded representation, characterized in that: The device comprises: A generating module, configured to generate a first embedded vector vehicle control field corresponding to the vehicle control command according to a preset model when a vehicle control command is acquired; A search module, configured to search a standard vector library for a second embedded vector having the highest similarity to the first embedded vector, and use the second embedded vector having the highest similarity to the first embedded vector as a target embedded vector; the standard vector library includes a plurality of second embedded vectors, and the second embedded vector is generated by the first sentence or a second sentence corresponding to the first sentence according to the preset model; The control module is used to parse the target embedded vector according to a preset knowledge graph in the field of vehicle control, obtain a parsing result, and control the vehicle to complete the target action according to the parsing result.
9. An electronic device, characterized in that: include: at least one processor and memory; The memory stores computer-executable instructions; The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the vehicle control method based on embedded representation as described in any one of claims 1-7.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the vehicle control method based on embedded representation as described in any one of claims 1-7.
Citation Information
Patent Citations
Dialog method and system for intelligent robot
CN109102809A
Clinical term standardization method and device, electronic equipment and storage medium
CN113593661A
Voice instruction mapping method and system based on fusion similarity calculation
CN114694643A
Voice interaction method, device and equipment of vehicle and storage medium
CN115641845A
Vehicle control method and device based on embedded representation, electronic equipment and medium
CN116494899A
Cited By
Decision support method for time-space dynamic data of Internet of Vehicles based on knowledge retrieval enhancement
CN119988570A
Decision Support Method for Spatiotemporal Dynamic Data of Internet of Vehicles Enhanced by Knowledge Retrieval
CN119988570B
Knowledge graph driven intelligent analysis system based on medical field
CN120911582A
