omp packages

pi-model-sysprompt-appendix0.1.2

Add model-specific content to Pi system prompt as a model_context section

w-winter Published 10 days ago MIT ~256 downloads/mo

Untested on omp

This is a pi package. No one has reported whether it works on omp yet. If you try it, add your result below.

Did it work for you?

Result

One report per person. A new report replaces your old one.

Reports 0

No reports yet.

Readme

Model system-prompt appendix for Pi (pi-model-sysprompt-appendix)

Adds a per-model "appendix" to Pi's system prompt as a <model_context> section.

Useful for model-specific calibration (e.g. adding model-targeted rules or identity steering).

Install

From npm:

pi install npm:pi-model-sysprompt-appendix

From the dot314 git bundle (filtered install):

Add to ~/.pi/agent/settings.json (or replace an existing unfiltered git:github.com/w-winter/dot314 entry):

{
  "packages": [
    {
      "source": "git:github.com/w-winter/dot314",
      "extensions": ["extensions/model-sysprompt-appendix/index.ts"],
      "skills": [],
      "themes": [],
      "prompts": []
    }
  ]
}

Configuration

Edit ~/.pi/agent/extensions/model-sysprompt-appendix/model-sysprompt-appendix.json.

Fields

Field Type Description
includeModelLine boolean (optional) If true and the current model has an exact match, adds an Active model: provider/id line before the appendix content. Default: false.
default string (optional) Appendix text for models not listed in exact. Ignored if an exact match exists for the current model.
exact object (optional) Map of provider/model-id keys to model-specific appendix text. Takes priority over default.

Example

{
  "includeModelLine": true,
  "default": "Always use `trash` instead of `rm` for deletions.",
  "exact": {
    "anthropic/claude-opus-4-5": "You are Opus 4.5.",
    "anthropic/claude-sonnet-4-0": "You are Sonnet 4.0."
  }
}
How this works

With the config above:

  • Opus 4.5 (anthropic/claude-opus-4-5) gets:

    # Model Context
    Active model: anthropic/claude-opus-4-5
    You are Opus 4.5.
    
  • Sonnet 4.0 (anthropic/claude-sonnet-4-0) gets:

    # Model Context
    Active model: anthropic/claude-sonnet-4-0
    You are Sonnet 4.0.
    
  • Any other model gets:

    # Model Context
    Always use `trash` instead of `rm` for deletions.
    

Important: default is only used when there's no exact match. If you want a model to have both specific content AND the default content, include the default text in the exact match value itself.

Usage

  • Command: /model-sysprompt-appendix reload
  • Command: /model-sysprompt-appendix status

Changes apply on the next agent turn (the appendix is injected on before_agent_start).