सार्वजनिक जानकारी से बना चयन मार्गदर्शन। केवल संदर्भ हेतु।
Cheetah Flutter एक Flutter प्लगइन है जो Picovoice के Cheetah स्पीच-टू-टेक्स्ट इंजन को एकीकृत करता है, जिससे कम लेटेंसी और उच्च सटीकता के साथ रियल-टाइम, डिवाइस पर बोली का अनुवाद संभव होता है। गोपनीयता-केंद्रित एप्लिकेशन के लिए डिज़ाइन किया गया, यह डेटा को क्लाउड में भेजे बिना ऑडियो को स्थानीय रूप से प्रोसेस करता है। प्लगइन Android और iOS प्लेटफॉर्म का समर्थन करता है, जिससे ऑफलाइन कार्यक्षमता की आवश्यकता वाले वॉइस-नियंत्रित एप्लिकेशन के लिए आदर्श है। यह बोली के अनुवाद को शुरू और बंद करने, प्राप्त टेक्स्ट को संभालने और ऑडियो इनपुट को प्रबंधित करने के लिए एक सरल API प्रदान करता है।
उपयोग
ऑफलाइन वॉइस असिस्टेंट
वॉइस कंट्रोल्ड आईओटी डिवाइस
गोपनीयता-संवेदनशील ट्रांसक्रिप्शन ऐप
रियल-टाइम कमांड पहचान
डिवाइस-आधारित बोलने का प्रसंस्करण
मुख्य विशेषताएँ
डिवाइस-पर बोलने का पहचान
कम लेटेंसी प्रदर्शन
Android और iOS का समर्थन करता है
बादल निर्भरता नहीं
Flutter के साथ सरल एकीकरण
इनके लिए उपयुक्त
ऑफलाइन वॉइस फीचर्स बनाने वाले डेवलपर्स
डेटा गोपनीयता की आवश्यकता वाले ऐप्स
रियल-टाइम वॉइस कमांड सिस्टम
एम्बेडेड वॉइस-सक्षम डिवाइसेस
हल्के ASR की आवश्यकता वाले Flutter प्रोजेक्ट
विचार योग्य बातें
मूल प्लेटफॉर्म सेटअप की आवश्यकता है
समर्थित भाषाओं तक सीमित
शोरग्रस्त वातावरण के लिए सूक्ष्म-समायोजन की आवश्यकता हो सकती है
बड़े शब्दावली के कार्यों के लिए उपयुक्त नहीं
Cheetah इंजन लाइसेंसिंग पर निर्भर करता है
मूल README
संबंधित सोर्स रिपॉज़िटरी के मूल README का स्नैपशॉट। नवीनतम सामग्री के लिए रिपॉज़िटरी देखें।
AccessKey is your authentication and authorization token for deploying Picovoice SDKs, including Cheetah. Anyone who is
using Picovoice needs to have a valid AccessKey. You must keep your AccessKey secret. You would need internet
connectivity to validate your AccessKey with Picovoice license servers even though the voice recognition is running 100%
offline.
AccessKey also verifies that your usage is within the limits of your account. You can see your usage limits and real-time usage on your Picovoice Console Profile. To get, renew or adjust your usage limits, please reach out to our Enterprise Sales Team or your existing Picovoice contact.
Language Support
Cheetah Streaming Speech-to-Text currently supports English, French, German, Italian, Portuguese, and Spanish.
./demo/c/build/cheetah_demo_mic -a ${ACCESS_KEY} -m ${MODEL_PATH} -l ${LIBRARY_PATH}
Replace ${ACCESS_KEY} with yours obtained from Picovoice Console, ${LIBRARY_PATH} with the path to appropriate
library under lib, and ${MODEL_PATH} to path to default model file
(or your custom one).
Replace let accessKey = "${YOUR_ACCESS_KEY_HERE}" in the file ViewModel.swift with your AccessKey.
Then, using Xcode, open the generated CheetahDemo.xcworkspace and run the application.
Android Demo
Using Android Studio, open demo/android/CheetahDemo as an Android project and then run the application.
Replace "${YOUR_ACCESS_KEY_HERE}" in the file MainActivity.java with your AccessKey.
Flutter Demo
To run the Cheetah demo on Android or iOS with Flutter, you must have the Flutter SDK installed on your system. Once installed, you can run flutter doctor to determine any other missing requirements for your relevant platform. Once your environment has been set up, launch a simulator or connect an Android/iOS device.
Run the prepare_demo script from demo/flutter with a language code to set up the demo in the language of your choice (e.g. de -> German, ko -> Korean). To see a list of available languages, run prepare_demo without a language code.
dart scripts/prepare_demo.dart ${LANGUAGE}
Replace "${YOUR_ACCESS_KEY_HERE}" in the file main.dart with your AccessKey.
Run the following command from demo/flutter to build and deploy the demo to your device:
flutter run
React Native Demo
To run the React Native Cheetah demo app you will first need to set up your React Native environment. For this,
please refer to React Native's documentation. Once your environment has
been set up, navigate to demo/react-native/CheetahDemo to run the following commands:
For Android:
yarn android-install # sets up environment
yarn android-run ${LANGUAGE}# builds and deploys to Android
For iOS:
yarn ios-install # sets up environment
yarn ios-run ${LANGUAGE}# builds and deploys to iOS
Node.js Demo
Install the demo package:
yarn global add @picovoice/cheetah-node-demo
With a working microphone connected to your device, run the following in the terminal:
cheetah-mic-demo --access_key ${ACCESS_KEY}
For more information about Node.js demos go to demo/nodejs.
Java Demos
The Cheetah Java demo is a command-line application that lets you choose between running Cheetah on an audio file or on real-time microphone input.
To try the real-time demo, make sure there is a working microphone connected to your device. Then invoke the following commands from the terminal:
cd demo/java
./gradlew build
cd build/libs
java -jar cheetah-mic-demo.jar -a ${ACCESS_KEY}
For more information about Java demos go to demo/java.
.NET Demo
Cheetah .NET demo is a command-line application that lets you choose between running Cheetah on an audio
file or on real-time microphone input.
Make sure there is a working microphone connected to your device. From demo/dotnet/CheetahDemo
run the following in the terminal:
dotnet run -c MicDemo.Release -- --access_key ${ACCESS_KEY}
Replace ${ACCESS_KEY} with your Picovoice AccessKey.
For more information about .NET demos, go to demo/dotnet.
Replace ${ACCESS_KEY} with yours obtained from Picovoice Console and ${MODEL_PATH} to path to
default model file (or your custom one). Finally, when done be sure to release
resources acquired using pv_cheetah_delete(handle).
iOS
The Cheetah iOS binding is available via CocoaPods. To import it into your iOS project, add the following line to your Podfile and run pod install:
pod 'Cheetah-iOS'
Create an instance of the engine and transcribe audio in real-time:
import Cheetah
let modelPath = Bundle(for: type(of: self)).path(
forResource: "${MODEL_FILE}", // Name of the model file name for Cheetah
ofType: "pv")!
let cheetah = Cheetah(accessKey: "${ACCESS_KEY}", modelPath: modelPath)
func getNextAudioFrame() -> [Int16] {
// .. get audioFrame
return audioFrame;
}
while true {
do {
let partialTranscript, isEndpoint = try cheetah.process(getNetAudioFrame())
if isEndpoint {
let finalTranscript = try cheetah.flush()
}
} catch let error as CheetahError {
// handle error
} catch { }
}
Replace ${ACCESS_KEY} with yours obtained from Picovoice Console and ${MODEL_FILE} with a custom trained model from
Picovoice Console or the default model.
Android
To include the package in your Android project, ensure you have included mavenCentral() in your top-level build.gradle file and then add the following to your app's build.gradle:
Replace ${ACCESS_KEY} with yours obtained from Picovoice Console and ${MODEL_FILE} with the default or custom trained model from console. When done be sure to explicitly release the resources using cheetah.delete().
When initialized, the valid sample rate is given by handle.SampleRate. Expected frame length (number of audio samples in an input array) is handle.FrameLength. The engine accepts 16-bit linearly-encoded PCM and operates on single-channel audio.