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 🙏

© 2024 – Pkg Stats / Ryan Hefner

empiricalrun

v0.14.0

Published

[![npm](https://img.shields.io/npm/v/empiricalrun)](https://npmjs.com/package/empiricalrun) [![Discord](https://img.shields.io/badge/discord-empirical.run-blue?logo=discord&logoColor=white&color=5d68e8)](https://discord.gg/NeR6jj8dw9)

Downloads

11

Readme

Empirical CLI

npm Discord

Empirical is the fastest way to test different LLMs, prompts and other model configurations, across all the scenarios that matter for your application.

With Empirical, you can:

  • Run your test datasets locally against off-the-shelf models
  • Test your own custom models and RAG applications (see how-to)
  • Reports to view, compare, analyze outputs on a web UI
  • Score your outputs with scoring functions
  • Run tests on CI/CD

Watch demo video | See all docs

Usage

See quick start on docs →

Empirical bundles together a CLI and a web app. The CLI handles running tests and the web app visualizes results.

Everything runs locally, with a JSON configuration file, empiricalrc.json.

Required: Node.js 20+ needs to be installed on your system.

Start with a basic example

In this example, we will ask an LLM to parse user messages to extract entities and give us a structured JSON output. For example, "I'm Alice from Maryland" will become "{name: 'Alice', location: 'Maryland'}".

Our test will succeed if the model outputs valid JSON.

  1. Use the CLI to create a sample configuration file called empiricalrc.json.

    npx empiricalrun init
    cat empiricalrc.json
  2. Run the test samples against the models with the run command. This step requires the OPENAI_API_KEY environment variable to authenticate with OpenAI. This execution will cost $0.0026, based on the selected models.

    npx empiricalrun
  3. Use the ui command to open the reporter web app and see side-by-side results.

    npx empiricalrun ui

Make it yours

Edit the empiricalrc.json file to make Empirical work for your use-case.