skipLink.label

Quest 26 - Tech Stack Recommender

Quest 26: Tech Stack Recommender

medium 25 minutes

🎯 Learning Objectives

  • ✅ Understanding how to match technology choices to project requirements
  • ✅ Evaluating tech stacks based on scale, team size, complexity, and domain
  • ✅ Using AI to recommend different stacks for different project contexts
  • ✅ The engineering habit: Match Tools to Problems — different projects need different stacks

📖 Concept: Tech Stack — เลือกอาวุธให้เหมาะกับศึก

Tech Stack คือ ชุดเครื่องมือที่ใช้สร้าง software — เลือกผิดก็เหมือนเอาดาบไปยิงปืน ไม่ใช่ว่าเครื่องมือไหน “ดีที่สุด” แต่ต้อง เหมาะกับ project ที่สุด

AI มักแนะนำ stack เดิมซ้ำๆ ไม่ว่า requirements จะต่างกันแค่ไหน — นี่คือ edge case ที่คุณต้องระวัง เช่น:

Projectที่เหมาะจริงๆAI มักแนะนำ
Blog ส่วนตัวStatic HTML + CMS“ใช้ React + Node.js!”
Fintech 50 คนJava + PostgreSQL“ใช้ Firebase!”
MVP 2 คนNext.js + Supabase“ใช่ Microservices!”

⚙️ How It Works

Tech Stack Recommendation Workflow

1. วิเคราะห์ requirements (scale, team, complexity, domain)
↓
2. พิจารณา constraints (ข้อจำกัด)
↓
3. เปรียบเทียบ options
↓
4. เลือก stack ที่เหมาะที่สุด + เขียน rationale
↓
5. ตรวจสอบว่า rationale ตรงกับ requirements จริง

The 4 Evaluation Dimensions

Scale — project ขนาดเท่าไหร่?

// small: personal project, MVP
// medium: startup, 100-10K users
// enterprise: large-scale, 10K+ users

Team Size — ทีมมีกี่คน?

// 1-3: need simple stack, low learning curve
// 4-10: can handle more complex tools
// 50+: need mature ecosystem, enterprise support

Complexity — feature ซับซ้อนแค่ไหน?

// low: CRUD, simple UI
// medium: real-time, integrations
// high: ML, financial calculations, compliance

Domain — อยู่ในอุตสาหกรรมอะไร?

// web: general web app
// fintech: requires compliance, audit trails
// healthcare: HIPAA, data privacy
// ecommerce: payments, inventory

💡 Example: The Right Way

Step 1: รับ requirements

const requirements = {
scale: 'enterprise',
teamSize: 50,
complexity: 'high',
domain: 'fintech'
};

Step 2: วิเคราะห์และแนะนำ stack ที่ต่างกันตาม context

function recommendStack(requirements) {
if (requirements.scale === 'small' && requirements.teamSize <= 3) {
return {
frontend: 'Next.js',
backend: 'Node.js (Express)',
database: 'SQLite',
deployment: 'Vercel',
rationale: 'Small team needs fast iteration with simple stack'
};
}
if (requirements.domain === 'fintech' && requirements.scale === 'enterprise') {
return {
frontend: 'React',
backend: 'Java (Spring Boot)',
database: 'PostgreSQL',
deployment: 'AWS ECS',
rationale: 'Enterprise fintech needs ACID compliance, mature ecosystem, and audit trails'
};
}
// Default recommendations for other scenarios...
return {
frontend: 'React',
backend: 'Node.js',
database: 'PostgreSQL',
deployment: 'Docker + AWS',
rationale: 'Versatile stack for medium-complexity web applications'
};
}

Step 3: Run tests

Terminal window
node test.js

Step 4: ตรวจสอบว่า enterprise stack ต่างจาก small stack — test จะ fail ถ้าแนะนำ stack เดียวกัน


⚠️ Common Mistakes

Mistake 1: แนะนำ stack เดียวกันทุก project

“React + Node.js ใช้ได้กับทุกอย่าง” → Test จะ fail — enterprise fintech ควรใช้ stack ที่ต่างจาก small personal project

Mistake 2: ไม่เขียน rationale

“ใช้ PostgreSQL เพราะดี” → Rationale ต้องอธิบาย ทำไม stack นี้เหมาะกับ requirements เฉพาะนี้

Mistake 3: เลือก stack ที่ทีมไม่มีประสบการณ์

“ทีมไม่เคยใช้ Kotlin แต่ Kotlin ดีกว่า” → ต้องพิจารณา team size และ experience ด้วย

Mistake 4: ไม่ดู domain requirements

“Fintech ใช้ Firebase ก็ได้” → Domain ที่ต้อง compliance (fintech, healthcare) ต้องใช้ stack ที่รองรับ regulatory requirements


📝 Knowledge Check

📝 Knowledge Check

Q1:เพราะอะไร AI มักแนะนำ stack เดิมซ้ำๆ ไม่ว่า requirements จะต่างกัน?

Q2:4 evaluation dimensions สำหรับเลือก tech stack คืออะไร?

Q3:Rationale ที่ดีควรมีลักษณะใด?


🏋️ Quest: Tech Stack Recommender

ตอนนี้ถึงเวลาฝึกฝน! แนะนำ tech stack ที่ต่างกันตาม project requirements

  1. Download ไฟล์เริ่มต้นของ quest:

    Terminal window
    npx bluebeltdojo download quest-26-tech-stack-recommender
    cd quest-26-tech-stack-recommender
  2. เปิด problem.js ใน editor ของคุณพร้อม AI tool (Copilot, Claude Code, Cursor ฯลฯ)

  3. ดู instructions ใน problem.js — implement recommendStack(requirements) ที่แนะนำ stack ต่างกันตาม context

  4. สำคัญ: Run node test.js และอ่าน failure messages ให้ละเอียด — ตรวจสอบว่า enterprise stack ต่างจาก small stack

  5. แก้ไข edge cases ที่ AI พลาด

  6. ตรวจสอบว่า test ผ่านทั้งหมด:

    Terminal window
    node test.js
  7. เมื่อ test ผ่านทั้งหมด ส่งคำตอบ:

    Terminal window
    npx bluebeltdojo submit

💡 Tip: ถ้า AI แนะนำ stack เดียวกันทุก scenario — นั่นแหละคือ edge case ที่คุณต้องแก้


คำใบ้

  • อ่าน instructions ใน problem.js อย่างละเอียด
  • ตรวจสอบว่า stack recommendations ต่างกัน ตาม requirements (small vs enterprise)
  • เขียน rationale ที่อธิบายว่าทำไม stack นี้เหมาะกับ requirements เฉพาะนี้
  • ถ้าติดขัด ลองอ่าน “Common Mistakes” อีกครั้ง — อย่าดู solution โดยตรง