oh-my-customcode 0.156.3 → 0.157.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -7
- package/dist/cli/index.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/templates/.claude/agents/arch-speckit-agent.md +1 -1
- package/templates/.claude/agents/sys-memory-keeper.md +3 -39
- package/templates/.claude/hooks/hooks.json +1 -1
- package/templates/.claude/hooks/scripts/plugin-cache-check.sh +1 -1
- package/templates/.claude/ontology/agents.yaml +4 -4
- package/templates/.claude/ontology/graphs/agent-skill.json +199 -68
- package/templates/.claude/ontology/graphs/full-graph.json +1240 -330
- package/templates/.claude/ontology/graphs/skill-rule.json +30 -13
- package/templates/.claude/ontology/rules.yaml +3 -3
- package/templates/.claude/ontology/skills.yaml +0 -31
- package/templates/.claude/profiles/data-eng.json +0 -1
- package/templates/.claude/profiles/harness-dev.json +0 -1
- package/templates/.claude/profiles/minimal.json +1 -2
- package/templates/.claude/profiles/web-app.json +1 -2
- package/templates/.claude/rules/SHOULD-memory-integration.md +9 -87
- package/templates/.claude/skills/agent-eval-framework/SKILL.md +2 -3
- package/templates/.claude/skills/crg-integration/SKILL.md +1 -10
- package/templates/.claude/skills/dev-review/SKILL.md +1 -2
- package/templates/.claude/skills/goal/SKILL.md +1 -1
- package/templates/.claude/skills/instinct-extractor/SKILL.md +0 -2
- package/templates/.claude/skills/intent-detection/patterns/agent-triggers.yaml +0 -19
- package/templates/.claude/skills/peer-messaging/SKILL.md +0 -2
- package/templates/.claude/skills/semble-integration/SKILL.md +0 -1
- package/templates/CLAUDE.md +3 -20
- package/templates/CLAUDE.md.en +2 -18
- package/templates/CLAUDE.md.ko +2 -18
- package/templates/guides/agent-design/ralph-loop-pattern.md +2 -2
- package/templates/guides/agent-eval/README.md +15 -35
- package/templates/guides/claude-code/15-version-compatibility.md +7 -7
- package/templates/guides/external-tools/ecc-absorption-decisions.md +2 -2
- package/templates/guides/harness-engineering/README.md +2 -2
- package/templates/guides/middleware-patterns/README.md +3 -5
- package/templates/guides/skill-promotion/instinct-extraction.md +1 -1
- package/templates/guides/token-efficiency/crg.md +7 -8
- package/templates/manifest.json +3 -3
- package/templates/.claude/skills/memory-management/SKILL.md +0 -240
- package/templates/.claude/skills/memory-recall/SKILL.md +0 -172
- package/templates/.claude/skills/memory-save/SKILL.md +0 -128
- package/templates/guides/agentmemory-migration/measure-step-zero.md +0 -120
- package/templates/guides/agentmemory-migration/phase-1-coexist.md +0 -261
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: memory-recall
|
|
3
|
-
description: Search and recall memories from claude-mem
|
|
4
|
-
scope: core
|
|
5
|
-
argument-hint: "<query> [--recent] [--limit <n>]"
|
|
6
|
-
user-invocable: true
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
# Memory Recall Skill
|
|
10
|
-
|
|
11
|
-
Search and recall relevant memories from claude-mem using semantic search.
|
|
12
|
-
|
|
13
|
-
## Parameters
|
|
14
|
-
|
|
15
|
-
| Name | Type | Required | Description |
|
|
16
|
-
|------|------|----------|-------------|
|
|
17
|
-
| query | string | yes* | Search query (*not required with --recent) |
|
|
18
|
-
|
|
19
|
-
## Options
|
|
20
|
-
|
|
21
|
-
```
|
|
22
|
-
--recent, -r Recall most recent memories
|
|
23
|
-
--limit, -l Maximum results to return (default: 5)
|
|
24
|
-
--verbose, -v Show full memory content
|
|
25
|
-
--date, -d Filter by date (YYYY-MM-DD)
|
|
26
|
-
```
|
|
27
|
-
|
|
28
|
-
## Workflow
|
|
29
|
-
|
|
30
|
-
```
|
|
31
|
-
1. Build semantic query
|
|
32
|
-
├── Prefix with "my-project"
|
|
33
|
-
├── Add user query terms
|
|
34
|
-
└── Include date if specified
|
|
35
|
-
|
|
36
|
-
2. Search claude-mem
|
|
37
|
-
└── chroma_query_documents
|
|
38
|
-
|
|
39
|
-
3. Format results
|
|
40
|
-
├── Sort by relevance score
|
|
41
|
-
├── Show summary for each
|
|
42
|
-
└── Provide memory IDs for detailed access
|
|
43
|
-
|
|
44
|
-
4. Present to user
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
## Query Tips
|
|
48
|
-
|
|
49
|
-
```yaml
|
|
50
|
-
effective_queries:
|
|
51
|
-
- "authentication flow" (topic-based)
|
|
52
|
-
- "2025-01-20 oauth" (temporal + topic)
|
|
53
|
-
- "decision jwt" (type + topic)
|
|
54
|
-
- "agent creation workflow" (semantic intent)
|
|
55
|
-
|
|
56
|
-
avoid:
|
|
57
|
-
- Single generic words like "code" or "task"
|
|
58
|
-
- Very long queries (keep it focused)
|
|
59
|
-
- Special characters or complex syntax
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
## Retrieval Strategy
|
|
63
|
-
|
|
64
|
-
### Recall-Precision Tradeoff
|
|
65
|
-
|
|
66
|
-
Default bias: **recall > precision** — it is easier to filter out irrelevant results (false positives) than to recover missed information (false negatives).
|
|
67
|
-
|
|
68
|
-
| Task Type | Bias | Recommended --limit | Rationale |
|
|
69
|
-
|-----------|------|--------------------:|-----------|
|
|
70
|
-
| Debugging / Investigation | High recall (16:1) | 10-15 | Cast wide net, prune later |
|
|
71
|
-
| Decision reference | Balanced | 5 (default) | Moderate breadth with manageable noise |
|
|
72
|
-
| Specific fact lookup | High precision | 3 | Narrow, targeted retrieval |
|
|
73
|
-
|
|
74
|
-
### Guidelines
|
|
75
|
-
|
|
76
|
-
- **Over-retrieve, then filter**: When uncertain, request more results and discard irrelevant ones in post-processing
|
|
77
|
-
- **Narrow progressively**: Start broad, refine query only if results are noisy — avoid starting too narrow
|
|
78
|
-
- **Combine temporal + semantic**: Add date filters (`--date`) to semantic queries for better precision without sacrificing recall
|
|
79
|
-
|
|
80
|
-
## Output Format
|
|
81
|
-
|
|
82
|
-
### Basic Search
|
|
83
|
-
```
|
|
84
|
-
[sys-memory-keeper:recall authentication]
|
|
85
|
-
|
|
86
|
-
Searching memories for: "my-project authentication"
|
|
87
|
-
|
|
88
|
-
Found 3 relevant memories:
|
|
89
|
-
|
|
90
|
-
[1] mem_abc123 (Score: 0.95)
|
|
91
|
-
Date: 2025-01-20
|
|
92
|
-
Summary: Implemented OAuth flow with Google provider
|
|
93
|
-
Tags: [authentication, oauth, google]
|
|
94
|
-
|
|
95
|
-
[2] mem_def456 (Score: 0.87)
|
|
96
|
-
Date: 2025-01-18
|
|
97
|
-
Summary: JWT token decision - RS256 algorithm
|
|
98
|
-
Tags: [authentication, decision, jwt]
|
|
99
|
-
|
|
100
|
-
[3] mem_ghi789 (Score: 0.82)
|
|
101
|
-
Date: 2025-01-15
|
|
102
|
-
Summary: Authentication architecture discussion
|
|
103
|
-
Tags: [authentication, architecture, planning]
|
|
104
|
-
|
|
105
|
-
Use "sys-memory-keeper:recall --verbose" for full content.
|
|
106
|
-
```
|
|
107
|
-
|
|
108
|
-
### Verbose Output
|
|
109
|
-
```
|
|
110
|
-
[sys-memory-keeper:recall authentication --verbose]
|
|
111
|
-
|
|
112
|
-
Searching memories for: "my-project authentication"
|
|
113
|
-
|
|
114
|
-
[1] mem_abc123 (Score: 0.95)
|
|
115
|
-
Date: 2025-01-20
|
|
116
|
-
Tags: [authentication, oauth, google]
|
|
117
|
-
|
|
118
|
-
Content:
|
|
119
|
-
## Session Summary
|
|
120
|
-
Date: 2025-01-20
|
|
121
|
-
|
|
122
|
-
### Tasks Completed
|
|
123
|
-
- Implemented OAuth flow with Google provider
|
|
124
|
-
- Added callback handler for OAuth response
|
|
125
|
-
- Created user session management
|
|
126
|
-
|
|
127
|
-
### Decisions Made
|
|
128
|
-
- Use passport.js for OAuth handling
|
|
129
|
-
Rationale: Well-maintained, good documentation
|
|
130
|
-
|
|
131
|
-
---
|
|
132
|
-
|
|
133
|
-
[2] mem_def456 (Score: 0.87)
|
|
134
|
-
...
|
|
135
|
-
```
|
|
136
|
-
|
|
137
|
-
### Recent Memories
|
|
138
|
-
```
|
|
139
|
-
[sys-memory-keeper:recall --recent]
|
|
140
|
-
|
|
141
|
-
Fetching recent memories for: my-project
|
|
142
|
-
|
|
143
|
-
[1] mem_xyz999 (Score: 1.00)
|
|
144
|
-
Date: 2025-01-24
|
|
145
|
-
Summary: Memory system Phase 1 implementation
|
|
146
|
-
Tags: [session, memory, phase1]
|
|
147
|
-
|
|
148
|
-
[2] mem_xyz888 (Score: 0.98)
|
|
149
|
-
Date: 2025-01-23
|
|
150
|
-
Summary: Agent identification rules update
|
|
151
|
-
Tags: [session, rules, enforcement]
|
|
152
|
-
|
|
153
|
-
...
|
|
154
|
-
```
|
|
155
|
-
|
|
156
|
-
### No Results
|
|
157
|
-
```
|
|
158
|
-
[sys-memory-keeper:recall "nonexistent topic"]
|
|
159
|
-
|
|
160
|
-
Searching memories for: "my-project nonexistent topic"
|
|
161
|
-
|
|
162
|
-
No memories found matching your query.
|
|
163
|
-
|
|
164
|
-
Suggestions:
|
|
165
|
-
- Try different keywords
|
|
166
|
-
- Use broader search terms
|
|
167
|
-
- Check available memories with "sys-memory-keeper:recall --recent"
|
|
168
|
-
```
|
|
169
|
-
|
|
170
|
-
## Related
|
|
171
|
-
|
|
172
|
-
- memory-save - Save current context
|
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: memory-save
|
|
3
|
-
description: Save current session context to claude-mem
|
|
4
|
-
scope: core
|
|
5
|
-
argument-hint: "[--tags <tags>] [--include-code]"
|
|
6
|
-
disable-model-invocation: true
|
|
7
|
-
user-invocable: true
|
|
8
|
-
---
|
|
9
|
-
|
|
10
|
-
# Memory Save Skill
|
|
11
|
-
|
|
12
|
-
Save current session context to claude-mem for persistence across context compaction.
|
|
13
|
-
|
|
14
|
-
## Options
|
|
15
|
-
|
|
16
|
-
```
|
|
17
|
-
--tags, -t Additional tags for the memory
|
|
18
|
-
--include-code Include code changes in the save
|
|
19
|
-
--summary, -s Custom summary (otherwise auto-generated)
|
|
20
|
-
--verbose, -v Show detailed save information
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
## Workflow
|
|
24
|
-
|
|
25
|
-
```
|
|
26
|
-
1. Collect session context
|
|
27
|
-
├── Tasks completed
|
|
28
|
-
├── Decisions made
|
|
29
|
-
├── Open items
|
|
30
|
-
└── Code changes (if --include-code)
|
|
31
|
-
|
|
32
|
-
2. Format with metadata
|
|
33
|
-
├── project: my-project
|
|
34
|
-
├── session: {date}-{uuid}
|
|
35
|
-
├── tags: [session, ...user_tags]
|
|
36
|
-
└── created_at: {timestamp}
|
|
37
|
-
|
|
38
|
-
3. Store in claude-mem
|
|
39
|
-
└── chroma_add_documents
|
|
40
|
-
|
|
41
|
-
4. Report result
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
## Storage Format
|
|
45
|
-
|
|
46
|
-
```yaml
|
|
47
|
-
project: my-project
|
|
48
|
-
session: {date}-{uuid}
|
|
49
|
-
tags: [session, task, decision]
|
|
50
|
-
content:
|
|
51
|
-
summary: Brief description of session context
|
|
52
|
-
tasks_completed: List of completed tasks
|
|
53
|
-
decisions: Key decisions made
|
|
54
|
-
open_items: Unfinished work
|
|
55
|
-
```
|
|
56
|
-
|
|
57
|
-
## Output Format
|
|
58
|
-
|
|
59
|
-
### Success
|
|
60
|
-
```
|
|
61
|
-
[sys-memory-keeper:save]
|
|
62
|
-
|
|
63
|
-
Saving session context...
|
|
64
|
-
|
|
65
|
-
Context collected:
|
|
66
|
-
Tasks: 3 completed
|
|
67
|
-
Decisions: 2 recorded
|
|
68
|
-
Open items: 1 pending
|
|
69
|
-
|
|
70
|
-
Metadata:
|
|
71
|
-
Project: my-project
|
|
72
|
-
Session: 2025-01-24-a1b2c3d4
|
|
73
|
-
Tags: [session, task, decision]
|
|
74
|
-
|
|
75
|
-
[Done] Session context saved successfully.
|
|
76
|
-
Memory ID: mem_abc123
|
|
77
|
-
```
|
|
78
|
-
|
|
79
|
-
### With Tags
|
|
80
|
-
```
|
|
81
|
-
[sys-memory-keeper:save --tags "authentication,oauth"]
|
|
82
|
-
|
|
83
|
-
Saving session context...
|
|
84
|
-
|
|
85
|
-
Metadata:
|
|
86
|
-
Project: my-project
|
|
87
|
-
Session: 2025-01-24-a1b2c3d4
|
|
88
|
-
Tags: [session, task, decision, authentication, oauth]
|
|
89
|
-
|
|
90
|
-
[Done] Session context saved successfully.
|
|
91
|
-
Memory ID: mem_abc123
|
|
92
|
-
```
|
|
93
|
-
|
|
94
|
-
### Verbose
|
|
95
|
-
```
|
|
96
|
-
[sys-memory-keeper:save --verbose]
|
|
97
|
-
|
|
98
|
-
Collecting session context...
|
|
99
|
-
|
|
100
|
-
Tasks Completed:
|
|
101
|
-
1. Implemented OAuth flow
|
|
102
|
-
2. Added JWT token validation
|
|
103
|
-
3. Created authentication middleware
|
|
104
|
-
|
|
105
|
-
Decisions Made:
|
|
106
|
-
1. Use RS256 for JWT signing
|
|
107
|
-
Rationale: Better security for distributed systems
|
|
108
|
-
2. Token expiry: 1 hour
|
|
109
|
-
Rationale: Balance security and user experience
|
|
110
|
-
|
|
111
|
-
Open Items:
|
|
112
|
-
1. Refresh token implementation
|
|
113
|
-
Status: In progress
|
|
114
|
-
|
|
115
|
-
Saving to claude-mem...
|
|
116
|
-
|
|
117
|
-
Document content:
|
|
118
|
-
## Session Summary
|
|
119
|
-
Date: 2025-01-24
|
|
120
|
-
...
|
|
121
|
-
|
|
122
|
-
[Done] Session context saved.
|
|
123
|
-
Memory ID: mem_abc123
|
|
124
|
-
```
|
|
125
|
-
|
|
126
|
-
## Related
|
|
127
|
-
|
|
128
|
-
- memory-recall - Search and recall memories
|
|
@@ -1,120 +0,0 @@
|
|
|
1
|
-
# AgentMemory 마이그레이션 — 단계 0: MEASURE (사용 빈도 측정)
|
|
2
|
-
|
|
3
|
-
> **목적**: Phase 1 (COEXIST) 진입 전, claude-mem skill 실제 호출 빈도 데이터를 수집하여 가설 기반 자산 처리표를 검증한다.
|
|
4
|
-
> **관련 이슈**: #1169 본문 조치 5
|
|
5
|
-
> **참고 메모리**: `feedback_claude_mem_maintenance`, `project_sequencing_alpha_beta_gamma`
|
|
6
|
-
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
## 1. 목적
|
|
10
|
-
|
|
11
|
-
AgentMemory 마이그레이션 계획(`feedback_claude_mem_maintenance.md`)에는 12개 claude-mem skill의 처리 방향이 가설로 기재되어 있다. 특히 폐기 후보 5종(`make-plan`, `do`, `babysit`, `wowerpoint`, `knowledge-agent`, `pathfinder`)은 "미사용 또는 저빈도"라는 가정 위에 놓여 있다.
|
|
12
|
-
|
|
13
|
-
이 단계에서는 실측 데이터로 가설을 검증한다. 데이터 없이 Phase 1에 진입하면:
|
|
14
|
-
- 실제로 자주 쓰이던 skill을 폐기하여 사용자 워크플로우가 깨질 수 있다.
|
|
15
|
-
- 자산 처리표 재설계 비용이 Phase 2~3로 이월된다.
|
|
16
|
-
|
|
17
|
-
---
|
|
18
|
-
|
|
19
|
-
## 2. 실행 방법
|
|
20
|
-
|
|
21
|
-
```bash
|
|
22
|
-
# 기본 실행 (최근 7일, 리포트를 ~/.claude/measure-claude-mem-usage-YYYY-MM-DD.md 에 저장)
|
|
23
|
-
bash scripts/measure-claude-mem-usage.sh
|
|
24
|
-
|
|
25
|
-
# 최근 14일 스캔
|
|
26
|
-
bash scripts/measure-claude-mem-usage.sh --days 14
|
|
27
|
-
|
|
28
|
-
# 출력 경로 지정
|
|
29
|
-
bash scripts/measure-claude-mem-usage.sh --output ~/Documents/claude-mem-usage.md
|
|
30
|
-
|
|
31
|
-
# 헤더 없이 실행 (CI/파이프라인 삽입용)
|
|
32
|
-
bash scripts/measure-claude-mem-usage.sh --quiet
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
### 스캔 대상 경로
|
|
36
|
-
|
|
37
|
-
| 경로 | 설명 |
|
|
38
|
-
|------|------|
|
|
39
|
-
| `~/.claude-mem/archives/` | claude-mem MCP 아카이브 (`.jsonl`, `.json`) |
|
|
40
|
-
| `~/.claude/projects/*/session-*.jsonl` | Claude Code 세션 로그 |
|
|
41
|
-
|
|
42
|
-
둘 중 하나가 없어도 스크립트는 조용히 skip하고 나머지를 스캔한다.
|
|
43
|
-
|
|
44
|
-
---
|
|
45
|
-
|
|
46
|
-
## 3. 1주 수집 계획
|
|
47
|
-
|
|
48
|
-
| 시점 | 작업 |
|
|
49
|
-
|------|------|
|
|
50
|
-
| **Day 1** | 첫 측정 — 베이스라인 (`--days 7` 기준 기존 archives 기반) |
|
|
51
|
-
| **Day 4** | 중간 측정 — 추이 확인 (`--days 4`) |
|
|
52
|
-
| **Day 7** | 최종 측정 — 자산 처리표 재검토 및 Phase 1 GO/NO-GO 결정 |
|
|
53
|
-
|
|
54
|
-
세 시점 모두 `--output` 경로를 달리 지정하여 비교 가능한 파일로 보관한다:
|
|
55
|
-
|
|
56
|
-
```bash
|
|
57
|
-
bash scripts/measure-claude-mem-usage.sh --output ~/.claude/claude-mem-day1.md
|
|
58
|
-
bash scripts/measure-claude-mem-usage.sh --days 4 --output ~/.claude/claude-mem-day4.md
|
|
59
|
-
bash scripts/measure-claude-mem-usage.sh --days 7 --output ~/.claude/claude-mem-day7.md
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
---
|
|
63
|
-
|
|
64
|
-
## 4. 해석 기준
|
|
65
|
-
|
|
66
|
-
| 호출 수 | 신호 | 권장 조치 |
|
|
67
|
-
|---------|------|----------|
|
|
68
|
-
| **0** | 미사용 | 폐기 안전 — 1주 후 처리 결정 |
|
|
69
|
-
| **1-3** | 가끔 사용 | wrapper 또는 대체 도구 매핑 필요 |
|
|
70
|
-
| **4+** | 정기 사용 | 폐기 시 대체 도구 명확화 필수 |
|
|
71
|
-
|
|
72
|
-
폐기 후보 5종 기준 예상:
|
|
73
|
-
- `make-plan`, `do`, `babysit` → 0 예상 (native AgentMemory로 대체 완료)
|
|
74
|
-
- `wowerpoint`, `knowledge-agent`, `pathfinder` → 0~1 예상 (특수 목적 skill)
|
|
75
|
-
|
|
76
|
-
실측값이 예상과 다를 경우 자산 처리표를 수정한 후 Phase 1에 진입한다.
|
|
77
|
-
|
|
78
|
-
---
|
|
79
|
-
|
|
80
|
-
## 5. 결과 활용
|
|
81
|
-
|
|
82
|
-
### 5-1. #1169에 리포트 첨부
|
|
83
|
-
|
|
84
|
-
```bash
|
|
85
|
-
gh issue comment 1169 --body-file ~/.claude/claude-mem-day7.md
|
|
86
|
-
```
|
|
87
|
-
|
|
88
|
-
### 5-2. 자산 처리표 갱신
|
|
89
|
-
|
|
90
|
-
`.claude/agent-memory/sys-memory-keeper/feedback_claude_mem_maintenance.md` 내 "처리 방향" 열을 실측값 기반으로 업데이트한다.
|
|
91
|
-
|
|
92
|
-
### 5-3. Phase 1 GO/NO-GO 결정
|
|
93
|
-
|
|
94
|
-
| 조건 | 결정 |
|
|
95
|
-
|------|------|
|
|
96
|
-
| 폐기 후보 모두 호출 수 0 | GO — Phase 1 진입 |
|
|
97
|
-
| 폐기 후보 중 1개 이상 호출 수 1-3 | CONDITIONAL GO — 대체 도구 매핑 완료 후 진입 |
|
|
98
|
-
| 폐기 후보 중 1개 이상 호출 수 4+ | NO-GO — 처리표 재설계 후 재측정 |
|
|
99
|
-
|
|
100
|
-
---
|
|
101
|
-
|
|
102
|
-
## 6. 한계 및 주의사항
|
|
103
|
-
|
|
104
|
-
| 항목 | 설명 |
|
|
105
|
-
|------|------|
|
|
106
|
-
| archives 미존재 | `~/.claude-mem/archives/` 없으면 카운트 0 (정상 — silent skip) |
|
|
107
|
-
| 세션 로그 형식 변경 | Claude Code 업데이트로 `session-*.jsonl` 구조가 변경되면 grep 패턴 수정 필요 |
|
|
108
|
-
| claude-mem MCP telemetry 미사용 | 외부 도구 의존 최소화 원칙에 따라 MCP 자체 지표는 사용하지 않음 |
|
|
109
|
-
| grep 기반 측정 | 같은 파일에 skill 이름이 여러 줄 등장하면 복수 카운트됨 (과대 계산 가능성) |
|
|
110
|
-
| macOS/Linux 호환 | `stat` 옵션 차이를 스크립트 내에서 자동 처리 (`-f %m` vs `-c %Y`) |
|
|
111
|
-
|
|
112
|
-
---
|
|
113
|
-
|
|
114
|
-
## 7. 참고
|
|
115
|
-
|
|
116
|
-
- **이슈**: [#1169](../../.github/ — `gh issue view 1169`)
|
|
117
|
-
- **자산 처리표**: `.claude/agent-memory/sys-memory-keeper/feedback_claude_mem_maintenance.md`
|
|
118
|
-
- **시퀀싱 메모리**: `.claude/agent-memory/mgr-creator/project_sequencing_alpha_beta_gamma.md` (또는 해당 메모리 파일)
|
|
119
|
-
- **스크립트**: `scripts/measure-claude-mem-usage.sh`
|
|
120
|
-
- **Phase 1 가이드**: `guides/agentmemory-migration/` (이 디렉토리에 추가 예정)
|
|
@@ -1,261 +0,0 @@
|
|
|
1
|
-
# AgentMemory Migration — Phase 1: COEXIST (Week 1-2)
|
|
2
|
-
|
|
3
|
-
> **상태**: 활성 — 2026-05-18 시작 (#1169)
|
|
4
|
-
> **다음 단계**: Phase 2 SWITCH (measure 결과 후 GO/NO-GO 결정)
|
|
5
|
-
> **이전 단계**: [measure-step-zero.md](./measure-step-zero.md)
|
|
6
|
-
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
## 1. 개요
|
|
10
|
-
|
|
11
|
-
Phase 1 (COEXIST)는 claude-mem과 AgentMemory를 **동시에 운영**하는 단계입니다.
|
|
12
|
-
이 단계에서는 어떤 destructive 변경도 발생하지 않습니다:
|
|
13
|
-
|
|
14
|
-
- claude-mem 기존 Chroma 데이터 유지
|
|
15
|
-
- 12 plugin skill 폐기 없음
|
|
16
|
-
- 어댑터 코드 활성화 없음 (STUB 상태 유지)
|
|
17
|
-
- 자산 처리표 적용 없음
|
|
18
|
-
|
|
19
|
-
목표는 1주간 실제 사용 데이터를 수집하고, AgentMemory 설치와 공존 운영에 익숙해지는 것입니다.
|
|
20
|
-
|
|
21
|
-
| 항목 | Phase 1 (COEXIST) | Phase 2 (SWITCH) |
|
|
22
|
-
|------|-------------------|------------------|
|
|
23
|
-
| claude-mem | 활성 (기존 운영) | 비활성화 예정 |
|
|
24
|
-
| AgentMemory | 설치 후 병렬 활성 | 단독 운영 |
|
|
25
|
-
| 데이터 마이그레이션 | 없음 | 선택적 (측정 후 결정) |
|
|
26
|
-
| 어댑터 코드 | STUB 유지 | 활성화 |
|
|
27
|
-
| 자산 처리표 | 적용 보류 | 사용자 검토 후 적용 |
|
|
28
|
-
|
|
29
|
-
---
|
|
30
|
-
|
|
31
|
-
## 2. AgentMemory 설치
|
|
32
|
-
|
|
33
|
-
> **R001 주의**: auto-install 금지. 아래 명령어를 사용자 로컬에서 수동으로 실행합니다.
|
|
34
|
-
|
|
35
|
-
### 2-1. 패키지 설치
|
|
36
|
-
|
|
37
|
-
```bash
|
|
38
|
-
# 옵션 A: pip
|
|
39
|
-
pip install agentmemory
|
|
40
|
-
|
|
41
|
-
# 옵션 B: pipx (격리 환경 권장)
|
|
42
|
-
pipx install agentmemory
|
|
43
|
-
|
|
44
|
-
# 옵션 C: uvx (uv 사용 시)
|
|
45
|
-
uvx agentmemory
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
### 2-2. MCP 서버 등록
|
|
49
|
-
|
|
50
|
-
```bash
|
|
51
|
-
# Claude Code CLI로 등록
|
|
52
|
-
claude mcp add agentmemory -- agentmemory mcp
|
|
53
|
-
|
|
54
|
-
# 또는 .mcp.json 수동 편집 (R001 auto-install 금지)
|
|
55
|
-
# {
|
|
56
|
-
# "mcpServers": {
|
|
57
|
-
# "agentmemory": {
|
|
58
|
-
# "command": "agentmemory",
|
|
59
|
-
# "args": ["mcp"]
|
|
60
|
-
# }
|
|
61
|
-
# }
|
|
62
|
-
# }
|
|
63
|
-
```
|
|
64
|
-
|
|
65
|
-
### 2-3. 등록 확인
|
|
66
|
-
|
|
67
|
-
```bash
|
|
68
|
-
claude mcp list
|
|
69
|
-
# 출력에 agentmemory 서버가 표시되어야 합니다
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
---
|
|
73
|
-
|
|
74
|
-
## 3. COEXIST 정책
|
|
75
|
-
|
|
76
|
-
Phase 1 기간 동안 두 backend는 다음 정책에 따라 공존합니다.
|
|
77
|
-
|
|
78
|
-
### 3-1. 기본 운영 방식
|
|
79
|
-
|
|
80
|
-
| 작업 | 우선 backend | 비고 |
|
|
81
|
-
|------|-------------|------|
|
|
82
|
-
| 기존 메모리 조회 | claude-mem | 기존 Chroma 데이터 유지 |
|
|
83
|
-
| 신규 메모리 저장 | 둘 다 | COEXIST 기간 중 병렬 저장 권장 |
|
|
84
|
-
| 세션 종료 시 저장 | 둘 다 | R011 Session-End Self-Check 참조 |
|
|
85
|
-
|
|
86
|
-
### 3-2. 쿼리 병합 (memory-aggregator)
|
|
87
|
-
|
|
88
|
-
두 backend에서 결과가 반환될 경우 `memory-aggregator` 스킬이 결과를 병합합니다:
|
|
89
|
-
|
|
90
|
-
```
|
|
91
|
-
claude-mem.search(query) → 결과 A
|
|
92
|
-
AgentMemory.search(query) → 결과 B
|
|
93
|
-
memory-aggregator → A + B 중복 제거 후 반환
|
|
94
|
-
```
|
|
95
|
-
|
|
96
|
-
`memory-aggregator` 스킬이 없는 경우, 두 결과를 순서대로 제시하고 사용자가 선택합니다.
|
|
97
|
-
|
|
98
|
-
### 3-3. 충돌 방지 원칙
|
|
99
|
-
|
|
100
|
-
- claude-mem 기존 데이터를 AgentMemory로 자동 복사하지 않음
|
|
101
|
-
- 두 backend에 동일 키로 저장 시 별개 항목으로 취급
|
|
102
|
-
- 강제 동기화 없음 — Phase 2에서 마이그레이션 여부 결정
|
|
103
|
-
|
|
104
|
-
---
|
|
105
|
-
|
|
106
|
-
## 4. Dual-Backend 충돌 Advisory
|
|
107
|
-
|
|
108
|
-
`.mcp.json`에 두 서버가 동시 등록된 상태를 감지하면 다음 advisory를 출력합니다.
|
|
109
|
-
|
|
110
|
-
### 4-1. 감지 조건
|
|
111
|
-
|
|
112
|
-
```
|
|
113
|
-
.mcp.json 내 서버 목록:
|
|
114
|
-
- "claude-mem" (또는 관련 tool prefix)
|
|
115
|
-
- "agentmemory"
|
|
116
|
-
→ 두 개 동시 존재 시 Phase 1 COEXIST 상태로 간주
|
|
117
|
-
```
|
|
118
|
-
|
|
119
|
-
### 4-2. Advisory 메시지
|
|
120
|
-
|
|
121
|
-
```
|
|
122
|
-
[Advisory] Dual memory backend detected (Phase 1 COEXIST)
|
|
123
|
-
- claude-mem: active (Chroma)
|
|
124
|
-
- agentmemory: active (SQLite)
|
|
125
|
-
현재 Phase 1 COEXIST 정책 적용 중 — 두 backend 병렬 운영
|
|
126
|
-
Phase 2 SWITCH 진입 전까지 두 backend 유지
|
|
127
|
-
가이드: guides/agentmemory-migration/phase-1-coexist.md
|
|
128
|
-
```
|
|
129
|
-
|
|
130
|
-
이 advisory는 경고가 아닙니다. Phase 1에서는 정상 상태입니다.
|
|
131
|
-
|
|
132
|
-
### 4-3. 강제 선택 (사용자 명시 시)
|
|
133
|
-
|
|
134
|
-
사용자가 명시적으로 "agentmemory만 사용" 또는 "claude-mem만 사용"을 요청하는 경우,
|
|
135
|
-
해당 요청을 따르되 자산 처리표 적용 및 어댑터 활성화는 Phase 2 GO 결정 후 진행합니다.
|
|
136
|
-
|
|
137
|
-
---
|
|
138
|
-
|
|
139
|
-
## 5. 사용자 행동 계획
|
|
140
|
-
|
|
141
|
-
### 5-1. 1주 measure 루틴 (자동 트리거: 2026-05-25)
|
|
142
|
-
|
|
143
|
-
`scripts/measure-claude-mem-usage.sh` 스크립트를 1주간 실행합니다:
|
|
144
|
-
|
|
145
|
-
```bash
|
|
146
|
-
# 수동 실행 (필요 시)
|
|
147
|
-
bash scripts/measure-claude-mem-usage.sh
|
|
148
|
-
|
|
149
|
-
# 결과는 .claude/outputs/sessions/ 에 저장됩니다
|
|
150
|
-
```
|
|
151
|
-
|
|
152
|
-
측정 항목:
|
|
153
|
-
- 일별 호출 횟수 (claude-mem vs AgentMemory)
|
|
154
|
-
- 응답 지연 (p50, p95)
|
|
155
|
-
- 저장 성공/실패율
|
|
156
|
-
- 메모리 용량 (Chroma vs SQLite)
|
|
157
|
-
|
|
158
|
-
### 5-2. GO/NO-GO 결정 기준 (2026-05-25 예정)
|
|
159
|
-
|
|
160
|
-
| 지표 | GO 조건 | NO-GO 조건 |
|
|
161
|
-
|------|---------|------------|
|
|
162
|
-
| 응답 지연 | AgentMemory ≤ claude-mem × 1.2 | AgentMemory > claude-mem × 2.0 |
|
|
163
|
-
| 저장 성공률 | ≥ 99% | < 95% |
|
|
164
|
-
| 운영 안정성 | 1주 무장애 | 크래시 또는 데이터 손실 |
|
|
165
|
-
| 호환성 | 기존 메모리 포맷 읽기 가능 | 포맷 비호환으로 검색 실패 |
|
|
166
|
-
|
|
167
|
-
### 5-3. 지금 할 수 있는 것
|
|
168
|
-
|
|
169
|
-
- AgentMemory 설치 및 MCP 등록 (위 섹션 2 참조)
|
|
170
|
-
- 신규 세션에서 AgentMemory로도 저장해보기 (실험적)
|
|
171
|
-
- measure 스크립트 결과 관찰
|
|
172
|
-
- 자산 처리표 (`guides/agentmemory-migration/asset-disposition.md`) 검토 준비
|
|
173
|
-
|
|
174
|
-
---
|
|
175
|
-
|
|
176
|
-
## 6. Phase 2 진입 조건
|
|
177
|
-
|
|
178
|
-
다음 조건이 모두 충족된 경우에만 Phase 2 (SWITCH)로 진행합니다.
|
|
179
|
-
|
|
180
|
-
### 필수 조건
|
|
181
|
-
|
|
182
|
-
- [ ] 1주 measure 결과 GO 판정 (5-2 기준 충족)
|
|
183
|
-
- [ ] 자산 처리표 사용자 검토 완료 (12 plugin skill 처리 방향 결정)
|
|
184
|
-
- [ ] 30분 롤백 절차 검증 완료
|
|
185
|
-
|
|
186
|
-
### 롤백 절차 검증 (Phase 2 진입 전 필수)
|
|
187
|
-
|
|
188
|
-
```bash
|
|
189
|
-
# 1. Chroma 백업 생성
|
|
190
|
-
cp -r ~/.local/share/claude-mem/chroma ~/.local/share/claude-mem/chroma.bak.$(date +%Y%m%d)
|
|
191
|
-
|
|
192
|
-
# 2. 백업에서 복원 가능 여부 확인
|
|
193
|
-
# (실제 복원 수행하지 않고 절차만 검증)
|
|
194
|
-
ls -la ~/.local/share/claude-mem/chroma.bak.*
|
|
195
|
-
|
|
196
|
-
# 3. AgentMemory SQLite 백업
|
|
197
|
-
cp ~/.local/share/agentmemory/memories.db ~/.local/share/agentmemory/memories.db.bak.$(date +%Y%m%d)
|
|
198
|
-
```
|
|
199
|
-
|
|
200
|
-
롤백 소요 시간이 30분 이내임을 확인한 후 Phase 2 진행.
|
|
201
|
-
|
|
202
|
-
---
|
|
203
|
-
|
|
204
|
-
## 7. 현 단계 한계 및 금지 사항
|
|
205
|
-
|
|
206
|
-
### 7-1. STUB 상태 유지 (변경 금지)
|
|
207
|
-
|
|
208
|
-
```
|
|
209
|
-
packages/eval-core/src/adapters/agentmemory.ts ← STUB, 활성화 금지
|
|
210
|
-
packages/eval-core/src/db/schema.ts ← 변경 금지
|
|
211
|
-
```
|
|
212
|
-
|
|
213
|
-
이 파일들은 Phase 2 GO 결정 후 별도 사이클에서 수정합니다.
|
|
214
|
-
|
|
215
|
-
### 7-2. 자산 처리표 적용 보류
|
|
216
|
-
|
|
217
|
-
12 plugin skill의 폐기/유지 결정은 measure 결과를 확인한 후 진행합니다:
|
|
218
|
-
|
|
219
|
-
```
|
|
220
|
-
.claude/skills/memory-*/ ← 폐기 여부 보류
|
|
221
|
-
.claude/skills/claude-mem-*/ ← 폐기 여부 보류
|
|
222
|
-
```
|
|
223
|
-
|
|
224
|
-
### 7-3. 데이터 마이그레이션 금지
|
|
225
|
-
|
|
226
|
-
Phase 1에서는 claude-mem Chroma 데이터를 AgentMemory SQLite로 이전하지 않습니다.
|
|
227
|
-
이전은 Phase 2에서 사용자가 명시적으로 승인한 경우에만 진행합니다.
|
|
228
|
-
|
|
229
|
-
---
|
|
230
|
-
|
|
231
|
-
## 8. R011과의 관계
|
|
232
|
-
|
|
233
|
-
Phase 1 COEXIST 기간 중 R011 (SHOULD-memory-integration) 적용:
|
|
234
|
-
|
|
235
|
-
| R011 항목 | COEXIST 수정 사항 |
|
|
236
|
-
|-----------|-----------------|
|
|
237
|
-
| Primary: Native auto memory | 변경 없음 |
|
|
238
|
-
| Supplementary: claude-mem | 변경 없음 (계속 사용) |
|
|
239
|
-
| Session-End Self-Check | claude-mem + AgentMemory 둘 다 저장 시도 |
|
|
240
|
-
| Failure Policy | 둘 중 하나 실패해도 비차단 |
|
|
241
|
-
|
|
242
|
-
세션 종료 시 자가 점검 (COEXIST 확장):
|
|
243
|
-
|
|
244
|
-
```
|
|
245
|
-
1. sys-memory-keeper가 MEMORY.md 갱신? → YES
|
|
246
|
-
2. claude-mem 저장 시도? → YES (기존)
|
|
247
|
-
3. AgentMemory 저장 시도? → YES (COEXIST 추가)
|
|
248
|
-
모두 완료 후 사용자에게 확인
|
|
249
|
-
```
|
|
250
|
-
|
|
251
|
-
---
|
|
252
|
-
|
|
253
|
-
## 9. 참고
|
|
254
|
-
|
|
255
|
-
- **이슈**: #1169 (AgentMemory 마이그레이션 계획)
|
|
256
|
-
- **이전 단계**: [measure-step-zero.md](./measure-step-zero.md)
|
|
257
|
-
- **R011**: `.claude/rules/SHOULD-memory-integration.md` (Dual-Backend Advisory 섹션)
|
|
258
|
-
- **관련 기억**: [[project-sequencing-alpha-beta-gamma]]
|
|
259
|
-
- **자산 처리표**: `guides/agentmemory-migration/asset-disposition.md` (Phase 2 전 검토 필요)
|
|
260
|
-
- **measure 스크립트**: `scripts/measure-claude-mem-usage.sh`
|
|
261
|
-
- **롤백 가이드**: #1169 본문 조치 4 (30분 롤백 절차)
|