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

@prisma-next/extension-paradedb

v0.14.0

Published

ParadeDB full-text search extension pack for Prisma Next.

Readme

@prisma-next/extension-paradedb

ParadeDB full-text search extension pack for Prisma Next.

Overview

This extension pack registers a 'bm25' index type with the SQL family's index-type registry, so contracts can author BM25 full-text search indexes via the standard constraints.index(...) surface and the Postgres adapter emits CREATE INDEX ... USING bm25 WITH (...) DDL.

The v1 surface covers the key_field storage parameter only. Per-field tokenizer and column configuration is deferred to expression-index support.

Responsibilities

  • bm25 index registration: declares a 'bm25' entry via defineIndexTypes() carrying an arktype validator for the bm25 options shape
  • Extension descriptor: declares the paradedb/bm25 capability for contract-level feature detection
  • Pack ref export: ships a pure /pack entrypoint for TypeScript contract authoring

Dependencies

  • @prisma-next/sql-contract: index-type registry primitive
  • @prisma-next/contract / @prisma-next/contract-authoring: core contract types
  • arktype: option-shape validation

Installation

pnpm add @prisma-next/extension-paradedb

Usage

Contract definition

Author bm25 indexes via the standard constraints.index(...) surface; the registered 'bm25' entry narrows options per-type:

import { int4Column, textColumn } from '@prisma-next/adapter-postgres/column-types';
import sqlFamily from '@prisma-next/family-sql/pack';
import { defineContract, field, model } from '@prisma-next/sql-contract-ts/contract-builder';
import paradedb from '@prisma-next/extension-paradedb/pack';
import postgres from '@prisma-next/target-postgres/pack';

export const contract = defineContract({
  family: sqlFamily,
  target: postgres,
  extensionPacks: { paradedb },
  models: {
    Item: model('Item', {
      fields: {
        id: field.column(int4Column).id(),
        body: field.column(textColumn),
      },
    }).sql(({ cols, constraints }) => ({
      table: 'items',
      indexes: [
        constraints.index([cols.body], {
          name: 'item_body_bm25_idx',
          type: 'bm25',
          options: { key_field: 'id' },
        }),
      ],
    })),
  },
});

key_field

ParadeDB BM25 indexes require a key_field — a unique column that identifies each document. It is required, must be a string, and is typically (but not always) the table's primary key.

Capabilities

  • paradedb/bm25 — indicates support for BM25 full-text search indexes

Authoring (maintainers)

After changing the contract source, run pnpm migrations:regen from the repo root to keep migration metadata, refs/head.json, and end-contract.* consistent with the freshly-built src/contract.json; it is also wired into pnpm fixtures:emit automatically.

See ADR 212 — Contract spaces ("Contract-space package layout") for the layout and rationale.

Not yet implemented

  • Per-column / per-expression tokenizer configuration (deferred to expression-index support)
  • @@@ operator and pdb.* query builder functions
  • Scoring, aggregation, and highlight functions

References