Claude Code의 화면과 모델 요청, 세션 사이의 메시지는 셸 스크립트 훅으로 수정할 수 없었지만 mod에서는 TypeScript 함수 몇 개로 수정할 수 있습니다. 다른 세션에 계획을 넘기고 결과를 돌려받는 릴레이, 채팅 옆에 비용과 도구 호출 현황을 표시하는 대시보드, 규칙에 맞는 요청만 다른 모델로 보내는 라우터를 각각 mod로 만들었습니다. 세 mod를 Claude Code 2.1.333에서 직접 테스트해 보았고 모두 동작했습니다. 계획을 넘긴 뒤 실행 결과가 돌아오기까지 13.5초가 걸렸습니다. 하지만 mod는 샌드박스 없이 사용자 권한으로 실행되는 코드이고 요청을 다른 모델로 처음 넘기는 턴에서는 그 모델의 프롬프트 캐시를 새로 써야 합니다.Shell-script hooks could not change the interface of Claude Code, the requests it sends to the model, or the messages between sessions, and a mod changes all three with a few TypeScript functions. I built three mods and tested them on Claude Code 2.1.333: a relay that hands a plan to another session and gets the result back, a dashboard beside the chat that shows cost and tool calls, and a router that sends only matching requests to another model. All three worked, and the result came back 13.5 seconds after the plan was handed off. A mod is still code that runs with your permissions and without a sandbox, and the first turn routed to another model has to write that model's prompt cache.
claude --plugin-dir로 설치 없이 한 세션에만 로드해 볼 수 있습니다.Structure: A mod is a plugin of functions (hooks) that run on events, on by default since 2.1.287. claude --plugin-dir loads one for a single session without installing it.$.session.send 한 번으로 다른 세션의 턴이 시작됩니다. 받은 세션은 자기 권한 설정 안에서만 동작하므로 실행 세션의 권한 모드를 먼저 정합니다.Session relay: One $.session.send starts a turn in another session. The receiver acts only within its own permission settings, so decide the executor's permission mode first.turn.step에서 model만 바꾸면 그 요청이 다른 모델로 갑니다. 처음 넘긴 턴에서 캐시 쓰기가 27,923토큰 생겼으므로 같은 종류의 요청이 반복될 때 사용합니다.Model routing: Changing only model at turn.step sends that request to another model. The first routed turn wrote 27,923 tokens to the cache, so use it where the same kind of request repeats.claude plugin validate로 연결된 이벤트와 호출 목록을 확인합니다.Trust: A mod runs with your permissions. Before installing one, list the events it hooks and the calls it makes with claude plugin validate.Claude Code를 작업 방식에 맞추는 수단은 그동안 설정 파일, 셸 스크립트 훅, 스킬, MCP 서버였고 모두 Claude Code 바깥에서 동작했습니다. 2.1.287부터는 Claude Code 안에서 실행되는 함수로 화면과 동작을 수정하는 mod가 기본으로 활성화되어 있습니다.
mod는 바깥의 스크립트가 닿지 못하던 세 곳을 수정합니다. 채팅 옆 화면, 모델에 보내는 요청, 세션 사이의 메시지입니다. 그래서 손으로 하던 일을 코드에 맡길 수 있습니다. 터미널 두 개 사이에서 계획을 복사해 붙이는 일, 비용과 컨텍스트를 보려고 /usage와 /context를 번갈아 입력하는 일, 짧은 질문 하나 때문에 /model을 바꿨다가 되돌리는 일입니다. 하지만 mod는 샌드박스 없이 사용자 권한으로 실행되므로 직접 작성했거나 코드를 읽어 본 mod만 사용해야 합니다.
세 곳을 하나씩 수정하는 mod 세 개를 직접 만들어 테스트했습니다. 세션 릴레이(session-relay)는 계획을 세운 세션이 다른 세션에 계획을 넘기고 결과를 돌려받게 합니다. 대시보드(hud-dashboard)는 채팅 옆 패널에 비용, 컨텍스트, 에이전트, 도구 호출 현황을 표시합니다. 모델 라우터(model-router)는 규칙에 맞는 프롬프트의 턴만 다른 모델로 보냅니다. 그림 1은 세 mod가 Claude Code의 어느 이벤트에 연결되는지와 테스트 환경을 보여 줍니다.

남은 것은 세 mod가 실제 세션에서 어떻게 동작했고 어느 지점이 문서나 예상과 달랐는가입니다.
01
mod는 이벤트를 처리하는 함수를 담은 플러그인입니다. 공식 문서는 이 함수를 훅(hook)이라고 부르고 설정 파일에 등록하는 기존 훅은 설정 훅(settings hook)이라고 구분합니다. 작은 mod는 파일 세 개로 구성되고 테스트 파일을 더할 수 있습니다.
model-router/
├── .claude-plugin/
│ └── plugin.json # 이름, 버전, 설명
├── hooks/
│ ├── hooks.json # { "modules": ["./register.ts"] }
│ └── register.ts # 훅을 등록하는 코드
└── tests/
└── router.test.ts # claude plugin test가 실행하는 테스트register.ts는 register(on) 함수를 내보내고 on(이벤트, 훅)으로 훅을 등록합니다. 훅은 인자 세 개를 받습니다. $는 Claude Code의 기능을 호출하는 mod API이고 e는 이벤트의 입력이며 next는 다음 처리로 넘기는 함수입니다. next(e)를 그대로 호출하면 이벤트를 지켜보기만 합니다. next({ ...e, model })처럼 값을 바꿔 호출하면 이벤트를 수정합니다. next를 호출하지 않고 값을 돌려주면 훅이 그 이벤트를 대신 처리합니다.
개발하는 동안에는 mod를 설치하지 않고 명령 세 개를 사용했습니다.
claude plugin validate ./model-router # 연결된 이벤트와 호출 목록, 타입 검사
claude plugin test ./model-router # tests 폴더의 테스트 실행
claude --plugin-dir ./model-router # 이 세션에만 mod 로드claude plugin validate는 mod를 실행하지 않고 어떤 이벤트에 연결되고 무엇을 호출하는지 출력합니다. TypeScript 타입 오류도 함께 알려 주어서 세 mod를 만드는 동안 오류 네 건을 이 출력에서 찾아 수정했습니다. claude plugin test는 세션과 로그인 없이 테스트 파일을 실행합니다. model-router에 두 명령을 실행한 출력의 일부를 옮겼습니다.
$ claude plugin validate ./model-router
❯ ./register.ts hooks: session.start, prompt.submit, turn.start, turn.step, turn.complete, command.run{command=route}
❯ ./register.ts calls: $.command.register, $.ui.log, $.ui.status
✔ Validation passed with warnings
$ claude plugin test ./model-router
tests/router.test.ts:
(pass) a matching prompt is sent to another model for that turn only [39.03ms]
(pass) a slash command and a peer message keep the session model [16.39ms]
2 pass
0 fail경고는 plugin.json에 저자 정보가 없다는 것과 플러그인 디렉터리에 제출할 때 필요한 README, 라이선스, 아이콘이 없다는 내용이었습니다. 세 mod의 테스트는 모두 5건이고 전부 통과했습니다. 코드를 직접 쓰지 않고 Claude에게 원하는 동작을 설명해 mod를 만들게 하는 방법도 있으며 절차는 공식 문서의 Create a mod에 있습니다.
02
Claude Code 세션은 2.1.224부터 같은 사용자의 다른 세션에 메시지를 보낼 수 있습니다. 보통은 Claude가 SendMessage 도구로 보내지만 mod도 $.session.send로 같은 전달을 합니다. session-relay는 이 호출을 명령 하나에 연결했습니다. 계획 세션이 작성한 마지막 답변을 실행 세션에 넘기고 실행 세션의 최종 답변을 계획 세션으로 돌려보냅니다.

훅은 세 개입니다. /handoff 명령의 훅은 마지막 답변을 찾아 보냅니다. session.receive 훅은 계획이 도착하면 회신할 세션 ID를 기록합니다. turn.complete 훅은 그 턴의 최종 답변을 기록해 둔 세션으로 보냅니다. 코드는 111줄인 register.ts에서 명령 등록, 상태 표시, 디버그 로그를 빼고 간추렸습니다.
import type { Register } from 'claude-code'
// 넘기는 메시지의 첫 줄. 보낸 세션의 ID를 담아 회신 주소로 사용한다.
// 문자열 처음에 고정하지 않는다(이유는 아래 "처음에는 보고가 돌아오지 않았습니다").
const PLAN = /\[relay:plan #(\d+) from=([0-9a-f-]{36})\]/
const ASK =
'This is a plan from the planning session. Carry it out in this folder, ' +
'then answer with what you changed and how you checked it.'
export const register: Register = on => {
let sent = 0
// 계획이 도착하면 기록하고, 답변을 돌려보낸 뒤 비운다.
let owed: { number: string; replyTo: string } | undefined
on('command.run', { command: 'handoff' }, async ($, e) => {
const [to, ...extra] = e.args.trim().split(/\s+/)
const rows = await $.session.messages({ last: 12 })
if (to === undefined || to === '' || 'deny' in rows) {
return { text: 'Usage: /handoff <session name>' }
}
// 마지막 답변(계획)을 찾는다.
const plan = rows.findLast(row => row.role === 'assistant' && row.text.trim() !== '')
if (plan === undefined) {
return { text: 'There is no answer to hand off yet.' }
}
const number = sent + 1
const text = [
`[relay:plan #${number} from=${await $.session.id()}]`,
[ASK, ...extra].join(' '),
'',
plan.text,
].join('\n')
const result = await $.session.send({ to, text })
if (!result.isDelivered) {
return { text: `Not delivered to ${to}: ${result.reason}` }
}
sent = number
return { text: `Plan #${number} (${plan.text.length} characters) is queued at ${to}.` }
})
// 다른 세션의 Claude나 mod가 보낸 메시지가 도착했을 때
on('session.receive', { origin: { kind: 'peer' } }, ($, e, next) => {
const plan = PLAN.exec(e.text)
if (plan !== null) {
owed = { number: plan[1] ?? '?', replyTo: plan[2] ?? '' }
}
return next(e)
})
// 계획을 실행한 턴이 끝났을 때: 그 턴의 답변이 보고가 된다.
on('turn.complete', async ($, e, next) => {
const done = await next(e)
if (e.agentId !== undefined || owed === undefined || e.reason !== 'answer') {
return done
}
const { number, replyTo } = owed
owed = undefined
await $.session.send({
to: { sessionId: replyTo },
text: `[relay:report #${number} from=${await $.session.id()}]\n${e.answer}`,
})
return done
})
}두 세션을 같은 폴더에서 이름을 붙여 실행했습니다. 계획 세션의 모델은 Sonnet 5.5, 실행 세션의 모델은 Haiku 5.5입니다.
# 터미널 1: 실행 세션
claude --plugin-dir ./session-relay --model haiku -n lab-executor \
--setting-sources project,local --debug-file executor.debug.log
# 터미널 2: 계획 세션
claude --plugin-dir ./session-relay --model sonnet -n lab-planner \
--setting-sources project,local --debug-file planner.debug.log계획 세션에 slugify 함수가 한글 제목에서 빈 문자열을 돌려주니 코드는 수정하지 말고 계획만 세워 달라고 요청한 뒤 /handoff lab-executor를 실행했습니다. 두 세션의 화면과 실행 세션의 디버그 로그에서 해당 줄을 옮겼고 세션 ID는 앞 여덟 자리만 남겼습니다.
# lab-planner 화면
❯ /handoff lab-executor
⎿ session-relay: Plan #1 (755 characters) is queued at lab-executor.
# lab-executor 화면
› Message from @lab-planner: [relay:plan #1 from=84d6e560-...] (ctrl+o to expand)
# lab-executor 디버그 로그 (UTC)
16:24:27.493Z [session-relay] $.ui.log (to debug): plan #1 received from session 84d6e560-...
16:24:40.990Z [session-relay] $.ui.log (to debug): report #1 to 84d6e560-...: queued
# lab-planner 화면
› Message from @lab-executor: [relay:report #1 from=3908f491-...] (ctrl+o to expand)
● lab-executor 세션이 계획 네 단계를 모두 처리했다고 보고했습니다. 이 세션에서는 직접 확인하지
않았고 보고 내용만 옮깁니다.실행 세션은 유휴 상태였고 메시지가 도착하자 새 턴이 시작됐습니다. 도구를 6회 호출해 src/slugify.py와 테스트, README를 수정했고 수정 전에는 테스트 5개 중 3개가 실패하고 수정 후에는 5개가 통과했다고 답했습니다. 테스트가 끝난 뒤 같은 폴더에서 테스트를 다시 실행해 다섯 개가 모두 통과하는 것을 확인했습니다. 계획을 보낸 뒤 보고가 돌아오기까지 13.5초, 계획 세션이 보고를 요약하기까지 3.2초가 더 걸렸습니다. 계획 세션은 보고를 그대로 받아들이지 않고 직접 확인하지 않았다는 점을 답변에 밝혔습니다.
첫 시도에서는 실행 세션이 계획을 실행하고도 보고를 보내지 않았습니다. session.receive 훅이 받는 e.text가 보낸 본문 그대로일 것으로 예상하고 정규식을 문자열 처음에 고정했는데 실제 값은 모델이 읽는 형태였습니다. 실행 세션의 대화 기록 파일에 남은 메시지의 앞부분을 옮겼습니다.
Another Claude session sent a message:
<cross-session-message from="uds:/tmp/cc-socks/<pid>.sock" from-name="lab-planner" from-mode="prompting" from-plugin="session-relay">
[relay:plan #1 from=e4cc827e-...]
This is a plan from the planning session. Carry it out in this folder, then answer with what you changed and how you checked it.본문 앞에 보낸 세션의 주소와 이름, 권한 모드, 보낸 mod의 이름을 담은 봉투가 추가됩니다. 정규식의 위치 고정을 없앤 뒤 왕복이 완료됐습니다. 타입 선언 파일의 주석에는 e.text가 모델이 읽게 될 본문이라고 적혀 있습니다.
공식 문서는 다른 세션의 메시지가 사용자의 승인으로 취급되지 않고 메시지가 요구하는 작업에도 받은 세션의 권한 확인이 그대로 적용된다고 안내합니다. 이번 테스트에서 두 세션은 모두 auto 모드였고 실행 세션의 도구 호출 6회에는 화면에 Allowed by auto mode가 표시됐습니다. 실행 세션을 어느 권한 모드로 시작하는지가 사람 없이 진행되는 범위를 정합니다.
문서는 받은 메시지에 적힌 보낸 이의 이름을 판단의 근거로 삼지 말라고도 안내합니다. 보낸 쪽이 적은 값이기 때문입니다. session-relay가 본문에 넣는 세션 ID도 같은 성격이어서 회신 주소로만 사용했습니다. 받는 이는 mods API 문서에 따르면 { sessionId }, { agentId }, 받은 메시지의 주소로 지정합니다. /handoff는 세션 이름을 그대로 넘겼고 이 테스트에서는 전달됐습니다. 이름을 받는다는 설명은 타입 선언 파일에만 있습니다.
03
Claude Code의 상태 표시줄은 셸 스크립트의 출력을 프롬프트 아래에 표시합니다. mod의 패널(pane)은 ui.render 훅이 돌려준 요소 트리를 Claude Code가 그리는 영역이고 훅이 모은 값이 바뀌면 다시 그려집니다. hud-dashboard는 세션이 시작될 때와 /hud 명령에서 패널을 열고 세션 현황을 열두 줄 안팎으로 표시합니다.

그림 3은 테스트 파일에 테스트를 추가하고 서브에이전트 하나로 폴더를 조사하게 한 요청이 진행되는 동안의 화면입니다. 오른쪽이 mod가 그린 패널이고 아래쪽 여러 줄은 원래 사용하던 상태 표시줄입니다. 패널의 각 줄이 값을 읽는 곳은 표 1과 같습니다.
| 줄 | 값을 읽는 곳 | 그림 3에 표시된 값 |
|---|---|---|
| SESSION | $.session.version(), $.session.model(), $.session.turns() | v2.1.333, claude-sonnet-5-5, turn 1 |
| COST | $.session.usage()의 cost | $0.4038 |
| CONTEXT | $.session.usage()의 context | 9%, 90k / 1000k |
| LIMITS | $.session.usage()의 rateLimits | none reported |
| AGENTS | $.agent.list() | 1 running (Explore, 43k tok) |
| TOOL CALLS | tool.call 훅이 직접 집계 | 7 done, 1 failed |
| TOOLS | $.tool.list() | 596 (built-in 38, MCP 558) |
| COMMANDS | $.command.list() | 433 (built-in 117, plugin 278, user 36, MCP 2) |
| PLUGINS | $.settings.read({ key: 'enabledPlugins' }) | 37 enabled |
| REPO | $.session.repo() | my-project |
| MEMO | /memo 명령과 $.store | 1건 |
표 1. 패널의 줄과 값을 읽는 mod API, 그림 3 시점의 값. 사용자 설정 전체를 불러온 세션에서 1회 실행했습니다
값을 기록하는 훅과 그리는 훅을 나눈 구조입니다. tool.call 훅은 호출 수를 $.state에 기록하고 ui.render 훅은 그 값을 읽어 줄을 만듭니다. 그리는 동안 읽은 값이 나중에 기록되면 Claude Code가 그 패널을 다시 그리므로 다시 그리라는 호출을 따로 하지 않았습니다. 코드는 302줄인 register.tsx에서 이 구조에 해당하는 부분만 간추렸습니다.
import { atom, read, update } from 'claude-code'
const PANE = 'hud'
const NO_CALLS = { total: 0, running: 0, failed: 0, byTool: {}, last: [] }
// $.state에 두는 값. 코드를 다시 불러와도 세션 동안 유지된다.
const calls = atom({ plugin: 'hud-dashboard', key: 'calls' } as const, NO_CALLS)
// 도구 호출마다: 시작할 때 실행 중 수를 올리고, 끝나면 집계한다.
on('tool.call', async ($, e, next) => {
const startedAt = await $.clock.now()
await update($, calls, now => ({ ...now, running: now.running + 1 }))
const ran = await next(e)
const ms = (await $.clock.now()) - startedAt
const isOk = ran.deny === undefined && ran.isError !== true
await update($, calls, now => ({
total: now.total + 1,
running: Math.max(0, now.running - 1),
failed: now.failed + (isOk ? 0 : 1),
byTool: { ...now.byTool, [e.tool]: (now.byTool[e.tool] ?? 0) + 1 },
last: [...now.last, { tool: String(e.tool), ms, isOk }].slice(-5),
}))
return ran
})
// 패널을 그릴 때: 읽기만 한다. 요소는 그리는 화면의 표에서 받는다.
on('ui.render', { component: 'Pane', requestId: PANE }, async ($, e) => {
const { Box, Text } = $.ui.resolve(e)
const tally = await read($, calls)
return (
<Box flexDirection="column" width={e.props.bodyColumns}>
<Box>
<Text dimColor>{'TOOL CALLS'.padEnd(11)}</Text>
<Text>
{tally.total} done · {tally.running} running ·{' '}
<Text color={tally.failed > 0 ? 'error' : undefined}>{tally.failed} failed</Text>
</Text>
</Box>
{/* SESSION, COST, CONTEXT 같은 나머지 줄도 같은 방식으로 만든다 */}
</Box>
)
})패널을 채팅 옆에 붙이기 위해 전체 화면 렌더링으로 세션을 시작했고 메모 하나를 남긴 뒤 작업을 요청했습니다.
CLAUDE_CODE_NO_FLICKER=1 claude --plugin-dir ./hud-dashboard --model sonnet -n hud-lab
# 세션 안에서
/memo rerun pytest before opening the PR/tui fullscreen이나 CLAUDE_CODE_NO_FLICKER=1로 활성화합니다. mod가 스스로 여는 패널은 폭이 144칸 이상인 터미널에서만 나타난다고 문서가 안내하며 테스트 터미널은 170칸이었습니다.$.session.repo()의 name은 값이 없었습니다. 타입 선언 파일에 따르면 빌드가 알고 있는 저장소에만 값이 들어가므로 root의 마지막 폴더 이름을 표시했습니다./memo 명령의 출력은 대화에 남아 모델도 읽었습니다. 그림 3의 답변 끝에서 Claude가 메모 내용을 언급합니다. 타입 선언 파일에는 출력을 화면에만 표시하는 isTextDisplayOnly 필드가 있고 이 필드는 테스트하지 않았습니다.04
turn.step 이벤트는 Claude Code가 모델에 요청 하나를 보내기 직전에 발생하고 훅이 next({ ...e, model })을 호출하면 그 요청만 다른 모델로 갑니다. model-router는 프롬프트가 제출될 때 규칙을 확인해 두었다가 그 턴의 요청에만 모델을 바꿉니다. 세션의 모델 설정은 바꾸지 않으므로 다음 턴은 원래 모델로 돌아갑니다.
규칙은 네 개를 넣었습니다. ?로 시작하는 프롬프트와 "번역", "커밋 메시지"가 들어간 프롬프트는 haiku로, !!로 시작하는 프롬프트는 opus로 보냅니다. 앞에 붙인 표시는 모델이 읽기 전에 지웁니다. 테스트한 규칙은 ?와 "번역" 두 가지입니다. 코드는 142줄인 register.ts에서 규칙 두 개와 훅 세 개만 남겨 간추렸습니다.
const RULES = [
{ name: 'quick', model: 'haiku', test: /^\?\s*/, strip: /^\?\s*/ },
{ name: 'translate', model: 'haiku', test: /번역|translate/i },
]
// 방금 제출된 프롬프트의 경로. 그 턴이 시작될 때까지만 둔다.
let pending: { rule: string; model: string } | undefined
// 실행 중인 턴의 경로. 턴 ID로 찾는다.
const routes = new Map<string, { rule: string; model: string }>()
on('prompt.submit', ($, e, next) => {
// 사람이 입력한 프롬프트만 대상이다. 슬래시 명령, 다른 세션의 메시지,
// 알림은 세션의 모델을 그대로 사용한다.
const isTyped = e.origin.kind === 'composer' || e.origin.kind === 'sdk'
if (!isTyped || e.command !== undefined || e.isMeta === true) {
return next(e)
}
const rule = RULES.find(one => one.test.test(e.text))
if (rule === undefined) {
pending = undefined
return next(e)
}
pending = { rule: rule.name, model: rule.model }
const text = rule.strip === undefined ? e.text : e.text.replace(rule.strip, '')
return next({ ...e, text })
})
on('turn.start', async ($, e, next) => {
const started = await next(e)
// 서브에이전트의 턴은 자기 모델을 유지한다. 메인 대화만 바꾼다.
if (e.agentId === undefined && pending !== undefined) {
routes.set(started.turnId, pending)
pending = undefined
}
return started
})
// turn.step은 응답이 스트리밍되므로 훅을 비동기 제너레이터로 작성한다.
on('turn.step', async function* ($, e, next) {
const route = e.agentId === undefined ? routes.get(e.turnId) : undefined
if (route === undefined) {
return yield* next(e)
}
// 이 요청만 다른 모델로 보낸다. 결과의 usage에 답한 모델과 토큰 수가 있다.
return yield* next({ ...e, model: route.model })
})yield* next(...)는 응답을 화면으로 전달하면서 요청이 끝난 뒤의 결과를 돌려줍니다. 공식 문서는 2.1.309 이전 버전에서 haiku 같은 별칭이 그대로 전송되어 모델 오류가 났다고 안내합니다. 세션 모델을 Sonnet 5.5로 두고 일반 프롬프트, ? 프롬프트 두 번, 번역 요청, 다시 일반 프롬프트 순서로 다섯 턴을 실행했습니다.
$ claude --plugin-dir ./model-router --model sonnet -n router-lab --setting-sources project,local
❯ 방금 본 함수에 쓰인 정규식만 한 줄로 다시 알려 주세요.
● r"[a-z0-9]+"
● model-router: router: quick → claude-haiku-5-5, 1 step(s), input 4, cache read 28941, cache write 27923, output 16화면의 프롬프트에는 입력한 ?가 없습니다. 훅이 지운 뒤의 글이 대화에 남기 때문입니다. 표 2는 다섯 턴의 대화 기록 파일에서 읽은 모델과 토큰 수입니다.
| 턴 | 프롬프트 | 규칙 | 답한 모델 | 캐시 읽기 | 캐시 쓰기 | 출력 |
|---|---|---|---|---|---|---|
| 1 | 파일을 읽고 한 문장으로 설명 | 없음 | claude-sonnet-5-5 | 40,411 56,530 | 16,119 188 | 89 109 |
| 2 | ? 정규식만 한 줄로 | quick | claude-haiku-5-5 | 28,941 | 27,923 | 16 |
| 3 | ? slugify('A B')의 결과 | quick | claude-haiku-5-5 | 56,864 | 39 | 7 |
| 4 | docstring을 한국어로 번역 | translate | claude-haiku-5-5 | 56,903 | 47 | 70 |
| 5 | 지금까지의 답을 두 문장으로 정리 | 없음 | claude-sonnet-5-5 | 57,020 | 29 | 201 |
표 2. 턴별 답한 모델과 토큰 수. 2회 실행 가운데 두 번째 실행의 값이고 1번 턴은 모델 요청이 2회여서 두 줄입니다
세 턴이 규칙대로 Haiku 5.5로 갔고 5번 턴은 Sonnet 5.5로 돌아왔습니다. 확인할 값은 2번 턴의 캐시 쓰기입니다. 프롬프트 캐시 문서는 모델마다 캐시가 따로 있어 모델을 바꾸면 같은 내용이라도 요청 전체를 다시 계산한다고 안내합니다. Haiku로 처음 넘긴 2번 턴에서 27,923토큰을 캐시에 썼고 같은 모델로 넘긴 3번과 4번 턴은 쓰기가 50토큰 미만이었습니다. 첫 번째 실행에서는 이 값이 30,075토큰이었습니다.
문서의 설명과 다른 점도 있었습니다. 문서대로라면 2번 턴에는 캐시 적중이 없어야 하지만 28,941토큰을 캐시에서 읽었습니다. 몇 분 전에 같은 환경에서 Haiku 세션을 실행했으므로 세션마다 같은 앞부분(시스템 프롬프트와 도구 정의)이 Haiku의 캐시에 남아 있었던 것으로 추정합니다. 추정이 맞다면 Haiku를 처음 호출하는 환경에서는 쓰기가 더 커집니다. 5번 턴은 Sonnet의 캐시에서 57,020토큰을 읽었습니다. Haiku로 세 턴을 보낸 30초가량의 시간 동안 Sonnet의 캐시는 유지됐습니다.
따라서 한 대화에서 한두 번만 넘기는 요청은 첫 캐시 쓰기 때문에 이득이 작고 같은 종류의 요청이 반복될 때 넘기는 효과가 생깁니다. 금액으로는 계산하지 않았습니다.
05
mod는 Claude Code 안에서 사용자 권한으로 실행되는 코드입니다. 공식 문서는 mod가 사용자 계정으로 파일을 읽고 쓰고 프로그램을 실행하며 샌드박스가 적용되지 않는다고 안내합니다. 다른 사람이 만든 mod는 설치하기 전에 claude plugin validate의 hooks와 calls 줄을 읽습니다. session-relay의 출력에서는 이 mod가 대화 기록을 읽고 다른 세션으로 메시지를 보낸다는 것이 드러납니다.
❯ ./register.ts hooks: session.start, command.run{command=handoff}, session.receive{origin has {kind=peer}}, turn.complete
❯ ./register.ts calls: $.command.register, $.session.id, $.session.messages, $.session.send, $.ui.log, $.ui.status--plugin-dir로 로드한 mod는 설치되지 않으므로 세션을 종료하면 남지 않습니다. 대시보드의 메모만 $.store에 남아 다음 세션에도 보이므로 /memo clear로 지웁니다. 설치한 mod는 /plugin의 Installed 탭에서 비활성화합니다. 한 세션에서 설치한 mod를 모두 제외하려면 --safe-mode로 시작하며 이때 다른 사용자 설정도 함께 비활성화됩니다.
| mod | 활용할 만한 경우 | 맞지 않는 경우 |
|---|---|---|
| session-relay | 계획과 실행을 서로 다른 모델이나 폴더의 세션으로 나누고 실행 세션의 권한을 미리 좁혀 둔 경우 | 권한 확인 없이 진행되면 안 되는 저장소의 실행 세션을 auto 모드로 두는 경우. 두 세션이 서로 계속 답하게 만드는 구성 |
| hud-dashboard | 서브에이전트와 도구 호출이 많은 긴 작업, 전체 화면 렌더링을 사용하는 넓은 터미널 | 폭이 좁은 터미널, 상태 표시줄로 충분한 경우 |
| model-router | 번역이나 단순 질문처럼 같은 종류의 짧은 요청이 한 대화에서 반복되는 경우 | 한두 번만 넘기는 짧은 대화. 넘길 모델의 컨텍스트 한도보다 긴 대화(테스트하지 않음) |
표 3. 테스트 결과로 정리한 mod별 적용 기준
세션 사이의 왕복을 자동으로 이어 붙일 때에는 횟수를 제한합니다. 공식 문서는 두 세션이 느리게 서로 답하면 사용자의 입력 없이 수천 번의 메시지가 오갈 수 있고 전달된 메시지마다 사용량에 포함된다고 안내합니다. session-relay는 계획 하나에 보고를 한 번만 보내고 보고에는 자동으로 답하지 않습니다.
테스트하지 못한 항목은 Desktop 앱과 VS Code 확장의 화면 표시, 다른 컴퓨터의 세션으로 보내는 메시지, opus로 넘기는 규칙, 조직이 mod를 제한하는 환경입니다. 세션 왕복과 대시보드는 1회, 모델 전환은 2회만 실행했습니다. 타입 선언 파일의 머리말에는 이 API가 릴리스 사이에 예고 없이 바뀔 수 있다고 적혀 있으므로 버전을 올린 뒤에는 claude plugin validate와 claude plugin test를 다시 실행합니다.
Until now, the ways to fit Claude Code to how you work were settings files, shell-script hooks, skills and MCP servers, and all of them work from outside Claude Code. Since 2.1.287, mods are on by default: functions that run inside Claude Code and change how it looks and behaves.
A mod changes three places that an outside script could not reach: the screen beside the chat, the requests sent to the model, and the messages between sessions. So code can take over things done by hand: copying a plan from one terminal to another, typing /usage and /context in turn to see cost and context, and switching /model for one short question and switching it back. A mod also runs with your permissions and without a sandbox, so use only mods you wrote or whose code you have read.
I built and tested three mods, one for each of those places. The session relay (session-relay) lets the session that wrote a plan hand it to another session and get the result back. The dashboard (hud-dashboard) shows cost, context, agents and tool calls in a pane beside the chat. The model router (model-router) sends only the turn of a matching prompt to another model. Figure 1 shows which Claude Code events the three mods hook, and the test environment.

What remains is how the three mods behaved in real sessions and where they differed from the documentation or from what I expected.
01
A mod is a plugin that holds functions that handle events. The official documentation calls such a function a hook and calls the older kind, registered in a settings file, a settings hook. A small mod is three files, and test files can be added.
model-router/
├── .claude-plugin/
│ └── plugin.json # name, version, description
├── hooks/
│ ├── hooks.json # { "modules": ["./register.ts"] }
│ └── register.ts # the code that registers the hooks
└── tests/
└── router.test.ts # the tests claude plugin test runsregister.ts exports a register(on) function and registers each hook with on(event, hook). A hook receives three arguments: $ is the mods API that calls into Claude Code, e is the event's input, and next passes the event on. Calling next(e) unchanged only observes the event. Calling it with a changed value, as in next({ ...e, model }), rewrites the event. Returning a value without calling next makes the hook answer the event itself.
During development I used three commands and installed nothing.
claude plugin validate ./model-router # hooked events, calls, and a type check
claude plugin test ./model-router # runs the tests in the tests folder
claude --plugin-dir ./model-router # loads the mod for this session onlyclaude plugin validate prints which events a mod hooks and what it calls, without running it. It also reports TypeScript type errors, and I found and fixed four errors from that output while building the three mods. claude plugin test runs the test files with no session and no sign-in. These lines are from the output of the two commands for model-router.
$ claude plugin validate ./model-router
❯ ./register.ts hooks: session.start, prompt.submit, turn.start, turn.step, turn.complete, command.run{command=route}
❯ ./register.ts calls: $.command.register, $.ui.log, $.ui.status
✔ Validation passed with warnings
$ claude plugin test ./model-router
tests/router.test.ts:
(pass) a matching prompt is sent to another model for that turn only [39.03ms]
(pass) a slash command and a peer message keep the session model [16.39ms]
2 pass
0 failThe warnings said that plugin.json names no author and that the README, license and icon a submission to the plugin directory needs are missing. The three mods have 5 tests in all, and all of them passed. You can also describe what you want and have Claude write the mod; the steps are in Create a mod in the official documentation.
02
Since 2.1.224, a Claude Code session can send a message to another session of the same user. Usually Claude sends it with the SendMessage tool, and a mod makes the same delivery with $.session.send. session-relay ties that call to one command. It hands the last answer of the planning session to the executing session and sends the executing session's final answer back to the planning session.

There are three hooks. The hook of the /handoff command finds the last answer and sends it. The session.receive hook records the session id to reply to when a plan arrives. The turn.complete hook sends the final answer of that turn to the recorded session. This is the 111-line register.ts, condensed by leaving out the command registration, the status line and the debug log.
import type { Register } from 'claude-code'
// The first line of a relayed message. It carries the sender's session id,
// which is the address the answer goes back to. Not anchored at the start
// (see "At first the report did not come back" below).
const PLAN = /\[relay:plan #(\d+) from=([0-9a-f-]{36})\]/
const ASK =
'This is a plan from the planning session. Carry it out in this folder, ' +
'then answer with what you changed and how you checked it.'
export const register: Register = on => {
let sent = 0
// Set when a plan arrives, cleared when its answer has been sent back.
let owed: { number: string; replyTo: string } | undefined
on('command.run', { command: 'handoff' }, async ($, e) => {
const [to, ...extra] = e.args.trim().split(/\s+/)
const rows = await $.session.messages({ last: 12 })
if (to === undefined || to === '' || 'deny' in rows) {
return { text: 'Usage: /handoff <session name>' }
}
// Find the last answer (the plan).
const plan = rows.findLast(row => row.role === 'assistant' && row.text.trim() !== '')
if (plan === undefined) {
return { text: 'There is no answer to hand off yet.' }
}
const number = sent + 1
const text = [
`[relay:plan #${number} from=${await $.session.id()}]`,
[ASK, ...extra].join(' '),
'',
plan.text,
].join('\n')
const result = await $.session.send({ to, text })
if (!result.isDelivered) {
return { text: `Not delivered to ${to}: ${result.reason}` }
}
sent = number
return { text: `Plan #${number} (${plan.text.length} characters) is queued at ${to}.` }
})
// A message another session's Claude or mod sent to this one.
on('session.receive', { origin: { kind: 'peer' } }, ($, e, next) => {
const plan = PLAN.exec(e.text)
if (plan !== null) {
owed = { number: plan[1] ?? '?', replyTo: plan[2] ?? '' }
}
return next(e)
})
// The turn that carried the plan out has ended: its answer is the report.
on('turn.complete', async ($, e, next) => {
const done = await next(e)
if (e.agentId !== undefined || owed === undefined || e.reason !== 'answer') {
return done
}
const { number, replyTo } = owed
owed = undefined
await $.session.send({
to: { sessionId: replyTo },
text: `[relay:report #${number} from=${await $.session.id()}]\n${e.answer}`,
})
return done
})
}I started two named sessions in the same folder. The planning session ran on Sonnet 5.5 and the executing session on Haiku 5.5.
# Terminal 1: the executing session
claude --plugin-dir ./session-relay --model haiku -n lab-executor \
--setting-sources project,local --debug-file executor.debug.log
# Terminal 2: the planning session
claude --plugin-dir ./session-relay --model sonnet -n lab-planner \
--setting-sources project,local --debug-file planner.debug.logI told the planning session that the slugify function returns an empty string for a Korean title and asked for a plan only, with no code changes, then ran /handoff lab-executor. These lines are from the two screens and from the executing session's debug log, with session ids cut to their first eight characters.
# lab-planner screen
❯ /handoff lab-executor
⎿ session-relay: Plan #1 (755 characters) is queued at lab-executor.
# lab-executor screen
› Message from @lab-planner: [relay:plan #1 from=84d6e560-...] (ctrl+o to expand)
# lab-executor debug log (UTC)
16:24:27.493Z [session-relay] $.ui.log (to debug): plan #1 received from session 84d6e560-...
16:24:40.990Z [session-relay] $.ui.log (to debug): report #1 to 84d6e560-...: queued
# lab-planner screen (the answer was in Korean; translated here)
› Message from @lab-executor: [relay:report #1 from=3908f491-...] (ctrl+o to expand)
● The lab-executor session reported that it handled all four steps of the plan. I did not
verify this in this session and only pass the report on.The executing session was idle, and a new turn started when the message arrived. It made 6 tool calls to change src/slugify.py, the tests and the README, and answered that 3 of 5 tests failed before the change and all 5 passed after it. After the run I ran the tests again in the same folder and saw 5 pass. The report came back 13.5 seconds after the plan was sent, and the planning session took another 3.2 seconds to summarize it. The planning session did not take the report as given: it stated in its answer that it had not verified the result itself.
On the first attempt the executing session carried out the plan and sent no report. I had expected the e.text that the session.receive hook receives to be the body as sent, and anchored the regular expression at the start of the string, but the actual value was the text the model reads. The executing session's transcript file records it like this.
Another Claude session sent a message:
<cross-session-message from="uds:/tmp/cc-socks/<pid>.sock" from-name="lab-planner" from-mode="prompting" from-plugin="session-relay">
[relay:plan #1 from=e4cc827e-...]
This is a plan from the planning session. Carry it out in this folder, then answer with what you changed and how you checked it.An envelope with the sending session's address, name and permission mode and the name of the sending mod comes before the body. After I removed the anchor from the regular expression, the round trip completed. A comment in the type declarations does say that e.text is the body as the model would read it.
The official documentation says that a message from another session never counts as the user's consent, and that the receiving session's permission checks still apply to whatever the message asks for. In this test both sessions were in auto mode, and the screen showed Allowed by auto mode on each of the executing session's 6 tool calls. The permission mode you start the executing session in decides how far it goes with nobody there.
The documentation also says not to base a decision on the sender's name on a received message, because the sender wrote it. The session id that session-relay puts in the body is the same kind of value, so I used it only as a reply address. According to the mods API page, the recipient is given as { sessionId }, { agentId } or the address a received message came from. /handoff passed the session name as typed, and in this test it was delivered. That a name is accepted is stated only in the type declarations.
03
Claude Code's status line shows the output of a shell script under the prompt. A mod's pane is a region where Claude Code draws the element tree a ui.render hook returns, and it is drawn again when the values the hooks collect change. hud-dashboard opens the pane when the session starts and on the /hud command, and shows the state of the session in about twelve lines.

Figure 3 is the screen while a request was running that added a test to the test file and had one subagent survey the folder. The pane the mod drew is on the right, and the lines at the bottom are the status line I already used. Table 1 lists where each row of the pane reads its value.
| Row | Where the value is read | Value shown in Figure 3 |
|---|---|---|
| SESSION | $.session.version(), $.session.model(), $.session.turns() | v2.1.333, claude-sonnet-5-5, turn 1 |
| COST | cost of $.session.usage() | $0.4038 |
| CONTEXT | context of $.session.usage() | 9%, 90k / 1000k |
| LIMITS | rateLimits of $.session.usage() | none reported |
| AGENTS | $.agent.list() | 1 running (Explore, 43k tok) |
| TOOL CALLS | counted by the mod's own tool.call hook | 7 done, 1 failed |
| TOOLS | $.tool.list() | 596 (built-in 38, MCP 558) |
| COMMANDS | $.command.list() | 433 (built-in 117, plugin 278, user 36, MCP 2) |
| PLUGINS | $.settings.read({ key: 'enabledPlugins' }) | 37 enabled |
| REPO | $.session.repo() | my-project |
| MEMO | the /memo command and $.store | 1 memo |
Table 1. The rows of the pane, the mods API each reads, and the values at the moment of Figure 3. One run in a session that loaded the full user settings
The hooks that record values are separate from the hook that draws. The tool.call hook records the count in $.state, and the ui.render hook reads it to build a row. When a value read while drawing is written later, Claude Code draws that pane again, so the mod makes no call to ask for a redraw. This is the part of the 302-line register.tsx that carries that structure, condensed.
import { atom, read, update } from 'claude-code'
const PANE = 'hud'
const NO_CALLS = { total: 0, running: 0, failed: 0, byTool: {}, last: [] }
// A value kept in $.state. It lasts for the session, across a reload of the code.
const calls = atom({ plugin: 'hud-dashboard', key: 'calls' } as const, NO_CALLS)
// On every tool call: count it as running at the start, tally it at the end.
on('tool.call', async ($, e, next) => {
const startedAt = await $.clock.now()
await update($, calls, now => ({ ...now, running: now.running + 1 }))
const ran = await next(e)
const ms = (await $.clock.now()) - startedAt
const isOk = ran.deny === undefined && ran.isError !== true
await update($, calls, now => ({
total: now.total + 1,
running: Math.max(0, now.running - 1),
failed: now.failed + (isOk ? 0 : 1),
byTool: { ...now.byTool, [e.tool]: (now.byTool[e.tool] ?? 0) + 1 },
last: [...now.last, { tool: String(e.tool), ms, isOk }].slice(-5),
}))
return ran
})
// When the pane is drawn: read only. The elements come from the surface's table.
on('ui.render', { component: 'Pane', requestId: PANE }, async ($, e) => {
const { Box, Text } = $.ui.resolve(e)
const tally = await read($, calls)
return (
<Box flexDirection="column" width={e.props.bodyColumns}>
<Box>
<Text dimColor>{'TOOL CALLS'.padEnd(11)}</Text>
<Text>
{tally.total} done · {tally.running} running ·{' '}
<Text color={tally.failed > 0 ? 'error' : undefined}>{tally.failed} failed</Text>
</Text>
</Box>
{/* the other rows, such as SESSION, COST and CONTEXT, are built the same way */}
</Box>
)
})To dock the pane beside the chat I started the session in fullscreen rendering, left one memo, and then asked for the work.
CLAUDE_CODE_NO_FLICKER=1 claude --plugin-dir ./hud-dashboard --model sonnet -n hud-lab
# inside the session
/memo rerun pytest before opening the PR/tui fullscreen or CLAUDE_CODE_NO_FLICKER=1. The documentation says a pane a mod opens by itself appears only in a terminal at least 144 columns wide, and the test terminal was 170 columns.name of $.session.repo() had no value. According to the type declarations it is set only for repositories the build knows, so the pane shows the last folder name of root./memo command stayed in the conversation, and the model read it too. At the end of the answer in Figure 3, Claude mentions the memo. The type declarations have an isTextDisplayOnly field that shows the output on screen only, and I did not test it.04
The turn.step event fires just before Claude Code sends one request to the model, and when a hook calls next({ ...e, model }), only that request goes to another model. model-router checks its rules when a prompt is submitted and changes the model only for the requests of that turn. It does not change the session's model setting, so the next turn goes back to the original model.
I put in four rules. A prompt that starts with ? and a prompt that contains 번역 (translate) or 커밋 메시지 (commit message) go to haiku, and a prompt that starts with !! goes to opus. The leading marker is removed before the model reads the prompt. The rules I tested are ? and 번역. This is the 142-line register.ts condensed to two rules and three hooks.
const RULES = [
{ name: 'quick', model: 'haiku', test: /^\?\s*/, strip: /^\?\s*/ },
{ name: 'translate', model: 'haiku', test: /번역|translate/i },
]
// The route of the prompt just submitted, until its turn starts.
let pending: { rule: string; model: string } | undefined
// The routes of the turns that are running, by turn id.
const routes = new Map<string, { rule: string; model: string }>()
on('prompt.submit', ($, e, next) => {
// Only what a person typed is routed: a slash command, a message from
// another session and a notification keep the session's model.
const isTyped = e.origin.kind === 'composer' || e.origin.kind === 'sdk'
if (!isTyped || e.command !== undefined || e.isMeta === true) {
return next(e)
}
const rule = RULES.find(one => one.test.test(e.text))
if (rule === undefined) {
pending = undefined
return next(e)
}
pending = { rule: rule.name, model: rule.model }
const text = rule.strip === undefined ? e.text : e.text.replace(rule.strip, '')
return next({ ...e, text })
})
on('turn.start', async ($, e, next) => {
const started = await next(e)
// A subagent's turn keeps its own model: only the main conversation is routed.
if (e.agentId === undefined && pending !== undefined) {
routes.set(started.turnId, pending)
pending = undefined
}
return started
})
// turn.step streams its response, so its hook is an async generator.
on('turn.step', async function* ($, e, next) {
const route = e.agentId === undefined ? routes.get(e.turnId) : undefined
if (route === undefined) {
return yield* next(e)
}
// Send only this request to another model. The result's usage holds the
// model that answered and the token counts.
return yield* next({ ...e, model: route.model })
})yield* next(...) forwards the response to the screen and evaluates to the result once the request has finished. The official documentation says that before 2.1.309 an alias such as haiku went out as written and failed with a model error. With Sonnet 5.5 as the session model I ran five turns: a plain prompt, two ? prompts, a translation request, and a plain prompt again.
$ claude --plugin-dir ./model-router --model sonnet -n router-lab --setting-sources project,local
❯ 방금 본 함수에 쓰인 정규식만 한 줄로 다시 알려 주세요.
● r"[a-z0-9]+"
● model-router: router: quick → claude-haiku-5-5, 1 step(s), input 4, cache read 28941, cache write 27923, output 16The prompt on screen, which asks in Korean for just the regular expression of the function, does not show the ? I typed, because the conversation keeps the text after the hook removed it. Table 2 lists the model and token counts of the five turns as read from the transcript file.
| Turn | Prompt | Rule | Model that answered | Cache read | Cache write | Output |
|---|---|---|---|---|---|---|
| 1 | Read the file and explain it in one sentence | none | claude-sonnet-5-5 | 40,411 56,530 | 16,119 188 | 89 109 |
| 2 | ? Just the regular expression, in one line | quick | claude-haiku-5-5 | 28,941 | 27,923 | 16 |
| 3 | ? The result of slugify('A B') | quick | claude-haiku-5-5 | 56,864 | 39 | 7 |
| 4 | Translate the docstring into Korean | translate | claude-haiku-5-5 | 56,903 | 47 | 70 |
| 5 | Sum up the answers so far in two sentences | none | claude-sonnet-5-5 | 57,020 | 29 | 201 |
Table 2. The model that answered and the token counts of each turn. Values of the second of 2 runs; turn 1 made 2 model requests, hence two lines
Three turns went to Haiku 5.5 as the rules say, and turn 5 came back to Sonnet 5.5. The value to look at is the cache write of turn 2. The prompt caching page says each model has its own cache, so switching models recomputes the entire request even when the content is identical. Turn 2, the first one routed to Haiku, wrote 27,923 tokens to the cache, and turns 3 and 4, routed to the same model, wrote fewer than 50 tokens each. In the first run this value was 30,075 tokens.
One thing differed from the documentation. By its description turn 2 should have had no cache hits, yet it read 28,941 tokens from the cache. I had run Haiku sessions in the same environment a few minutes earlier, so I estimate that the part every session shares (the system prompt and the tool definitions) was still in Haiku's cache. If that estimate holds, the write is larger in an environment that calls Haiku for the first time. Turn 5 read 57,020 tokens from Sonnet's cache: it had survived the half minute or so during which three turns went to Haiku.
So a request that is routed only once or twice in a conversation gains little because of the first cache write, and routing pays off when the same kind of request repeats. I did not calculate this in money.
05
A mod is code that runs inside Claude Code with your permissions. The official documentation says a mod can read and write files and start programs as your user account, and that it is not sandboxed. Before installing a mod someone else wrote, read the hooks and calls lines of claude plugin validate. The output for session-relay shows that this mod reads the transcript and sends messages to other sessions.
❯ ./register.ts hooks: session.start, command.run{command=handoff}, session.receive{origin has {kind=peer}}, turn.complete
❯ ./register.ts calls: $.command.register, $.session.id, $.session.messages, $.session.send, $.ui.log, $.ui.statusA mod loaded with --plugin-dir is not installed, so nothing of it remains after the session ends. Only the dashboard's memos stay in $.store and show up in the next session, so clear them with /memo clear. Disable an installed mod on the Installed tab of /plugin. To leave out every installed mod for one session, start with --safe-mode, which also disables your other customizations.
| Mod | Worth using when | A poor fit when |
|---|---|---|
| session-relay | Planning and execution are split across sessions on different models or folders, and the executing session's permissions were narrowed beforehand | The executing session of a repository where work must not go on without a permission check is left in auto mode. A setup that makes two sessions keep answering each other |
| hud-dashboard | Long work with many subagents and tool calls, in a wide terminal with fullscreen rendering | A narrow terminal, or when the status line is enough |
| model-router | The same kind of short request, such as translation or a simple question, repeats within one conversation | A short conversation that routes only once or twice. A conversation longer than the context limit of the target model (not tested) |
Table 3. When to use each mod, from the test results
A round trip between sessions that continues by itself needs a limit. The official documentation says that two sessions answering each other slowly can exchange thousands of messages without a prompt from you, and that each delivered message counts toward usage. session-relay sends one report for one plan and does not answer a report automatically.
What I did not test: how the mods draw in the Desktop app and the VS Code extension, messages to a session on another computer, the rule that routes to opus, and an environment where an organization restricts mods. The session round trip and the dashboard ran once, and model routing ran twice. The header of the type declarations says this API may change between releases without notice, so run claude plugin validate and claude plugin test again after an update.
| No. | 출처Source | 종류Kind | 확인한 날Checked |
|---|---|---|---|
| 1 | Mods overview | Claude Code 문서Claude Code docs | 2026-12-02 |
| 2 | Create a mod | Claude Code 문서Claude Code docs | 2026-12-02 |
| 3 | React to events with a mod | Claude Code 문서Claude Code docs | 2026-12-02 |
| 4 | Use the mods API | Claude Code 문서Claude Code docs | 2026-12-02 |
| 5 | Draw in the interface with a mod | Claude Code 문서Claude Code docs | 2026-12-02 |
| 6 | Message your other Claude Code sessions | Claude Code 문서Claude Code docs | 2026-12-02 |
| 7 | Fullscreen rendering | Claude Code 문서Claude Code docs | 2026-12-02 |
| 8 | How Claude Code uses prompt caching | Claude Code 문서Claude Code docs | 2026-12-02 |
| 9 | Plugin commands reference | Claude Code 문서Claude Code docs | 2026-12-02 |
| 10 | Claude Code CHANGELOG.md | ChangelogChangelog | 2026-12-02 |