pi-caveman 1.0.0 → 1.0.2
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/README.md +4 -0
- package/extensions/caveman.ts +6 -6
- package/package.json +11 -3
package/README.md
CHANGED
|
@@ -23,6 +23,10 @@ A [pi](https://github.com/mariozechner/pi) extension that cuts **~75% of output
|
|
|
23
23
|
</tr>
|
|
24
24
|
</table>
|
|
25
25
|
|
|
26
|
+
<p align="center">
|
|
27
|
+
<img src="https://raw.githubusercontent.com/jonjonrankin/pi-caveman/main/pi-caveman.gif" alt="pi-caveman demo" width="600">
|
|
28
|
+
</p>
|
|
29
|
+
|
|
26
30
|
## Install
|
|
27
31
|
|
|
28
32
|
```bash
|
package/extensions/caveman.ts
CHANGED
|
@@ -113,27 +113,27 @@ Good: "Bug in auth middleware. Token expiry check use \`<\` not \`<=\`. Fix:"`;
|
|
|
113
113
|
|
|
114
114
|
const INTENSITY: Record<Exclude<Level, "off">, string> = {
|
|
115
115
|
lite: `\
|
|
116
|
-
|
|
116
|
+
No filler/hedging. Keep articles + full sentences. Professional but tight.
|
|
117
117
|
Example: "Your component re-renders because you create a new object reference each render. Wrap it in \`useMemo\`."`,
|
|
118
118
|
|
|
119
119
|
full: `\
|
|
120
|
-
|
|
120
|
+
Drop articles, fragments OK, short synonyms.
|
|
121
121
|
Example: "New object ref each render. Inline object prop = new ref = re-render. Wrap in \`useMemo\`."`,
|
|
122
122
|
|
|
123
123
|
ultra: `\
|
|
124
|
-
|
|
124
|
+
Abbreviate (DB/auth/config/req/res/fn/impl), strip conjunctions, arrows for causality (X → Y).
|
|
125
125
|
Example: "Inline obj prop → new ref → re-render. \`useMemo\`."`,
|
|
126
126
|
|
|
127
127
|
"wenyan-lite": `\
|
|
128
|
-
|
|
128
|
+
Semi-classical Chinese. Grammar intact, filler gone. Technical terms in English.
|
|
129
129
|
Example: "組件頻重繪,以每繪新生對象參照故。以 useMemo 包之。"`,
|
|
130
130
|
|
|
131
131
|
wenyan: `\
|
|
132
|
-
|
|
132
|
+
Maximum classical terseness. 80-90% character reduction. Technical terms in English.
|
|
133
133
|
Example: "物出新參照,致重繪。useMemo Wrap之。"`,
|
|
134
134
|
|
|
135
135
|
"wenyan-ultra": `\
|
|
136
|
-
|
|
136
|
+
Extreme classical compression. Technical terms in English.
|
|
137
137
|
Example: "新參照→重繪。useMemo Wrap。"`,
|
|
138
138
|
};
|
|
139
139
|
|
package/package.json
CHANGED
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-caveman",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "Why use many token when few do trick. Caveman mode for pi — cuts ~75% output tokens while keeping full technical accuracy.",
|
|
5
|
-
"keywords": [
|
|
5
|
+
"keywords": [
|
|
6
|
+
"pi-package",
|
|
7
|
+
"pi-extension",
|
|
8
|
+
"caveman",
|
|
9
|
+
"token-saving"
|
|
10
|
+
],
|
|
6
11
|
"license": "MIT",
|
|
7
12
|
"author": "jonjonrankin",
|
|
8
13
|
"repository": {
|
|
@@ -16,7 +21,10 @@
|
|
|
16
21
|
"LICENSE"
|
|
17
22
|
],
|
|
18
23
|
"pi": {
|
|
19
|
-
"extensions": [
|
|
24
|
+
"extensions": [
|
|
25
|
+
"./extensions"
|
|
26
|
+
],
|
|
27
|
+
"image": "https://raw.githubusercontent.com/jonjonrankin/pi-caveman/main/pi-caveman.gif"
|
|
20
28
|
},
|
|
21
29
|
"peerDependencies": {
|
|
22
30
|
"@mariozechner/pi-coding-agent": "*"
|