Владимир Дашукевич @life__777
Владимир Дашукевич @life__777
Звук — физическое явление, представляющее собой распространение в виде упругих волн механических колебаний в твёрдой, жидкой или газообразной среде.
var recognition = new webkitSpeechRecognition();
recognition.onresult = function(event) {
if (event.results.length > 0) {
q.value = event.results[0][0].transcript;
}
}
recognition.start();
var recognition = new webkitSpeechRecognition();
recognition.onresult = function(event) {
if (event.results.length > 0) {
q.value = event.results[0][0].transcript;
}
}
recognition.start();
var recognition = new webkitSpeechRecognition();
recognition.onresult = function(event) {
if (event.results.length > 0) {
q.value = event.results[0][0].transcript;
}
}
recognition.start();
var recognition = new webkitSpeechRecognition();
recognition.onresult = function(event) {
if (event.results.length > 0) {
q.value = event.results[0][0].transcript;
}
}
recognition.start();
{ 0: {
confidence: 0.9320464730262756,
transcript: "зубная паста"
}, 1: {
confidence: 0.3405290540655,
transcript: "зубная паста спб"
},
isFinal:true,
length: 2 }
{ 0: {
confidence: 0.9320464730262756,
transcript: "зубная паста"
}, 1: {
confidence: 0.3405290540655,
transcript: "зубная паста спб"
},
isFinal:true,
length: 2 }
{ 0: {
confidence: 0.9320464730262756,
transcript: "зубная паста"
}, 1: {
confidence: 0.3405290540655,
transcript: "зубная паста спб"
},
isFinal:true,
length: 2 }
continuous
interimResults
lang
maxAlternatives
grammars
var u = new SpeechSynthesisUtterance();
u.text = 'Привет';
u.lang = 'ru-RU';
speechSynthesis.speak(u);
var u = new SpeechSynthesisUtterance();
u.text = 'Привет';
u.lang = 'ru-RU';
speechSynthesis.speak(u);
var u = new SpeechSynthesisUtterance();
u.text = 'Привет';
u.lang = 'ru-RU';
speechSynthesis.speak(u);
var u = new SpeechSynthesisUtterance();
u.text = 'Привет';
u.lang = 'ru-RU';
speechSynthesis.speak(u);
volume
pitch
rate
lang
voice
Генерация и распознование речи | |
Генерация речи | |
Не поддерживается |
var audioContext = new AudioContext();
navigator.getUserMedia({audio: true}, function(stream) {
var input = audioContext.createMediaStreamSource(stream);
recorder = new AudioRecorder(input);
recognizer = new Module.Recognizer();
recorder.consumers.push(recognizer);
recorder.start();
}, function(e) {});
var audioContext = new AudioContext();
navigator.getUserMedia({audio: true}, function(stream) {
var input = audioContext.createMediaStreamSource(stream);
recorder = new AudioRecorder(input);
recognizer = new Module.Recognizer();
recorder.consumers.push(recognizer);
recorder.start();
}, function(e) {});
var audioContext = new AudioContext();
navigator.getUserMedia({audio: true}, function(stream) {
var input = audioContext.createMediaStreamSource(stream);
recorder = new AudioRecorder(input);
recognizer = new Module.Recognizer();
recorder.consumers.push(recognizer);
recorder.start();
}, function(e) {});
var audioContext = new AudioContext();
navigator.getUserMedia({audio: true}, function(stream) {
var input = audioContext.createMediaStreamSource(stream);
recorder = new AudioRecorder(input);
recognizer = new Module.Recognizer();
recorder.consumers.push(recognizer);
recorder.start();
}, function(e) {});
var audioContext = new AudioContext();
navigator.getUserMedia({audio: true}, function(stream) {
var input = audioContext.createMediaStreamSource(stream);
recorder = new AudioRecorder(input);
recognizer = new Module.Recognizer();
recorder.consumers.push(recognizer);
recorder.start();
}, function(e) {});
var recognizer = new Module.Recognizer(),
words = new Module.VectorWords()
words.push_back(["Привет", "PR EE V ET"]);
words.push_back(["мир", "M IY R"]);
recognizer.addWords(words)
var recognizer = new Module.Recognizer(),
words = new Module.VectorWords()
words.push_back(["Привет", "PR EE V ET"]);
words.push_back(["мир", "M IY R"]);
recognizer.addWords(words)
{numStates: 3, start: 0, end: 3, transitions: [
{from: 0, to: 1, word: "WINDOWS"},
{from: 0, to: 1, word: "LINUX"},
{from: 1, to: 2, word: "IS"},
{from: 2, to: 2, word: "NOT"},
{from: 2, to: 3, word: "GOOD"},
{from: 2, to: 3, word: "BAD"}]}
{numStates: 3, start: 0, end: 3, transitions: [
{from: 0, to: 1, word: "WINDOWS"},
{from: 0, to: 1, word: "LINUX"},
{from: 1, to: 2, word: "IS"},
{from: 2, to: 2, word: "NOT"},
{from: 2, to: 3, word: "GOOD"},
{from: 2, to: 3, word: "BAD"}]}
{numStates: 3, start: 0, end: 3, transitions: [
{from: 0, to: 1, word: "WINDOWS"},
{from: 0, to: 1, word: "LINUX"},
{from: 1, to: 2, word: "IS"},
{from: 2, to: 2, word: "NOT"},
{from: 2, to: 3, word: "GOOD"},
{from: 2, to: 3, word: "BAD"}]}
{numStates: 3, start: 0, end: 3, transitions: [
{from: 0, to: 1, word: "WINDOWS"},
{from: 0, to: 1, word: "LINUX"},
{from: 1, to: 2, word: "IS"},
{from: 2, to: 2, word: "NOT"},
{from: 2, to: 3, word: "GOOD"},
{from: 2, to: 3, word: "BAD"}]}
var julius = new Julius();
julius.onrecognition = function(sentence) {
console.log(sentence);
};