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

@nicolasakf/agentize

v0.2.0

Published

First-party semantic search and discovery for websites

Readme

Agentize

Make your website legible to AI agents.

Agentize builds a semantic index of the content you choose and serves it from your own domain under /agents/*. An agent asks a question in natural language and receives your Markdown, with canonical URLs attached, instead of crawling and parsing your HTML.

Install this package in the website owner's repository, declare the content sources, and serve an authoritative agent interface from the owner's domain. Protocol 0.2 supports public websites and shared-access intranets.

curl https://example.com/agents/search \
  -H 'content-type: application/json' \
  -d '{"query":"Can employees use a company identity provider?","limit":5}'

The response names each matching resource, its canonical URL, type, and last update, along with the passages that matched. A follow-up request to GET /agents/resources/:id returns the full page as normalized Markdown.

Agentize is not a web crawler. It does not accept arbitrary website URLs, and it does not send your content or an agent's queries to a hosted AI provider. Embeddings are computed locally at build time.

Quick start

Requires Node.js 22 or newer.

npm install @nicolasakf/agentize
npx agentize init

Declare your content sources in the generated agentize.config.ts:

import { defineConfig, markdown } from "@nicolasakf/agentize";

export default defineConfig({
  site: {
    name: "Example",
    origin: "https://example.com",
    description: "Example's authoritative agent interface",
  },
  sources: [
    markdown({ root: "content", include: ["**/*.{md,mdx}"] }),
  ],
});

Then validate, build, and serve the index:

npx agentize check
npx agentize build
npx agentize serve
curl http://127.0.0.1:4242/agents

Endpoints

  • GET /agents discovers the site and its agent endpoints.
  • GET /agents/index lists semantic collections and paginated standalone resources.
  • POST /agents/search performs semantic-first retrieval, with optional filters on type, collection, tag, and language.
  • GET /agents/resources/:id returns JSON, or Markdown with Accept: text/markdown.

Commands

  • agentize init creates configuration and framework integration files.
  • agentize build produces an atomic .agentize/output/ bundle.
  • agentize dev watches source files, rebuilds incrementally, and serves on port 4242.
  • agentize serve serves a previously generated bundle.
  • agentize check validates resources, privacy exclusions, relationships, and Next.js route coverage.

Next.js

agentize init creates an App Router catch-all route under app/agents/[[...path]]/route.ts. Wrap your Next config with withAgentize from @nicolasakf/agentize/next, and run agentize build before next build.

Protected intranets

Set access: { mode: "protected" } for one shared employee corpus. Protect every /agents/* request with the host's middleware by passing authorizeRequest to createAgentizeRouteHandlers, or run a sidecar behind an authenticated reverse proxy with agentize serve --trust-upstream-protection.

Protected bundles refuse to start without one of those safeguards. Every admitted caller can search and retrieve every indexed resource, so exclude documents with narrower permissions. Protected Markdown and static HTML sources may set includeNoindex: true when their pages use noindex only to block public search engines.

Documentation

Configuration reference, database-backed resources, the v0.2 protocol specification, and deployment notes: github.com/nicolasakf/agentize

Licensed under the MIT License.