6 ms·
Show HN: AI Generated (Not-Real) User Avatar Images for Development Needs
Hello,
There are many services that return fake avatar images, but it can be hard to get consistent names and faces.
In this service ChatGPT was used to generate a list of users with various characteristics and Dall-E to generate their avatars, based on those.
You can get a random avatar image like so:
https://avatars.tzador.com/face https://avatars.tzador.com/face
Or request a specific size, like so:
https://avatars.tzador.com/face?size=250 https://avatars.tzador.com/face?size=250
You can ask for specific gender, like so:
https://avatars.tzador.com/face?gender=female https://avatars.tzador.com/face?gender=female
Also you can pin point with id param to get back always the same image:
https://avatars.tzador.com/face?gender=female&id=0987654321 https://avatars.tzador.com/face?gender=female&id=0987654321
If you need a list of fake users with their names, usernames and avatars, you can get it in JSON here.
https://avatars.tzador.com/faces https://avatars.tzador.com/faces
Hope it helps someone, runs on CloudFlare, so should be fast, built using SvelteKit.
- snet0 3y agoMinor spelling issue: > You can mix and match the above paramers as needed. Should be "parameters", of course. I'm literally building a tiny webapp for myself and a few others, this'll come in handy! Just out of interest, would you consider describing the prompt(s) you used for this? I've barely dabbled in ChatGPT for anything like this. Did you use one of those wrapper-like services to ensure the data-out was of the appropriate format?
- timz 3y agoSure, here is gist for generating the data and the images: https://gist.github.com/tzador/ec9c14dd20f0ba1be243727b4f9ae04b https://gist.github.com/tzador/ec9c14dd20f0ba1be243727b4f9ae... Some manual filtering was required of the generated images, since some where looking like mutants.
- snet0 3y agoThanks, that's really helpful!
- ShamelessC 3y agoIncredibly useful thanks!
- timz 3y agoThanks for the spelling tip.
- BaudouinVH 3y agowhat is the syntax to mix and match. Say I want hispanic, male and 26-35 age range ?
- almostnormal 3y agoIt seems to accept multiple GET parameters, e.g., https://avatars.tzador.com/face?age=26-35ðnicity=hispanic&gender=male https://avatars.tzador.com/face?age=26-35ðnicity=hispanic...
- Gare 3y agoI cannot quite put it into words, but something looks eerily uncanny about them.
- replwoacause 3y agoI think it is the symmetry of the faces for one
- JKCalhoun 3y agoThey all have long necks, are looking straight on, are perfectly vertical....
- schleck8 3y agoThe human brain is much better at picking up inconsistencies for faces because that's where you look so often. It's the most difficulg aspect to the uncanney valley.
- tylerrobinson 3y agoIt would be refreshing to see a version of this where the avatars actually look like plausible users and not models/dolls/uncanny robots. Backgrounds, less attractive faces, and different poses would help. Most of the time avatars come from candid snapshots.
- Brajeshwar 3y agoMissed this comment. Yes, there was a service where you can either use the API or link to a random avatar of real people. I have forgotten the name but I can look around and it should be there. I would download/test an App and I would be looking at my Avatar/Picture with someone else's name.
- mpetrovich 3y agoPerhaps something powered by thispersondoesnotexist.com would better for that. That site returns completely AI-generated faces that seem much more realistic and candid.
- timz 3y agothispersondoesnotexist.com is great, but doesn't provide metadata, and one of the primary goals was to be able to have consistent names with images, so boys don't get girls names. Also multiple sizes and fixed ids where needed.
- mpetrovich 3y agoGood point. What if we combined the best of both: more realistic images from tpdne.com and API-accessible metadata from your site? Seems like a matter of crawling the former to get all the images and then tagging them and serving them via your API. Anyway, I think your approach is great and only wanted to propose a possible approach to the original feedback above :)
- timz 3y agoNot sure tpdne would allow to use their images
- sailorganymede 3y agoHonestly, when it comes Avatars for my development needs, I just use Emojis. It’s just really easy to set up compared to getting anything more complicated.
- timz 3y agoI love emojis too. Check out my other project, https://emojifavicon.dev/ https://emojifavicon.dev/, to use emojis as favicons
- cal85 3y agoDid you know you can also use a data-URI as a favicon? And if you use a <text> element inside that SVG, you can set any text as a favicon - including an emoji. For example, this sets the favicon to a little picture of the text "!!!": <link rel="icon" href='data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text y=".9em" font-size="90">!!!</text></svg>' /> You can also replace the "!!!" in the above snippet with any emoji, and it works. (I couldn't do an emoji here because HN filters them out.) You could maybe add this as an option for copying code from your site, and the result will work without any request to any server (with the caveat that the emoji design will vary depending on OS).
- timz 3y agoThat is a cool trick, i should add an option to copy that code as well.
- yreg 3y agoWhat is the license of the GitHub emoji assets?
- Brajeshwar 3y agoOnce upon a time there was a service for avatars and people used to contribute their real avatars (pictures of faces). I contributed mine and it used to pop up at random apps, websites, and such.
- ivanbozic 3y agoWasn't that UIFaces? They're now also some sort of AI-generated faces product, but I remember I also submitted mine there and it was great seeing it pop up here and there.
- Brajeshwar 3y agowww.uifaces.co pops up at the top of the search but this is not. WebArchive says it started around 2018 and the domain was registered in 2017. I remember the services (faces, or avatar, something) but it was since the early 2010s.
- dpkirchner 3y agoI think you're talking about Gravatar: https://gravatar.com/ https://gravatar.com/
- Brajeshwar 3y agoNope. Gravatar by WordPress/Automattic associates your email ID with your avatar. The one I meant is a service, where you can use something similar to the service in this post thread but with real avatars contributed by people on the Internet.
- deleted 3y ago[deleted]
- wouldbecouldbe 3y agoWould default to a bit warmer styles. Looks very much like a modern art portrait style where no one is allowed to smile
- timz 3y agoThis can be extended to infinity, with many styles, shapes and forms. What about Disney looking like avatars https://i.ibb.co/zbk8DnN/3c31a768-d244-47d9-b5ba-0f902e097f8b.webp https://i.ibb.co/zbk8DnN/3c31a768-d244-47d9-b5ba-0f902e097f8...
- wouldbecouldbe 3y agoStill very stylistic and brownish colours; but look at main sentiment here the landing page doesn’t feel like a warm set of humans inviting you
- timz 3y agoThanks for the feedback, will tweak the prompts.
- hasbot 3y agoThe age parameter should accept more granularity for 50+. There is a huge difference between 50-59, 60-69, 70-79, and 80+.
- romanhn 3y agoThis is neat, but it bugs me that it generates email addresses with real providers (Gmail, Outlook, etc). This can lead to accidental emails to real people during testing. I would recommend using @example.com for all emails.
- lcnPylGDnU4H9OF 3y agoNot to take away from the point but it’s also a good practice to catch outbound emails in dev/test and send them to the same (developer-controlled) inbox. Definitely also use fake test data, though; avoidance of this sort of mistake is best handled with a bit of redundancy.
- timz 3y agoGood point, thanks
- pimlottc 3y agoWhen are real user-generated avatars ever consistent? What kind of artificial visual goal are you chasing with this? Or is it just to make your pitch deck look pretty? This feels like another small step toward making the tech world a more visually bland and uniform space [0]. 0: https://www.theverge.com/2016/8/3/12325104/airbnb-aesthetic-global-minimalism-startup-gentrification https://www.theverge.com/2016/8/3/12325104/airbnb-aesthetic-...
- bicx 3y agoIt’s just meant to fill in non-existent profile images for staging builds and demos. It’s not meant to chase anything.
- mberning 3y agoWhere are all the fat and ugly people.
- WesolyKubeczek 3y agoYou should probably go outside to meet them ;-) But yeah otherwise When developing things you also want badly take photos, photos with poor lighting, photos with ugly colors. No one carefully crafts their contact lists as on those apple presentations…
- mberning 3y agoI was thinking of testing healthcare software. Very few 50+ GQ models in the system.
- xdennis 3y agoIf you use this and refresh they all look the same. https://avatars.tzador.com/face?gender=maleðnicity=white&age=26-35 https://avatars.tzador.com/face?gender=maleðnicity=white&...
- WesolyKubeczek 3y agoThe images are all overly handsome faces. Can it be dialed to more ugly and less symmetric mugs, like those you are actually likely to see in real life?