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

Welcome to the forefront of conversational AI as we explore the fascinating world of AI chatbots in our dedicated blog series. Discover the latest advancements, applications, and strategies that propel the evolution of chatbot technology. From enhancing customer interactions to streamlining business processes, these articles delve into the innovative ways artificial intelligence is shaping the landscape of automated conversational agents. Whether you’re a business owner, developer, or simply intrigued by the future of interactive technology, join us on this journey to unravel the transformative power and endless possibilities of AI chatbots.
Thank you for visiting nature.com. You are using a browser version with limited support for CSS. To obtain the best experience, we recommend you use a more up to date browser (or turn off compatibility mode in Internet Explorer). In the meantime, to ensure continued support, we are displaying the site without styles and JavaScript.
Advertisement
Simon Wang is a lecturer in English at Hong Kong Baptist University.
PubMed  Google Scholar
Yu Ruobin is a PhD candidate in English Literature at Hong Kong Baptist University.
PubMed  Google Scholar
Stuart Christie is a Professor of English Literature at Hong Kong Baptist University.
PubMed  Google Scholar
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’.
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.
Vibe coding removed the coding barrier, but not the need for human judgement. As research designers, we defined the experimental structure — two AI creativity levels and a five-week duration — on the basis of decisions that no algorithm could make for us. As prompt authors, we shaped the chatbot’s behaviour through system prompts that drew on our teaching intuition. As quality controllers, we piloted the platform and discovered that the AI was sometimes overscaffolding — drafting full stanzas when a student hesitated. We revised our prompts so that it would offer only a couple of options and direct questions to the student: “Here are two possible metaphors. Which feels closer to what you want to express?” Fixing that required an understanding of poetry and learning, not knowing how to debug code.
We piloted the platform with 30 university students who were interested in poetry but unfamiliar with writing it in English. One told us: “The AI chatbot helped me build confidence in choosing words.” Another said: “I’m not a very creative person, but I feel like I can rely on AI to have some sparks in my brain.”
Yu Ruobin, Stuart Christie and Simon Wang (left to right) used vibe coding to create a custom poetry laboratory.Credit: HKBU staff
or
doi: https://doi.org/10.1038/d41586-026-01106-6
Declaration of AI Use: The authors used Anysphere’s AI tool Cursor to help prepare this Careers Column.
This is an article from the Nature Careers Community, a place for Nature readers to share their professional experiences and advice. Guest posts are encouraged.
Subscribe to Nature Briefing: Careers, an unmissable free weekly round-up of help and advice for working scientists.
The authors declare no competing interests.
How to vibe code in science: early adopters share their tips
Why universities need to radically rethink exams in the age of AI
OpenClaw AI chatbots are running amok — these scientists are listening in
ChatGPT for students: learners find creative new uses for chatbots
Six tips for better coding with ChatGPT
Collection: ChatGPT’s impact on careers in science
AI in science recruitment: friend or foe? Join our free webinar
Career News
Power imbalances in adviser–student relationships need safeguarding
Correspondence
First and last authors more likely to be men in leading science journals
Nature Index
Microsoft upgrades controversial quantum chip — researchers are still sceptical
News
How good are ‘AI doctors’ — and will they take over medicine?
News
Experimental randomness amplification
Article
Poor supervision is pushing young researchers out of academia
News
Innovation starts in schools — lessons from China
Comment
Antibiotics look like any other drugs — and that’s a problem
Outlook
Job Title: Associate or Senior Editor, Communications AI & Computing Locations: Shanghai, Beijing, Pune, New Delhi, Berlin or Madrid (hybrid) Appli…
Shanghai, Beijing, Pune, New Delhi, Berlin or Madrid (hybrid)
Springer Nature Ltd
A tenure-track Assistant Prof. position in machine learning linked to IceLab’s Center for modeling adaptive mechanisms in living systems under stress
Umeå, Sweden
Umeå University
The Medizinische Klinik I (Kardiologie) invites applications for a PhD Student in cardiovascular immunology (m/f/d).
Munich (Stadt), Bayern (DE)
LMU Klinikum
Postdoctoral positions exploring microbiota–stem cell interactions in development, disease & cancer using gnotobiotic models, organoids & multi-omics.
Beijing (CN)
The Chinese Institutes for Medical Research (CIMR), Beijing
Anhui Normal University sincerely invites outstanding researchers and academics worldwide to join its faculty.
Wuhu, Anhui (CN)
Anhui Normal University
How to vibe code in science: early adopters share their tips
Why universities need to radically rethink exams in the age of AI
OpenClaw AI chatbots are running amok — these scientists are listening in
ChatGPT for students: learners find creative new uses for chatbots
Six tips for better coding with ChatGPT
Collection: ChatGPT’s impact on careers in science
An essential round-up of science news, opinion and analysis, delivered to your inbox every weekday.
Sign up for the Nature Briefing newsletter — what matters in science, free to your inbox daily.
Nature (Nature)
ISSN 1476-4687 (online)
ISSN 0028-0836 (print)
© 2026 Springer Nature Limited

source

Scroll to Top