A kind of method, apparatus, the equipment of dynamic adjustment TTS casting
Technical field
The present embodiments relate to technical field of information processing, in particular to a kind of method of dynamic adjustment TTS casting, dress
It sets, equipment and computer readable storage medium.
Background technique
With the development and universal, the various aspects offer that the intellectual technologies such as human-computer interaction are lived in people of computer technology
Conveniently service.TTS (Text to Speech) can be realized the conversion from Text To Speech, be in artificial intelligence technology
The important technology of human-computer interaction.TTS is widely used in a variety of intelligent terminals, such as vehicle intelligent terminal.
Existing TTS is usually after receiving new casting information, directly to be broadcasted, alternatively, when connecing when being broadcasted
When receiving multiple casting information, multiple casting information are lined up, are sequentially broadcasted, alternatively, when receiving new casting information,
Previous casting is interrupted, new voice broadcast is directly entered.But in practical applications, above-mentioned processing mode does not consider in real time
Vehicle-state and communication conditions, and the variation of vehicle-state and communication conditions will lead to casting content invalid, so that
User receives invalid or error message, causes user poor using physical examination.
In view of the drawbacks of the prior art, TTS casting how is correctly and efficiently adjusted, the casting effect of TTS casting is improved, mentions
The usage experience of user is risen, establishing more optimized human-computer interaction process is current urgent need to resolve problem.
Summary of the invention
The embodiment of the invention provides method, apparatus, equipment and the computer-readable storages of a kind of adjustment TTS casting of dynamic
Medium can be used for solving the problems in the relevant technologies.
On the one hand, the embodiment of the invention provides a kind of methods of dynamic adjustment TTS casting, which is characterized in that the side
Method includes:
Step 1, it receives one or more TTS and broadcasts information;
Step 2, the casting information is parsed, determines the first casting parameter, wherein the first casting parameter includes survival
Time TTL;
Step 3, according to vehicle's current condition, the second casting parameter is determined, wherein the second casting parameter includes vehicle
Driving direction;
Step 4, according to the first casting parameter and the second casting parameter, it is determined whether execute TTS casting;If
It is to execute step 5;
Step 5, TTS casting is executed.
Preferably, the time-to-live TTL is determined according to following at least any one:
The casting information is parsed, the time-to-live TTL is directly obtained, wherein is deposited described in the casting information carrying
Live time TTL;
The casting information is parsed, casting information type corresponding to the casting information is obtained, according to the casting
Information type determines the time-to-live TTL.
Preferably, which is characterized in that according to the casting information type, determine that the time-to-live TTL includes:
According to the casting information type, matching inquiry is carried out in TTL inquiry table, to obtain the time-to-live TTL,
Wherein, the mapping relations between time-to-live TTL of the TTL inquiry table comprising casting information type and corresponding to it.
Preferably, the first casting parameter further comprises the casting information content;Second casting parameter further includes vehicle
Travel route, and/or, current vehicle position.
Preferably, the step 4 further comprises:
If the time-to-live TTL does not exceed the time limit, but broadcasts the information content and vehicle heading mismatch, then do not execute
TTS casting;
And/or
If the time-to-live TTL does not exceed the time limit, but broadcasts the information content and vehicle heading and mismatches, and with vehicle row
It sails route not meeting, does not then execute TTS casting;
And/or
If the time-to-live TTL does not exceed the time limit, and broadcasts the information content and match with vehicle heading, but broadcast information
Exceed preset distance about the distance between the location information in place and current vehicle position in content, does not then execute TTS casting.
Preferably, the step 5 further comprises: when there are multiple casting information, and broadcasting information is to remind category information
When, according to the sending time and time-to-live TTL of casting information, weight is calculated, priority level is arranged according to the size of weight
Height, according to priority level to remind category information queue be ranked up, successively broadcast;
When there are multiple casting information, and casting information is instruction feedback category information, according to the degree of correlation of casting information
It is grouped and calculates grouping weight to casting information with sending time, for multiple casting information in being grouped, when according to sending
Between determine in the grouping information weight in the groups of multiple casting information, according to the size of information weight in organizing and grouping weight
Size be respectively set grouping in casting information group in casting priority level height and broadcast information block grouping broadcast
Report the height of priority level;Priority level is broadcasted according to the grouping of casting information block, team is grouped to casting information block
Column sequence is successively broadcasted in organizing in each grouping and broadcasts the highest casting information of priority level.
On the other hand, the embodiment of the invention provides a kind of devices of dynamic adjustment TTS casting, which is characterized in that described
Device includes:
Receiving module receives one or more TTS and broadcasts information;
First casting parameter acquisition module, parses the casting information, determines the first casting parameter, wherein described first broadcasts
Reporting parameter includes time-to-live TTL;
Second casting parameter acquisition module determines the second casting parameter according to vehicle's current condition, wherein described second broadcasts
Reporting parameter includes vehicle heading;
Judgment module, according to the first casting parameter and the second casting parameter, it is determined whether execute TTS casting;
Control module executes or does not execute TTS casting according to the judging result of judgment module.
Preferably, the time-to-live TTL is determined according to following at least any one:
The casting information is parsed, the time-to-live TTL is directly obtained, wherein is deposited described in the casting information carrying
Live time TTL;
The casting information is parsed, casting information type corresponding to the casting information is obtained, according to the casting
Information type determines the time-to-live TTL.
Preferably, according to the casting information type, determine that the time-to-live TTL includes:
According to the casting information type, matching inquiry is carried out in TTL inquiry table, to obtain the time-to-live TTL,
Wherein, the mapping relations between time-to-live TTL of the TTL inquiry table comprising casting information type and corresponding to it.
Preferably,
First casting parameter further comprises the casting information content;Second casting parameter further includes vehicle driving road
Line, and/or, current vehicle position.
Preferably, the judgment module is further used for determining whether to execute TTS casting based on the following contents:
If the time-to-live TTL does not exceed the time limit, but broadcasts the information content and vehicle heading mismatch, then do not execute
TTS casting;
And/or
If the time-to-live TTL does not exceed the time limit, but broadcasts the information content and vehicle heading and mismatches, and with vehicle row
It sails route not meeting, does not then execute TTS casting;
And/or
If the time-to-live TTL does not exceed the time limit, and broadcasts the information content and match with vehicle heading, but broadcast information
Exceed preset distance about the distance between the location information in place and current vehicle position in content, does not then execute TTS casting.
Preferably, described device further includes weight calculation module,
The first casting parameter acquisition module is further used for, and determining casting information category is sent to weight calculation
Module;
When there are multiple casting information, and broadcast information and be when reminding category information, according to the sending time of casting information with
And time-to-live TTL, weight is calculated, the height of priority level is set according to the size of weight, according to priority level to prompting class
Message queue is ranked up, and is successively broadcasted;
When there are multiple casting information, and casting information is instruction feedback category information, according to the degree of correlation of casting information
It is grouped and calculates grouping weight to casting information with sending time, for multiple casting information in being grouped, when according to sending
Between determine in the grouping information weight in the groups of multiple casting information, according to the size of information weight in organizing and grouping weight
Size be respectively set grouping in casting information group in casting priority level height and broadcast information block grouping broadcast
Report the height of priority level;Priority level is broadcasted according to the grouping of casting information block, team is grouped to casting information block
Column sequence is successively broadcasted in organizing in each grouping and broadcasts the highest casting information of priority level.
On the other hand, the embodiment of the invention provides a kind of terminal devices of device comprising dynamic adjustment TTS casting.
On the other hand, the embodiment of the invention provides a kind of computer equipment, the computer equipment include processor and
Memory is stored with the computer program that can be run on a processor in the memory, and the computer program is described
Processor realizes method above-mentioned when executing.
On the other hand, the embodiment of the invention provides a kind of computer readable storage medium, the computer-readable storages
The computer program that can be run on a processor is stored in medium, the computer program realizes side above-mentioned when executed
Method.
The implementation of the embodiment of the present invention correctly and efficiently can receive and adjust TTS casting, improve the casting effect of TTS casting
Fruit promotes the usage experience of user, establishes more optimized human-computer interaction process, achieves beneficial effect.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below
There is attached drawing needed in technical description to be briefly described, it is clear that ground, the accompanying drawings in the following description are this hairs
Bright some embodiments for those of ordinary skill in the art without creative efforts, can be with root
Other attached drawings are obtained according to these attached drawings.
Fig. 1 is the flow diagram of the method for the dynamic adjustment TTS casting that this specification embodiment provides.
Fig. 2 be this specification embodiment provide dynamic adjustment TTS casting method in determine whether execute TTS casting
Idiographic flow schematic diagram.
Fig. 3 is the apparatus structure for the dynamic adjustment TTS casting that this specification embodiment provides.
Specific embodiment
To make the object, technical solutions and advantages of the present invention clearer, below in conjunction with attached drawing to embodiment party of the present invention
Formula is described in further detail.The embodiment of the present invention and the specific features of embodiment are to technical side of the embodiment of the present invention
The detailed description of case, rather than the restriction to description of the invention technical solution, in the absence of conflict, the embodiment of the present invention
And the technical characteristic of embodiment can be combined with each other.
Embodiment one
Referring to Fig. 1, Fig. 1 is a kind of method for dynamic adjustment TTS casting that the embodiment of the present invention one provides, feature exists
In, the method includes but be not limited to:
Step 1, it receives one or more TTS and broadcasts information;
Step 2, the casting information is parsed, determines the first casting parameter, wherein the first casting parameter includes survival
Time TTL;
Step 3, according to vehicle's current condition, the second casting parameter is determined, wherein the second casting parameter includes vehicle
Driving direction;
Step 4, according to the first casting parameter and the second casting parameter, it is determined whether execute TTS casting;If so, executing
Step 5;
Step 5, TTS casting is executed.
Specifically, the casting information casting information format can be such that
ID |
Data |
Timestamp |
Reserved1 |
Reserved2 |
Wherein, id field can be recipient's mark, and Data field can be the casting information content, Timestamp field
For access time stamp, Reserved field is reserved field.
Specifically, it determines that the detailed process of the first casting parameter can be in step 2 to be determined according to following at least any one
The time-to-live TTL:
The casting information is parsed, the time-to-live TTL is directly obtained, wherein is deposited described in the casting information carrying
Live time TTL;
The casting information is parsed, casting information type corresponding to the casting information is obtained, according to the casting
Information type determines the time-to-live TTL.
Such as the TTS casting information that cloud is sent can carry TTL.It is ttl field that one of reserved field, which is such as arranged,.Casting letter
Breath is as follows:
ID |
Data |
Timestamp |
TTL |
Reserved |
Alternatively, information can be broadcasted by parsing TTS, according to the casting information content, classifies to casting information, such as mention
Awake category information, alternatively, instruction feedback category information;It wherein reminds category information that can also be classified as commonly reminding category information, promptly mentions
Awake category information;The corresponding TTL inquiry table of classification information is inquired for different classification informations, so that it is determined that the casting information
TTL。
TTL inquiry table is as shown in the table:
Table 1:TTL inquiry table
Information type |
Time-to-live TTL |
It is urgent to remind category information |
10~60s |
It is common to remind category information |
60~300s |
Instruction feedback category information |
30~180S |
Information type is carried alternatively, can broadcast in information in TTS, as follows:
ID |
Data |
Timestamp |
Type |
Reserved |
Wherein Type identifies type of message, such as " 00 " represents urgent prompting category information;" 01 " represents common prompting class letter
Breath, " 10 " instruction feedback category information.
Alternatively, information type and TTL are carried simultaneously in TTS casting information, it is as follows:
ID |
Data |
Timestamp |
Type |
TTL |
Specifically, judge to broadcast whether information exceeds TTL, if exceeding, delete the casting information.
Further, the first casting parameter further comprises the casting information content;Second casting parameter further includes vehicle
Travel route, and/or, current vehicle position.
Specifically, referring to fig. 2, according to first casting parameter and second casting parameter, it is determined whether execute TTS broadcast into
One step includes:
If the time-to-live TTL does not exceed the time limit, but broadcasts the information content and vehicle heading mismatch, then do not execute
TTS casting;
For example, casting information broadcasts the information content also within the time-to-live are as follows: " 100 meters of front, turns right, close to XX ", but
The vehicle obtained at this time is being run at high speed, and driving direction is that from south to north, can not turn right, at this time due to the casting information content and vehicle
Driving direction mismatches, and drilling breath of notifying is invalid to this vehicle, then, can be direct without broadcasting to drilling breath of notifying
Delete the casting information.
Alternatively,
If the time-to-live TTL does not exceed the time limit, but broadcasts the information content and vehicle heading and mismatches, and with vehicle row
It sails route not meeting, does not then execute TTS casting;
For example, casting information broadcasts the information content are as follows: " there is traffic thing on 200 meters of front, the road XX also within the time-to-live
Therefore ", but the vehicle heading obtained at this time is to turn right, and broadcasts the information content and vehicle heading at this time and mismatches, can be with
Further judge route or travel by vehicle, if route or travel by vehicle is that northwards straight trip reaches the road XX after viaduct after turning right,
Judging result is to be consistent with route or travel by vehicle, needs to be implemented casting, so that user receives the casting information, acquisition has
Imitate information.If route or travel by vehicle is to turn right to retrodeviate from the road XX, judging result is not meet with route or travel by vehicle, at this time
Without broadcasting to drilling breath of notifying, the casting information can be directly deleted.
Alternatively,
If the time-to-live TTL does not exceed the time limit, and broadcasts the information content and match with vehicle heading, but broadcast information
Exceed preset distance about the distance between the location information in place and current vehicle position in content, does not then execute TTS casting.
For example, casting information broadcasts the information content are as follows: " front road is through gas station ", vehicle driving also within the time-to-live
Direction matches with the casting information content, but since Vehicle Speed is very fast, and judgement has missed the oiling station location, then
Without broadcasting to drilling breath of notifying, the casting information is directly deleted.
The combination of above-mentioned many kinds of parameters is merely illustrative citing, for specific Rule of judgment, such as judges whether TTL surpasses
Phase judges to broadcast whether the information content matches with vehicle heading, judge locating for the corresponding location information of vehicle and vehicle
Whether position exceeds preset distance, judges to broadcast whether the information content is consistent with route or travel by vehicle, can be based on actual
Using the execution priority different to above condition setting, the dynamic adjustment of TTS casting is carried out using multiple combinations mode.
The priority level of casting information can also be arranged in multiple casting information that casting condition is executed for meeting;
Specifically,
When there are multiple casting information, and broadcast information and be when reminding category information, according to the sending time of casting information with
And time-to-live TTL, weight is calculated, the height of priority level is set according to the size of weight, according to priority level to prompting class
Message queue is ranked up, and is successively broadcasted;
When there are multiple casting information, and casting information is instruction feedback category information, according to the degree of correlation of casting information
It is grouped and calculates grouping weight to casting information with sending time, for multiple casting information in being grouped, when according to sending
Between determine in the grouping information weight in the groups of multiple casting information, according to the size of information weight in organizing and grouping weight
Size be respectively set grouping in casting information group in casting priority level height and broadcast information block grouping broadcast
Report the height of priority level;Priority level is broadcasted according to the grouping of casting information block, team is grouped to casting information block
Column sequence is successively broadcasted in organizing in each grouping and broadcasts the highest casting information of priority level.
Embodiment two
Based on similarly conceiving with the method for dynamically adjusting TTS casting in previous embodiment, the embodiment of the present invention is also provided
A kind of device of dynamic adjustment TTS casting, referring to Fig. 3, described device includes but is not limited to:
Receiving module receives one or more TTS and broadcasts information;
First casting parameter acquisition module, parses the casting information, determines the first casting parameter, wherein described first broadcasts
Reporting parameter includes time-to-live TTL;
Second casting parameter acquisition module determines the second casting parameter according to vehicle's current condition, wherein described second broadcasts
Reporting parameter includes vehicle heading;
Judgment module, according to the first casting parameter and the second casting parameter, it is determined whether execute TTS casting;
Control module executes or does not execute TTS casting according to the judging result of judgment module.
Specifically, the time-to-live TTL is determined according to following at least any one:
The casting information is parsed, the time-to-live TTL is directly obtained, wherein is deposited described in the casting information carrying
Live time TTL;
The casting information is parsed, casting information type corresponding to the casting information is obtained, according to the casting
Information type determines the time-to-live TTL.
Such as information can be broadcasted by parsing TTS, according to the casting information content, classifies to casting information, such as mention
Awake category information, alternatively, instruction feedback category information;It wherein reminds category information that can also be classified as commonly reminding category information, promptly mentions
Awake category information;The corresponding TTL inquiry table of classification information is inquired for different classification informations, so that it is determined that the casting information
TTL;
Alternatively, information type directly can be carried in TTS casting information, for different classification information inquiry classification letters
Corresponding TTL inquiry table is ceased, so that it is determined that the TTL of the casting information;
Alternatively, carrying information type and TTL simultaneously in TTS casting information.
Specifically, judge to broadcast whether information exceeds TTL, if exceeding, delete the casting information.
Specifically, the first casting parameter further comprises the casting information content;Second casting parameter further includes vehicle
Travel route, and/or, current vehicle position.
Specifically, the judgment module is further used for
Determine whether to execute TTS casting based on the following contents:
If the time-to-live TTL does not exceed the time limit, but broadcasts the information content and vehicle heading mismatch, then do not execute
TTS casting;
And/or
If the time-to-live TTL does not exceed the time limit, but broadcasts the information content and vehicle heading and mismatches, and with vehicle row
It sails route not meeting, does not then execute TTS casting;
And/or
If the time-to-live TTL does not exceed the time limit, and broadcasts the information content and match with vehicle heading, but broadcast information
Exceed preset distance about the distance between the location information in place and current vehicle position in content, does not then execute TTS casting.
The combination of above-mentioned many kinds of parameters is merely illustrative citing, for specific Rule of judgment, such as judges whether TTL surpasses
Phase judges to broadcast whether the information content matches with vehicle heading, judge locating for the corresponding location information of vehicle and vehicle
Whether position exceeds preset distance, judges to broadcast whether the information content is consistent with route or travel by vehicle, can be based on actual
Using the execution priority different to above condition setting, the dynamic adjustment of TTS casting is carried out using multiple combinations mode.
The priority level of casting information can also be arranged in multiple casting information that casting condition is executed for meeting;
Specifically, described device further includes weight calculation module,
The first casting parameter acquisition module is further used for, and determining casting information category is sent to weight calculation
Module;
When there are multiple casting information, and broadcast information and be when reminding category information, according to the sending time of casting information with
And time-to-live TTL, weight is calculated, the height of priority level is set according to the size of weight, according to priority level to prompting class
Message queue is ranked up, and is successively broadcasted;
When there are multiple casting information, and casting information is instruction feedback category information, according to the degree of correlation of casting information
It is grouped and calculates grouping weight to casting information with sending time, for multiple casting information in being grouped, when according to sending
Between determine in the grouping information weight in the groups of multiple casting information, according to the size of information weight in organizing and grouping weight
Size be respectively set grouping in casting information group in casting priority level height and broadcast information block grouping broadcast
Report the height of priority level;Priority level is broadcasted according to the grouping of casting information block, team is grouped to casting information block
Column sequence is successively broadcasted in organizing in each grouping and broadcasts the highest casting information of priority level.
Based on similarly conceiving with information-pushing method in previous embodiment, the embodiment of the invention also provides a kind of terminals
Equipment, the terminal include the device of the dynamic adjustment TTS casting in above-described embodiment two.
Specifically, terminal device can be computer, tablet computer, mobile phone, intelligent assistant, car-mounted terminal etc..
Based on dynamically adjust TTS broadcasting method in previous embodiment and similarly conceive, the embodiment of the invention also provides
A kind of computer equipment, the computer equipment include processor and memory, and being stored in the memory can be in processor
The computer program of upper operation, the computer program realize that corresponding dynamic adjustment TTS is broadcast when being executed by the processor
Reporting method.
Based on similarly conceiving with information-pushing method in previous embodiment, the embodiment of the invention also provides a kind of calculating
Machine readable storage medium storing program for executing is stored with the computer program that can be run on a processor, institute in the computer readable storage medium
State the method that computer program realizes dynamic adjustment TTS casting when executed.
The above is only a preferred embodiment of the present invention, it is not intended to restrict the invention, it is noted that for this skill
For the those of ordinary skill in art field, without departing from the technical principles of the invention, can also make it is several improvement and
Modification, these improvements and modifications also should be regarded as protection scope of the present invention.