diff --git a/README.md b/README.md index 7c4dea82..a856e529 100644 --- a/README.md +++ b/README.md @@ -666,7 +666,7 @@ Memories decay over time (Ebbinghaus curve). Frequently accessed memories streng | Hook | Captures | |------|----------| -| `SessionStart` | Project path, session ID | +| `SessionStart` | Project path, session ID, model, agent identity | | `UserPromptSubmit` | User prompts (privacy-filtered) | | `PreToolUse` | File access patterns + enriched context | | `PostToolUse` | Tool name, input, output | @@ -1109,6 +1109,32 @@ Full endpoint list: [`src/triggers/api.ts`](src/triggers/api.ts) +`POST /agentmemory/session/start` accepts optional session metadata so teams can +distinguish which client, model, or agent role created a session: + +```json +{ + "sessionId": "ses_123", + "project": "/repo", + "cwd": "/repo", + "model": "claude-sonnet-4-6", + "agent": { + "client": "claude-code", + "model": "claude-sonnet-4-6", + "agentType": "planner", + "sessionSource": "startup" + }, + "metadata": { + "taskType": "refactor", + "agentVersion": "2.1.0" + } +} +``` + +Recall and context results include compact session attribution, so agents can see +which client/model/role produced a retrieved observation instead of receiving an +opaque session ID only. + ---
No sessions yet. Start a coding session with agentmemory hooks enabled.
| Project | Status | Obs | Started |
|---|
| Project | Agent | Status | Obs | Started |
|---|---|---|---|---|
| ' + esc(s.project ? s.project.split('/').pop() : s.id.slice(0,8)) + ' | '; + html += '' + esc(truncate(agentLabel, 38)) + ' | '; html += '' + esc(s.status) + ' | '; html += '' + (s.observationCount || 0) + ' | '; html += '' + esc(shortTime(s.startedAt)) + ' |