GPT-3 Fine-tuning: How to generate "JSONL" training file without code?

Hello! I need help from you no-coders.
As the title says, I try to fine-tunig GPT-3 for OpenAI, but I’m having trouble generating the
JSONL training data without code in the first step “Prepare training data”.
I used this converter to convert CSV to JSONL, but when I request the file endpoint in Postman, it returns the following error.

  • part of my training data
{"prompt":"My stomach is growling","completion":"Would you like something to eat?"}
{"prompt":"I feel tired","completion":"That is a concern. If there is anything I can do for you, please let me know."}
  • Error message
{
    "error": {
        "message": "Expected file to have JSONL format, where every line is a JSON dictionary. Line 1 is not a dictionary (HINT: line starts with: \"{\"p...\").",
        "type": "invalid_request_error",
        "param": null,
        "code": null
    }
}

It says that there are some newlines at the beginning of the file. But the content is fine according to the JONLint.

What should I do? I am eagerly awaiting your advice.
Thank you.

1 Like

Did you try running the API call and postman?

Thank you @AliFarahat .

Yes, I received the above error message in Postman.

Have you tried wrapping each line in quotes as suggested by the message in the error?

Thank you, @dorilama .

Yes, I tried with data each line wrapped in ["] or ["backslash], but the same error message was returned.

So it’s probably the way you make the request with the API connector.

【Solved.】
I changed Unicode from UTF-8 with Bom to UTF-8 without BOM, so the file upload was successful.
It seemed to be related to the fact that I was creating training data in Japanese…
Thanks everyone.

1 Like

I’m having this issue as well, but I’m not sure how to change Unicode.

Any help on this would be great, as I’m still getting that error even after converting to jsonl and trying to upload

Hi @jamesgetsresults . How about then?

You can convert unicode with a text editor for developers, like Adobe Dreamweaver.

The last item, " Unicode Signature (BOM)", in this page is relevant. Please translate and use accordingly!

But Dreamweaver isn’t automated - it would have to be manual - yea?

You are right. I have not found a way to automate.

This topic was automatically closed after 70 days. New replies are no longer allowed.