speechcortex-sdk 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- speechcortex_sdk-0.1.0/LICENSE +21 -0
- speechcortex_sdk-0.1.0/MANIFEST.in +8 -0
- speechcortex_sdk-0.1.0/PKG-INFO +218 -0
- speechcortex_sdk-0.1.0/README.md +183 -0
- speechcortex_sdk-0.1.0/pyproject.toml +102 -0
- speechcortex_sdk-0.1.0/requirements-dev.txt +10 -0
- speechcortex_sdk-0.1.0/requirements.txt +8 -0
- speechcortex_sdk-0.1.0/setup.cfg +4 -0
- speechcortex_sdk-0.1.0/setup.py +52 -0
- speechcortex_sdk-0.1.0/speechcortex/__init__.py +124 -0
- speechcortex_sdk-0.1.0/speechcortex/audio/__init__.py +12 -0
- speechcortex_sdk-0.1.0/speechcortex/audio/microphone/__init__.py +7 -0
- speechcortex_sdk-0.1.0/speechcortex/audio/microphone/constants.py +11 -0
- speechcortex_sdk-0.1.0/speechcortex/audio/microphone/errors.py +21 -0
- speechcortex_sdk-0.1.0/speechcortex/audio/microphone/microphone.py +289 -0
- speechcortex_sdk-0.1.0/speechcortex/client.py +113 -0
- speechcortex_sdk-0.1.0/speechcortex/clients/__init__.py +21 -0
- speechcortex_sdk-0.1.0/speechcortex/clients/transcribe/__init__.py +39 -0
- speechcortex_sdk-0.1.0/speechcortex/clients/transcribe/enums.py +20 -0
- speechcortex_sdk-0.1.0/speechcortex/clients/transcribe/realtime/__init__.py +36 -0
- speechcortex_sdk-0.1.0/speechcortex/clients/transcribe/realtime/client.py +310 -0
- speechcortex_sdk-0.1.0/speechcortex/clients/transcribe/realtime/options.py +78 -0
- speechcortex_sdk-0.1.0/speechcortex/clients/transcribe/realtime/response.py +130 -0
- speechcortex_sdk-0.1.0/speechcortex/errors.py +188 -0
- speechcortex_sdk-0.1.0/speechcortex/options.py +181 -0
- speechcortex_sdk-0.1.0/speechcortex/utils/__init__.py +19 -0
- speechcortex_sdk-0.1.0/speechcortex/utils/verboselogs/__init__.py +83 -0
- speechcortex_sdk-0.1.0/speechcortex_sdk.egg-info/PKG-INFO +218 -0
- speechcortex_sdk-0.1.0/speechcortex_sdk.egg-info/SOURCES.txt +30 -0
- speechcortex_sdk-0.1.0/speechcortex_sdk.egg-info/dependency_links.txt +1 -0
- speechcortex_sdk-0.1.0/speechcortex_sdk.egg-info/requires.txt +8 -0
- speechcortex_sdk-0.1.0/speechcortex_sdk.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 Zeus
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,218 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: speechcortex-sdk
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: The official Python SDK for SpeechCortex ASR platform.
|
|
5
|
+
Home-page: https://github.com/skanda-observeai/zeus-sdk-py
|
|
6
|
+
Author: SpeechCortex Team
|
|
7
|
+
Author-email: SpeechCortex Team <team@speechcortex.com>
|
|
8
|
+
License: MIT
|
|
9
|
+
Project-URL: Homepage, https://github.com/skanda-observeai/zeus-sdk-py
|
|
10
|
+
Project-URL: Bug Tracker, https://github.com/skanda-observeai/zeus-sdk-py/issues
|
|
11
|
+
Project-URL: Source Code, https://github.com/skanda-observeai/zeus-sdk-py
|
|
12
|
+
Project-URL: Documentation, https://github.com/skanda-observeai/zeus-sdk-py#readme
|
|
13
|
+
Keywords: speechcortex,asr,speech-to-text,speech recognition
|
|
14
|
+
Classifier: Intended Audience :: Developers
|
|
15
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
16
|
+
Classifier: Programming Language :: Python :: 3
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
20
|
+
Requires-Python: >=3.10
|
|
21
|
+
Description-Content-Type: text/markdown
|
|
22
|
+
License-File: LICENSE
|
|
23
|
+
Requires-Dist: httpx>=0.25.2
|
|
24
|
+
Requires-Dist: websockets>=12.0
|
|
25
|
+
Requires-Dist: dataclasses-json>=0.6.3
|
|
26
|
+
Requires-Dist: typing-extensions>=4.9.0
|
|
27
|
+
Requires-Dist: aiohttp>=3.9.1
|
|
28
|
+
Requires-Dist: aiofiles>=23.2.1
|
|
29
|
+
Requires-Dist: aenum>=3.1.0
|
|
30
|
+
Requires-Dist: deprecation>=2.1.0
|
|
31
|
+
Dynamic: author
|
|
32
|
+
Dynamic: home-page
|
|
33
|
+
Dynamic: license-file
|
|
34
|
+
Dynamic: requires-python
|
|
35
|
+
|
|
36
|
+
# SpeechCortex Python SDK
|
|
37
|
+
|
|
38
|
+
[](https://github.com/skanda-observeai/zeus-sdk-py/actions/workflows/ci.yml)
|
|
39
|
+
[](https://badge.fury.io/py/speechcortex-sdk)
|
|
40
|
+
[](https://pypi.org/project/speechcortex-sdk/)
|
|
41
|
+
[](https://opensource.org/licenses/MIT)
|
|
42
|
+
[](https://github.com/psf/black)
|
|
43
|
+
|
|
44
|
+
Official Python SDK for SpeechCortex ASR (Automatic Speech Recognition) platform.
|
|
45
|
+
|
|
46
|
+
## Features
|
|
47
|
+
|
|
48
|
+
- **Real-time Speech Recognition**: WebSocket-based streaming ASR
|
|
49
|
+
- **Pre-recorded Transcription**: REST API for batch processing (coming soon)
|
|
50
|
+
- **Easy Integration**: Simple, intuitive API
|
|
51
|
+
- **Async Support**: Full async/await support for modern Python applications
|
|
52
|
+
|
|
53
|
+
## Requirements
|
|
54
|
+
|
|
55
|
+
- Python 3.10 or higher
|
|
56
|
+
|
|
57
|
+
## Installation
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
pip install "git+https://github.com/skanda-observeai/zeus-sdk-py.git@package_init"
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
export SPEECHCORTEX_API_KEY=your_api_key_here
|
|
65
|
+
export SPEECHCORTEX_HOST=wss://api.speechcortex.com
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## Quick Start
|
|
69
|
+
|
|
70
|
+
### Real-time Transcription
|
|
71
|
+
|
|
72
|
+
```python
|
|
73
|
+
from speechcortex import SpeechCortexClient, LiveTranscriptionEvents, LiveOptions
|
|
74
|
+
|
|
75
|
+
# Initialize the client
|
|
76
|
+
speechcortex = SpeechCortexClient(api_key="your_api_key_here")
|
|
77
|
+
|
|
78
|
+
# Get WebSocket connection
|
|
79
|
+
connection = speechcortex.listen.websocket.v("1")
|
|
80
|
+
|
|
81
|
+
# Set up event handlers
|
|
82
|
+
def on_message(self, result, **kwargs):
|
|
83
|
+
sentence = result.channel.alternatives[0].transcript
|
|
84
|
+
if result.is_final:
|
|
85
|
+
print(f"Final: {sentence}")
|
|
86
|
+
else:
|
|
87
|
+
print(f"Interim: {sentence}")
|
|
88
|
+
|
|
89
|
+
def on_error(self, error, **kwargs):
|
|
90
|
+
print(f"Error: {error}")
|
|
91
|
+
|
|
92
|
+
# Register event handlers
|
|
93
|
+
connection.on(LiveTranscriptionEvents.Transcript, on_message)
|
|
94
|
+
connection.on(LiveTranscriptionEvents.Error, on_error)
|
|
95
|
+
|
|
96
|
+
# Configure options
|
|
97
|
+
options = LiveOptions(
|
|
98
|
+
model="zeus-v1",
|
|
99
|
+
language="en-US",
|
|
100
|
+
smart_format=True,
|
|
101
|
+
)
|
|
102
|
+
|
|
103
|
+
# Start the connection
|
|
104
|
+
connection.start(options)
|
|
105
|
+
|
|
106
|
+
# Send audio data
|
|
107
|
+
connection.send(audio_data)
|
|
108
|
+
|
|
109
|
+
# Close when done
|
|
110
|
+
connection.finish()
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
### Using with Microphone
|
|
114
|
+
|
|
115
|
+
```python
|
|
116
|
+
from speechcortex import SpeechCortexClient, LiveTranscriptionEvents, LiveOptions, Microphone
|
|
117
|
+
|
|
118
|
+
speechcortex = SpeechCortexClient()
|
|
119
|
+
connection = speechcortex.listen.websocket.v("1")
|
|
120
|
+
|
|
121
|
+
# Set up event handlers...
|
|
122
|
+
connection.on(LiveTranscriptionEvents.Transcript, on_message)
|
|
123
|
+
|
|
124
|
+
# Start connection
|
|
125
|
+
options = LiveOptions(model="zeus-v1", smart_format=True)
|
|
126
|
+
connection.start(options)
|
|
127
|
+
|
|
128
|
+
# Use microphone helper
|
|
129
|
+
microphone = Microphone(connection.send)
|
|
130
|
+
microphone.start()
|
|
131
|
+
|
|
132
|
+
# Microphone will stream audio automatically
|
|
133
|
+
# Press Ctrl+C to stop
|
|
134
|
+
|
|
135
|
+
microphone.finish()
|
|
136
|
+
connection.finish()
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
## Configuration
|
|
140
|
+
|
|
141
|
+
### API Key
|
|
142
|
+
|
|
143
|
+
Set your API key via environment variable:
|
|
144
|
+
|
|
145
|
+
```bash
|
|
146
|
+
export SPEECHCORTEX_API_KEY=your_api_key_here
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
Or pass it directly:
|
|
150
|
+
|
|
151
|
+
```python
|
|
152
|
+
speechcortex = SpeechCortexClient(api_key="your_api_key_here")
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
### Custom Endpoints
|
|
156
|
+
|
|
157
|
+
```python
|
|
158
|
+
from speechcortex import SpeechCortexClient, SpeechCortexClientOptions
|
|
159
|
+
|
|
160
|
+
config = SpeechCortexClientOptions(
|
|
161
|
+
api_key="your_api_key",
|
|
162
|
+
url="https://custom-api.speechcortex.com"
|
|
163
|
+
)
|
|
164
|
+
speechcortex = SpeechCortexClient(config=config)
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
## Features
|
|
168
|
+
|
|
169
|
+
### Real-time Transcription Options
|
|
170
|
+
|
|
171
|
+
- `model`: ASR model to use (e.g., "zeus-v1")
|
|
172
|
+
- `language`: Language code (e.g., "en-US")
|
|
173
|
+
- `smart_format`: Enable smart formatting
|
|
174
|
+
- `punctuate`: Enable punctuation
|
|
175
|
+
- `interim_results`: Receive interim results
|
|
176
|
+
- `utterance_end_ms`: Utterance end timeout in milliseconds
|
|
177
|
+
- `vad_events`: Enable voice activity detection events
|
|
178
|
+
|
|
179
|
+
### Events
|
|
180
|
+
|
|
181
|
+
- `Open`: Connection opened
|
|
182
|
+
- `Transcript`: Transcription result received
|
|
183
|
+
- `Metadata`: Metadata received
|
|
184
|
+
- `SpeechStarted`: Speech detected
|
|
185
|
+
- `UtteranceEnd`: End of utterance detected
|
|
186
|
+
- `Close`: Connection closed
|
|
187
|
+
- `Error`: Error occurred
|
|
188
|
+
- `Unhandled`: Unhandled message received
|
|
189
|
+
|
|
190
|
+
## Development
|
|
191
|
+
|
|
192
|
+
### Setup Development Environment
|
|
193
|
+
|
|
194
|
+
```bash
|
|
195
|
+
# Clone the repository
|
|
196
|
+
git clone https://github.com/speechcortex/speechcortex-sdk.git
|
|
197
|
+
cd speechcortex-sdk
|
|
198
|
+
|
|
199
|
+
# Install dependencies
|
|
200
|
+
pip install -r requirements-dev.txt
|
|
201
|
+
|
|
202
|
+
# Run tests
|
|
203
|
+
pytest
|
|
204
|
+
|
|
205
|
+
# Run linting
|
|
206
|
+
pylint speechcortex/
|
|
207
|
+
|
|
208
|
+
# Format code
|
|
209
|
+
black speechcortex/
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
## License
|
|
213
|
+
|
|
214
|
+
MIT License - see [LICENSE](LICENSE) file for details.
|
|
215
|
+
|
|
216
|
+
## Support
|
|
217
|
+
|
|
218
|
+
For issues, questions, or contributions, please visit our [GitHub repository](https://github.com/speechcortex/speechcortex-sdk).
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
# SpeechCortex Python SDK
|
|
2
|
+
|
|
3
|
+
[](https://github.com/skanda-observeai/zeus-sdk-py/actions/workflows/ci.yml)
|
|
4
|
+
[](https://badge.fury.io/py/speechcortex-sdk)
|
|
5
|
+
[](https://pypi.org/project/speechcortex-sdk/)
|
|
6
|
+
[](https://opensource.org/licenses/MIT)
|
|
7
|
+
[](https://github.com/psf/black)
|
|
8
|
+
|
|
9
|
+
Official Python SDK for SpeechCortex ASR (Automatic Speech Recognition) platform.
|
|
10
|
+
|
|
11
|
+
## Features
|
|
12
|
+
|
|
13
|
+
- **Real-time Speech Recognition**: WebSocket-based streaming ASR
|
|
14
|
+
- **Pre-recorded Transcription**: REST API for batch processing (coming soon)
|
|
15
|
+
- **Easy Integration**: Simple, intuitive API
|
|
16
|
+
- **Async Support**: Full async/await support for modern Python applications
|
|
17
|
+
|
|
18
|
+
## Requirements
|
|
19
|
+
|
|
20
|
+
- Python 3.10 or higher
|
|
21
|
+
|
|
22
|
+
## Installation
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
pip install "git+https://github.com/skanda-observeai/zeus-sdk-py.git@package_init"
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
export SPEECHCORTEX_API_KEY=your_api_key_here
|
|
30
|
+
export SPEECHCORTEX_HOST=wss://api.speechcortex.com
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Quick Start
|
|
34
|
+
|
|
35
|
+
### Real-time Transcription
|
|
36
|
+
|
|
37
|
+
```python
|
|
38
|
+
from speechcortex import SpeechCortexClient, LiveTranscriptionEvents, LiveOptions
|
|
39
|
+
|
|
40
|
+
# Initialize the client
|
|
41
|
+
speechcortex = SpeechCortexClient(api_key="your_api_key_here")
|
|
42
|
+
|
|
43
|
+
# Get WebSocket connection
|
|
44
|
+
connection = speechcortex.listen.websocket.v("1")
|
|
45
|
+
|
|
46
|
+
# Set up event handlers
|
|
47
|
+
def on_message(self, result, **kwargs):
|
|
48
|
+
sentence = result.channel.alternatives[0].transcript
|
|
49
|
+
if result.is_final:
|
|
50
|
+
print(f"Final: {sentence}")
|
|
51
|
+
else:
|
|
52
|
+
print(f"Interim: {sentence}")
|
|
53
|
+
|
|
54
|
+
def on_error(self, error, **kwargs):
|
|
55
|
+
print(f"Error: {error}")
|
|
56
|
+
|
|
57
|
+
# Register event handlers
|
|
58
|
+
connection.on(LiveTranscriptionEvents.Transcript, on_message)
|
|
59
|
+
connection.on(LiveTranscriptionEvents.Error, on_error)
|
|
60
|
+
|
|
61
|
+
# Configure options
|
|
62
|
+
options = LiveOptions(
|
|
63
|
+
model="zeus-v1",
|
|
64
|
+
language="en-US",
|
|
65
|
+
smart_format=True,
|
|
66
|
+
)
|
|
67
|
+
|
|
68
|
+
# Start the connection
|
|
69
|
+
connection.start(options)
|
|
70
|
+
|
|
71
|
+
# Send audio data
|
|
72
|
+
connection.send(audio_data)
|
|
73
|
+
|
|
74
|
+
# Close when done
|
|
75
|
+
connection.finish()
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
### Using with Microphone
|
|
79
|
+
|
|
80
|
+
```python
|
|
81
|
+
from speechcortex import SpeechCortexClient, LiveTranscriptionEvents, LiveOptions, Microphone
|
|
82
|
+
|
|
83
|
+
speechcortex = SpeechCortexClient()
|
|
84
|
+
connection = speechcortex.listen.websocket.v("1")
|
|
85
|
+
|
|
86
|
+
# Set up event handlers...
|
|
87
|
+
connection.on(LiveTranscriptionEvents.Transcript, on_message)
|
|
88
|
+
|
|
89
|
+
# Start connection
|
|
90
|
+
options = LiveOptions(model="zeus-v1", smart_format=True)
|
|
91
|
+
connection.start(options)
|
|
92
|
+
|
|
93
|
+
# Use microphone helper
|
|
94
|
+
microphone = Microphone(connection.send)
|
|
95
|
+
microphone.start()
|
|
96
|
+
|
|
97
|
+
# Microphone will stream audio automatically
|
|
98
|
+
# Press Ctrl+C to stop
|
|
99
|
+
|
|
100
|
+
microphone.finish()
|
|
101
|
+
connection.finish()
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
## Configuration
|
|
105
|
+
|
|
106
|
+
### API Key
|
|
107
|
+
|
|
108
|
+
Set your API key via environment variable:
|
|
109
|
+
|
|
110
|
+
```bash
|
|
111
|
+
export SPEECHCORTEX_API_KEY=your_api_key_here
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
Or pass it directly:
|
|
115
|
+
|
|
116
|
+
```python
|
|
117
|
+
speechcortex = SpeechCortexClient(api_key="your_api_key_here")
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
### Custom Endpoints
|
|
121
|
+
|
|
122
|
+
```python
|
|
123
|
+
from speechcortex import SpeechCortexClient, SpeechCortexClientOptions
|
|
124
|
+
|
|
125
|
+
config = SpeechCortexClientOptions(
|
|
126
|
+
api_key="your_api_key",
|
|
127
|
+
url="https://custom-api.speechcortex.com"
|
|
128
|
+
)
|
|
129
|
+
speechcortex = SpeechCortexClient(config=config)
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
## Features
|
|
133
|
+
|
|
134
|
+
### Real-time Transcription Options
|
|
135
|
+
|
|
136
|
+
- `model`: ASR model to use (e.g., "zeus-v1")
|
|
137
|
+
- `language`: Language code (e.g., "en-US")
|
|
138
|
+
- `smart_format`: Enable smart formatting
|
|
139
|
+
- `punctuate`: Enable punctuation
|
|
140
|
+
- `interim_results`: Receive interim results
|
|
141
|
+
- `utterance_end_ms`: Utterance end timeout in milliseconds
|
|
142
|
+
- `vad_events`: Enable voice activity detection events
|
|
143
|
+
|
|
144
|
+
### Events
|
|
145
|
+
|
|
146
|
+
- `Open`: Connection opened
|
|
147
|
+
- `Transcript`: Transcription result received
|
|
148
|
+
- `Metadata`: Metadata received
|
|
149
|
+
- `SpeechStarted`: Speech detected
|
|
150
|
+
- `UtteranceEnd`: End of utterance detected
|
|
151
|
+
- `Close`: Connection closed
|
|
152
|
+
- `Error`: Error occurred
|
|
153
|
+
- `Unhandled`: Unhandled message received
|
|
154
|
+
|
|
155
|
+
## Development
|
|
156
|
+
|
|
157
|
+
### Setup Development Environment
|
|
158
|
+
|
|
159
|
+
```bash
|
|
160
|
+
# Clone the repository
|
|
161
|
+
git clone https://github.com/speechcortex/speechcortex-sdk.git
|
|
162
|
+
cd speechcortex-sdk
|
|
163
|
+
|
|
164
|
+
# Install dependencies
|
|
165
|
+
pip install -r requirements-dev.txt
|
|
166
|
+
|
|
167
|
+
# Run tests
|
|
168
|
+
pytest
|
|
169
|
+
|
|
170
|
+
# Run linting
|
|
171
|
+
pylint speechcortex/
|
|
172
|
+
|
|
173
|
+
# Format code
|
|
174
|
+
black speechcortex/
|
|
175
|
+
```
|
|
176
|
+
|
|
177
|
+
## License
|
|
178
|
+
|
|
179
|
+
MIT License - see [LICENSE](LICENSE) file for details.
|
|
180
|
+
|
|
181
|
+
## Support
|
|
182
|
+
|
|
183
|
+
For issues, questions, or contributions, please visit our [GitHub repository](https://github.com/speechcortex/speechcortex-sdk).
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
######
|
|
2
|
+
# general configuration
|
|
3
|
+
######
|
|
4
|
+
[build-system]
|
|
5
|
+
requires = ["setuptools>=61.0", "wheel"]
|
|
6
|
+
build-backend = "setuptools.build_meta"
|
|
7
|
+
|
|
8
|
+
[project]
|
|
9
|
+
name = "speechcortex-sdk"
|
|
10
|
+
version = "0.1.0"
|
|
11
|
+
description = "The official Python SDK for SpeechCortex ASR platform."
|
|
12
|
+
readme = "README.md"
|
|
13
|
+
requires-python = ">=3.10"
|
|
14
|
+
license = {text = "MIT"}
|
|
15
|
+
authors = [
|
|
16
|
+
{name = "SpeechCortex Team", email = "team@speechcortex.com"}
|
|
17
|
+
]
|
|
18
|
+
keywords = ["speechcortex", "asr", "speech-to-text", "speech recognition"]
|
|
19
|
+
classifiers = [
|
|
20
|
+
"Intended Audience :: Developers",
|
|
21
|
+
"License :: OSI Approved :: MIT License",
|
|
22
|
+
"Programming Language :: Python :: 3",
|
|
23
|
+
"Programming Language :: Python :: 3.10",
|
|
24
|
+
"Programming Language :: Python :: 3.11",
|
|
25
|
+
"Programming Language :: Python :: 3.12",
|
|
26
|
+
]
|
|
27
|
+
dependencies = [
|
|
28
|
+
"httpx>=0.25.2",
|
|
29
|
+
"websockets>=12.0",
|
|
30
|
+
"dataclasses-json>=0.6.3",
|
|
31
|
+
"typing-extensions>=4.9.0",
|
|
32
|
+
"aiohttp>=3.9.1",
|
|
33
|
+
"aiofiles>=23.2.1",
|
|
34
|
+
"aenum>=3.1.0",
|
|
35
|
+
"deprecation>=2.1.0",
|
|
36
|
+
]
|
|
37
|
+
|
|
38
|
+
[project.urls]
|
|
39
|
+
"Homepage" = "https://github.com/skanda-observeai/zeus-sdk-py"
|
|
40
|
+
"Bug Tracker" = "https://github.com/skanda-observeai/zeus-sdk-py/issues"
|
|
41
|
+
"Source Code" = "https://github.com/skanda-observeai/zeus-sdk-py"
|
|
42
|
+
"Documentation" = "https://github.com/skanda-observeai/zeus-sdk-py#readme"
|
|
43
|
+
|
|
44
|
+
######
|
|
45
|
+
# poetry configuration (optional)
|
|
46
|
+
######
|
|
47
|
+
[tool.poetry]
|
|
48
|
+
name = "speechcortex-sdk"
|
|
49
|
+
version = "0.1.0"
|
|
50
|
+
description = "The official Python SDK for SpeechCortex ASR platform."
|
|
51
|
+
authors = ["SpeechCortex Team <team@speechcortex.com>"]
|
|
52
|
+
license = "MIT"
|
|
53
|
+
readme = "README.md"
|
|
54
|
+
|
|
55
|
+
[tool.poetry.dependencies]
|
|
56
|
+
python = "^3.10"
|
|
57
|
+
httpx = "^0.25.2"
|
|
58
|
+
websockets = ">=12.0"
|
|
59
|
+
typing-extensions = "^4.9.0"
|
|
60
|
+
dataclasses-json = "^0.6.3"
|
|
61
|
+
aiohttp = "^3.9.1"
|
|
62
|
+
aiofiles = "^23.2.1"
|
|
63
|
+
aenum = "^3.1.0"
|
|
64
|
+
deprecation = "^2.1.0"
|
|
65
|
+
|
|
66
|
+
[tool.poetry.group.dev.dependencies]
|
|
67
|
+
black = "^24.0"
|
|
68
|
+
pylint = "^3.0"
|
|
69
|
+
mypy = "^1.0"
|
|
70
|
+
pytest = "^7.4.3"
|
|
71
|
+
pytest-asyncio = "^0.21.1"
|
|
72
|
+
pytest-cov = "^4.1.0"
|
|
73
|
+
types-aiofiles = "^23.2.0"
|
|
74
|
+
|
|
75
|
+
######
|
|
76
|
+
# black configuration
|
|
77
|
+
######
|
|
78
|
+
[tool.black]
|
|
79
|
+
line-length = 88
|
|
80
|
+
target-version = ['py310']
|
|
81
|
+
include = '\.pyi?$'
|
|
82
|
+
|
|
83
|
+
######
|
|
84
|
+
# mypy configuration
|
|
85
|
+
######
|
|
86
|
+
[tool.mypy]
|
|
87
|
+
python_version = "3.10"
|
|
88
|
+
warn_return_any = true
|
|
89
|
+
warn_unused_configs = true
|
|
90
|
+
disallow_untyped_defs = false
|
|
91
|
+
ignore_missing_imports = true
|
|
92
|
+
|
|
93
|
+
######
|
|
94
|
+
# pytest configuration
|
|
95
|
+
######
|
|
96
|
+
[tool.pytest.ini_options]
|
|
97
|
+
minversion = "7.0"
|
|
98
|
+
asyncio_mode = "auto"
|
|
99
|
+
testpaths = ["tests"]
|
|
100
|
+
python_files = ["test_*.py", "*_test.py"]
|
|
101
|
+
python_classes = ["Test*"]
|
|
102
|
+
python_functions = ["test_*"]
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# Copyright 2024 SpeechCortex SDK contributors. All Rights Reserved.
|
|
2
|
+
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
|
|
3
|
+
# SPDX-License-Identifier: MIT
|
|
4
|
+
|
|
5
|
+
from setuptools import setup, find_packages
|
|
6
|
+
import sys
|
|
7
|
+
|
|
8
|
+
if sys.version_info < (3, 10):
|
|
9
|
+
sys.exit("Sorry, Python < 3.10 is not supported")
|
|
10
|
+
|
|
11
|
+
with open("README.md", "r", encoding="utf-8") as fh:
|
|
12
|
+
LONG_DESCRIPTION = fh.read()
|
|
13
|
+
|
|
14
|
+
DESCRIPTION = "The official Python SDK for SpeechCortex ASR platform."
|
|
15
|
+
|
|
16
|
+
setup(
|
|
17
|
+
name="speechcortex-sdk",
|
|
18
|
+
version="0.1.0",
|
|
19
|
+
author="SpeechCortex Team",
|
|
20
|
+
author_email="team@speechcortex.com",
|
|
21
|
+
url="https://github.com/skanda-observeai/zeus-sdk-py",
|
|
22
|
+
project_urls={
|
|
23
|
+
"Bug Tracker": "https://github.com/skanda-observeai/zeus-sdk-py/issues",
|
|
24
|
+
"Source Code": "https://github.com/skanda-observeai/zeus-sdk-py",
|
|
25
|
+
"Documentation": "https://github.com/skanda-observeai/zeus-sdk-py#readme",
|
|
26
|
+
},
|
|
27
|
+
description=DESCRIPTION,
|
|
28
|
+
long_description=LONG_DESCRIPTION,
|
|
29
|
+
long_description_content_type="text/markdown",
|
|
30
|
+
license="MIT",
|
|
31
|
+
packages=find_packages(exclude=["tests", "examples"]),
|
|
32
|
+
install_requires=[
|
|
33
|
+
"httpx>=0.25.2",
|
|
34
|
+
"websockets>=12.0",
|
|
35
|
+
"dataclasses-json>=0.6.3",
|
|
36
|
+
"typing_extensions>=4.9.0",
|
|
37
|
+
"aiohttp>=3.9.1",
|
|
38
|
+
"aiofiles>=23.2.1",
|
|
39
|
+
"aenum>=3.1.0",
|
|
40
|
+
"deprecation>=2.1.0",
|
|
41
|
+
],
|
|
42
|
+
keywords=["speechcortex", "asr", "speech-to-text", "speech recognition"],
|
|
43
|
+
classifiers=[
|
|
44
|
+
"Intended Audience :: Developers",
|
|
45
|
+
"License :: OSI Approved :: MIT License",
|
|
46
|
+
"Programming Language :: Python :: 3",
|
|
47
|
+
"Programming Language :: Python :: 3.10",
|
|
48
|
+
"Programming Language :: Python :: 3.11",
|
|
49
|
+
"Programming Language :: Python :: 3.12",
|
|
50
|
+
],
|
|
51
|
+
python_requires=">=3.10",
|
|
52
|
+
)
|