Vibe Coding: How to use LLM prompts to code effectively!

Subscribers:
5,450
Published on ● Video Link: https://www.youtube.com/watch?v=-FHKKdZVeF4



Duration: 0:00
470 views
9


A demonstration of vibe coding, using plain text instructions to get an LLM to code, feeding back in the errors and/or additional context like API format required!

Here, I use it to generate a text-based game with background music based on emotions and images based on DALL-E 2. The LLM structured output format is provided by StrictJSON library!

Key takeaways:
1. LLMs is not that great with API syntax that are not within its memory. Use external context to give it the right format
2. LLMs can struggle with understanding code bases - use gitingest to help it understand a github better. Replace github with gitingest to get an LLM-friendly text of an entire github: Example Github: https://github.com/tanchongmin/agentjo
Example Gitingest: https://gitingest.com/tanchongmin/agentjo
3. Feeding back the errors can help the LLM correct itself. You are acting as a visual verifier, and you can also input your own "error message" to get the LLM to better understand the gameplay / visual aesthetics of the game
~~~

Refined pfoject can be found here: https://github.com/tanchongmin/agentjo/blob/main/contrib/Fun_AgentJo_Projects/Text-Based Adventure/Game.ipynb
StrictJSON: https://github.com/tanchongmin/strictjson
AgentJo: https://github.com/tanchongmin/agentjo

~~~

0:00 Introduction
1:13 Environment Setup + Initial Prompt
6:28 Initial Problem: Outdated API usage
17:44 Augmenting the prompt with proper API usage guide
22:24 gitingest of strictjson library
26:17 First working game?
29:31 Debugging with a simpler version
41:31 Using new chat to go back to gradio
45:32 Adding music
58:34 Using DALL-E 2 to generate images based on scenario
1:06:46 Final Game Prototype + Conclusion

~~~

AI and ML enthusiast. Likes to think about the essences behind breakthroughs of AI and explain it in a simple and relatable way. Also, I am an avid game creator.

Discord: https://discord.gg/bzp87AHJy5
LinkedIn: https://www.linkedin.com/in/chong-min-tan-94652288/
Online AI blog: https://delvingintotech.wordpress.com/
Twitter: https://twitter.com/johntanchongmin
Try out my games here: https://simmer.io/@chongmin




Other Videos By John Tan Chong Min


2025-06-16Universal Filter (Part 2): Time, Akashic Records, Individual Mind-based, Body-based memory
2025-06-04Good Vibes Only with Dylan Chia: Lyria (Music), Veo3 (Video), Gamma (Slides), GitHub Copilot (Code)
2025-03-10Memory Meets Psychology - Claude Plays Pokemon: How It works, How to improve it
2025-02-24Vibe Coding: How to use LLM prompts to code effectively!
2025-01-26PhD Thesis Overview (Part 2): LLMs for ARC-AGI, Task-Based Memory-Infused Learning, Plan for AgentJo
2025-01-20PhD Thesis Overview (Part 1): Reward is not enough; Towards Goal-Directed, Memory-based Learning
2024-12-04AgentJo CV Generator: Generate your CV by searching for your profile on the web!
2024-11-11Can LLMs be used in self-driving? CoMAL: Collaborative Multi-Agent LLM for Mixed Autonomy Traffic
2024-10-28From TaskGen to AgentJo: Creating My Life Dream of Fast Learning and Adaptable Agents
2024-10-21Tian Yu X John: Discussing Practical Gen AI Tips for Image Prompting
2024-10-08Jiafei Duan: Uncovering the 'Right' Representations for Multimodal LLMs for Robotics
2024-09-27TaskGen Tutorial 6: Conversation Wrapper
2024-09-26TaskGen Tutorial 5: External Functions & CodeGen
2024-09-24TaskGen Tutorial 4: Hierarchical Agents
2024-09-23TaskGen Tutorial 3: Memory
2024-09-19TaskGen Tutorial 2: Shared Variables and Global Context
2024-09-16Beyond Strawberry: gpt-o1 - Is LLM alone sufficient for reasoning?
2024-09-11TaskGen Tutorial 1: Agents and Equipped Functions
2024-09-11TaskGen Tutorial 0: StrictJSON
2024-09-10LLM-Modulo: Using Critics and Verifiers to Improve Grounding of a Plan - Explanation + Improvements
2024-09-06TaskGen: Co-create the best open-sourced LLM Agentic Framework together!