anthropics / anthropics/claude-code

[FEATURE] Local status feed from the desktop app (Cowork, Chat) for ambient "Claude needs you" tools

Aperta
#92,288 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
area:cowork area:desktop area:integrations enhancement platform:windows
Lingua principale
Python
Stelle
145k
Fork
23.1k
Metriche di merge delle PR
Metriche PR in attesa

Descrizione

### Preflight Checklist

- [x] I have searched [existing requests](https://github.com/anthropics/claude-code/issues?q=is%3Aissue%20label%3Aenhancement) and this feature hasn't been requested yet
- [x] This is a single feature request (not multiple features)

### Problem Statement

I built a small desktop pet for Windows that shows what Claude needs from me: it works while Claude works, waves a flag when a task finishes, and hops when Claude is waiting on a permission or an answer. Clicking it opens the right session. Source, a demo GIF, and a release: https://github.com/rubberdonut67/clawdbot

![Claw'dbot demo](https://github.com/rubberdonut67/clawdbot/raw/main/docs/clawdbot-demo.gif)

For **Claude Code** this was straightforward because hooks exist: eleven HTTP hooks into a loopback server give instant, reliable state for every session.

For **Cowork** in the desktop app there is no equivalent, so the pet has to read two undocumented things on the host:

- the app's Windows toast notifications, out of the notification store (`wpndatabase.db`), and
- the app's log file (`main.log`).

That works today, but every part of it is unpublished behaviour that changes with silent app updates. Measured on Windows 11 with desktop app 1.46388.4:

- The only "needs you" signal for a Cowork session is the `cowork-awaiting-cse_…` / `cowork-idle-cse_…` toast. In-app permission prompts raise no toast at all while the app window is visible.
- Answering a prompt inside the app leaves no trace on the host: the toast row stays and nothing is logged, so a tool cannot tell the ask was handled.
- "Working" has to be inferred from `[remote-bash] user=rcw-… mounts=…` log lines, which cloud-only turns never write.
- **Chat** has no host-side signal whatsoever.

So an ambient "Claude needs you" indicator (a pet, a lamp, a tray icon, a Stream Deck key) is either Claude-Code-only or reverse-engineered and fragile. #89435 describes the same gap from the Hardware Buddy side: prompts that never reach the device.

### Proposed Solution

A local, opt-in status feed from the desktop app, covering Claude Code, Cowork, and Chat sessions: a loopback WebSocket or named pipe (enabled in settings), emitting one JSON event per state change with at least:

- session id, surface (`code` / `cowork` / `chat`), title, and project or folder;
- state: `working`, `waiting_for_user` (with a kind: permission, question, idle), `done`, `error`;
- a deep link to open the session.

The desktop app already ships almost exactly this shape for hardware: the Buddy maker feed over Bluetooth, a JSON heartbeat with a `waiting` flag. A software version of that feed on loopback would make every ambient tool trivial to build and robust across app updates, and it would give the Hardware Buddy and any software companion the same source of truth.

### Alternative Solutions

- Keep reading the notification store and log (what the pet does now): works, but breaks silently on app updates and cannot see in-app answers or Chat at all.
- Polling the cloud sessions API with the CLI's OAuth token: undocumented, and reusing a credential for it is not something I want to ship to other people.
- Extending hooks to the desktop app's Cowork and Chat sessions would also solve it, but a push feed seems closer to what the Buddy feature already does.

### Priority

Medium: today's workaround exists but is fragile by construction.

### Feature Category

Desktop app / integrations (Cowork, Chat, Hardware Buddy).

### Use Case Example

Start a Cowork task on a granted folder, switch to another window. When the task hits a permission prompt or finishes, the pet on the desktop hops and shows the session title and the prompt text; clicking it opens that session in the app. Today that only works when the app raises a toast, which it does not do for in-app prompts while its window is visible, and never for Chat.

Happy to share everything that was measured (tags, texts, log formats, timings) if it helps; it is documented in the source comments under `src-tauri/src/cowork/` in the repo above.

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Direzione di ricerca

Start by reading this issue, linked issue #89435, and the measured notes mentioned under src-tauri/src/cowork/ in the linked clawdbot repo. The requested outcome is an opt-in local desktop-app feed, via WebSocket or named pipe, that emits session state changes for Code, Cowork, and Chat with deep links. There are no in-repo files or tests named here, so this needs maintainer guidance before implementation.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
ai-infra-agents, python
Ambito
ai-infra-agents, api, desktop
Tipo di issue
Funzionalità
Difficoltà
5/5
Tempo stimato
Più di una settimana
Stato di attività
Attiva
Chiarezza
Abbastanza chiara
Idoneità per principianti
28/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.