cbh123 / emoji Goto Github PK
View Code? Open in Web Editor NEWMake emojis for slack using AI
Home Page: https://emojigen.com
Make emojis for slack using AI
Home Page: https://emojigen.com
Some generated images don't get downloaded upon click, inspecting the console (using eruda mobile console) shows scripts errors.
One is already on the site.
It looks like this functionality was added in 2004eeb but it's causing the app to fail. In my fly.io logs I am seeing:
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info]14:33:44.701 [error] GenServer #PID<0.2594.0> terminating
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info]** (Ecto.NoResultsError) expected at least one result but got none in query:
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info]from p0 in Emoji.Predictions.Prediction,
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info] where: is_nil(p0.embedding) and not is_nil(p0.emoji_output) and p0.score != 10,
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info] order_by: [asc: fragment("RANDOM()")],
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info] limit: 1
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info] (ecto 3.10.3) lib/ecto/repo/queryable.ex:161: Ecto.Repo.Queryable.one!/3
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info] (emoji 0.1.0) lib/emoji/embeddings/worker.ex:35: Emoji.Embeddings.Worker.handle_info/2
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info] (stdlib 5.0.2) gen_server.erl:1077: :gen_server.try_handle_info/3
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info] (stdlib 5.0.2) gen_server.erl:1165: :gen_server.handle_msg/6
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info] (stdlib 5.0.2) proc_lib.erl:241: :proc_lib.init_p_do_apply/3
2023-09-26T14:33:44Z app[148ed770fe2258] dfw [info]Last message: :work
Of note, I cleared out my predictions table to start fresh (though even when it had content it was failing too). I am running 92f44d7.
It says "We can't find the internet."
Heyo! This is a super neat app and I saw it looks like it should be possible to deploy it to Fly.io. I've attempted to do this but I don't think I've got it completely working.
mix setup
.fly.toml
file aside - mv fly.toml fly.toml.bak
.flyctl launch
. I deployed it with a PostgreSQL database though I don't think that is necessary - correct me if I am wrong.REPLICATE_API_TOKEN
and filled it in with the token I obtained from https://replicate.com. I redeployed the app so it would use the token.Any ideas on getting this to work would be very much appreciated. If there's any other information or details I can provide to help troubleshoot please don't hesitate to let me know!
Thanks,
getting this error in local and also on fly
investigating now
[debug] QUERY OK source="predictions" db=0.4ms idle=1217.6ms
SELECT count(*) FROM "predictions" AS p0 WHERE (NOT (p0."image_embedding") IS NULL) []
↳ Emoji.Embeddings.Worker.should_generate_image_embedding?/0, at: lib/emoji/embeddings/worker.ex:36
[debug] QUERY OK source="predictions" db=0.4ms idle=1218.3ms
SELECT count(*) FROM "predictions" AS p0 WHERE (NOT (p0."embedding") IS NULL) []
↳ Emoji.Embeddings.Worker.should_generate_text_embedding?/0, at: lib/emoji/embeddings/worker.ex:28
[debug] QUERY OK source="predictions" db=0.2ms idle=1219.0ms
SELECT p0."id", p0."no_bg_output", p0."emoji_output", p0."prompt", p0."uuid", p0."score", p0."count_votes", p0."is_featured", p0."local_user_id", p0."moderation_score", p0."moderator", p0."embedding", p0."image_embedding", p0."embedding_model", p0."inserted_at", p0."updated_at" FROM "predictions" AS p0 WHERE (((p0."embedding" IS NULL) AND NOT (p0."emoji_output" IS NULL)) AND (p0."score" != 10)) ORDER BY RANDOM() LIMIT 1 []
↳ Emoji.Embeddings.Worker.handle_info/2, at: lib/emoji/embeddings/worker.ex:81
[error] GenServer #PID<0.730.0> terminating
** (Ecto.NoResultsError) expected at least one result but got none in query:
from p0 in Emoji.Predictions.Prediction,
where: is_nil(p0.embedding) and not is_nil(p0.emoji_output) and p0.score != 10,
order_by: [asc: fragment("RANDOM()")],
limit: 1
(ecto 3.10.3) lib/ecto/repo/queryable.ex:161: Ecto.Repo.Queryable.one!/3
(emoji 0.1.0) lib/emoji/embeddings/worker.ex:81: Emoji.Embeddings.Worker.handle_info/2
(stdlib 3.17.1) gen_server.erl:695: :gen_server.try_dispatch/4
(stdlib 3.17.1) gen_server.erl:771: :gen_server.handle_msg/6
(stdlib 3.17.1) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
Last message: :work
State: %{}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.