Skip to content

feat(c-generative-ui): airline operations KPI dashboard (PR 3 of 4)#355

Merged
blove merged 10 commits into
mainfrom
claude/c-generative-ui-aviation
May 16, 2026
Merged

feat(c-generative-ui): airline operations KPI dashboard (PR 3 of 4)#355
blove merged 10 commits into
mainfrom
claude/c-generative-ui-aviation

Conversation

@blove
Copy link
Copy Markdown
Contributor

@blove blove commented May 16, 2026

Summary

  • PR 3 of 4 in the c-* aviation theme rollout. Converts the c-generative-ui cockpit demo from a SaaS metrics dashboard to an airline operations KPI dashboard.
  • Swaps dataset (KPI snapshot, on-time trend, flights-by-airline, recent disruptions), 4 tools, prompt, and emit_state per-tool branches. Graph topology and Angular view components are unchanged.
  • Mirrors the rewrite into the per-capability standalone backend AND fixes a long-standing prompt-path bug: graph.py referenced prompts/dashboard.md while the file was misnamed generative-ui.md. The standalone's index.ts promptAssetPaths entry was updated to match.

KPI mapping

Component Label Source tool
stat_card × 4 On-time %, Flights Today, Avg Delay, Load Factor query_airline_kpis
line_chart On-time % trend (12 mo) query_on_time_trend
bar_chart Flights by airline query_flights_by_airline
data_grid Recent disruptions query_recent_disruptions

Test plan

  • pnpm nx run cockpit-langgraph-streaming-python:build — green
  • pnpm nx run cockpit-chat-generative-ui-angular:build — green
  • pnpm nx test cockpit-chat-generative-ui-angular — 6 test files, 21 tests passing
  • Programmatic real-LLM smoke (umbrella backend): spec generates with all 7 aviation $state paths, all 4 aviation tools invoked
  • Manual chrome MCP smoke against running umbrella backend on real LLM:
    • "Show me the dashboard" → spec emitted, 4 tool calls fire (query_airline_kpis, query_on_time_trend, query_flights_by_airline, query_recent_disruptions), conversational summary correctly cites On-time %, Flights Today, Avg Delay, Load Factor + 12-month trend
    • "Why might on-time % have dipped in December?" → pure conversational reply citing real mock-data values (78.9% Dec, 82.6% Nov, 80.2% Jan, all matching ON_TIME_TREND), no JSON, no tools, no spec regen
  • Note: leaf view components (stat_card / line_chart / bar_chart / data_grid) currently render the chat-lib render-default-fallback ("Building UI…") instead of populated values. dashboard_grid and container render. This pattern is independent of this PR (no frontend code changed) and tracks with the chat-lib's state-event propagation for $state props — to be addressed in a follow-up that's orthogonal to the aviation conversion.

Files

  • cockpit/langgraph/streaming/python/src/aviation_data.py — appended KPI_SNAPSHOT, ON_TIME_TREND, FLIGHTS_BY_AIRLINE, RECENT_DISRUPTIONS
  • cockpit/langgraph/streaming/python/src/dashboard_tools.py — rewrite (4 aviation tools)
  • cockpit/langgraph/streaming/python/src/dashboard_graph.pyemit_state per-tool branches
  • cockpit/langgraph/streaming/python/prompts/dashboard.md — aviation framing, state paths, example spec
  • cockpit/chat/generative-ui/python/src/dashboard_tools.py — mirror (analytics inlined)
  • cockpit/chat/generative-ui/python/src/graph.py — mirror emit_state
  • cockpit/chat/generative-ui/python/prompts/dashboard.md — created (mirrors umbrella)
  • cockpit/chat/generative-ui/python/prompts/generative-ui.md — deleted
  • cockpit/chat/generative-ui/python/src/index.tspromptAssetPaths updated to dashboard.md
  • Spec + plan in docs/superpowers/{specs,plans}/

🤖 Generated with Claude Code

blove and others added 9 commits May 15, 2026 22:45
PR 3 of 4 in c-* aviation theme rollout. Converts the c-generative-ui
demo from SaaS metrics to airline operations KPIs. Graph topology and
Angular view components stay untouched; only dataset, 4 tools, prompt,
and emit_state mapping change. Standalone copy gets parity rewrite plus
the stale prompt-path fix.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
11 tasks: extend aviation_data.py with analytics fixtures, rewrite
dashboard_tools.py with 4 aviation @tool functions, update emit_state
state-path mapping, rewrite dashboard.md prompt, mirror into standalone
backend (with prompt-path bug fix), build verification, REQUIRED chrome
MCP smoke against real LLM, PR open.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 16, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
cacheplane Ready Ready Preview, Comment May 16, 2026 6:58am

Request Review

Stale module docstrings in dashboard_graph.py and the standalone
graph.py still read "SaaS metrics dashboard". Updated to "airline
operations KPI dashboard" to match the actual functionality post-PR-3.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@blove blove force-pushed the claude/c-generative-ui-aviation branch from 41ae9dc to 5a1cf20 Compare May 16, 2026 06:56
@blove blove merged commit ef4f8e2 into main May 16, 2026
15 of 16 checks passed
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