| id | session-drift | ||||||
|---|---|---|---|---|---|---|---|
| name | Session Drift | ||||||
| group | session-hygiene | ||||||
| severity | medium | ||||||
| scope | sessions | ||||||
| version | 1 | ||||||
| tags |
|
||||||
| thresholds |
|
Detects sessions that cover too many different task types, confusing the AI context window.
{{count}} sessions cover {{extra.maxWorkTypes}}+ different task types. Mixed-purpose sessions confuse the AI context.
Start a new session when switching task types (bug fix to feature, docs to testing, etc.). Focused sessions get better responses.
{{extra.workspace}}: {{extra.workTypes}}
scan: sessions
match: requestCount >= thresholds.minReqsPerSession AND workTypeCount(requests) >= thresholds.maxWorkTypes
aggregate: count
check: count > thresholds.minSessions
examples: {{workspaceName}}: {{workTypeCount(requests)}} work types in one session