npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@a16njs/plugin-agentsmd

v1.0.4

Published

AGENTS.md plugin for a16n

Readme

@a16njs/plugin-agentsmd

npm version codecov

AGENTS.md plugin for a16n. Discovers and emits AGENTS.md files at any directory depth.

Stability

Stable since 1.0.0: the plugin's discover/emit behavior follows semantic versioning, and breaking changes to the public API bump the major version.

Installation

This plugin is bundled with the a16n CLI. For programmatic use:

npm install @a16njs/plugin-agentsmd

Supported Types

| Type | AGENTS.md Format | Description | |------|------------------|-------------| | GlobalPrompt | root AGENTS.md | Always-active instructions | | FileRule | <dir>/AGENTS.md | Directory-scoped instructions (directory-shaped globs only) |

AGENTS.md is plain markdown with no frontmatter, globs, skills, commands, or ignore rules, so converting into AGENTS.md is lossy for everything else:

  • FileRules whose globs are not directory-shaped (e.g. *.ts) are skipped with a warning
  • Skills, manual prompts, and agent-ignore rules are reported as unsupported

Converting out of AGENTS.md is lossless.

Supported Files

Discovery

  • AGENTS.md — root instructions (GlobalPrompt)
  • <dir>/AGENTS.md — nested instructions at any depth (FileRule with globs: ['<dir>/**'])

Per the AGENTS.md standard, a nested AGENTS.md provides instructions scoped to its subtree. a16n encodes that scoping as a directory-shaped glob so it converts into native path-scoped rules:

  • Cursor: .cursor/rules/<dir>/AGENTSMD.mdc with globs: <dir>/**
  • Claude Code: .claude/rules/<dir>/AGENTSMD.md with paths: frontmatter

Discovery skips dot-directories and node_modules.

Emission

  • GlobalPrompt → root AGENTS.md (multiple prompts are concatenated, with a merged warning)
  • GlobalPrompt discovered from a nested CLAUDE.md<same-dir>/AGENTS.md
  • FileRule with a single directory-shaped glob (<dir>/** or <dir>/**/*) → <dir>/AGENTS.md
  • Everything else → warning or unsupported (see above)

Emission deterministically overwrites target files (output depends only on the converted items, so repeated conversions converge). Replacing a pre-existing AGENTS.md whose content differs produces an overwritten warning.

When converting AGENTS.md into Cursor/Claude rules, a16n emits AGENTSMD.* rule filenames. See the plugin docs for rationale and collision behavior details: https://texarkanine.github.io/a16n/plugin-agentsmd.

Usage

import agentsmdPlugin from '@a16njs/plugin-agentsmd';
import { A16nEngine } from '@a16njs/engine';

const engine = new A16nEngine([agentsmdPlugin]);

// Discover AGENTS.md files
const result = await agentsmdPlugin.discover('./my-project');
console.log(`Found ${result.items.length} items`);

// Emit to AGENTS.md format
await agentsmdPlugin.emit(result.items, './my-project');

Documentation

Full documentation available at https://texarkanine.github.io/a16n/plugin-agentsmd.