pi-tsien-code-mode
Code mode: the run_code tool (program-driven tool calls).
Package details
Install pi-tsien-code-mode from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:pi-tsien-code-mode- Package
pi-tsien-code-mode- Version
0.1.2- Published
- Sep 27, 2026
- Downloads
- 450/mo · 12/wk
- Author
- tsien1992
- License
- MIT
- Types
- extension
- Size
- 59.5 KB
- Dependencies
- 0 dependencies · 1 peer
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-tsien-code-mode
用一个模型生成的 TypeScript 程序编排已有工具,把中间结果留在程序里而不是上下文里,减少往返次数。
工具
run_code
事件钩子
agent_settled、before_agent_start、message_end、model_select、session_shutdown、session_start
配置
无
依赖
- 内部:无
- peer:
@earendil-works/pi-coding-agent
加载
在 settings.json 里列出包,或写进 extensions.config.json 的 loadOrder;
Pi 会直接加载本包的 TS 入口(package.json 的 pi.extensions),不需要编译。