
speechly-browser-client

This repository contains source code for the browser client for Speechly SLU API. Speechly allows you to easily build applications with voice-enabled UIs.
Usage
Install the package:
# Using Yarn
yarn add @speechly/browser-client
# Using NPM
npm install --save @speechly/browser-client
Start using the client:
import { Client, Segment } from "@speechly/browser-client";
const client = new Client({
appId: "your-app-id",
language: "en-US",
});
await client.initialize();
client.onSegmentChange((segment: Segment) => {
console.log(
"Received new segment from the API:",
segment.intent,
segment.entities,
segment.words,
segment.isFinal
);
});
await client.startContext();
setTimeout(async function() {
await client.stopContext();
}, 3000);
Check out the browser-client-example repository for a demo app built using this client.
Documentation
You can find the detailed API documentation in GitHub repository.
Contributing
See contribution guide in CONTRIBUTING.md.