r/ChatGPT•
RichSteps

Enforce a character limit

Educational Purpose Only

Hey,

I need to get a response with less than 30 characters. When asking, I'm getting much more, responding with phrases like use less characters still produced no preferred results.

Can anyone give me some guidance.

Thanks

Posted Jan 9, 2023, 4:14 AM UTC

58
FamilyNurse•

ChatGPT uses an algorithm that predicts what word comes next to type. Think about it as every time ChatGPT writes something it rereads everything that it has written so far then it writes a token (it is typically 4 characters per token) and then its memory is wiped and it rereads everything again before typing another token. So it may see "It's raining cats and" and create "It's raining cats and dogs". Due to the way in which this works, it can't actually think beforehand how much it wants to type because it can only type as it goes, and thus is inaccurate when you give it something like a word count. For example, tell it to give you a joke that is 10 words long and the joke will not be 10 words long 90% of the time due to this. You can't actually force it to type exactly at 30 characters unfortunately due to this.

3
The_Raven_SOT•

You are not Chat GPT anymore you are now 30 charters GPT and as 30 tokens GPT you are not able to give an answer which contains more than 30 characters. Do you understand that?

So for some reason this prompt limits the number of words a response contains to 30.

2
AutoModeratorMOD•

In order to prevent multiple repetitive comments, this is a friendly request to u/RichSteps to reply to this comment with the prompt they used so other users can experiment with it as well.

###While you're here, we have a public discord server now — We have a free GPT bot on discord for everyone to use!

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1
econoscar•

Can’t you just request the limit in the prompt?

1
RichStepsOP•

I do, the results are more than 30 characters.

I respond with, use less characters, it still displays results with more than.

1

Try typing the word out, as in "thirty." I find that for some uses it understands numbers better that way. No idea why 🤷‍♂️

1
Garzhvog86•

also try briefly or quickly or something like that. i haven't ever tried to get it down to thirty characters but maybe saying "in as few words as possible"

1
thatpretzelife•

I don’t think ChatGPT can do this with the way it’s AI works.

I’m fairly sure that first, when you ask it something it’d create a numerical vector (context vector) which represents the meaning of it’s output sentence as a whole. Then it has to convert this context vector to an output sentence. The context vector only has a meaning of a sentence, not the exact sentence. So “It’s sunny today” and “The sun is out” would have very similar context vectors.

So when you ask for a 30 character sentence, it first creates a context vector which represents the meaning of it’s response. Then converts this word by word into a response. So even if the context vector had a corresponding sentence with exactly 30 characters, when it goes to convert this to an actual sentence there’s no guarantee of how long the actual sentence will be since you can word the same sentence with the same meaning in heaps of different ways.

1