Unlocking PhD-Level Insights: Shipping Our Deep Project Analysis Workflow and More!
We've just pushed a massive update, launching a 7-step Deep Project Analysis workflow powered by LLMs, alongside a comprehensive 5-phase enhancement plan. Dive into how we're transforming repository analysis into PhD-level insights and what it means for your projects.
What a sprint! There's a special kind of satisfaction that comes with pushing a significant chunk of work to main, knowing that months of planning and countless hours of coding have culminated in a truly transformative release. Today, we're thrilled to announce that our ambitious Deep Project Analysis workflow and a comprehensive 5-phase enhancement plan are officially live!
The commit 28813b0 is more than just a hash; it represents a monumental leap forward in how we understand, analyze, and improve software projects. Everything is typecheck clean, and our systems are humming. Let's dive into what's new.
Building a Robust Foundation: The 5-Phase Enhancement Plan
Before we could unleash the full power of Deep Project Analysis, we needed to fortify our platform with essential capabilities. This five-phase plan laid the groundwork, enhancing everything from reporting to persona management.
Here’s a quick rundown of the foundational elements we’ve shipped:
- Transparent Reporting (Phase 1A & 1B): We've integrated detailed metrics into every report footer, showing duration, token usage, cost, energy consumption, and the specific models used. On the admin side, managing API keys and browsing our model catalog is now more intuitive than ever, ensuring you always know what's powering your analysis.
- Shareable Insights (Phase 2): Ever wanted to export an entire workflow bundle? Now you can! Our new export feature bundles your complete workflow into a
jszipZIP archive, including individual Markdown downloads and crisp Mermaid diagrams, making sharing and documentation a breeze. - Project Health at a Glance (Phase 3A): Get instant visibility into your project's well-being with new health checks, a comprehensive stats bar, and configurable settings fields. Understanding your project's pulse has never been easier.
- Enriched Notes (Phase 3B): We've supercharged our notes with an LLM-powered enrichment pipeline. This means your project notes now benefit from "LLM wisdom injection" – automatically adding insightful context, potential implications, and actionable points, transforming raw observations into strategic assets.
- Expert Teams & Quality Scoring (Phase 4A & 4B): We've introduced
PersonaTeamandPersonaTeamMembermodels, allowing you to assemble and manage expert teams. These teams can be assigned to workflows, guiding the analysis. Complementing this isG-Evalquality scoring, a non-blocking 4-dimension LLM-as-Judge system that provides objective quality assessments for various outputs. - Automated Quality Gates (Phase 5): To ensure consistent excellence, we've implemented automated quality gates. These post-step hooks can validate security, documentation, or even generate "letters to myself" based on predefined criteria, ensuring nothing falls through the cracks.
These enhancements collectively create a more powerful, transparent, and intelligent platform, ready for the heavy lifting of deep analysis.
The Main Event: Deep Project Analysis Workflow
Now, for the star of the show! The Deep Project Analysis (DPA) workflow is designed to provide a PhD-level, 7-step repository analysis covering 15 critical dimensions. This isn't just a surface scan; it's a forensic examination, leveraging advanced LLM techniques to uncover insights typically reserved for senior architects and domain experts.
Here's how this groundbreaking workflow unfolds:
dpaRecon- Structural Reconnaissance: The journey begins with a forensic file tree analysis and dependency inventory. Using cost-effective models like Google's Gemini Flash, we quickly establish a comprehensive understanding of your project's architecture and interdependencies. (Temperature 0.2, for focused output).dpaDimensionMap- Dimension Mapper: With the structural overview in hand, this step organizes the 15 analysis dimensions into self-contained briefs. This ensures a systematic and thorough approach, preventing "lost in the middle" problems and ensuring each facet of the project is adequately covered. (Gemini Flash, Temp 0.3).dpaDeepAnalysis- Deep Dimension Analysis: This is where the magic happens. We use a "fan-out" approach, where each of the mapped dimensions is analyzed independently. Powered by Anthropic's Sonnet, this step performs PhD-level analysis for each dimension: gathering evidence, identifying patterns, conducting gap analysis, assessing risks, and formulating detailed recommendations. (Sonnet, Temp 0.3, splitting by###\s+\d+\.regex for precise segmentation).dpaSynthesis- Cross-Dimensional Synthesis: After deep-diving into individual dimensions, this step brings it all together. Using Anthropic models withgenerateCount: 2for self-consistency, it detects convergences, resolves contradictions, analyzes cascading risks, and identifies overarching trends by leveraging both current session memory and long-term project wisdom. (Anthropic, Temp 0.4).dpaExpertReview- Expert Panel Review: Quality control is paramount. This review step is designed for "comparePersonas" debate, where multiple AI personas (or even a human expert) validate the accuracy, coverage, prioritization, and actionability of the findings. This ensures a robust and well-vetted analysis. (Anthropic, Temp 0.2).dpaReport- Project Memory Report: The culmination of the analysis is a comprehensive report. This includes a system identity card, a health scores table for each dimension, prioritized P0/P1/P2 findings, identified architecture patterns, a tech debt register, a risk register, and a deployment readiness checklist. (Anthropic, Temp 0.5, maxTokens 16384 for extensive detail).dpaActionPlan- Action Plan: Finally, the analysis translates into actionable steps. This step generates a sprint-organized action plan, complete with exact file paths, implementation steps, and validation criteria, making it easy for your team to immediately address the findings. (Anthropic, Temp 0.5, maxTokens 12288).
This entire workflow is now available as a built-in template, ready to transform your project analysis.
Engineering AI for Precision: The Science Behind the Workflow
Our design choices for the DPA workflow weren't arbitrary. They were informed by cutting-edge research and extensive experimentation:
- Chain-of-Thought Prompting: We've seen a 13-16% improvement in code analysis accuracy by guiding the LLM through a step-by-step reasoning process.
- Prompt Sweet Spot: Our prompts are carefully crafted to be between 150-300 words, maximizing instruction effectiveness without overwhelming the model.
- Sequential Fan-out: While parallel processing might seem appealing, we found that running each dimension's deep analysis sequentially yields more coherent and focused results.
- Persona-Driven Insights: The
comparePersonasfeature, fully implemented, allows us to generate multiple persona alternatives and a baseline, fostering a "debate" that leads to more nuanced and reliable findings. We even created a new Sage Emmerich persona – a PhD-level IT documentation expert – specifically to enhance these reviews. - Self-Consistency: Using
generateCountto produce multiple outputs and then synthesizing them significantly improves the reliability of findings. - Hierarchical Summarization: To combat the "lost in the middle" problem with large contexts, we employ hierarchical summarization, ensuring no crucial detail is overlooked.
- Tiered Model Strategy: We intelligently leverage different LLMs for different tasks: Gemini Flash for fast, cheap structural reconnaissance, and Anthropic's Sonnet for deep, high-quality analytical work. This optimizes both cost and output quality.
Navigating the Nuances: Lessons Learned
Even with such a massive release, development isn't without its quirks. One particular "gotcha" surfaced during git add:
- The Zsh Globbing Trap: When trying to
git addfiles with parentheses or brackets in their paths (common in Next.js(dashboard)routing),zshusers might encounterno matches found: src/app/(dashboard)/.... This is becausezshinterprets parentheses and brackets as glob characters. - The Fix: A simple yet crucial workaround is to enclose such paths in single quotes:
git add 'src/app/(dashboard)/...'. This tells zsh to treat the path literally.
It's a small detail, but one that can cause significant frustration in the moment! (And yes, we're still keeping an eye on previous database embedding column and Badge variant issues, as per our internal notes).
What's Next? Testing and Refinement
With the code pushed, our immediate focus shifts to rigorous validation:
- Workflow Execution: We'll be manually creating a new workflow using the "Deep Project Analysis" template, linking it to a GitHub repository, and verifying that all 7 steps execute flawlessly.
- Fan-out Validation: Ensuring that the Deep Dimension Analysis step correctly splits and processes all 15 dimensions as intended.
- Persona Debate: Actively testing the "Expert Panel Review" step with
comparePersonas, including our new Sage Emmerich, to observe the persona debate in action. - Report Integrity: A thorough check of the final Project Memory Report for structure, completeness, and accuracy.
- Team Integration: We're considering creating a dedicated "Analysis Team" (e.g., Sage Emmerich + Sasha Lindqvist + Noor Okafor) to further streamline the DPA workflow.
- Automated Memory: Exploring mechanisms to automatically save the comprehensive
dpaReportoutput directly into project memory or notes for future reference.
This release marks a significant milestone in our journey to empower developers with unparalleled project insights. We're excited to see how the Deep Project Analysis workflow transforms your understanding of your codebase and accelerates your path to engineering excellence. Stay tuned for more updates!