@@ -5,12 +5,16 @@ this is a openai-proxy, using ngixn proxy.
## Develop
```conf
-docker build -t jianboy/aitakegpt:latest .
-docker-compose up -d
+docker compose -f "openai-proxy/docker-compose.debug.yml" up -d --build
```
## Usage
+```
+wget https://git.yoqi.me/lyq/openai-proxy/raw/master/docker-compose.yml
+docker-compose up -d
+
```python
import openai
openai.api_key = api_key
@@ -0,0 +1,18 @@
+@token=sk-sss
+### gpt-3.5-turbo proxy
+POST /v1/chat/completions HTTP/1.1
+Content-Type: application/json
+Authorization: Bearer {{token}}
+Host: ai.takegpt.cn
+{
+ "model": "gpt-3.5-turbo",
+ "messages": [{
+ "role": "user",
+ "content": "宝宝每天咳几声正常吗"
+ }],
+ "stream" : true,
+ "temperature": 0.5
+}
@@ -6,8 +6,8 @@ services:
build:
context: .
dockerfile: ./Dockerfile
- environment:
- JAVA_OPTS: -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005,quiet=y
ports:
- - 3000:3000
- - 5005:5005
+ - 80:80
+ volumes:
+ - ./ai.takegpt.cn.conf:/etc/nginx/conf.d/ai.takegpt.cn.conf
+ restart: unless-stopped