Skip to content
Tech News
← Back to articles

We vibe-coded a custom AI poetry lab. Here’s how you can, too.

read original get AI Poetry Generator Kit → more articles
Why This Matters

This article highlights how educators and developers can leverage AI tools like vibe coding to create customized platforms for creative learning, such as poetry writing. It demonstrates the potential for tailored AI applications to enhance teaching methods and foster creativity, even without extensive coding experience. This approach signals a shift towards more accessible, experiment-driven AI development in the education sector.

Key Takeaways

Researchers are using artificial-intelligence tools to build their own platforms for teaching. Credit: wichan sumalee / Getty Images

Last November, our poetry students walked into the computer laboratory and found something new: a web interface with chat-room windows labelled “the structured studio” and “the exploratory atelier”. Each chat room ran the same artificial-intelligence chatbot that students could use to co-write poems in English, but the chatbot behaved differently between the two. In one case, the chatbot took creative risks, pushing students towards surprising metaphors; in the other, it was cautious and literal.

Behind the chat-room windows was a custom AI platform that none of us — a language teacher, an English-literature PhD candidate and a literature professor all at Hong Kong Baptist University — could have built by ourselves.

Our project began with a simple question: how can teachers use AI to help learners write poetry in English? We wanted to explore how different AI configurations shape creativity when students co-write poems with chatbots. We could have pointed our participants towards OpenAI’s ChatGPT, but generic chatbots don’t offer control over key parameters that drive AI behaviour, systematic conversation logging and ways to set up experimental conditions. We needed a custom platform — and none of us had the coding experience to build one. So, we turned to ‘vibe coding’.

From natural language to web app

Vibe coding is the process of describing, in plain English, the software that you want to develop to an AI tool and letting it write the required code. Using Lovable, an AI coding assistant that turns written instructions into working web applications, we laid out our requirements: two chat rooms with different AI settings, a clean interface, conversation logging and controls for adjusting our experimental conditions. Lovable generated a working web app with a back-end database for data storage, authentication and conversation logging.

Why universities need to radically rethink exams in the age of AI

We did not get everything right the first time. Our early prompts were vague. Given the instruction “log all the chats so we can download them later”, Lovable created a logging feature that stored only the most recent message. We learnt to be precise: “store every turn in the conversation, with timestamps and room labels, in a downloadable CSV file”. The same lesson applied to shaping the chatbot that Loveable made for us — a short, specific instruction such as “respond with one concrete revision suggestion and one question about the student’s word choice” produced better results than a page-long specification did.

With AI assistance, we connected our web app to OpenRouter, a service that provides access to a number of large language models, which enabled our app to send prompts to a model and receive responses. We then asked the Loveable coding assistant to route each chat-room message to a selected model, return the reply to the correct chat room and log every prompt, response, room label and time stamp for analysis. Crucially, we also made it possible to adjust key parameters such as temperature and top‑p. Temperature influences how randomly the AI tool combines ideas; top‑p affects how widely it samples possible word choices. These settings are often hidden in off‑the‑shelf chatbots, but in our platform they became research variables — levers we could tune and study in real student interactions.

Retaining human judgement

... continue reading