feat: implement scope organization runtime for RFC #1345 - #1401
Conversation
There was a problem hiding this comment.
license-eye has checked 978 files.
| Valid | Invalid | Ignored | Fixed |
|---|---|---|---|
| 704 | 21 | 253 | 0 |
Click to see the invalid file list
- integrations/codex/plugins/powercontext/hooks/bind_tools.py
- integrations/codex/plugins/powercontext/hooks/session_binding.py
- integrations/codex/plugins/powercontext/scripts/scope_binding.py
- src/powercontext/builtin/handoff_report/init.py
- src/powercontext/builtin/handoff_report/adapters.py
- src/powercontext/builtin/handoff_report/canonical.py
- src/powercontext/builtin/handoff_report/errors.py
- src/powercontext/builtin/handoff_report/protocols.py
- src/powercontext/builtin/handoff_report/rendering.py
- src/powercontext/builtin/scope/init.py
- src/powercontext/builtin/scope/application.py
- src/powercontext/builtin/scope/errors.py
- src/powercontext/builtin/scope/models.py
- src/powercontext/builtin/scope/repository.py
- src/powercontext/server/static/handoff-report.js
- src/powercontext/server/static/scope-selection.js
- src/powercontext/server/templates/pages/handoff_report.html
- tests/builtin/test_scope_application.py
- tests/codex_plugin/test_scope_binding.py
- tests/test_handoff_report.py
- tests/test_scope_api.py
Use this command to fix any missing license headers
```bash
docker run -it --rm -v $(pwd):/github/workspace apache/skywalking-eyes header fix
</details>
POWERCONTEXT: AGENT <-> SCOPE INTERACTION MAPA Scope is server-owned. Agent, session, workspace, repository, SCENARIO 1: NEW AGENT SESSIONFirst prompt: SCENARIO 2: RESUME OR REUSE AN EXISTING SCOPEResume the same session: Start a new session with a workspace binding: Explicitly reuse or switch to Scope Y: Next request uses Scope Y: SCENARIO 3: CREATE A NEW ISOLATED SCOPEExplicit switch: SCENARIO 4: MULTIPLE AGENTSShare all state: Both sessions are bound separately to Scope X. Shared inside Scope X:
Isolate independently continuable work: Create children: Parent means organization only. It does not inherit or share data. SCENARIO 5: READ FROM OR DELIVER ACROSS SCOPESDirect Context Reference: Deliver one accepted result: Publication copies only the selected Artifact revision. KEY RULES
|
907b730 to
605701b
Compare
|
resolve conflicts |
Which issue or RFC does this PR close?
Implements the runtime design in #1345.
Rationale for this change
Scope is the durable boundary for memory ownership, isolation, sharing, and reporting. The runtime and Agent integrations need to use the same server-owned Scope model instead of Project, Workstream, or client-generated Scope identifiers.
What changes are included in this PR?
Are there any user-facing changes?
Yes. This is a breaking change:
How was this change tested?
make checkmake testmake contract-testmake docs-testmake harness-checkAI usage statement
OpenAI Codex was used for code analysis, implementation, tests, and documentation editing.