Indexing

How Peam discovers, filters, and indexes content

Overview

Indexing is the build-time pipeline that turns your content into searchable artifacts. Most teams configure it via withPeam (Next.js) or the Peam CLI. The builder and indexers are managed for you.

Quick start (Next.js)

// next.config.ts
import withPeam from '@peam-ai/next';

export default withPeam({
  exclude: ['/admin/**', '/private/**'],
  robotsTxt: true,
})();

Quick start (CLI)

peam \
	--source fileBased --projectDir . --sourceDir .next \
	--exclude /admin/** \
	--store fileBased --indexPath .peam/index.json

How indexing runs

At build time, Peam discovers pages via index sources, applies filters, then uses the indexing pipeline to produce artifacts that are exported to your configured store.

Continue with