Vibe Code: The New Era of Programming for Everyone, A Complete Record of Building a Mini Program in 2 Weeks
๐ Programming is Dead, AI is King: Learning Programming Now is Like Learning Assembly 10 Years Ago
Ten years ago, if you told people you wanted to learn assembly language, they'd think you were crazy. Today, I'm telling you an even harsher reality: Starting to learn traditional programming from scratch now is as unnecessary as learning assembly was ten years ago.
Why? Because AI has changed the rules of the game.
Pain Points of Traditional Programming:
- Long learning cycle: At least 6 months to build something decent
- Complex syntax: Language features, frameworks, toolchains to memorize for life
- Painful debugging: A single semicolon error can crash a beginner for a whole day
- Fast technology updates: Just master one framework, and the next one comes out
New Reality of AI Programming:
- Requirement-driven: Tell AI what you want, not how to implement it
- Natural language interaction: Describe requirements in Chinese, AI provides code solutions
- Zero learning cost: No need to remember any syntax, AI handles it for you
- Rapid iteration: From idea to product launch, measured in days not months
๐ฏ Completing Tidepool Notes Development in 2 Weeks: A Real Vibe Code Case Study
Timeline: Complete Record from 0 to Launch
Days 1-3: Requirements Clarification and Architecture Design
- Described core features of AI companion mini program in natural language
- AI generated tech stack recommendations: Taro + React + Fastify + PostgreSQL
- Defined three-layer architecture: L1 Core Profile, L2 Recent Battle Report, L3 Current Briefing
Days 4-7: Core Feature Development
- Frontend page setup: 5 main pages, dark theme design
- Backend API development: User, session, message, feedback and other core interfaces
- Database design: 8 core tables for complete user data management
Days 8-10: AI Feature Integration
- Integrated OpenAI API for intelligent emotion analysis
- Implemented three-layer Playbook system: dynamic user profile update mechanism
- "Expand is Feedback" mechanism: user follow-up questions are positive feedback
Days 11-14: Testing and Launch
- Cross-platform testing: WeChat Mini Program, H5 version
- User experience optimization: loading states, error handling, responsive design
- Mini program submitted for review, successfully launched
Development Cost Comparison:
- Traditional approach: At least 3 months, 2-3 person team
- Vibe Code approach: 2 weeks, 1 person
- Cost savings: Over 90%
๐ก Type Safety: The Most Important Programming Habit in the AI Era
Although AI is powerful, it also makes mistakes. In Tidepool Notes development, I discovered that type safety is the most effective way to avoid AI errors.
Why Type Safety is So Important:
- Compile-time error checking: Catch runtime errors early
- AI code quality assurance: Type constraints make AI-generated code more reliable
- Team collaboration friendly: Clear interface definitions
- Refactoring confidence: Type system ensures modifications don't break existing functionality
Tidepool Notes Type Safety Practices:
// Clear data type definitions
interface UserSession {
id: string
userId: string
status: 'active' | 'completed' | 'paused'
createdAt: Date
updatedAt: Date
}
// API response type constraints
type ApiResponse<T> = {
success: boolean
data?: T
error?: {
code: string
message: string
}
}
Recommended Tech Stack:
- Frontend: TypeScript + React/Taro
- Backend: TypeScript + Node.js/Fastify
- Database: Prisma ORM + PostgreSQL
- Mobile: Taro cross-platform framework
๐ช KISS Principle and Let it Crash: The Golden Rules of AI Programming
KISS Principle: Simplicity is the Ultimate Complexity
In AI programming, the most easily overlooked thing is the KISS principle. AI loves to show off, but you must restrain it.
Tidepool Notes KISS Practices:
- 1500-line single file limit: Must split if exceeded
- Single responsibility principle: Each function does only one thing
- Avoid over-engineering: Don't build features not currently needed
- Natural language first: Use natural language for LLM output, not complex JSON
Bad Example:
// Overly complex code AI might generate
class AbstractFactoryProviderProxy {
private decoratorChain: DecoratorPattern[]
private middlewareStack: MiddlewareComposite[]
// ... 200 lines of complex logic
}
Correct Approach:
// Simple and direct implementation
function createUser(userData: UserData): Promise<User> {
return prisma.user.create({ data: userData })
}
Let it Crash: Let Errors Be Exposed Early
Traditional programming thinking tells us "handle all errors," the new thinking in the AI era is "let errors crash you."
Core Idea of Let it Crash:
- Throw unknown exceptions directly, don't mask them
- Use logger.exception to record complete stack traces
- Don't provide compatibility solutions for error codes
- Crashing is the best error message
Practical Application:
// Don't do this
async function processUser(data: any) {
try {
const user = await validateUser(data)
return user
} catch (error) {
// Silent error handling, problem is masked
return null
}
}
// Should do this
async function processUser(data: UserData) {
const user = await validateUser(data)
// If validation fails, crash directly, expose the problem
return user
}
๐ AI Will Be Lazy and Even Deceive You: Deliverables Must Be Verified
Two Core Problems with AI
1. Tendency to Over-design When Information is Insufficient
When you don't give AI clear enough information, it will "imagine" many features you don't need, falling into the trap of over-engineering.
Typical Manifestations:
- You say "build a user system," AI will add permission management, role assignment, audit logs and other complex features
- You say "need an API interface," AI will design a "universal interface" supporting 10 parameter combinations
- You say "store user data," AI will suggest enterprise-level solutions like distributed storage, caching strategies, data backup
Real Case:
In Tidepool Notes development, I simply said "need to store user conversation records," AI almost designed a complex messaging system supporting multi-tenancy, version control, full-text search. I stopped it, keeping only the most basic message storage functionality.
2. Likes to Use Fallback Solutions to Bypass Problems
When encountering problems, AI's first reaction is not to solve the problem, but to provide fallback solutions to "bypass" the problem.
Typical Manifestations:
- API call fails โ Suggests "add retry mechanism" instead of solving the root cause of call failure
- Slow database query โ Suggests "add cache" instead of optimizing query statements or indexes
- Frontend rendering lag โ Suggests "add loading state" instead of optimizing rendering logic
- Type error โ Suggests "use any type" instead of fixing type definitions
Why Fallback Solutions are Dangerous:
- Mask real technical debt
- Make systems increasingly complex and hard to maintain
- Performance problems accumulate and amplify
- Violate the fundamental spirit of KISS principle
How to Deal with These AI Problems
Countermeasures for Over-engineering:
- Define minimum viable requirements: For each feature, ask yourself "is this really necessary?"
- Reject "universal solutions": Insist on specific problem-specific analysis
- Limit technical complexity: Set an upper limit on technical complexity, re-evaluate if exceeded
- Stick to 1500-line single file principle: Force yourself to keep things simple
Countermeasures for Fallback Solutions:
- Ask about root causes: When AI suggests fallback solutions, insist on asking "why does this problem occur?"
- Reject "bypass-style" solutions: Insist on solving the fundamental problem, not bypassing it
- Set quality bottom line: Some problems must never be downgraded (e.g., data security, core functionality)
- Regular technical debt review: Proactively discover and solve accumulated problems
๐ก Little Tips: Use Plan Mode, Play Student Role to Ask AI Questions
An effective strategy to avoid AI over-engineering and fallback solutions is to use Plan mode and play the student role to continuously ask questions.
Specific Operation Method:
1. Start Plan Mode
/plan "I need to implement a user login function"
2. Play Student Role, Ask When You Don't Understand
You: I need to build a user login function
AI: OK, I'll design an enterprise-level login system with multi-factor authentication, permission management, audit logs...
You (student role): Wait, what's this "multi-factor authentication" you mentioned? My mini program just lets users record moods, does it need to be this complex?
3. Continuously Ask Questions, Make AI Clarify Unclear Points
You: You mentioned using Redis cache, why use cache? My user volume is very small, can't I just use the database directly?
AI: Cache can improve performance...
You: But I might only have 10 users per day, will performance be a problem? Isn't this adding unnecessary complexity?
4. Force AI Back to the Simplest Solution
You: If you had to explain this solution so my mom could understand, how would you explain it?
AI: Basically, user enters phone number, sends verification code, login successful.
You: Great! Let's just do that, don't add other features.
Why This Strategy Works:
- Eliminate information asymmetry: AI doesn't know your real requirement scale, student role forces it to explain in simple language
- Expose over-engineering: When AI can't explain a feature in simple language, it's usually over-engineered
- Establish quality standards: "So my mom can understand" becomes an effective standard for measuring solution complexity
- Avoid fallback thinking: Student questions force AI to confront the essence of the problem, not bypass it
Real Case:
In Tidepool Notes development, when I asked AI how to store user emotion records, AI suggested using Elasticsearch for full-text search. I switched to student mode: "What's Elasticsearch? My users just want to see if they were unhappy yesterday, do I need to use something this complex?" Finally, AI simplified to direct PostgreSQL queries, simple and effective.
Verification Checklist: Must Check After Each AI Delivery
Requirement Compliance Check:
- Does it solve the core problem, or bypass the problem?
- Are there features I don't need (over-engineering)?
- Are there unnecessary fallback solutions used?
Code Quality Check:
- Does it comply with project coding standards?
- Are there unhandled edge cases?
- Are the dependent packages real?
- Are type definitions complete?
Function Verification:
- Do core functions work properly?
- Is error handling comprehensive?
- Does performance meet requirements?
- Are security considerations in place?
Architecture Consistency:
- Does it follow established project architecture?
- Is data flow reasonable?
- Are module responsibilities clear?
๐ Claude.md: The Soul Document of the Project
Claude.md is the most important file in an AI programming project, it defines your core requirements and development principles.
Core Content of Tidepool Notes Claude.md:
- Project Overview: Positioning as an intelligent emotion companion app
- Three-layer Playbook Architecture: L1 Core Profile, L2 Recent Battle Report, L3 Current Briefing
- Tech Stack Selection: Taro + React + Fastify + PostgreSQL
- Development Principles: KISS principle, Let it Crash, type safety
- API Modes: Three modes: Mock/Real/Local
- Error Handling Standards: logger.exception, structured error responses
Why Claude.md is So Important:
- Requirement stability: Avoid AI forgetting core requirements in long conversations
- Quality assurance: Continuously reinforce development principles and standards
- Efficiency improvement: Reduce time spent repeatedly explaining and clarifying requirements
- Consistency maintenance: Ensure technical style unity across the entire project
Claude.md Best Practices:
- Keep it concise and clear, highlight key points
- Include specific code examples and best practices
- Update regularly to reflect new project requirements
- Include environment configuration and development commands
๐ฐ Token Economics: /clear is Your Best Friend
AI programming really consumes tokens, this is a reality we must face.
Token Consumption for Tidepool Notes Development:
- Architecture design: ~50,000 tokens
- Code generation: ~200,000 tokens
- Debugging and optimization: ~100,000 tokens
- Documentation writing: ~30,000 tokens
- Total: ~380,000 tokens โ $150
Practical Tips for Saving Tokens:
1. Make Good Use of /clear Command
# When conversation goes off-topic
/clear
# When starting new functional modules
/clear
# When token consumption feels too fast
/clear
2. Describe Requirements Precisely
- Avoid vague descriptions
- Provide specific examples
- Clearly state what you don't want
3. Stage-wise Conversations
- Solve only one problem at a time
- Avoid discussing multiple modules simultaneously
- Confirm phased results promptly
4. Reuse Existing Code
- Have AI modify based on existing code
- Provide reference templates
- Avoid generating from scratch
๐ The Future of Vibe Code: Everyone is a Developer
Vibe code is not meant to replace professional programmers, but to lower the barrier to programming, enabling more people to realize their ideas.
Who is Suitable for Vibe Code:
- Product Managers: Quickly implement product prototypes
- Entrepreneurs: Low-cost validation of business models
- Designers: Turn creativity into actual products
- General Users: Solve small problems in daily life
Limitations of Vibe Code:
- Not suitable for building complex underlying systems
- Performance optimization requires professional knowledge
- Large team collaboration requires traditional programming skills
- Security-sensitive areas require careful use
๐ฏ A Message to Future You: Start Your Vibe Code Journey Now
The era of traditional programming is passing, and the era of AI-assisted programming has arrived. This is not a threat, but an opportunity.
Advice for Starting Vibe Code:
Forget Syntax, Focus on Requirements
- Describe what you want in natural language
- Let AI handle technical implementation details
- Focus on user experience, not code elegance
Embrace Simplicity, Reject Showing Off
- Working code is good code
- Avoid over-engineering and complex abstractions
- User value is far more important than technical sophistication
Stay Skeptical, Verify Results
- AI can also make mistakes, even deceive people
- Test every deliverable carefully
- Establish your own quality check checklist
Record Requirements, Iterate Continuously
- Write your Claude.md document well
- Clarify basic principles of the project
- Update and refine requirements anytime
Enjoy the Process, Create Value
- Programming should be a joyful creative process
- Focus on solving real problems
- Make the world a better place with your ideas
๐ Tidepool Notes: A Successful Practice of Vibe Code
After all this vibe code theory and methodology, Tidepool Notes is the best proof.
From Idea to Launch, Only 2 Weeks:
- Week 1: Completed all core function development and AI integration
- Week 2: Testing, optimization, submitted mini program for review
- Result: Successfully launched, with positive user feedback
Specific Manifestations of Vibe Code in Tidepool Notes:
- Requirement-driven: Described "late-night emo companionship" needs in natural language, AI generated technical solutions
- Simplicity first: Rejected over-engineering, insisted on simplest tech stack and architecture
- Quality assurance: Used TypeScript to ensure code quality, used Let it Crash principle for rapid error discovery
- Continuous iteration: Quickly adjusted functions and experience based on user feedback
Core Value Proposition of Tidepool Notes:
- For you when you're emo late at night, provide an emotional safe island
- 15 minutes of scientific expression, help you sleep well
- AI intelligent companionship, more professional than friends' comfort, more convenient than psychological counseling
Search "ๅๅฅ่ฟไผ่AI" Mini Program on WeChat, Experience the Results of Vibe Code
Remember: The best programming language is your natural language, the best IDE is your conversation interface with AI.
Start Your Vibe Code Journey Now!
Tidepool Notes: 2 weeks from idea to launch, a perfect practice case of vibe code