Claude Code가 macOS 27의 온디바이스 모델로 대용량 요약 작업을 넘기도록 설정하기
I had Claude Code hand off big summarizing jobs to the on-device model in macOS 27
핵심 요약
macOS 27의 'fm' 도구를 활용해 Claude Code의 토큰 사용량을 줄이고 로컬에서 대용량 텍스트를 요약하는 방법입니다.
- 온디바이스 요약 — macOS 27의 fm 도구를 사용하여 Claude Code의 토큰 비용을 절감함
- 스킬 설정 — 대용량 텍스트를 로컬 모델로 요약하고 Claude가 이를 참조하도록 구성함
- 성능 한계 — 로컬 모델의 컨텍스트 윈도우 제한과 판단력 부족을 고려하여 설계됨
- 검증 절차 — 요약의 정확성을 보장하기 위해 원본과 비교하는 검증 단계를 포함함
macOS 27에는 애플의 온디바이스 파운데이션 모델을 위한 커맨드라인 도구인 fm이 포함되어 있어. 나는 이걸 써서 세션 기록, 로그, 긴 문서 같은 방대한 텍스트를 처리할 때 Claude Code의 토큰 사용량을 줄이고 있지. 로컬 모델이 요약을 작성하면 Claude는 원문 대신 그 요약본을 읽는 방식이야. 전부 맥 내부에서 돌아가니까 외부로 데이터가 나갈 일도 없어.
Claude Code가 이 기능을 구현하도록 내가 쓴 프롬프트를 공유할게. 먼저 fm을 직접 테스트해보면서 성능을 측정했고, 그 결과를 프롬프트에 녹여냈어. 그래야 작은 모델이 뭘 잘하고 어디서 뻗는지 모델이 정확히 파악하거든.
먼저 설정부터 하자. macOS 27이 필요하고, 터미널에서 sudo fm license를 한 번 실행해서 애플 약관에 동의해야 해(이거 안 하면 다른 fm 명령어는 그냥 다 튕겨). 그 다음 fm available을 쳤을 때 "System model available"이라고 뜨면 성공이야.
이 내용을 Claude Code에 붙여넣어:
Create a user-level Claude Code skill named "on-device-summarize" at ~/.claude/skills/on-device-summarize/SKILL.md that tells Claude when and how to use Apple's on-device language model (the "fm" command-line tool) to summarize text instead of reading it with Claude tokens. User wants this to save Claude tokens where doing so costs no accuracy. Before writing, confirm the current skill file format (frontmatter fields, how the description triggers the skill) in the Claude Code documentation; use the claude-code-guide agent. Put "effort:" in the frontmatter only if needed (on most models, an effort change reloads the prompt cache). Never put "model:" in it: a skill that names a different model is a model switch, and the next request re-reads the whole conversation with no cache hits.
Intent
- Use the on-device model to compress large volumes of text (session transcripts, logs, long documents, exports) into short summaries that Claude then reads, when the raw text would cost many Claude tokens and a faithful summary is enough for the task.
- Do not use it where the answer needs judgment across many documents, exact values, or a decision. Claude does that part, reading the summaries plus the authoritative sources.
- Accuracy outranks token savings (User's priority order: accuracy, reliability, CPU, memory, time, tokens). When unsure whether a summary is faithful enough, check a sample against the source before relying on the rest.
Tool facts (measured on the Mac, 2026-10-01; re-measure if macOS changes)
- Binary: /usr/bin/fm ("Apple Foundation Models CLI"). "fm available" prints "System model available" when it is usable. Commands: available, chat, count-tokens, license, respond, schema, serve. Read "fm <command> --help" for options; strip ANSI color codes from its output.

