You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: wire customInstructions from plugin config (#181)
* feat: wire customInstructions from plugin config
The customInstructions parameter threads through all 4 prompt builders
(buildLeafSummaryPrompt, buildD1Prompt, buildD2Prompt, buildD3PlusPrompt)
but is never read from config. This means operators cannot control
summarization tone or style without patching source.
Fix:
- Add customInstructions to LcmConfig type and resolver (config.ts)
- Read in resolveSummarize() chokepoint (engine.ts) with fallback:
params.customInstructions || this.config.customInstructions || undefined
- Add to plugin schema and uiHints (openclaw.plugin.json)
- Add config test coverage (test/custom-instructions.test.ts)
Every summarization path (afterTurn, /compact, overflow recovery) gets
instructions automatically through the chokepoint without caller changes.
* fix: honor customInstructions overrides across summarizers
---------
Co-authored-by: Josh Lehman <[email protected]>
Copy file name to clipboardExpand all lines: openclaw.plugin.json
+7Lines changed: 7 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -52,6 +52,10 @@
52
52
"summaryMaxOverageFactor": {
53
53
"label": "Summary Max Overage Factor",
54
54
"help": "Maximum allowed overage factor for summaries relative to target tokens (default 3). Summaries exceeding this are deterministically truncated."
55
+
},
56
+
"customInstructions": {
57
+
"label": "Custom Instructions",
58
+
"help": "Natural language instructions injected into all summarization prompts (e.g., formatting rules, tone control)"
0 commit comments