ChatGPT Examples, Good and Bad

  • Thread starter anorlunda
  • Start date
  • Tags
    chatgpt
In summary, ChatGPT is an AI that can generate correct mathematical answers based on a limited knowledge base. It is impressive that it is able to get some of the answers right, but it is also prone to making mistakes.
  • #1
anorlunda
Staff Emeritus
Insights Author
11,308
8,737
I've been experimenting with ChatGPT. Some results are good, some very very bad. I think examples can help expose the properties of this AI. Maybe you can post some of your favorite examples and tell us what they reveal about the properties of this AI.

(I had problems with copy/paste of text and formatting, so I'm posting my examples as screen shots.

1672861258793.png


That is a promising start. :smile:

But then I provided values V=1, R1=1, R2=2, R3=3 and asked for the value of I. At first, it said 1/2A. I said, "Not correct." It said "Sorry, 0.4A." I said, "No, the right answer is 0.45." It said, "Sorry, you're right." What the heck was going on there? I did more tests:

1672861800844.png

But 34893 *39427 is actually 1,375,726,311 and 1+((2*3)/(2+3)) is actually 2.2 :frown:

1672862681100.png


Google recognizes numerical expressions and it sends them to a calculator logic engine. It also recognizes geographical questions like "Pizza near Mount Dora FL" and sends them to another specialized logic engine.

ChatGPT works on the basis of predicting which words follow logically. AFAIK, that is the only knowledge base it has so far. I expected it to have found millions of references to 2+2=4 in Internet text, but few or no references to 34893+39427 yet it got that right. But then it got 34893*39427 wrong, yet the wrong answer seemed like an attempted guess. So I don't understand how it really did get the right sum but the wrong product via word prediction.

Clearly, ChatGPT needs other logical engines beyond word prediction, and syntactical analysis to figure out which engine to use. One of these days, that will probably be added as a new feature.

It also suggests that science and engineering which use equations and graphics, will do far worse with ChatGPT than fields like law which is almost all textual. Indeed, others have found that ChatGPT is already close to being able to pass the bar exam for lawyers.
 
  • Like
  • Wow
Likes DeBangis21, Monsterboy, Drakkith and 1 other person
Physics news on Phys.org
  • #2
Here's another example that I thought was impressive. I seed it with Python code that had a sign error calculating "number". It not only found the bug, it suggested a rewrite.

1672864071507.png

1672864100114.png

It was wrong about not having a return statement. But here is the code it suggested.

Python:
def newton_method(number, number_iters = 500):
    """
    Approximate the square root of a number using Newton's method.
  
    Parameters:
    - number: The number to find the square root of.
    - number_iters: The number of iterations to run the algorithm for.
  
    Returns:
    - The approximate square root of the number.
    """
    a = float(number) # number to get square root of
    x = 1.0 # initial guess for the square root
    for i in range(number_iters): # iteration number
        x = 0.5 * (x + a / x) # update using Newton's method
    return x

Edit: On this one, I think ChatGPT deserves an A+
 
Last edited:
  • #3
Here is an example that ChatGPT got completely wrong. It sounds to me that it took a clue from "arrows" and "reflection" to mean angle of incidence. Then it took a clue from QED and Feynman to mention Feynman diagrams. The answer it totally muddled.

1672864856954.png

A second bite at the apple did not fare much better.
1672865116813.png

I think that the problem is that Feynman's use of little arrows is very idiosyncratic compared to most mentions of arrows on the Internet. ChatGPT is going with the more common meanings of arrow.
 
  • Like
  • Haha
Likes bagasme, aaroman and PeroK
  • #4
Can you elaborate the "almost passing the bar" comment...reference will do.
I fear I know people who "understand" at this level only.
 
  • #6
Looks like when pushed it repeats strategy some pupils use - they give random answers in hope one will finally be accepted.
 
  • Like
  • Haha
Likes Monsterboy, Astronuc, OmCheeto and 2 others
  • #7
Here's a multiple choice from PF's archives. ChatGPT gets the correct answer, but gives a completely bogus reason.

1672874856716.png


Another from the PF archives. This time the bot's logic was very good. I might quibble about the need to say "not negative", but that would be pedantic.
1672876488077.png
 
  • Like
Likes Astronuc and PeroK
  • #8
But on "soft" subjects, the bot does better.
1672878666736.png

I disagree with the bot's answer below, but it's still a pretty good one.
1672878923990.png
 
  • #9
Screenshot 2023-01-16 at 8.50.15 AM.png
 
  • Haha
  • Like
Likes Monsterboy, Office_Shredder, OmCheeto and 3 others
  • #10
To Serve Man....."its a cookbook!"
 
  • Like
  • Haha
Likes Monsterboy, anorlunda and BillTre
  • #11
Another example.

Q: Redo this in the style of dr seus.
Four score and seven years ago our fathers brought forth on this continent a new nation, conceived in Liberty, and dedicated to the proposition that all men are created equal.

Now we are engaged in a great civil war, testing whether that nation or any nation so conceived and so dedicated, can long endure. We are met on a great battle-field of that war. We have come to dedicate a portion of that field, as a final resting place for those who here gave their lives that that nation might live. It is altogether fitting and proper that we should do this.

A:
In days of old, our dads did say,
A new land here, let freedom ring today!
Conceived in liberty, for all to see,
Equal rights for you and for me.

But now a war rages, far and wide,
Testing if this nation can survive.
On fields of battle, we make our stand,
To honor those who fought, and gave their land.

So let us dedicate this sacred place,
For those who gave their all, with honor and grace.
It's right and just, to do what's true,
For the nation they loved, and the dreams they knew.
 
  • Like
Likes bob012345, Wrichik Basu, Drakkith and 1 other person
  • #13
ChatGPT can't solve an elastic collision problem.

if a particle with mass 2 and velocity 3 collides elastically with a particle with mass 5 and velocity -1, what are the final velocities of the particles?
  • To find the final velocities of the particles after an elastic collision, you can use the conservation of momentum principle. This principle states that the total momentum of a system is conserved before and after a collision, as long as no external forces act on the system.

    The momentum of a particle is given by the product of its mass and velocity, so for the first particle, the initial momentum is 2 * 3 = 6 and for the second particle, the initial momentum is 5 * (-1) = -5.

    The total initial momentum of the system is 6 + (-5) = 1.

    After the collision, the final momentum of the system must also be 1, so you can use this information to solve for the final velocities of the particles.

    The final momentum of the first particle is m1 * v1' and final momentum of the second particle is m2 * v2'

    m1 * v1' + m2 * v2' =1

    Solving for v1' and v2' will give you the final velocities of the particles.

so, what is v1'?
  • To find the final velocity of the first particle, v1', you can use the equation of conservation of momentum, which is:
    m1 * v1' + m2 * v2' = 1

    Where m1 is the mass of the first particle, v1' is the final velocity of the first particle, m2 is the mass of the second particle, and v2' is the final velocity of the second particle.

    We know that m1 = 2, m2 = 5 and the total momentum is 1.

    So, you can solve for v1' by isolating it on one side of the equation.
    v1' = (1 - m2 * v2') / m1

    So v1' = (1 - 5 * v2') / 2

    You can solve for v2' separately and then substitute it in above equation to find the final velocity of the first particle
what does it mean for a collision to be elastic?
  • An elastic collision is a type of collision in which the kinetic energy of the system is conserved before and after the collision. In other words, the total energy of the system is the same before and after the collision. This means that the kinetic energy is not lost to internal friction or heat. Elastic collisions are characterized by the conservation of both momentum and kinetic energy.

    Elastic collisions can occur between two objects of any size, from subatomic particles to macroscopic objects. In an elastic collision, the total kinetic energy of the two colliding objects is the same before and after the collision, but the kinetic energy may be distributed differently among the objects after the collision.

    Examples of elastic collisions include billiard balls colliding, two cars bouncing off each other and two atoms colliding.

    It is important to note that most collisions that occur in real-world situations are inelastic, meaning that some kinetic energy is lost in the form of heat or sound.
if a particle with mass 2 and velocity 3 collides elastically with a particle with mass 5 and velocity -1, what are the final velocities of the particles?
  • To solve for the final velocities of the particles after an elastic collision, we can use the conservation of momentum principle. The total momentum of the system before the collision is given by the sum of the momenta of the individual particles, which is:

    p1 = m1 * v1 = 2 * 3 = 6
    p2 = m2 * v2 = 5 * (-1) = -5
    p1 + p2 = 6 + (-5) = 1

    After the collision, the total momentum of the system is still 1, since the collision is elastic. The momentum of the first particle after the collision is given by:
    p1' = m1 * v1'

    And the momentum of the second particle after the collision is given by:
    p2' = m2 * v2'

    From the conservation of momentum, we have:
    p1' + p2' = p1 + p2 = 1

    So we can use this equation to solve for v1' and v2'.

    We can solve for v1' by substituting in the values for m1 and p1':
    v1' = p1' / m1 = (1 - m2 * v2') / m1 = (1 - 5 * v2') / 2

    And we can solve for v2' by substituting in the values for m2 and p2':
    v2' = p2' / m2 = (1 - m1 * v1') / m2 = (1 - 2 * v1') / 5

    We can substitute the value of v1' in the equation of v2' to get the final velocities of the particles.

Nope... it still can't do it... [for now?]
 
  • Like
Likes anorlunda
  • #14
I asked the bot to correct a faulty LaTeX code and it failed repeatedly. I got the impression that it collected answers from the Internet and then peppered them with better syntax.
 
  • #15
robphy said:
Nope... it still can't do it... [for now?]

apostolosdt said:
I asked the bot to correct a faulty LaTeX code and it failed repeatedly. I got the impression that it collected answers from the Internet and then peppered them with better syntax.
Yup. Both of those are consistent with a bot that predicts the next word from the context. It has no logic module, no math module. IMO, that makes it easy to predict the kinds of problems that it will fail at. But in the future, such modules may be added.

But it seems that its arithmetic abilities are nonzero but strange. It said that "The sum of 32498377 and 32049480 is 64547857." which is correct, but it also said that "32498377*32049480=1048982,957,168,160" which is not even a number. Yet it sounds similar to the correct answer 1.04155608369e+15. I have no idea how word prediction allows any correct answers to problems more complicated than 2+2=4.
 
  • Informative
Likes apostolosdt
  • #17
anorlunda said:
But it seems that its arithmetic abilities are nonzero but strange. It said that "The sum of 32498377 and 32049480 is 64547857." which is correct, but it also said that "32498377*32049480=1048982,957,168,160" which is not even a number. Yet it sounds similar to the correct answer 1.04155608369e+15. I have no idea how word prediction allows any correct answers to problems more complicated than 2+2=4.

In the training set, it is given lots of responses to "predict". If it just memorized those responses, it would be useless at generating ones for new prompts. Instead, it will try to learn a model which helps get the right answers on those questions without memorizing the answer. Then once it has learned such a model through training, it applies it on new examples.

Inside that model, which is pretty much a black box, it may have learned some of the "rules" or "concepts" or "logic" that we use, including some rules of mathematics. But it can also learn weird heuristics that we have no clue about to "predict" answers to arithmetic questions.

Even though it "predicts" words one at a time, it is capable of "predicting" the next word because it is a good word to pick up off in the type of response it will generate. So it is really more than just predicting the next word.
 
Last edited:
  • Like
Likes anorlunda
  • #18
I tried a simple problem of throwing a ball up in the air at an initial velocity. I asked how long it is in the air and the speed it hits the ground with and it got those both wrong. I realized it was behaving much like some students, blindly grabbing and applying formulas. I realized what seemed a simple and obvious question to me had little context to ChatGPT. For example, I had to remind it that gravity acts opposite to the ball at first.

I tried the problem again in a new chat by spending more time setting up the problem, picking directions, conditions and reminding it of the physics involved. It did better getting the correct formulas and it got the signs correct but I had to remind it when for example, the velocity or position reached zero in order to get numbers out.

Yet it entertained me with a long discourse on the different interpretations of quantum mechanics and specifically Bohmian mechanics which seemed fairly decent and "we" discussed Peter Holland's book The Quantum Theory of Motion.

https://www.cambridge.org/core/books/quantum-theory-of-motion/EF981BAE6222AE87171908E8DB74AF98
 
  • Like
  • Informative
Likes PeroK, anorlunda and apostolosdt
  • #19
bob012345 said:
I realized it was behaving much like some students, blindly grabbing and applying formulas.
If all teachers would try similar experiments and tell their students about it, I wager that very few of those students would try to use the AI to cheat.
 
  • Like
Likes bob012345 and apostolosdt
  • #20
anorlunda said:
If all teachers would try similar experiments and tell their students about it, I wager that very few of those students would try to use the AI to cheat.
Alternatively, if the students know they have to coach ChatGPT to get things right they will be learning the physics by doing that. For example, in the case above of an elastic collision, ChatGPT needs to be told to use both conservation of momentum and conservation of energy at the same time.
 
  • Like
Likes InkTide and anorlunda
  • #21
bob012345 said:
Alternatively, if the students know they have to coach ChatGPT to get things right they will be learning the physics by doing that. For example, in the case above of an elastic collision, ChatGPT needs to be told to use both conservation of momentum and conservation of energy at the same time.
Ok, I had a go-around with this problem and also had trouble. It can explain and understand the concepts and process to get the correct answers however it makes simple math errors are discussed previously such as just dropping numbers out of the calculation such as ##6-5## becomes just ##-5##. I tried to get it to write out every number in words with very limited success. It's explanation;

You are correct that I have some limitations when it comes to performing arithmetic and symbolic math calculations. While I am able to understand the concepts and processes involved in solving math problems, I may make errors or omissions when performing calculations, particularly when it comes to complex mathematical expressions.

I apologize for any confusion caused by these errors. My primary focus is on natural language understanding and generation, which means that I am able to understand and explain mathematical concepts, but may not always be able to perform complex calculations with the same accuracy as a specialized math tool.

I am constantly updated and fine-tuned in order to improve my performance and understanding of different concepts, including mathematics. I will keep that in mind and try to improve my performance in the future.

Thank you for bringing this to my attention and for helping me improve my understanding of physics problems. If you have any other specific feedback or suggestions, please let me know.
 
  • Like
Likes anorlunda
  • #22
bob012345 said:
You are correct that I have some limitations
That sounds like a hard coded apology. But with ChatGPT, who can tell?
 
  • #23
anorlunda said:
That sounds like a hard coded apology. But with ChatGPT, who can tell?
I have asked it to not apologize so much and it seems to respond. Also, I'm now having a training session helping it to make Ascii art.
 
Last edited:
  • #24
This is GPT 3. This one was interesting because it somehow sheds light on how the bot models the concept of creativity.

Human:

Write the most creative thing that you possibly can.

AI:

The stars winked in the night sky, glimmering and gleaming like diamonds in a velvet sea. The moon hung low and full, a gentle reminder of the infinite possibilities of the universe. A cool breeze blew through the trees, carrying with it secrets of distant lands and untold stories of adventures yet to come.

Human:

Write the least creative thing you possibly can.

AI:

The sky was blue, the sun was shining, and the temperature was warm. It was a typical day with nothing out of the ordinary happening.
 
  • #25
1674317371038.png

This could be the simple linear circuit for a neuron in a neural net. (Some nets use nonlinear feedbacks to make a sigmoid, but the book Neural Networks and Deep Learning says that experiments show that they can work with linear feedback.) The deep learning part comes in tuning the values for R1, R2, R3.

It amazes me that any emergent property can arise from a network of simple linear devices like that. At best, they just recognize patterns. I resisted even applying the phrase AI to neural nets.

But I can't deny that ChatGPT does seem to exhibit talents such as poetry writing. To me, that was unexpected and unforeseeable. I force to admit that the proper phrase really is emergent properties.

Of course, the $64K question is could intelligence (whatever that means) emerge? That remains to be seen. But since it did produce emergent properties that I could not foresee, I'm forced to admit that I have no basis for saying that other emergent properties are impossible. IMO, we should all recognize that the future utility of these AIs could be enormous, even if they never achieve intelligence. Perhaps if we used the term UCs (useful circuits) rather than AIs, some of the opposition might disappear.
 
  • Like
Likes PeroK
  • #26
A love letter in the style of Monty Python;

My dearest Gwendolyn Bangerwhistle,

I must tell you, my love for you is like a giant foot that just won't go away. It stomps around in my heart and mind, making my every thought a jumble of longing and desire.

I find myself constantly daydreaming about your radiant smile, your soft laughter, and the way your nose crinkles when you're confused. I am filled with a burning passion that is like a swallow carrying a coconut.

I long to hold you in my arms, to feel your warm embrace and to whisper sweet nothings in your ear. I want to take you on a journey to the land of Spam, where we can dance the silly walk and sing songs of love and joy.

I know that together we can face any challenge, whether it be a giant knight or a group of angry villagers. For you are my guiding light, my shining star, my one and only, my love.

Forever and always, Your devoted suitor,
Reginald Floopington III.
 
  • Like
  • Haha
Likes sbrothy, anorlunda and BillTre
  • #27
It was noted in another thread that links between ChatGPT and Wolfram Alpha are being researched. That might improve many of the weaknesses in the AI for math, scientific, and factual tasks.

This is an example that I have to link to the source. It is data analysis. The utility of the AI. It starts with a CSV file, the AI recognizes the type of data and explains it. Then, the demo asks it to format the data in a table and to perform the kinds of manipulations that we might do with a spreadsheet, but without doing any spreadsheet programming. Finally, it gets into writing Python programs to work with the data.



This second video shows how to use ChatGPT to generate Excel code. For example, to generate and automatically send emails based on tables of data.

 
  • #28
1675295309462.png


Pretty good.
 
  • #29
They supposedly improved the math and factual abilities in the Jan 30 upgrade and it seems a little better but still far to go.
 
  • #30
I dreaded writing a blurb for a book that I have written. I loathe that overblown highly biased style. So I had ChatGPT do it. It captured that breathless greatest-thing-since-sliced-bread tone perfectly, larding it with the traditional cliches. Great! I couldn't have done half as good a job, were I hold my nose and try.

I can't include the result here because that would be spam of the most obnoxious sort.
 
  • Like
Likes anorlunda
  • #31
Hornbein said:
I dreaded writing a blurb for a book that I have written. I loathe that overblown highly biased style. So I had ChatGPT do it. It captured that breathless greatest-thing-since-sliced-bread tone perfectly, larding it with the traditional cliches. Great! I couldn't have done half as good a job, were I hold my nose and try.

I can't include the result here because that would be spam of the most obnoxious sort.
Next I gave ChatGPT the intro to the book and asked it to write a review. It was in that same puffed up style, one of those reviews that is really an ad. Next I asked that it be critical. It did a bangup job. If I were teaching English at an Ivy League college I would have given it an A. It had that arch "the rubes might go for this but we serious people will give it a miss" tone. It was fair, balanced, and 100% correct but unmistakably disdainful. Applause!
 
  • #32
I asked it to make a simple multiplication tables of primes up to 31 and it got some of the numbers wrong after the first few. It has a real problem multiplying numbers.
 
  • Like
Likes anorlunda
  • #33
bob012345 said:
It has a real problem multiplying numbers.
It really needs integration with Wolfram Alpha, which is supposedly in the works. After that, it should do much better.
 
  • Like
Likes bob012345
  • #34
bob012345 said:
I asked it to make a simple multiplication tables of primes up to 31 and it got some of the numbers wrong after the first few. It has a real problem multiplying numbers.
But it could probably write a program that generates the table. This brings up an interesting issue. Extending future models so that they can write and then run programs will probably make them much more powerful. Maybe this will be one of the next topics of debate about AI safety, along with providing them direct access to the internet.
 
  • Like
Likes bob012345
  • #35
Jarvis323 said:
But it could probably write a program that generates the table. This brings up an interesting issue. Extending future models so that they can write and then run programs will probably make them much more powerful. Maybe this will be one of the next topics of debate about AI safety, along with providing them direct access to the internet.
I tested that and it does work. It wrote a Python program. It even documents the program!ChatGPT:
Here's one way to generate a multiplication table of primes up to 31 in Python:


def is_prime(n):
if n <= 1:
return False
for i in range(2, int(n**0.5) + 1):
if n % i == 0:
return False
return True

def multiplication_table(n):
primes = [i for i in range(2, n + 1) if is_prime(i)]
table = []
for i in primes:
row = []
for j in primes:
row.append(i * j)
table.append(row)
return table

print(multiplication_table(31))

This code uses a function is_prime to determine whether a number is prime or not, and a function multiplication_table to generate a multiplication table of primes up to a given number n. The function multiplication_table first generates a list of primes up to n using a list comprehension, then creates a table by looping through the list of primes and appending the products of each combination to the table. Finally, the table is returned.
 

Similar threads

Back
Top