Problems with PocketSphinx + UniMRCP + Asterisk

928 views
Skip to first unread message

Dejan Štimpfelj

unread,
Jul 20, 2011, 6:23:14 AM7/20/11
to UniMRCP
Hello

I am having some problems with enabling voice recognition on my
Asterisk box. These are the software versions of the packages I am
using:

PocketSphinx - 0.7
UniMRCP - 1.0.0
Asterisk - 1.8.5

The OS is CentOS 5.6, all 3 packages are installed on a single
machine. The IP address of the server is 192.168.7.3.

I followed these tutorials, as far as the installation of the required
packeages is concerned, and for now things are looking to be installed
correctly:

http://code.google.com/p/unimrcp/wiki/PocketSphinxPlugin
http://code.google.com/p/unimrcp/wiki/asteriskUniMRCP

When I set up the .conf files according to the tutorials I can not get
the whole setup working. I also do not know where to unpack the
PocketSphinx model (communicator) (the wsj1 model and default.dic can
not be found in the /usr/local/unimrcp/data/)

This is my DialPlan in Asterisk:

exten => 631,1,Answer()
exten => 631,n,SpeechCreate()
exten => 631,n,SpeechLoadGrammar(digit,/usr/local/unimrcp/data/
grammar.xml)
exten => 631,n,SpeechActivateGrammar(digit)
exten => 631,n,SpeechBackground(hello-world,20)
exten => 631,n,NoOp(The result of speech recognition: $
{SPEECH_TEXT(0)})
exten => 631,n,SpeechDeactivateGrammar(digit)
exten => 631,n,SpeechUnloadGrammar(digit)
exten => 631,n,SpeechDestroy()
exten => 631,n,Hangup()

At the last part of the e-mail also please find the config files that
I have changed and te debugs I have made in the Asterisk CLI. I have
not changed any additional .conf files on the 3 packages that are in
question.

I was able to find the instructions to get to this point, but now I am
a bit lost when I need to find the cause of the problems. I bet I made
a mistake in the .conf files, but I need the help of the community to
find the exact place of the problem.

I thank for any help in advance.

Dejan Štimpfelj


***** This is what I get when I make a call *****

[Jul 19 00:42:17] VERBOSE[14006] netsock2.c: == Using SIP RTP CoS
mark 5
[Jul 19 00:42:17] VERBOSE[14055] pbx.c: -- Executing
[631@internal_calls:1] Answer("SIP/262-00000003", "") in new stack
[Jul 19 00:42:17] VERBOSE[14055] pbx.c: -- Executing
[631@internal_calls:2] SpeechCreate("SIP/262-00000003", "") in new
stack
[Jul 19 00:42:17] NOTICE[14055] app_unimrcp.c: Create MRCP Handle
0x8e41f10 [uni2]
[Jul 19 00:42:17] DEBUG[14055] app_unimrcp.c: Create Channel 0x8e41f10
<new>
[Jul 19 00:42:17] DEBUG[14055] res_speech_unimrcp.c: Send session
request type:2
[Jul 19 00:42:17] DEBUG[14055] app_unimrcp.c: Signal Message to [MRCP
Client] [4;0]
[Jul 19 00:42:17] DEBUG[14055] res_speech_unimrcp.c: Wait for session
response
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Process Message [MRCP
Client] [4;0]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Receive App Request
0x8e41f10 <new> [2]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Add MRCP Handle
0x8e41f10 <new>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Dispatch App Request
0x8e41f10 <new> [2]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Signal Message to
[MRCPv2-Agent-1] [1;0]
[Jul 19 00:42:17] NOTICE[14025] app_unimrcp.c: Add Control Channel
0x8e41f10 <new@speechrecog>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Add Media Termination
0x8e41f10 <new@media-tm>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Add Media Termination
0x8e41f10 <new@rtp-tm>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Signal Message to [Media-
Engine-1] [1;0]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Wait for Messages [MRCP
Client]
[Jul 19 00:42:17] DEBUG[14028] app_unimrcp.c: Process Poller Wakeup
[MRCPv2-Agent-1]
[Jul 19 00:42:17] DEBUG[14028] app_unimrcp.c: Process Message [MRCPv2-
Agent-1] [1;0]
[Jul 19 00:42:17] DEBUG[14028] app_unimrcp.c: Signal Message to [MRCP
Client] [2;0]
[Jul 19 00:42:17] DEBUG[14028] app_unimrcp.c: Wait for Messages
[MRCPv2-Agent-1]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Process Message [MRCP
Client] [2;0]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Control Channel Added
0x8e41f10 <new@speechrecog>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Wait for Messages [MRCP
Client]
[Jul 19 00:42:17] DEBUG[14029] app_unimrcp.c: Process Message [Media-
Engine-1] [1;0]
[Jul 19 00:42:17] DEBUG[14029] app_unimrcp.c: Add Media Context
0x8e41f10
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Process Message [MRCP
Client] [3;0]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Media Termination Added
0x8e41f10 <new@media-tm>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Media Termination Added
0x8e41f10 <new@rtp-tm>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Send Offer 0x8e41f10
<new> [c:1 a:1 v:0] to 192.168.7.3:8060
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Local SDP 0x8e41f10
<new>
v=0
o=UniMRCPClient 0 0 IN IP4 192.168.7.3
s=-
c=IN IP4 192.168.7.3
t=0 0
m=application 9 TCP/MRCPv2 1
a=setup:active
a=connection:new
a=resource:speechrecog
a=cmid:1
m=audio 4006 RTP/AVP 0 8 96 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:96 L16/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendonly
a=ptime:20
a=mid:1

[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Wait for Messages [MRCP
Client]
[Jul 19 00:42:17] DEBUG[14026] app_unimrcp.c: Receive SIP Event
[nua_i_state] Status 0 INVITE sent
[Jul 19 00:42:17] NOTICE[14026] app_unimrcp.c: SIP Call State
0x8e41f10 [calling]
[Jul 19 00:42:17] DEBUG[14026] app_unimrcp.c: Receive SIP Event
[nua_r_invite] Status 503 Service Unavailable
[Jul 19 00:42:17] DEBUG[14026] app_unimrcp.c: Receive SIP Event
[nua_i_state] Status 503 Service Unavailable
[Jul 19 00:42:17] NOTICE[14026] app_unimrcp.c: SIP Call State
0x8e41f10 [terminated]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Process Message [MRCP
Client] [1;4]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Raise App Response
0x8e41f10 <new> [2] FAILURE [2]
[Jul 19 00:42:17] DEBUG[14025] res_speech_unimrcp.c: Received message
from client stack
[Jul 19 00:42:17] DEBUG[14025] res_speech_unimrcp.c: On channel add
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Wait for Messages [MRCP
Client]
[Jul 19 00:42:17] DEBUG[14055] res_speech_unimrcp.c: Waked up, status
code: 2
[Jul 19 00:42:17] WARNING[14055] res_speech_unimrcp.c: Failed to add
channel
[Jul 19 00:42:17] DEBUG[14055] res_speech_unimrcp.c: Send session
request type:1
[Jul 19 00:42:17] DEBUG[14055] app_unimrcp.c: Signal Message to [MRCP
Client] [4;0]
[Jul 19 00:42:17] DEBUG[14055] res_speech_unimrcp.c: Wait for session
response
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Process Message [MRCP
Client] [4;0]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Receive App Request
0x8e41f10 <new> [1]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Dispatch App Request
0x8e41f10 <new> [1]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Terminate Session
0x8e41f10 <new>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Remove Control Channel
0x8e41f10 <new>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Signal Message to
[MRCPv2-Agent-1] [1;0]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Subtract Media
Termination 0x8e41f10 <new@media-tm>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Subtract Media
Termination 0x8e41f10 <new@rtp-tm>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Signal Message to [Media-
Engine-1] [1;0]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Wait for Messages [MRCP
Client]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Process Message [MRCP
Client] [1;1]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Session Terminated
0x8e41f10 <new>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Wait for Messages [MRCP
Client]
[Jul 19 00:42:17] DEBUG[14028] app_unimrcp.c: Process Poller Wakeup
[MRCPv2-Agent-1]
[Jul 19 00:42:17] DEBUG[14028] app_unimrcp.c: Process Message [MRCPv2-
Agent-1] [1;0]
[Jul 19 00:42:17] DEBUG[14028] app_unimrcp.c: Signal Message to [MRCP
Client] [2;2]
[Jul 19 00:42:17] DEBUG[14028] app_unimrcp.c: Wait for Messages
[MRCPv2-Agent-1]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Process Message [MRCP
Client] [2;2]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Control Channel Removed
0x8e41f10 <new@speechrecog>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Wait for Messages [MRCP
Client]
[Jul 19 00:42:17] DEBUG[14029] app_unimrcp.c: Process Message [Media-
Engine-1] [1;0]
[Jul 19 00:42:17] DEBUG[14029] app_unimrcp.c: Remove Media Context
0x8e41f10
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Process Message [MRCP
Client] [3;0]
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Media Termination
Subtracted 0x8e41f10 <new@media-tm>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Media Termination
Subtracted 0x8e41f10 <new@rtp-tm>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Remove MRCP Handle
0x8e41f10 <new>
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Raise App Response
0x8e41f10 <new> [1] SUCCESS [0]
[Jul 19 00:42:17] DEBUG[14025] res_speech_unimrcp.c: Received message
from client stack
[Jul 19 00:42:17] DEBUG[14025] res_speech_unimrcp.c: On session
terminate
[Jul 19 00:42:17] DEBUG[14025] app_unimrcp.c: Wait for Messages [MRCP
Client]
[Jul 19 00:42:17] DEBUG[14055] res_speech_unimrcp.c: Waked up, status
code: 0
[Jul 19 00:42:17] NOTICE[14055] app_unimrcp.c: Destroy MRCP Handle
0x8e41f10
[Jul 19 00:42:17] VERBOSE[14055] pbx.c: -- Executing
[631@internal_calls:3] SpeechLoadGrammar("SIP/262-00000003", "digit,/
usr/local/unimrcp/data/gra
mmar.xml") in new stack
[Jul 19 00:42:17] VERBOSE[14055] pbx.c: == Spawn extension
(interni_klici_telos, 631, 3) exited non-zero on 'SIP/262-00000003'


These are the config files:

***** res-speech-unimrc.conf *****
[general]
; UniMRCP named profile. Options are:
unimrcp-profile = uni2 ; UniMRCP MRCPv2 Server
;unimrcp-profile = uni1 ; UniMRCP MRCPv1 Server
;unimrcp-profile = lv2 ; LumenVox MRCPv2 Server
;unimrcp-profile = lv1 ; LumenVox MRCPv1 Server
;unimrcp-profile = nss2 ; Nuance MRCPv2 Server
;unimrcp-profile = nss1 ; Nuance MRCPv1 Server

; UniMRCP logging level. Options are:
; EMERGENCY|ALERT|CRITICAL|ERROR|WARNING|NOTICE|INFO|DEBUG -->
log-level = DEBUG


; Preloaded grammars
[grammars]
;grammar-name = path-to-grammar-file

; MRCPv2 properties (recognizer and generic header fields)
; http://tools.ietf.org/html/draft-ietf-speechsc-mrcpv2-20#section-9.4
[mrcpv2-properties]
Recognition-Timeout = 20000
No-Input-Timeout = 15000


; MRCPv1 properties (recognizer and generic header fields)
; http://tools.ietf.org/html/rfc4463#section-8.4
[mrcpv1-properties]
Recognition-Timeout = 20000
No-Input-Timeout = 15000


***** mrcp.conf *****
[general]
default-asr-profile = speech-nuance5-mrcp2
default-tts-profile = speech-nuance5-mrcp2
; UniMRCP logging level to appear in Asterisk logs. Options are:
; EMERGENCY|ALERT|CRITICAL|ERROR|WARNING|NOTICE|INFO|DEBUG -->
log-level = DEBUG
max-connection-count = 100
offer-new-connection = 1
; rx-buffer-size = 1024
; tx-buffer-size = 1024
; request-timeout = 60

[speech-nuance5-mrcp1]
; +++ MRCP settings +++
version = 1
;
; +++ RTSP +++
; === RSTP settings ===
server-ip = 192.168.1.3
server-port = 4900
; force-destination = 1
resource-location = media
speechsynth = speechsynthesizer
speechrecog = speechrecognizer
;
; +++ RTP +++
; === RTP factory ===
; rtp-ip = 0.0.0.0
rtp-ip = 192.168.1.2
; rtp-ext-ip = auto
rtp-port-min = 4000
rtp-port-max = 5000
; === RTP settings ===
; --- Jitter buffer settings ---
playout-delay = 50
; min-playout-delay = 20
max-playout-delay = 200
; --- RTP settings ---
ptime = 20
codecs = PCMU PCMA L16/96/8000
; --- RTCP settings ---
rtcp = 1
rtcp-bye = 2
rtcp-tx-interval = 5000
rtcp-rx-resolution = 1000


[speech-nuance5-mrcp2]
; +++ MRCP settings +++
version = 2
;
; +++ SIP +++
; === SIP settings ===
server-ip = 192.168.7.3
server-port = 5060
; server-username = test
force-destination = 1
; === SIP agent ===
; client-ip = 0.0.0.0
client-ip = 192.168.7.3
; client-ext-ip = auto
client-port = 5093
sip-transport = udp
; ua-name = Asterisk
; sdp-origin = Asterisk
;
; +++ RTP +++
; === RTP factory ===
; rtp-ip = 0.0.0.0
rtp-ip = 192.168.7.3
; rtp-ext-ip = auto
rtp-port-min = 4000
rtp-port-max = 5000
; === RTP settings ===
; --- Jitter buffer settings ---
playout-delay = 50
; min-playout-delay = 20
max-playout-delay = 200
; --- RTP settings ---
ptime = 20
codecs = PCMU PCMA L16/96/8000
; --- RTCP settings ---
rtcp = 1
rtcp-bye = 2
rtcp-tx-interval = 5000
rtcp-rx-resolution = 1000

***** unimrcpserver.xml *****

<?xml version="1.0" encoding="UTF-8"?>
<!-- UniMRCP server document -->
<unimrcpserver xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="unimrcpserver.xsd" version="1.0">
<properties>
<!-- By default, network interface (IP address) to bind to will be
implicitly identified.
Alternatively, it can be explicitly set.
-->
<!-- <ip type="auto"/> -->
<ip>192.168.7.3</ip>
<!-- <ext-ip>a.b.c.d</ext-ip> -->
</properties>

<components>
<!-- Factory of MRCP resources -->
<resource-factory>
<resource id="speechsynth" enable="true"/>
<resource id="speechrecog" enable="true"/>
<resource id="recorder" enable="true"/>
</resource-factory>

<!-- SofiaSIP MRCPv2 signaling agent -->
<sip-uas id="SIP-Agent-1" type="SofiaSIP">
<!-- By default, "ip" and "ext-ip" addresses set in the
properties will be used.
They still can be explicitly specified (overriden) here.
-->
<!-- <sip-ip>10.10.0.1</sip-ip> -->
<!-- <sip-ext-ip>a.b.c.d</sip-ext-ip> -->
<sip-port>8060</sip-port>
<sip-transport>udp,tcp</sip-transport>
<!-- <force-destination>true</force-destination> -->
<ua-name>UniMRCP SofiaSIP</ua-name>
<sdp-origin>UniMRCPServer</sdp-origin>
<!-- <sip-t1>500</sip-t1> -->
<!-- <sip-t2>4000</sip-t2> -->
<!-- <sip-t4>4000</sip-t4> -->
<!-- <sip-t1x64>32000</sip-t1x64> -->
</sip-uas>

<!-- UniRTSP MRCPv1 signaling agent -->
<rtsp-uas id="RTSP-Agent-1" type="UniRTSP">
<!-- By default, "ip" and "ext-ip" addresses set in the
properties will be used.
They still can be explicitly specified (overriden) here.
-->
<!-- <rtsp-ip>10.10.0.1</rtsp-ip> -->
<!-- <rtsp-ext-ip>a.b.c.d</rtsp-ext-ip> -->
<rtsp-port>1554</rtsp-port>
<!-- <force-destination>true</force-destination> -->
<resource-map>
<param name="speechsynth" value="speechsynthesizer"/>
<param name="speechrecog" value="speechrecognizer"/>
</resource-map>
<max-connection-count>100</max-connection-count>
<sdp-origin>UniMRCPServer</sdp-origin>
</rtsp-uas>

<!-- MRCPv2 connection agent -->
<mrcpv2-uas id="MRCPv2-Agent-1">
<!-- By default, "ip" set in the properties will be used.
It still can be explicitly specified (overriden) here.
-->
<!-- <mrcp-ip>10.10.0.1</mrcp-ip> -->
<mrcp-port>1544</mrcp-port>
<max-connection-count>100</max-connection-count>
<force-new-connection>false</force-new-connection>
<rx-buffer-size>1024</rx-buffer-size>
<tx-buffer-size>1024</tx-buffer-size>
</mrcpv2-uas>

<!-- Media processing engine -->
<media-engine id="Media-Engine-1">
<realtime-rate>1</realtime-rate>
</media-engine>

<!-- Factory of RTP terminations -->
<rtp-factory id="RTP-Factory-1">
<!-- By default, "ip" and "ext-ip" addresses set in the
properties will be used.
They still can be explicitly specified (overriden) here.
-->
<!-- <rtp-ip>10.10.0.1</rtp-ip> -->
<!-- <rtp-ext-ip>a.b.c.d</rtp-ext-ip> -->
<rtp-port-min>5000</rtp-port-min>
<rtp-port-max>6000</rtp-port-max>
</rtp-factory>

<!-- Factory of plugins (MRCP engines) -->
<plugin-factory>
<engine id="PocketSphinx-1" name="mrcppocketsphinx"
enable="true"/>
<engine id="Flite-1" name="mrcpflite" enable="false"/>
<engine id="Demo-Synth-1" name="demosynth" enable="true"/>
<engine id="Demo-Recog-1" name="demorecog" enable="true"/>
<engine id="Recorder-1" name="mrcprecorder" enable="true"/>

<!-- Engines may have additional named and generic params
<engine id="Your-Engine-1" name="yourengine" enable="true">
<max-channel-count>100</max-channel-count>
<param name="..." value="..."/>
</engine>
-->
</plugin-factory>
</components>

<settings>
<!-- RTP/RTCP settings -->
<rtp-settings id="RTP-Settings-1">
<jitter-buffer>
<playout-delay>50</playout-delay>
<max-playout-delay>200</max-playout-delay>
</jitter-buffer>
<ptime>20</ptime>
<codecs own-preference="false">PCMU PCMA L16/96/8000 telephone-
event/101/8000</codecs>
<!-- <codecs own-preference="false">PCMU PCMA L16/96/8000 PCMU/
97/16000 PCMA/98/16000 L16/99/16000</codecs> -->
<!-- enable/disable RTCP support -->
<rtcp enable="false">
<!-- RTCP BYE policies (RTCP must be enabled first)
0 - disable RTCP BYE
1 - send RTCP BYE at the end of session
2 - send RTCP BYE also at the end of each talkspurt
(input)
-->
<rtcp-bye>1</rtcp-bye>
<!-- rtcp transmission interval in msec (set 0 to disable) -->
<tx-interval>5000</tx-interval>
<!-- period (timeout) to check for new rtcp messages in msec
(set 0 to disable) -->
<rx-resolution>1000</rx-resolution>
</rtcp>
</rtp-settings>
</settings>


<profiles>
<!-- MRCPv2 default profile -->
<mrcpv2-profile id="uni2">
<sip-uas>SIP-Agent-1</sip-uas>
<mrcpv2-uas>MRCPv2-Agent-1</mrcpv2-uas>
<media-engine>Media-Engine-1</media-engine>
<rtp-factory>RTP-Factory-1</rtp-factory>
<rtp-settings>RTP-Settings-1</rtp-settings>

<!-- It's possible to define profile based map of resources and
engines.
<resource-engine-map>
<param name="speechsynth" value="Flite-1"/>
<param name="speechrecog" value="PocketSphinx-1"/>
</resource-engine-map>
-->
</mrcpv2-profile>

<!-- MRCPv1 default profile -->
<mrcpv1-profile id="uni1">
<rtsp-uas>RTSP-Agent-1</rtsp-uas>
<media-engine>Media-Engine-1</media-engine>
<rtp-factory>RTP-Factory-1</rtp-factory>
<rtp-settings>RTP-Settings-1</rtp-settings>
</mrcpv1-profile>

<!-- more profiles might be added here -->
</profiles>

<plugin>
<engine name="PocketSphinx-1" class="mrcppocketsphinx"
enable="1"/>
</plugin>
</unimrcpserver>

***** unimrcpclient.xml *****

<?xml version="1.0" encoding="UTF-8"?>
<!-- UniMRCP client document -->
<unimrcpclient xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="unimrcpclient.xsd"
version="1.0"
subfolder="client-profiles">
<properties>
<!-- By default, network interface (IP address) to bind to will be
implicitly identified.
Alternatively, it can be explicitly set.
-->
<!-- <ip type="auto"/> -->
<ip>192.168.7.3</ip>
<!-- <ext-ip>a.b.c.d</ext-ip> -->
<server-ip>192.168.7.3</server-ip>
</properties>

<components>
<!-- Factory of MRCP resources -->
<resource-factory>
<resource id="speechsynth" enable="true"/>
<resource id="speechrecog" enable="true"/>
<resource id="recorder" enable="true"/>
</resource-factory>

<!-- SofiaSIP MRCPv2 signaling agent -->
<sip-uac id="SIP-Agent-1" type="SofiaSIP">
<!-- By default, "ip" and "ext-ip" addresses set in the
properties will be used.
They still can be explicitly specified (overriden) here.
-->
<!-- <sip-ip>10.10.0.1</sip-ip> -->
<!-- <sip-ext-ip>a.b.c.d</sip-ext-ip> -->
<sip-port>8062</sip-port>
<sip-transport>udp</sip-transport>
<ua-name>UniMRCP SofiaSIP</ua-name>
<sdp-origin>UniMRCPClient</sdp-origin>
<!-- <sip-t1>500</sip-t1> -->
<!-- <sip-t2>4000</sip-t2> -->
<!-- <sip-t4>4000</sip-t4> -->
<!-- <sip-t1x64>32000</sip-t1x64> -->
</sip-uac>

<!-- UniRTSP MRCPv1 signaling agent -->
<rtsp-uac id="RTSP-Agent-1" type="UniRTSP">
<max-connection-count>100</max-connection-count>
<!-- <request-timeout>5000</request-timeout> -->
<sdp-origin>UniMRCPClient</sdp-origin>
</rtsp-uac>

<!-- MRCPv2 connection agent -->
<mrcpv2-uac id="MRCPv2-Agent-1">
<max-connection-count>100</max-connection-count>
<offer-new-connection>false</offer-new-connection>
<rx-buffer-size>1024</rx-buffer-size>
<tx-buffer-size>1024</tx-buffer-size>
<!-- <request-timeout>5000</request-timeout> -->
</mrcpv2-uac>

<!-- Media processing engine -->
<media-engine id="Media-Engine-1">
<realtime-rate>1</realtime-rate>
</media-engine>

<!-- Factory of RTP terminations -->
<rtp-factory id="RTP-Factory-1">
<!-- By default, "ip" and "ext-ip" addresses set in the
properties will be used.
They still can be explicitly specified (overriden) here.
-->
<!-- <rtp-ip>10.10.0.1</rtp-ip> -->
<!-- <rtp-ext-ip>a.b.c.d</rtp-ext-ip> -->
<rtp-port-min>4000</rtp-port-min>
<rtp-port-max>5000</rtp-port-max>
</rtp-factory>
</components>

<settings>
<!-- common (default) RTP/RTCP settings -->
<rtp-settings id="RTP-Settings-1">
<jitter-buffer>
<playout-delay>50</playout-delay>
<max-playout-delay>200</max-playout-delay>
</jitter-buffer>
<ptime>20</ptime>
<codecs>PCMU PCMA L16/96/8000 telephone-event/101/8000</codecs>
<!-- <codecs>PCMU PCMA L16/96/8000 PCMU/97/16000 PCMA/98/16000
L16/99/16000</codecs> -->
<!-- enable/disable RTCP support -->
<rtcp enable="false">
<!-- RTCP BYE policies (RTCP must be enabled first)
0 - disable RTCP BYE
1 - send RTCP BYE at the end of session
2 - send RTCP BYE also at the end of each talkspurt
(input)
-->
<rtcp-bye>1</rtcp-bye>
<!-- rtcp transmission interval in msec (set 0 to disable) -->
<tx-interval>5000</tx-interval>
<!-- period (timeout) to check for new rtcp messages in msec
(set 0 to disable) -->
<rx-resolution>1000</rx-resolution>
</rtcp>
</rtp-settings>
</settings>
</unimrcpclient>


***** pocketsphinx.xml *****

<?xml version="1.0" encoding="UTF-8"?>
<!-- PocketSphinx Document -->
<pocketsphinx>
<!-- Senstitivity level and timeout are used for voice activity
(speech) detection
reasonable values: level is in [2..250] range, timeout is in
[100..500] msec range
-->
<sensitivity level="50" timeout="300"/>

<!-- Default values for noinput and recognition timeout,
these values can be overriden by client's requests
-->
<timers noinput-timeout="10000" recognition-timeout="15000"/>


<!-- PocketSphinx related model and dictionary data.
Default dir (dir="") is InstallDir/data
-->
<model dir="" narrowband="communicator" wideband="wsj1"
dictionary="default.dic" preferred="narrowband"/>
<!-- <model dir="/usr/local/freeswitch/grammar" narrowband="model/
communicator" wideband="model/wsj1" dictionary="default.dic"/> -->

<!-- Enable to save utterance.
Default dir (dir="") is InstallDir/data
-->
<save-waveform dir="" enable="0"/>
</pocketsphinx>

Arsen Chaloyan

unread,
Jul 22, 2011, 6:55:03 PM7/22/11
to uni...@googlegroups.com
Hello Dejan,

Everything seems to be configured properly. However, it looks like you
didn't start the UniMRCP server, did you?

From what I can see,

> [Jul 19 00:42:17] NOTICE[14026] app_unimrcp.c: SIP Call State 0x8e41f10 [calling]
> [Jul 19 00:42:17] DEBUG[14026] app_unimrcp.c: Receive SIP Event [nua_r_invite] Status 503 Service Unavailable

Asterisk couldn't connect to to the server.

2011/7/20 Dejan Štimpfelj <yac...@gmail.com>:

> --
> You received this message because you are subscribed to the Google Groups "UniMRCP" group.
> To post to this group, send email to uni...@googlegroups.com.
> To unsubscribe from this group, send email to unimrcp+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/unimrcp?hl=en.
>
>

--
Arsen Chaloyan
Author of UniMRCP
http://www.unimrcp.org

Dejan Stimpfelj

unread,
Jul 23, 2011, 10:41:06 AM7/23/11
to uni...@googlegroups.com
Dear Arsen

Thank you very much for poiting this out. I have already figured the
cause of the problem a couple days after I posted the message on the
google group. You are right, I did not manually start the unimrc
server and therefore the unirmcp client could not connect it. It is
very interesting that no tutorials ever said that I need to manually
run the unirmcp server in order I can use unimrcp in connection with
Asterisk, that is the main thing why I had the problem.

Now the unimrcp server and client connect, but I have the same
problems like the last couple users of this google group. When I call
the extension that should enable me to do voice reconition, the voice
is not identified (asterisk shows it is waiting for an audio, unimrcp
server is shows IN PROGRESS status). I followed your advice and put
the following settings from pocketsphix.xml

<sensitivity level="50" activity-timeout="300" inactivity-timeout="300"/>

but this did not resolve the problem for me. So I am guessing that I
have problems with the model, dictionary or the grammar ...

Can you please post your settings of pocketsphix.xml? Your tutorial
states that the wsj1 model and default.dic are located in the
/usr/local/unimrcp/data, but I do not have those files there. So I
need your help with installing and understanding the pocketsphinx
settings that need to be made so basic voice recognition works.

Best regards
Dejan

Dejan Stimpfelj

unread,
Aug 5, 2011, 6:07:35 PM8/5/11
to uni...@googlegroups.com
Dear Arsen

I have tried a lot of things to get voice recognition working with
UniMRCP, but I still can not get the PocketSphinx to recognize voice
when I make a call to Asterisk IVR. The call is successfull, but the
SpeechBackground() does not recognize any words. I am using the
language model and dictionary that Robert Koch (roko) has mentioned in
his instructions on how to install Asterisk + UniMRCP + PocketSphinx
(hub4wsj_sc_8k). The reason for that is that I do not have any wsj1


model and default.dic are located in the

/usr/local/unimrcp/data when I install the PocketSphinx.

I am really lost and need help with getting a simple voice recognition
working in my setup. Can I make any additonal debugs to see what
exactly is not configured OK?

These are the debugs from Asterisk and UniMRCP server, hope they help.

***** Asterisk server debug *****
[Aug 5 22:18:08] WARNING[32291] chan_sip.c: Autodestruct on dialog
'ZTI5NTUxZjVkZjc5MTFkZjJmZjA5ZmJmNWNlYzUyY2U.' with owner in place
(Method: BYE)
[Aug 5 22:18:16] VERBOSE[32291] netsock.c: == Using UDPTL CoS mark 5
[Aug 5 22:18:16] VERBOSE[32291] netsock2.c: == Using SIP RTP CoS mark 5
[Aug 5 22:18:16] VERBOSE[303] pbx.c: -- Executing
[631@interni_klici_telos:1] Answer("SIP/262-00000002", "") in new
stack
[Aug 5 22:18:16] VERBOSE[303] pbx.c: -- Executing
[631@interni_klici_telos:2] SpeechCreate("SIP/262-00000002", "") in
new stack
[Aug 5 22:18:16] NOTICE[303] app_unimrcp.c: Create MRCP Handle 0xa535308 [uni2]
[Aug 5 22:18:16] DEBUG[303] app_unimrcp.c: Create Channel 0xa535308 <new>
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Send session request type:2
[Aug 5 22:18:16] DEBUG[303] app_unimrcp.c: Signal Message to [MRCP
Client] [4;0]
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Wait for session response
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [4;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Receive App Request
0xa535308 <new> [2]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Add MRCP Handle 0xa535308 <new>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Dispatch App Request
0xa535308 <new> [2]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Signal Message to
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] NOTICE[32309] app_unimrcp.c: Add Control Channel
0xa535308 <new@speechrecog>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Add Media Termination
0xa535308 <new@media-tm>
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Poller Wakeup
[MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Add Media Termination
0xa535308 <new@rtp-tm>
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Message
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Signal Message to
[Media-Engine-1] [1;0]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Signal Message to [MRCP
Client] [2;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [2;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Control Channel Added
0xa535308 <new@speechrecog>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[32313] app_unimrcp.c: Process Message
[Media-Engine-1] [1;0]
[Aug 5 22:18:16] DEBUG[32313] app_unimrcp.c: Add Media Context 0xa535308
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [3;0]

[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Media Termination Added
0xa535308 <new@rtp-tm>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Send Offer 0xa535308
<new> [c:1 a:1 v:0] to 127.0.0.1:8060
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Local SDP 0xa535308 <new>
v=0
o=UniMRCPClient 0 0 IN IP4 127.0.0.1
s=-
c=IN IP4 127.0.0.1


t=0 0
m=application 9 TCP/MRCPv2 1
a=setup:active
a=connection:new
a=resource:speechrecog
a=cmid:1

m=audio 4000 RTP/AVP 0 8 96 101


a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:96 L16/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendonly
a=ptime:20
a=mid:1

[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[32310] app_unimrcp.c: Receive SIP Event


[nua_i_state] Status 0 INVITE sent

[Aug 5 22:18:16] NOTICE[32310] app_unimrcp.c: SIP Call State
0xa535308 [calling]
[Aug 5 22:18:16] DEBUG[32310] app_unimrcp.c: Receive SIP Event
[nua_r_invite] Status 200 OK
[Aug 5 22:18:16] DEBUG[32310] app_unimrcp.c: Receive SIP Event
[nua_i_state] Status 200 OK
[Aug 5 22:18:16] NOTICE[32310] app_unimrcp.c: SIP Call State 0xa535308 [ready]
[Aug 5 22:18:16] DEBUG[32310] app_unimrcp.c: Remote SDP 0xa535308 <new>
v=0
o=UniMRCPServer 6638611846974092934 763172150506164068 IN IP4 192.168.99.221
s=-
c=IN IP4 127.0.0.1
t=0 0
m=application 1544 TCP/MRCPv2 1
a=setup:passive
a=connection:new
a=channel:ab12894821bd4d69@speechrecog
a=cmid:1
m=audio 5000 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000


a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15

a=recvonly

a=ptime:20
a=mid:1

[Aug 5 22:18:16] DEBUG[32310] app_unimrcp.c: Receive SIP Event
[nua_i_active] Status 200 Call active
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [1;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Receive Answer 0xa535308


<new> [c:1 a:1 v:0]

[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Modify Control Channel
0xa535308 <ab12894821bd4d69>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Signal Message to
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Poller Wakeup
[MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Modify Media Termination
0xa535308 <ab12894821bd4d69@rtp-tm>
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Message
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Signal Message to
[Media-Engine-1] [1;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] NOTICE[32312] app_unimrcp.c: Established TCP/MRCPv2
Connection 127.0.0.1:55806 <-> 127.0.0.1:1544
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Add Control Channel
<ab12894821bd4d69@speechrecog> 127.0.0.1:55806 <-> 127.0.0.1:1544 [1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Signal Message to [MRCP
Client] [2;1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [2;1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Control Channel Modified
0xa535308 <ab12894821bd4d69@speechrecog>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[32313] app_unimrcp.c: Process Message
[Media-Engine-1] [1;0]
[Aug 5 22:18:16] DEBUG[32313] app_unimrcp.c: Enable RTP Session 127.0.0.1:4000
[Aug 5 22:18:16] DEBUG[32313] app_unimrcp.c: Create Linear Audio
Bridge 0xa535308
[Aug 5 22:18:16] DEBUG[32313] app_unimrcp.c: Open RTP Transmitter
127.0.0.1:4000 -> 127.0.0.1:5000
[Aug 5 22:18:16] DEBUG[32313] app_unimrcp.c: Media Path 0xa535308
Source->[LPCM/8000/1]->Bridge->[LPCM/8000/1]->Encoder->[PCMU/8000/1]->Sink
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [3;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Media Termination
Modified 0xa535308 <ab12894821bd4d69@rtp-tm>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Raise App Response
0xa535308 <ab12894821bd4d69> [2] SUCCESS [0]
[Aug 5 22:18:16] DEBUG[32309] res_speech_unimrcp.c: Received message
from client stack
[Aug 5 22:18:16] DEBUG[32309] res_speech_unimrcp.c: On channel add
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Waked up, status code: 0
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Create media buffer
frame_size:160
[Aug 5 22:18:16] NOTICE[303] res_speech_unimrcp.c: Created speech
instance 'ab12894821bd4d69'
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Set properties
'ab12894821bd4d69'
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Send MRCP request
[Aug 5 22:18:16] DEBUG[303] app_unimrcp.c: Signal Message to [MRCP
Client] [4;0]
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Wait for MRCP response
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [4;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Receive App MRCP Request
0xa535308 <ab12894821bd4d69>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Send MRCP Request
0xa535308 <ab12894821bd4d69@speechrecog> [1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Signal Message to
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Poller Wakeup
[MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Message
[MRCPv2-Agent-1] [1;0]

MRCP/2.0 132 SET-PARAMS 1
Channel-Identifier: ab12894821bd4d69@speechrecog
Recognition-Timeout: 20000
No-Input-Timeout: 15000

[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Signalled
Descriptor [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Receive MRCPv2 Stream
127.0.0.1:55806 <-> 127.0.0.1:1544 [80 bytes]
MRCP/2.0 80 1 200 COMPLETE
Channel-Identifier: ab12894821bd4d69@speechrecog


[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Signal Message to [MRCP
Client] [2;3]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [2;3]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Raise App MRCP Response
0xa535308 <ab12894821bd4d69>
[Aug 5 22:18:16] DEBUG[32309] res_speech_unimrcp.c: Received message
from client stack
[Aug 5 22:18:16] DEBUG[32309] res_speech_unimrcp.c: On message receive
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Waked up
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] VERBOSE[303] pbx.c: -- Executing
[631@interni_klici_telos:3] SpeechLoadGrammar("SIP/262-00000002",
"digit,/telos/asterisk-sources/test_models/grammar.xml") in new stack
[Aug 5 22:18:16] NOTICE[303] res_speech_unimrcp.c: Load grammar
name:digit type:application/srgs+xml
path:/telos/asterisk-sources/test_models/grammar.xml
'ab12894821bd4d69'
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Send MRCP request
[Aug 5 22:18:16] DEBUG[303] app_unimrcp.c: Signal Message to [MRCP
Client] [4;0]
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Wait for MRCP response
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [4;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Receive App MRCP Request
0xa535308 <ab12894821bd4d69>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Send MRCP Request
0xa535308 <ab12894821bd4d69@speechrecog> [2]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Signal Message to
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Poller Wakeup
[MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Message
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Send MRCPv2 Stream
127.0.0.1:55806 <-> 127.0.0.1:1544 [437 bytes]
MRCP/2.0 437 DEFINE-GRAMMAR 2
Channel-Identifier: ab12894821bd4d69@speechrecog
Content-Type: application/srgs+xml
Content-Id: digit
Content-Length: 278

<?xml version="1.0"?>
<grammar xmlns="http://www.w3.org/2001/06/grammar" xml:lang="en-US"
version="1.0" mode="voice" root="digit">
<rule id="digit">
<one-of>
<item>one</item>
<item>two</item>
<item>three</item>
</one-of>
</rule>
</grammar>
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Signalled
Descriptor [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Receive MRCPv2 Stream
127.0.0.1:55806 <-> 127.0.0.1:1544 [112 bytes]
MRCP/2.0 112 2 200 COMPLETE
Channel-Identifier: ab12894821bd4d69@speechrecog
Completion-Cause: 000 success


[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Signal Message to [MRCP
Client] [2;3]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [2;3]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Raise App MRCP Response
0xa535308 <ab12894821bd4d69>
[Aug 5 22:18:16] DEBUG[32309] res_speech_unimrcp.c: Received message
from client stack
[Aug 5 22:18:16] DEBUG[32309] res_speech_unimrcp.c: On message receive
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Waked up
[Aug 5 22:18:16] VERBOSE[303] pbx.c: -- Executing
[631@interni_klici_telos:4] SpeechActivateGrammar("SIP/262-00000002",
"digit") in new stack
[Aug 5 22:18:16] NOTICE[303] res_speech_unimrcp.c: Activate grammar
name:digit 'ab12894821bd4d69'
[Aug 5 22:18:16] VERBOSE[303] pbx.c: -- Executing
[631@interni_klici_telos:5] SpeechBackground("SIP/262-00000002",
"hello-world,20") in new stack
[Aug 5 22:18:16] NOTICE[303] res_speech_unimrcp.c: Start audio
'ab12894821bd4d69'
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Send MRCP request
[Aug 5 22:18:16] DEBUG[303] app_unimrcp.c: Signal Message to [MRCP
Client] [4;0]
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Wait for MRCP response
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [4;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Receive App MRCP Request
0xa535308 <ab12894821bd4d69>
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Send MRCP Request
0xa535308 <ab12894821bd4d69@speechrecog> [3]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Signal Message to
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Poller Wakeup
[MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Message
[MRCPv2-Agent-1] [1;0]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Send MRCPv2 Stream
127.0.0.1:55806 <-> 127.0.0.1:1544 [190 bytes]
MRCP/2.0 190 RECOGNIZE 3
Channel-Identifier: ab12894821bd4d69@speechrecog
Content-Type: text/uri-list
Cancel-If-Queue: false
Start-Input-Timers: true
Content-Length: 13

session:digit
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Process Signalled
Descriptor [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Receive MRCPv2 Stream
127.0.0.1:55806 <-> 127.0.0.1:1544 [83 bytes]
MRCP/2.0 83 3 200 IN-PROGRESS
Channel-Identifier: ab12894821bd4d69@speechrecog


[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Signal Message to [MRCP
Client] [2;3]
[Aug 5 22:18:16] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [2;3]
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Raise App MRCP Response
0xa535308 <ab12894821bd4d69>
[Aug 5 22:18:16] DEBUG[32309] res_speech_unimrcp.c: Received message
from client stack
[Aug 5 22:18:16] DEBUG[32309] res_speech_unimrcp.c: On message receive
[Aug 5 22:18:16] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:16] DEBUG[303] res_speech_unimrcp.c: Waked up
[Aug 5 22:18:17] DEBUG[32312] app_unimrcp.c: Process Signalled
Descriptor [MRCPv2-Agent-1]
[Aug 5 22:18:17] DEBUG[32312] app_unimrcp.c: Receive MRCPv2 Stream
127.0.0.1:55806 <-> 127.0.0.1:1544 [94 bytes]
MRCP/2.0 94 START-OF-INPUT 3 IN-PROGRESS
Channel-Identifier: ab12894821bd4d69@speechrecog


[Aug 5 22:18:17] DEBUG[32312] app_unimrcp.c: Signal Message to [MRCP
Client] [2;3]
[Aug 5 22:18:17] DEBUG[32312] app_unimrcp.c: Wait for Messages [MRCPv2-Agent-1]
[Aug 5 22:18:17] DEBUG[32309] app_unimrcp.c: Process Message [MRCP
Client] [2;3]
[Aug 5 22:18:17] DEBUG[32309] app_unimrcp.c: Raise App MRCP Event
0xa535308 <ab12894821bd4d69>
[Aug 5 22:18:17] DEBUG[32309] res_speech_unimrcp.c: Received message
from client stack
[Aug 5 22:18:17] DEBUG[32309] res_speech_unimrcp.c: On message receive
[Aug 5 22:18:17] DEBUG[32309] app_unimrcp.c: Wait for Messages [MRCP Client]
[Aug 5 22:18:42] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:42] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:42] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:42] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:43] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:43] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:43] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:43] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:43] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:44] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:45] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:45] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:45] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:45] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:45] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:45] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:18:54] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:50] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:50] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:50] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:51] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:51] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:51] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:51] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:51] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:51] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:52] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:52] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:52] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:52] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:52] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:52] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:52] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:53] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:53] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:53] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:53] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:53] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:53] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:53] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:54] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:54] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:19:54] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:20:58] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:20:58] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:20:58] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:20:58] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:20:59] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:20:59] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:20:59] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:00] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:00] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:00] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:00] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:00] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:00] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:00] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:00] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:01] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:01] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:01] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:01] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:01] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:01] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:01] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:01] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:02] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:02] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:02] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:21:02] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:07] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:07] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:07] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:07] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:07] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:07] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:08] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:08] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:08] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:08] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:08] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:08] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:09] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:10] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:10] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320
[Aug 5 22:22:10] DEBUG[303] res_speech_unimrcp.c: Failed to write audio len:320


***** UniMRCP server debug *****

>2011-08-05 22:18:16:613534 [INFO] Receive SIP Event [nua_i_invite] Status 100 Trying
2011-08-05 22:18:16:613653 [INFO] Receive SIP Event [nua_i_state]
Status 100 Trying
2011-08-05 22:18:16:613715 [NOTICE] SIP Call State [received]
2011-08-05 22:18:16:648900 [INFO] Create Session 0x9e58800 <new> [uni2]
2011-08-05 22:18:16:648997 [INFO] Remote SDP 0x9e58800 <new>
v=0
o=UniMRCPClient 2171006181812647067 1247851589215049543 IN IP4 192.168.99.221
s=-
c=IN IP4 127.0.0.1


t=0 0
m=application 9 TCP/MRCPv2 1
a=setup:active
a=connection:new
a=resource:speechrecog
a=cmid:1

m=audio 4000 RTP/AVP 0 8 96 101


a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:96 L16/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendonly
a=ptime:20
a=mid:1

2011-08-05 22:18:16:659008 [NOTICE] Add Session <ab12894821bd4d69>
2011-08-05 22:18:16:659091 [INFO] Receive Offer 0x9e58800
<ab12894821bd4d69> [c:1 a:1 v:0]
2011-08-05 22:18:16:659618 [INFO] Add Pending Control Channel
<ab12894821bd4d69@speechrecog> [1]
2011-08-05 22:18:16:662903 [INFO] Enable RTP Session 127.0.0.1:5000
2011-08-05 22:18:16:663069 [INFO] Open RTP Receiver 127.0.0.1:5000
<- 127.0.0.1:4000 playout [50 ms]
2011-08-05 22:18:16:663136 [INFO] Media Path 0x9e58800
Source->[PCMU/8000/1]->Decoder->[LPCM/8000/1]->Bridge->[LPCM/8000/1]->Sink
2011-08-05 22:18:16:663614 [INFO] Send Answer 0x9e58800
<ab12894821bd4d69> [c:1 a:1 v:0] Status OK
2011-08-05 22:18:16:663773 [INFO] Local SDP 0x9e58800 <ab12894821bd4d69>
v=0
o=UniMRCPServer 0 0 IN IP4 127.0.0.1
s=-
c=IN IP4 127.0.0.1
t=0 0
m=application 1544 TCP/MRCPv2 1
a=setup:passive
a=connection:new
a=channel:ab12894821bd4d69@speechrecog
a=cmid:1
m=audio 5000 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000


a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15

a=recvonly
a=ptime:20
a=mid:1

2011-08-05 22:18:16:666428 [INFO] Receive SIP Event [nua_i_state]
Status 200 OK
2011-08-05 22:18:16:666512 [NOTICE] SIP Call State 0x9e58800 [completed]
2011-08-05 22:18:16:668140 [INFO] Receive SIP Event [nua_i_ack] Status 200 OK
2011-08-05 22:18:16:668233 [INFO] Receive SIP Event [nua_i_state]
Status 200 OK
2011-08-05 22:18:16:668285 [NOTICE] SIP Call State 0x9e58800 [ready]
2011-08-05 22:18:16:668336 [INFO] Receive SIP Event [nua_i_active]
Status 200 Call active
2011-08-05 22:18:16:670320 [NOTICE] Accepted TCP/MRCPv2 Connection
127.0.0.1:1544 <-> 127.0.0.1:55806
2011-08-05 22:18:16:679701 [INFO] Receive MRCPv2 Stream
127.0.0.1:1544 <-> 127.0.0.1:55806 [132 bytes]
MRCP/2.0 132 SET-PARAMS 1
Channel-Identifier: ab12894821bd4d69@speechrecog
Recognition-Timeout: 20000
No-Input-Timeout: 15000


2011-08-05 22:18:16:680309 [INFO] Attach Control Channel
<ab12894821bd4d69@speechrecog> to Connection 127.0.0.1:1544 <->
127.0.0.1:55806 [1]
2011-08-05 22:18:16:680630 [INFO] Process SET-PARAMS Request
<ab12894821bd4d69@speechrecog> [1]
2011-08-05 22:18:16:680813 [INFO] Process SET-PARAMS Response
<ab12894821bd4d69@speechrecog> [1]
2011-08-05 22:18:16:681013 [INFO] Send MRCPv2 Stream 127.0.0.1:1544
<-> 127.0.0.1:55806 [80 bytes]
MRCP/2.0 80 1 200 COMPLETE
Channel-Identifier: ab12894821bd4d69@speechrecog


2011-08-05 22:18:16:684182 [INFO] Receive MRCPv2 Stream
127.0.0.1:1544 <-> 127.0.0.1:55806 [437 bytes]
MRCP/2.0 437 DEFINE-GRAMMAR 2
Channel-Identifier: ab12894821bd4d69@speechrecog
Content-Type: application/srgs+xml
Content-Id: digit
Content-Length: 278

<?xml version="1.0"?>
<grammar xmlns="http://www.w3.org/2001/06/grammar" xml:lang="en-US"
version="1.0" mode="voice" root="digit">
<rule id="digit">
<one-of>
<item>one</item>
<item>two</item>
<item>three</item>
</one-of>
</rule>
</grammar>
2011-08-05 22:18:16:684446 [INFO] Process DEFINE-GRAMMAR Request
<ab12894821bd4d69@speechrecog> [2]
2011-08-05 22:18:16:684593 [INFO] Process DEFINE-GRAMMAR Response
<ab12894821bd4d69@speechrecog> [2]
2011-08-05 22:18:16:684770 [INFO] Send MRCPv2 Stream 127.0.0.1:1544
<-> 127.0.0.1:55806 [112 bytes]
MRCP/2.0 112 2 200 COMPLETE
Channel-Identifier: ab12894821bd4d69@speechrecog
Completion-Cause: 000 success


2011-08-05 22:18:16:688234 [INFO] Receive MRCPv2 Stream
127.0.0.1:1544 <-> 127.0.0.1:55806 [190 bytes]
MRCP/2.0 190 RECOGNIZE 3
Channel-Identifier: ab12894821bd4d69@speechrecog
Content-Type: text/uri-list
Cancel-If-Queue: false
Start-Input-Timers: true
Content-Length: 13

session:digit
2011-08-05 22:18:16:688559 [INFO] Process RECOGNIZE Request
<ab12894821bd4d69@speechrecog> [3]
2011-08-05 22:18:16:688895 [INFO] Process RECOGNIZE Response
<ab12894821bd4d69@speechrecog> [3]
2011-08-05 22:18:16:688945 [INFO] State Transition IDLE ->
RECOGNIZING <ab12894821bd4d69@speechrecog>
2011-08-05 22:18:16:689085 [INFO] Send MRCPv2 Stream 127.0.0.1:1544
<-> 127.0.0.1:55806 [83 bytes]
MRCP/2.0 83 3 200 IN-PROGRESS
Channel-Identifier: ab12894821bd4d69@speechrecog


2011-08-05 22:18:17:062569 [INFO] Detected Voice Activity
<ab12894821bd4d69@speechrecog>
2011-08-05 22:18:17:062934 [INFO] Process START-OF-INPUT Event
<ab12894821bd4d69@speechrecog> [3]
2011-08-05 22:18:17:063092 [INFO] Send MRCPv2 Stream 127.0.0.1:1544
<-> 127.0.0.1:55806 [94 bytes]
MRCP/2.0 94 START-OF-INPUT 3 IN-PROGRESS
Channel-Identifier: ab12894821bd4d69@speechrecog

Best regards
Dejan

Arsen Chaloyan

unread,
Sep 22, 2011, 4:47:24 PM9/22/11
to uni...@googlegroups.com
Hello Dejan,

You still have a problem with the detection of end of input.

2011-08-05 22:18:17:062569 [INFO] Detected Voice Activity
<ab12894821bd4d69@speechrecog>

this one is missing
2011-08-05 22:18:xx:xxxxxx [INFO] Detected Voice Inactivity
<ab12894821bd4d69@speechrecog>

Try to experiment more with the same settings


<sensitivity level="50" activity-timeout="300" inactivity-timeout="300"/>

BTW, you can enable an additional log output which is commented out by
default. Go to mpf_activity_detector.c :127
#if 1
apt_log(APT_LOG_MARK,APT_PRIO_INFO,"Activity Detector
[%"APR_SIZE_T_FMT"]",level);
#endif

Keep track of the "level" and you will figure out what to use in the config.

Dejan Stimpfelj

unread,
Oct 12, 2011, 3:13:58 AM10/12/11
to uni...@googlegroups.com
Dear Arsen

Thank you very much for your answer. My settings in the
pocketsphinx.xml are the same as you suggested:

<sensitivity level="50" activity-timeout="300" inactivity-timeout="300"/>

I tried enabling the additonal debug and I am sending the unimrcp
server log in the attachment. You can eazily see the increase of the
counter to well over a 1000 when I say a number in the phone handset.
To be totally honest I can not make much sense from this debug, so I
would like to ask you to make a suggestion about the parameter
tweaking in pocketsphinx.xml or any other conf file.

Thank you very much for your help in advance.

Best regards
Dejan

unimrcpserver.log

Dejan Stimpfelj

unread,
Dec 15, 2011, 12:35:16 PM12/15/11
to uni...@googlegroups.com
Hello

I am still not able to get the voice recognition to work in my Asterisk-UniMRCP setup.

Or more thing that I noticed is, that when I start the unimrcp server, I also get 2 warning messages:

[WARN]   Unknown Attribute <inactivity-timeout>
[WARN]   Unknown Attribute <activity-timeout>

My pocketsphinx.xml containes this line:


 <sensitivity level="50" activity-timeout="300" inactivity-timeout="300"/>

But the "inactivity-timeout" and "activity-timeout" should be perameters that the unimrcp server code recognizes. Or am I doing something wrong?

If I check the asterisk full log, these messages still keep pooping up:

DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320
DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320
DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320
DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320
DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320

I really do not know what that is supposed to mean. There is no firewall on the server and if I do a packet capture with tcpdump I see that the RTP packets are flowing correctly.

Best regards
Dejan

Arsen Chaloyan

unread,
Dec 16, 2011, 9:42:01 PM12/16/11
to uni...@googlegroups.com
Hello Dejan,

Please see below

On Thu, Dec 15, 2011 at 9:35 AM, Dejan Stimpfelj <yac...@gmail.com> wrote:
> Hello
>
> I am still not able to get the voice recognition to work in my
> Asterisk-UniMRCP setup.
>
> Or more thing that I noticed is, that when I start the unimrcp server, I
> also get 2 warning messages:
>
> [WARN]   Unknown Attribute <inactivity-timeout>
> [WARN]   Unknown Attribute <activity-timeout>
>
> My pocketsphinx.xml containes this line:
>
>
>  <sensitivity level="50" activity-timeout="300" inactivity-timeout="300"/>

It looks like you are using the new configuration parameters with the
old software.

I split the common "timeout" into two parts "activity-timeout" and
"inactivity-timeout" in r1743

http://code.google.com/p/unimrcp/source/detail?spec=svn1820&r=1743

Thus, with the version you have installed at the moment, use the
common "timeout" instead. Later on, when you figure out how to make it
work with the current version, you may consider upgrading to the
latest one.

>
> But the "inactivity-timeout" and "activity-timeout" should be perameters
> that the unimrcp server code recognizes. Or am I doing something wrong?
>
> If I check the asterisk full log, these messages still keep pooping up:
>
> DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320
> DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320
> DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320
> DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320
> DEBUG[17395] res_speech_unimrcp.c: Failed to write audio len:320

This is not good, but it's not the source of the problem you were
experiencing originally. I mean the detection of voice inactivity.
Looking at the provided logs, I could see that the voice energy/level
was high enough even at the end of the utterance. I don't know either
you kept speaking towards the end or there was a significant
background noise. This makes an energy level based detection of voice
(in)activity quite tricky. There are superior techniques, of course,
to filter out background noise...

In other words, if you want to use the pocketsphinx plugin, you should
be ready to fight against several issues, as it's not production
ready.

>
> I really do not know what that is supposed to mean. There is no firewall on
> the server and if I do a packet capture with tcpdump I see that the RTP
> packets are flowing correctly.
>
> Best regards
> Dejan

Best regards,

Dejan Stimpfelj

unread,
Dec 20, 2011, 12:12:38 PM12/20/11
to uni...@googlegroups.com
Dear Arsen

I am running a manually compiled Asterisk 1.8.7.0 on CentOS 5.7 box. I made the dialplan myself. I am running the latest stable version of the unimrcp package:

uni-ast-package-0.3.2
unimrcp-1.0.0
unimrcp-deps-1.1.0

I am willing to work with unimrcp until I get it working, but I am still very very lost and don't know where to look for a solution.

I switched back to "timeout" parameter and I also tweaked the "sensitivity-level" parameter value from 50 to 1000, but no luck. I do not have much background noise in my test enviroment, so it should not be an issue.

Do you have any more advice on what I can try to get basic voice recognition to work? Based on the sent debug, do you have any suggestion for the "sensitivity-level" and "timeout" parameter values?

Best regards
Dejan
Reply all
Reply to author
Forward
0 new messages