How mizcausevic-dev/boardroom-sparring-partner works
Purpose and principal workflow
Boardroom Sparring Partner turns a bundled synthetic board-prep export into readiness metrics, evidence and downside findings, board-question and memo views, and rehearsal guidance. The primary workflow starts when a web visitor requests a page or JSON endpoint; a separate command-line user can analyze an input file and receive a summary or JSON report. The product is read-only: the sampled application uses in-memory sample data, not live board materials or persistent storage.
Components
Web application and views
• Web visitor — *External actor; repository path: null.* Initiates the main workflow by requesting a dashboard page or API endpoint.
• Express HTTP application — src/app.ts. Creates the Express app, registers HTML and JSON routes, calls view renderers or data-service functions, and starts a listener when run directly.
• Board-prep views — src/services/render.ts. Renders the overview and grouped question-lane, pushback, memo-posture, rehearsal, verification, and documentation screens; also serializes the sample payload for its route.
• Board-prep data service — src/services/verticalBriefService.ts. Builds the report from the sample set and exposes summary, per-view projections, risk findings, verification statements, and the combined payload.
Analysis and source data
• Synthetic board-prep export — src/data/sampleVerticalBrief.ts. Supplies the modeled themes and their questions, readiness, downside, evidence state, memo answers, next moves, tags, and related surfaces.
• Board-prep analyzer — src/analyze.ts. Evaluates each item against evidence, downside, confidence, and readiness rules, then calculates report-level metrics and findings.
• Report formatters — src/format.ts. Converts an analyzed report into human-readable summary text or JSON.
• Domain contracts — src/types.ts. Defines the item, export, finding, and report shapes used by the analysis and interfaces.
CLI and library interfaces
• CLI user — *External actor; repository path: null.* Starts the file-based workflow by invoking the published command with an export path and output format.
• Command-line interface — src/cli.ts. Reads and parses the selected JSON file, analyzes its items, and prints summary or JSON output.
• Package library surface — src/index.ts. Re-exports analysis, export construction, formatters, sample data, and public domain types for package consumers.
Relationships
• Web visitor -> Express HTTP application: requests a page or JSON endpoint; routes are registered in the app.
• Express HTTP application -> Board-prep views: calls render functions for HTML routes and sample serialization.
• Express HTTP application -> Board-prep data service: calls data functions for JSON routes.
• Board-prep views -> Board-prep data service: reads projections and verification content to construct page output.
• Board-prep data service -> Synthetic board-prep export: reads the bundled items to build projections and the payload.
• Board-prep data service -> Board-prep analyzer: analyzes the bundled items at module initialization to derive report metrics and findings.
• Board-prep analyzer -> Domain contracts: consumes and returns the defined item and report shapes.
• CLI user -> Command-line interface: invokes the command with an input file and requested format.
• Command-line interface -> input JSON file: reads and parses the selected file; the default path is a repository fixture.
• Command-line interface -> Board-prep analyzer: analyzes the parsed items.
• Command-line interface -> Report formatters: selects summary or JSON formatting and prints the result.
• Report formatters -> Domain contracts: consume the report shape when formatting output.
• Package library surface -> Board-prep analyzer: re-exports analysis and export construction.
• Package library surface -> Report formatters: re-exports the output formatters.
• Package library surface -> Synthetic board-prep export: re-exports the bundled sample data.
Coverage limits
The sampled sources establish the web and CLI flows and their in-memory data handling. The README documents static-site prerendering and additional routes, but the prerender script and deployment behavior were not sampled; no claim is made about their runtime wiring. No live-data ingestion, persistence, or external provider integration is evidenced.
Main entry points: cli.ts Command-line interface · verticalBriefService.ts Board-prep data service · analyze.ts Board-prep analyzer · index.ts Package library surface
Components 12
Web application
- Express application
src/app.ts - Board-prep views
src/services/render.ts - Board-prep data service
src/services/verticalBriefService.ts
Analysis and source data
- Synthetic board-prep export
src/data/sampleVerticalBrief.ts - Board-prep analyzer
src/analyze.ts - Report formatters
src/format.ts - Domain contracts
src/types.ts
CLI and library interfaces
- Command-line interface
src/cli.ts - Input JSON file · Selected export file; default is a repository fixture.
- Package library surface
src/index.ts
Other components
- Web visitor
- CLI user
Connections 15
- Web visitor → Express application: requests · Requests a page or JSON endpoint.
- Express application → Board-prep views: calls · Renders HTML routes and sample serialization.
- Express application → Board-prep data service: calls · Serves JSON routes.
- Board-prep views → Board-prep data service: reads · Uses projections and verification content.
- Board-prep data service → Synthetic board-prep export: reads · Uses bundled items to build projections and payload.
- Board-prep data service → Board-prep analyzer: analyzes · Derives report metrics and findings at module initialization.
- Board-prep analyzer → Domain contracts: uses · Consumes and returns item and report shapes.
- CLI user → Command-line interface: invokes · Provides an export path and output format.
- Command-line interface → Input JSON file: reads · Reads and parses the selected file.
- Command-line interface → Board-prep analyzer: analyzes · Analyzes the parsed items.
- Command-line interface → Report formatters: formats · Selects summary or JSON output.
- Report formatters → Domain contracts: uses · Consumes the report shape.
- Package library surface → Board-prep analyzer: re-exports · Exposes analysis and export construction.
- Package library surface → Report formatters: re-exports · Exposes output formatters.
- Package library surface → Synthetic board-prep export: re-exports · Exposes bundled sample data.