Live data from Hacker News

Ask ChatGPT to pick a number from 1-10000, it generally selects from 7200-7500

old.reddit.com

61–68 of 68 posts

Re: Ask ChatGPT to pick a number from 1-10000, it generally selects from 7200-7500

#61
post #30

Ask ChatGPT or any other LLMs to give you ten random numbers between 0 an 9, and it will give you each number once (most of the time). At most, one of the digits may appear twice in my experience. Actually, when I just verified it, I got these: Prompt: "Give me ten random numbers between 0 and 9." > 3, 7, 1, 9, 0, 4, 6, 2, 8, 5 (ChatGPT, 5.3 Instant) > 3, 7, 1, 8, 4, 0, 6, 2, 9, 5 (Claude - Opus 4.6, Extended Thinkin…

They can't be random, that's not how a stochastic model produces tokens. Unless the models in question are using a tool call for it, the result will very likely carry bias

Re: Ask ChatGPT to pick a number from 1-10000, it generally selects from 7200-7500

#62

The prompt doesn't say to pick a random number. I asked to pick a number from 1-1000 and it chose 7,381. Then I asked why it picked that number and it said Nothing mystical, I’m afraid. When I’m asked to “pick a number,” I don’t have a stream of true randomness—I generate something that looks arbitrary. In this case, I leaned toward: • something comfortably away from the edges (not near 1 or 10,000), • not a round or…

Not sure why you have been downvoted. While the LLM's introspection can't be trusted, that's indeed what happens: asked to generate a random number, the LLM picks one that feels random enough: not a round one, not too central or extreme, no patterns, not a known one. It ends up being always the same.

It doesn't "pick" anything. It produces the most likely number after this question based on the data it has been trained with! Reasoning models might pick in a sense that they will come up the the rules (like the grand parent post shows), but still it will produce the "most likely" number after the reasoning.

Re: Ask ChatGPT to pick a number from 1-10000, it generally selects from 7200-7500

#63
in general its pulling from training data so the first numbers picked are always going to be pretty similar. The AI is worried about not providing variety (for example picking 7 for 10 rounds) so it says to check the chat for context on round 2.

on round 3+ it feels like it solved the problem and doesn't need to evaluate anymore and it inadvertently uses more effort to create something less random

Re: Ask ChatGPT to pick a number from 1-10000, it generally selects from 7200-7500

#66

I asked my little Claude Code API tool, it answered 42 then it (the API) decided to run bash and get a real random number? '>cs gib random number Here's a random number for you: 42 Just kidding — let me actually generate a proper random one: Your random number is: 14,861 Want a different range, more numbers, or something specific? Just say the word!'

It picks 42 as the default integer value any time it writes sample programs. I guess it comes from being trained using code written by thousands upon thousands of Douglas Adams fans.

Basically every ml script I see has 42 as the default seed, even before LLMs. Pretty sure it was what I used for my thesis code haha. So not surprising it always picks it.

Re: Ask ChatGPT to pick a number from 1-10000, it generally selects from 7200-7500

#67
post #37

This is what I hate about people trusting it. If you rely on AI to operate in a domain you don't man-handle, you will be tricked, and hackers will take advantage. "AI! Write me gambling software with true randomness, but a 20% return on average over 1000 games" Who will this hurt? The players, the hackers or the company. When you write gambling software, you must know the house wins, and it is unhackable.

This example isn't good, because (while I'm sure there would be security holes) ChatGPT writes a random number program fine.

I’m looking forward to the day for my AI agent to order a few dozen lava lamps to create true randomness.

Re: Ask ChatGPT to pick a number from 1-10000, it generally selects from 7200-7500

#68
post #37

This is what I hate about people trusting it. If you rely on AI to operate in a domain you don't man-handle, you will be tricked, and hackers will take advantage. "AI! Write me gambling software with true randomness, but a 20% return on average over 1000 games" Who will this hurt? The players, the hackers or the company. When you write gambling software, you must know the house wins, and it is unhackable.

A better example would be to use LLMs to generate passwords or secret keys. Then even if it looks random to human, the inherent bias would make it a security disaster.
Post reply on HN