Skip to content

Use superpowers to implement spec#5

Open
chapter37haptics wants to merge 19 commits into
chapter37haptics/customized-domainfrom
customized-domain-superpowers
Open

Use superpowers to implement spec#5
chapter37haptics wants to merge 19 commits into
chapter37haptics/customized-domainfrom
customized-domain-superpowers

Conversation

@chapter37haptics
Copy link
Copy Markdown
Owner

@chapter37haptics chapter37haptics commented May 15, 2026

Use superpowers to implement the spec from customized-domain branch

chapter37haptics and others added 12 commits May 15, 2026 02:54
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Extends the entity reference regex so markdown links like [text](goals/slug)
and wikilinks like [[goals/slug|text]] are recognized as graph edges.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…r domain

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@chapter37haptics
Copy link
Copy Markdown
Owner Author

Codex Review (gpt-4.1-codex)

GATE: PASS — 4 findings, 0 critical

Findings (severity order)

1. Medium: Singular/plural DIR_PATTERN inconsistency
markdown.ts:361 accepts singular paths (/goal/, /decision/, /process/) via inferType, but link-extraction.ts:46 DIR_PATTERN only matches plural dirs (goals|decisions|processes). A link like [X](goal/slug) would get typed correctly but fail auto-linking.

Claude's take: Low real-world impact. Canonical directories are always plural. The existing codebase has the same pattern — inferType accepts /person/ but DIR_PATTERN only has people. Defensive fallback, not a bug.

2. Medium: doctor.ts graph_coverage excludes concept
The SQL clause adds goal/decision/process but still excludes concept, which is now a first-class developer entity.

Claude's take: Pre-existing gap, not a regression from this PR. concept was already excluded before these changes. Worth a follow-up.

3. Medium: writes_to drops VC entities (intentional)
brain-ops and signal-detector no longer declare people/, companies/, deals/, meetings/ in their writes_to frontmatter.

Claude's take: Intentional per spec — "VC types remain in the infrastructure but the agent's behavioral layer stops triggering on them."

4. Low: Test coverage gaps
Missing: singular-dir extraction tests, wikilink tests for decisions/ and processes/, regression tests confirming old dirs still match after DIR_PATTERN expansion.

Verification Evidence

  • bun run typecheck: PASS (exit 0)
  • 485 tests across 7 affected test files: 0 failures
  • bun run verify (CI pre-test gate): PASS

Recommendation

Ship as-is. Finding #1 is a pre-existing pattern in the codebase, #2 is a pre-existing gap, #3 is intentional. Finding #4 (additional test coverage) is polish, not a blocker.


🤖 Review by Codex CLI (codex exec, reasoning effort: high, 53k tokens) + Claude synthesis

Codex cross-model review flagged that we touched this query to add
goal/decision/process but left out concept, which is now a first-class
developer entity. One-line fix.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@chapter37haptics
Copy link
Copy Markdown
Owner Author

Claude's Evaluation of Codex Review Findings

Verified each finding against the actual codebase before deciding what to do.

Finding Verdict Reasoning
#1 Singular/plural DIR_PATTERN No action Pre-existing pattern. inferType accepts /person/ but DIR_PATTERN only has people. The singular forms are defensive fallbacks for directories that canonically use plural names.
#2 doctor.ts excludes concept No action (initially) Pre-existing gap, not a regression. concept was already excluded before this PR.
#3 writes_to drops VC entities No action Intentional per spec: "VC types remain in the infrastructure but the agent's behavioral layer stops triggering on them."
#4 Test coverage gaps No action We have 1 wikilink test for goals/ proving DIR_PATTERN works for new entries. Additional singular-dir and wikilink tests are polish, not blockers.

@chapter37haptics
Copy link
Copy Markdown
Owner Author

Codex Second Opinion on Claude's Dismissals

Asked Codex to evaluate whether Claude's dismissals of the original 4 findings hold up.

Finding Codex Grade Codex's Take
#1 Singular/plural DIR_PATTERN PARTIAL Claude is right on low impact, but the existing person/people mismatch is "precedent for technical debt, not proof this is safe."
#2 doctor.ts excludes concept PARTIAL "Pre-existing" is factually plausible but weak — this PR did modify that exact query and expanded entity typing. Leaving out concept keeps health metrics misaligned with the new first-class entity framing. Worth fixing.
#3 writes_to drops VC entities VALID Intentional and internally consistent. Only caveat: it is a behavior change and should be called out as such.
#4 Test coverage gaps PARTIAL "One wikilink test proves DIR_PATTERN works" is too broad a claim. Real risk is low-to-moderate, not zero.

Action taken: Fixed finding #2 — added concept to the doctor.ts graph_coverage SQL clause (commit 5856aa2). Codex was right that touching the query and leaving concept out was a missed opportunity with a one-line fix.

Other findings: dismissals stand. #1 and #4 are real but low-risk technical debt, #3 is intentional.

chapter37haptics and others added 2 commits May 15, 2026 21:09
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…spec

Tests use slugs from a real development goal (email chain bounding box
detection). Covers: realistic goal/concept slugs, frontmatter type override,
decisions-log false positive regression guard, wikilinks for decisions/ and
processes/, mixed entity body extraction, code block exclusion, and VC dir
regression.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@chapter37haptics
Copy link
Copy Markdown
Owner Author

Codex Spec-vs-Tests Audit

Asked Codex to grade each spec requirement against the actual test suite.

Spec Requirement Grade Notes
types.ts: add goal/decision/process to PageType + ALL_PAGE_TYPES TESTED (loose) No assertion on ALL_PAGE_TYPES count (25)
markdown.ts inferType(): map goals/, decisions/, processes/ TESTED (tight) 3 direct path tests + longest-prefix test
inferType longest-prefix: projects/x/decisions/y -> decision TESTED (tight) Regression would fail
link-extraction.ts DIR_PATTERN: add goals/decisions/processes TESTED (tight) Both markdown-link + wikilink syntax covered
VC types stay in infrastructure TESTED (loose) people + companies checked, not full legacy set
DIR_PATTERN used by ENTITY_REF_RE and WIKILINK_RE TESTED (tight) Both syntaxes directly tested

Untested but not actionable (skill-layer agent behavior, not unit-testable):
MECE boundaries, debug trail placement, page template schema, execution order

Action taken: Added ALL_PAGE_TYPES.length === 25 assertion to pin the exact type count (commit incoming).

chapter37haptics and others added 4 commits May 15, 2026 21:32
Codex spec audit flagged that the contract test checked entries were
non-empty but didn't pin the count. Adding or removing a type would
pass silently.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Experiment 1: tested whether gbrain fires during a /goal session with
customized-domain skills loaded. Result: zero brain interactions across
288 session log lines. Root cause: advisory instructions ignored under
task execution pressure. Includes cross-model analysis (Claude + Codex),
ideal session flow, fix priority, and CLAUDE.md patch for fix #4.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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