You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "robocanic (via GitHub)" <gi...@apache.org> on 2026/08/22 01:39:52 UTC
[I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
robocanic opened a new issue, #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539
<!-- Please only use this template for submitting feature requests -->
为Dubbo Admin Agent 实现完整的上下文管理功能:
1. Prompt Template的占位和渲染。System Prompt, AI Message, User Message 的组合。
2. 长对话的上下文压缩。
3. 跨对话的记忆机制。
更多细节请参考:https://summer.ospp.ac.cn/org/prodetail/26cf40055?list=org&navpage=org
> English version
Implement comprehensive context management for the Dubbo Admin Agent:
1. Prompt template placeholders and rendering, including the composition of system prompts, AI messages, and user messages.
2. Context compression for long conversations.
3. A cross-conversation memory mechanism.
For more details, please refer to: https://summer.ospp.ac.cn/org/prodetail/26cf40055?list=org&navpage=org
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "Qiao-yq (via GitHub)" <gi...@apache.org>.
Qiao-yq commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-6093674127
## Proposed Phase 1 Breakdown
Phase 1 covers requirements 4, 5, and 6, plus the foundational parts of requirements 8 and 12. It establishes the security and lifecycle boundaries required before introducing Context Compiler, Summary, long-term Memory, or RAG.
| PR | Scope | Acceptance boundary |
| --- | --- | --- |
| PR 1: Session Ownership Foundation (#1592) | Server-owned identity context, tenant/owner persistence, Store enforcement, and isolation across Session APIs, Chat, History, and Delete | Cross-user and cross-tenant Session access is rejected consistently |
| PR 2: Sensitive-Data Controls | Data classification, log/audit redaction, derived-data allowlists, secret detection, and temporary model-input filtering | Canonical messages are not silently rewritten; sensitive content does not enter logs, audits, or unauthorized derived data |
| PR 3: Session Lifecycle | Idempotency, concurrent Turn control, quotas, retention, deletion propagation, cleanup, and reconciliation | Retries and concurrent writes are safe; deleted data becomes immediately unreadable and derived cleanup is recoverable |
| PR 4: Production Security and Rollout Gate | JWT or signed-gateway authentication, resource-level authorization, Usage/Cost, privacy-safe audit, feature flags, and the G1 suite | Production identity and resource permissions are verified; static mode cannot pass production acceptance |
### Scope Notes
PR #1592 implements the Session ownership foundation of requirement 4. Its static authenticator is limited to local development and does not represent complete production authentication.
Requirement 4 is complete only after PR 4 provides:
- at least one production authenticator;
- policy resolution from untrusted resource references to authorized scopes;
- resource-permission enforcement across Session APIs, Chat, History, and Delete;
- credential, cross-tenant, and resource-revocation tests.
PR 2 separates canonical-data protection from redaction:
- canonical messages use access control, encryption, and retention;
- logs and audits never retain raw sensitive text;
- indexes and derived Memory use field allowlists and secret detection;
- model input uses a temporary policy-filtered view without rewriting canonical records.
### Phase 1 Exit Gate
Phase 1 is complete only when production authentication, resource authorization, concurrency, quota, deletion, cleanup, and sensitive-data tests pass against both Memory and GORM stores.
Detailed API, migration, and threat-model decisions remain in the corresponding PRs and ADRs.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "larry-zy (via GitHub)" <gi...@apache.org>.
larry-zy commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-5567895247
Pure prompt and prompt-assembly issues include: the final-answer phase reuses a system prompt that instructs the model to call tools when needed, while tools are no longer bound and the model is simultaneously required to produce a final answer. This creates an instruction conflict that may lead to fabricated verification or invalid tool calls. The prompt should therefore be split into separate act and final-answer policies, with the final-answer policy explicitly stating that no tools are available and that the answer must rely only on already provided evidence. Other issues include absolute history instructions that can induce hallucination; no clear distinction between confirmed facts, inferences, and unknowns; undefined user-facing behavior for tool failures, timeouts, empty results, and unavailable data; no rule that user input, retrieved documents, tool outputs, and future Memory content must be treated as untrusted data rather than executable instructions; redundant injecti
on of tool names; and overly specific, easily outdated infrastructure rules. The prompt should be simplified into reusable policy fragments and retain stable decision principles rather than hardcoded tool names or metric details. Diagnostic answers should also follow a minimum structure covering conclusion, evidence, uncertainty, and recommended next steps. These changes are limited to `ai/prompts/agentReasonAct.txt` and `ai/component/agent/react/prompt.go` and do not depend on storage, compression, hooks, middleware, or changes in other modules.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "larry-zy (via GitHub)" <gi...@apache.org>.
larry-zy commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-5580187308
@Yuqi Qiao
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "larry-zy (via GitHub)" <gi...@apache.org>.
larry-zy commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-5778304014
The next phase of context engineering should provide an extensible, secure, and measurable pipeline for assembling
model inputs. Each context source should have explicit permissions, provenance, freshness, lifecycle, and token
limits. The implementation should use project-owned interfaces without integrating PowerContext. Reviewing the
design document also highlights requirements that need explicit coverage: shared security controls, storage limits,
evidence precedence, memory deduplication, and deletion of derived data.
1. Unified Context Compiler
Define extensible context-source interfaces and assemble authorized sources into model inputs. Record included
and omitted items with reasons, support bounded historical queries, and prioritize fresh tool evidence over
historical summaries or memory.
2. Versioned Prompt Templates
Support template variables, message roles, versioning, and backward compatibility. Restrict available variables
and functions, validate required inputs, and prevent user-controlled values from changing message roles or tool
permissions.
3. Server-Side Page Context Validation
Validate snapshot structure, size, allowed fields, and resource permissions. Redact sensitive data, limit
snapshots to the current interaction, and verify current resource state through live tools.
4. Session Ownership and Access Isolation
Derive tenant and user identity from server-side authentication. Enforce ownership and resource permissions
across session APIs, chat requests, history retrieval, and deletion.
5. Shared Context Security and Sensitive-Data Controls
Apply consistent trust boundaries and redaction across page context, tool results, summaries, memory, and RAG.
Treat external content as untrusted data and prevent secrets from entering persistent memory, indexes, or logs.
6. Request Idempotency and Session Lifecycle
Prevent duplicate interactions on retries, define concurrent-write behavior, and support configurable retention
and cleanup. Bound in-memory session counts, event counts, and total storage size; propagate deletion to derived
data and pending background work.
7. Token Budgets and Tool-Result Compression
Reserve output capacity and a safety margin, allocate budgets by source, and trim deterministically without
breaking tool-call/result pairs. Compress large results into structured evidence with authorized references, and
return explicit errors when mandatory content alone exceeds the budget.
8. Token Usage Attribution and Cost Accounting
Distinguish pre-call estimates from provider-reported usage and track estimated consumption by context source.
Aggregate usage across agent iterations, retries, and auxiliary model calls such as summarization; calculate
auditable costs using versioned pricing and explicitly mark unknown costs.
9. Conversation Summarization
Generate structured summaries containing goals, confirmed facts, evidence, completed actions, unresolved work,
and superseded conclusions. Track source ranges and versions, protect concurrent updates, and support continued
conversations beyond fixed turn limits with bounded fallback when summarization fails.
10. Long-Term Memory Creation and Management
Support confirmed memory facts, candidate extraction, deduplication, and replacement of outdated facts. Provide
controls to view, confirm, edit, delete, clear, expire, and disable memory, with traceable provenance and
cleanup of derived copies.
11. Long-Term Memory Retrieval and Injection
Begin with structured-key and keyword retrieval. Apply permission and scope filters before ranking, then enforce
confirmation status, validity, relevance, and token limits; historical memory must not override current
authoritative evidence.
12. Evaluation, Observability, and Controlled Rollout
Evaluate multi-turn reasoning, long conversations, memory corrections, access isolation, prompt injection,
deletion, and failure recovery. Record privacy-preserving metrics and version identifiers, provide independent
feature flags and rollback, and retire legacy paths after validation.
13. Vector Retrieval Extension
Introduce pluggable vector indexing when evaluations demonstrate a benefit. Enforce authorization during
retrieval, synchronize updates and deletion, and keep the index rebuildable from canonical memory records.
14. Authorized RAG Evidence and Genuine Reranking
Integrate RAG as a context source with collection permissions, provenance, document versions, and retrieval
scores. Implement actual reranking, enforce evidence budgets, and allow basic conversation to continue when
retrieval fails.
15. Declarative Skills and Task-Specific Assembly
Implement versioned Skill manifests, registration, and deterministic selection. Load task instructions,
examples, and permitted tools or knowledge sources within the caller’s permissions and token budget; Skills must
not override core security policy.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "Qiao-yq (via GitHub)" <gi...@apache.org>.
Qiao-yq commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-6384456151
## Proposed Core MVP Plan
After Phase 1 passes G1, the next milestone will deliver the issue’s three core capabilities: prompt templates, long-conversation summarization, and cross-session memory, through a unified Context Compiler.
| PR | Status | Scope | Acceptance |
| --- | --- | --- | --- |
| 1. Compiler and Templates ([#1610](https://github.com/apache/dubbo-admin/pull/1610)) | Completed | Unified Source contracts, versioned templates, tool-call/result records, and request budgeting | Every Act/Answer call uses the compiler; roles, tool pairs, and budgets remain valid |
| 2. Conversation Summaries ([#1611](https://github.com/apache/dubbo-admin/pull/1611)) | Completed | Structured rolling summaries, bounded recovery, and history fallback | Earlier goals survive beyond the recent window; failures and deletion do not corrupt or revive summaries |
| 3. Cross-Session Memory | Planned | Explicit user-scoped memory APIs, project/task matching, and update/delete consistency | Relevant facts carry across Sessions; isolation holds and invalidated facts are not reinjected through tracked dependencies |
| 4. User Controls and Validation | Planned | Simple memory editor, chat project/task selection, and end-to-end tests | Users can save, recall, correct, delete, clear, and disable memory through the UI |
**Status:** PRs 1 and 2 are completed; PRs 3 and 4 remain planned. Delivery follows PR 1 → 2 → 3 → 4, targeting `ai`.
All changes retain Phase 1 security and lifecycle guarantees. Automatic memory extraction, page-context integration, dynamic plugin management, and advanced retrieval are deferred.
Completion requires all three capabilities to work end to end, including failure recovery and isolation checks. This milestone delivers the core capabilities within the issue’s scope, with the remaining G2/G3 requirements to be completed in subsequent work.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "Qiao-yq (via GitHub)" <gi...@apache.org>.
Qiao-yq commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-5906442883
Thanks for the detailed breakdown. I reviewed the 15 requirements against the current `ai` branch and prepared a dependency-ordered implementation roadmap.
This proposal covers the remaining context-engineering work using project-owned interfaces. It does not introduce PowerContext.
## Current baseline
- Short-term multi-turn context windows and stable per-interaction snapshots are already implemented.
- ReAct act/final-answer prompt policies have been separated.
- The frontend page-context provider foundation exists, but backend integration needs to be reintroduced through the unified compiler after the ReAct refactor.
The following phases therefore describe the remaining work rather than a from-scratch implementation.
## Phase 1: Security and lifecycle foundation
Requirements: 4, 5, 6, plus the foundations of 8 and 12.
Main deliverables:
- server-derived subject and session ownership;
- authorization for session, history, chat, and deletion APIs;
- idempotency and a defined concurrent-turn policy;
- quotas, retention, tombstones, derived-data cleanup, and shared sanitization;
- base usage, audit, version, and feature-flag models.
Exit gate G1: cross-user isolation, concurrency, quota, deletion-propagation, and sensitive-data tests pass.
## Phase 2: Unified context compiler
Requirements: 1, 2, 3, 7, and 8.
Main deliverables:
- project-owned ContextSource, ContextItem, Compiler, and CompilationReport;
- bounded history, validated page context, and grouped tool evidence sources;
- deterministic evidence resolution and token budgeting;
- versioned prompt templates;
- ReAct consumes compiler output exclusively, initially behind a shadow flag.
Exit gate G2: the production Agent path no longer assembles model input outside the compiler, and deterministic, injection, permission, and budget tests pass.
## Phase 3: Long conversations and memory
Requirements: 9, 10, and 11.
Main deliverables:
- structured, versioned conversation summaries with CAS protection and fallback;
- manageable canonical memory with confirmation, correction, expiry, and deletion;
- deduplication and replacement semantics;
- ACL-filtered structured-key and keyword retrieval through the compiler.
Exit gate G3: long-conversation, correction, deduplication, isolation, and derived-data deletion tests pass.
## Phase 4: Advanced retrieval and skills
Requirements: 12, 13, 14, and 15.
This phase has separate approval gates:
- G4A: authorized RAG source, evidence budgets, real reranking, and degradation;
- G4B: vector retrieval only if predefined quality/latency/cost thresholds pass;
- G4C: versioned Skill manifests, deterministic selection, permission
intersection, controlled rollout, and legacy-path retirement.
Each capability will have an independent feature flag and rollback path.
## Delivery strategy
I propose submitting small, reviewable PRs for contracts/ADRs, storage and security, compiler integration, summary/memory, and advanced retrieval.
Each PR will include its tests, configuration/schema changes, observability, failure behavior, and rollback path where applicable.
Before implementation, I would like to confirm:
1. What is the authoritative identity source for the AI service, and should isolation use user, tenant, mesh, or a combination?
2. Is `ai/component/context` acceptable as the ownership boundary for the compiler and source contracts?
3. Should the approved work be tracked as child issues under #1539, with this issue remaining the umbrella tracker?
I will submit the full design and requirement-to-task mapping as a documentation PR so each phase and PR can be reviewed against explicit acceptance criteria.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "Qiao-yq (via GitHub)" <gi...@apache.org>.
Qiao-yq commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-5772194186
The current context-window problem is that, although the Agent already injects messages before each model call through ai.WithMessages, WindowMemoryForTurn returns only the current active turn. Previously completed turns are therefore excluded from the model context, effectively reducing multi-turn conversations to single-turn interactions and incorrectly relying on the Memory Tool to recover history. The fix should build one stable context snapshot at the beginning of each interaction, containing the most recent N completed turns in chronological order followed by the selected active turn, while excluding all other concurrent active turns. Subsequent tool results should be persisted to the Store and appended to the in-memory snapshot for the next ReAct model call. MemoryStore and GormStore must implement identical window semantics, with tests covering message ordering, window limits, concurrent-turn isolation, snapshot stability, and cleanup on failure. This change is limited to
restoring short-term context within one Session and does not include prompt templates, context summarization, cross-session long-term memory, or generic hooks and middleware.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "Geaus (via GitHub)" <gi...@apache.org>.
Geaus commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-5384493613
Hi! I’ve submitted my proposal and résumé through the OSPP system and would love to work on this issue. I’m happy to discuss the implementation details and refine the proposal based on the community’s feedback. Thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "larry-zy (via GitHub)" <gi...@apache.org>.
larry-zy commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-5778307014
@Qiao-yq
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [I] [OSPP] Implement Full Context Management for the Dubbo Admin Agent [dubbo-admin]
Posted by "Qiao-yq (via GitHub)" <gi...@apache.org>.
Qiao-yq commented on issue #1539:
URL: https://github.com/apache/dubbo-admin/issues/1539#issuecomment-5906375432
> The next phase of context engineering should provide an extensible, secure, and measurable pipeline for assembling model inputs. Each context source should have explicit permissions, provenance, freshness, lifecycle, and token limits. The implementation should use project-owned interfaces without integrating PowerContext. Reviewing the design document also highlights requirements that need explicit coverage: shared security controls, storage limits, evidence precedence, memory deduplication, and deletion of derived data.
>
> 1. Unified Context Compiler
> Define extensible context-source interfaces and assemble authorized sources into model inputs. Record included
> and omitted items with reasons, support bounded historical queries, and prioritize fresh tool evidence over
> historical summaries or memory.
> 2. Versioned Prompt Templates
> Support template variables, message roles, versioning, and backward compatibility. Restrict available variables
> and functions, validate required inputs, and prevent user-controlled values from changing message roles or tool
> permissions.
> 3. Server-Side Page Context Validation
> Validate snapshot structure, size, allowed fields, and resource permissions. Redact sensitive data, limit
> snapshots to the current interaction, and verify current resource state through live tools.
> 4. Session Ownership and Access Isolation
> Derive tenant and user identity from server-side authentication. Enforce ownership and resource permissions
> across session APIs, chat requests, history retrieval, and deletion.
> 5. Shared Context Security and Sensitive-Data Controls
> Apply consistent trust boundaries and redaction across page context, tool results, summaries, memory, and RAG.
> Treat external content as untrusted data and prevent secrets from entering persistent memory, indexes, or logs.
> 6. Request Idempotency and Session Lifecycle
> Prevent duplicate interactions on retries, define concurrent-write behavior, and support configurable retention
> and cleanup. Bound in-memory session counts, event counts, and total storage size; propagate deletion to derived
> data and pending background work.
> 7. Token Budgets and Tool-Result Compression
> Reserve output capacity and a safety margin, allocate budgets by source, and trim deterministically without
> breaking tool-call/result pairs. Compress large results into structured evidence with authorized references, and
> return explicit errors when mandatory content alone exceeds the budget.
> 8. Token Usage Attribution and Cost Accounting
> Distinguish pre-call estimates from provider-reported usage and track estimated consumption by context source.
> Aggregate usage across agent iterations, retries, and auxiliary model calls such as summarization; calculate
> auditable costs using versioned pricing and explicitly mark unknown costs.
> 9. Conversation Summarization
> Generate structured summaries containing goals, confirmed facts, evidence, completed actions, unresolved work,
> and superseded conclusions. Track source ranges and versions, protect concurrent updates, and support continued
> conversations beyond fixed turn limits with bounded fallback when summarization fails.
> 10. Long-Term Memory Creation and Management
> Support confirmed memory facts, candidate extraction, deduplication, and replacement of outdated facts. Provide
> controls to view, confirm, edit, delete, clear, expire, and disable memory, with traceable provenance and
> cleanup of derived copies.
> 11. Long-Term Memory Retrieval and Injection
> Begin with structured-key and keyword retrieval. Apply permission and scope filters before ranking, then enforce
> confirmation status, validity, relevance, and token limits; historical memory must not override current
> authoritative evidence.
> 12. Evaluation, Observability, and Controlled Rollout
> Evaluate multi-turn reasoning, long conversations, memory corrections, access isolation, prompt injection,
> deletion, and failure recovery. Record privacy-preserving metrics and version identifiers, provide independent
> feature flags and rollback, and retire legacy paths after validation.
> 13. Vector Retrieval Extension
> Introduce pluggable vector indexing when evaluations demonstrate a benefit. Enforce authorization during
> retrieval, synchronize updates and deletion, and keep the index rebuildable from canonical memory records.
> 14. Authorized RAG Evidence and Genuine Reranking
> Integrate RAG as a context source with collection permissions, provenance, document versions, and retrieval
> scores. Implement actual reranking, enforce evidence budgets, and allow basic conversation to continue when
> retrieval fails.
> 15. Declarative Skills and Task-Specific Assembly
> Implement versioned Skill manifests, registration, and deterministic selection. Load task instructions,
> examples, and permitted tools or knowledge sources within the caller’s permissions and token budget; Skills must
> not override core security policy.
Thanks for the detailed breakdown. I reviewed the 15 requirements against the
current `ai` branch and prepared a dependency-ordered implementation roadmap.
This proposal covers the remaining context-engineering work using project-owned
interfaces. It does not introduce PowerContext.
## Current baseline
- Short-term multi-turn context windows and stable per-interaction snapshots
are already implemented or under review.
- ReAct act/final-answer prompt policies have been separated.
- The frontend page-context provider foundation exists, but backend integration
needs to be reintroduced through the unified compiler after the ReAct refactor.
The following phases therefore describe the remaining work rather than a
from-scratch implementation.
## Phase 1: Security and lifecycle foundation
Requirements: 4, 5, 6, plus the foundations of 8 and 12.
Main deliverables:
- server-derived subject and session ownership;
- authorization for session, history, chat, and deletion APIs;
- idempotency and a defined concurrent-turn policy;
- quotas, retention, tombstones, derived-data cleanup, and shared sanitization;
- base usage, audit, version, and feature-flag models.
Exit gate G1: cross-user isolation, concurrency, quota, deletion-propagation,
and sensitive-data tests pass.
## Phase 2: Unified context compiler
Requirements: 1, 2, 3, 7, and 8.
Main deliverables:
- project-owned ContextSource, ContextItem, Compiler, and CompilationReport;
- bounded history, validated page context, and grouped tool evidence sources;
- deterministic evidence resolution and token budgeting;
- versioned prompt templates;
- ReAct consumes compiler output exclusively, initially behind a shadow flag.
Exit gate G2: the production Agent path no longer assembles model input outside
the compiler, and deterministic, injection, permission, and budget tests pass.
## Phase 3: Long conversations and memory
Requirements: 9, 10, and 11.
Main deliverables:
- structured, versioned conversation summaries with CAS protection and fallback;
- manageable canonical memory with confirmation, correction, expiry, and deletion;
- deduplication and replacement semantics;
- ACL-filtered structured-key and keyword retrieval through the compiler.
Exit gate G3: long-conversation, correction, deduplication, isolation, and
derived-data deletion tests pass.
## Phase 4: Advanced retrieval and skills
Requirements: 12, 13, 14, and 15.
This phase has separate approval gates:
- G4A: authorized RAG source, evidence budgets, real reranking, and degradation;
- G4B: vector retrieval only if predefined quality/latency/cost thresholds pass;
- G4C: versioned Skill manifests, deterministic selection, permission
intersection, controlled rollout, and legacy-path retirement.
Each capability will have an independent feature flag and rollback path.
## Delivery strategy
I propose submitting small, reviewable PRs for contracts/ADRs, storage and
security, compiler integration, summary/memory, and advanced retrieval.
Each PR will include its tests, configuration/schema changes, observability,
failure behavior, and rollback path where applicable.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org