메모리 규칙 경로 범위 적용을 위한 paths 프런트매터 지원 추가
Some checks failed
Release Gate / gate (push) Has been cancelled

계층형 메모리 문서에 YAML 유사 paths 프런트매터를 추가해 현재 작업 폴더 경로에 따라 규칙 적용 여부를 제어할 수 있도록 했습니다.

AgentMemoryService에서 프런트매터를 파싱하고 프로젝트 루트 기준 상대 경로에 대해 *, **, ? glob 매칭을 수행하도록 구현했습니다.

README와 DEVELOPMENT 문서에 메모리 규칙 범위 제어 기능과 동작 방식을 2026-04-07 00:22 (KST) 기준으로 반영했고, Release 빌드 경고 0 오류 0을 확인했습니다.
This commit is contained in:
2026-04-07 00:07:32 +09:00
parent 18551a0aea
commit 2e0362a88f
3 changed files with 107 additions and 1 deletions

View File

@@ -5165,3 +5165,13 @@ ow + toggle ?쒓컖 ?몄뼱濡??ㅼ떆 ?뺣젹?덈떎.
- [AgentMemoryService.cs](/E:/AX%20Copilot%20-%20Codex/src/AxCopilot/Services/AgentMemoryService.cs)
- `@include` 해석 시 설정을 읽어, 외부 include가 꺼져 있으면 홈 경로(`@~/...`), 절대 경로, 프로젝트 바깥으로 벗어나는 상대 경로를 차단하도록 바꿨다.
- `claw-code`처럼 메모리 편집은 도구/명령 중심으로 하고, 외부 include는 별도 안전 정책으로 관리하는 구조를 목표로 한다.
## 2026-04-07 00:22 (KST)
- [AgentMemoryService.cs](/E:/AX%20Copilot%20-%20Codex/src/AxCopilot/Services/AgentMemoryService.cs)
- 계층형 메모리 문서에 YAML 유사 frontmatter `paths:` 규칙을 추가했다.
- 문서 상단이 `---`로 시작하면 `paths:` 아래의 `- pattern` 목록을 읽고, 현재 작업 폴더가 프로젝트 루트 기준 상대 경로로 그 패턴과 일치할 때만 해당 문서를 메모리 계층에 포함한다.
- frontmatter는 제거된 뒤 본문만 실제 메모리 콘텐츠로 주입되며, `paths:`가 없는 문서는 기존처럼 항상 적용된다.
- [AgentMemoryService.cs](/E:/AX%20Copilot%20-%20Codex/src/AxCopilot/Services/AgentMemoryService.cs)
- 간단한 glob 매처를 추가해 `*`, `**`, `?` 패턴을 지원한다.
- 현재는 `.ax/rules/*.md` 같은 프로젝트 규칙 파일을 `claw-code`의 경로 범위 rules와 비슷하게 운영할 수 있는 수준까지 올라온 상태다.