Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
Adding header and other minor changes.
  • Loading branch information
nickali authored Mar 27, 2023
1 parent 2414893 commit 07db3bc
Showing 1 changed file with 33 additions and 12 deletions.
45 changes: 33 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,35 +1,56 @@
<p align="center">
<img src="https://raw.githubusercontent.com/NICEElevateAI/NICEElevateAI/main/images/ElevateAI-blue-red-logo.png" />
</p>

<div align="center"><a name="menu"></a>
<h4>
<a href="https://www.elevateai.com">
Website
</a>
<span> | </span>
<a href="https://docs.elevateai.com">
Documentation
</a>
<span> | </span>
<a href="https://www.elevateai.com/blogs">
Blog
</a>
</h4>
</div>

# ElevateAI Java SDK

ElevateAI - the most afforable, accurate Speech-to-text (ASR) API. Free to use for hundreds of hours of audio per month!
[ElevateAI](https://www.elevateai.com) provides an API for Speech-to-text (ASR), behavioral analysis and sentiment analysis of voice interactions.

Steps - Pre Req: signup for a free account @ https://app.elevateai.com and retrieve your API token
1. Declare an interaction (give a URI if you want ElevateAI to download the interaction via a Public URI)
2. Store Interaction ID
3. Upload a file if no URI specified during declare using the Interaction ID
4. Check status every 30 seconds using Interaction ID until status is 'processed' or an error status https://docs.elevateai.com/tutorials/check-the-processing-status
5. Retrieve results (transcripts, ai results) https://docs.elevateai.com/tutorials/get-phrase-by-phrase-transcript
### Example
1. [Signup](https://app.elevateai.com) and retrieve API token from ElevateAI.
1. Declare an interaction. Provide a URI if you want ElevateAI to download the interaction via a Public URI.
2. Retrieve Interaction ID from JSON response and store.
3. Upload a file.
4. Check status every 30 seconds using Interaction ID until status returns 'processed' or an [error status](https://docs.elevateai.com/tutorials/check-the-processing-status).
5. Retrieve results - [phrase-by-phrase transcript](https://docs.elevateai.com/tutorials/get-phrase-by-phrase-transcript), [punctuated transcript](https://docs.elevateai.com/tutorials/get-punctuated-transcript), and [AI results](https://docs.elevateai.com/tutorials/get-cx-ai).

#Usage:

```java
import elevateAi.cient.Client;
import elevateAi.client.Client;

... ...
var cli = Client.newInstance(baseUrl, apiToken);

// 1,2. Declare
// Step 2,3
var it = cli.declare("en-us", "default", "highAccuracy", null, null, false);

// 3. Upload media file
// Step 4
var uploadOk = cli.upload(it, "d:/dev/elevateai-cli/sample-media/media.wav");

// 4. Wait for processing completion
// Step 5
while (true){
var s = cli.status(it);
if("processed".equals(s))
break;
Thread.sleep(60000);
}

var tx = cli.transcripts(it, true);
var ai = cli.aiResults(it);
System.out.println(String.format("Interaction [%s]: \nTranscripts: %s, \nAiResults: %s", it, tx, ai));
Expand Down

0 comments on commit 07db3bc

Please sign in to comment.