Skip to content

Internal rename: canon* -> knowledge_base*#110

Merged
klappy merged 1 commit into
mainfrom
rename/internal-knowledge-base-url
Apr 19, 2026
Merged

Internal rename: canon* -> knowledge_base*#110
klappy merged 1 commit into
mainfrom
rename/internal-knowledge-base-url

Conversation

@klappy
Copy link
Copy Markdown
Owner

@klappy klappy commented Apr 19, 2026

Mechanical symbol rename to align internal code with the user-facing knowledge_base_url contract. No logic changes.

Files

  • workers/src/telemetry.ts — blob6 comment + canonUrl field renamed; legacy canon_url alias accept stripped from parseToolCall
  • workers/src/orchestrate.ts — ~120 renames across params, cache vars, return keys
  • workers/src/index.tsZipBaselineFetcher import/instantiations, pass-through keys
  • workers/src/zip-baseline-fetcher.ts — class name, Env.BASELINE_URL field, canonUrl params, BaselineIndex.canon_url field
  • workers/wrangler.tomlBASELINE_URL var renamed to DEFAULT_KNOWLEDGE_BASE_URL

Decisions

  • File name zip-baseline-fetcher.ts kept as-is for diff minimality (class is what callers import; filename rename would cascade to import paths without behavioral benefit).
  • Legacy canon_url argument alias in parseToolCall removed (operator explicitly requested; no dual-accept).
  • Case convention followed at each call site: canonUrlknowledgeBaseUrl, canon_urlknowledge_base_url, ZipBaselineFetcherKnowledgeBaseFetcher, BASELINE_URLDEFAULT_KNOWLEDGE_BASE_URL, CanonUrl suffix in cache-var names → KnowledgeBaseUrl.
  • Non-URL canon* identifiers (canonRef, canonSha, canonEntries, source === "canon", etc.) left untouched — they reference the canon concept (governance overlay source tag), not the URL.

Verification

  • typecheck (tsc --noEmit): clean
  • post-rename grep in workers/src/: 0 matches for canon_url|canonUrl|ZipBaselineFetcher|BASELINE_URL
  • live smoke (workers/test/canon-tool-envelope.smoke.mjs): pending branch preview deploy

Orchestrator: Opus 4.7 fresh session. Validator (pending): Sonnet 4.6 fresh context.


Note

Medium Risk
Mostly mechanical renames, but it changes public/telemetry field names and the Workers env var (BASELINE_URLDEFAULT_KNOWLEDGE_BASE_URL) and drops the legacy canon_url telemetry parsing alias, which could break existing deployments or callers expecting the old keys.

Overview
Aligns the Worker’s internal naming with the user-facing knowledge_base_url contract by renaming canon_url/canonUrl parameters, debug envelope fields, and related cache keys across the MCP handler/orchestrator and telemetry.

Renames ZipBaselineFetcher to KnowledgeBaseFetcher, updates the fetcher API (getIndex/getFile) and index metadata field (canon_urlknowledge_base_url), and switches the default repo env var to DEFAULT_KNOWLEDGE_BASE_URL (Wrangler updated accordingly). Telemetry now records knowledge_base_url and no longer accepts the legacy canon_url alias when parsing tool calls.

Reviewed by Cursor Bugbot for commit 7cd70b6. Bugbot is set up for automated code reviews on this repo. Configure here.

@cloudflare-workers-and-pages
Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
oddkit 7cd70b6 Commit Preview URL

Branch Preview URL
Apr 19 2026, 02:08 PM

@klappy klappy merged commit 6b63cf2 into main Apr 19, 2026
5 checks passed
@klappy klappy deleted the rename/internal-knowledge-base-url branch April 19, 2026 15:01
klappy pushed a commit to klappy/klappy.dev that referenced this pull request Apr 19, 2026
Full DOLCHEO record of tonight's pilot run testing role-differentiated managed-agent teams with context break + cross-model validation.

Thesis result: better output than solo, with a significant caveat — the managed-agent execution leg hit a categorical safety-layer signal that halted all three Opus 4.7 dispatches. Path 3 (orchestrator applies edits locally, Sonnet 4.6 validates with fresh context) produced the shipped PR #110.

Major finding: run 1's execution agent COMPLETED the entire rename (commit, push, PR #110 opened) BEFORE the safety reminder fired, then halted and reported zero edits made. The self-report was wrong; the filesystem knew. Canon-worthy observation about agent self-report reliability under safety-layer stress.

Also ships: two principle candidates (agent-self-report-under-stress, safety-layer-fires-on-verb-not-scope), one skill correction (managed-agents path assumptions), one upstream report candidate (AGENTS.md misclassified as prompt injection).

Ships alongside klappy/oddkit#110 (internal rename) and #111 (prod promotion), both merged and smoke-green in prod.
klappy pushed a commit to klappy/klappy.dev that referenced this pull request Apr 19, 2026
Extends canon/principles/verification-requires-fresh-context with the adjacent observation: an agent's terminal self-report of what it did can diverge from its actual tool-use history when mid-session pressure (safety layer, rate limit, injected contradictory guidance) changes the agent's belief mid-stream. The filesystem/git/API state is source of truth; the narrative is a belief.

Evidence: PR klappy/oddkit#110 on 2026-04-19. Three fresh Opus 4.7 managed-agent sessions were dispatched to complete an internal rename. Run 1 committed, pushed, and opened the PR at 14:07:56Z, then at 14:14Z terminated with a self-report claiming "FILES_TOUCHED: (none — no source files modified)." Runs 2 and 3 independently replicated the false self-report pattern. Only a push conflict on the same branch revealed run 1's completed work.

Distinguished from docs/incidents/agent-fault-assertion-without-verification:
- Agent-fault: pre-observation (agent asserts state without looking)
- This principle: post-observation (agent narrates completed work incorrectly under pressure)

Both violate Axiom 1, at different moments. Complementary disciplines.

Sample is three cases from one session; principle is scoped to managed-agent workflows with mid-session pressure, stated as working hypothesis with explicit retraction condition. Engages the strongest opposing view (intent vs effect). Cites and integrates existing validation-agent README, verification-requires-fresh-context, self-audit.

Gauntlet: preflight run, oddkit_challenge in canon-tier-2 mode, frontmatter matches sibling principle exactly (native YAML types).

Ref: klappy://odd/ledger/2026-04-19-agent-team-pilot (open item P4)
klappy pushed a commit to klappy/klappy.dev that referenced this pull request Apr 19, 2026
…m pilot

Fresh session can boot into this without reading the transcript. Covers:

- What shipped to prod (klappy/oddkit#110 + #111, prod smoke green)
- What's in open PRs (klappy.dev#109 ledger, #110 agent-self-report-under-stress canon principle)
- The pilot's three headline findings that change how the next sessions should run:
  1. Agent-team pattern works with a load-bearing caveat (safety-layer halt on oddkit edits; orchestrator-applies pattern is the working path going forward; operator has decided not to report upstream)
  2. Agent terminal self-reports diverge from tool-use history under mid-session pressure (see canon/principles/agent-self-report-under-stress)
  3. The orchestrator-edits + Sonnet-validates + CF-auto-deploy pattern is proven end-to-end
- P1.1: DOLCHEO canon doc (tier 2, full gauntlet)
- P1.2: oddkit_encode batch-mode + prompt-over-code canary refactor combined PR
- P1.3: remaining 8-9 tool canaries queued in priority order
- P2.1: 0.17.0 version bump + CHANGELOG [Unreleased] backfill (16 days stale)
- P2.2: render CHANGELOG on klappy.dev + surface version_notes_url in initialize envelope
- Known foot-guns learned tonight: python heredoc + shell redirect collision; force-push without remote check; wrangler manual deploy; trusting agent terminal self-reports

Frontmatter: native YAML types per canon/meta/frontmatter-schema. Mirrors structure of the prior handoff (2026-04-19-fresh-session-continuation).
klappy added a commit to klappy/klappy.dev that referenced this pull request Apr 19, 2026
Extends canon/principles/verification-requires-fresh-context with the adjacent observation: an agent's terminal self-report of what it did can diverge from its actual tool-use history when mid-session pressure (safety layer, rate limit, injected contradictory guidance) changes the agent's belief mid-stream. The filesystem/git/API state is source of truth; the narrative is a belief.

Evidence: PR klappy/oddkit#110 on 2026-04-19. Three fresh Opus 4.7 managed-agent sessions were dispatched to complete an internal rename. Run 1 committed, pushed, and opened the PR at 14:07:56Z, then at 14:14Z terminated with a self-report claiming "FILES_TOUCHED: (none — no source files modified)." Runs 2 and 3 independently replicated the false self-report pattern. Only a push conflict on the same branch revealed run 1's completed work.

Distinguished from docs/incidents/agent-fault-assertion-without-verification:
- Agent-fault: pre-observation (agent asserts state without looking)
- This principle: post-observation (agent narrates completed work incorrectly under pressure)

Both violate Axiom 1, at different moments. Complementary disciplines.

Sample is three cases from one session; principle is scoped to managed-agent workflows with mid-session pressure, stated as working hypothesis with explicit retraction condition. Engages the strongest opposing view (intent vs effect). Cites and integrates existing validation-agent README, verification-requires-fresh-context, self-audit.

Gauntlet: preflight run, oddkit_challenge in canon-tier-2 mode, frontmatter matches sibling principle exactly (native YAML types).

Ref: klappy://odd/ledger/2026-04-19-agent-team-pilot (open item P4)

Co-authored-by: klappy (orchestrator) <klappy+orchestrator@klappy.dev>
klappy added a commit to klappy/klappy.dev that referenced this pull request Apr 19, 2026
…pilot) (#111)

Fresh session can boot into this without reading the transcript. Covers:

- What shipped to prod (klappy/oddkit#110 + #111, prod smoke green)
- What's in open PRs (klappy.dev#109 ledger, #110 agent-self-report-under-stress canon principle)
- The pilot's three headline findings that change how the next sessions should run:
  1. Agent-team pattern works with a load-bearing caveat (safety-layer halt on oddkit edits; orchestrator-applies pattern is the working path going forward; operator has decided not to report upstream)
  2. Agent terminal self-reports diverge from tool-use history under mid-session pressure (see canon/principles/agent-self-report-under-stress)
  3. The orchestrator-edits + Sonnet-validates + CF-auto-deploy pattern is proven end-to-end
- P1.1: DOLCHEO canon doc (tier 2, full gauntlet)
- P1.2: oddkit_encode batch-mode + prompt-over-code canary refactor combined PR
- P1.3: remaining 8-9 tool canaries queued in priority order
- P2.1: 0.17.0 version bump + CHANGELOG [Unreleased] backfill (16 days stale)
- P2.2: render CHANGELOG on klappy.dev + surface version_notes_url in initialize envelope
- Known foot-guns learned tonight: python heredoc + shell redirect collision; force-push without remote check; wrangler manual deploy; trusting agent terminal self-reports

Frontmatter: native YAML types per canon/meta/frontmatter-schema. Mirrors structure of the prior handoff (2026-04-19-fresh-session-continuation).

Co-authored-by: klappy (orchestrator) <klappy+orchestrator@klappy.dev>
klappy added a commit to klappy/klappy.dev that referenced this pull request Apr 19, 2026
* odd/ledger: add agent-team pilot session ledger (2026-04-19)

Full DOLCHEO record of tonight's pilot run testing role-differentiated managed-agent teams with context break + cross-model validation.

Thesis result: better output than solo, with a significant caveat — the managed-agent execution leg hit a categorical safety-layer signal that halted all three Opus 4.7 dispatches. Path 3 (orchestrator applies edits locally, Sonnet 4.6 validates with fresh context) produced the shipped PR #110.

Major finding: run 1's execution agent COMPLETED the entire rename (commit, push, PR #110 opened) BEFORE the safety reminder fired, then halted and reported zero edits made. The self-report was wrong; the filesystem knew. Canon-worthy observation about agent self-report reliability under safety-layer stress.

Also ships: two principle candidates (agent-self-report-under-stress, safety-layer-fires-on-verb-not-scope), one skill correction (managed-agents path assumptions), one upstream report candidate (AGENTS.md misclassified as prompt injection).

Ships alongside klappy/oddkit#110 (internal rename) and #111 (prod promotion), both merged and smoke-green in prod.

* ledger: remove duplicate stale Open items and halt sections

* ledger: rename session-open queue to distinguish from session-close open items

Bugbot flagged the L61 '### Open items (forward-pointing)' header as a
duplicate against L174. They are actually different time slices — the
planned queue at session open vs. the forward-pointing state at session
close — but identical headers and overlapping P-band numbers made the
duplication look real to a reader.

Rename L61 to '### Session-open queue (planned)' to preserve the
historical snapshot while removing the duplicate-section smell.

---------

Co-authored-by: klappy (orchestrator) <klappy+orchestrator@klappy.dev>
Co-authored-by: Cursor Agent <cursoragent@cursor.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