Android Question What is the current best option for offline Speech To Text

Mike1970

Well-Known Member
Licensed User
Longtime User
Hi everyone, I'm looking for an offline speech to text library... which the best one currently?
I was using this one, but it stopped working... so I switched to this one, but this one misunderstand a lot of words... is not precise...

Thanks in advance
 

JohnC

Expert
Licensed User
Longtime User
The first one looks like it would be the best one because it uses android's own SR engine.

What exactly "stopped working"?
 
Upvote 0

Mike1970

Well-Known Member
Licensed User
Longtime User
The first one looks like it would be the best one because it uses android's own SR engine.
Exactly


What exactly "stopped working"?
So, the problem came out because, out of the clear blue sky, after an year some clients told me that the app started crashing when using the speech to text, so I connected my phone to B4A to see the logs and i found out this and this.

Then I tried merging the original class with the code suggested by Cesaral but still does not work, when i start the STT the app crashes and in the logs i only see this:
B4X:
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create (first time) **
** Activity (main) Resume **
** Activity (main) Pause, UserClosed = false **
sending message to waiting queue (activity_permissionresult)
running waiting messages (1)
** Activity (main) Resume **
** Activity (main) Pause, UserClosed = true **
Received_Event=onReadyForSpeech
Received_Event=onRmsChanged=-2.0
Received_Event=onRmsChanged=0.76
Received_Event=onRmsChanged=-2.0
Received_Event=onError
SR_Error: 5
Client side error
** Service (starter) Destroy (ignored)**

i attach the code i used for this last test
 

Attachments

  • testSR_2.zip
    10.4 KB · Views: 155
Upvote 0

JohnC

Expert
Licensed User
Longtime User
I did not run your code, but I did find these two articles for error "5":


 
Upvote 0

GMan

Well-Known Member
Licensed User
Longtime User
On Android 13 the app crashes directly after starting
 
Upvote 0

Mike1970

Well-Known Member
Licensed User
Longtime User
I did not run your code, but I did find these two articles for error "5":


i see, seems to be something related to google things...
in the second post however they talk about "stopListening" and "cancel", but in this case this is not the problem

i also found this:
 
Upvote 0

Mike1970

Well-Known Member
Licensed User
Longtime User
i see, seems to be something related to google things...
in the second post however they talk about "stopListening" and "cancel", but in this case this is not the problem

i also found this:
Any news about this? For b4a?
 
Upvote 0
Top