Giter Site home page Giter Site logo

使用咨询 about gpt_api_free HOT 7 CLOSED

chatanywhere avatar chatanywhere commented on June 25, 2024
使用咨询

from gpt_api_free.

Comments (7)

loukai99 avatar loukai99 commented on June 25, 2024 1

简单看了一下 他应该用的也是官方openai库 参照教程改环境变量即可

from gpt_api_free.

chatanywhere avatar chatanywhere commented on June 25, 2024

gpt-academic应该也是用的openai官方库,参照教程改环境变量即可

from gpt_api_free.

nimrod1990 avatar nimrod1990 commented on June 25, 2024

我在 huggingface 中部署,是不是修改 config.py中的以下内容即可?

重新URL重新定向,实现更换API_URL的作用(常规情况下,不要修改!!)

  | # (高危设置!通过修改此设置,您将把您的API-KEY和对话隐私完全暴露给您设定的中间人!)
  | # 格式 {"https://api.openai.com/v1/chat/completions": "在这里填写重定向的api.openai.com的URL"}
  | # 例如 API_URL_REDIRECT = {"https://api.openai.com/v1/chat/completions": "https://ai.open.com/api/conversation"}
  | API_URL_REDIRECT = {"https://api.chatanywhere.cn/v1/chat/completions": "https://api.chatanywhere.cn"}
 我试了一下还是不行,还需要修改什么吗?我是小白……搞不太明白。

from gpt_api_free.

chatanywhere avatar chatanywhere commented on June 25, 2024
API_URL_REDIRECT = {"https://api.openai.com/v1/chat/completions": "https://api.chatanywhere.cn/v1/chat/completions"}

应该是这样吧

from gpt_api_free.

nimrod1990 avatar nimrod1990 commented on June 25, 2024

谢谢你的帮助~

from gpt_api_free.

nimrod1990 avatar nimrod1990 commented on June 25, 2024

可否添加对开源项目ChatPaper的支持?
需要如何在源码中修改反向代理?

from gpt_api_free.

nimrod1990 avatar nimrod1990 commented on June 25, 2024

Set OPENAI_API_BASE environment variable

os.environ["OPENAI_API_BASE"] = "https://api.chatanywhere.cn/v1"

简单看了一下 他应该用的也是官方openai库 参照教程改环境变量即可

from gpt_api_free.

Related Issues (20)

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.