用 AI 构建应用前,先搞懂前端、后端、数据库和 AI 四个部分
Building an app with AI? Learn these 4 parts first Want to build an app with AI? Learn the four parts first: the front end, the back end, the database, and where AI fits in a modern app. When you ask ChatGPT or Claude to build you an app (vibe coding, no code), these four parts are what you're actually describing. Explained for complete beginners. We follow one customer message through an online coffee store app, start to finish: 1. Front end: everything the customer sees and taps. The screens, the buttons, the text box. It doesn't know prices or stock. It shows things and passes messages along. 2. Back end: runs on a server the customer never sees. This is where the business rules live: login, stock, prices, payments. The front end asks, the back end decides. 3. Database: where everything is saved, like a giant spreadsheet that never closes. Products, prices, customers, orders. Only the back end opens it, and it checks who's asking. 4. AI in the middle: the back end calls the AI model
用 ChatGPT 或 Claude 做 vibe coding 构建应用时,实际描述的是前端、后端、数据库和 AI 四个部分。前端只负责展示并传递消息,后端掌管登录、库存、价格与支付,数据库保存商品和订单且仅由后端访问。AI 只做两件事:把自然语言转成搜索、用数据库返回的真实商品写回答,价格和库存始终由后端决定。
粉丝 11万
- 浏览
- 4.6万
- 点赞
- 2414
- 评论
- 18
- 分享
- 698
- 收藏
- 2572
数字来自平台,为最近一次抓取时的数据。
以下是视频口播的自动转写,可能有错字。
if you're about to build an app with ai, watch this first. right now, you type, build me an app into ChatGPT or claude, and hope for the best.
i'm going to show you the four parts of a modern app, so you know exactly what you're asking ai to build. you don't need any code to follow this.
building an app used to mean months of coding. now you describe it, and ai builds it. but you can only describe what you understand.
front end, back end, database. sounds like a gym routine. and the fourth part, the ai, is the one almost everyone puts in the wrong place.
we'll get there. Say you sell coffee online, a customer opens your app and types, i need a gift for my dad. He drinks it black under forty dollars.
Let's follow that one message all the way through part one, the front end. That's everything she can see and touch the screens, the buttons, the little box, she just typed in it runs on her phone.
And the front end is a bit dumb, on purpose. It doesn't know your prices or what's in stock. It looks good, and passes messages along.
So, it packs up her message, and sends it off. Part two, the back end. It runs on a computer somewhere else called a server, and your customer never sees it.
This is where the rules live. Is she logged in? Is this coffee in stock? What does it cost? Charge the card. Every decision that has to be exactly right happens here.
The front end asks, the back end decides. Part three, the database. That's where everything gets written down, every coffee, every price, every customer, every order.
Picture a giant spreadsheet that never closes. She closes the app, comes back next month, and her orders are still there, because they're saved here.
And her phone never opens the database itself. It asks the back end, and the back end checks who's asking. That's what stops one customer from seeing somebody else's orders.
Now part four, the ai. Most people picture the ai running the whole app. It doesn't. It sits in the middle, next to the back end, and the back end calls it only for the jobs that need understanding.
Watch, her message comes in, gift for dad, drinks it black, under 40. An old app chokes on that, there's no button for my dad.
So the back end hands that sentence to the ai. Job one, understand it. The ai turns it into a search the back end can run.
Dark roast, no flavors, under 40 dollars, gift box. The back end runs that search in the database, and gets back three real coffees with real prices.
Job two, write the answer. The ai writes, your dad's going to love this one, and here's why, using only those three. The front end shows it on her screen.
A couple of seconds start to finish. Now look at what the ai never touched. It never set a price, it never checked the stock, it never went near the card.
The back end did all of that straight from the database. That's the rule. The ai handles the words, the back end handles the facts and the money.
Let the ai quote prices from memory, and one day, it'll invent one. So, here's the whole app in 40. Lines, the front end shows, the back end decides, the database remembers, the ai understands and writes, and that's exactly what you describe when you ask ai to build you an app.
What she sees, the rules the backend follows, what the database has to remember, and the one or two jobs you give the ai.
Describe all four, and you get a real app. Describe only the screen, and you get a very pretty picture of an app. If you want to go from knowing the four parts to building your own apps, i have a full vibe coding course inside my community, plus 7 more that take you from complete beginner to building real systems with ai.
If you're interested, the link is in my profile.
来源:TikTok · 搜「ai tools」 · tiktok.com