Files
everything-claude-code/docs/ko-KR/rules/performance.md
konstapukarifastnetfi 8b24f63ede fix: refresh stale technical content in agents, rules, and skills (#2168)
Several published examples contained APIs that no longer exist, code that
does not run, or model versions that drifted from reality:

- agents/performance-optimizer.md used the web-vitals v3 API
  (getCLS/getFID/getLCP/getFCP/getTTFB) and reported FID. web-vitals v4
  renamed the imports to onCLS/onINP/onLCP/onFCP/onTTFB and FID was
  replaced by INP (target < 200ms)
- rules/common/performance.md pinned stale model versions in the
  model-selection guidance; refresh to the versions the repo itself uses
  (agent.yaml pins claude-opus-4-6) and add the PowerShell variant for
  MAX_THINKING_TOKENS next to the bash export
- skills/python-patterns/SKILL.md: both get_value examples referenced
  default_value without declaring the parameter (NameError); add
  default_value: Any = None to the EAFP and LBYL signatures
- skills/frontend-patterns/SKILL.md: the custom useQuery example rebuilt
  refetch whenever callers passed inline fetchers/options, re-triggering
  the effect after every state update (infinite fetch loop). Keep the
  latest fetcher/options in refs so refetch stays referentially stable.
  The PASS-labelled useMemo example mutated its input with in-place sort;
  copy before sorting
- skills/coding-standards/SKILL.md repeated the same PASS-labelled
  in-place-sort-in-useMemo example; same fix
- rules/typescript/security.md used a vendor-specific OPENAI_API_KEY in
  generic guidance; switch to a neutral API_KEY

Every hand-maintained copy of the affected content is synced in the same
change: locale mirrors (ja-JP, ko-KR, pt-BR, tr, zh-CN, zh-TW - each only
where it carries the affected file) and the .agents/.kiro/.cursor harness
mirrors. Two structural divergences are left alone and noted here:
.kiro/steering/performance.md has no extended-thinking control list to
carry the PowerShell variant, and docs/zh-TW/rules/performance.md keeps an
older condensed thinking section without the budget-cap line.
rules/zh/performance.md is intentionally untouched - the rules/zh tree is
being retired in a separate change
2026-06-07 13:26:01 +08:00

1.8 KiB

성능 최적화

모델 선택 전략

Haiku 4.5 (Sonnet 능력의 90%, 3배 비용 절감):

  • 자주 호출되는 경량 에이전트
  • 페어 프로그래밍과 코드 생성
  • 멀티 에이전트 시스템의 워커 에이전트

Sonnet 4.6 (최고의 코딩 모델):

  • 주요 개발 작업
  • 멀티 에이전트 워크플로우 오케스트레이션
  • 복잡한 코딩 작업

Opus 4.6 (가장 깊은 추론):

  • 복잡한 아키텍처 의사결정
  • 최대 추론 요구사항
  • 리서치 및 분석 작업

컨텍스트 윈도우 관리

컨텍스트 윈도우의 마지막 20%에서는 다음을 피하세요:

  • 대규모 리팩토링
  • 여러 파일에 걸친 기능 구현
  • 복잡한 상호작용 디버깅

컨텍스트 민감도가 낮은 작업:

  • 단일 파일 수정
  • 독립적인 유틸리티 생성
  • 문서 업데이트
  • 단순한 버그 수정

확장 사고 + 계획 모드

확장 사고는 기본적으로 활성화되어 있으며, 내부 추론을 위해 최대 31,999 토큰을 예약합니다.

확장 사고 제어 방법:

  • 전환: Option+T (macOS) / Alt+T (Windows/Linux)
  • 설정: ~/.claude/settings.json에서 alwaysThinkingEnabled 설정
  • 예산 제한: export MAX_THINKING_TOKENS=10000 (bash) 또는 $env:MAX_THINKING_TOKENS = "10000" (PowerShell)
  • 상세 모드: Ctrl+O로 사고 출력 확인

깊은 추론이 필요한 복잡한 작업:

  1. 확장 사고가 활성화되어 있는지 확인 (기본 활성)
  2. 구조적 접근을 위해 계획 모드 활성화
  3. 철저한 분석을 위해 여러 라운드의 비판 수행
  4. 다양한 관점을 위해 역할 분리 서브에이전트 사용

빌드 문제 해결

빌드 실패 시:

  1. build-error-resolver 에이전트 사용
  2. 에러 메시지 분석
  3. 점진적으로 수정
  4. 각 수정 후 검증