소스 정보
- 저장소
- macro-inc/macro
- 최근 소스 활동
- 2026년 7월 13일 13:24
- 감지된 SKILL.md 언어
- 영어
- 스타
- 3,572
- 포크
- 358
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/macro-inc/macro --skill upgrade-model명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
Wrap a new backend endpoint in the TypeScript SDK (packages/sdk), or record it as skipped. Use when `just coverage` fails, or after adding an endpoint to a Rust service.
Debug local Rust services in this repository by starting the crate's binary with debug logging, tailing service logs, and using those logs to answer runtime questions. Use when Codex needs to investigate service startup, runtime behavior, errors, or logs for a Rust binary in a crate.
Validate Rust work after substantial Rust code changes by running `just check`, `just clippy`, then `just format`. Use before the final response after a significant Rust implementation or cleanup task; batch edits first instead of running after every small change.
SOC 직업 분류 기준
SKILL.md 표시 중
| name | upgrade-model |
| description | Upgrade an AI chat model (fast or good) across backend and frontend. |
| allowed-tools | Bash, Read, Write, Edit, Grep, Glob |
Upgrades the AI model used in the chat app. There are two model slots:
CHAT_MODELS)CHAT_MODELS)The user must specify which slot to upgrade and the new model name (e.g. claude-opus-4-6).
Ask the user (if not already provided):
fast or good?claude-opus-4-6)Derive from the model name:
SERDE_NAME: the kebab-case model ID sent over the wire (e.g. claude-opus-4-6)ENUM_VARIANT: PascalCase variant name (e.g. Claude46Opus)CONST_NAME: SCREAMING_SNAKE constant name (e.g. CLAUDE_46_OPUS)CONST_VALUE: display string used by the frontend/provider (e.g. claude-4.6-opus)PRETTY_NAME: human-readable name (e.g. Claude Opus 4.6)File: crates/agent/src/model/predefined_model.rs
Check if the enum variant already exists. If not, add all of the following:
Enum variant in pub enum Model (under the Anthropic section):
#[serde(rename = "{SERDE_NAME}")]
#[strum(serialize = "{SERDE_NAME}")]
{ENUM_VARIANT},
String constant in pub mod constants::models:
pub const {CONST_NAME}: &str = "{CONST_VALUE}";
Match arm in to_provider_model_string():
Model::{ENUM_VARIANT} => (ANTHROPIC, {CONST_NAME}),
Match arm in from_model_str():
{CONST_NAME} => Model::{ENUM_VARIANT},
File: crates/agent/src/model/predefined_model.rs
Metadata in fn metadata():
Model::{ENUM_VARIANT} => ModelMetadata {
context_window: 200_000,
},
Use the correct context window for the model. Anthropic models are typically 200,000.
Provider in fn provider():
Model::{ENUM_VARIANT} => Provider::Anthropic,
File: services/document_cognition_service/src/core/model.rs
CHAT_MODELS and update FALLBACK_MODEL.CHAT_MODELS.File: services/document_cognition_service/src/api/ws/chat_message/mod.rs
Search for the old model variant being used in the model selection logic (e.g. Model::Claude45Opus). Update it to the new variant.
cargo check -p agent -p document_cognition_service
Fix any compilation errors before proceeding.
Run from apps/web/:
cd apps/web && bun install && bun run gen-api
This builds all Rust OpenAPI and models binaries from local code, generates openapi.json, runs orval for TypeScript types, and generates model.ts from the local models binary. All generated files will reflect your local Rust changes.
bun check to find frontend usagescd apps/web && bun check
This will report TypeScript errors everywhere the old model string is used. Fix each one. Common locations:
apps/web/src/lib/core/component/AI/constant/model.ts — MODEL_PRETTYNAME, MODEL_PROVIDER_ICON, SMART_MODE_MODEL / DEFAULT_MODELapps/web/src/lib/core/component/AI/component/input/useChatInput.tsx — hardcoded model referencesapps/web/src/lib/core/component/AI/signal/pendingSend.test.ts — test dataReplace old model strings and update display names.
cd apps/web && bun format && bun check
The only errors remaining should be pre-existing ones unrelated to models (e.g. three, @aws-crypto/sha256-js type issues). All model-related errors must be resolved.
Finally, run the CI check:
cd apps/web && bun run gen-api -- --check
This must pass.
ExhaustiveMap type in constant/model.ts requires an entry for every model in the Model type, so missing entries will cause type errors.SMART_MODE_MODEL constant is the "good" model, DEFAULT_MODEL is the "fast" model.