Giter Club home page Giter Club logo

free-gpt3.5-2api's Introduction

接口

/v1/chat/completions

支持返回stream和json
http://<ip>:<port>/v1/chat/completions
示例
curl http://127.0.0.1:9846
curl --location --request POST 'http://127.0.0.1:9846/v1/chat/completions' \
--header 'Authorization: Bearer abc' \
--header 'Content-Type: application/json' \
--data-raw '{
    "model": "gpt-3.5-turbo",
    "messages": [
        {
            "role": "user",
            "content": "西红柿炒钢丝球怎么做?"
        }
    ],
    "stream": false
}'

配置

环境变量

LOG_LEVEL=info   # debug, info, warn, error
BIND=0.0.0.0     # 127.0.0.1
PORT=3040
PROXY=			 # http://127.0.0.1:7890
AUTHORIZATIONS=  # abc,bac (英文 , 分隔)
POOL_MAX_COUNT=5 # max number of connections to keep in the pool
AUTH_ED=180      # expiration time for the authorization in seconds
AUTH_USE_COUNT=5 # number of times an authorization can be used
也可使用与程序同目录下 .env 文件配置上述字段

docker部署

1 .创建文件夹
mkdir -p $PWD/free-gpt3.5-2api
2.拉取镜像启动
docker run -itd  --name=free-gpt3.5-2api -p 9846:3040 -v $PWD/free-gpt3.5-2api/logs:/app/logs ghcr.io/aurorax-neo/free-gpt3.5-2api

Koyeb部署

注意:Regions请选择支持openai免登的区域!!!

Deploy to Koyeb

free-gpt3.5-2api's People

Contributors

aurorax-neo avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.