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

[Request] 请求添加对Fine-tuning模型调用支持 #188

Closed
leeyiding opened this issue Sep 12, 2023 · 6 comments · Fixed by #305
Closed

[Request] 请求添加对Fine-tuning模型调用支持 #188

leeyiding opened this issue Sep 12, 2023 · 6 comments · Fixed by #305
Labels
🌠 Feature Request New feature or request | 特性与建议 released

Comments

@leeyiding
Copy link

🥰 需求描述 | Feature Description

目前openai已开放对gpt-3.5-turbo的微调支持,可以通过接口查询用户已经训练的模型,微调后的模型调用方式只需要修改model名称即可

🧐 解决方案 | Proposed Solution

openai提供了接口可以查询用户已经训练的模型列表

curl https://api.openai.com/v1/fine_tuning/jobs \
  -H "Authorization: Bearer $OPENAI_API_KEY"

查询结果如下

{
  "object": "list",
  "data": [
    {
      "object": "fine_tuning.job",
      "id": "ftjob-xxxxxxxxxxxxxxxxxxxxxxx",
      "model": "gpt-3.5-turbo-0613",
      "created_at": 1694484520,
      "finished_at": null,
      "fine_tuned_model": null,
      "organization_id": "org-xxxxxxxxxxxxxxxxxx",
      "result_files": [],
      "status": "running",
      "validation_file": null,
      "training_file": "file-xxxxxxxxxxxxxxxxxxx",
      "hyperparameters": {
        "n_epochs": 3
      },
      "trained_tokens": null,
      "error": null
    },
    {
      "object": "fine_tuning.job",
      "id": "ftjob-xxxxxxxxxxxxxxxxx",
      "model": "gpt-3.5-turbo-0613",
      "created_at": 1694437049,
      "finished_at": 1694438970,
      "fine_tuned_model": "ft:gpt-3.5-turbo-0613:personal:correction:xxxxxxx",
      "organization_id": "org-xxxxxxxxxxxxx",
      "result_files": [
        "file-xxxxxxxxxxxxxxxx"
      ],
      "status": "succeeded",
      "validation_file": null,
      "training_file": "file-xxxxxxxxxxxxxx",
      "hyperparameters": {
        "n_epochs": 3
      },
      "trained_tokens": 486432,
      "error": null
    }
  ],
  "has_more": false
}

其中把status为succeeded的fine_tuned_model字段提取出来即可
参考:
https://platform.openai.com/docs/guides/fine-tuning
https://platform.openai.com/docs/api-reference/fine-tuning/undefined

📝 补充信息 | Additional Information

No response

@leeyiding leeyiding added the 🌠 Feature Request New feature or request | 特性与建议 label Sep 12, 2023
@arvinxx
Copy link
Contributor

arvinxx commented Sep 12, 2023

这个我们需要评估一下。微调能力我知道有开放,但目前有多少人在使用,以及在哪些场景下使用,还是打个问号的。

如果可以的话,能否提供更加详细的场景介绍,以方便我们评估这个功能的重要度?

@leeyiding
Copy link
Author

没有特殊应用场景,只是为了测试微调模型的输出效果,使用命令行也能测试,但是在Web应用中对测试过程进行截图展示会比较美观。所以并不是非常重要,只是基于产品功能的丰富程度进行考虑,这是一个低优先级的需求,开发者可以评估考虑一下,是否把此项需求添加到今后的开发计划中。

@arvinxx
Copy link
Contributor

arvinxx commented Sep 12, 2023

没有特殊应用场景,只是为了测试微调模型的输出效果,使用命令行也能测试,但是在Web应用中对测试过程进行截图展示会比较美观。所以并不是非常重要,只是基于产品功能的丰富程度进行考虑,这是一个低优先级的需求,开发者可以评估考虑一下,是否把此项需求添加到今后的开发计划中。

我们未来会做 web 服务的,这块倒是可以考虑作为增值功能提供出来(包括和微调相关的管理数据集选择、管理、优化的整套东西)。如果没有其他强烈应用场景中的话,开源版本中可能应该不会加进来了。

@Cassianvale
Copy link

我想使用0613的模型,现在的模型傻傻的

@arvinxx
Copy link
Contributor

arvinxx commented Sep 12, 2023

我想使用0613的模型,现在的模型傻傻的

现在默认用的就是 0613模型。你可以在你的 API 里看看调用情况

@lobehubbot
Copy link
Member

🎉 This issue has been resolved in version 0.87.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

skylinemusiccds pushed a commit to skylinemusiccds/BrainWeaver-development that referenced this issue May 12, 2024
* 🤖 chore(auto-submit): Add amazon (lobehub#187)

* 🤖 chore(auto-submit): Generate i18n for amazon (lobehub#187)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🌠 Feature Request New feature or request | 特性与建议 released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants