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-copilot-queue

v0.2.0

Published

Pi extension that queues ask_user responses for Copilot-style workflows

Downloads

348

Readme

Copilot Queue (Pi Extension)

Queue user feedback ahead of time and let the model consume it via an ask_user tool.

This extension is inspired by TaskSync-style workflows: you preload responses, then the github-copilot provider can pull them during long runs.

What it does

  • Registers tool: ask_user
  • Registers command: /copilot-queue
  • Keeps a FIFO queue of responses
  • Supports autopilot prompt cycling (1→2→3→1…)
  • Activates queue/autopilot only on provider github-copilot
  • Injects Copilot-only ask_user loop policy into the system prompt on each new run
  • While github-copilot is actively running, normal interactive input is captured into queue by default (instead of triggering a new turn)
  • Interactive capture can be toggled with /copilot-queue capture on|off (on by default)
  • Tracks session elapsed time and tool-call count in status line
  • Emits session hygiene warnings at configurable thresholds (default: 120 minutes, 50 tool calls)
  • Persists state in session entries
  • Shows queue/autopilot/session state in Pi status line

When ask_user is called:

  1. If queue has items → returns next queued response
  2. Else if autopilot is enabled and has prompts → returns next autopilot prompt (cycling)
  3. Else in interactive UI (github-copilot provider) → waits for /copilot-queue add <message> or /copilot-queue done (optionally with timeout)
  4. Else → returns fallback response (continue by default)

When current model provider is not github-copilot, queue/autopilot is bypassed and ask_user uses manual/fallback behavior only.

Install

Option 1: Direct with Pi (npm or git)

Install from npm:

pi install npm:pi-copilot-queue

Install from git:

pi install git:github.com/ayagmar/pi-copilot-queue

Pinned to a specific release tag:

pi install git:github.com/ayagmar/[email protected]

Project-local install (writes to .pi/settings.json):

pi install -l git:github.com/ayagmar/pi-copilot-queue

Install from local path:

pi install /absolute/path/to/pi-copilot-queue

Then reload in Pi:

/reload

Option 2: With pi-extmgr (/extensions)

Install extmgr once:

pi install npm:pi-extmgr

Then in Pi (GitHub source):

/extensions install git:github.com/ayagmar/pi-copilot-queue
/reload

Or install the extension file directly from GitHub (index.ts/entrypoint path):

/extensions install https://github.com/ayagmar/pi-copilot-queue/blob/master/src/index.ts
/reload

You can also install a local extension file directly:

/extensions install /absolute/path/to/pi-copilot-queue/src/index.ts
/reload

Usage

Queue messages

/copilot-queue add continue with the refactor
/copilot-queue add now add tests for edge cases
/copilot-queue list
/copilot-queue clear
/copilot-queue done

Done / stop waiting

/copilot-queue done

This clears the queue, disables autopilot, and releases a waiting ask_user call with done.

Interactive capture while busy (github-copilot only)

/copilot-queue capture on
/copilot-queue capture off
  • on (default): while a run is active, interactive input is queued for ask_user.
  • off: keep normal steering behavior (input is not auto-queued).

Wait timeout (for empty queue in UI mode)

/copilot-queue wait-timeout 0
/copilot-queue wait-timeout 60
  • 0 disables timeout (default): wait indefinitely.
  • >0 makes waiting ask_user return fallback after <seconds>.

Session counters and hygiene warnings

/copilot-queue session status
/copilot-queue session reset
/copilot-queue session threshold 120 50
  • Status line always includes elapsed time + tool-call count.
  • Warnings are advisory only (no forced stop).
  • Default thresholds are 120 minutes and 50 tool calls.

Fallback message

/copilot-queue fallback continue

Autopilot (cycling prompts)

/copilot-queue autopilot add continue with implementation
/copilot-queue autopilot add now write tests
/copilot-queue autopilot on
/copilot-queue autopilot list
/copilot-queue autopilot off
/copilot-queue autopilot clear

Recommended instruction snippet for your model

When provider is github-copilot, use the ask_user tool whenever feedback is required. Keep calling ask_user for iterative feedback unless the user explicitly says to stop.

Development

pnpm install
pnpm run check

Quick run:

pi -e ./src/index.ts