
Show HN: Birdseed – A silly way to get random numbers by hashing tweets - ryansworks
https://github.com/ryanmcdermott/birdseed
======
rajington
i know most people talk about the technical aspect of things, but i got to
hand it to you, that's an amazing name

~~~
ryansworks
Thank you! It was better than my second choice which was "Bird of Pair-a-Dice"

------
masonhipp
I always love seeing clever ways to be random. Hadn't considered this one but
it's a pretty good idea, and I'm sure there are even better ways to run with
the basic concept (maybe analyzing color values of recent pinterest or
instagram photos).

If you can find a private source of community-driven-randomness that'd be even
better.

~~~
jdmichal
I wonder whether pictures would be a good source. I could see strong leanings
towards blue (sky, water) and green (vegetation), and maybe also grey
(concrete, asphalt). Would be interesting to do a collective histogram over a
wide array of images and see if colors tend to average out or if there's clear
peaks.

~~~
bmm6o
There's still plenty of room for enough entropy to power most use cases. Even
two people _trying_ to take identical pictures should have enormous
differences when analyzed at the pixel level.

------
binarymax
This is great! I did an experiment a long time ago, before Twitter closed
their JSONP API, to make brownian motion visualizations with a similar
concept.

[http://binarymax.com/brownian_2.gif](http://binarymax.com/brownian_2.gif)

I'll have to find some time to recode it to use this service :)

------
mikeskim
i wrote a paper about leveraging public random streams like this one. it can
be downloaded here
[https://drive.google.com/file/d/0B9IkyvYlZZe7TldTRGlSMnpQX0U...](https://drive.google.com/file/d/0B9IkyvYlZZe7TldTRGlSMnpQX0U/view?usp=docslist_api)

~~~
mtdewcmu
Stock market data does seem like a better source of entropy than Twitter
queries.

~~~
ryansworks
I would tend to agree with you, though my tune might be different if I were an
investment advisor!

------
UncombedCoconut
I love it! Quick idea -- though I'm not sure if this would further the goal of
having fun, even as a PR -- there's a documented way to make Birdseed subclass
random.Random
([https://hg.python.org/cpython/file/2.7/Lib/random.py#l72](https://hg.python.org/cpython/file/2.7/Lib/random.py#l72))
and inherit the familiar interface and fancy methods.

------
grubles
To reiterate: "This is for fun. It's not secure. Don't use it in production
:)"

------
huntaub
I know that this has a disclaimer that isn't to be used in production. But,
just know that hash functions are not there to provide randomness. There is no
guarantee that a hash will be statistically indistinguishable from random
noise.

~~~
benchaney
There is no guarantee that any PRNG will be indistinguishable from random
noise but a properly designed hash function will be as close as any.

~~~
huntaub
Sorry - guarantee was probably too strong. I meant it in the mathematical
sense (no more than a negligible chance of distinguishing from random noise)
[1].

[1]
[https://en.wikipedia.org/wiki/Cryptographically_secure_pseud...](https://en.wikipedia.org/wiki/Cryptographically_secure_pseudorandom_number_generator)

