Specific embodiment
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present inventionIn attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment isA part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, those of ordinary skill in the artEvery other embodiment obtained without creative efforts, shall fall within the protection scope of the present invention.
Fig. 1 shows a kind of flow diagram of response timeout treatment method provided in an embodiment of the present invention.
As shown in Figure 1, the described method comprises the following steps:
S11, the voice flow for obtaining user terminal;
Specifically, after breathing out by outer calling platform, the voice stream data of user is obtained.In embodiment, it can pass throughFreeSWITCH platform is to user's outbound calling, the Event Socket (thing that monitoring is made a phone call provided by FreeSWITCHPart) monitoring telephone obtains user speech stream.
S12, speech recognition is carried out to the voice flow;
Specifically, by carrying out speech recognition to the user speech stream of acquisition, user speech is converted into text.
S13, judge whether obtain speech recognition result before preset duration time-out;
Specifically, it if user never has response, is waited for, speech recognition result is sky.Pass through timerPeriodically, judge the result that speech recognition whether is obtained before timer expiry.
S14, overtime process is executed according to judging result, or continues call flow.
Specifically, by whether obtaining speech recognition result before judging timer expiry, determine user in the preset timeInside whether there is response, to be confirmed whether answering or continuing communication process to user.
Response timeout treatment method provided in an embodiment of the present invention, by carrying out speech recognition, judgement to user speech streamWhether obtain speech recognition result in preset duration, determine whether user has response, can under intelligent outgoing call scene userFor a long time without being confirmed whether answering to user in the case where response, the long-time obstruction of phone is avoided, system money is improvedSource utilization rate.
On the basis of the above embodiments, step S14 includes:
If not obtaining institute's speech recognition result before the preset duration time-out, overtime process is executed.
Specifically, if not obtaining speech recognition result before timer expiry, user never has response, executes at this timeOvertime process, to confirm whether user is answering.
On the basis of the above embodiments, if described do not obtain the speech recognition knot before the preset duration time-outFruit, then executing overtime process includes:
Confirmation message is sent to the user terminal, or is hung up the telephone.
Specifically, overtime process is to send confirmation message to user, judges whether user is answering.If long in overtime processTime again without response, then hangs up the telephone.
On the basis of the above embodiments, step S14 further include:
If obtaining institute's speech recognition result before the preset duration time-out, continue call flow.
Specifically, if having obtained speech recognition result before timer expiry, continue call flow.
Fig. 2 shows the flow diagrams for the response timeout treatment method that further embodiment of this invention provides.
As shown in Fig. 2, specifically includes the following steps:
Obtain user speech flow data;
Timer starts timing, and carries out speech recognition to voice flow;
Before timer expiry, speech recognition result is obtained, judges whether recognition result is empty;
If recognition result is sky, overtime process is carried out;
If recognition result is not sky, call flow is carried out according to recognition result.
Specifically, using Java language, the implementation method of above-mentioned process is realized with the Java support module of freeswitchIt is as follows:
1, flow of presentation uses Java language, uses esl+freeswitch+mrcp (intelligent call center mrcpServer the phone process of outgoing call) is realized.
2, esl+freeswitch+mrcp service is built, guarantees that the sofia script for calling freeswicth can breathe out electricityWords.
3, the mod_java script module for writing freeswitch, it is newly-built in the place for needing to start speech recognitionThe thread of Callable-FutureTask, interior execute " play_and_detect_speech " of thread starts to identify voice, and returnsReturn the result " detect_speech_result " of speech recognition.
4, recognition result is obtained using FutureTask.get (Long timeout, TimeUnit unit), if dished outTimeoutException, then it represents that user does not answer at the appointed time, carries out overtime flow processing;Normally get knowledgeNot as a result, then carrying out normal follow-up process processing.
It should be noted that above-mentioned process is realized using the Java support module of freeswitch, in specific implementation processIn, use other solution modules such as Timer, Callable, Future and FutureTask etc. in Java languageRealize above-mentioned process.
Fig. 3 shows a kind of structural schematic diagram of response timeout treatment device provided in an embodiment of the present invention.
As shown in figure 3, described device further include: acquiring unit 11, recognition unit 12, judging unit 13 and processing unit listMember 14, in which:
The acquiring unit 11, for obtaining the voice flow of user terminal;
Specifically, after breathing out by outer calling platform, the voice stream data of user is obtained.In embodiment, it can pass throughFreeSWITCH platform is to user's outbound calling, the Event Socket (thing that monitoring is made a phone call provided by FreeSWITCHPart) monitoring telephone obtains user speech stream.
The recognition unit 12, for carrying out speech recognition to the voice flow;
Specifically, by carrying out speech recognition to the user speech stream of acquisition, user speech is converted into text.
The judging unit 13, for judging whether obtain speech recognition result before preset duration time-out;
Specifically, it if user never has response, is waited for, speech recognition result is sky.Pass through timerPeriodically, judge the result that speech recognition whether is obtained before timer expiry.
The processing unit 14 is used to execute overtime process according to judging result, or continues call flow.
Specifically, by whether obtaining speech recognition result before judging timer expiry, determine user in the preset timeInside whether there is response, to be confirmed whether answering or continuing communication process to user.
Response timeout treatment device provided in an embodiment of the present invention, by carrying out speech recognition, judgement to user speech streamWhether obtain speech recognition result in preset duration, determine whether user has response, can under intelligent outgoing call scene userFor a long time without being confirmed whether answering to user in the case where response, the long-time obstruction of phone is avoided, system money is improvedSource utilization rate.
On the basis of the above embodiments, the processing unit 14 includes:
First processing module, if being held for not obtaining institute's speech recognition result before the preset duration time-outRow time-out process.
Specifically, if not obtaining speech recognition result before timer expiry, user never has response, executes at this timeOvertime process, to confirm whether user is answering.
On the basis of the above embodiments, the first processing module is specifically used for sending confirmation to the user terminalMessage, or hang up the telephone.
Specifically, overtime process is to send confirmation message to user, judges whether user is answering.If long in overtime processTime again without response, then hangs up the telephone.
On the basis of the above embodiments, the processing unit 14 further include:
Second processing module, if for obtaining institute's speech recognition result before preset duration time-out, continue intoRow call flow.
Specifically, if having obtained speech recognition result before timer expiry, continue call flow.
Fig. 4 illustrates the entity structure schematic diagram of a kind of electronic equipment, as shown in figure 4, the electronic equipment may include: placeManage device (processor) 41, communication interface (Communications Interface) 42, memory (memory) 43 and communicationBus 44, wherein processor 41, communication interface 42, memory 43 complete mutual communication by communication bus 44.Processor41 can call the logical order in memory 43, to execute following method:
Obtain the voice flow of user terminal;
Speech recognition is carried out to the voice flow;
Judge whether obtain speech recognition result before preset duration time-out;
Overtime process is executed according to judging result, or continues call flow.
In addition, the logical order in above-mentioned memory 43 can be realized and as only by way of SFU software functional unitVertical product when selling or using, can store in a computer readable storage medium.Based on this understanding, this hairSubstantially the part of the part that contributes to existing technology or the technical solution can be with soft in other words for bright technical solutionThe form of part product embodies, which is stored in a storage medium, including some instructions are to makeIt obtains a computer equipment (can be personal computer, server or the network equipment etc.) and executes each embodiment of the present inventionThe all or part of the steps of the method.And storage medium above-mentioned include: USB flash disk, mobile hard disk, read-only memory (ROM,Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic or disk etc. it is variousIt can store the medium of program code.
On the other hand, the embodiment of the present invention also provides a kind of non-transient computer readable storage medium, is stored thereon with meterCalculation machine program, which is implemented to carry out the various embodiments described above offer method when being executed by processor, for example,
Obtain the voice flow of user terminal;
Speech recognition is carried out to the voice flow;
Judge whether obtain speech recognition result before preset duration time-out;
Overtime process is executed according to judging result, or continues call flow.
The apparatus embodiments described above are merely exemplary, wherein described, unit can as illustrated by the separation memberIt is physically separated with being or may not be, component shown as a unit may or may not be physics listMember, it can it is in one place, or may be distributed over multiple network units.It can be selected according to the actual needsIn some or all of the modules achieve the purpose of the solution of this embodiment.Those of ordinary skill in the art are not paying creativenessLabour in the case where, it can understand and implement.
Through the above description of the embodiments, those skilled in the art can be understood that each embodiment canIt realizes by means of software and necessary general hardware platform, naturally it is also possible to pass through hardware.Based on this understanding, onStating technical solution, substantially the part that contributes to existing technology can be embodied in the form of software products in other words, shouldComputer software product may be stored in a computer readable storage medium, such as ROM/RAM, magnetic disk, CD, including several fingersIt enables and using so that a computer equipment (can be personal computer, server or the network equipment etc.) executes each implementationMethod described in certain parts of example or embodiment.
Finally, it should be noted that the above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;AlthoughPresent invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that: it still may be usedTo modify the technical solutions described in the foregoing embodiments or equivalent replacement of some of the technical features;And these are modified or replaceed, technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution spirit andRange.