Metadata-Version: 2.4
Name: pvbatdemo
Version: 1.0.1
Summary: Bat spoken language identification engine demos
Home-page: https://github.com/Picovoice/bat
Author: Picovoice
Author-email: hello@picovoice.ai
Keywords: Spoken Language Identification,Language Detection,Speech Recognition,Voice Recognition
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Multimedia :: Sound/Audio :: Speech
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: pvbat==1.0.1
Requires-Dist: pvrecorder==1.2.7
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: keywords
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# Bat Spoken Language Identification Demos

Made in Vancouver, Canada by [Picovoice](https://picovoice.ai)

## Bat

Bat is an on-device spoken language identification engine. Bat is:

- Private; All voice processing runs locally.
- Cross-Platform:
    - Linux (x86_64), macOS (x86_64, arm64), and Windows (x86_64, arm64)
    - Android and iOS
    - Chrome, Safari, Firefox, and Edge
    - Raspberry Pi (3, 4, 5)

## Compatibility

- Python 3.9+
- Runs on Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64, arm64), and Raspberry Pi (3, 4, 5).

## Installation

```console
pip3 install pvbatdemo
```

## AccessKey

Bat requires a valid Picovoice `AccessKey` at initialization. `AccessKey` acts as your credentials when using Bat SDKs.
You can get your `AccessKey` for free. Make sure to keep your `AccessKey` secret.
Signup or Login to [Picovoice Console](https://console.picovoice.ai/) to get your `AccessKey`.

## Usage

### Microphone Demo

The mic demo takes audio input from a microphone and outputs the language detection scores to the terminal.

You need a working microphone connected to your machine for this demo. Run the following in the terminal:

```console
bat_demo_mic --access_key ${ACCESS_KEY}
```

Replace `${ACCESS_KEY}` with yours obtained from Picovoice Console.

### File Demo

The file demo takes audio input from a series of `.wav` files and prints the language detection scores to the terminal.
Each set of scores is tagged with the timestamp in seconds for the corresponding audio file.

Run the following in the terminal:

```console
bat_demo_file --access_key ${ACCESS_KEY} --wav_paths ${WAV_PATH}
```

Replace `${ACCESS_KEY}` with yours obtained from Picovoice Console and `${WAV_PATH}` with a path to a compatible
(single-channel, 16 kHz, 16-bit PCM) wav file you wish to process.
