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

os-dpt

v0.2.1

Published

Local web-based SQL editor with a built-in chat-to-SQL AI agent.

Downloads

48

Readme

Data Profile Tool

Data Profile Tool is a fully local, file-based SQL editor with powerful chat-to-SQL functionality, charting, and a context layer.

Features

SQL editor

Write a query against a connection and run it; results appear inline.

A SQL worksheet with a query joining order_items, products and orders

The results grid showing eight rows of product revenue, with row numbers and column headers

Chat-to-SQL agent

Ask a question in plain English. The agent reads your live schema, writes and runs SQL, and charts the answer — with every tool call shown in the transcript, so you see exactly what it did rather than trusting a black box.

The chat agent answering "which product categories bring in the most revenue?" — showing its get_context, get_schema and run_sql tool calls, then a rendered bar chart

Transparent, versioned memory

The agent's knowledge isn't hidden in a vendor database — it's git-tracked markdown in your repo. Correct it once and it writes the rule to its notes, then applies it on its own from then on:

The agent confirming it saved a rule to conventions.md via its update_context tool, so it applies the exclusion automatically in future queries

Those notes are plain markdown you read and edit in the Documentation view — Schemas, Conventions, and Feedback per data source. Every change, yours or the agent's, is a reviewable diff:

The Documentation view showing a Conventions doc for a connection, rendered from a git-tracked markdown file

Everything is a file

Worksheets are .sql and context is .md, so version history is built in — diff any two versions of a query and restore an earlier one.

The worksheet history viewer diffing two versions of a query side by side, with a "Restore this version" button

Local-first & private

The server binds to 127.0.0.1 and credentials are encrypted in your OS keychain. Nothing about your data leaves your machine except what you send to your LLM provider.

Read-only by default

Connections open read-only; you opt into writes per connection, so the agent can't change your data unless you let it.

Quick start

# In the directory you want as your workspace:
npx os-dpt

This launches a local server on 127.0.0.1 and opens the editor in your browser. On first run it creates a workspace (see below). Add a database connection (Postgres to start), then open a worksheet or the chat panel.

You'll need an Anthropic API key for the agent — set it in Settings → AI providers.

To install it globally instead:

npm install -g os-dpt
os-dpt

Options

os-dpt [options]

  --workspace <dir>   Workspace directory (default: current directory)
  --port <n>          Preferred port (default: 3756, falls back if taken)
  --no-open           Don't open the browser automatically
  -v, --version       Print version
  -h, --help          Show this help

Workspace layout

os-dpt treats your current directory as the workspace root (like git or npm):

<workspace>/
├── .os-dpt/          # gitignored — encrypted credentials, cache, drafts
├── worksheets/       # git-tracked .sql files, one per worksheet
├── context/          # git-tracked agent memory (markdown), scoped per source
├── connections.json  # connection metadata (no secrets)
└── .gitignore        # excludes .os-dpt/

Anything sensitive lives in .os-dpt/ and is gitignored. Anything worth versioning — your queries and the agent's context — is plain text at the root.

If the directory isn't already a git repository, os-dpt runs git init so worksheet/context history works out of the box.

How the agent works

Under the hood, the agent runs a small, focused tool loop (see server/agent/):

  • get_schema — introspect live tables/columns.
  • get_context / update_context — read and write the markdown knowledge files.
  • run_sql — execute SQL (read-only by default; see Security).
  • write_sql — stage SQL into a worksheet for you to review and save.
  • render_chart — draw a chart inline from query results.
  • ask_user_question — pause and ask rather than guess.

Because worksheets and context are just files, the collaboration is durable: the agent rewrites a worksheet in place as you iterate, git keeps the full history of both your queries and the agent's notes, and the in-app history viewer is a thin wrapper over git log / git diff for a given file.

Security

os-dpt is a single-user, loopback-only tool with no API authentication, and the agent can run SQL against your database. Connections are read-only by default; you opt into writes per connection. For the full trust model — credential storage, the read-only guards, TLS behavior, and what gets sent to your LLM provider — read SECURITY.md before pointing it at anything important.

Develop

Requires Node and pnpm. This is a pnpm monorepo (client + server).

pnpm install
pnpm dev          # Vite + Hono in parallel
pnpm typecheck    # gate changes with this

Run the app against a throwaway workspace so you never materialize personal data in the repo:

os-dpt --workspace ./dev-workspace

See CONTRIBUTING.md for design principles and how to add a database driver.

License

MIT © Paul Demick