正在加载视频...

视频加载失败

I built a “Ghibli” Anime generator using OpenAI’s new image model with v0 on Vercel and Stripe in 2 hours. Here’s the good, the bad, and “could be improved” 🧵(Did Guillermo Rauch and team cook?)

109,367 次观看 • 1 年前 •via X (Twitter)

11 条评论

Michael Luo 的头像
Michael Luo1 年前

Try it out I first started off by asking ChatGPT to create me a PRD. This was super helpful in making sure v0 covers all the main functionality.

Michael Luo 的头像
Michael Luo1 年前

I then copy + pasted the PRD prompt into v0 and right off the bat it asks me to connect to Supabase and Blob storage. Super easy and great! Then, it asked me to setup env variables.

Michael Luo 的头像
Michael Luo1 年前

v0 asked me for Stripe secret key & webhook secret - ok, fair. But what URL do I use for the Stripe webhook event destinations? I literally have no idea what to put because… v0/Vercel never deployed my app and never gave me a URL! I had no choice but to put a placeholder and figure out how to update this later. It later gives me instructions for how to setup my Stripe webhook (presumably because I left it blank) - great!

Michael Luo 的头像
Michael Luo1 年前

Slight nitpick: It tells me to add an endpoint in Stripe (again, what’s the URL?!) before selecting the event. But in Stripe, you actually select the event before adding your URL. Not a big deal and I’m sure users can figure this out. The other nitpick I have is it uses the checkout.session.completed event, which is fine for card/synchronous payment methods. But for async payment methods (e.g. ACH transfer that takes 2 days), this isn’t the right event to fulfill products for. But if anything, that’s feedback on us (at Stripe) to better educate!

Michael Luo 的头像
Michael Luo1 年前

Next, v0 asked me for NEXT_PUBLIC_BASE_URL - and it never gave me an explanation. And I still didn’t have a URL. So I left it blank for now. (Shouldn’t v0 autofill this?!) Then, I was debugging some OpenAI image generation code. I even copy pasted the OpenAI guide for images.edit into the prompt and it completely hallucinated and used image.generate API call. It’s one thing to hallucinate without an API reference… it’s another to hallucinate with clear instructions to follow the guide. Not a huge deal once I looked at the code… but a waste of a prompt.

Michael Luo 的头像
Michael Luo1 年前

One other big issue is for some reason, v0 doesn’t “see” the next.config and understand when to update it. I kept telling it to set the max file size uploaded to 10mb but kept getting the error “Body exceeded 1MB limit”. Obviously I didn’t look at the docs and just kept copy + pasting the error into v0 and it kept fixing the wrong thing. Finally, it looked at the link and I just manually updated the next.config file.

Michael Luo 的头像
Michael Luo1 年前

Now for the 🚨 biggest issue: Remember when I said I was debugging some OpenAI image generation code? Well, Vercel would run the async generateGhibliImage function in the webhook, with no await. But vercel webhooks die once you return a response since they’re serverless, causing the async generateGhibliImage to also die. And I can’t await anyways because the Stripe webhook needs to be acknowledged quickly and image generation takes on the order of ~1 min. I had to figure out an esoteric workaround with after I have no idea how a non-developer would debug and figure this issue out.

Michael Luo 的头像
Michael Luo1 年前

Don’t get me wrong - overall @v0 is great productivity boost. This would’ve taken me at least 2 days. And I finished in 2 hours. No brainer. But that doesn’t mean there aren’t friction points. I’m excited that this is the worst v0 (and AI coding) will ever be! @rauchg and team cooked

Moescape AI 的头像
Moescape AI1 年前

Sign up & create wholesome anime art on Moescape AI now!

Guillermo Rauch 的头像
Guillermo Rauch1 年前

@v0 @vercel @stripe Amazing, and welcoming all feedback!

Michael Luo 的头像
Michael Luo1 年前

@v0 @vercel @stripe Great product leaders listen to feedback. Appreciate you all for building such a great tool for creativity!

相关视频