Skip to content

Repository files navigation

🧭 NAVIGATOR

AI-Powered PM Β· Agile Β· Dev Tracking Co-Pilot

Design. Ship. Verify. β€” All in one AI-native workflow.

Version Python FastAPI React Electron LangGraph License


NAVIGATOR is a desktop AI agent built around three core pipelines:

β‘  Design β€” turns ideas or codebases into complete PM + SA documentation in minutes
β‘‘ Agile β€” auto-generates and distributes task tickets, exports to GitHub Wiki/Issues, and manages design change approvals
β‘’ Dev Tracking β€” hooks into every PR, reverse-engineers the actual code, compares it against the published design spec, classifies gaps as intentional or not, and routes the result to the PM for sign-off


Quick Start Β· Architecture Β· Design Pipeline Β· Agile Pipeline Β· QA Pipeline Β· API Reference Β· Contributing


English | ν•œκ΅­μ–΄


✨ Three Pillars

πŸ—οΈ Design

Generate a full software architecture package from a single idea or existing codebase.

  • Requirements Traceability Matrix
  • Component architecture + dependency graph
  • REST API spec (OpenAPI style)
  • DB schema (DBML)
  • Test strategy & test cases
  • Project directory layout

Three modes: CREATE Β· UPDATE Β· REVERSE_ENGINEER

πŸƒ Agile Collaboration

Close the gap between design documents and what actually gets built.

  • Auto-generate task tickets from SA artifacts
  • Distribute tasks by role + workload (PM Β· Engineer Β· Backend Β· Frontend Β· DevOps)
  • PM approval workflow for design change requests
  • Publish directly to GitHub Issues / Wiki
  • Track task status: pending β†’ approved β†’ done

πŸ”¬ Dev Tracking

Every PR triggers an automated design conformance check.

  • AST-scan the branch β†’ build code_inventory
  • Load the published design spec from shared.db
  • Identify gaps: missing APIs, missing components, design mismatches
  • Classify each gap: INTENTIONAL or UNINTENTIONAL
  • Route to PM for approval or auto-comment on the PR
  • Manual run via Dev Tracking tab in addition to GitHub Webhook

πŸ—ΊοΈ Architecture

flowchart TB
    classDef client   fill:#dbeafe,stroke:#3b82f6,color:#1e3a8a,rx:6
    classDef transport fill:#fef9c3,stroke:#eab308,color:#713f12
    classDef design   fill:#dcfce7,stroke:#22c55e,color:#14532d
    classDef agile    fill:#ede9fe,stroke:#8b5cf6,color:#2e1065
    classDef qa       fill:#fee2e2,stroke:#ef4444,color:#7f1d1d
    classDef db       fill:#f8fafc,stroke:#94a3b8,color:#334155
    classDef ext      fill:#fff7ed,stroke:#f97316,color:#431407

    subgraph CLIENT["πŸ–₯️ Client"]
        direction LR
        EL["Electron\nmain.js Β· preload.js"]:::client
        RF["React 18 Β· Vite\nZustand Β· ReactFlow Β· Monaco"]:::client
        EL <--> RF
    end

    CLIENT <-->|"WebSocket /ws/pipeline\nREST /api/*"| BACKEND

    subgraph BACKEND["βš™οΈ FastAPI Backend  (Sidecar)"]

        subgraph TR["Transport Β· Auth"]
            direction LR
            WS["/ws/pipeline"]:::transport
            RA_T["/api/*  REST"]:::transport
            AU["JWT Β· GitHub OAuth\nRBAC  PM / Engineer / …"]:::transport
        end

        subgraph P1["β‘  Design Pipeline"]
            direction LR
            GU["guardian"]:::design --> REQ["requirement\nanalyzer"]:::design --> SP["stack\nplanner"]:::design
            SP <-->|"PENDING_CRAWL\nself-heal loop"| SC["stack\ncrawling"]:::design
            SP --> MO["sa_unified\nmodeler"]:::design --> TE["sa_test\nanalysis"]:::design --> PS["sa_project\nstructure"]:::design --> RS["Result\nShaper"]:::design
        end

        subgraph P2["β‘‘ Agile Collaboration Pipeline"]
            direction LR
            TG["task\ngenerator"]:::agile --> TD["task\ndistributor"]:::agile --> TC["task\ncoordinator"]:::agile
            CA["commit\nanalyzer"]:::agile --> DS["doc_sync"]:::agile --> WP["wiki\npublisher"]:::agile
            VR["verifier\nV-001~009"]:::agile --> IA["impact\nanalyzer"]:::agile
            DCR(["Design Change\nRequest\nEngineer β†’ PM"]):::agile -->|Approve| DU_A["doc\nupdater"]:::agile
            DCR -->|Reject| PCN_A["pr_comment\nnotifier"]:::agile
        end

        subgraph P3["β‘’ Dev Tracking Pipeline"]
            direction LR
            WH(["GitHub\nWebhook"]):::qa --> DTP["dev_task\nplanner"]:::qa --> BF["branch\nfetcher"]:::qa --> RAN["reverse\nanalyzer\nAST scan"]:::qa
            RAN --> FP["forensic\nprofiler\nfile role map"]:::qa --> SL["spec\nloader\nshared.db"]:::qa --> GA["gap\nanalyzer\nHIGH/MED/LOW"]:::qa
            GA -->|"HIGH GAP"| IC["intent\nclassifier\nINTENTIONAL?"]:::qa
            GA -->|"NO GAP"| MT["milestone\ntracker"]:::qa --> PRG["pm_report\ngenerator"]:::qa
            IC -->|"Approve  (PM)"| DU_Q["doc\nupdater\n+ Wiki sync"]:::qa
            IC -->|"Reject  (PM)"| PCN_Q["pr_comment\nnotifier"]:::qa
        end

        TR --> P1 & P2 & P3
    end

    subgraph DB["πŸ’Ύ Data Layer"]
        direction LR
        LDB[("local.db\nteams Β· users\nsessions Β· memos")]:::db
        SDB[("shared.db\npublished\nsnapshots")]:::db
        TDB[("tasks.db\nAgile\ntask board")]:::db
    end

    subgraph EXT["☁️ External Services"]
        direction LR
        GEM["Google\nGemini API"]:::ext
        GHA["GitHub API\nIssues Β· Wiki Β· Repos"]:::ext
    end

    RS --> LDB
    TC --> LDB & TDB
    DU_Q -.->|"pin version"| SDB
    SL -.->|"version match"| SDB
    PRG --> TC

    P1 & P2 & P3 -.->|"LLM calls"| GEM
    P2 & P3 -.->|"API calls"| GHA
Loading

πŸ”¬ Design Pipeline

Three Analysis Modes

Mode Input Output
CREATE Product idea (text) RTM Β· Tech stack Β· Component arch Β· API spec Β· DB schema Β· Test strategy Β· Directory layout
UPDATE Previous analysis JSON + new feature description Merged design preserving existing feature IDs / positions
REVERSE_ENGINEER Path to existing codebase AST-derived RTM Β· Component map Β· API surface reconstruction

Self-Healing Agent Loop

When the Stack Planner finds incomplete tech-stack data, it automatically queues a PENDING_CRAWL and re-enters the crawling loop (max 2 iterations) β€” no human intervention needed.

Real-time Streaming

Every pipeline node streams its status and reasoning to the UI via WebSocket:

{ "type": "status",   "node": "requirement_analyzer", "data": { "status": "running" } }
{ "type": "thinking", "node": "stack_planner",         "data": { "text": "Comparing React vs Vue..." } }
{ "type": "result",   "node": "complete",              "data": { /* full artifact payload */ } }

Output Artifacts

Key Contents
requirements_rtm Atomic requirements with priority, category, traceability
context_spec Project context summary
sa_arch_bundle Component architecture, dependency graph
sa_api OpenAPI-style endpoint specifications
sa_db DBML database schema
sa_test_analysis_output Unit / Integration / E2E test strategy + test cases
sa_project_structure Recommended directory layout
pm_overview Β· sa_overview QA summary reports

πŸƒ Agile Collaboration Pipeline

Task Generation & Distribution

NAVIGATOR reads completed SA artifacts and automatically decomposes them into implementation tickets:

SA Artifact Generated Task Type
sa_arch_bundle.components Component implementation (Frontend / Backend)
sa_arch_bundle.apis API endpoint implementation
sa_arch_bundle.tables DB table implementation
sa_project_structure Initial project scaffold setup
sa_test_analysis_output.risk_zones Test implementation
pm_bundle (RTM) Task title / description enrichment

Tasks are distributed by matching role and current workload:

Role Assignment Rule
PM Excluded from task assignment (reviewer / approver)
Engineer Fullstack β€” receives all task types
Backend / Frontend / DevOps Domain-matched tasks only

Task Lifecycle

unassigned β†’ PR_WAITING β†’ approved β†’ done (history)
                       β””β†’ rejected β†’ unassigned
  • PR_WAITING: triggered when a PR is opened against the task's branch
  • approved: PM signs off on the implementation
  • rejected: returned to unassigned queue for reassignment

Design Change Request Flow

Engineer                PM                    System
   β”‚                     β”‚                       β”‚
   β”œβ”€ POST /api/change-requests ──────────────► β”‚
   β”‚   (target section + description)            β”‚
   β”‚                     β”‚                       β”‚
   β”‚            PATCH /api/change-requests/{id}  β”‚
   β”‚                  approve ──────────────► doc_updater
   β”‚                  reject ───────────────► pr_comment_notifier

GitHub Integration

  • Export design documents to GitHub Issues or GitHub Wiki (dropdown in the Design banner)
  • Sync architecture reports to GitHub Wiki via doc_sync
  • Analyze commit history via commit_analyzer
  • Design gap comments posted directly on PRs via pr_comment_notifier

πŸ”¬ Dev Tracking Pipeline

The Dev Tracking pipeline closes the loop between design and implementation. It triggers automatically on every GitHub PR/push event (or via manual run) and produces a PM-ready conformance report.

Pipeline Flow

GitHub Webhook (PR opened / push to feature branch)
       β”‚
       β–Ό
dev_task_planner   β€” parse webhook payload (branch name, PR#, commit SHA, branch creation timestamp)
       β”‚
branch_fetcher     β€” repo_cache.get_local_repo_path() β†’ git checkout target branch
       β”‚
reverse_analyzer   β€” single AST scan β†’ (project_context str, code_inventory dict)
       β”‚              [wraps pipeline_runner.build_reverse_context()]
       β”‚
forensic_profiler  β€” classify each file by role: DB Β· API Β· SERVICE Β· UI Β· STORE Β· CONFIG Β· UTIL
       β”‚              output: file_role_map {file_path: role}
       β”‚
spec_loader        β€” load published design spec from shared.db at branch-creation timestamp
       β”‚              if a newer spec exists β†’ set spec_outdated: true
       β”‚              output: spec {components, apis, tables} + spec_version + spec_outdated
       β”‚
gap_analyzer       β€” diff spec vs file_role_map
       β”‚              β†’ missing APIs, missing components, intent mismatches
       β”‚              β†’ severity: HIGH Β· MED Β· LOW
       β”‚              β†’ if spec_outdated: annotate gaps that may be version-drift artifacts
       β”‚
       β”œβ”€β”€β”€ HIGH GAP found ──►
       β”‚         intent_classifier  β€” INTENTIONAL vs UNINTENTIONAL
       β”‚              (evidence: commit messages + PR description vs design intent)
       β”‚              spec_outdated gaps β†’ INTENTIONAL candidates by default
       β”‚                    β”‚
       β”‚         β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
       β”‚      Approve (PM)         Reject (PM)
       β”‚      [TaskApprovalPanel]  [TaskApprovalPanel]
       β”‚           β”‚                    β”‚
       β”‚      doc_updater         pr_comment_notifier
       β”‚      (reflect approved   ("Design intent mismatch β€”
       β”‚       GAP in design doc   please revise")
       β”‚       + GitHub Wiki sync
       β”‚       + pin spec version
       β”‚       to this branch)
       β”‚
       └─── NO GAP ──►
                 milestone_tracker     β€” feature completion rate + estimated completion date
                      β”‚
                 pm_report_generator   β€” unified PM report:
                      β”‚                   Β· Milestone achievement %
                      β”‚                   Β· GAP list (by severity)
                      β”‚                   Β· Intent classification results
                      β”‚                   Β· spec_outdated warning ("Dev working on v1, v2 exists")
                      β”‚
                 task_coordinator      β€” update local.db Β· queue approved tasks to agile board
                      β”‚
                 develop_embedding     β€” persist GAP analysis + PM report to local.db

Node Reference

Node Status Based On
dev_task_planner Modified existing node β€” replaces RTM read with webhook payload parsing
branch_fetcher New repo_cache.get_local_repo_path() + git checkout
reverse_analyzer New wraps build_reverse_context() β€” single scan, dual output
forensic_profiler New reads code_inventory from state β†’ LLM role classification
spec_loader New publish_service.py + shared.db query pattern
gap_analyzer New LLM node β€” spec vs implementation diff
intent_classifier New LLM node β€” commit message + PR description evidence
milestone_tracker Modified replaces feature_queue_controller
pm_report_generator New based on feature_completion_qa_report() structure
pr_comment_notifier Modified replaces branch_pr_orchestrator β€” PR comment only, no PR creation
doc_updater New extends doc_sync β€” applies PM-approved GAPs to design + Wiki
task_coordinator Modified existing Agile node β€” adds QA result persistence
develop_embedding Modified existing dev-pipeline β€” targets GAP analysis + PM report

πŸš€ Quick Start

Prerequisites

Requirement Version
Node.js 18+
Python 3.11+
Google Gemini API Key Get one β†’

1. Clone & Install

git clone https://github.com/your-org/navigator.git
cd navigator

# Node dependencies
npm install

# Python virtual environment + backend dependencies
cd backend
python -m venv .venv

# Windows
.venv\Scripts\activate
# macOS / Linux
# source .venv/bin/activate

pip install -r requirements.txt
cd ..

2. Configure Environment

# Windows
copy backend\.env.example backend\.env

# macOS / Linux
cp backend/.env.example backend/.env

Edit backend/.env:

GEMINI_API_KEY=your_gemini_api_key_here
ENV=dev

# Optional: GitHub OAuth (for team collaboration + QA pipeline features)
GITHUB_CLIENT_ID=your_github_client_id
GITHUB_CLIENT_SECRET=your_github_client_secret

3. Run

# Windows β€” recommended one-click launcher
run_v2.bat

# Cross-platform
npm run dev

The launcher:

  1. Cleans up stale node / python / electron processes
  2. Starts Vite dev server and waits for port 5173
  3. Launches Electron (which starts the FastAPI sidecar automatically)

πŸ”Œ API Reference

WebSocket β€” /ws/pipeline

{
  "type": "analyze",
  "payload": {
    "action_type": "CREATE",
    "idea": "Your product idea here",
    "api_key": "GEMINI_API_KEY",
    "auth_token": "JWT_TOKEN"
  }
}

REST Endpoints

Method Endpoint Description Auth
GET /health Health check β€”
POST /auth/register Create account β€”
POST /auth/login Email / password login β€”
GET /auth/github/oauth-url GitHub OAuth Web Flow β€”
POST /auth/github/device-start GitHub Device Flow start β€”
POST /auth/github/device-poll GitHub Device Flow poll β€”
GET /auth/me Current user profile βœ“
POST /api/analyze Synchronous pipeline run βœ“
POST /api/idea-chat Multi-turn idea chat βœ“
POST /api/agile/verify Design consistency check (V-001~V-009) βœ“
POST /api/agile/impact Change impact analysis βœ“
POST /api/agile/generate-tasks Auto-generate tasks from SA artifacts βœ“
POST /api/agile/distribute-tasks Distribute tasks to team members βœ“ PM
GET/PATCH /api/change-requests Design change request management βœ“
POST /api/github/publish Export design to GitHub Wiki or Issues (publish_mode: "wiki"|"issue") βœ“
POST /api/webhook/github GitHub PR webhook β†’ Dev Tracking pipeline HMAC
POST /api/dev-tracking/run Manual Dev Tracking run βœ“
POST /api/doc-sync Sync report to GitHub Wiki βœ“
GET/POST /api/tasks Task CRUD βœ“
GET/POST /api/snapshots Publish / restore analysis snapshots βœ“
GET/POST/DELETE /api/memos Session memo management βœ“
GET /metrics Prometheus metrics β€”

πŸ—„οΈ Database Schema

Database Contents
local.db teams Β· users Β· analysis_sessions Β· analysis_results Β· memo_items Β· design_change_requests
shared.db published_snapshots (cross-team, used by spec_loader for version matching)
tasks.db tasks (Agile board: type Β· status Β· assignee Β· payload)

πŸ—οΈ Project Structure

navigator/
β”œβ”€β”€ electron/
β”‚   β”œβ”€β”€ main.js               # Electron main process, FastAPI sidecar launcher
β”‚   └── preload.js            # IPC bridge
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ components/
β”‚   β”‚   β”œβ”€β”€ ResultViewer.jsx
β”‚   β”‚   β”œβ”€β”€ resultViewer/
β”‚   β”‚   β”‚   β”œβ”€β”€ RTMTab.jsx Β· SAComponentsTab.jsx Β· SAApiTab.jsx
β”‚   β”‚   β”‚   β”œβ”€β”€ SADatabaseTab.jsx Β· SATestStrategyTab.jsx
β”‚   β”‚   β”‚   β”œβ”€β”€ ProjectStructureTab.jsx
β”‚   β”‚   β”‚   β”œβ”€β”€ AgileVerifierTab.jsx      # V-001~V-009 results
β”‚   β”‚   β”‚   β”œβ”€β”€ AgileImpactTab.jsx        # change impact analysis
β”‚   β”‚   β”‚   β”œβ”€β”€ TaskApprovalPanel.jsx     # PM review UI (Agile + Dev Tracking)
β”‚   β”‚   β”‚   └── DevTrackingTab.jsx        # manual Dev Tracking run + analysis history
β”‚   β”‚   └── github/GitHubDashboard.jsx
β”‚   └── store/slices/
β”‚       β”œβ”€β”€ authSlice.js Β· pipelineSlice.js Β· wsSlice.js
β”‚       β”œβ”€β”€ sessionSlice.js Β· githubSlice.js Β· publishSlice.js
β”‚       └── uiSlice.js Β· fileSlice.js Β· notificationSlice.js
β”œβ”€β”€ backend/
β”‚   β”œβ”€β”€ auth/                 # JWT + GitHub OAuth + RBAC
β”‚   β”œβ”€β”€ transport/            # rest_handler.py Β· ws_handler.py
β”‚   β”œβ”€β”€ orchestration/        # pipeline_runner.py Β· graph.py Β· aux_graphs.py
β”‚   β”œβ”€β”€ pipeline/domain/
β”‚   β”‚   β”œβ”€β”€ pm/nodes/         # guardian Β· requirement_analyzer Β· stack_planner
β”‚   β”‚   β”œβ”€β”€ sa/nodes/         # sa_unified_modeler Β· sa_test_analysis Β· sa_project_structure
β”‚   β”‚   β”œβ”€β”€ agile/nodes/      # verifier Β· impact Β· task_generator Β· task_distributor Β· doc_sync
β”‚   β”‚   β”œβ”€β”€ chat/             # idea_chat
β”‚   β”‚   └── dev_tracking/     # service Β· nodes Β· gap_analyzer Β· intent_classifier Β· followup
β”‚   β”œβ”€β”€ result_shaping/       # result_shaper.py Β· sa_artifact_compiler.py
β”‚   β”œβ”€β”€ connectors/           # github_connector.py Β· folder_connector.py Β· repo_cache.py
β”‚   β”œβ”€β”€ storage/              # publish_service.py
β”‚   └── observability/        # logger.py Β· metrics.py
β”œβ”€β”€ run_v2.bat
└── package.json

🧩 Extending the Pipeline

Adding a New Node

# backend/pipeline/domain/<domain>/nodes/your_node.py
from pipeline.core.state import PipelineState

async def your_node(state: PipelineState) -> dict:
    data = state.get("some_key", [])
    result = await your_llm_call(data)
    return {"your_output_key": result}

Wrap with cost tracking in graph.py:

from orchestration.pipeline_runner import _wrap_node_with_usage
graph.add_node("your_node", _wrap_node_with_usage("your_node", your_node))

Protected endpoints must use the appropriate dependency:

# Any authenticated user
async def endpoint(user = Depends(get_current_user)): ...

# PM role only
async def endpoint(user = Depends(require_pm)): ...

βš™οΈ Configuration

Variable Required Description
GEMINI_API_KEY βœ… Google Gemini API key
ENV β€” dev / prod (default: dev)
GITHUB_CLIENT_ID β€” GitHub OAuth App client ID
GITHUB_CLIENT_SECRET β€” GitHub OAuth App client secret
npm Script Description
npm run dev Full stack (Vite + Electron)
npm run backend Backend only (port 8765)
npm run build:electron Package Electron app

πŸ§ͺ Testing

cd backend
python -m pytest -q test/

Smoke test checklist after major changes:

  • CREATE mode β€” idea input β†’ full artifact generation
  • UPDATE mode β€” load previous result β†’ add feature β†’ verify design preserved
  • REVERSE_ENGINEER mode β€” local folder β†’ reverse analysis
  • WebSocket streaming β€” live progress visible in UI

πŸ”’ Security

  • Never commit .env β€” only .env.example is version-controlled
  • CORS restricted to localhost / 127.0.0.1 only
  • RBAC enforced at dependency layer (require_pm, require_engineer)
# Scan for leaked secrets before pushing
git diff --cached | grep -E "(sk-|ghp_|AIza|PRIVATE KEY)"

πŸ› οΈ Troubleshooting

WebSocket connection fails on startup

Check Electron console for [Python] Initializing PM Agent Backend subsystems...
Restart via run_v2.bat to clean up stale processes.

Port 5173 wait timeout

Check vite.log (last 40 lines) for errors. Verify no other process is binding port 5173.

Architecture diagram shows 0 components

sa_phase1.file_inventory is empty or mapped_requirements[].file_path is missing. Re-run the analysis β€” past JSON results are not retroactively updated.

GitHub OAuth Device Flow stuck
  1. Call POST /auth/github/device-start β†’ open verification_uri in browser β†’ enter user_code
  2. Poll POST /auth/github/device-poll every 5 seconds until status: "authorized"
  3. Verify GITHUB_CLIENT_ID is set in .env

πŸ—ΊοΈ Roadmap

  • Dev Tracking Pipeline β€” GitHub Webhook integration (design β†’ implementation conformance)
  • Dev Tracking Pipeline β€” manual run via Dev Tracking tab
  • GitHub Wiki / Issue export from Design banner
  • Dev Tracking β€” automated test code generation from code_inventory + file_role_map
  • Multi-model support: OpenAI / Anthropic Claude
  • MCP (Model Context Protocol) server mode
  • Export to Confluence / Notion
  • Real-time collaborative editing (multi-user sessions)
  • VS Code extension
  • Docker Compose one-command setup

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feat/your-feature
  3. New pipeline nodes: place under pipeline/domain/<domain>/nodes/, use _wrap_node_with_usage
  4. Write tests in backend/test/
  5. Smoke test all three modes (CREATE / UPDATE / REVERSE_ENGINEER)
  6. Open a PR with a clear description

Code Style

  • Backend: PEP 8, full type hints, Pydantic v2 for all schemas
  • Frontend: functional components, Zustand for shared state, Tailwind for styling
  • Auth: protected endpoints must use Depends(get_current_user) or role-specific deps

πŸ“„ License

MIT License β€” see LICENSE for details.


Built with LangGraph Β· FastAPI Β· Electron Β· React Β· Google Gemini

If NAVIGATOR saves you hours of architecture and QA work, consider giving it a ⭐

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages