<commit_before># platoai

> Python implementation of the [Plato AI](https://platoai.com/) [API](http://api.platoai.com:3001/graphiql).

## installation

```
pip install platoai
```

## usage

```python
from __future__ import print_function
import datetime
import platoai

metadata = {
    'id': 'callId',
    'timestamp': datetime.datetime.now(),
    'company': {
        'id': 'companyId'
    },
    'agents': [{
        'id': 'agentId',
        'name': 'Agent Name',
        'phoneNumber': 1234567890
    }],
    'customers': [{
        'id': 'customerId',
        'name': '<NAME>',
        'phoneNumber': 9876543210
    }],
    'direction': 'OUTGOING'
}

with open('test.wav', 'rb') as f:
    print(platoai.push(metadata, f))
```
<commit_msg>Rename `id` key to `identifier` in docs<commit_after># platoai

> Python implementation of the [Plato AI](https://platoai.com/) [API](http://api.platoai.com:3001/graphiql).

## installation

```
pip install platoai
```

## usage

```python
from __future__ import print_function
import datetime
import platoai

metadata = {
    'identifier': 'callId',
    'timestamp': datetime.datetime.now(),
    'company': {
        'identifier': 'companyId'
    },
    'agents': [{
        'identifier': 'agentId',
        'name': 'Agent Name',
        'phoneNumber': 1234567890
    }],
    'customers': [{
        'identifier': 'customerId',
        'name': '<NAME>',
        'phoneNumber': 9876543210
    }],
    'direction': 'OUTGOING'
}

with open('test.wav', 'rb') as f:
    print(platoai.push(metadata, f))
```

{'fraction_non_alphanumeric': 0.18087855297157623, 'fraction_numerical': 0.031007751937984496, 'mean_word_length': 3.0656167979002626, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1581383', 'n_tokens_mistral': 569, 'n_tokens_neox': 529, 'n_words': 116}