yym68686 commited on
Commit
deb4a88
·
1 Parent(s): 5fc94c0

✨ Feature: Add support for vercel deployment

Browse files
Files changed (4) hide show
  1. .gitignore +1 -0
  2. README.md +4 -0
  3. README_CN.md +4 -0
  4. vercel.json +14 -0
.gitignore CHANGED
@@ -8,6 +8,7 @@ node_modules
8
  .pytest_cache
9
  *.jpg
10
  *.json
 
11
  *.png
12
  *.db
13
  .aider*
 
8
  .pytest_cache
9
  *.jpg
10
  *.json
11
+ !vercel.json
12
  *.png
13
  *.db
14
  .aider*
README.md CHANGED
@@ -187,6 +187,10 @@ The `hours` parameter in `/stats?hours=48` allows you to control how many hours
187
 
188
  There are other statistical data that you can query yourself by writing SQL in the database. Other data includes: first token time, total processing time for each request, whether each request was successful, whether each request passed content moderation, the text content of each request, the API key for each request, the number of input tokens, and the number of output tokens for each request.
189
 
 
 
 
 
190
  ## Docker local deployment
191
 
192
  Start the container
 
187
 
188
  There are other statistical data that you can query yourself by writing SQL in the database. Other data includes: first token time, total processing time for each request, whether each request was successful, whether each request passed content moderation, the text content of each request, the API key for each request, the number of input tokens, and the number of output tokens for each request.
189
 
190
+ ## Vercel Deployment
191
+
192
+ [![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fyym68686%2Funi-api%2Ftree%2Fmain&project-name=uni-api-vercel&repository-name=uni-api-vercel)
193
+
194
  ## Docker local deployment
195
 
196
  Start the container
README_CN.md CHANGED
@@ -187,6 +187,10 @@ yym68686/uni-api:latest
187
 
188
  还有其他统计数据,可以自己写sql在数据库自己查。其他数据包括:首字时间,每个请求的总处理时间,每次请求是否成功,每次请求是否符合道德审查,每次请求的文本内容,每次请求的 API key,每次请求的输入 token,输出 token 数量。
189
 
 
 
 
 
190
  ## Docker 本地部署
191
 
192
  Start the container
 
187
 
188
  还有其他统计数据,可以自己写sql在数据库自己查。其他数据包括:首字时间,每个请求的总处理时间,每次请求是否成功,每次请求是否符合道德审查,每次请求的文本内容,每次请求的 API key,每次请求的输入 token,输出 token 数量。
189
 
190
+ ## Vercel 部署
191
+
192
+ [![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fyym68686%2Funi-api%2Ftree%2Fmain&project-name=uni-api-vercel&repository-name=uni-api-vercel)
193
+
194
  ## Docker 本地部署
195
 
196
  Start the container
vercel.json ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "builds": [
3
+ {
4
+ "src": "main.py",
5
+ "use": "@vercel/python"
6
+ }
7
+ ],
8
+ "routes": [
9
+ {
10
+ "src": "/(.*)",
11
+ "dest": "main.py"
12
+ }
13
+ ]
14
+ }