dsh-nextsteps 1.3.1 → 1.3.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.
Files changed (2) hide show
  1. package/index.js +8 -2
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -126,12 +126,15 @@ const PARAMETER_SCHEMA = {
126
126
 
127
127
  function toolDescription(settings) {
128
128
  const language = LANGUAGE_NAMES[settings.lang] ?? LANGUAGE_NAMES.auto;
129
+ const languageRule = settings.lang === 'auto'
130
+ ? 'Write every prompt and label in the same language the conversation has been using.'
131
+ : `LANGUAGE OVERRIDE, applies to this tool only: write every prompt and label in ${language} — even if the conversation or the session history is in another language. Never copy the conversation's language here.`;
129
132
  return [
130
133
  'MANDATORY in every turn: once all real work and other tool calls are done, call this tool BEFORE writing your final answer — the answer must come after this tool returns, so the turn ends cleanly right after it. Never write your final answer before calling it.',
131
134
  `Suggest exactly ${settings.maxFollowups} followup prompts the user is likely to want next.`,
132
135
  'Good suggestions include alternatives to the latest implementation, related features, cleanup opportunities, tests to add, or verification steps you could run yourself; if plan steps remain, one suggestion may be continuing with the next step.',
133
136
  `Each prompt must be short (usually one sentence), goal-oriented — name the outcome, not the steps — stand alone without conversation context, and be phrased in the user's first-person voice.`,
134
- `Write every prompt in ${language}.`,
137
+ languageRule,
135
138
  'Never suggest actions the user would carry out themselves outside this session (e.g. "commit these changes"); judge by the tools you actually have.',
136
139
  'This never waits for an answer: its result only confirms the suggestions were recorded.',
137
140
  'Example input:',
@@ -205,11 +208,14 @@ function turnTranscript(events, afterSeq) {
205
208
 
206
209
  function generateSystem(settings) {
207
210
  const language = LANGUAGE_NAMES[settings.lang] ?? LANGUAGE_NAMES.auto;
211
+ const languageRule = settings.lang === 'auto'
212
+ ? 'Write every prompt and label in the same language the conversation has been using.'
213
+ : `LANGUAGE OVERRIDE, applies to this answer only: write every prompt and label in ${language} — even if the transcript is in another language. Never copy the transcript's language here.`;
208
214
  return [
209
215
  'You suggest followup prompts the user of a coding-agent chat may want next. You answer with JSON only — no prose, no code fence.',
210
216
  `Output shape: {"followups":[{"prompt":"...","label":"..."}]} with exactly ${settings.maxFollowups} items.`,
211
217
  'Each prompt is one short sentence in the user\'s first-person voice, goal-oriented, standing alone without the transcript; each label is 2-5 words.',
212
- `Write every prompt and label in ${language}.`,
218
+ languageRule,
213
219
  'Good suggestions: alternatives to the latest change, related features, cleanup, tests, verification steps. If the transcript shows remaining plan steps, one suggestion may continue the next step.'
214
220
  ].join('\n');
215
221
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-nextsteps",
3
- "version": "1.3.1",
3
+ "version": "1.3.2",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": "./index.js",