portable-agent-layer 0.60.0 → 0.61.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.
@@ -0,0 +1,70 @@
1
+ ---
2
+ name: humanize
3
+ description: "Rewrites text to remove AI slop and make it sound human: eliminates em-dashes and en-dashes, LLM tell-words (delve, leverage, robust, seamless), 'not just X, it's Y' constructions, rule-of-three padding, boilerplate openers/closers, hedging, and decorative emoji, while preserving meaning and voice. Use when asked to humanize text, de-slop, remove AI dashes or em-dashes, strip AI tells, make writing sound human, or clean AI-generated prose."
4
+ argument-hint: <text, or a file path, or empty to rewrite the previous message>
5
+ ---
6
+
7
+ # Humanize
8
+
9
+ Rewrite the given content to strip AI-writing tells and return a human-sounding version. This is a rewrite, not a summary: preserve the author's meaning, facts, argument, structure, and voice. Never add new claims.
10
+
11
+ ## Input handling
12
+
13
+ Resolve the input in this order:
14
+
15
+ 1. **File path argument**: if `$ARGUMENTS` is a path to an existing file, read it. Ask the user whether to rewrite the file in place or output the rewrite in the response; if the request already made this clear, skip the question.
16
+ 2. **Inline text argument**: if `$ARGUMENTS` is text, rewrite that text.
17
+ 3. **No argument**: rewrite the most recent generated content or the immediately preceding message in the conversation.
18
+
19
+ ## Rule 1: zero AI dashes (the headline rule)
20
+
21
+ The output must contain **zero em-dashes (—) and zero en-dashes (–) used as sentence punctuation**. Resolve every one by exactly one of:
22
+
23
+ - Splitting into two sentences.
24
+ - Replacing with a comma.
25
+ - Wrapping the aside in parentheses.
26
+ - Replacing with a colon (when the dash introduces an explanation or list).
27
+ - Restructuring the clause so no separator is needed.
28
+
29
+ Pick whichever reads most naturally per instance; do not mechanically apply one substitute everywhere. A plain hyphen inside a genuine compound word ("well-known", "off-the-shelf") is fine. A spaced or unspaced dash joining clauses is not. Numeric ranges ("pages 3–7") may keep an en-dash only in technical or reference contexts; in prose, prefer "to".
30
+
31
+ ## Workflow
32
+
33
+ 1. Resolve the input per **Input handling** above.
34
+ 2. Scan the content and inventory every violation of the rules below before rewriting, so you can report counts afterward.
35
+ 3. Rewrite the content, applying all of the following transformations:
36
+ - **Dashes**: apply Rule 1 to every em-dash and en-dash.
37
+ - **Antithesis constructions**: rewrite every "It's not just X, it's Y" and "not only… but also" into a direct statement of what the thing is.
38
+ - **Rule-of-three padding**: collapse empty tricolons ("faster, cheaper, and more scalable" when only one quality matters) down to the item(s) that carry real information.
39
+ - **LLM tell-words**: replace with a plain equivalent: delve (dig into, examine), tapestry, testament, underscore (show), pivotal, crucial (important, or cut), robust (reliable, or cut), seamless (cut, or state the actual behavior), elevate (improve), unlock, harness, leverage (use), navigate when figurative (handle, deal with), realm (area), landscape (field, market, or cut), ever-evolving, fast-paced (cut), game-changer, foster (encourage, or cut), embark (start), myriad, plethora (many), boasts (has), meticulous (careful).
40
+ - **Boilerplate openers/closers**: delete "In today's world", "In conclusion", "Overall", "At the end of the day", "Let's dive in", "It's worth noting that", "Needless to say", and equivalents. If a closer carried a real point, keep the point and drop the frame.
41
+ - **Hedging and throat-clearing**: cut filler that adds no information ("It's important to remember that", "Generally speaking", "In many ways", "Arguably").
42
+ - **Inflation**: remove reflexive superlatives and marketing adjectives ("incredible", "powerful", "cutting-edge", "world-class"). Prefer a concrete claim over vague praise; if no concrete claim exists in the source, drop the praise rather than invent one.
43
+ - **Decoration**: strip decorative emoji and gratuitous bold sprinkled through prose. Keep bold only where it marks genuine structure (a defined term, a table header, a key already emphasized deliberately and sparingly).
44
+ 4. Verify: search the rewritten output for `—` and `–` and confirm zero sentence-punctuation hits remain.
45
+ 5. Verify meaning: confirm the rewrite makes the same claims as the original, in the same order, at roughly the same length. If a sentence lost its point during de-slopping, restore the point in plain words.
46
+ 6. If operating on a file and the user chose in-place editing, write the rewrite back to the file.
47
+
48
+ ## Output format
49
+
50
+ Return, in order:
51
+
52
+ 1. The fully rewritten content (or, if a file was edited in place, state which file was edited instead of repeating the content).
53
+ 2. A short bullet list of changes by category with counts, for example:
54
+ - removed 7 em-dashes (4 split into sentences, 2 commas, 1 colon)
55
+ - replaced "leverage" → "use" ×3, "seamless" cut ×2
56
+ - rewrote 2 "not just X, it's Y" constructions
57
+ - cut 2 boilerplate closers, 1 opener
58
+ - stripped 5 decorative emoji
59
+
60
+ ## When to use
61
+
62
+ - The user asks to humanize, de-slop, or "make it sound human / less like AI".
63
+ - The user asks to remove em-dashes, AI dashes, or AI tells from text.
64
+ - The user wants AI-generated prose cleaned up before publishing, without changing what it says.
65
+
66
+ ## Do NOT use
67
+
68
+ - To condense or shorten content: that is `summarize`. Humanize preserves length and structure.
69
+ - To pull insights, quotes, or ideas out of content: that is `extract-wisdom`. Humanize returns the whole text, rewritten in place.
70
+ - To change the argument, add claims, or restructure a document. Humanize changes wording, never meaning.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "portable-agent-layer",
3
- "version": "0.60.0",
3
+ "version": "0.61.0",
4
4
  "description": "PAL — Portable Agent Layer: persistent personal context for AI coding assistants",
5
5
  "type": "module",
6
6
  "bin": {
package/src/cli/index.ts CHANGED
@@ -1311,7 +1311,9 @@ async function importState(args: string[]) {
1311
1311
  }
1312
1312
 
1313
1313
  async function update() {
1314
- const { checkForUpdate } = await import("../hooks/handlers/update-check");
1314
+ const { checkForUpdate, clearUpdateCache } = await import(
1315
+ "../hooks/handlers/update-check"
1316
+ );
1315
1317
  const result = await checkForUpdate(true);
1316
1318
 
1317
1319
  log.info(`Current: ${result.current} (${result.mode} mode)`);
@@ -1351,6 +1353,7 @@ async function update() {
1351
1353
  throw new Error(`Failed to read updated package.json: ${e}`);
1352
1354
  }
1353
1355
  log.success(`Updated: ${result.current} → ${newPkg.version}`);
1356
+ clearUpdateCache();
1354
1357
 
1355
1358
  log.info("Reinstalling...");
1356
1359
  await install(resolveTargets([]));
@@ -7,7 +7,7 @@
7
7
  * Caches result in state/update-available.json. Checked at most once per hour.
8
8
  */
9
9
 
10
- import { existsSync, readFileSync, writeFileSync } from "node:fs";
10
+ import { existsSync, readFileSync, rmSync, writeFileSync } from "node:fs";
11
11
  import { resolve } from "node:path";
12
12
  import { logDebug } from "../lib/log";
13
13
  import { ensureDir, palPkg, paths } from "../lib/paths";
@@ -179,6 +179,15 @@ export async function checkForUpdate(force = false): Promise<UpdateCache> {
179
179
  return result;
180
180
  }
181
181
 
182
+ /** Invalidate the cached update status — call after a successful update so the notice clears immediately. */
183
+ export function clearUpdateCache(): void {
184
+ try {
185
+ rmSync(cachePath(), { force: true });
186
+ } catch {
187
+ /* non-critical */
188
+ }
189
+ }
190
+
182
191
  /** Read cached update status for greeting display. Returns null if no update. */
183
192
  export function getUpdateNotice(): string | null {
184
193
  try {
@@ -44,6 +44,20 @@ export const MODEL_PRICING: Record<
44
44
  cacheWrite1h: 2,
45
45
  cacheRead: 0.1,
46
46
  },
47
+ [FABLE_MODEL]: {
48
+ input: 10,
49
+ output: 50,
50
+ cacheWrite5m: 12.5,
51
+ cacheWrite1h: 20,
52
+ cacheRead: 1,
53
+ },
54
+ "claude-opus-4-8": {
55
+ input: 5,
56
+ output: 25,
57
+ cacheWrite5m: 6.25,
58
+ cacheWrite1h: 10,
59
+ cacheRead: 0.5,
60
+ },
47
61
  "claude-opus-4-7": {
48
62
  input: 5,
49
63
  output: 25,
@@ -58,6 +72,14 @@ export const MODEL_PRICING: Record<
58
72
  cacheWrite1h: 10,
59
73
  cacheRead: 0.5,
60
74
  },
75
+ // Claude Sonnet 5 — introductory pricing through 2026-08-31; standard (3/15/3.75/6/0.30) applies from 2026-09-01.
76
+ "claude-sonnet-5": {
77
+ input: 2,
78
+ output: 10,
79
+ cacheWrite5m: 2.5,
80
+ cacheWrite1h: 4,
81
+ cacheRead: 0.2,
82
+ },
61
83
  "claude-sonnet-4-6": {
62
84
  input: 3,
63
85
  output: 15,