Skip to content

feat(aligned-onboarding): Knoweth organize part (global+tags today, family lanes as forward path) - #175

Merged
motionBuilderEric merged 8 commits into
eric/aligned-onboarding-v2-meta-packagefrom
runneth/knoweth-organize-onboarding
Jul 24, 2026
Merged

feat(aligned-onboarding): Knoweth organize part (global+tags today, family lanes as forward path)#175
motionBuilderEric merged 8 commits into
eric/aligned-onboarding-v2-meta-packagefrom
runneth/knoweth-organize-onboarding

Conversation

@rezakhadjavi

Copy link
Copy Markdown
Contributor

Add the Knoweth "organize the brain" part to aligned-onboarding

Stacked on #172 (base is that PR's branch), so this shows only the Knoweth additions. Merge after / into #172.

What this adds

  • aligned-onboarding/knoweth/knoweth-organize-onboarding-package.md — the cross-cutting Knoweth part, in the same house style as the meta parts (version, one-line model, activation with two sentinel guard blocks, hard-gate prerequisites, scope, persistence, honesty section, changelog).
  • install-config.json — registers the file (v2.2.0) so it stages to /agent/brain/aligned-onboarding/.
  • README.md — adds the "Organize with Knoweth (after the questions are answered)" step to the run order.

The part in one line

After the account questions are answered and content has landed, organize the brain so retrieval stays tight, then hold it with a standing save + maintenance contract (the runneth:knoweth-organize and runneth:knoweth-brain guard blocks merged into user.md).

Key design decision (grounded in the harness code)

The harness requests exactly [user:<userId>, project:<workspaceId>, global], and project is the Motion workspace. So today: keep all shared content in the global lane and slice it with tags + a naming decoder; user: lanes for isolation; the workspace project lane is automatic. Do not carve data-source-family or initiative lanes on a live VM — they are not queried yet and the content would go dark. The family-lane scheme is documented as a forward path gated on a harness change (option B), not shipped.

Open items for review

  1. Harness dependency: family/business lanes need the harness to layer configured lanes into the requested read set. Needs an owner (fits the Knoweth UX followups ticket, PDEC-9225).
  2. Manifest naming: repo README specifies runneth-package.json schema-v1; aligned-onboarding uses install-config.json. Worth reconciling for the OS-package migration.
  3. Sequencing: organize is placed after the account questions and before the validation loop, so validation exercises the organized brain. Confirm that's the intended order.

@rezakhadjavi

Copy link
Copy Markdown
Contributor Author

Expanded the Knoweth organize doc from a thin "organize step" into a full operational spec, and made the lane model consistent throughout (option B: everything in global + tags today; user: isolation; project = the Motion workspace; family lanes are a documented forward path gated on the harness layering configured lanes).

Added sections: save routing + refresh, how to decide the lanes/config (tags + naming decoder, family-lane candidates for later), the Standard-spec format and the three specs, the front-matter schema, the existing-org repair checklist, the validation / retrieval smoke test, gotchas, a worked example, and the standard-vs-brand-decided framing. Dropped only the repo-meta "packaging" notes (they live in this PR description, not the staged doc).

Still open (unchanged): the harness dependency to layer configured lanes (fits PDEC-9225), the runneth-package.json vs install-config.json manifest-name reconciliation, and confirming organize-before-validation sequencing.

…t-in-Knoweth, no-Knoweth-aware, user/workspace lane scenarios, org-type adaptation, standard-spec detail, maintenance section
@rezakhadjavi
rezakhadjavi marked this pull request as ready for review July 23, 2026 20:28
@rezakhadjavi

Copy link
Copy Markdown
Contributor Author

Updated to v1.0 (final, not a draft) and marked ready. Changes from the round of review:

  • De-drafted to match the folder (most parts don't say "draft"; version line is now v1.0, and the PR is no longer a draft).
  • Activation matches the other parts' convention now: an explicit MERGE INSTRUCTIONS block for the two sentinel guards, same shape as the meta validation/account-context parts.
  • Why some data isn't in Knoweth spelled out: Knoweth indexes brain files; the creative store (Cacheth) and performance store (Counteth) are surfaced through it, not duplicated into the index (index bloat / split truth / staleness). The wiki points at the database.
  • Works with or without Knoweth: the organizing discipline (folders, tags, save routing, specs, maintenance) is retrieval-agnostic; only the lane config is Knoweth-specific, so the parallel no-Knoweth variant reuses everything else. Framed for the harness rollout, so nothing depends on Knoweth being live on a given VM.
  • How/when lanes get set up (users + workspaces): global by default, the workspace project:<workspaceId> lane is automatic, user: lanes only for genuine per-person isolation, custom lanes are forward-path only.
  • Adapts to org type from prod usage: most orgs are single-workspace (all global + tags), but multi-workspace orgs (agencies/large teams) drive most activity and get per-client separation free from the automatic workspace lane, so shared knowledge goes in global and no custom per-client lanes.
  • Standard-spec detail expanded (the four-part spec shape + the primitive specs it backs: dashboard, context source, routine).
  • Maintenance section added: the runneth:knoweth-brain guard + the brain-maintenance routine are the two mechanisms, with user.md as the durable home.
  • De-internalized: removed environment/codename references so it reads as a customer-installed file.

On activation (the double-check): aligned-onboarding has no auto-activation, it triggers when a person runs the package/README (same as every other part). This file is staged via install-config.json, is in the README run order, and activates by merging its guards during that run, so a run that follows the README will trigger it. If we want it guaranteed rather than run-order-dependent, that needs the orchestrator step (still open) or promoting the package to the schema-v1 package_instruction format.

@rezakhadjavi

Copy link
Copy Markdown
Contributor Author

Applied the "now" batch from review:

  • A1 - deterministic activation. Added an Activation checklist to the doc (both sentinels present in user.md, organize step ran, brain-maintenance routine exists) and strengthened the README run-order step to name both guard merges (runneth:knoweth-organize + runneth:knoweth-brain) explicitly. This closes the "does it actually get triggered" gap for a run that follows the README, without waiting on the orchestrator.
  • A2 - pre-Knoweth / prod note. The doc now says setup is fine before the Knoweth harness reaches a VM: organizing, tags, save routing, specs, and maintenance work regardless of harness; only lane/project scoping goes fully live once the harness lands. Nothing blocks setup or promises lane behavior that isn't on yet.
  • A4 - detect org type. Organizing now starts by reading single- vs multi-workspace and branching (single = all global+tags; multi = automatic per-workspace lane + shared knowledge in global, no custom lanes).

Still open and not in this PR: guaranteed activation via an orchestrator or the schema-v1 package_instruction format, the harness lane dependency on PDEC-9225, the manifest-format reconciliation, and the deck install-slide update. A3 (splitting out the Knoweth-only section for the no-Knoweth variant) is held pending the variant-shape decision.


## 12. Rollout, triggering, and how it stays consistent
- **The package ships to the GitHub repo and installs on every VM, but installing does not act.** A trigger is needed: an SSH conversation per VM that says "use this package / do the readme," which runs the setup. New orgs onboard this way; existing orgs get a manual cleanup pass.
- **VoC auto-installs on connect** (the connect-time dispatch), so a connected platform pulls without a manual trigger; secrets-path platforms use the manual `package intent add-integration` route.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

VoC doesn't auto install on connect anymore, right?

- `[[lane_assignments]]` override the lane for a root-relative path glob, last match wins (e.g. `css-2026/**` -> `project:css-2026`). This is how a project or business lane is carved out of a tree.
- `[policy]` with `default_read_lanes` and `[[policy.lane_grants]]` keyed by `user_id` and/or `project_id` (each `read = [lanes...]`, optional `write`) is the ACL: it decides which layered lanes a request can read. User/team separation lives here (grant `user:alice` only to `user_id = "alice"`).
- `[embeddings]`, `[hybrid]`, `[resolver]` tune the search channels (checked-in default is guarded OpenAI hybrid: lexical + graph + adaptive dense, fused with RRF).
The lane count matters because every authorized lane is scored per query; keep the set small (verify the cap). **Caveat: today only `global`, `user:<userId>`, and `project:<workspaceId>` are in the requested read set, so `[[lane_assignments]]` that create family/initiative lanes are forward-path only, using them now hides content.** Keep content in `global` plus tags until the harness layers configured lanes. The skeleton plus the front-matter attributes are the content the config's roots/assignments are generated from. Note the repo is migrating to the OS package format (`runneth-package.json` schema-v1, targets under `agent_brain`/`agent_skills`/`agent_tools`/`agent_apps`); the Knoweth package registers there.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

runneth-package.json → package.json already landed repo-wide on this PR's base branch (via #159/#172) so the manifest name here is stale, and the validator expects package.json.

---

## 5. Front-matter (findability and provenance, not a filter)
Front-matter is **not a Knoweth query filter.** Retrieval runs on lane (today `global`, `user:<userId>`, and the workspace) plus lexical/dense search over the text. The header earns its place for four things only: lexical findability (facet words become searchable text), provenance (`sources` cite the exact raw file), chunk-standalone context (a chunk is retrieved without its neighbors), and agent-side filtering of returned files. Keep it lean and do not restate what the path or config already encode. VoC raw file (one per item), aligned to the installer package's unified record:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this tells runneth to add front-matter to VoC files, but the shipped voc template doesn't use front-matter at all.
metadata lives in the collapsed YAML block at the bottom (front-matter rendered badly in the file viewer, check out Harry's okendo files, so we dropped it).

so these two docs disagree about the same files. can this section just point at the voc template and use that metadata block as the tag source?

we can also go back to front matter. It is a UI thing, but maybe we're less concerned.

voc/<integration>/ticket-<id>.md # (no reviews/ or tickets/ subfolders)
voc/meta-ads/comment-<id>.md # meta ad comments are VoC
voc/reddit/post-<id>.md
voc/<integration>/<integration>-context.md # compiled: segments, personas, keywords, quotes

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this puts a summary file in the folder where the voc sync writes raw items - the skill uses that folder for its "empty → backfill" and "newest item date" checks, so a non-item file can trip both. move it one level up?

@motionBuilderEric

Copy link
Copy Markdown

I left direct inline comments for a few of these already

All in runneth-apps unless noted:

  • knoweth/knoweth-organize-onboarding-package.md (~line 204): tells runneth to add front-matter to VoC files; the shipped template (voc-data-pull/templates/*.md) has none, metadata is the bottom block. Should defer to the voc format.
  • Same file, skeleton (~line 179): puts <integration>-context.md inside the VoC raw items folder; conflicts with voc-data-pull/SKILL.md's items-only contract and its backfill/window checks. Move compiled output out.
  • Same file, Guard 1 (~line 29): "organize if not organized yet" has no durable done-marker, so it can double-fire across conversations. Gate on decoder-file existence.
  • Same file, Guard 1: "content has landed" can be true mid-backfill. Gate on the sync run's coverage-complete report.
  • Run order lives in 3 places and disagrees: aligned-onboarding/README.md step 5, the knoweth doc's "where it sits" section, and Guard 1. Single-source in the README.
  • Same file (~line 199): stale facts. "VoC auto-installs on connect" (now manual), the package intent add-integration route (index is empty on this branch), and runneth-package.json (renamed to package.json on the base branch).
  • Same file: restates the VoC skeleton/schema it doesn't own despite its own "one owner per fact" rule. Replace with pointers to voc-data-pull/SKILL.md.
  • Same file, Cacheth notes: the flag flipping mid-life leaves files and Cacheth both populated; no reconciliation step.
  • Not an issue, verified: the lane model (global plus tags today) matches agent-builder's apps/agent/src/harness/harneth/harneth-harness.ts resolveKnowethReadLanes, which requests exactly [user, project:<workspaceId>, global]. The forward path (family lanes) needs that harness function to layer configured lanes; that's the agent-builder dependency to file (PDEC-9225 fits).

…record, no per-creative brain files

- Rewrite the Creative Attribution playbook as the creative-content-layer contract: what Cacheth holds per creative, the query paths (Knoweth injection first, then the motion cache CLI), and the naming decode - all local, no API calls, nothing written to the brain
- Fold the naming decode into account-context.md Field 4 (no separate taxonomy file); Field 4 starts from the Step 1 provisional table
- Reframe per-creative-file rules from prohibition to ownership: person-requested snapshots allowed, sweep asks before archiving
- Validation (v1.3) gates on cache coverage instead of files and adds the show-the-work loop rule
- Upgrade the Knoweth answer standard: read the naming decode before name filters, route structural vs creative questions by signal, frame performance + VoC as one system, state filter/signal/unconfirmed on analytical answers
- Stage the Cacheth command reference beside the Data-Query Guide; reconcile all cache command syntax against it

Co-authored-by: Cursor <cursoragent@cursor.com>
@motionBuilderEric
motionBuilderEric merged commit 1799273 into eric/aligned-onboarding-v2-meta-package Jul 24, 2026
2 of 3 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.

3 participants