Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Siri + ChatGPT = 贾维斯? #74

Open
woodongwong opened this issue Mar 14, 2023 · 4 comments
Open

Siri + ChatGPT = 贾维斯? #74

woodongwong opened this issue Mar 14, 2023 · 4 comments
Labels

Comments

@woodongwong
Copy link
Owner

output.mp4
@woodongwong
Copy link
Owner Author

视频中是借助【快捷指令】实现的,快捷指令地址:https://www.icloud.com/shortcuts/ab376156b0384382815ae5f553cad8a4

@woodongwong
Copy link
Owner Author

api.openai.com 已经被GFW关照了,我是通过 Cloudflare Workers + Workers Routes 实现的,workers 负责 proxy,由于 workers.dev 也被GFW关照,所以我通过 Workers Routes 映射到 worker,worker 代码非常简单,就几行:

export default {
  async fetch(request) {
    return fetch(new Request(`https://api.openai.com${new URL(request.url).pathname}`, {
      headers: request.headers,
      method: request.method,
      body: request.body
    }));
  },
};

@Tan-JinDa
Copy link

可不可以教教我

@woodongwong
Copy link
Owner Author

可不可以教教我

快捷指令是可以看到如何设置的,官方的API也非常简单 https://platform.openai.com/docs/api-reference/chat

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants