@iiiokojiadbi/shift 0.32.0 → 0.33.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/core/hint.ts CHANGED
@@ -4,9 +4,10 @@ import { formatK } from './markdown'
4
4
  import type { Gauge, Reading } from './types'
5
5
 
6
6
  // Every step is a share of the limit — the harness's own threshold, or the window when it is unknown — so the rhythm is the same on any window.
7
- // Soft hints come every max(100K, 25%) of growth: a shorter stretch does not pay for its own letter and records.
7
+ // Soft hints come every max(150K, 40%) of growth: a shorter stretch does not pay for its letter, its records and the cache
8
+ // built anew after it. On a small window the step does not fit before the final hint, so the final one is the only one.
8
9
  export function softStep(limit: number): number {
9
- return Math.max(100_000, Math.round(limit / 4))
10
+ return Math.max(150_000, Math.round(limit * 0.4))
10
11
  }
11
12
 
12
13
  // The final hint comes at 80% of the limit, with room left to finish a stage, and again every 5% after it.
@@ -172,11 +172,11 @@ ${PLACES}
172
172
 
173
173
  ## When to shift
174
174
 
175
- Not before the first soft hint. A finished task is not a reason by itself: a short stretch does not pay for its letter and records, and its history still holds what the next step may need. Until the soft hint, go on working; earlier only on the owner's word. \`${STATUS_TOOL}\` says when the next hint comes.
175
+ Never before the first hint, never on a small history. A shift costs the owner's limits: the harness builds its cache of the history anew, and the files of the work are read again. A short stretch does not pay for that, nor for its letter and records, and its history still holds what the next step may need. A finished task is not a reason by itself. Until the first hint, go on working; earlier only on the owner's word. \`${STATUS_TOOL}\` says when the next hint comes.
176
176
 
177
- After the soft hint — at a stage boundary: an item or a task is done, a commit is made, the plan moved to its next step — and the stretch's history is not needed whole any more. Not in the middle of a thought that is easier to finish than to write down.
177
+ After a hint — at a stage boundary: an item or a task is done, a commit is made, the plan moved to its next step — and the stretch's history is not needed whole any more. Not in the middle of a thought that is easier to finish than to write down.
178
178
 
179
- The mod hints with a "Shift hint" line at the end of a tool result or next to a message: the soft hint when the history has grown noticeably since the last shift, the final one when room is running out. A hint names what the history grew from most. A soft hint is not an order: you decide.
179
+ The mod hints with a "Shift hint" line at the end of a tool result or next to a message: the soft hint when the history has grown by a large share of the room since the last shift, the final one when room is running out. On a small window the final hint is the only one. A hint names what the history grew from most. A soft hint is not an order: you decide.
180
180
 
181
181
  ## Tools
182
182
 
@@ -249,7 +249,7 @@ export const EXCLUDED = (file: string) =>
249
249
 
250
250
  // The shift refused before anything is written: the harness would not let this history go.
251
251
  export const SHIFT_TOO_EARLY = (why: string) =>
252
- `Nothing to shift yet: ${why} Nothing was written. Keep working with the records as they are, and shift once the history has grown — after the first soft hint.`
252
+ `Nothing to shift yet: ${why} Nothing was written. Keep working with the records as they are, and shift once the history has grown — after the first hint.`
253
253
 
254
254
  // A shift accepted and then not made: the agent was told it was accepted, so it is told it was not.
255
255
  export const NOT_MADE_NOTE = (name: string, why: string) =>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iiiokojiadbi/shift",
3
- "version": "0.32.0",
3
+ "version": "0.33.0",
4
4
  "description": "The agent decides by itself when to shift: it keeps a work board and task folders, writes a letter to itself, and continues from where it stopped.",
5
5
  "license": "MIT",
6
6
  "type": "module",