Skip to content

RFC: Add unified tags for Artifacts and Memory entries #1466

Description

@Teingi

Problem

Teams need to classify individual PowerContext-managed resources with custom tags such as a customer, product area,
scenario, or validation status, and then retrieve current resources by exact tag membership.

Encoding classification in Artifact content would create content Revisions and rebuild search projections even though
the reusable knowledge did not change. Existing Source and managed Skill metadata fields have different authorities
and version semantics. A tag on the single Memory Artifact for a Scope also cannot distinguish individual Memory
entries.

Proposed direction

  • Treat tags as mutable, Scope-local catalog attributes rather than Artifact content or lineage.
  • Give managed Experience, Skill, Handoff, whole Memory Artifacts, and individual Memory entries one public tag-set
    model.
  • Store all assignments in one polymorphic pc_artifact_tags table.
  • Retain the owning family + artifact_id, then distinguish an Artifact target from a nested Memory-entry target.
  • Bind tags to logical identities, not Artifact Revisions or Memory entry versions.
  • Support exact all and any queries and apply tag eligibility before Memory FTS/vector top-k selection.
  • Do not copy tags across Scope publication by default and never interpret tags as authorization or Agent
    instructions.

First-delivery scope

  • Read and compare-and-swap replacement of a complete tag set.
  • Cross-family exact tag query with current exact Artifact or Memory citations.
  • Optional tag filters for current Artifact listing, Memory-entry listing, and Memory search.
  • A minimal Dashboard tag editor and filter.
  • Deterministic Unicode normalization, bounded values, pagination, authorization filtering, and secret-safe
    observability.

Non-goals

The first delivery does not include tag colors, hierarchy, aliases, a managed tag catalog, automatic model tagging,
historical tag snapshots, tag-based authorization, revision-specific tags, or arbitrary key/value Artifact metadata.

Acceptance direction

The design must preserve tags across content revisions, isolate tags between Memory entries in the same Memory,
change no content digest or lineage, reject stale concurrent replacements, keep existing unfiltered behavior backward
compatible, and produce equivalent behavior on SQLite and OceanBase/seekDB profiles.

A bilingual RFC pull request will define the complete target, persistence, API, retrieval, security, migration, and
validation contracts.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions