C.W.K.
Stream
Lesson 05 of 13 · published

Slash Commands — /init, /compact, /cost, /effort

~14 min · slash-commands, compact, cost, effort, model

Level 0🌱 입문자
0 XP0/70 lessons0/11 achievements
0/120 XP to next level120 XP to go0% complete

매일 쓰는 built-in 들

Slash command 는 deterministic — 고정 로직 실행, AI prompt 아님. 한 다스쯤 되는 built-in 이 모델 해석을 원치 않는 순간을 커버해.

매 세션 값 하는 것들: /compact (context 커지면 — history 요약, 토큰 free), /cost (실시간 지출), /effort low|medium|high|max (reasoning 깊이), /model (mid-session 전환), /permissions (룰 점검), /init (project 부트스트랩). /help 가 풀 리스트 언제든 덤프.

커스텀 slash command 는 .claude/commands/name.md 에 살아 — markdown 파일 쓰면 /name 이 생겨. 본문의 $ARGUMENTS 가 명령어 뒤에 입력한 걸로 치환돼. 2분 만에 셋업, 같은 리뷰 prompt 재입력 그만.

Code

Six commands worth memorizing·bash
# Inside any Claude Code session:

/compact       # squeeze conversation history, save tokens
/cost          # show session $$$ spent and cache savings
/effort high   # dial up reasoning for the next message
/model opus    # switch model mid-session
/permissions   # inspect / edit allow-ask-deny rules
/init          # generate a CLAUDE.md from project state
/help          # full list with descriptions
A custom /review command·markdown
# .claude/commands/review.md
Review the file at $ARGUMENTS for:

1. Logic bugs and edge cases
2. Security issues (SQL injection, XSS, auth bypass)
3. Performance concerns (N+1 queries, blocking I/O)
4. Style violations against our CLAUDE.md standards

Output a prioritized list with severity (HIGH/MEDIUM/LOW)
and file:line references.

External links

Exercise

매일 하는 작업 (diff 리뷰, 로그 요약, 커밋 메시지 생성) 위해 커스텀 slash command 작성. .claude/commands/ 에 저장, 실제 input 으로 돌리고, prompt 두 번 iterate. 보관할 가치 생기면 커밋.

Progress

Progress is local-only — sign in to sync across devices.
이 페이지에서 버그를 발견하셨거나 피드백이 있으세요?문제 신고

댓글 0

🔔 답글 알림 (로그인 필요)
로그인댓글을 남기려면 로그인해 주세요.

아직 댓글이 없어요. 첫 댓글을 남겨보세요.