Files
Maven/docs/plans/08-hearing.md
kami 5fe8f228c1 feat(mavweb): /ecosystem page consuming Nexus/Praxis/Hexis + shell fixes
Add a read-only /ecosystem page that consumes the sibling services'
JSON APIs (Nexus entities, Praxis attention, Hexis capabilities),
fetched concurrently with honest per-panel error states. Siblings stay
headless — mavweb is their human surface (arch §16). Wired via mavweb
-nexus/-praxis/-hexis flags; mavweb joins the ecosystem compose network.

Fix mobile horizontal overflow across all pages: .content is a flex
child with default min-width:auto, so it refused to shrink below the
tables' intrinsic width. min-width:0 lets wide tables pan inside .scroll
instead of dragging the page sideways. Verified via CDP geometry check
(scrollWidth === clientWidth at 430px).

Also includes in-progress Ethos UI redesign, ecosystem deploy compose,
and planning docs.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-19 22:04:23 +04:00

2.7 KiB

Plan: Hearing — Audio Stream Monitoring & Meeting Summarization

Goal: Maven can "hear" ambient audio from workpc — microphone input during meetings, system audio — and on demand (or on trigger) produce transcripts, summaries, or extract action items. A typical use case: "Maven, запиши встречу" starts capture, "хватит" stops it, and Maven writes a summary note.

Done when:

  • internal/audio/capture.go — remote microphone capture client (receives PCM stream from workpc over WebSocket or the existing voice TCP protocol)
  • internal/stt/ — streaming transcription (uses existing stt.Transcriber interface, extended with streaming support)
  • Meeting capture triggered by voice command (IntentCapture) or configurable keyword ("maven record")
  • Raw audio is either streamed to STT in real-time or saved to a WAV file and transcribed after capture ends
  • Transcription + LLM summary is written as a note (source:capture:meeting) through ipc.CoreAPI
  • New mavheary module (cmd/mavheard/) — the workpc-side agent that captures mic/speaker audio and streams it to mavend

Scope:

  • New cmd/mavheard/ — workpc-side agent: captures microphone (PortAudio or ALSA arecord), streams over WebSocket to mavend
  • internal/audio/ extended with capture types: MicCapture, SystemCapture, FileCapture
  • internal/stt/stt.go extended with StreamingTranscriber interface (or reuse existing with chunked input)
  • Router: new IntentCapture intent for start/stop commands
  • Reuses internal/llm.Client for summarization
  • Reuses internal/voice/server.go TCP protocol for streaming audio

Steps:

  1. Create cmd/mavheard/main.go — workpc-side daemon: captures microphone via arecord pipe or PortAudio, opens WebSocket or TCP connection to mavend, streams PCM frames
  2. Create internal/audio/capture.goCapture interface: Start(), Stop(), AudioCh <-chan Audio; implement MicCapture (reads from mavheard stream) and FileCapture (reads WAV)
  3. Extend internal/stt/stt.go — add TranscribeStream(ctx, audio <-chan Audio) (string, error) to Transcriber interface; Stub returns empty; Remote forwards chunks to worker socket
  4. Add IntentCapture to internal/router/intent.go — slots: Action ("start"/"stop"/"status"), Duration
  5. Wire capture handler in cmd/mavend/voice.go:reactiveHandler — start = spawn goroutine receiving audio, stream to STT; stop = finalize, send to LLM for summarization, write note via WriteNote
  6. Add capture config to voice block in config.Config{capture_enabled, capture_timeout}
  7. Test with a recorded WAV file — simulate a meeting, verify transcription + summary note is created