Skip to content

feat(docs): architecture case study and TASK-017 completion - #20

Merged
skibkitty merged 5 commits into
mainfrom
feat/017-case-study
Sep 4, 2026
Merged

skibkitty merged 5 commits into
mainfrom
feat/017-case-study

Conversation

@skibkitty

Copy link
Copy Markdown
Owner

TASK-017 — Architecture case study and final documentation

What this PR adds

docs/case-study.md — comprehensive architecture case study covering:

  • Core problem statement and product differentiator
  • Domain model (Project/Task/Goal entities, task status model, dependency direction)
  • Dependency graph (construction, Kahn's topological ordering, cycle detection via self-reachability)
  • Scheduling and critical path (CPM forward/backward pass, slack, critical path)
  • Decision engine (eligibility, additive scoring model, six default factors, normalization, tie-breaking, composability, selection policy)
  • Recommendation explainability (factors, assumptions, warnings, nullable recommendation)
  • Scenario simulation (three scenario types, derivation over mutation, affected-downstream filtering, comparison output)
  • Architecture and layering (UI/Application/Domain/Infrastructure)
  • Persistence (repository abstraction, StorageProvider, versioned serialization)
  • Testing strategy (287 tests, 2 E2E specs, 6 benchmarks, integration tests crossing layer boundaries)
  • Measured performance (full benchmark table from benchmark/results.txt at 100–10,000 tasks)
  • CI/CD (four-job workflow, Playwright E2E)
  • Design decisions and tradeoffs
  • Repository structure

docs/decisions.md — ADR-013 resolving project naming and availability:

  • Product name: Trajectory
  • Repository: skibkitty/trajectory-project
  • Availability: source code on GitHub (no deployment target for MVP)
  • Removed "final product name" from Pending Decisions

PROJECT_PLAN.md — resume story updated with concrete claims based on actual benchmark results and test counts (287 tests, 2 E2E specs, graph construction ~11ms at 10k tasks, recommendation ~22ms)

Other updates

  • docs/architecture.md — references the case study
  • README.md — case study added to repository guide
  • docs/handoff.md — TASK-017 marked DONE, all phases complete
  • docs/tasks.md — TASK-017 marked DONE
  • docs/progress.md — TASK-017 entry appended

Verification

  • npm run verify passes (typecheck, 287 tests, lint, format)
  • npm run build succeeds
  • All performance claims in the case study trace to benchmark/results.txt

- Add docs/case-study.md: comprehensive architecture case study covering
  core problem, domain model, dependency graph, scheduling/CPM, decision
  engine, explainability, scenario simulation, architecture/layering,
  persistence, testing strategy, measured performance (full benchmark
  table from benchmark/results.txt), CI/CD, and design tradeoffs
- Add ADR-013: project naming (Trajectory) and availability (source
  code on GitHub, no deployment target for MVP)
- Update PROJECT_PLAN.md resume story with concrete claims based on
  actual benchmark results and test counts
- Update docs/architecture.md to reference the case study
- Update README.md repository guide to include the case study
- Update docs/handoff.md and docs/tasks.md to mark TASK-017 DONE
- Append TASK-017 entry to docs/progress.md
- Remove stale 'final product name and availability' from human-decisions
  sections (case-study §14 and handoff), which contradicted ADR-013's
  resolved naming/availability decision; note the ADR-013 resolution instead
- Clarify that benchmark datasets and algorithm outputs are deterministic
  while wall-clock timings naturally vary and are machine-dependent
- Add machine context (OS, Node/npm versions, iteration counts) to the
  benchmark methodology
- Resolve the O(V+E) conflict: CPM passes are linear O(V+E), but
  topologicalOrder() uses an array ready queue that is re-sorted as nodes
  are added, so total ordering cost grows superlinearly. Clarify that
  calculateSchedule is dominated by the topological sort it invokes, and
  document the measured scaling (7.26ms at 1k tasks -> 799.31ms at 10k).
- Correct the branch-protection claim: the four CI jobs run on every push/PR
  and surface as status checks, but requiring those checks before merge is a
  repository-settings action that remains to be configured by the owner. This
  aligns the case study with docs/handoff.md, which lists branch protection
  as pending.
- Clarify that benchmark/results.txt is a git-ignored generated artifact
  (reproduced locally and uploaded as a CI artifact), not a committed file.
…list

- Reword the 10k-task scenario-simulation observation as a benchmark-context
  measurement that is 'likely acceptable for occasional interactive use' and
  a candidate for optimization, rather than a flat acceptability judgment.
- Add a short note in the CI/CD section that documentation consistency is
  treated as a review concern across the multiple state-describing files
  (implemented claims map to code, accepted decisions leave pending lists,
  future/human actions stay marked, benchmark figures trace to npm run
  benchmark output).
@skibkitty
skibkitty merged commit 5e7eccc into main Sep 4, 2026
6 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant