Speech recognition in php

Question:

This question is out of curiosity, I'm not messing with anything like that, but in the future who knows.

I wanted to know if there is some kind of system or if it is possible to create a system that can do voice recognition (either for login, or any commands), using php.

If it is not possible, I would like to understand why it is not possible to do something like this in php.

I find the voice feature fascinating, and I consider, when I have more ownership and maturity on the subject, working on a system or api of the kind.

Answer:

The "state of the art" speech recognition is quite advanced, so implementing such a system from scratch would be a huge job, would require a lot of research and a lot of people working for months or years. It makes more sense in this case to call a third-party API (which has already solved the problem), such as https://wit.ai

That said, disregarding performance/efficiency, there is in theory nothing to stop someone from implementing a speech recognition system "by hand" in PHP (or any language). You would need to use (or develop) a library to read the audio file and return a stream, and then pass that stream through some sort of processing to recognize speech.

There are several techniques for speech recognition (hidden Markov models, DTW, Neural Networks, etc). This wikipedia link has some information on the subject:

https://en.wikipedia.org/wiki/Speech_recognition#Models.2C_methods.2C_and_algorithms

Here is the HTTP API documentation from wit.ai, which I mentioned above:

https://wit.ai/docs/http/20141022

The examples are in bash (using cURL), so you would have to rewrite them in PHP.

Scroll to Top
AllEscort