Awareness across workspaces

open…
osebo50d ago

Does Claude have awarness across workspaces?

3 repliesoldestnewest
Osebotfable-5-150d ago

Short answer: no. Everything Claude sees on a run is scoped to the thread's workspace. Humans can read every workspace, but Claude's view is a single workspace at a time.

Checked each of the four channels that feed a run (threadide/lib/context.ts → assembleContext):

ChannelScopeWhere
Memory notes (<memory> block)listMemory(ws.id) — only this workspace's noteslib/data.ts:415
Memory candidateslistMemoryCandidates(ws.id)lib/data.ts:377
Related posts injected into the promptsearchRelatedPosts(ws.id, …) filters on post_embeddings.workspace_idlib/embeddings.ts:83
search_threads tool mid-runsame function, with job.thread.workspaceIdapp/api/internal/jobs/[id]/search/route.ts:15

Plus save_memory writes to (workspace_id, key) — the PK on memory_notes — so there is no such thing as a global note. The sandbox also only checks out the workspace's repos. General threads (workspace_id IS NULL) are never embedded (embedPost is a no-op without a workspace) and can't run Claude at all.

One wording gotcha: the search_threads tool description says "across all repos" — that means all repos within the workspace, not all workspaces.

If you want cross-workspace awareness, the access model already allows it (any signed-in user can read every workspace, so there's no privacy wall to respect). The natural options, smallest first:

  1. search_threads gets a scope: "workspace" | "all" param — drop the workspace_id filter when all, and prefix hits with the workspace name. Zero schema change; lets Claude look things up elsewhere when it decides to.
  2. Global memory notes — make memory_notes.workspace_id nullable (new migration), inject NULL-workspace notes into every run, and give save_memory a global: true flag. Good for things like "we use Resend for email everywhere" that aren't repo-specific.
  3. Cross-workspace related-post retrieval in the prompt — same filter drop in assembleContext, but I'd keep it off by default: the decider rerank would need to work harder to keep other projects' conventions from leaking in as noise.

Happy to do (1), (1)+(2), or something else — say which and I'll ship it in this thread.

oseboasked Osebot50d ago

Does claude have an understanding of all of the threads in a workspace?

Osebotfable-5-150d ago

No — not "all of them", and not as a list. Within a workspace Claude has selective, retrieval-based awareness of other threads, not a standing picture of everything that's been discussed. Here's exactly what a run gets (threadide/lib/context.ts → assembleContext):

WhatCoverage of other threads
The current threadFull. Verbatim up to 30 posts (each clipped at 6k chars); beyond that, the stored threads.summary plus the last 12 posts.
Memory notes (<memory> block)Indirect. Every note in the workspace is injected on every run — this is the only thing that's truly "all of it". But it's what past runs chose to save_memory, not the threads themselves.
Related posts (<related_from_other_threads>)Selective. The thread title + triggering post are embedded, pgvector returns the top 16 posts from other threads with cosine similarity > 0.35, the decider model reranks for relevance (confidence ≥ 0.5), and at most 8 posts make it into the prompt — individual posts, clipped to 2k chars, not whole threads.
search_threads toolOn demand. Same embedding search, up to 20 hits per call, Claude decides when and what to query.
Memory candidatesHuman posts a classifier flagged as possibly durable, shown so Claude can promote them to notes.

What Claude does not have:

  • No index/list of thread titles in the workspace — it can't tell you "there are 14 threads, here they are".
  • No full text of other threads; only posts that happened to be semantically similar to the current task. A thread that's relevant but worded differently won't surface (e.g. this thread's question would never pull in a thread titled "fix the ☰ button").
  • No awareness of thread status elsewhere (what's open, merged, waiting) unless it appears in a retrieved post.
  • The whole mechanism depends on embeddings existing: embedPost runs on post creation, so posts written before embeddings were enabled (or during an embedding-provider outage) are invisible to retrieval.

Concretely, on this very run the retrieval returned nothing (<related_from_other_threads>(none found)</related_from_other_threads>) — the memory notes are what gave me the file paths above, not other threads.

If you want broader workspace awareness, options in increasing cost:

  1. Thread index in the prompt — inject a compact list of the workspace's threads (title, status, updated-at, maybe one-line summary) into the system prompt. Cheap (~30–50 tokens per thread), gives Claude a map so it can search_threads deliberately. Would want a cap/recency window for busy workspaces.
  2. Per-thread summaries as a retrieval unit — threads.summary already exists for long threads; generate one for every thread on close and embed it alongside posts, so whole-thread gist competes in search rather than only individual posts.
  3. list_threads tool — let Claude page through titles/statuses mid-run instead of relying on similarity.

(1) is the one I'd do first; say the word and I'll ship it here.