Skip to content

[FEATURE] Feature request: consumer-side arbitrary source mappings #1535

Description

Feature request: consumer-side arbitrary source mappings

At a glance

  • Problem: APM can only install content when the repo or subpath already looks like a recognized package shape.
  • Why it matters: many useful internal repos already contain agent guidance, but were never authored as APM packages.
  • Example syntax:
dependencies:
  apm:
    - git: git@github.example.com:platform/engineering-guidance.git
      ref: main
      mappings:
        - from: docs/agents/**/*.instructions.md
          to: .github/instructions/
        - from: skills/review/**
          to: .agents/skills/review/

Is your feature request related to a problem? Please describe.
Yes. Teams often know exactly which files they want from an existing repo, but APM rejects the source unless the selected repo or subpath already looks like .apm/, SKILL.md, or plugin.json.

That blocks a very common adoption path:

  • the source repo has useful agent docs or skill folders
  • the consumer knows what to pull
  • but the source repo has no APM metadata and no package boundary at the repo root

Describe the solution you'd like
Allow the consumer to declare file mappings for arbitrary repo layouts.

The key pieces would be:

  • repo URL
  • ref rules
  • optional sparse checkout hints
  • one or more from -> to mappings into APM-managed outputs

Example syntax:

dependencies:
  apm:
    - git: git@github.example.com:platform/engineering-guidance.git
      ref: v1.2.3
      mappings:
        - from: docs/agents/**/*.instructions.md
          to: .github/instructions/
        - from: skills/android-upgrade/**
          to: .agents/skills/android-upgrade/

This should work for both remote git dependencies and local paths, including repo-root-plus-subdirectory installs.

Describe alternatives you've considered

  • Reshape the source repo into an APM package
  • Point directly at a pre-existing SKILL.md folder
  • Create a separate APM-only wrapper repo

Those options work sometimes, but they add migration cost, duplicate content, or depend on the source repo already being laid out the "right" way.

Additional context
This would make APM much easier to adopt in large codebases where shared guidance already exists, but nobody is going to stop and repackage every source repo before consumers can benefit from it.

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

    area/content-securityUnicode scanning, Glassworm, apm audit content checks, SARIF output.area/distributionInstallers (curl/PowerShell/Brew/Scoop), self-update, devcontainer, codespaces.status/triagedAutomated advice completed; deduplication only. Not human approval; silence is not approval.theme/securitySecure by default. Content scanning, lockfile integrity, MCP trust boundaries.type/featureNew capability, new flag, new primitive.

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions