As amazing as they are, they still have many limitations.
I’ve been working with ChatGPT and Gemini to apply simple rules like the one above and I got so frustrated.
As amazing as they are, they still have many limitations.
I’ve been working with ChatGPT and Gemini to apply simple rules like the one above and I got so frustrated.
I can’t fault llms for not knowing what to do here because I, a human, have no idea what on earth this means.
I’m not a native English speaker, how would you write it?
FWIW the LLMs get it right many times, but fail other times.
Just ask it in your own native language.
And third, I’m not the only one working on this problem, there are others that are native speakers, and as my initial message stated, there have been many variations of the prompt. None work for all cases.
And lastly, how would you rewrite my sample prompt? Which BTW bad a typo (unrelated to my English skills) that I’ve now fixed.
I.e. It doesn't seem to answer the actual question.
They seem to be half responding to the second sentence which was a personal opinion, so I wasn't soliciting any answers about it. And half going on a tangent that seems to lead away from forming a direct answer.
Run these comment through a translation tool if your still not 100% sure after reading this.
I think you left out a few words that most English writers would include. So instead of:
> "ensure that numbers from one to ten as written as words and numbers greater ten as digits in the given text",
something like the following might be better for most people:
> "ensure that the numbers from one to ten are written as words, and the numbers greater ten are written using numerical digits in the given text"
There are multiple ways to write this, so other people may have better versions.
I'm not an English grammar expert, so I cannot explain to you why the addition of those extra words helps with the clarity of that sentence.
"Using" is important as a number greater than ten can't be written as a digit, but can be written using digits ("with" would be just as good). Repeating "written" makes it clearer that there are two instructions.
or at least that's my understanding of the prompt
There are two blue, one red, and 15 green m&ms in this bag.
But if you are writing about a large number, particularly one with a lot of different digits, prefer writing the digits: "A mile is 5,280 feet." Compare that to: "A mile is five thousand, two hundred, and eighty feet."
Given the many reaponses, it would be fun to aee if llm beat humans on understanding the sentence ahah
> Change all numbers between one and ten to words, and write numbers eleven and above as digits in the text.
It even used eleven rather than ten which sounds like counting.
You could get this behavior implemented perfectly with constrained text gen techniques like grammars or any of the various libraries implementing constrained text gen (i.e. guidance)
I could think of how to use them to prevent the LLM from generating digits for numbers greater than ten by using a regex plus a constraint that forbids digits, but the main problem is the other part of the rule, i.e. numbers above 10 should never be spelled out and should be written as digits instead. For that I presume you need to identify the spelled out numbers first, for which you presumably would need the LLM so you're back to LLM fallibility.
Any pointers would be greatly appreciated.