Skip to content

feat(memory): assignment 노트는 필요할 때 찾는다, 매 턴 싣지 않는다 (4.100.0) - #172

Merged
CocoRoF merged 2 commits into
mainfrom
feat/assignment-recall
Oct 23, 2026
Merged

CocoRoF merged 2 commits into
mainfrom
feat/assignment-recall

Conversation

@CocoRoF

@CocoRoF CocoRoF commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

무엇을 바꿨나

assignment 노트는 필요할 때 찾는다. 매 턴 싣지 않는다.

4.99.0 은 열린 assignment 노트를 매 턴 프롬프트에 실었다. 진행 중인 대화는 단기 기억 창에 원문으로 이미 있으므로, 같은 지시가 두 번 들어가고, 먼저 써 둔 노트는 방금 한 말보다 뒤처질 수 있다. 다른 대화의 열린 일도 상관없는 턴마다 "따르라" 는 말과 함께 들어갔다.

목표 장면은 나중에 사용자가 "예전에 했던 그 편집에서 하나 고치고 싶어" 라고 할 때, 메모리로 그 일을 찾아 이어 가는 것이다.

  1. 찾는다: assignment 노트는 그 턴의 기억 검색에 오른다. 모델이 memory_search·memory_list(tag="assignment") 로 찾기도 한다.
  2. 어디서 했는지 안다: memory_write 가 노트를 쓴 대화를 frontmatter written_in 에 적는다. 모델이 아니라 메모리가 적고, memory_read 가 보여 준다.
  3. 원문까지 읽는다: ConversationHistory(conversation=<id>) 가 그 사용자의 다른 대화를 원문으로 읽는다. 열 수 있는지는 호스트(provider.session_stm)가 정한다.

메모리 지침: 노트에는 사용자의 말·조건과 한 일(파일·자리·결과)을 남긴다. 사용자가 예전 일을 가리키면, 행동하기 전에 메모리에서 찾고 노트와 그 대화를 읽는다.

확인

  • tests/unit/test_assignment_memory.py 6개:
    • 상관없는 턴에는 실리지 않는다.
    • 그 일을 가리키는 말은 검색이 찾는다.
    • written_in 이 찍히고, 고쳐 써도 남는다.
    • 다른 대화는 호스트가 열 때만 읽힌다.
    • 지침 문구를 확인한다.
    • 끝에서 끝까지 확인한다: 대화 A 에서 편집하고 노트를 남긴 뒤, 대화 B 에서 "예전에 했던 그 편집" 으로 검색 → 노트 → A 의 원문까지 이어진다. 모델의 선택은 대본이다.
  • 전체 6,233 passed, 18 skipped. ruff, format, mypy, gen_event_docs 통과.

🤖 Generated with Claude Code

CocoRoF and others added 2 commits October 23, 2026 13:42
…very turn (4.100.0)

4.99.0 loaded the open assignment notes into every turn. The conversation in
progress is already in the context as it happened (the short-term window), so its
instructions came twice, a note written earlier could lag behind what was just said,
and other conversations' open work rode along in unrelated turns with "follow them".

The scenario is "the edit we did before, change one thing", answered through memory:
- assignment notes are found by the turn's memory search and by the agent
  (memory_search, memory_list(tag="assignment"));
- memory_write stamps the conversation a note was written in (frontmatter
  written_in), keeping earlier ones and other frontmatter on rewrite; memory_read
  shows it;
- ConversationHistory(conversation=<id>) reads another conversation of this user's
  word for word when the host opens it (provider.session_stm).
- The guidance says to keep what was done (files, places, results) in the note and
  to look earlier work up in memory before acting.
- Removed: the per-turn Assignments section and retriever layer; event
  memory.assignments_loaded retired (catalogue v21).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…nership query)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@CocoRoF
CocoRoF merged commit 2b894f7 into main Oct 23, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant