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

@xynogen/pix-pretty

v1.6.1

Published

Enhanced tool output rendering with syntax highlighting, file icons, tree views, FFF search, and paste chip formatting

Downloads

1,570

Readme

pix-pretty

Complete rendering and formatting solution for Pi Coding Agent with syntax highlighting, file icons, tree views, FFF search, paste chip formatting, and reasoning tag cleanup.

Features

Tool Output Rendering

  • Syntax highlighting - Uses cli-highlight (highlight.js-backed) for code blocks
  • File icons - Visual file type indicators in ls/find output
  • Tree views - Hierarchical directory display
  • FFF search - Fast full-text search integration with @ff-labs/fff-node
  • Diff rendering - Enhanced git diff and edit/write tool output
  • Image metadata - Display image dimensions and format info
  • Bash exit summary - Command status and timing info

Paste Chip Formatting

  • Image path collapsing - Converts /tmp/pi-clipboard-abc.png[paste image #1]
  • Text paste markers - Long pasted text → [paste text +42 lines]
  • Atomic deletion - Delete entire paste markers as single units
  • Type-aware labels - Visual distinction between image and text pastes

Reasoning Tag Rendering

  • Live streaming - Splits <think>/<thinking> regions into native Pi thinking content blocks token-by-token during streaming
  • Finalized cleanup - On message_end, re-splits every affected text block for persistence (the finalized message bypasses the live rebuild)
  • Partial-tag safety - Strips trailing half-streamed tags (e.g. <thin) so they never flash as literal text
  • Visual distinction - Uses Pi's native thinking block rendering (dim + italic via thinkingText theme token) — no ANSI injection, no markdown blockquote shim

Installation

pi install npm:@xynogen/pix-pretty

Configuration

Environment Variables

Tool rendering:

  • PRETTY_THEME - Color theme for syntax highlighting
  • PRETTY_MAX_HL_CHARS - Max characters to highlight (default: 80000)
  • PRETTY_MAX_PREVIEW_LINES - Max lines in preview output
  • PRETTY_CACHE_LIMIT - FFF cache size limit
  • PRETTY_ICONS - Enable/disable file icons
  • PRETTY_DISABLE_TOOLS - Comma-separated list of tools to skip rendering
  • PRETTY_IMAGE_PROTOCOL - Protocol for image display (tmux passthrough)
  • PRETTY_FFF_DIR - Override FFF state dir (default: ~/.cache/pi/fff)

Architecture

This package combines two rendering systems:

  1. Theme + FFF commands (src/index.ts) - Initialises syntax-highlight theme from Pi settings, clears highlight cache, and registers FFF slash commands. Tool renderers live in the standalone pix-{read,bash,ls,find,grep,edit,write} packages — each self-registers via its own Pi extension entry point.
  2. Paste chip formatting (src/paste-chips.ts) - Custom editor component for paste markers.
  3. Reasoning tag rendering (src/thinking.ts) - Converts leaked <think>/<thinking> tags into native Pi thinking content blocks (dim + italic via thinkingText theme token).

Both work independently but complement each other for a cohesive visual experience.

Origin

Tool rendering replaced npm:@heyhuynhgiabuu/pi-pretty (which was previously replaced by npm:@heyhuynhgiabuu/pi-diff). This package is a clean reimplementation — no code was copied directly. Developed independently; changes are not submitted back and upstream changes are not pulled in.

Key divergences from upstream:

  1. Highlight engine: shiki → cli-highlight - Simpler, no WASM, synchronous
  2. FFF state dir - ~/.pi/agent/pi-pretty/fff~/.cache/pi/fff (XDG cache)
  3. Split diff view for edit/write tools - Full side-by-side diff with gutter, line numbers, syntax highlighting
  4. Paste chip formatting - Custom editor component for Pi's paste marker system (not in upstream)
  5. Reasoning tag rendering - Converts leaked <think>/<thinking> tags into native Pi thinking content blocks (not in upstream)

Paste chip formatting and reasoning tag rendering are original additions with no upstream equivalent.

Full distro

To install the complete pix suite (all packages + Pi itself):

curl -fsSL https://raw.githubusercontent.com/xynogen/pix-mono/main/scripts/install.sh | sh

License

MIT