diff --git a/.gitignore b/.gitignore index a5c57bc2..658801be 100644 --- a/.gitignore +++ b/.gitignore @@ -208,6 +208,11 @@ __marimo__/ # Claude Code (local config, agents, settings) .claude/ +.agents/ + +# Temp/generated files +backend/test_results.txt +frontend/stats.html # Railway CLI (local tooling) node_modules/ diff --git a/docs/plans/2026-02-04-feature-ideas-brainstorm.md b/docs/plans/2026-02-04-feature-ideas-brainstorm.md index 3c5c231e..e73adfd7 100644 --- a/docs/plans/2026-02-04-feature-ideas-brainstorm.md +++ b/docs/plans/2026-02-04-feature-ideas-brainstorm.md @@ -448,20 +448,20 @@ Turns ResolutionFlow from a tool you visit per-ticket into something you keep op ### Mid-term (build next, medium effort, high value) -4. **Share Progress / Escalation** (Idea 2) — daily use for team collaboration -5. **Recurring Issue Detection** (Idea 8) — leverages existing data immediately -6. **Quick Actions Dashboard** (Bonus) — improves daily UX -7. **Path Analytics** (Idea 5) — needs session volume, start collecting data now +1. **Share Progress / Escalation** (Idea 2) — daily use for team collaboration +2. **Recurring Issue Detection** (Idea 8) — leverages existing data immediately +3. **Quick Actions Dashboard** (Bonus) — improves daily UX +4. **Path Analytics** (Idea 5) — needs session volume, start collecting data now ### Later (larger effort, needs foundation) -8. **Push Steps to Active Sessions** (Idea 4) — needs notification system -9. **Tree Health Scores** (Idea 9) — needs session volume + analytics infrastructure -10. **Multi-Tree Sessions** (Idea 7) — complex UX, large refactor +1. **Push Steps to Active Sessions** (Idea 4) — needs notification system +2. **Tree Health Scores** (Idea 9) — needs session volume + analytics infrastructure +3. **Multi-Tree Sessions** (Idea 7) — complex UX, large refactor ### Long-term vision -11. **AI Tree Intelligence** (Idea 10) — phased rollout, ultimate differentiator +1. **AI Tree Intelligence** (Idea 10) — phased rollout, ultimate differentiator --- diff --git a/docs/plans/2026-02-10-feature-ideas-brainstorm.md b/docs/plans/2026-02-10-feature-ideas-brainstorm.md new file mode 100644 index 00000000..a12e6168 --- /dev/null +++ b/docs/plans/2026-02-10-feature-ideas-brainstorm.md @@ -0,0 +1,285 @@ +# 10x Analysis: ResolutionFlow + +Session 1 | Date: 2026-02-10 + +## Current Value + +ResolutionFlow guides MSP engineers through structured troubleshooting decision trees, captures every step/decision/note, and exports professional ticket documentation. Target: Michael Chihlas uses it for 50% of tickets within 3 months. + +**Core loop:** Receive ticket → pick tree → follow guided path → take notes → export documentation → paste into PSA. + +**What works well:** The guided troubleshooting UX is solid. Tree editor supports rich content (markdown, PowerShell commands). Session capture is comprehensive. Export formats cover common needs. Step Library enables knowledge reuse. RBAC/multi-tenant foundations are strong. + +## The Question + +What would make this 10x more valuable — from "useful documentation tool" to "indispensable MSP operating system"? + +--- + +## Massive Opportunities + +### 1. Intelligence Loop: Session Data → Actionable Insights → Better Trees + +**What**: Every session captures rich data (path taken, time per step, outcomes, custom steps created) but today it evaporates after export. Build an analytics engine that mines session data to: surface trending issues, identify dead-end tree branches, recommend tree improvements, and predict what tree an engineer needs based on ticket keywords. + +**Why 10x**: This transforms ResolutionFlow from a static playbook into a **learning system**. Every session makes the product smarter. MSP managers get visibility they've never had — which trees work, which engineers are efficient, which clients have recurring problems. This is the moat: the more sessions run, the more valuable the platform becomes. No competitor can replicate your accumulated operational intelligence. + +**Unlocks**: + +- "Smart tree picker" — paste ticket description, get recommended tree +- Tree health scores — identify underperforming branches +- Auto-detect when custom steps should become permanent tree branches +- Manager dashboards with real ROI metrics (time saved, resolution rates) + +**Effort**: High (analytics pipeline, dashboards, recommendation engine) +**Risk**: Need enough session volume to be useful. Cold start problem for new teams. +**Score**: 🔥 **Must do** — this is THE compounding moat + +--- + +### 2. PSA Integration: One-Click Ticket Documentation + +**What**: Direct API integration with ConnectWise, Autotask, Kaseya BMS, and HaloPSA. When a session completes, one click pushes formatted documentation directly into the ticket. Better yet: start sessions FROM a ticket (pull ticket number, client name, issue description automatically). + +**Why 10x**: The current workflow breaks at the last mile — engineer copies export text, switches to PSA, pastes. This friction is the #1 adoption killer. Every extra click is a reason to skip ResolutionFlow and just wing it. Direct PSA integration makes the tool frictionless AND positions ResolutionFlow inside the tool engineers already live in. + +**Unlocks**: + +- Bi-directional flow: ticket → session → documentation → ticket +- Auto-populate client name, ticket number from PSA +- Pull client history from PSA into session context +- Time entry sync (PSA time tracking from session duration) + +**Effort**: High (multiple PSA APIs, OAuth flows, field mapping, each PSA is different) +**Risk**: PSA APIs are notoriously painful. ConnectWise alone could take weeks. Start with ONE (whichever Michael's MSP uses). +**Score**: 🔥 **Must do** — eliminates the biggest adoption barrier + +--- + +### 3. Client Intelligence: "What happened last time?" + +**What**: When starting a session, show the engineer a sidebar with: previous sessions for this client, known configurations, recurring issues, client-specific notes. Build a living client dossier from accumulated session data. + +**Why 10x**: MSPs manage dozens of clients. Engineers often handle tickets for clients they haven't worked with before. Today they dig through PSA history or ask colleagues. ResolutionFlow already captures client_name on sessions — aggregating this into a client profile transforms it from a troubleshooting tool into a **client knowledge base**. + +**Unlocks**: + +- "This client had the same VPN issue 3 times in 6 months" — pattern detection +- Client-specific tree customizations (e.g., "Acme uses Cisco, not Fortinet") +- Handoff quality — new engineer sees full client troubleshooting history +- Churn risk signals for MSP account managers + +**Effort**: Medium-High (client entity, aggregation, UI sidebar in session view) +**Risk**: Depends on consistent client naming (or PSA integration for canonical names) +**Score**: 🔥 **Must do** — obvious value, data already partially exists + +--- + +### 4. AI Copilot: "What should I try next?" + +**What**: An AI assistant within sessions that can: suggest next steps based on symptoms described in notes, generate PowerShell/CLI commands tailored to the situation, explain error messages, and recommend relevant KB articles or similar past sessions. + +**Why 10x**: This makes junior engineers perform like seniors. MSPs constantly struggle with training — juniors escalate too quickly, seniors are bottlenecked. An AI copilot that understands the tree context + session notes + client history could dramatically reduce escalation rates and resolution times. + +**Unlocks**: + +- "Paste the error message" → AI suggests likely cause + next tree branch +- Dynamic command generation (fill in hostnames, IPs from session context) +- Natural language search across all trees ("how do I fix BSOD after update?") +- Auto-generate tree drafts from freeform troubleshooting notes + +**Effort**: Very High (LLM integration, prompt engineering, context management, cost control) +**Risk**: Accuracy matters enormously — bad advice in IT troubleshooting can cause outages. Needs confidence indicators and human-in-the-loop. +**Score**: 👍 **Strong** — transformative but needs careful execution, do after intelligence loop + +--- + +## Medium Opportunities + +### 1. Step-Level Time Tracking + Resolution Outcomes + +**What**: Automatically capture duration at each tree step (timestamp on entry/exit). Add a "Did this resolve the issue?" prompt at session end with outcome categories (resolved, escalated, workaround, unresolved). Surface this in session history and analytics. + +**Why 10x**: This is the foundation for everything else. Without outcome tracking, you can't measure tree effectiveness. Without time tracking, you can't quantify ROI. This data answers: "Is ResolutionFlow actually saving us time?" — the question every MSP manager will ask before buying. + +**Impact**: Enables ROI dashboards, tree optimization, SLA compliance tracking +**Effort**: Low-Medium (timestamps exist, just need step-level granularity + outcome modal) +**Score**: 🔥 **Must do** — foundational data, low effort, unlocks analytics + +--- + +### 2. Tree Effectiveness Dashboard + +**What**: A dashboard showing: most-used trees, average resolution time per tree, completion rate, escalation rate, most-common paths taken (heatmap on tree visualization), and trees with high custom-step insertion (signals missing content). + +**Why 10x**: MSP managers have zero visibility into troubleshooting quality today. This dashboard sells the product to decision-makers (not just engineers). It answers: "Which trees need improvement?" and "Which engineers need training?" + +**Impact**: Turns ResolutionFlow from an engineer tool into a management tool — expands buyer persona +**Effort**: Medium (aggregation queries, dashboard UI, tree heatmap visualization) +**Score**: 🔥 **Must do** — sells to managers, not just engineers + +--- + +### 3. Tree Templates + Marketplace + +**What**: Pre-built tree packs for common MSP scenarios (M365 admin, Azure AD, network troubleshooting, endpoint management). Allow MSPs to publish and share tree templates. Eventually: a marketplace where top MSPs sell their proven playbooks. + +**Why 10x**: Building trees from scratch is the biggest adoption barrier after PSA integration. If an MSP can import a "Microsoft 365 Troubleshooting" pack on day one, time-to-value collapses from weeks to minutes. A marketplace creates network effects — more MSPs = more templates = more valuable for everyone. + +**Impact**: Eliminates cold start, creates community, potential revenue stream +**Effort**: Medium (template export/import, curation, marketplace UI is later) +**Score**: 👍 **Strong** — import/export is quick win, full marketplace is later + +--- + +### 4. Team Activity Feed + Collaboration + +**What**: A team-wide activity feed showing: sessions started/completed, trees created/updated, custom steps shared, and the ability to comment on sessions ("Hey, next time try X instead"). Add @mentions and notifications. + +**Why 10x**: MSPs are teams, not individuals. Knowledge sharing between engineers is where the real value compounds. Today a senior engineer's expertise lives in their head. Activity feeds make institutional knowledge visible and enable peer learning. + +**Impact**: Transforms solo tool into team platform, increases daily engagement +**Effort**: Medium (activity model, feed UI, notifications) +**Score**: 👍 **Strong** — high engagement driver, moderate effort + +--- + +### 5. Quick-Start from Clipboard + +**What**: Engineer pastes a ticket description or error message → ResolutionFlow analyzes it and suggests the most relevant tree + starting branch. One click to begin a pre-contextualized session. + +**Why 10x**: Eliminates the "which tree do I use?" friction. Engineers currently browse a library — with 50+ trees, this becomes a bottleneck. Clipboard analysis makes the tool feel intelligent and fast. + +**Impact**: Reduces session start time from 30s of browsing to 3s of paste-and-go +**Effort**: Medium (text analysis, tree matching — could be keyword-based initially, AI later) +**Score**: 👍 **Strong** — significant UX improvement, can start simple + +--- + +## Small Gems + +### 1. Session Timer (Visible Clock) + +**What**: A live timer in the session header showing elapsed time. Optionally, a "target time" per tree (e.g., "Password resets should take <5 min"). +**Why powerful**: Engineers are often unaware of time spent. Visible timer creates gentle urgency, helps with time entries, and provides data for analytics. Trivial to build. +**Effort**: Low (frontend-only, a `Date.now() - startedAt` display) +**Score**: 🔥 **Must do** + +### 2. Keyboard-First Navigation + +**What**: Number keys (1-9) to select options, Enter to continue, Escape to go back, Tab to focus notes. Full keyboard-driven troubleshooting. +**Why powerful**: Engineers troubleshoot while on calls or remoted into machines. Mouse-dependent UI slows them down. Keyboard shortcuts make the tool feel professional and fast — power users will love it. +**Effort**: Low (event listeners, already have `useKeyboardShortcuts` hook) +**Score**: 🔥 **Must do** + +### 3. "Repeat Last Session" Button + +**What**: One-click to start a new session on the same tree you last used, pre-filled with the same client name. +**Why powerful**: MSP engineers often handle batches of similar tickets. "I'm doing password resets all morning." Eliminating re-selection saves minutes across dozens of sessions. +**Effort**: Very Low (store last session reference, pre-fill modal) +**Score**: 🔥 **Must do** + +### 4. Session Draft Auto-Recovery + +**What**: If browser crashes or closes mid-session, auto-recover from the last saved state on next visit. Show a "Resume interrupted session?" prompt. +**Why powerful**: Losing a 20-minute troubleshooting session to a browser crash is rage-inducing. Auto-recovery eliminates this anxiety and builds trust. Sessions already persist to DB — just need reconnection logic. +**Effort**: Low (check for incomplete sessions on login, offer resume) +**Score**: 🔥 **Must do** + +### 5. Copy Individual Step to Clipboard + +**What**: A copy icon on each step during session review that copies just that step's content (command, notes, outcome) to clipboard. +**Why powerful**: Engineers often need to share a specific step with a colleague or paste one command into a remote session. Currently must export entire session and find the relevant line. +**Effort**: Very Low (copy button per step in session detail view) +**Score**: 👍 **Strong** + +### 6. "This Step is Wrong" Flag + +**What**: A small flag/report button on each tree step during sessions. Flags aggregate for tree authors to review. +**Why powerful**: Creates a quality feedback loop without requiring formal reviews. Engineers won't write bug reports, but they'll click a flag button. Tree authors see which steps get flagged most. +**Effort**: Low (flag button, flag count on tree author view) +**Score**: 👍 **Strong** + +### 7. Dark/Light Syntax Highlighting in Commands + +**What**: PowerShell/CLI commands in tree steps get proper syntax highlighting (already have Monaco — could reuse its highlighting). +**Why powerful**: Engineers scan commands quickly when they're highlighted. Wall of monochrome text is harder to parse. Makes the product feel more premium and developer-native. +**Effort**: Low (use highlight.js or Monaco's tokenizer for inline code blocks) +**Score**: 🤔 **Maybe** — nice polish, not urgent + +--- + +## Recommended Priority + +### Do Now (Quick Wins — ship this week) + +1. **Session Timer** — live elapsed time display in session header. Foundation for time analytics. +2. **Keyboard Navigation** — 1-9 for options, Enter/Escape, Tab to notes. Power user essential. +3. **Repeat Last Session** — one-click re-start with same tree/client. Batch workflow enabler. +4. **Session Draft Auto-Recovery** — resume interrupted sessions. Trust builder. +5. **Copy Step to Clipboard** — per-step copy button in session detail. Daily utility. + +### Do Next (High Leverage — next 2-4 weeks) + +1. **Step-Level Time Tracking + Outcome Capture** — foundational data for everything below +2. **"This Step is Wrong" Flag** — quality feedback loop for tree authors +3. **Tree Effectiveness Dashboard** — most-used trees, resolution rates, time metrics. Sells to managers. +4. **Quick-Start from Clipboard** — paste ticket text, get tree recommendation. Start with keyword matching. + +### Explore (Strategic Bets — next 1-3 months) + +1. **PSA Integration (ConnectWise first)** — one-click documentation push. Biggest adoption unlocker. Risk: API complexity. Start with the PSA Michael's team uses. +2. **Client Intelligence Sidebar** — past sessions for this client, recurring issues, client notes. Medium effort, enormous value for MSPs managing 30+ clients. +3. **Intelligence Loop / Analytics Engine** — mine session data for tree improvement signals, trending issues, engineer efficiency. THE compounding moat. +4. **Tree Templates + Import/Export** — pre-built MSP tree packs. Eliminates cold start for new teams. + +### Backlog (Good but Not Now) + +1. **AI Copilot** — powerful but premature. Need more session data and user trust first. Revisit after analytics foundation exists. +2. **Team Activity Feed** — valuable but not urgent until team sizes grow beyond 5-10. +3. **Marketplace** — needs critical mass of templates and users. Phase 4+. +4. **Syntax Highlighting** — polish, not priority. + +--- + +## The Thesis + +ResolutionFlow today is a **guided workflow tool**. That's valuable but replaceable — a good Notion template could approximate it. + +The 10x version is a **troubleshooting intelligence platform**: every session makes the system smarter, every team member's knowledge becomes institutional, every client interaction builds a living dossier, and every metric proves ROI to the person signing the check. + +The moat is the data flywheel: + +``` +More sessions → better analytics → smarter trees → faster resolutions → more adoption → more sessions +``` + +**The single most important near-term move**: add step-level time tracking + session outcomes. It's low effort, but without it, you can't prove value, optimize trees, or build analytics. Everything else depends on this data. + +**The single most important strategic move**: PSA integration. It's the difference between "another tool to check" and "the tool that lives inside my workflow." MSP engineers live in ConnectWise/Autotask. Meet them there. + +--- + +## Questions + +### Answered (from codebase research) + +- **Q**: Does the product capture enough data for analytics? **A**: Yes — session decisions, path taken, timestamps, client names, tree snapshots all exist. Missing: step-level timing and explicit outcomes. +- **Q**: Is multi-tenant ready? **A**: Yes — Account/Subscription/Team models exist with RBAC. SaaS foundation is solid. +- **Q**: What PSA does Michael's MSP use? **A**: Not specified in codebase. ConnectWise and Kaseya mentioned in Phase 4 roadmap. + +### Blockers (need user input) + +- **Q**: Which PSA does your MSP use? This determines integration priority. +- **Q**: How many trees do you realistically expect teams to maintain? (5? 20? 100?) — affects whether search/recommendation is urgent. +- **Q**: What's the current session volume? Enough to make analytics meaningful? +- **Q**: Would your manager pay for a dashboard showing team resolution metrics and ROI? + +## Next Steps + +- [ ] Ship quick wins (timer, keyboard nav, repeat session, auto-recovery) +- [ ] Add step-level timestamps to session decision records +- [ ] Add session outcome capture (resolved/escalated/unresolved) +- [ ] Determine PSA target for first integration +- [ ] Design tree effectiveness dashboard mockup +- [ ] Validate "paste ticket → suggest tree" with Michael's real ticket descriptions diff --git a/frontend/package-lock.json b/frontend/package-lock.json index f4ffc444..0db16f17 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -21,6 +21,7 @@ "immer": "^11.1.3", "lodash": "^4.17.23", "lucide-react": "^0.563.0", + "monaco-editor": "^0.55.1", "react": "^19.2.0", "react-day-picker": "^9.13.1", "react-dom": "^19.2.0", @@ -2029,8 +2030,7 @@ "resolved": "https://registry.npmjs.org/@types/trusted-types/-/trusted-types-2.0.7.tgz", "integrity": "sha512-ScaPdn1dQczgbl0QFTeTOmVHFULt394XJgOQNoyVhZ6r2vLnMLJfBPd53SB52T/3G36VI1/g2MZaX0cwDuXsfw==", "license": "MIT", - "optional": true, - "peer": true + "optional": true }, "node_modules/@types/unist": { "version": "3.0.3", @@ -2633,13 +2633,13 @@ } }, "node_modules/axios": { - "version": "1.13.4", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.13.4.tgz", - "integrity": "sha512-1wVkUaAO6WyaYtCkcYCOx12ZgpGf9Zif+qXa4n+oYzK558YryKqiL6UWwd5DqiH3VRW0GYhTZQ/vlgJrCoNQlg==", + "version": "1.13.5", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.13.5.tgz", + "integrity": "sha512-cz4ur7Vb0xS4/KUN0tPWe44eqxrIu31me+fbang3ijiNscE129POzipJJA6zniq2C/Z6sJCjMimjS8Lc/GAs8Q==", "license": "MIT", "dependencies": { - "follow-redirects": "^1.15.6", - "form-data": "^4.0.4", + "follow-redirects": "^1.15.11", + "form-data": "^4.0.5", "proxy-from-env": "^1.1.0" } }, @@ -3268,7 +3268,6 @@ "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-3.2.7.tgz", "integrity": "sha512-WhL/YuveyGXJaerVlMYGWhvQswa7myDG17P7Vu65EWC05o8vfeNbvNf4d/BOvH99+ZW+LlQsc1GDKMa1vNK6dw==", "license": "(MPL-2.0 OR Apache-2.0)", - "peer": true, "optionalDependencies": { "@types/trusted-types": "^2.0.7" } @@ -4614,7 +4613,6 @@ "resolved": "https://registry.npmjs.org/marked/-/marked-14.0.0.tgz", "integrity": "sha512-uIj4+faQ+MgHgwUW1l2PsPglZLOLOT1uErt06dAPtx2kjteLAkbsd/0FiYg/MGS+i7ZKLb7w2WClxHkzOOuryQ==", "license": "MIT", - "peer": true, "bin": { "marked": "bin/marked.js" }, @@ -5319,7 +5317,6 @@ "resolved": "https://registry.npmjs.org/monaco-editor/-/monaco-editor-0.55.1.tgz", "integrity": "sha512-jz4x+TJNFHwHtwuV9vA9rMujcZRb0CEilTEwG2rRSpe/A7Jdkuj8xPKttCgOh+v/lkHy7HsZ64oj+q3xoAFl9A==", "license": "MIT", - "peer": true, "dependencies": { "dompurify": "3.2.7", "marked": "14.0.0" diff --git a/frontend/package.json b/frontend/package.json index eb5b159b..4982a269 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -26,6 +26,7 @@ "immer": "^11.1.3", "lodash": "^4.17.23", "lucide-react": "^0.563.0", + "monaco-editor": "^0.55.1", "react": "^19.2.0", "react-day-picker": "^9.13.1", "react-dom": "^19.2.0", diff --git a/resolutionflow.code-workspace b/resolutionflow.code-workspace new file mode 100644 index 00000000..876a1499 --- /dev/null +++ b/resolutionflow.code-workspace @@ -0,0 +1,8 @@ +{ + "folders": [ + { + "path": "." + } + ], + "settings": {} +} \ No newline at end of file