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

pi-studio

v0.7.0

Published

Two-pane browser workspace for pi with prompt/response editing, annotations, critiques, prompt/response history, and live Markdown/LaTeX/code preview

Readme

pi-studio

Extension for pi that opens a local two-pane browser workspace for working with prompts, responses, live working details, Markdown and LaTeX documents, code files, and other common text-based files side by side. Annotate responses and files, add local comments, write, edit, and run prompts, browse prompt and response history, request critiques, and use live preview for code, Markdown, and LaTeX.

Quick demo

Watch the 2-minute demo (MP4, 2x speed, no audio)

Screenshots

Dark

Pi Studio workspace (dark)

Light

Pi Studio workspace (light)

What it does

  • Opens a two-pane browser workspace: Editor (left) + Response/Working/Editor Preview (right)
  • Supports one canonical full Studio view per Pi session, plus additional editor-only companion views when you just want extra editing/preview surfaces; the editor toolbar can open a detached copy of the current editor text as a companion view
  • Runs editor text directly, or asks for structured critique (auto/writing/code focus)
  • Includes a live Working view for following current model/tool activity, with All / Thinking / Tools filters plus Load visible into editor and Copy visible actions
  • Includes a local persistent scratchpad for quick notes you want to keep out of the main editor until you're ready to copy or insert them
  • Includes a docked Outline rail for navigating document structure in the current editor text, with clickable entries that jump in the raw editor and reveal matching preview locations when available
  • Includes local comments anchored to selections/lines, shown in a docked Comments rail, with transient Comment / Jump actions from raw-editor selections plus editor-preview selections for Markdown, LaTeX, and code/text/diff previews, alongside optional inline [an: ...] toggles when you want comments reflected in the document text
  • Browses response history (Prev/Next/Last) and loads either:
    • response text
    • critique notes/full critique
    • the prompt that generated a selected response
  • Supports an annotation workflow for [an: ...] markers:
    • inserts/removes the annotated-reply header
    • shows/hides annotation markers in preview
    • strips markers before send (optional)
    • saves .annotated.md
  • Renders Markdown/LaTeX/code previews (math + Mermaid), theme-synced with pi
  • Embeds local PDFs in Studio Markdown previews via explicit studio-pdf fenced blocks
  • Ships optional pi-studio-dark and pi-studio-light themes tuned for Studio's browser workspace
  • Exports right-pane preview as PDF (pandoc + LaTeX)
  • Exports local files headlessly via /studio-pdf <path> to <name>.studio.pdf
  • Shows model/session/context usage in the footer, plus a compact-context action

Commands

| Command | Description | |---|---| | /studio | Open with last assistant response (fallback: blank) | | /studio <path> | Open with file preloaded | | /studio --last | Force last response | | /studio --blank | Force blank editor | | /studio --status | Show studio server status | | /studio --stop | Stop studio server | | /studio --help | Show help | | /studio-replace [path\|--blank\|--last] | Replace the current full Studio view with a new full Studio view | | /studio-editor-only [path\|--blank\|--last] | Open an editor-only Studio view; multiple editor-only views may be open at once | | /studio-current <path> | Load a file into currently open Studio tab(s) without opening a new browser window | | /studio-pdf <path> [options] | Export a local file to <name>.studio.pdf via the Studio PDF pipeline, with optional layout controls |

Install

# npm
pi install npm:pi-studio

# GitHub
pi install https://github.com/omaclaren/pi-studio

Run once without installing:

pi -e https://github.com/omaclaren/pi-studio

Studio Markdown extras

Studio previews standard Markdown, code fences, display math, Mermaid, and local images. When adding companion files such as generated plots or PDFs, prefer the project's existing folder convention. If there is no convention, attachments/ is a reasonable default for newly generated assets. Use relative paths from the opened Markdown file or Studio working/resource directory, and wrap paths in angle brackets when spaces are possible:

![Short descriptive caption](<attachments/plot.png>)

Local PDFs can be embedded with an explicit Studio-only fenced block:

```studio-pdf
path: attachments/paper.pdf
title: Optional title
page: 3
height: 760
caption: Optional caption
```

path must point to a local .pdf within the current Studio resource directory. Relative paths resolve from the opened document's directory, or from Studio's working dir for non-file-backed content. page is an initial page hint for the browser PDF viewer, and height controls the embedded frame height in pixels. Use normal Markdown links for PDFs when embedding is not useful.

Notes

  • Local-only server (127.0.0.1) with tokenized Studio URLs.
  • For remote SSH sessions, keep Studio bound to localhost and use SSH local port forwarding; /studio and /studio --status print the full tokenized localhost URL. The SSH hint repeats the full URL so it is visible even if your terminal only shows the latest notification. Open that URL through the tunnel, preserving the ?token=... parameter.
  • Full Studio is a singleton per Pi session: use /studio to open it, /studio-replace to explicitly replace it, and /studio-editor-only for extra editing/preview tabs that do not take over the full Studio session view.
  • Studio is designed as a complement to terminal pi, not a replacement.
  • Installing pi-studio makes the optional pi-studio-dark and pi-studio-light themes available in pi's theme selector; it does not change your active theme.
  • Editor/code font uses a best-effort terminal-monospace match when the current terminal config exposes it; set PI_STUDIO_FONT_MONO to force a specific CSS font-family stack. Use PI_STUDIO_FONT_UI or PI_STUDIO_FONT_PROSE to override the Studio UI or rendered-preview font stacks.
  • Full preview/PDF quality depends on pandoc (and xelatex for PDF):
    • brew install pandoc
    • install TeX Live/MacTeX for PDF export
  • Mermaid diagrams in exported PDFs may also require Mermaid CLI (mmdc / @mermaid-js/mermaid-cli) when you want diagram blocks rendered as diagrams rather than left as code.

License

MIT