# mosabutey/career-ops-lifesci architecture

> Architecture diagram of the GitHub repository mosabutey/career-ops-lifesci, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-04-09). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mosabutey/career-ops-lifesci
- Repository: https://github.com/mosabutey/career-ops-lifesci

## Overview

1. **Overall shape**
   - This is a **local-first career operating system**, not a hosted SaaS app.
   - The repo combines **prompt-driven agent workflows**, **Node/Playwright automation**, and a small **Go terminal dashboard** around a shared career data model.

2. **Local user data boundary**
   - Personal inputs live outside the public system layer: `config/profile.yml`, `cv.md`, `article-digest.md`, local interview-prep notes, and generated application artifacts.
   - The public repo supplies the reusable logic, templates, and prompts; the user’s identity, CV content, and application defaults are meant to stay machine-local.

3. **Agent command surface**
   - The main operational interface is the set of **mode prompts** in `modes/`, mirrored by command wrappers in `.opencode/commands/` and skill files under `.agents/skills/` and `.claude/skills/`.
   - These define reusable workflows such as apply, compare, evaluate, scan, tracker, batch, pdf, patterns, and interview prep.
   - The repo is designed to work with **Claude Code, OpenCode, and Codex** as the execution environment for those commands.

4. **Opportunity intake and evaluation flow**
   - A job description or URL enters the system through the command layer.
   - The system then classifies the opportunity by **role pack** and **career stage**, evaluates fit, and produces structured outputs: a report, a recommended resume variant, and tracker updates.
   - This is the core decision-support path that turns raw opportunities into ranked, actionable candidates.

5. **Document generation subsystem**
   - Resume/PDF generation is template-driven via `templates/cv-template.html` and scripts such as `scripts/generate-pdf.mjs`.
   - The intent is ATS-safe, tailored output rather than generic document export.
   - Example source material in `examples/` shows how different candidate archetypes are represented and transformed.

6. **Application tracking and data integrity**
   - The tracker is a first-class subsystem, with merge, deduplication, status normalization, and contract validation scripts in `scripts/`.
   - `DATA_CONTRACT.md` and `scripts/tracker-contract.mjs` indicate that tracker data has a defined schema and integrity rules.
   - Outputs from evaluation and application flows are consolidated into reports, TSV/tracker artifacts, and summary views rather than scattered notes.

7. **Browser-assisted application layer**
   - Live application support is handled by **Playwright-based scripts** under `scripts/`, including Workday- and Phenom-specific probes and handoff flows.
   - This layer is explicitly **human-in-the-loop**: it can inspect, prefill, and stage applications, but the candidate is expected to review before final submission.
   - The browser automation depends on local profile defaults, portal-specific configuration, and saved file paths for uploadable documents.

8. **Batch and pipeline processing**
   - `batch/` supports parallel or grouped processing of multiple opportunities, with logs and merged tracker additions.
   - This is the throughput-oriented layer for handling many roles without losing the same evaluation and tracker discipline used in single-role workflows.
   - `scripts/verify-pipeline.mjs`, `scripts/merge-tracker.mjs`, and related helpers keep batch output consistent with the main system.

9. **Observability and local UI**
   - `dashboard/` is a **Go-based terminal application** that reads career data and presents pipeline/viewer screens.
   - It depends on `dashboard/internal/data`, `model`, `theme`, and `ui/screens`, which suggests a read-oriented UI over existing tracker/report artifacts rather than a separate backend service.
   - This dashboard is the repo’s lightweight operational view into the application pipeline.

10. **Configuration, localization, and extensions**
   - The repo supports multiple role packs and career stages, plus localized command sets in `modes/de`, `modes/fr`, and `modes/pt`.
   - `templates/portals.example.yml` and `config/profile.example.yml` show that portal behavior and profile defaults are configurable rather than hardcoded.
   - Supporting docs in `docs/` define the operational rules, privacy boundaries, and validation process; GitHub Actions in `.github/workflows/validate.yml` provide automated repo checks.

Main entry points: [`.opencode/commands/career-ops.md`](https://github.com/mosabutey/career-ops-lifesci/blob/main/.opencode/commands/career-ops.md) (Ops command), [`modes/pipeline.md`](https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/pipeline.md) (Pipeline), [`modes/apply.md`](https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/apply.md) (Apply), [`modes/evaluate.md`](https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/evaluate.md) (Evaluate)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_group_commands["Command surface"]
  node_node_mode_apply["Apply<br/>mode prompt<br/>[apply.md]"]
  node_node_mode_evaluate["Evaluate<br/>mode prompt<br/>[evaluate.md]"]
  node_node_mode_batch["Batch<br/>mode prompt<br/>[batch.md]"]
  node_node_mode_pipeline["Pipeline<br/>mode prompt<br/>[pipeline.md]"]
  node_node_mode_tracker["Tracker<br/>mode prompt<br/>[tracker.md]"]
  node_node_command_root["Ops command<br/>command wrapper<br/>[career-ops.md]"]
  node_node_skill["Career skill<br/>skill pack<br/>[SKILL.md]"]
end

subgraph group_group_workflows["Workflows"]
  node_node_eval_script["Verify pipe<br/>pipeline check"]
  node_node_merge_script["Merge tracker<br/>tracker merge<br/>[merge-tracker.mjs]"]
end

subgraph group_group_generation["Document generation"]
  node_node_pdf_script["Generate PDF<br/>document build<br/>[generate-pdf.mjs]"]
  node_node_template["CV template<br/>html template<br/>[cv-template.html]"]
  node_node_example["Example report<br/>sample output<br/>[sample-report.md]"]
end

subgraph group_group_browser["Browser automation"]
  node_node_probe["Workday probe<br/>browser automation"]
  node_node_phenom["Phenom handoff<br/>browser automation"]
end

subgraph group_group_dashboard["Dashboard"]
  node_node_dashboard_main["Dashboard main<br/>go app<br/>[main.go]"]
  node_node_dashboard_ui["Pipeline view<br/>ui screen<br/>[pipeline.go]"]
  node_node_dashboard_data["Career data<br/>data model<br/>[career.go]"]
  node_node_dashboard_model["Career model<br/>domain model<br/>[career.go]"]
end

subgraph group_group_data["Data and contracts"]
  node_node_readme["README<br/>repo overview<br/>[README.md]"]
  node_node_contract_script["Tracker contract<br/>schema validation"]
  node_node_profile["Profile defaults<br/>local config"]
  node_node_contract["Data contract<br/>schema spec<br/>[DATA_CONTRACT.md]"]
end

node_node_command_root -->|"dispatches to"| node_node_mode_apply
node_node_command_root -->|"dispatches to"| node_node_mode_evaluate
node_node_command_root -->|"dispatches to"| node_node_mode_batch
node_node_command_root -->|"dispatches to"| node_node_mode_pipeline
node_node_command_root -->|"dispatches to"| node_node_mode_tracker
node_node_skill -->|"encodes"| node_node_mode_apply
node_node_skill -->|"encodes"| node_node_mode_evaluate
node_node_mode_apply -->|"uses"| node_node_eval_script
node_node_mode_evaluate -->|"constrains"| node_node_contract
node_node_mode_batch -->|"feeds"| node_node_merge_script
node_node_mode_tracker -->|"validates against"| node_node_contract_script
node_node_merge_script -->|"checks"| node_node_contract_script
node_node_pdf_script -->|"renders"| node_node_template
node_node_mode_pipeline -->|"invokes"| node_node_pdf_script
node_node_mode_pipeline -->|"updates"| node_node_merge_script
node_node_probe -->|"reads"| node_node_profile
node_node_probe -->|"stages"| node_node_contract
node_node_phenom -->|"reads"| node_node_profile
node_node_dashboard_main -->|"loads"| node_node_dashboard_data
node_node_dashboard_data -->|"maps to"| node_node_dashboard_model
node_node_dashboard_ui -->|"renders"| node_node_dashboard_model
node_node_readme -->|"orients"| node_node_command_root
node_node_readme -->|"documents"| node_node_dashboard_main
node_node_example -.->|"illustrates"| node_node_template

click node_node_readme "https://github.com/mosabutey/career-ops-lifesci/blob/main/README.md"
click node_node_mode_apply "https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/apply.md"
click node_node_mode_evaluate "https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/evaluate.md"
click node_node_mode_batch "https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/batch.md"
click node_node_mode_pipeline "https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/pipeline.md"
click node_node_mode_tracker "https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/tracker.md"
click node_node_command_root "https://github.com/mosabutey/career-ops-lifesci/blob/main/.opencode/commands/career-ops.md"
click node_node_skill "https://github.com/mosabutey/career-ops-lifesci/blob/main/.agents/skills/career-ops/SKILL.md"
click node_node_eval_script "https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/verify-pipeline.mjs"
click node_node_merge_script "https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/merge-tracker.mjs"
click node_node_contract_script "https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/tracker-contract.mjs"
click node_node_pdf_script "https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/generate-pdf.mjs"
click node_node_template "https://github.com/mosabutey/career-ops-lifesci/blob/main/templates/cv-template.html"
click node_node_example "https://github.com/mosabutey/career-ops-lifesci/blob/main/examples/sample-report.md"
click node_node_probe "https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/probe-workday-fill-myinfo.mjs"
click node_node_phenom "https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/assist-phenom-review-handoff.mjs"
click node_node_dashboard_main "https://github.com/mosabutey/career-ops-lifesci/blob/main/dashboard/main.go"
click node_node_dashboard_ui "https://github.com/mosabutey/career-ops-lifesci/blob/main/dashboard/internal/ui/screens/pipeline.go"
click node_node_dashboard_data "https://github.com/mosabutey/career-ops-lifesci/blob/main/dashboard/internal/data/career.go"
click node_node_dashboard_model "https://github.com/mosabutey/career-ops-lifesci/blob/main/dashboard/internal/model/career.go"
click node_node_profile "https://github.com/mosabutey/career-ops-lifesci/blob/main/config/profile.example.yml"
click node_node_contract "https://github.com/mosabutey/career-ops-lifesci/blob/main/DATA_CONTRACT.md"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_node_mode_apply,node_node_mode_evaluate,node_node_mode_batch,node_node_mode_pipeline,node_node_mode_tracker,node_node_command_root,node_node_skill toneBlue
class node_node_eval_script,node_node_merge_script toneAmber
class node_node_pdf_script,node_node_template,node_node_example toneMint
class node_node_probe,node_node_phenom toneRose
class node_node_dashboard_main,node_node_dashboard_ui,node_node_dashboard_data,node_node_dashboard_model toneIndigo
class node_node_readme,node_node_contract_script,node_node_profile,node_node_contract toneTeal
```

## Components

### Command surface

Mode prompts, command wrappers, and skills that define the agent-facing workflows.

- [Apply](https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/apply.md): mode prompt · Primary application workflow prompt. · `modes/apply.md`
- [Evaluate](https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/evaluate.md): mode prompt · Fit analysis and opportunity ranking workflow. · `modes/evaluate.md`
- [Batch](https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/batch.md): mode prompt · Multi-opportunity processing workflow. · `modes/batch.md`
- [Pipeline](https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/pipeline.md): mode prompt · End-to-end opportunity processing workflow. · `modes/pipeline.md`
- [Tracker](https://github.com/mosabutey/career-ops-lifesci/blob/main/modes/tracker.md): mode prompt · Tracker update and consolidation workflow. · `modes/tracker.md`
- [Ops command](https://github.com/mosabutey/career-ops-lifesci/blob/main/.opencode/commands/career-ops.md): command wrapper · Unified command entry surface for agent runtimes. · `.opencode/commands/career-ops.md`
- [Career skill](https://github.com/mosabutey/career-ops-lifesci/blob/main/.agents/skills/career-ops/SKILL.md): skill pack · Shared skill definition for the career operations workflows. · `.agents/skills/career-ops/SKILL.md`

### Workflows

Core opportunity intake, evaluation, batch, and tracking flows.

- [Verify pipe](https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/verify-pipeline.mjs): pipeline check · Validates the evaluation-to-tracker pipeline. · `scripts/verify-pipeline.mjs`
- [Merge tracker](https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/merge-tracker.mjs): tracker merge · Combines tracker additions into merged outputs. · `scripts/merge-tracker.mjs`

### Document generation

Resume and PDF output pipeline plus representative examples.

- [Generate PDF](https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/generate-pdf.mjs): document build · Creates ATS-safe tailored PDF outputs. · `scripts/generate-pdf.mjs`
- [CV template](https://github.com/mosabutey/career-ops-lifesci/blob/main/templates/cv-template.html): html template · Template used to render tailored resume documents. · `templates/cv-template.html`
- [Example report](https://github.com/mosabutey/career-ops-lifesci/blob/main/examples/sample-report.md): sample output · Representative generated report and transformation example. · `examples/sample-report.md`

### Browser automation

Playwright-assisted live application flows and portal handoff scripts.

- [Workday probe](https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/probe-workday-fill-myinfo.mjs): browser automation · Playwright probe for live application flow inspection. · `scripts/probe-workday-fill-myinfo.mjs`
- [Phenom handoff](https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/assist-phenom-review-handoff.mjs): browser automation · Human-in-the-loop review handoff for portal applications. · `scripts/assist-phenom-review-handoff.mjs`

### Dashboard

Go terminal UI for reading career data and pipeline state.

- [Dashboard main](https://github.com/mosabutey/career-ops-lifesci/blob/main/dashboard/main.go): go app · Entry point for the terminal dashboard. · `dashboard/main.go`
- [Pipeline view](https://github.com/mosabutey/career-ops-lifesci/blob/main/dashboard/internal/ui/screens/pipeline.go): ui screen · Pipeline screen for reading local career artifacts. · `dashboard/internal/ui/screens/pipeline.go`
- [Career data](https://github.com/mosabutey/career-ops-lifesci/blob/main/dashboard/internal/data/career.go): data model · Dashboard data loading and normalization layer. · `dashboard/internal/data/career.go`
- [Career model](https://github.com/mosabutey/career-ops-lifesci/blob/main/dashboard/internal/model/career.go): domain model · Shared career state and presentation model. · `dashboard/internal/model/career.go`

### Data and contracts

Local profile defaults, tracker schema, and integrity rules.

- [README](https://github.com/mosabutey/career-ops-lifesci/blob/main/README.md): repo overview · Top-level orientation for the career operations system. · `README.md`
- [Tracker contract](https://github.com/mosabutey/career-ops-lifesci/blob/main/scripts/tracker-contract.mjs): schema validation · Enforces tracker data rules and schema integrity. · `scripts/tracker-contract.mjs`
- [Profile defaults](https://github.com/mosabutey/career-ops-lifesci/blob/main/config/profile.example.yml): local config · Example local profile boundary for personal defaults. · `config/profile.example.yml`
- [Data contract](https://github.com/mosabutey/career-ops-lifesci/blob/main/DATA_CONTRACT.md): schema spec · Defines tracker and artifact integrity rules. · `DATA_CONTRACT.md`

## Connections

- Ops command → Apply: dispatches to · Command wrapper exposes the apply workflow.
- Ops command → Evaluate: dispatches to · Command wrapper exposes the evaluate workflow.
- Ops command → Batch: dispatches to · Command wrapper exposes the batch workflow.
- Ops command → Pipeline: dispatches to · Command wrapper exposes the pipeline workflow.
- Ops command → Tracker: dispatches to · Command wrapper exposes the tracker workflow.
- Career skill → Apply: encodes · Skill pack mirrors the reusable operational workflows.
- Career skill → Evaluate: encodes · Skill pack mirrors the reusable operational workflows.
- Apply → Verify pipe: uses · Apply flow depends on pipeline verification and checks.
- Evaluate → Data contract: constrains · Evaluation output must respect the shared data contract.
- Batch → Merge tracker: feeds · Batch runs accumulate tracker additions for merging.
- Tracker → Tracker contract: validates against · Tracker workflow enforces schema integrity.
- Merge tracker → Tracker contract: checks · Merged tracker output is validated after consolidation.
- Generate PDF → CV template: renders · PDF generation is driven by the HTML resume template.
- Pipeline → Generate PDF: invokes · Pipeline flow can generate tailored document artifacts.
- Pipeline → Merge tracker: updates · Pipeline flow writes consolidated tracker outputs.
- Workday probe → Profile defaults: reads · Browser automation relies on local profile defaults.
- Workday probe → Data contract: stages · Portal actions are bounded by document and tracker rules.
- Phenom handoff → Profile defaults: reads · Handoff automation uses local profile defaults.
- Dashboard main → Career data: loads · Dashboard entry point reads career data artifacts.
- Career data → Career model: maps to · Loaded artifacts are normalized into the shared model.
- Pipeline view → Career model: renders · UI screens present the career model state.
- README → Ops command: orients · Repository overview points to the command surface.
- README → Dashboard main: documents · Top-level docs reference the dashboard view.
- Example report → CV template: illustrates · Example output demonstrates template-driven generation.
