pi-apply-patch
OpenAI Codex apply_patch file-editing tool for GPT models on Pi
Package details
Install pi-apply-patch from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:pi-apply-patch- Package
pi-apply-patch- Version
0.1.1- Published
- Aug 18, 2026
- Downloads
- 366/mo · 22/wk
- Author
- kennyfrc
- License
- MIT
- Types
- extension
- Size
- 68.7 KB
- Dependencies
- 1 dependency · 4 peers
Pi manifest JSON
{
"extensions": [
"./src/index.ts"
]
}Security note
Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.
README
pi-apply-patch
OpenAI Codex apply_patch file-editing tool for Pi, active only for GPT-family
models, where it replaces the built-in edit and write tools.
Install
pi install npm:pi-apply-patch
Config lives in ~/.pi/agent/pi-apply-patch.json. Omit it for the default
auto mode.
{
"mode": "auto",
"gptIdPatterns": ["^gpt", "^o\\d"]
}
mode is auto (default), on, or off:
auto: enablesapply_patchand removeseditandwritefor GPT-family models; every other model keepsedit/writeand hasapply_patchhidden.on: enablesapply_patchfor every model.off: disablesapply_patchfor every model.
gptIdPatterns are regexes tested against the model id. Models whose api is
openai-codex-responses always count as GPT.
License
MIT.