| name | data-model-reviewer |
| description | Analyze and Refactor TypeScript data models. Detect duplication, improve type safety, and validate relationships in interfaces/types. |
| allowed-tools | Read, Grep, Glob |
Data Model Reviewer
TypeScript ํ์
์ ์๋ฅผ ๊ฒํ ํ์ฌ SSOT, ํ์
์์ ์ฑ, ๋ฐ์ดํฐ ๊ด๊ณ์ ํ์ง์ ํ์ธํฉ๋๋ค.
๊ฒ์ฌ ์์น
- SSOT - ๋ฐ์ดํฐ ์ ์ ์ค๋ณต ์ ๊ฑฐ
- Type Safety - any ์ง์, Union/Enum ํ์ฉ
- Relationship - ๋ฐ์ดํฐ ๊ฐ ๊ด๊ณ ๋ช
ํ์ฑ
Instructions
- ๋์ ํ์ธ: ์ฌ์ฉ์๊ฐ ํน์ ํ์ผ/๋๋ ํ ๋ฆฌ๋ฅผ ์ง์ ํ ๊ฒฝ์ฐ ํด๋น ๋์์์ ๊ฒํ , ๋ฏธ์ง์ ์ ํ๋ก์ ํธ ์ ์ฒด ํ์
- ํ์
ํ์ผ ํ์:
Glob์ผ๋ก **/types/**/*.ts, **/*.d.ts ๋ฑ ํ์
์ ์ ํ์ผ ์ฐพ๊ธฐ
- ํ์
์ ์ ๋ถ์:
Read๋ก ํ์ผ ์ฝ๊ณ interface/type ์ ์ ํ์ธ
- ๋ฌธ์ ํจํด ๊ฒ์:
Grep์ผ๋ก any, ๋งค์ง ์คํธ๋ง, ์ค๋ณต ์ ์ ํ์ง
- ์ฒดํฌ๋ฆฌ์คํธ ๊ธฐ๋ฐ ๊ฒํ : ์๋ ์ฒดํฌ๋ฆฌ์คํธ ํญ๋ชฉ๋ณ๋ก ๊ฒ์ฆ
- ๊ฒฐ๊ณผ ์ถ๋ ฅ: examples.md์ ์ถ๋ ฅ ํ์์ ๋ฐ๋ผ ๋ฆฌ๋ทฐ ๊ฒฐ๊ณผ ์ ์
์ฒดํฌ๋ฆฌ์คํธ
ํ์
์์ ์ฑ
๊ตฌ์กฐ ๋ฐ ๊ด๊ณ
์ถ๋ ฅ ํ์
examples.md์ "๋ฆฌ๋ทฐ ์ถ๋ ฅ ํ์" ์น์
์ ๋ฐ๋ฅผ ๊ฒ