Theo's Site

Writing about technology, self-hosting, and things I find interesting.

Note: This post is 3 years old and may no longer reflect current thinking or accurate information.

Using GPT-3 for Creative Writing

by theo

Created another script that uses a single run of the edit mode of GPT-3 with a high temperature (ie. giving GPT-3 a high degree of creativity). But it runs it three distinct times.

https://gogs.theopjones.blog/theo/LittleScripts/src/master/transcribefoldermultiple.py The results are interesting The results are interesting

Unedited Transcript

I’ve been experimenting a bit with using GPT-3 to process speech-to-text transcripts, which in their raw form contain no line breaks, no paragraph breaks, kind of off-text because it’s a direct transcription of my speech, like not how I would normally write it. I’m feeding, and I have a little Python script written to feed these raw, unprocessed speech-to-text transcripts into GPT-3. Of course, GPT-3 can’t be ran locally, so it has to make an external API call. But how the script I wrote works is it makes one API call to have the text split up into individual paragraphs, and it makes another set of API calls for each paragraph to correct the grammar, style, spelling, and all of that. I did the two-part thing because based on my experimentation, GPT-3 doesn’t really like being given a huge wall of text, so splitting it up into paragraphs is one of the best techniques I found to get GPT-3 not to remove a lot of text without creating replacement text or add totally new text. From what I can tell, the little script I wrote is able to keep things pretty faithful to how I originally dictated while still punching up the grammar and resolving a lot of the editing I would have to do to make a speech-to-text transcript usable on my blog or something. So I think it’s helpful because it reduces a lot of really error-prone stuff that comes with using speech-to-text to write. I’ve uploaded a little Python script. I’ve used use slash created, and you can find it below.

Run 1 of GPT-3

I’ve been experimenting a bit with using GPT-3 to process speech-to-text transcripts, which in their raw form contain no line breaks, no paragraph breaks, kind of off-text because it’s a direct transcription of my speech, like not how I would normally write it. I’m feeding, and I have a little Python script written to feed these raw, unprocessed speech-to-text transcripts into GPT-3.

Of course, GPT-3 can’t be run locally, so it has to make an external API call.

But how the script I wrote works is it makes one API call to have the text split up into individual paragraphs, and it makes another set of API calls for each paragraph to correct the grammar, style, spelling, and all of that.

I did the two-part thing because based on my experimentation GPT-3 doesn’t really like being given a huge wall of text, so splitting it up into paragraphs is one of the best techniques I found to get GPT-3 not to remove a lot of text without creating replacement text or add totally new text.

From what I can tell, the little script I wrote is able to keep things pretty faithful to how I originally dictated while still punching up the grammar and resolving a lot of the editing I would have to do to make a speech-to-text transcript usable on my blog or something.

So I think it’s helpful because it reduces a lot of really error-prone stuff that comes with using speech-to-text to write.

I've uploaded a little Python script. You can find it below.

Run 2 of GPT-3

Currently, all of the transcripts on my YouTube channel are just raw, unedited speech-to-text outputs. They’re posted in their raw form so that they’ll be more accessible to people with all types of cognitive impairments who may not have the mental capacity to parse a transcript that’s been edited to improve grammar, spelling, sentence structure, style, and probably many more things I’m forgetting. Unedited speech-to-text transcripts are also more accurate since there’s no bias about word usage. Since speech-to-text is closer to merely transcribing all the words that I actually said, it’s more accurate than an edited transcript will be because I’m speaking with some bias and editing to clean up the transcript would increase that bias. However, the unedited speech-to-text transcripts increase the difficulty of parsing the text. For someone with severe speech-to-text-related cognitive impairments, they may continue to be beneficial, but for a lot of people with some type of speech-to-text-related cognitive impairment, an edited transcript would be helpful. That’s where GPT-3 comes in. GPT-3, because of its ability to edit, process, and rework text, can be used to make speech-to-text transcripts more accessible for people with a wider range of learning styles and ways of processing text. In short, GPT-3 can help turn unedited speech-to-text transcript from something that’s not very accessible to something that’s more accessible for a lot of people with different kinds of cognitive impairments. This seems like a common sense thing. Since most online videos have speech-to-text transcripts, most online speech-to-text transcript must be pretty difficult to parse, especially if someone has a mild learning disability of some sort.

GPT-3 can be used to punch up unedited speech to text transcripts, improving their readability and overall quality. I’ve been experimenting with using GPT-3 to process speech-to-text transcripts, which in their raw form contain no line breaks, no paragraph breaks, and are generally kind of off-text because it’s a direct transcription of my speech, not how I would normally write it. I’ve written a little Python script to feed these raw, unprocessed speech-to-text transcripts into GPT-3. Of course, GPT-3 can’t be ran locally, so it has to make an external API call. But the script I wrote works by making one API call to have the text split up into individual paragraphs and making another set of API calls for each paragraph to correct the grammar, style, spelling, and all of that. I did the two-part thing because based on my experimentation, GPT-3 doesn’t really like being given a huge wall of text, so splitting it up into paragraphs is one of the best techniques I found to get GPT-3 not to remove a lot of text without creating replacement text or add totally new text. From what I can tell, the little script I wrote is able to keep things pretty faithful to how I originally dictated while still punching up the grammar and resolving a lot of the editing I would have to do to make a speech-to-text transcript usable on my blog or something. So I think it’s helpful because it reduces a lot of really error-prone stuff that comes with using speech-to-text to write. I’ve uploaded a little Python script. You can find it below.

Run 3 of GPT-3

I’ve been using GPT-3 to process speech-to-text transcripts, which are quite rough in their original form.

They have no line breaks or paragraph breaks, and their formatting is off because GPT-3 has to read directly from audio.

But I wrote a little Python script which takes these unprocessed transcripts, inputs them into GPT-3, and the script outputs the corrected versions.

Since GPT-3 can’t be accessed locally, the script has to make external API calls.

The script works by making one API call to have the text split into individual paragraphs, and then another call for each paragraph to correct the grammar, style, spelling and such.

I did the two-part thing because, from my experimentation, GPT-3 doesn’t really like being given large walls of text, so splitting it into paragraphs is one of the best ways to get GPT-3 to not remove a lot of text without creating replacement text or adding totally new text.

The script I made seems to be able to keep things pretty faithful to the original while still enhancing the grammar and resolving a lot of the editing I would have to do to make the transcript usable on my blog or elsewhere.

So I think it’s helpful because it reduces a lot of the really error-prone stuff that comes with using speech-to-text to write.

I’ve uploaded the Python script to use slash created – you can find it below.

Leave a Comment

Your email address will not be published. Required fields are marked *