Harness Intelligence Wiki
SpecsCLIIP-96-monorepo-foundation

Implementation Notes

Implementation Notes

Summary

  • Scaffolded the Harness Intelligence product monorepo foundation and committed it as 3f7890c.
  • Moved the existing CLI into apps/cli while preserving executable bins and behavior.
  • Added app boundaries for apps/api, apps/wiki, and apps/web, plus package boundaries for shared auth/config/contract/db/env/ui concerns.
  • Ran and reconciled dp scaffold setup output into scoped prompts, hooks, skills, harness mirrors, subagent manifest, and .devpunks metadata.
  • Replaced default Fumadocs sample docs with Harness/CLI wiki pages that point back to the durable source wiki tree.

Execution Mode

Sequential. The monorepo foundation move was tightly coupled, and two read-only review workers timed out without returning findings; implementation ownership and review synthesis stayed local.

Deviations From the Plan

  • The foundation implementation happened before this formal IP-96 spec/plan pass because the initial milestone bootstrap was required before the ordered epic loop could start.
  • A local review found and fixed the wiki/Fumadocs merge issue before IP-96 closeout.

Surprises and Decisions

  • Initial dp scaffold setup detection included .devpunks-cache, bundled skill templates, and CLI test fixtures. Detection ignore rules were tightened before accepting scaffold output.
  • Root check originally formatted generated skill/template surfaces too broadly. Oxlint/Oxfmt ignores were scoped so generated skill mirrors are not treated as product code.
  • The scaffolded Hono backend remains explicitly temporary; final Effect HTTP router/layer work is deferred to later contract/backend scope.

Sanity Checks

CheckResultNotes
bun run checkPassedOxlint plus Oxfmt check.
bun run check-typesPassedTurborepo typecheck tasks.
bun run testPassedCLI Vitest suite: 12 files, 56 tests.
bun run buildPassedCLI, API, web, and wiki build through Turborepo.
bun run build --filter=@punks/wikiPassedWiki renders CLI domain docs; Next warns only about unset metadataBase.

Acceptance Criteria Status

CriterionStatusNotes
Repository is a Turborepo/workspace monorepoDoneRoot workspaces cover apps/* and packages/*; turbo.json exists.
Root scripts delegate through turbo runDoneRoot scripts call Turborepo filters or full task runs.
apps/cli owns executable binsDoneapps/cli/package.json owns devpunks, dp, and punks.
Existing CLI workflows remain availableDoneCLI package exposes build/test/local/baseline/release/sync scripts; root delegates to them.
Existing CLI behavior is preservedDoneCLI test suite passes after relocation and fixtures were restored under apps/cli/test-fixtures.
Other packages do not import from apps/cli internalsDoneNo shared package imports apps/cli internals.
App boundaries exist for API/wiki/webDoneapps/api, apps/wiki, and apps/web are present and buildable.
Package boundaries exist for foundation packagesDonepackages/auth, config, contract, db, env, and ui exist.
Changed-package validation can use TurborepoDoneRoot tasks and package-local scripts support filtered/full validation.
Scoped guidance and symlink mirrors existDoneRoot/docs/apps/packages have AGENTS.md; scoped CLAUDE.md files are symlinks.
Docs/runbooks explain the new shapeDoneREADME.md, docs/README.md, and docs/runbooks/dp-cli-scaffolding.md were updated.

Manual Review Checklist

AreaCheckHow to performExpected result
CLI relocationConfirm bins and root delegationInspect apps/cli/package.json and root package.jsonBins live in apps/cli; root scripts use turbo run.
ValidationConfirm full root validationRun bun run check, bun run check-types, bun run test, bun run buildAll commands pass.
Wiki mergeConfirm rendered content is not Fumadocs sample contentRun bun run build --filter=@punks/wiki and inspect apps/wiki/content/docs/cliBuild includes /docs/cli routes.
Scaffold outputConfirm generated artifacts are reconciledInspect .devpunks/AGENT-HANDOFF.md, .devpunks/scaffold-manifest.json, .agents/subagents/manifest.mjsReal workspace paths and Harness-shaped subagents are present.

Pre-existing Issues

  • None blocking IP-96.

Out of Scope Observations

  • apps/api still uses Better-T-Stack/Hono scaffold shape. Final backend replacement belongs to the Effect HTTP router/layer work after IP-96.
  • packages/contract is intentionally skeletal until IP-97 defines the shared Effect API contract boundary.
  • Next build warns that wiki metadataBase is unset; this is non-blocking for IP-96.

Remaining Work

  • Close IP-96, IP-109, IP-110, and IP-111 in Linear after committing this closeout.

Steering

DateFeedbackChanges
2026-05-12Initial M1 goal requires strict epic order and subissue closeout.IP-96 spec explicitly absorbed IP-109, IP-110, and IP-111.

On this page