Skip to content

feat(gamification): audio-sme ideas — blocked alert, spawn sound, task arc, @mention ping#180

Merged
jsell-rh merged 17 commits intomainfrom
feat/gamification
Mar 12, 2026
Merged

feat(gamification): audio-sme ideas — blocked alert, spawn sound, task arc, @mention ping#180
jsell-rh merged 17 commits intomainfrom
feat/gamification

Conversation

@jsell-rh
Copy link
Owner

Summary

Four new audio cues based on audio-sme brainstorm (ideas #2, #3, #6, #9, #12 from TASK-048):

#2 Dissonance Flag (playBlockedAlert)

  • Minor second interval (A4 + A#4 triangle/sine) — inherently tense but not alarming
  • Fires when an agent transitions INTO blocked or error (not on every update)
  • Fills the highest-value gap: operators with 15 agents need audio triage of problems

#3 The Arc (playTaskTransition)

  • →in_progress: rising 330→523Hz sweep ("starting")
  • →review: C5 + D5 suspended second chord ("waiting, anticipating")
  • →done: existing playSuccess() (unchanged)
  • Wired to both local drag-drop and remote task_updated SSE events
  • Tells the full emotional story of a task's life in sound

#6 Warp Arrival (playAgentSpawn)

  • 200→1200Hz sweep + resonant triangle ring-off
  • Fires on agent_spawned SSE event (alongside existing CSS warp animation)
  • Skipped entirely under prefers-reduced-motion

#9 @Mention Ping (playMentionPing)

  • C6 (1046.5Hz) percussive tone — higher and shorter than message chime
  • Fires once per agent_message event containing a valid @mention
  • Completes the mention feedback loop (visual pulse ring + audio)

#12 Motion-Sound Parity

  • prefersReducedMotion detection at module load
  • Halves volume on all new sounds; skips sweeps; replaces with shorter tones

Test plan

  • npm run build passes ✓
  • Enable sounds; agent goes blocked → hear dissonance alert (not on every update)
  • Drag task → in_progress → hear rising tone; → review → hear suspended chord
  • Remote agent moves task via SSE → same arc sounds fire
  • Agent spawns → hear warp arrival sound
  • Message with @agent-name → hear C6 ping alongside pulse ring
  • prefers-reduced-motion → all new sounds quieter, no sweeps

🤖 Generated with Claude Code

jsell-rh and others added 17 commits March 12, 2026 16:23
…date

Status pulse animations (StatusBadge.vue):
- active: already had ping dot (unchanged)
- idle: slow breathe animation (opacity 1.0↔0.45, 3s ease-in-out)
- blocked/error: subtle jitter (±1.5px translateX, 0.4s loop)
- done: no animation — calm green glow (static)
- prefers-reduced-motion: all animations disabled

Event feed stagger (EventLog.vue):
- New rows slide in from slightly above (translateY -5px → 0, 0.18s)
- animation-fill-mode: both keeps initial state before start
- prefers-reduced-motion: disabled
- Works on DOM insertion — no re-animation on filter/re-render

Spec update (gamification.md):
- Mark 1.2 (sounds) and 2.2 (all-agents-idle) as implemented
- Add 2.3 agent status pulse rings (now implemented)
- Add 2.4 agent mood/vibes field
- Upgrade 3.5 sound themes to implemented
- Add 3.6 agent signature chimes, 3.7 @mention pulse, 3.8 event feed stagger
- Remove deterministic SVG avatar item (boss preference: keep existing avatars)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…print-fix

Kanban card spring-drop (KanbanColumn.vue):
- Cards enter with a physical spring animation: drop from above, slight
  overshoot (bounce +5px), then settle. CSS @Keyframes, 0.35s.
- prefers-reduced-motion: animation disabled.

@mention pulse animation (App.vue + AppSidebar.vue):
- SSE agent_message handler now parses @mentions from message content.
- Mentioned agent's card in sidebar pulses with a 3s ring animation
  (box-shadow expand/fade, CSS @Keyframes).
- Reactive mentionedAgents Set with auto-expiry timers.
- AppSidebar accepts mentionedAgents prop and applies .mention-pulse class.

Fleet Vibe roll-up (SpaceOverview.vue):
- Computed fleetVibe shows a live emoji + label in the space header
  based on agent status distribution (Shipping / Blocked / On fire / etc.).
- Tooltip shows "Fleet vibe: <label>" on hover.
- Updates reactively with every SSE agent_updated event.

Sprint-complete detection fix (App.vue):
- No longer triggers on page load (when agents are already idle).
- Requires at least one agent to have been `active` since the last
  celebration. Resets after celebrating, so next one needs a new active phase.
- Requires at least 2 agents — single-agent spaces don't have sprint semantics.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Agent spawn warp animation (App.vue + AppSidebar.vue):
- When agent_spawned SSE fires, adds agent to spawnedAgents set (600ms).
- AppSidebar applies .agent-spawn CSS class: scale(0.35) → overshoot →
  settle(1.0) with a ring burst. Feels like a portal opening.
- Clears automatically after 600ms animation.

PR badge shimmer (AppSidebar.vue):
- PR links (#N) on agent cards get a traveling light shimmer animation
  (CSS background-position sweep, 2.4s loop) whenever the agent has a PR.
- Visual signal: "code is out there, awaiting review."

Priority-based confetti variations (useConfetti.ts + KanbanView.vue):
- Critical tasks: gold/orange particle palette, 2x count (130), wider
  blast radius, 2.4s duration.
- High priority: 1.4x count (90), slightly faster spread.
- Medium: standard burst (65 particles).
- Low: lighter burst (40 particles).
- KanbanView passes task.priority to celebrate() on drag-drop and
  SSE-triggered task_updated to done transitions.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…mentation status

Mark Tier 2.3-2.10 as implemented. Add Tier 3.9-3.18 from second
brainstorm round (audio ticks, emoji reactions, streaks, ship-it
broadcast, co-working indicators, standup digest, presence, leaderboard,
chromashift).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… fields

The MCP spawn_agent path (lifecycle.go:spawnAgentService) was broadcasting
the bare agent name string as the agent_spawned SSE payload. The frontend
SSEAgentSpawned type expects {space, agent} JSON, so data.space and
data.agent were undefined — causing '[undefined] agent spawned' in the
event log and 'Failed to load space undefined: 404' errors.

Fix: use json.Marshal({space, agent}) matching the handlers_agent.go path.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Agent signature chimes (useNotifications.ts + App.vue):
- Each agent gets a unique 2-note chord from a hash of their name.
- Pentatonic scale ensures all chords are consonant. Plays once per
  page load per agent on first agent_updated SSE event.
- Resets on space navigation so agents get their chime each visit.

Activity tick (useNotifications.ts + App.vue + SettingsView.vue):
- 4ms white-noise burst on each agent_updated SSE event. Very subtle.
- Off by default; toggled in Settings via new "Ambient activity tick" switch.
- Stored in localStorage (boss_activity_tick_enabled).

TASK-035 guard (App.vue):
- agent_spawned handler drops events with missing space/agent.
- Prevents loadSpace("undefined") from partial payloads.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Keep the updated @mention protocol note referencing PR #171 (garden docs merged).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- H1: make `now` a reactive ref in KanbanView, updated via setInterval
  every 60s so overdue detection stays accurate without page reload
- H2: replace browser confirm() in TaskDetailPanel delete with AlertDialog
  component for consistent UX and keyboard accessibility
- H6: add data-search-focus attribute to Kanban search input for
  Playwright and keyboard shortcut targeting
- H7: surface send errors in ConversationsView inline compose —
  previously silently swallowed, now shows error text below form
- TASK-038: fix agent selector dropdown overflow in ConversationsView
  new-message picker by replacing ScrollArea (which doesn't apply
  max-height correctly) with a plain div with max-h-48 overflow-y-auto

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- H3: Tasks/Conversations sidebar nav items now show active state via
  useRoute() — was hardcoded :data-active="false"
- H4: Remove duplicate unread count badge on Conversations nav item;
  icon dot badge is sufficient, SidebarMenuBadge was redundant
- M1: Guard sound theme preview behind soundEnabled — selecting a theme
  no longer plays audio when sounds are disabled
- M13: pr-shimmer animation now conditional on agent.status === 'active';
  previously applied to all agents with a PR regardless of state

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- C2: implement 'i' keyboard shortcut (navigate to space overview);
  was documented in help overlay but had no handler
- M2: add 'Change' label to task assignee dropdown trigger when task
  is already assigned — lone ChevronDown was undiscoverable
- M3: store due dates at noon UTC (T12:00:00Z) instead of midnight UTC
  (T00:00:00Z); midnight rolls back a day for all GMT+ users
- M4: Assignee and Label filter dropdowns highlight in primary color
  when an active filter is set, matching the Overdue button pattern
- M10: add 'no tasks match your filters' empty state + Clear filters
  button when all columns are empty due to active filters
- M11: add .prevent to @keydown.ctrl.enter on comment textarea so
  the default newline insertion is suppressed on submit
- M14: add 'Ctrl+Enter to send' hint below comment textarea

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… panel

The 'Create persona' link in AgentCreateDialog emitted open-personas
while the Dialog was still open. Both Dialog and Sheet use z-50 fixed
portals, causing the Sheet to render behind (or at same level as) the
Dialog overlay.

Fix: close agentCreateDialogOpen before emitting open-personas in
SpaceOverview. The dialog animates out, then the Personas sheet slides
in — clean stack, no z-index conflict.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add pitch micro-variation (±5%) and timing jitter (±15ms) to agent
  signature chimes so each play feels organic rather than robotic
- Extract _playAgentVoice() helper shared by auto-chime and preview
- Add previewAgentVoice() export — plays on demand regardless of
  once-per-session guard, for explicit user-triggered previews
- Add Volume2 button in AgentDetail header (only when sounds enabled)
  so users can hear an agent's unique voice from their profile

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…system

Keep _playAgentVoice helper with micro-variation and previewAgentVoice export
over the inlined version from main.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…k arc, mention ping

Based on audio-sme brainstorm (ideas #2, #3, #6, #9, #12):

- #2 Dissonance Flag: playBlockedAlert() — minor second interval (A4+A#4)
  fires when agent transitions INTO blocked or error state. Tense but
  not alarming; tells operator something needs attention.

- #3 The Arc: playTaskTransition(status) — rising sweep on →in_progress,
  suspended Csus2 chord on →review. Completes the emotional story that
  playSuccess() already starts at →done. Wired to both drag-drop and
  remote SSE task_updated events.

- #6 Warp Arrival: playAgentSpawn() — 200→1200Hz sweep + resonant ring.
  Fires on agent_spawned SSE, skipped under prefers-reduced-motion.

- #9 @Mention Ping: playMentionPing() — C6 percussive tone, distinct
  from message chime. Fires once per agent_message event that contains
  at least one valid @mention, alongside the existing CSS pulse ring.

- #12 Motion-Sound Parity: prefersReducedMotion check halves volume
  on all new sounds, skips sweeps, replaces with shorter tones.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…es, PR shipped, collaboration chord

- soundVolume ref (0-100% slider) applied via tone()/sweep() multiplier
- soundCategories ref with 5 categories: urgent, events, celebrations, ambient, social
- SOUND_CATEGORY_META for rendering category toggles in SettingsView
- isCategoryEnabled() helper replaces bare soundEnabled checks in all play* fns
- SettingsView: volume slider + per-category toggle grid
- playPRShipped(): descending 700→350Hz sweep + landing tone (events)
- playCollaborationChord(): both agents' pentatonic voices as chord (social)
- App.vue: wire playPRShipped via currentSpace watch, playCollaborationChord in agent_message

Audio Control Center implements audio-sme idea #11 (impact 5)
PR shipped implements audio-sme idea #10
Collaboration harmony implements audio-sme idea #8
…o category system

Keep per-category isCategoryEnabled() checks (HEAD) over simple soundEnabled
guard from main. HEAD has the Audio Control Center with category toggles.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@jsell-rh jsell-rh merged commit 8ff687d into main Mar 12, 2026
1 check passed
@jsell-rh jsell-rh deleted the feat/gamification branch March 12, 2026 21:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant