Skip to content

Commit

Permalink
Introduced audio transcription and speech creation
Browse files Browse the repository at this point in the history
In this revision, we've added new features including audio transcription and speech creation. We've also introduced a web interface for easier interaction. Additionally, there are minor adjustments to the formatting of the README file for better readability.
  • Loading branch information
leokwsw committed Apr 18, 2024
1 parent ac27e06 commit a5422e1
Show file tree
Hide file tree
Showing 8 changed files with 35 additions and 106 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "web"]
path = web
url = [email protected]:leokwsw/chatgpt-web.git
17 changes: 12 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,24 @@

## This is a personal maintenance version. Compared with the original version, there are the following changes and changes based on changes in OpenAI.

### 2024-04-19

- Added audio transcription and speech creation functionality
- Added Web Interface [http://host:8080/web](http://host:8080/web)

### 2024-04-09

- `imitate update`:support no auth conversation
- `POST /imitate/v1/chat/completions` with fixed token by env value named `CUSTOM_FREE_TOKEN`(default is `python`) :
- openai lib not allow no token
- Sample Request [main.py](example%2Fpython%2Fmain.py)
- `POST /imitate/v1/chat/completions` with fixed token by env value named `CUSTOM_FREE_TOKEN`(default is `python`) :
- openai lib not allow no token
- Sample Request [main.py](example%2Fpython%2Fmain.py)

### 2024-04-06

- Update OpenAIAuth and funcaptcha library
- `POST /chatgpt/conversation`, `POST /chatgpt/backend-api/conversation` and `/api/conversation` support no auth conversation
- Sample Request [freeChatgpt.http](example%2FfreeChatgpt.http)
- `POST /chatgpt/conversation`, `POST /chatgpt/backend-api/conversation` and `/api/conversation` support no auth
conversation
- Sample Request [freeChatgpt.http](example%2FfreeChatgpt.http)

### 2024-03-23

Expand Down Expand Up @@ -44,6 +50,7 @@
- [ChatGPTNextWeb/ChatGPT-Next-Web](https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web)

.env

```
OPENAI_API_KEY=<your openai api key>
BASE_URL=http://localhost:8080/platform
Expand Down
8 changes: 4 additions & 4 deletions example/python/dalle.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import os

import openai

PROMPT = "An eco-friendly computer from the 90s in the style of vaporwave"
Expand All @@ -12,5 +10,7 @@
n=1,
size="256x256",
)

print(response.data[0].url)
if hasattr(response, "error"):
print(response.error["message"])
else:
print("url", response.data[0].url)
10 changes: 3 additions & 7 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,15 @@ require (
github.com/bogdanfinn/fhttp v0.5.28
github.com/bogdanfinn/tls-client v1.7.4
github.com/denisbrodbeck/machineid v1.0.1
github.com/gin-contrib/static v1.1.1
github.com/gin-gonic/gin v1.9.1
github.com/google/uuid v1.6.0
github.com/gorilla/websocket v1.5.1
github.com/joho/godotenv v1.5.1
github.com/linweiyuan/go-logger v0.0.0-20230709142852-da1f090a7d4c
github.com/xqdoo00o/OpenAIAuth v0.0.0-20240403091529-7ef147706fc4
github.com/xqdoo00o/funcaptcha v0.0.0-20240403090732-1b604d808f6c
go.mongodb.org/mongo-driver v1.14.0
)

require (
Expand All @@ -24,8 +26,6 @@ require (
github.com/bogdanfinn/utls v1.6.1 // indirect
github.com/bytedance/sonic v1.11.5 // indirect
github.com/bytedance/sonic/loader v0.1.1 // indirect
github.com/chenzhuoyu/base64x v0.0.0-20230717121745-296ad89f973d // indirect
github.com/chenzhuoyu/iasm v0.9.1 // indirect
github.com/cloudflare/circl v1.3.7 // indirect
github.com/cloudwego/base64x v0.1.3 // indirect
github.com/cloudwego/iasm v0.2.0 // indirect
Expand All @@ -41,12 +41,12 @@ require (
github.com/json-iterator/go v1.1.12 // indirect
github.com/klauspost/compress v1.17.8 // indirect
github.com/klauspost/cpuid/v2 v2.2.7 // indirect
github.com/kr/text v0.1.0 // indirect
github.com/leodido/go-urn v1.4.0 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/montanaflynn/stats v0.7.1 // indirect
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e // indirect
github.com/onsi/ginkgo/v2 v2.15.0 // indirect
github.com/onsi/gomega v1.30.0 // indirect
github.com/pelletier/go-toml/v2 v2.2.1 // indirect
Expand All @@ -55,21 +55,17 @@ require (
github.com/tam7t/hpkp v0.0.0-20160821193359-2b70b4024ed5 // indirect
github.com/twitchyliquid64/golang-asm v0.15.1 // indirect
github.com/ugorji/go/codec v1.2.12 // indirect
github.com/unrolled/secure v1.14.0 // indirect
github.com/xdg-go/pbkdf2 v1.0.0 // indirect
github.com/xdg-go/scram v1.1.2 // indirect
github.com/xdg-go/stringprep v1.0.4 // indirect
github.com/youmark/pkcs8 v0.0.0-20201027041543-1326539a0a0a // indirect
go.mongodb.org/mongo-driver v1.14.0 // indirect
golang.org/x/arch v0.7.0 // indirect
golang.org/x/crypto v0.22.0 // indirect
golang.org/x/exp v0.0.0-20240416160154-fe59bbe5cc7f // indirect
golang.org/x/net v0.24.0 // indirect
golang.org/x/sync v0.7.0 // indirect
golang.org/x/sys v0.19.0 // indirect
golang.org/x/text v0.14.0 // indirect
golang.org/x/tools v0.20.0 // indirect
google.golang.org/protobuf v1.33.0 // indirect
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
Loading

0 comments on commit a5422e1

Please sign in to comment.