166 comments

[ 4.3 ms ] story [ 200 ms ] thread
The generator isn't very accurate. I prompted "a sad bald construction worker" and I got a smiling construction worker wearing a hard hat. Only 1 out of 3 adjectives was implemented.
Construction workers probably need to wear a hard hat even when they are bald. ;)
True, but I think a human graphic artist would have known what I was asking for
> Pro-tip: we'll automatiically pre-pend 'A TOK emoji of a' to your prompt. Try something simple like 'cat' or 'high five'.

What is a "TOK emoji"?

A sure sign that it was trained to replicate a particular style, which the trainer decided to name TOK.

It’s somewhat helpful to pick names that are a single token after byte pair encoding, which TOK happens to be.

> Pro-tip: we'll automatiically pre-pend 'A TOK emoji of a' to your prompt.

What if I write "cat, except give me a real photo"?

Hi! Creator here! I just started hacking on this last night and wasn't expecting to see this on HN already :)

It works by taking your prompt and generating an emoji using https://replicate.com/fofr/sdxl-emoji. Next, I remove the background using https://replicate.com/cjwbw/rembg. Then, click to download and add to slack!

It's all open-source, code is here: https://github.com/cbh123/emoji

Let me know if you have any questions!

Wonderful, but the background removal breaks the image - the original final is great, then it destroys it trying to remove the background...

Try this prompt, and it gives a full image, then depending, it culls far too much when removing background, please make background removal optional?

"round brook as designed by comfort tiffany and alphonse mucha in green black and gold"

Yeah I’ve noticed that too. Adding a toggle soon!
Really cool, I think this would be a nice service for Slack, etc to add custom emoji
That's such a coincidence. I was browsing Replicate last night for new models and played with the very same one and was impressed at the results (well, mostly). Kudos to you for turning it into something more accessible and the background removal idea. For everyone else, Replicate is well worth playing around with if you want to tinker with some models without much commitment.
Ahah, that's awesome. Thank you! Let me know if you have any questions about Replicate! Happy to help.
what did you use to recorder the demo in the GitHub readme? its very smooth on the transitions.
Elixir... don't see that every day. I started reading through the code and was like "what the heck is an ex file?!!"

Never really seen Elixir before. Looks pretty nice.

The beauty of Ruby with the bulletproof-ness of Erlang.
Elixir is a killer language and tool. It's considered esoteric these days but I think more and more folks are going to wake up to the inherent beauty of the Erlang BEAM and OTP applications pretty soon here.
Is Elixir really considered esoteric? There’s some pretty big businesses running on it.
It never took off as the Ruby killer. It hurts to say so because I agree with all the positive Elixir comments around here - IMO, people are missing out by not knowing of it.
Yes! I love Elixir :) Phoenix LiveView is really amazing. I feel so fast working in it. I got hooked after watching Chris McCord's 'Build a real-time Twitter clone in 15 minutes' demo, and things have improved a lot since then.
Doesn't this cost money? Could you use a model from huggingface too. I'm trying to get into this kind of stuff, but I want to use free or local AI models to avoid bills.. lol
I guess even with hugging face you have to pay for the compute costs which could get pretty big pretty fast if something takes off.
Just came off your Elixir talk photos on Twitter to find this on HN. Please share your ElixirConf talk recording. Producing a nice emoji/avatar for an AI agent seems like a cool idea.
Thanks so much :)

I'll share it as soon as I have access! I'll also post a transcript on my site (charlieholtz.com) soon.

Super cool! I would add a checkbox to toggle whether you want background removal, or make that an optional second step. In about half the cases I tried, the background was an important part of my image and without it only weird artifacts remained.
I really like it. It does seem to be suffering a little from some biases that are probably coming from sdxl though.
What biases?
As others have pointed out it tends to associate some professions with specific races. And crime related emojis with black people. It's a Stable Diffusion issue.
It's not a stable diffusion issue, it's a culture issue.
"It's not a stable diffusion issue, it's a culture issue."

parroting and perpetuating the biases will ensure it will continue to be a culture issue.

The text to image models represent the data that is being fed to it. If you feed it 100 images and out of those 100 images 95 are of white men politicians and 5 are of politicians of color, that's what you are going to get back. These datasets are gathered automatically from various internet sources and represent the data that is available out in the wild. For stable diffusion to "fix" the bias in the data set would be simply impossible. That would require hiring an army of people whose sole purpose would be to "rebalance" the data set on some internal objective schema manually.
Id rather train it on real data and fix the root cause than to interject some version of utopia that won the minds of developers.
It seems biased towards white people for most anything I input.

criminal - black man stealing - white murderer - white killer - white thief - white skin, black beard. arab? Indian? man murdering kittens - white

I just ran "a criminal" 8 times and got only white men.
Awesome job! One criticism I have is these are emoji, they're more like bitmoji or memoji.
I see that the perpetually-offended have already shown up.

My advice is to either simply ignore them, or point and laugh (your choice).

The one thing you can count on them is that they are never going to be satisfied. Most likely they're not even actually offended, not really. They just enjoy bullying other people.

Remarkably complete, it even declined to make a dirty eggplant.
I tried the prompt "electric bass" -- the generated image was OK (it was a three string bass, but whatever) but the background removal not only removed the background but most of the body of the bass because (I assume) the pickguard was the same color as the image background.
The word confused appears to cause a failure
Oh this is crazy, I didnt realize replicate had user models like that for chaining

Is there a good video or channel to follow thats all about replicate and similar services at this level of depth?

Hi, neat idea. Appear to have hit an issue. https://i.imgur.com/XQGfBed.png Interesting, just not a clean Emoji.

Using :bob: (Thought it might give me "B.O.B.", "Bob Dylab", or "What about Bob")

Based on some of these, it seems 'AI' still just can't figure out fingers.
When you setup SD1.5 with enough extras, the finger problem is effectively gone. For those very few that slip through, a new seed or inpainting takes care of it.
The handshake is hilarious. That's so many fingers
Symbolises any contract I signed well.
[X] I have read and agree to the Terms of Service and Sale of Soul Agreements.
Does it make sense to prompt it based on the names of existing Apple emojis? I can’t tell if it’s helping or not. Some tests are exceptionally good, some are inexplicably awful. Very cool either way! I had a lot of fun experimenting.
The generated "emoji" size is 500kb. That's really a lot.
They're relatively large PNGs, so that's not surprising. Resize and convert to JPG if you want to use them for something and care about the size.
I think it has some xss attack as on load my ios safari asked if i want to download 2girls1cup.jpg
It seems to use %s.jpg as a filename and to request the browser to download the picture you clicked on as that filename, so probably some larrikin typed 2girls1cup in as a prompt and you happened to click on whatever picture came out and was in the feed.
> Larrikin is an Australian English term meaning "a mischievous young person, an uncultivated, rowdy but good hearted person", or "a person who acts with apparent disregard for social or political conventions".
Seeing what other users are prompting it with is half the fun of the output.

Nice to see people merely pushing boundaries rather than ruining it for everyone for now.

Tons of fun :) thanks for the laugh!

    Good news from Fly.io! We don’t collect bills smaller than $5.00. 

    Bad news, you made it on the HN homepage and your CC is now on fire.
I just saw this was on fly and thought the same thing lol. But I also thought to myself “this is actually a good use for fly, nice simple app to see if there’s traction before moving to something reliable.”
Does fly do runaway billing?
Bandwidth would be the concern, I think. They won't auto-scale machines up/down for you.
Fly bandwidth pricing is pretty competitive; if bandwidth is an issue your bill will be cheaper on Fly than most other providers.
Do you have any specific references or instances that indicate fly.io as being unreliable?
Very anecdotal so take this lightly but the past year or so of Fly.io threads have had a lot of comments expressing negative experiences with reliability. I have no experience myself so I can't comment, but if you search for a fairly recent thread you'll probably find some people's experiences.
I was about to start building a new application and I really wanted to give Fly a shot, but the CLI literally wouldn’t connect to their builder API. The status page was all green, but clearly things weren’t working.

I moved to Render and I’ve had a much better experience.

I had something deployed on fly for a few months and was regularly running into random restarts and connection issues. I ended up switching to DO’s app platform and haven’t seen any of that since.
FlyIO deleted my database and I lost all data.

Fly told me in 7-days they would automatically update my redis database. My plan was to manually update it that weekend. 3 days later, I get an alert that they migrated the db early. b/c I didn't have storage enabled, all data was gone.

Support ticket:

https://community.fly.io/t/forced-migration-to-v2-with-decei...

Fly.io definitely has an innaproprately casual attitude, and it's a big deal they migrated you early.

However, they do point out that literally any reboot would have wiped your data and that that could have happened at any time previously. I think there's some truth to the suggestion I've seen on HN that the users running into the worst fly.io issues are the ones aiming to spend single digit amounts per month and not paying for enough machines and disk space to have reliability be possible

Like I said in the forum history, I should have paid for persistent storage, but this data lose could have been avoided during a planned reboot.

FlyIO knew that there was no storage attached to the redis instance and there would be data loss, but they still chose to reboot it ahead of schedule.

... And it is hugged to death now.
Curious as a non dev, could this equally have been on vercel or netlify or does this type of app lend itself to fly?
I like the Futurama ones. They’re inaccurate but in cute ways. Fry has smaller Frys coming out of his head and Leela has two eyes.
Asking it for one eyed anything produces only outputs with two eyes
The broken AI hands with extra fingers as the thumbs up / thumbs down button is a nice touch.
I know, I thought it was a mistake but then I literally laughed out loud once I understood.
I assumed it was an intentional “two thumbs up/down” that amusingly highlighted questionable AI hands at the same time. :)
Amen! Had a nice chuckle. Kudos for self-deprecating humor on the part of the authors.
I can’t stop thinking that in 2-3 years this kind of functionality might get bundled with popular chat platforms by default.

As I keep trying to generate :sexy-cthulu: and :van-gogh-with-an-eyepatch: , my queries time out, perhaps for the best.

> I keep trying to generate :sexy-cthulu:

The e621 model will probably have that in the training set…

Something similar (maybe not ai, idk) is included in Google's keyboard app. You can combine many emoji. Not all of them, but it's still quite nice!
I see a bunch of Disney characters there.

They look exactly like how they're supposed to look.

That might be a problem, legally speaking ...

(comment deleted)
"threesome" is an interesting one.

Men are always black and the women are always white.

I wonder where it learned that..

n=?
n=3 for me.

It's also "featured". And the featured one is an example of what I'm talking about.

Interested to know what can be done with the up/down votes, some kind of RLHF for image generation?

Unfortunately it seems some "tiled images" must have made it into the dataset as half the time it generates an array of tiny images instead of a single emoji. Out of about 5 or 6 tries I got one good one that wasn't centered correctly.

Yeah my thought was the up/down votes could be used to have a "Trending" or "Most Popular" section on the site. But that RHLF idea is interesting too — I've had the same problem with tiled images, and so fine-tuning on highly upvoted examples may help