@llm4ts/shell 2.22.2 → 2.23.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.
@@ -1002,6 +1002,18 @@ export const gatesIn = (process, events, commands) => (workDir, laneEvents) => E
1002
1002
  }
1003
1003
  return mergeReviewResults(results);
1004
1004
  });
1005
+ /**
1006
+ * LLM4TS_STORY_CONTEXT_CHARS: how much of the code a story starts from its
1007
+ * coder sees up front (0 leaves it out); the executor's default otherwise.
1008
+ */
1009
+ export const storyContextChars = (environment) => {
1010
+ const value = Number(environment.LLM4TS_STORY_CONTEXT_CHARS?.trim() ?? "");
1011
+ return environment.LLM4TS_STORY_CONTEXT_CHARS === undefined ||
1012
+ !Number.isInteger(value) ||
1013
+ value < 0
1014
+ ? {}
1015
+ : { contextChars: value };
1016
+ };
1005
1017
  /** Today's story judge: the rubric judge over the four dimensions. */
1006
1018
  export const rubricStoryJudge = (context) => (story, diff, seats, subject) => judgeStory(
1007
1019
  // The story's own seat, not the run's: its time counts for the story.
@@ -1287,6 +1299,7 @@ export const runEpicStories = (options) => Effect.gen(function* () {
1287
1299
  gates,
1288
1300
  // With a roster, the judge and the verifier are leased per story,
1289
1301
  // away from the executor coding it (ADR 0019).
1302
+ ...storyContextChars(process.env),
1290
1303
  judge: options.storyJudge({
1291
1304
  plan: unit.plan,
1292
1305
  budget: contextBudget,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@llm4ts/shell",
3
- "version": "2.22.2",
3
+ "version": "2.23.0",
4
4
  "description": "Interactive shell and CLI for llm4ts: flow discovery, run-a-flow, and view",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -52,9 +52,9 @@
52
52
  "dependencies": {
53
53
  "@effect/platform-node": "4.0.0",
54
54
  "@effect/platform-node-shared": "4.0.0",
55
- "@llm4ts/core": "2.22.2",
56
- "@llm4ts/flow": "2.22.2",
57
- "@llm4ts/runner": "2.22.2"
55
+ "@llm4ts/core": "2.23.0",
56
+ "@llm4ts/flow": "2.23.0",
57
+ "@llm4ts/runner": "2.23.0"
58
58
  },
59
59
  "peerDependencies": {
60
60
  "effect": "4.0.0"