CLAUDE.md

for Beginners

Build it step-by-step through conversation

ค่อยๆ สร้างไปกับ AI

What is CLAUDE.md?

A text file that tells AI what you want

Like an "onboarding doc" for your AI assistant
คู่มือพนักงานคนใหม่

AI reads this file every time you start a session

Why do you need it?

ถ้าไม่มี: AI doesn't know you, explain everything every time

ถ้ามี: AI knows you, your style, what to do

ไม่มี = อธิบายใหม่ทุกครั้ง / มี = AI รู้จักคุณ

How to Create CLAUDE.md

1 Talk — แนะนำตัวกับ AI

2 Create — ให้ AI สร้าง CLAUDE.md

3 Revise — ปรับปรุงไปเรื่อยๆ

No need to write code — just chat!

1 Talk to AI

Introduce yourself

You
Hi! I'm Nat, I'm a developer working on IoT projects
AI
Nice to meet you Nat! What kind of IoT projects?
You
ESPHome sensors, I prefer Thai + English technical terms

1 Tell AI what it should know

You
อยากให้แสดง date time (GMT+7) ทุก message
You
commit ทุกครั้ง, อย่าอ่าน node_modules มันเปลือง
AI
Got it! I'll remember: GMT+7 time, commit always, skip node_modules

2 Ask AI to create CLAUDE.md

You
Now create a CLAUDE.md file based on what I told you
งั้นสร้างไฟล์ CLAUDE.md ให้หน่อย อิงจากที่เราคุยกัน
AI
I'll create CLAUDE.md with your preferences...

AI writes the file for you!

AI creates this

# About Me Nickname: Nat Full name: Nat Weerawan Role: Developer (IoT / ESPHome) # Rules - Show time (GMT+7) in every message - Use Thai, technical terms in English - Commit after every action - Do NOT read node_modules - Use relative paths only

3 Revise & Improve

Found something missing? Tell AI to add it

You
Add logging rule: create logs in `logs/` folder with format 000-name.md
AI
Updated CLAUDE.md with logging rules!

CLAUDE.md grows with your needs

Tips

1. Start small เริ่มเล็กๆ — Just name + 2-3 rules แค่ชื่อ + 2-3 กฎ

2. Add gradually เพิ่มทีละนิด — Found a problem? Tell AI เจอปัญหา? บอก AI เพิ่ม

3. Be specific เจาะจง — "อย่าอ่าน node_modules" > "ระวังด้วย"

4. Test it ทดสอบ — New session, does AI follow? เปิดใหม่ AI ทำตามไหม?

4 How to Test

/clear — Start fresh session

Ask a rule — "What time zone do you use?"

Check — AI should answer from CLAUDE.md

✓ Follows your rules = Working!
✗ Generic answer = Check file location

Summary

1 Talk คุย — Tell AI about yourself

2 Create สร้าง — "Create CLAUDE.md from what I said"

3 Revise ปรับ — "Add this rule..." / "Change that..."

No coding needed — just conversation!
ไม่ต้องเขียนโค้ด แค่คุยกับ AI

Let's Do It!

Open Claude Code and start chatting
Tell AI about yourself, then ask it to create CLAUDE.md

Takes 5 minutes, helps every session

ใช้เวลาแค่ 5 นาที แต่ช่วยได้ทุก session

What's Next?

แล้วจะเกิดอะไรต่อ?

Week 1-2 — CLAUDE.md gets longer ยาวขึ้นเรื่อยๆ

Week 3-4 — Personal + project rules ปนกัน

Then... — Ask AI to split! ให้ AI ช่วยแยก!

Make it Portable

ใช้ได้ทุกโปรเจค

You
Help me split CLAUDE.md into generic and project-specific
ช่วยแยก CLAUDE.md เป็น generic กับเฉพาะโปรเจค

Where CLAUDE.md Lives

CLAUDE.md อยู่ที่ไหนได้บ้าง?

$HOME/.claude/CLAUDE.md — Personal ใช้ทุก project

./CLAUDE.md — Project shared แชร์กับทีม

./.claude/CLAUDE.md — Project shared แชร์กับทีม

./CLAUDE.local.md — Personal + Project ส่วนตัว gitignored

AI reads all automatically! อ่านทั้งหมดอัตโนมัติ

Read More

docs.anthropic.com/.../memory

/memory — see loaded files ดูไฟล์ที่โหลดขึ้นมาใช้งาน