Skip to content

Commit 65c90f3

Browse files
committed
Added a README.md and a LICENSE file
1 parent 4fb2841 commit 65c90f3

File tree

3 files changed

+66
-0
lines changed

3 files changed

+66
-0
lines changed

text_to_speech/LICENSE

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SPDX-License-Identifier: MIT
2+
3+
MIT License
4+
5+
Copyright (c) 2024 Ouko Okowa
6+
7+
Permission Notice
8+
9+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software under the following conditions:
10+
11+
Conditions
12+
13+
1. Attribution: Any distribution of the Software or derivative works must include the original copyright notice and this permission notice, giving appropriate credit to the original authors and contributors.
14+
15+
2. Non-Commercial Use: The Software may not be used for commercial purposes without prior written permission from the copyright holder.
16+
17+
3. Modification: If you modify the Software and distribute it, you must clearly state that the Software has been modified and provide a description of the changes made.
18+
19+
4. No Warranty: The Software is provided "as is," without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose, and non-infringement. In no event shall the authors or copyright holders be liable for any claim, damages, or other liability arising from the use of the Software.

text_to_speech/README.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# FreeTextToSpeechApp Documentation
2+
## version: 1.0.0
3+
4+
## Overview
5+
In this project I demonstrate the use of Django Rest Framework to build an application API and how to seamlessly connect it to the frontend for amazing User Interface(UI). Included, is an integration of Google's Text-to-speech (gTTS) engine that leverages on AI to help convert texts to audio.
6+
7+
## Authentication
8+
No authentication is set in this early version. The app allows you to write text and output it immediately as an audio output without needing to access the database.
9+
10+
## Endpoints Overview
11+
12+
### TextToSpeechView
13+
- **URL**: `/api/`
14+
- **Method**: `POST`
15+
- **Description**: Enter text using the form provided and submit it for real-time processing
16+
- **Request Body**:
17+
```json
18+
{
19+
20+
"text": "sample text",
21+
22+
}
23+
```
24+
- **Response**: Returns a an audio file containing the converted text.
25+
26+
27+
## Example Usage
28+
### Convert TextToSpeech from your terminal
29+
```bash
30+
curl -X POST http://localhost:8000/api/ \
31+
-H "Content-Type: application/json" \
32+
-d '{
33+
"text": "Hello, this is a test for text-to-speech conversion.",
34+
"rate": 1.0,
35+
"volume": 1.0,
36+
"lang": "en"
37+
}' \
38+
--output output.mp3
39+
40+
```
41+
42+
## Error Codes
43+
- **400**: Bad Request — The request could not be understood or was missing required parameters.
44+
45+
46+
## License
47+
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

text_to_speech/package.json

Whitespace-only changes.

0 commit comments

Comments
 (0)