cd /news/ai-agents/designing-directory-as-id-for-ai-dis… · home topics ai-agents article
[ARTICLE · art-119880] src=dev.to ↗ pub= topic=ai-agents verified=true sentiment=· neutral

Designing Directory-as-ID for AI-Discoverable Capabilities

A developer proposes a 'directory-as-ID' pattern for making AI-agent capabilities discoverable, using the repository's directory structure as the canonical identifier. This approach simplifies governance by attaching ACLs at directory boundaries and makes capabilities legible to AI systems through stable paths and metadata, without custom discovery code.

read1 min views2 publishedSep 3, 2026

Capability discovery is one of those problems that quietly gets solved five different ways in the same company.

For AI agents it matters even more: if you cannot reliably discover and describe your own capabilities, models will not either.

A simple, robust pattern is directory-as-ID:

Why this helps:

Natural for developers

Your repo already uses directory structure to organize concepts. Making it the capability ID means git diff

, code review, and grep remain your primary tools.

Good for governance

ACLs and approval rules can be attached at directory boundaries (e.g., payments/*

requires stronger checks than analytics/*

).

Legible to AI systems

Models (or offline indexers) can infer semantics from stable paths and read schemas/metadata without custom discovery code.

A minimal implementation looks like:

capabilities/
payments/charge/
schema.json
metadata.yaml
implementation.py

Your runtime:

capabilities/

.From there you can project the same capability into MCP tools, HTTP endpoints, CLIs, or direct imports—with governance hanging off the catalog instead of scattered across services.

If you are wrestling with “how do I let agents discover what they can safely do?”, directory-as-ID is a surprisingly powerful starting constraint.

── more in #ai-agents 4 stories · sorted by recency
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
Live at https://your-agent.zahid.host
Get free account → Pricing
from €0/mo · no card required
LIVE [news/designing-directory-…] indexed:0 read:1min 2026-09-03 ·