fix: activate agentos from link names#1
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 40a5e2353c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| Open a fresh persistent Planner Agent session: | ||
|
|
||
| ```sh | ||
| pi --link --link-name planner | ||
| ``` |
There was a problem hiding this comment.
Stop calling --link-name a fresh-session command
For users who already have a Pi session in this cwd, pi --link --link-name planner does not force a new session; pi-link documents --link-name as link identity only and leaves Pi's normal session selection untouched (latest session in cwd, or fresh only when there is none). This example can make users attach the Planner Agent role to an existing conversation when they expected a clean persistent session, so the README should either describe the normal Pi selection behavior or include the actual fresh-session mechanism.
Useful? React with 👍 / 👎.
Summary
pi-link <agent>now reliably becomes that AgentOS role when the project registry declares it, while undeclared link names remain plain pi-link sessions. The fix also documents the intended fresh/resume flows and adds/agentos-statusso users can confirm whether the current session is role-backed, fallback-only, or failing to load.The important behavior is now:
pi-link plannerplannerlinked session and activate Planner Agent when declaredpi --link --link-name plannerpi --link --link-name planner --no-session/agentos-statusDesign notes
--link-nameflag,PI_LINK_NAME, pi-link savedlink-nameentries, and finally the Pi session name.Verification
npm test— 17 passingnpm pack --dry-runnode -e "import('./index.ts').then(() => console.log('index import ok'))"git diff --checkpi --link --link-name plannerreplied as Planner rolepi --link --link-name scratchstayed plain Pi