Skip to content

fix(routing): recognize the AIOS root as Shared - #146

Closed
filocosta46 wants to merge 6 commits into
mainfrom
fix/aios-root-defaults-to-shared
Closed

fix(routing): recognize the AIOS root as Shared#146
filocosta46 wants to merge 6 commits into
mainfrom
fix/aios-root-defaults-to-shared

Conversation

@filocosta46

Copy link
Copy Markdown
Owner

What this does

  • defaults a validated, stable AIOS root to Memory: Shared while preserving unique active verified project precedence
  • keeps invalid, swapped, unsafe, conflicting, and unverified roots and workspaces at Memory: Off while preserving the exact two-field identify JSON contract
  • binds generated bridges to the exact configured AIOS root and keeps portable project handoff text free of machine-local paths

What this does not do

  • does not publish a new npm version or GitHub release
  • does not widen Shared memory to managed workspaces or unrelated folders
  • does not weaken project registration or approval boundaries

How this was checked

  • node --test tests/**/*.test.mjs — full clean-tree suite: 2,680 passed, 9 skipped, 0 failed (2,689 total)
  • npm run smoke
  • focused custom-root, config-identity, root-swap, duplicate-owner, fail-closed, JSON-contract, bridge, privacy, and shell-quoting regressions
  • live dogfood receipts: AIOS root → Shared; registered DotAIOS checkout → This project; unrelated directory → Off
  • independent privilege-boundary review: no findings

filocosta46 and others added 6 commits September 4, 2026 10:20
`project identify` was binary: a registered project, or `Memory: Off`. The
AIOS folder is never itself a registered project, so identifying from inside
it always fell through to `Memory: Off` — the most closed mode, in the one
folder whose entire purpose is the memory it holds. Reaching Shared required
the user to say "use my memory" while already standing in their own memory.

identify now reports `Memory: Shared` with `aios_folder: true` when the cwd
resolves inside the AIOS folder, and the managed bridges forward that receipt
instead of re-deriving a mode. Containment goes through the symlink-aware
`isPathWithin`, so a sibling sharing a path prefix stays `Memory: Off`.

Scope is unchanged everywhere else: a registered project still wins, an
unrelated directory is still `Memory: Off`, and `Private chat` still locks
`Memory: Off` ahead of the receipt.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The black-box induction run pins the exact `project identify --json` shape from
the packed product. Its receipt is unchanged — an unregistered project folder
outside the AIOS folder is still `Memory: Off`.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: ASSERTIVE

Plan: Team

Run ID: a22a84a3-d24c-4947-a7f5-868000c80526


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@filocosta46

Copy link
Copy Markdown
Owner Author

Superseded by #150.

That branch carries this work reconciled with the other two context-admission PRs, and #150's head is green on all 8 checks. Verified equivalence before closing: #150 retains 18/18 of #146's added tests, 6/6 of #147's, and 9/9 of #148's (one renamed). #146's head here never received the project-root-swap repair; #150 contains it, byte-identical to the reviewed local fix.

This head is older than #150 and conflicts with it, so merging it would regress. Closing rather than merging. The branch is archived in a local git bundle and this PR can be reopened if #150 is ever abandoned.

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