From 24d485f42f5b1405d2fab13f2f497d5edd3b5300 Mon Sep 17 00:00:00 2001 From: Nourrisse Florian <3023852+Flo5k5@users.noreply.github.com> Date: Mon, 13 Apr 2026 15:29:10 +0200 Subject: [PATCH] feat: activate local-only team memory in open build (#648) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat: activate local-only team memory in open build Enable the TEAMMEM feature flag and the isTeamMemoryEnabled() gate so team memory works in local-only mode for all open-build users. Team memory is a shared memory system scoped per-project, stored at ~/.claude/projects//memory/team/. The implementation is already almost entirely local — extraction, UI, prompts, file detection, and path validation all work on local files. The cloud sync overlay (OAuth + API) is cleanly separated: the watcher does an early return when OAuth is unavailable, so the feature degrades gracefully to local-only storage with no crashes. What works locally: - Memory extraction (auto + team, combined prompts) - Team MEMORY.md loaded into conversation context - File selector with team memory folder option - Collapse tracking (read/search/write counts) - Secret scanning before persistence - Path validation + symlink protection What requires OAuth (not available in open build): - Cloud sync between team members - Automatic push/pull via file watcher * fix: preserve opt-out gate for team memory via feature flag Change isTeamMemoryEnabled() to read tengu_herring_clock with default true instead of unconditional return true. This enables team memory by default while preserving user opt-out via ~/.claude/feature-flags.json. --- scripts/build.ts | 2 +- src/memdir/teamMemPaths.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/build.ts b/scripts/build.ts index 52b7953c..33df301a 100644 --- a/scripts/build.ts +++ b/scripts/build.ts @@ -33,7 +33,7 @@ const featureFlags: Record = { BUILTIN_EXPLORE_PLAN_AGENTS: true, CONTEXT_COLLAPSE: false, COMMIT_ATTRIBUTION: false, - TEAMMEM: false, + TEAMMEM: true, UDS_INBOX: false, BG_SESSIONS: false, AWAY_SUMMARY: false, diff --git a/src/memdir/teamMemPaths.ts b/src/memdir/teamMemPaths.ts index 1a13ae7e..13a6ed87 100644 --- a/src/memdir/teamMemPaths.ts +++ b/src/memdir/teamMemPaths.ts @@ -74,7 +74,7 @@ export function isTeamMemoryEnabled(): boolean { if (!isAutoMemoryEnabled()) { return false } - return getFeatureValue_CACHED_MAY_BE_STALE('tengu_herring_clock', false) + return getFeatureValue_CACHED_MAY_BE_STALE('tengu_herring_clock', true) } /**