gpt4 book ai didi

python - OpenAI GPT-3 API : Which file formats can be used for fine-tuning?

转载 作者:行者123 更新时间:2023-12-02 22:45:36 25 4
gpt4 key购买 nike

随着我们进入 AI 的动荡时代。我也把我的水洒进了海里。因为我是 pythonian,所以所有的尝试都是在 python/anaconda 中完成的。

是否有人对可传递给 GPT AI 家族的“数据格式”有一些经验?

在文档中推荐使用 OpenAI 工具进行控制。后跟文档推荐格式(“提示:”,“完成:”)字符串标记为:

  ["str" = in quotes,"/" = separator ,"@>" = unique symbol, 
" " = comp. starts with empty space]

'Prompt': 'Hello AI..!!/@>'
'Completion': ' How are you today?/@>'

“完成”应该在每个字符串的开头都有空白。到目前为止,我只能找到简单的例子:

Col1             Col2
'Prompt': 'Completion':
'Text/@>' ' Text/@>'

它有什么办法可以理解更复杂的数据集吗?效果更暗淡。数据框?示例:

     Col1        Col2             Col3         Col4        
'Prompt_a': 'Completion_a': 'Prompt_b': 'Completion_b':
'Text/@>' ' Text/@>' 'Text/@>' ' Text/@>

较长的上下文文本是作为“str/@>”传递的,还是需要一些分区?

' text text text /@>'

非常感谢所有的回答和提前的努力。

已检查:https://help.openai.com/en/articles/6811186-how-do-i-format-my-fine-tuning-data

最佳答案

如官方所述OpenAI documentation :

Your data must be a JSONL document, where each line is aprompt-completion pair corresponding to a training example. You canuse our CLI data preparation tool to easily convert your data intothis file format.

This tool accepts different formats, with the only requirement thatthey contain a prompt and a completion column/key. You can pass a CSV,TSV, XLSX, JSON or JSONL file, and it will save the output into aJSONL file ready for fine-tuning, after guiding you through theprocess of suggested changes.

关于python - OpenAI GPT-3 API : Which file formats can be used for fine-tuning?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/75559672/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com