← Catalog

pi-sticky-model

Pi extension that keeps your selected model and thinking level across /new, /resume, and /fork. Resets on Ctrl+C.

Extension

Install

Install with PiG

pig install npm:pi-sticky-model

Install with Pi

pi install npm:pi-sticky-model
Review before installing

Packages run code with your permissions and influence agent behavior. Catalog inclusion is not a security audit. Review the source before installing a third-party package.

Pi manifest JSON

The pi field of package.json.

{
  "extensions": [
    "./extensions"
  ]
}

README

Written by the package's publisher, shown as published in version 0.4.12 (README.md). PiG does not review it.

pi-sticky-model

Join dotfield.xyz on Discord

CI Publish npm version npm downloads License: MIT Pi package Trusted Publishing Buy Me A Coffee

Keeps your model and thinking-level selections across /new, /resume, and /fork without mixing settings between sessions. Resets on Ctrl+C — no settings.json override needed.

What this is

Pi extension. When you switch models with /model or Ctrl+P, or change the thinking level, the selection sticks across /new, /resume, and /fork for the lifetime of the Pi process. Close Pi (Ctrl+C) and everything resets to your settings.json default.

For anyone tired of their model snapping back to the settings.json default every time they start a new conversation. Each session keeps its own model; a new or forked session inherits only from its predecessor.

Features

  • Sticky model: /model selection persists across /new, /resume, /fork
  • Sticky thinking: thinking level follows the selected model across /new, /resume, /fork
  • Session-scoped: sessions keep separate model selections; Ctrl+C / process exit resets the current session
  • Zero config: install and it works — no YAML, no JSON, no setup
  • Reload-safe: /reload preserves your current model

Coexistence

This extension works alongside other model-switching extensions such as pi-weighted-model-router and pi-scheduled-router. Since all of them call pi.setModel(), the last one to fire wins. Control the priority by ordering your packages array in .pi/settings.json.

Install

Install the published npm package with Pi:

pi install npm:pi-sticky-model

Pin a specific version when you want reproducible installs:

pi install npm:pi-sticky-model@0.4.12

Install into the current project instead of your user Pi settings:

pi install npm:pi-sticky-model -l

Or install from GitHub:

pi install git:github.com/eiei114/pi-sticky-model

Try it without permanently installing:

pi -e npm:pi-sticky-model

Quick start

Try this package locally:

pi -e .

Then pick a model and thinking level, then run /new — both selections stay.

Package contents

Shipped files (see package.json files and npm pack --dry-run):

PathPurpose
extensions/index.tsPi extension entrypoint — event hooks for model persistence
lib/sticky-model.tsSession-scoped process memory for sticky models
README.mdPackage overview and install guide
CHANGELOG.mdVersion history
LICENSEMIT license

Development

npm install
npm run ci

npm run ci runs typecheck, tests, and npm pack --dry-run via pack:check. Confirm the published tarball any time with:

npm run pack:check

Short flow:

Vault notes -> PRD -> Issues -> implement -> ci/check -> release -> save learnings

Release

This package is set up for npm Trusted Publishing, so no NPM_TOKEN is required.

npm version patch
git push --follow-tags

See docs/release.md for setup details.

Docs

Security

Pi packages can execute code with your local permissions. Review extensions before installing third-party packages.

For vulnerability reporting, see SECURITY.md.

License

MIT