Skip to content

Maintainer alignment: potential Agent Memory Guard provider and guarded memory-service boundary #7347

Closed as not planned

Description

@vgudur-dev

I am writing in a personal, nonconfidential capacity. I am not speaking for my employer, Google, OWASP, or any other organization. This is a scope question only; it does not claim endorsement, acceptance, support, integration, or adoption by Google or OWASP.

🔴 Required Information

Is your feature request related to a specific problem?

ADK exposes runner-level security callbacks and a separate BaseMemoryService interface. A runner plugin alone cannot truthfully claim to mediate every long-term-memory read or write. Before any implementation, I am asking maintainers to choose whether and where a narrowly memory-lifecycle-focused Agent Memory Guard (AMG) integration belongs.

Describe the Solution You'd Like

The intended scope uses documented public ADK APIs only:

  • AdkMemoryGuardPlugin(BasePlugin) would scan text or serializable payloads at user-message, assembled model-context, model-response, and tool boundaries. Non-text and multimodal values would be preserved and explicitly documented as unscanned.
  • GuardedMemoryService(BaseMemoryService) would decorate a caller-provided service: pre-scan supported ingestion operations and scan/filter/block search_memory results before recall. It would guard only operations that pass through the decorator; it would not claim backend-integrity verification, coverage of direct/out-of-band access, or universal memory protection.

The plugin is defense in depth; the optional memory-service decorator is the proposed memory-ingestion/retrieval boundary. The proposal is not a request to modify Model Armor and is not intended as a generic duplicate of existing runner guardrails. A first package would be Python-only, use public APIs, and include credential-free deterministic tests.

Impact on your work

A maintainer decision would prevent an unsupported or misleading integration and establish the correct placement and failure semantics before code is written. There is no requested release deadline.

Willingness to contribute

Conditional: if maintainers select a placement and enforcement contract, I can prepare a small design and test matrix for review before any implementation. This is not a commitment to a release or support obligation.

🟡 Recommended Information

Describe Alternatives You've Considered

Please choose the appropriate direction, if any:

  • an externally maintained provider package (for example, adk-agent-memory-guard) followed by an ADK integration-catalog/docs page;
  • google/adk-python-community;
  • ADK core; or
  • no integration / another location.

Proposed API / Implementation

Do maintainers approve or reject the two-component BasePlugin plus optional GuardedMemoryService design above? In particular, is decorating BaseMemoryService the appropriate public extension boundary for guarded ingestion and retrieval, rather than representing a runner plugin as universal memory coverage?

For an unsafe tool result before it can become later model context, which typed behavior should a first implementation use?

  • replace: return a documented typed refusal/replacement envelope to the model context;
  • error: return a documented typed tool-error/refusal result through the tool-result path; or
  • abort: raise/return a documented typed policy failure that stops the affected runner flow.

A silent text placeholder would not be used. The selected behavior would be regression-tested to ensure it cannot trigger a tool re-call loop.

If there is interest, I can prepare a small design and test matrix only after this placement and contract are clarified. If the answer is no, or the scope should be narrowed, that guidance would be equally useful.

Additional Context

Activity

  1. added
    core[Component] This issue is related to the core interface and implementation
    on Sep 30, 2026
  2. sanketpatil06 commented on Oct 6, 2026

    @sanketpatil06

    Hi @vgudur-dev , thank you for your feature request. It is currently under review, and we will let you know if we need any further information. We appreciate your understanding.

  3. added
    needs review[Status] The PR/issue is awaiting review from the maintainer
    on Oct 6, 2026
  4. self-assigned this
    on Oct 26, 2026
  5. GWeale commented on Oct 26, 2026

    @GWeale
    Collaborator

    hi @vgudur-dev, thanks for checking with us before writing the code. we're going to keep this outside adk core, and the nice thing is you don't need any internal hooks from us to build it: a BasePlugin and a wrapper around the caller's BaseMemoryService both sit on public apis, so you can publish it as its own package and propose it for https://adk.dev/integrations/ with a pull request to google/adk-docs. how you handle failures is up to you, and returning a dict from after_tool_callback will replace the tool result before the model sees it. if you find a hook you need is missing, please open a new issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

core[Component] This issue is related to the core interface and implementationneeds review[Status] The PR/issue is awaiting review from the maintainer

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions