@wenaixi/dsh-ponytail 4.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +32 -0
- package/CHANGELOG.md +26 -0
- package/LICENSE +21 -0
- package/README.en.md +100 -0
- package/README.md +139 -0
- package/assets/benchmark-3model.svg +21 -0
- package/assets/benchmark-agentic.svg +62 -0
- package/assets/logo-dark.png +0 -0
- package/assets/logo-dark.svg +115 -0
- package/assets/logo-greenpt-dark.svg +27 -0
- package/assets/logo-greenpt.svg +27 -0
- package/assets/logo.png +0 -0
- package/assets/social-preview.png +0 -0
- package/assets/waitlist-banner-es.png +0 -0
- package/assets/waitlist-banner-ko.png +0 -0
- package/assets/waitlist-banner.png +0 -0
- package/cordis.patch.yml +3 -0
- package/lib/ponytail-config.d.ts +28 -0
- package/lib/ponytail-config.d.ts.map +1 -0
- package/lib/ponytail-config.js +125 -0
- package/lib/ponytail-config.js.map +1 -0
- package/lib/ponytail-instructions.d.ts +5 -0
- package/lib/ponytail-instructions.d.ts.map +1 -0
- package/lib/ponytail-instructions.js +81 -0
- package/lib/ponytail-instructions.js.map +1 -0
- package/lib/ponytail-runtime.d.ts +16 -0
- package/lib/ponytail-runtime.d.ts.map +1 -0
- package/lib/ponytail-runtime.js +63 -0
- package/lib/ponytail-runtime.js.map +1 -0
- package/lib/ponytail.d.ts +74 -0
- package/lib/ponytail.d.ts.map +1 -0
- package/lib/ponytail.js +553 -0
- package/lib/ponytail.js.map +1 -0
- package/package.json +77 -0
- package/skills/ponytail/SKILL.md +77 -0
- package/skills/ponytail-audit/SKILL.md +31 -0
- package/skills/ponytail-debt/SKILL.md +31 -0
- package/skills/ponytail-gain/SKILL.md +37 -0
- package/skills/ponytail-help/SKILL.md +65 -0
- package/skills/ponytail-review/SKILL.md +45 -0
package/AGENTS.md
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# Ponytail, lazy senior dev mode
|
|
2
|
+
|
|
3
|
+
You are a lazy senior developer. Lazy means efficient, not careless. The best code is the code never written.
|
|
4
|
+
|
|
5
|
+
Before writing any code, stop at the first rung that holds:
|
|
6
|
+
|
|
7
|
+
1. Does this need to be built at all? (YAGNI)
|
|
8
|
+
2. Does it already exist in this codebase? Reuse the helper, util, or pattern that's already here, don't re-write it.
|
|
9
|
+
3. Does the standard library already do this? Use it.
|
|
10
|
+
4. Does a native platform feature cover it? Use it.
|
|
11
|
+
5. Does an already-installed dependency solve it? Use it.
|
|
12
|
+
6. Can this be one line? Make it one line.
|
|
13
|
+
7. Only then: write the minimum code that works.
|
|
14
|
+
|
|
15
|
+
The ladder runs after you understand the problem, not instead of it: read the task and the code it touches, trace the real flow end to end, then climb.
|
|
16
|
+
|
|
17
|
+
Bug fix = root cause, not symptom: a report names a symptom. Grep every caller of the function you touch and fix the shared function once — one guard there is a smaller diff than one per caller, and patching only the path the ticket names leaves a sibling caller still broken.
|
|
18
|
+
|
|
19
|
+
Rules:
|
|
20
|
+
|
|
21
|
+
- No abstractions that weren't explicitly requested.
|
|
22
|
+
- No new dependency if it can be avoided.
|
|
23
|
+
- No boilerplate nobody asked for.
|
|
24
|
+
- Deletion over addition. Boring over clever. Fewest files possible.
|
|
25
|
+
- Shortest working diff wins, but only once you understand the problem. The smallest change in the wrong place isn't lazy, it's a second bug.
|
|
26
|
+
- Question complex requests: "Do you actually need X, or does Y cover it?"
|
|
27
|
+
- Pick the edge-case-correct option when two stdlib approaches are the same size, lazy means less code, not the flimsier algorithm.
|
|
28
|
+
- Mark deliberate simplifications that cut a real corner with a known ceiling (global lock, O(n²) scan, naive heuristic) with a `ponytail:` comment naming the ceiling and upgrade path.
|
|
29
|
+
|
|
30
|
+
Not lazy about: understanding the problem (read it fully and trace the real flow before picking a rung, a small diff you don't understand is just laziness dressed up as efficiency), input validation at trust boundaries, error handling that prevents data loss, security, accessibility, the calibration real hardware needs (the platform is never the spec ideal, a clock drifts, a sensor reads off), anything explicitly requested. Lazy code without its check is unfinished: non-trivial logic leaves ONE runnable check behind, the smallest thing that fails if the logic breaks (an assert-based demo/self-check or one small test file; no frameworks, no fixtures). Trivial one-liners need no test.
|
|
31
|
+
|
|
32
|
+
(Yes, this file also applies to agents working on the ponytail repo itself. Especially to them.)
|
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
所有重要变更记录于此,格式基于 [Keep a Changelog](https://keepachangelog.com/zh-CN/1.0.0/),版本号与上游 [DietrichGebert/ponytail](https://github.com/DietrichGebert/ponytail) 同步。
|
|
4
|
+
|
|
5
|
+
## [4.9.0] - 2026-08-21
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
- 完整移植上游 v4.9.0:6 个 Skill(`ponytail` / `ponytail-review` / `ponytail-audit` / `ponytail-debt` / `ponytail-gain` / `ponytail-help`)
|
|
9
|
+
- Always-on 梯子注入(`systemPrompt` section, `order: 50`),随 `lite/full/ultra/off/review` 动态裁剪
|
|
10
|
+
- 复刻 hooks 行为:`activate` / `mode-tracker` / `subagent` / `config` / `instructions` / `runtime`
|
|
11
|
+
- `PONYTAIL_DEFAULT_MODE` env > cordis 配置 > 配置文件 > `full` 三级回退,`review` 不可作默认,BOM 处理、`isShellSafe`、`isDeactivationCommand` 全量对齐
|
|
12
|
+
- 中文化:6 个 Skill 的 `description` 与正文、fallback 指令、hook 日志、systemPrompt 注入文本全部中文,触发词兼容中英文
|
|
13
|
+
- `CLAUDE.md` 核心记忆库、`LICENSE`(MIT)、`README.md`/`README.en.md`、`CHANGELOG.md`、`assets/`、`AGENTS.md`
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
- DSH 形态:单一插件包 `dsh-ponytail`,`dsh.bundle.patch = ./cordis.patch.yml`,包名引用挂载
|
|
17
|
+
- 注入文本中文化:`PONYTAIL 已激活 — 等级:…`,`hook` 日志全中文
|
|
18
|
+
|
|
19
|
+
### Fixed
|
|
20
|
+
- `initialMode` 优先级修正为 `env > cordis 显式 config > 文件 > full`,与上游语义一致
|
|
21
|
+
|
|
22
|
+
### Notes
|
|
23
|
+
- 无空 tool(不在 `ctx.tools` 注册任何占位),`scripts/verify.mjs` 校验
|
|
24
|
+
- 构建:`pnpm build` (`tsc -p tsconfig.build.json`),`pnpm typecheck`,`pnpm verify`
|
|
25
|
+
|
|
26
|
+
[4.9.0]: https://github.com/Wenaixi/dsh-ponytail/releases/tag/v4.9.0
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 DietrichGebert
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.en.md
ADDED
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
# dsh-ponytail
|
|
2
|
+
|
|
3
|
+
<p align="center">
|
|
4
|
+
<img src="assets/logo.png" width="180" alt="Ponytail" />
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
<strong>The Lazy Senior �?ported to DeepSeek Harness</strong><br/>
|
|
9
|
+
<em>The best code is the code you never wrote.</em>
|
|
10
|
+
</p>
|
|
11
|
+
|
|
12
|
+
<p align="center">
|
|
13
|
+
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-111111?style=flat-square" alt="MIT"/></a>
|
|
14
|
+
<img src="https://img.shields.io/badge/version-4.9.0-111111?style=flat-square" alt="version"/>
|
|
15
|
+
<img src="https://img.shields.io/badge/DSH-0.1.1--rc.2-333333?style=flat-square" alt="DSH"/>
|
|
16
|
+
<img src="https://img.shields.io/badge/skills-6-008080?style=flat-square" alt="skills"/>
|
|
17
|
+
<img src="https://img.shields.io/badge/node-%3E%3D18-3C873A?style=flat-square" alt="node"/>
|
|
18
|
+
</p>
|
|
19
|
+
|
|
20
|
+
<p align="center">
|
|
21
|
+
<a href="README.md">中文</a> · English · <a href="CHANGELOG.md">Changelog</a> · <a href="https://github.com/DietrichGebert/ponytail">Upstream</a>
|
|
22
|
+
</p>
|
|
23
|
+
|
|
24
|
+
---
|
|
25
|
+
|
|
26
|
+
> A complete DSH port of [DietrichGebert/ponytail](https://github.com/DietrichGebert/ponytail) v4.9.0.
|
|
27
|
+
> Brings the "lazy senior dev" into DeepSeek Harness: always-on ladder injection + 6 localized skills, no empty tools.
|
|
28
|
+
|
|
29
|
+
## �?Features
|
|
30
|
+
|
|
31
|
+
- **Always-on ladder**: 7-rung decision (YAGNI �?reuse �?stdlib �?platform native �?installed dep �?one-liner �?minimal), auto-injected before every model request, silent when `off`.
|
|
32
|
+
- **6 localized skills**: `ponytail` / `ponytail-review` / `ponytail-audit` / `ponytail-debt` / `ponytail-gain` / `ponytail-help`, `rank: 550` so project layers can override.
|
|
33
|
+
- **Three intensities**: `lite` / `full` (default) / `ultra`.
|
|
34
|
+
- **Upstream-faithful behavior**: `PONYTAIL_DEFAULT_MODE` env > cordis config > config file > `full`; `review` not allowed as default; whole-sentence deactivation; `ponytail:` debt ledger; `PONYTAIL_SUBAGENT_MATCHER` filtering.
|
|
35
|
+
- **No empty tools**: no `ctx.tools` placeholder �?everything via `ctx.skills`.
|
|
36
|
+
|
|
37
|
+
## 📦 Skills
|
|
38
|
+
|
|
39
|
+
| Skill | Type | Notes |
|
|
40
|
+
|---|---|---|
|
|
41
|
+
| `ponytail` | skill + always-on | 7-rung ladder, 3 intensities, CN/EN triggers |
|
|
42
|
+
| `ponytail-review` | skill | diff review, `delete/stdlib/native/yagni/shrink` |
|
|
43
|
+
| `ponytail-audit` | skill | repo-wide audit, same tags, ranked |
|
|
44
|
+
| `ponytail-debt` | skill | harvest `ponytail:` comments |
|
|
45
|
+
| `ponytail-gain` | skill | scoreboard (benchmark medians) |
|
|
46
|
+
| `ponytail-help` | skill | quick reference |
|
|
47
|
+
|
|
48
|
+
## 🚀 Install
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
pnpm install && pnpm build
|
|
52
|
+
dsh plugin --profile demo add ./
|
|
53
|
+
dsh --profile demo --dump-config # should show ponytail
|
|
54
|
+
dsh --profile demo
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
Or from a tarball:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
pnpm pack && dsh plugin --profile demo add ./dsh-ponytail-4.9.0.tgz
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Remove:
|
|
64
|
+
|
|
65
|
+
```bash
|
|
66
|
+
dsh plugin --profile demo remove @wenaixi/dsh-ponytail
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
## ⚙️ Configure
|
|
70
|
+
|
|
71
|
+
```yaml
|
|
72
|
+
- insert:
|
|
73
|
+
- id: ponytail
|
|
74
|
+
name: dsh-ponytail
|
|
75
|
+
config:
|
|
76
|
+
providerName: ponytail
|
|
77
|
+
skillDir: /path/to/skills
|
|
78
|
+
defaultMode: full # off|lite|full|ultra
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Priority: `PONYTAIL_DEFAULT_MODE` env > explicit cordis `defaultMode` > `~/.config/ponytail/config.json` (`%APPDATA%` on Windows, `XDG_CONFIG_HOME` wins) > `full`. `/ponytail default <mode>` persists to that file.
|
|
82
|
+
|
|
83
|
+
## 🎮 Usage
|
|
84
|
+
|
|
85
|
+
- Active by default on every coding turn. Explicit: `/ponytail [lite|full|ultra|off]`, `/ponytail default <mode>`, `/ponytail-review` etc.
|
|
86
|
+
- One-shot skills: `/ponytail-review`, `/ponytail-audit`, `/ponytail-debt`, `/ponytail-gain`, `/ponytail-help`
|
|
87
|
+
- Deactivate: `stop ponytail` / `normal mode` (whole sentence) or `/ponytail off`
|
|
88
|
+
- Subagents: `PONYTAIL_SUBAGENT_MATCHER` regex, same as upstream
|
|
89
|
+
|
|
90
|
+
## 🛠�?Dev
|
|
91
|
+
|
|
92
|
+
```bash
|
|
93
|
+
pnpm typecheck && pnpm build && node scripts/verify.mjs
|
|
94
|
+
dsh --profile web --patch ./cordis.patch.yml --dump-config
|
|
95
|
+
pnpm dsh web --patch ./cordis.patch.yml
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
## 📄 License
|
|
99
|
+
|
|
100
|
+
[MIT](LICENSE) © DietrichGebert / Wenaixi
|
package/README.md
ADDED
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
# dsh-ponytail
|
|
2
|
+
|
|
3
|
+
<p align="center">
|
|
4
|
+
<img src="assets/logo.png" width="180" alt="Ponytail" />
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
<strong>懒惰的资深工程师 · 移植�?DeepSeek Harness</strong><br/>
|
|
9
|
+
<em>The best code is the code you never wrote.</em>
|
|
10
|
+
</p>
|
|
11
|
+
|
|
12
|
+
<p align="center">
|
|
13
|
+
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-111111?style=flat-square" alt="MIT"/></a>
|
|
14
|
+
<a href="https://www.npmjs.com/package/dsh-ponytail"><img src="https://img.shields.io/npm/v/dsh-ponytail?color=111111&style=flat-square" alt="npm"/></a>
|
|
15
|
+
<img src="https://img.shields.io/badge/version-4.9.0-111111?style=flat-square" alt="version"/>
|
|
16
|
+
<img src="https://img.shields.io/badge/DSH-0.1.1--rc.2-333333?style=flat-square" alt="DSH"/>
|
|
17
|
+
<img src="https://img.shields.io/badge/skills-6-008080?style=flat-square" alt="skills"/>
|
|
18
|
+
<img src="https://img.shields.io/badge/node-%3E%3D18-3C873A?style=flat-square" alt="node"/>
|
|
19
|
+
</p>
|
|
20
|
+
|
|
21
|
+
<p align="center">
|
|
22
|
+
<a href="README.md">中文</a> · <a href="README.en.md">English</a> · <a href="CHANGELOG.md">Changelog</a> · <a href="https://github.com/DietrichGebert/ponytail">上游</a> · <a href="https://www.npmjs.com/package/dsh-ponytail">npm</a>
|
|
23
|
+
</p>
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
> [DietrichGebert/ponytail](https://github.com/DietrichGebert/ponytail) v4.9.0 �?**DSH 完整移植�?*�?> 把「懒惰的资深工程师」带�?DeepSeek Harness:always-on 梯子注入 + 6 个中�?Skill,无�?tool,开箱即用�?
|
|
28
|
+
## �?特�?
|
|
29
|
+
- **Always-on 梯子**�? 阶决策(YAGNI �?复用 �?标准�?�?平台原生 �?已有依赖 �?一�?�?最小实现),每轮模型请求前自动注入,`off` 时静默�?- **6 个中�?Skill**:`ponytail` / `ponytail-review` / `ponytail-audit` / `ponytail-debt` / `ponytail-gain` / `ponytail-help`,`rank: 550` 可被项目级覆盖�?- **三档强度**:`lite`(点出更懒的替代�?/ `full`(默认,强制走梯子) / `ultra`(先删后加,挑战需求本身)�?- **上游行为全量复刻**:`PONYTAIL_DEFAULT_MODE` env > cordis 配置 > 配置文件 > `full`;`review` 不可作默认;`stop ponytail` 全句匹配;`ponytail:` 债务台账;`PONYTAIL_SUBAGENT_MATCHER` 过滤�?- **无空 tool**:不�?`ctx.tools` 注册任何占位 tool,全部能力经 `ctx.skills` 暴露�?
|
|
30
|
+
## 📦 包含能力
|
|
31
|
+
|
|
32
|
+
| 能力 | 类型 | 说明 |
|
|
33
|
+
|---|---|---|
|
|
34
|
+
| `ponytail` | skill + always-on | 7 级梯子,lite/full/ultra 三档,触发词兼容中英�?|
|
|
35
|
+
| `ponytail-review` | skill | diff 过度设计评审,`delete/stdlib/native/yagni/shrink` |
|
|
36
|
+
| `ponytail-audit` | skill | 全仓审计,按可删收益排序 |
|
|
37
|
+
| `ponytail-debt` | skill | 收割 `ponytail:` 注释台账 |
|
|
38
|
+
| `ponytail-gain` | skill | 收益看板(benchmark 中位数) |
|
|
39
|
+
| `ponytail-help` | skill | 速查�?|
|
|
40
|
+
| 模式切换 | hook | `agent/pre-step` + `session/event` 双路径,/ponytail 族指�?|
|
|
41
|
+
| 持久�?| 文件 | `~/.config/ponytail/config.json`(Win: `%APPDATA%`),`/ponytail default <mode>` 写入 |
|
|
42
|
+
|
|
43
|
+
## 🚀 安装
|
|
44
|
+
|
|
45
|
+
### 方式一:npm(推荐,发布后可用)
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
# 作为 DSH 插件安装(自动走 dsh.bundle�?dsh plugin --profile demo add @wenaixi/dsh-ponytail
|
|
49
|
+
|
|
50
|
+
# 或作为普�?npm �?npm i @wenaixi/dsh-ponytail
|
|
51
|
+
# �?pnpm / yarn
|
|
52
|
+
pnpm add @wenaixi/dsh-ponytail
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
> 版本与上游同步,当前 `4.9.0`,`npm view dsh-ponytail version` 可查�?
|
|
56
|
+
### 方式二:GitHub 直装(无需构建,lib 已提交)
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
dsh plugin --profile demo add github:Wenaixi/dsh-ponytail
|
|
60
|
+
# 指定 tag / 分支亦可
|
|
61
|
+
dsh plugin --profile demo add github:Wenaixi/dsh-ponytail#v4.9.0
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
### 方式三:本地联调 / tarball
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
pnpm install && pnpm build
|
|
68
|
+
dsh plugin --profile demo add ./
|
|
69
|
+
dsh --profile demo --dump-config # 应能看到 ponytail �?
|
|
70
|
+
# �?pnpm pack && dsh plugin --profile demo add ./dsh-ponytail-4.9.0.tgz
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
### 卸载
|
|
74
|
+
|
|
75
|
+
```bash
|
|
76
|
+
dsh plugin --profile demo remove @wenaixi/dsh-ponytail
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
### 验证(不重启 3080�?
|
|
80
|
+
```bash
|
|
81
|
+
pnpm build && pnpm typecheck && node scripts/verify.mjs
|
|
82
|
+
dsh --profile demo --dump-config | grep -A2 ponytail # 应出�?- id: ponytail
|
|
83
|
+
# 隔离 profile 验证 GitHub 直装(不影响 web/3080�?dsh plugin --profile ponytail-test add github:Wenaixi/dsh-ponytail
|
|
84
|
+
dsh --profile ponytail-test --dump-config | grep -A2 ponytail
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
## ⚙️ 配置
|
|
88
|
+
|
|
89
|
+
�?`cordis.patch.yml` 行内覆盖�?
|
|
90
|
+
```yaml
|
|
91
|
+
- insert:
|
|
92
|
+
- id: ponytail
|
|
93
|
+
name: dsh-ponytail
|
|
94
|
+
config:
|
|
95
|
+
providerName: ponytail
|
|
96
|
+
skillDir: E:/path/to/skills # 调试用,默认包内 skills/
|
|
97
|
+
defaultMode: full # off|lite|full|ultra
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
优先级(与上游一致)�?
|
|
101
|
+
1. `PONYTAIL_DEFAULT_MODE=ultra` 环境变量(最高)
|
|
102
|
+
2. `cordis.patch.yml` 中显式的 `defaultMode`
|
|
103
|
+
3. `~/.config/ponytail/config.json`(Windows: `%APPDATA%\ponytail\config.json`,`XDG_CONFIG_HOME` 优先�?4. `full`
|
|
104
|
+
|
|
105
|
+
持久化:`/ponytail default <mode>` 会写入上述配置文件;`review` 不可作默认�?
|
|
106
|
+
## 🎮 使用
|
|
107
|
+
|
|
108
|
+
- **自动生效**:任一编码任务都会注入梯子,无需手动触发�?- **显式切换**:`/ponytail`(full)、`/ponytail lite|full|ultra|off`、`/ponytail default <mode>`、`/ponytail-review`
|
|
109
|
+
- **一键技�?*:`/ponytail-review`、`/ponytail-audit`、`/ponytail-debt`、`/ponytail-gain`、`/ponytail-help`
|
|
110
|
+
- **退�?*:`stop ponytail` �?`normal mode`(需整句匹配)或 `/ponytail off`,随时用 `/ponytail` 恢复
|
|
111
|
+
- **子智能体**:`PONYTAIL_SUBAGENT_MATCHER` 正则过滤(与上游一致),DSH 侧所�?agent 共享同一 section
|
|
112
|
+
|
|
113
|
+
## 🛠�?本地开�?
|
|
114
|
+
```bash
|
|
115
|
+
pnpm typecheck
|
|
116
|
+
pnpm build
|
|
117
|
+
pnpm verify # 6 技�?+ 产物 + 无空 tool 校验
|
|
118
|
+
dsh --profile web --patch ./cordis.patch.yml --dump-config
|
|
119
|
+
pnpm dsh web --patch ./cordis.patch.yml # 热重载:�?src/ �?skills/ 即生�?```
|
|
120
|
+
|
|
121
|
+
- `skills/` 中文化后需重跑 `build` �?`verify`(已处理 BOM �?`\r\n`�?- HMR:改 `src/*.ts` �?`skills/**/SKILL.md` 后旧 provider/section 自动清理
|
|
122
|
+
- 发布:`pnpm build && npm publish --access public --provenance`(需 npm Trusted Publisher 或带 2FA �?granular token�?
|
|
123
|
+
## 📂 目录
|
|
124
|
+
|
|
125
|
+
```
|
|
126
|
+
src/ponytail.ts # 唯一入口,name/inject/Config/apply
|
|
127
|
+
src/ponytail-config.ts # env > 文件 > full(含 BOM、review 限制、shell 白名单)
|
|
128
|
+
src/ponytail-instructions.ts # �?mode 裁剪 SKILL.md + 中文 fallback
|
|
129
|
+
src/ponytail-runtime.ts # flag 文件 + 多平台识别(Claude/Codex/Qoder�?skills/ponytail/*.md # 6 个中�?Skill
|
|
130
|
+
assets/ # logo / benchmark �?lib/ # 构建产物(已提交,支�?GitHub 直装�?cordis.patch.yml # - insert: { id: ponytail, name: dsh-ponytail }
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
## 🔗 上游
|
|
134
|
+
|
|
135
|
+
- 原仓:https://github.com/DietrichGebert/ponytail(MIT,v4.9.0�?- 本包:MIT,`skills/` �?`AGENTS.md` 原样拷贝自上游,仅为 DSH 运行时做适配
|
|
136
|
+
- 关联:`ponytail:` 债务台账、`ponytail-gain` 永不输出本仓实时节省�?
|
|
137
|
+
## 📄 许可
|
|
138
|
+
|
|
139
|
+
[MIT](LICENSE) © DietrichGebert / Wenaixi
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
<svg viewBox="0 0 860 336" xmlns="http://www.w3.org/2000/svg" font-family="-apple-system, 'Segoe UI', Helvetica, Arial, sans-serif">
|
|
2
|
+
<title>Median lines of code per arm across three models</title>
|
|
3
|
+
<text x="20" y="26" font-size="15" font-weight="600" fill="#8b949e">Median lines of code. 10 runs per cell. Lower is leaner.</text>
|
|
4
|
+
<text x="20" y="45" font-size="12" fill="#8b949e" opacity="0.85">Ponytail writes 80-94% less code, costs 42-75% less, and runs 3-6x faster than a no-skill agent.</text>
|
|
5
|
+
<rect x="20" y="58" width="12" height="12" rx="2" fill="#8b949e"/><text x="38" y="69" font-size="13" fill="#8b949e">baseline (no skill)</text>
|
|
6
|
+
<rect x="190" y="58" width="12" height="12" rx="2" fill="#d9822b"/><text x="208" y="69" font-size="13" fill="#8b949e">caveman</text>
|
|
7
|
+
<rect x="300" y="58" width="12" height="12" rx="2" fill="#2da44e"/><text x="318" y="69" font-size="13" fill="#8b949e">ponytail</text>
|
|
8
|
+
<text x="112" y="119" font-size="13" font-weight="600" fill="#8b949e" text-anchor="end">Haiku</text>
|
|
9
|
+
<rect x="120" y="92" width="508" height="14" rx="2" fill="#8b949e"/><text x="634" y="103" font-size="11" fill="#8b949e">518</text>
|
|
10
|
+
<rect x="120" y="110" width="114" height="14" rx="2" fill="#d9822b"/><text x="240" y="121" font-size="11" fill="#d9822b">116</text>
|
|
11
|
+
<rect x="120" y="128" width="38" height="14" rx="2" fill="#2da44e"/><text x="164" y="139" font-size="11" fill="#2da44e" font-weight="600">39</text>
|
|
12
|
+
<text x="112" y="193" font-size="13" font-weight="600" fill="#8b949e" text-anchor="end">Sonnet</text>
|
|
13
|
+
<rect x="120" y="166" width="680" height="14" rx="2" fill="#8b949e"/><text x="806" y="177" font-size="11" fill="#8b949e">693</text>
|
|
14
|
+
<rect x="120" y="184" width="118" height="14" rx="2" fill="#d9822b"/><text x="244" y="195" font-size="11" fill="#d9822b">120</text>
|
|
15
|
+
<rect x="120" y="202" width="43" height="14" rx="2" fill="#2da44e"/><text x="169" y="213" font-size="11" fill="#2da44e" font-weight="600">44</text>
|
|
16
|
+
<text x="112" y="267" font-size="13" font-weight="600" fill="#8b949e" text-anchor="end">Opus</text>
|
|
17
|
+
<rect x="120" y="240" width="251" height="14" rx="2" fill="#8b949e"/><text x="377" y="251" font-size="11" fill="#8b949e">256</text>
|
|
18
|
+
<rect x="120" y="258" width="66" height="14" rx="2" fill="#d9822b"/><text x="192" y="269" font-size="11" fill="#d9822b">67</text>
|
|
19
|
+
<rect x="120" y="276" width="50" height="14" rx="2" fill="#2da44e"/><text x="176" y="287" font-size="11" fill="#2da44e" font-weight="600">51</text>
|
|
20
|
+
<text x="120" y="324" font-size="11" fill="#8b949e" opacity="0.8">Median of 10 runs/cell, default temperature. 5 tasks (email, debounce, CSV sum, countdown, rate-limit), same model per group. Reproduce: npx promptfoo eval -c benchmarks/promptfooconfig.yaml</text>
|
|
21
|
+
</svg>
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
<svg viewBox="0 0 860 488" xmlns="http://www.w3.org/2000/svg" font-family="-apple-system, 'Segoe UI', Helvetica, Arial, sans-serif">
|
|
2
|
+
<title>Each arm vs the no-skill baseline across every metric, plus safety, Claude Code on Haiku 4.5</title>
|
|
3
|
+
<text x="430" y="24" font-size="15" font-weight="600" fill="#8b949e" text-anchor="middle">Every metric vs the no-skill baseline (Claude Code, Haiku 4.5, 12 tasks)</text>
|
|
4
|
+
|
|
5
|
+
<rect x="212" y="38" width="12" height="12" rx="2" fill="#8b949e"/><text x="229" y="48" font-size="12" fill="#8b949e">baseline</text>
|
|
6
|
+
<rect x="300" y="38" width="12" height="12" rx="2" fill="#d9822b"/><text x="317" y="48" font-size="12" fill="#8b949e">caveman</text>
|
|
7
|
+
<rect x="392" y="38" width="12" height="12" rx="2" fill="#2da44e"/><text x="409" y="48" font-size="12" fill="#8b949e">ponytail</text>
|
|
8
|
+
<rect x="478" y="38" width="12" height="12" rx="2" fill="#8957e5"/><text x="495" y="48" font-size="12" fill="#8b949e">yagni-oneliner</text>
|
|
9
|
+
|
|
10
|
+
<text x="32" y="248" font-size="12" fill="#8b949e" text-anchor="middle" transform="rotate(-90 32 248)">% of baseline (lower is leaner)</text>
|
|
11
|
+
<line x1="85" y1="360" x2="815" y2="360" stroke="#8b949e" stroke-opacity="0.55"/>
|
|
12
|
+
<line x1="85" y1="305" x2="815" y2="305" stroke="#8b949e" stroke-opacity="0.16"/>
|
|
13
|
+
<line x1="85" y1="250" x2="815" y2="250" stroke="#8b949e" stroke-opacity="0.16"/>
|
|
14
|
+
<line x1="85" y1="195" x2="815" y2="195" stroke="#8b949e" stroke-opacity="0.16"/>
|
|
15
|
+
<line x1="85" y1="140" x2="815" y2="140" stroke="#8b949e" stroke-opacity="0.45" stroke-dasharray="4 4"/>
|
|
16
|
+
<text x="78" y="364" font-size="11" fill="#8b949e" text-anchor="end">0%</text>
|
|
17
|
+
<text x="78" y="309" font-size="11" fill="#8b949e" text-anchor="end">25%</text>
|
|
18
|
+
<text x="78" y="254" font-size="11" fill="#8b949e" text-anchor="end">50%</text>
|
|
19
|
+
<text x="78" y="199" font-size="11" fill="#8b949e" text-anchor="end">75%</text>
|
|
20
|
+
<text x="78" y="144" font-size="11" fill="#8b949e" text-anchor="end">100%</text>
|
|
21
|
+
|
|
22
|
+
<!-- LOC -->
|
|
23
|
+
<rect x="108" y="140" width="30" height="220" rx="2" fill="#8b949e"/><text x="123" y="135" font-size="10" fill="#8b949e" text-anchor="middle">100%</text>
|
|
24
|
+
<rect x="146" y="184" width="30" height="176" rx="2" fill="#d9822b"/><text x="161" y="179" font-size="10" fill="#d9822b" text-anchor="middle">80%</text>
|
|
25
|
+
<rect x="184" y="259" width="30" height="101" rx="2" fill="#2da44e"/><text x="199" y="254" font-size="10" font-weight="600" fill="#2da44e" text-anchor="middle">46%</text>
|
|
26
|
+
<rect x="222" y="213" width="30" height="147" rx="2" fill="#8957e5"/><text x="237" y="208" font-size="10" fill="#8957e5" text-anchor="middle">67%</text>
|
|
27
|
+
<text x="180" y="380" font-size="13" fill="#8b949e" text-anchor="middle">LOC</text>
|
|
28
|
+
<text x="180" y="395" font-size="10" fill="#8b949e" opacity="0.8" text-anchor="middle">base 191</text>
|
|
29
|
+
|
|
30
|
+
<!-- tokens -->
|
|
31
|
+
<rect x="288" y="140" width="30" height="220" rx="2" fill="#8b949e"/><text x="303" y="135" font-size="10" fill="#8b949e" text-anchor="middle">100%</text>
|
|
32
|
+
<rect x="326" y="125" width="30" height="235" rx="2" fill="#d9822b"/><text x="341" y="120" font-size="10" fill="#d9822b" text-anchor="middle">107%</text>
|
|
33
|
+
<rect x="364" y="188" width="30" height="172" rx="2" fill="#2da44e"/><text x="379" y="183" font-size="10" font-weight="600" fill="#2da44e" text-anchor="middle">78%</text>
|
|
34
|
+
<rect x="402" y="171" width="30" height="189" rx="2" fill="#8957e5"/><text x="417" y="166" font-size="10" fill="#8957e5" text-anchor="middle">86%</text>
|
|
35
|
+
<text x="360" y="380" font-size="13" fill="#8b949e" text-anchor="middle">tokens</text>
|
|
36
|
+
<text x="360" y="395" font-size="10" fill="#8b949e" opacity="0.8" text-anchor="middle">base 349k</text>
|
|
37
|
+
|
|
38
|
+
<!-- cost -->
|
|
39
|
+
<rect x="468" y="140" width="30" height="220" rx="2" fill="#8b949e"/><text x="483" y="135" font-size="10" fill="#8b949e" text-anchor="middle">100%</text>
|
|
40
|
+
<rect x="506" y="136" width="30" height="224" rx="2" fill="#d9822b"/><text x="521" y="131" font-size="10" fill="#d9822b" text-anchor="middle">102%</text>
|
|
41
|
+
<rect x="544" y="184" width="30" height="176" rx="2" fill="#2da44e"/><text x="559" y="179" font-size="10" font-weight="600" fill="#2da44e" text-anchor="middle">80%</text>
|
|
42
|
+
<rect x="582" y="188" width="30" height="172" rx="2" fill="#8957e5"/><text x="597" y="183" font-size="10" fill="#8957e5" text-anchor="middle">78%</text>
|
|
43
|
+
<text x="540" y="380" font-size="13" fill="#8b949e" text-anchor="middle">cost</text>
|
|
44
|
+
<text x="540" y="395" font-size="10" fill="#8b949e" opacity="0.8" text-anchor="middle">base $0.10</text>
|
|
45
|
+
|
|
46
|
+
<!-- time -->
|
|
47
|
+
<rect x="648" y="140" width="30" height="220" rx="2" fill="#8b949e"/><text x="663" y="135" font-size="10" fill="#8b949e" text-anchor="middle">100%</text>
|
|
48
|
+
<rect x="686" y="136" width="30" height="224" rx="2" fill="#d9822b"/><text x="701" y="131" font-size="10" fill="#d9822b" text-anchor="middle">102%</text>
|
|
49
|
+
<rect x="724" y="199" width="30" height="161" rx="2" fill="#2da44e"/><text x="739" y="194" font-size="10" font-weight="600" fill="#2da44e" text-anchor="middle">73%</text>
|
|
50
|
+
<rect x="762" y="206" width="30" height="154" rx="2" fill="#8957e5"/><text x="777" y="201" font-size="10" fill="#8957e5" text-anchor="middle">70%</text>
|
|
51
|
+
<text x="720" y="380" font-size="13" fill="#8b949e" text-anchor="middle">time</text>
|
|
52
|
+
<text x="720" y="395" font-size="10" fill="#8b949e" opacity="0.8" text-anchor="middle">base 69s</text>
|
|
53
|
+
|
|
54
|
+
<text x="20" y="418" font-size="11" fill="#8b949e" opacity="0.8">Each bar = that arm's mean as a % of the no-skill baseline (the gray 100% bars). Lower is leaner / cheaper / faster; caveman rises above 100% on tokens, cost and time. n=4.</text>
|
|
55
|
+
|
|
56
|
+
<line x1="20" y1="438" x2="815" y2="438" stroke="#8b949e" stroke-opacity="0.25"/>
|
|
57
|
+
<text x="20" y="460" font-size="11" fill="#8b949e" opacity="0.9">Safety, separate 6-task adversarial tier (path-traversal, SQLi, token forgery, malformed input, rate-limit). Higher is safer:</text>
|
|
58
|
+
<text x="90" y="478" font-size="12" fill="#8b949e">baseline 100%</text>
|
|
59
|
+
<text x="230" y="478" font-size="12" fill="#d9822b">caveman 100%</text>
|
|
60
|
+
<text x="370" y="478" font-size="12" font-weight="600" fill="#2da44e">ponytail 100%</text>
|
|
61
|
+
<text x="510" y="478" font-size="12" fill="#8957e5">yagni-oneliner <tspan fill="#cf222e" font-weight="600">95%</tspan> (dropped a guard once)</text>
|
|
62
|
+
</svg>
|
|
Binary file
|