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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to