Inspiration
Ever wanted to express yourself, but couldn’t find the right words? Ever tried to find a meme to express yourself, but never succeeded no matter how hard you looked? Ever tried to create a meme yourself, but couldn’t find the right tools to do it?
Well our team sure has! That's why we built the Meme Machine, the solution to all of your meme needs!
What it does
The Meme Machine provides an interface via a website that allows everyone to generate a meme that is tailored to how they are feeling, incorporating experiences they encountered throughout their day.
The user answers two simple questions to gauge their mood and any events that occurred to them. Our AI model analyses the responses and searches our database of meme templates to display to the user a suitable meme image with an auto-generated caption that the user can download or share with their friends.
Furthermore, after meme generation, the meme is exported and piped into the Meme Machine hardware device, which uses advanced inkjet technology to display the meme in a physical format for portable usage.

Example meme from the Meme Machine is shown above. See the demo video for an understanding of the context and how this meme relates to this user's day.
How we built it

Our meme generation server makes use of OpenAI’s ChatGPT4 API to analyze the user’s prompts. All of our meme templates were scraped on the server using NodeJS, Cheerio and Axios.
We store all the memes generated in a Redis database to display at our website’s homepage.
Our website interface was built with Next.js & React.js frameworks and styled with Radix UI and TailwindCSS.
Challenges we ran into
We wanted a large variety of meme templates to feed into our GPT model to ensure that users get relevant memes. However, going through meme templates as a human by hand is incredibly inefficient, slow and prone to error. To make it easier and more fun for us to include good memes in our AI training dataset, we wrote NodeJS scripts to scrape the meme wiki knowledgebase knowyourmeme.com.
It's also possible that we bought a printer from KMart and returned it 10 minutes later when we realised a team member already had one.
Accomplishments that we're proud of
We’re happy we were able to choose a set of light-weight technologies that fit the scope and use-case of this project. We chose the NextJS 14 framework for easily handling server actions like interfacing with the AI and storing/retrieving memes from the database. We chose the redis database because allows us to easily store our simple meme data schema (name, image, description, text positions) and has a cloud hosting option.
We were able to achieve all of our initial objectives (tailored meme generation based on user input, large selection of friendly entertaining memes, simple intuitive user interface, displaying users’ creations on a public memeboard) by designing our codebase in a modular structure that each team member could contribute to with minimal dependencies and blockages from other development tasks.
We’ve effectively allocated the tasks to each individual member’s strengths and all learnt from each other’s unique skills and backgrounds in web development, OpenAI API, database choices, scripting and UI.
What we learned
Because we needed a substantial corpus of meme data to train our GPT model, we had to learn how to write scripts to extract meme data from websites and turn them into a structured format that conforms to our data schema.
We also spent a lot of time on ideation on the first night, describing various ideas in great detail, each of which would have strengths in areas like usefulness, impact, business potential, relevance and appeal to the unihack audience, before deciding on an idea that we were motivated by the entertainment factor.
What's next for Meme Machine
We want to make the Meme Machine experience even more seamless by integrating voice recognition technology to create a more causal UX. This also improves inclusivity by providing support for those with disabilities.
We also want to improve our meme generation by integrating facial recognition technology during the quiz process to provide our AI model with more information to further understand the user’s mood.

Log in or sign up for Devpost to join the conversation.