session-automation-scout — 반복 작업 자동화 정찰병#
| 항목 | 내용 |
|---|---|
| 모델 | haiku |
| 사용 도구 | Read, Glob, Grep |
한마디로#
작업 중에 똑같은 일을 손으로 자꾸 반복하는 부분을 찾아내서, "이건 자동화하면 편하겠어요"라고 제안해 주는 도우미입니다. 사무실에서 같은 서류 작업을 매일 반복하는 직원을 보고 "이건 양식 하나 만들면 끝나겠네"라고 짚어주는 똑똑한 관리자와 같아요.
누가·언제 쓰나요#
- 한 작업 세션에서 비슷한 일을 손으로 여러 번 반복했을 때
- "이거 매번 똑같이 하는데 좀 더 편하게 할 수 없나?" 싶을 때
- 새로운 자동화 도구(skill/agent)를 만들지, 기존 도구를 개선할지 판단하고 싶을 때
👉 보통 한 작업이 끝난 뒤 "이번에 반복된 일이 없었나" 되돌아보는 정리 단계에서 호출됩니다.
무엇을 해주나요#
세션에서 반복된 패턴을 찾아 자동화 제안 목록을 정리해 줍니다. 각 제안에는 다음이 담깁니다.
- 어떤 패턴이 몇 번 반복됐는지 (frequency)
- 매번 얼마나 시간이 드는지 추정치 (time_spent_estimate)
-
어떤 식으로 자동화하면 좋은지 — 새 도구 만들기(
new_skill), 기존 도구 개선(skill_enhancement), 자동 실행 훅(workflow_hook), 템플릿 추가(template), 린트 규칙 추가(lint_rule) - 실제로 어떻게 구현하면 되는지 힌트 (implementation_hint)
어떻게 쓰나요#
이 에이전트는 직접 옵션을 넣어 쓰기보다, 세션 정리 흐름 안에서 자동으로 불려 다음과 같은 형태의 결과를 내놓습니다.
automatable_patterns:
- id: " pattern-001 "
pattern: " BLoC 이벤트를 추가할 때 항상 State도 같이 추가함 "
frequency: 3
automation_type: " new_skill "
suggestion:
name: " bloc-event-state-pair "
위처럼 "이 패턴이 3번 반복됐고, 새 도구를 만들면 좋겠다"는 식으로 알려줍니다.
안에서 무슨 일이 벌어지나요#
- 작업 추출 — 이번 세션에서 한 일(파일 생성·수정, 명령 실행, 도구 호출)을 모읍니다.
- 비슷한 일 묶기 — 같은 패턴의 코드 변경, 같은 순서의 명령, 같은 구조의 파일 생성을 한데 묶습니다.
- 반복 횟수 분석 — 2번 이상이면 후보, 3번 이상이면 강력 추천으로 분류합니다.
- 자동화 가능성 판단 — 규칙으로 만들 수 있는지, 예외가 적은지, 들이는 노력 대비 이득이 있는지 따집니다.
- 제안 만들기 — 새 도구 만들기 / 기존 도구 개선 / 자동 실행 훅 추가 중 가장 알맞은 형태로 제안합니다.
핵심 원칙은 2번 이상 반복된 것만 제안하고, 새 도구를 만들기보다 기존 도구 개선을 먼저 권하며, 절약되는 시간과 구현 난이도까지 함께 알려주는 것입니다.
⚙️ 상세 옵션·실행 명세 (개발자 / AI 에이전트용)
Role#
- Repetitive Pattern Detection: Identify manually repeated tasks
- Automation Suggestions: Suggest skill/agent creation
- Existing Tool Improvement: Suggest improvements for current skills
- Workflow Optimization: Suggest workflow improvements
Detection Targets#
1. Repetitive Code Tasks#
| Pattern | Automation Approach |
|---|---|
| Repeatedly adding same imports | Auto-import skill |
| Generating boilerplate | Template skill |
| Creating file structures | Scaffolding skill |
2. Repetitive Command Execution#
| Pattern | Automation Approach |
|---|---|
| Build → test → lint | Chain skill |
| Editing multiple files simultaneously | Batch skill |
| Tasks in specific order | Workflow skill |
3. Manual Verification Tasks#
| Pattern | Automation Approach |
|---|---|
| Checklist verification | Auto-check skill |
| Code review patterns | Review automation |
| Convention checking | Add lint rules |
Output Format#
automatable_patterns:
- id: " pattern-001 "
pattern: " Always add State when adding BLoC event "
frequency: 3
time_spent_estimate: " 5 min/occurrence "
automation_type: " new_skill "
suggestion:
name: " bloc-event-state-pair "
description: " Simultaneously generate BLoC event and matching State "
complexity: " low "
implementation_hint: |
1. Accept event class definition as input
2. Auto-generate matching State class
3. Add BLoC handler skeleton
- id: " pattern-002 "
pattern: " Adding identical imports to every test file "
frequency: 5
time_spent_estimate: " 1 min/occurrence "
automation_type: " skill_enhancement "
suggestion:
target_skill: " test "
enhancement: " Add auto-import feature "
implementation_hint: |
Add standard test import auto-addition option to test skill
- id: " pattern-003 "
pattern: " Running format + analyze before PR creation "
frequency: 4
time_spent_estimate: " 2 min/occurrence "
automation_type: " workflow_hook "
suggestion:
hook_type: " pre-pr "
commands: [ " melos run format " , " melos run analyze " ]주: 위
commands는 탐지된 패턴 예시다(실행 아님). 자동화 훅으로 제안할 때는 도구 부재를 가정하라 —melos없으면dart/flutter직접 호출로 degrade 하도록 제안하고, hook 이 도구 미설치로 하드페일하지 않게 한다(GD-01).
Detection Algorithm#
1. Extract tasks from session
├── File creation/modification
├── Command execution
└── Tool invocations
2. Group similar tasks
├── Same pattern of code changes
├── Same sequence of command execution
└── Same structure of file creation
3. Frequency analysis
├── Repeated 2+ times → candidate
└── Repeated 3+ times → strongly recommended
4. Automation feasibility assessment
├── Can it be rule-based?
├── Are there few edge cases?
└── Is the effort-to-benefit ratio positive?
5. Generate suggestions
├── Create new skill
├── Improve existing skill
└── Add workflow hookAutomation Types#
| Type | Description | Example |
|---|---|---|
new_skill | Create new skill | /bloc-event-state |
skill_enhancement | Improve existing skill | Add auto-import to test skill |
workflow_hook | Auto-execute hook | Format before PR |
template | Add template | BLoC boilerplate |
lint_rule | Add lint rule | Enforce isClosed check |
Key Rules#
- Frequency-based: Only suggest tasks repeated 2+ times
- Impact Analysis: Estimate time savings from automation
- Specific Suggestions: Include implementation hints
- Existing Tools First: Prioritize improving existing tools over new ones
- Complexity Assessment: Include implementation difficulty level