Skip to content

Commit d58d19c

Browse files
committed
feat: thread jam personality into trace, verify, and commit prompts
1 parent 16ad8b6 commit d58d19c

3 files changed

Lines changed: 9 additions & 9 deletions

File tree

src/commands/commit.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ export function buildCommitSystemPrompt(
143143
// Compact for small models
144144
const format = convention?.format ?? detected?.format ?? 'type(scope): short description';
145145
return [
146-
`Generate a commit message for the code changes described.`,
146+
`You are Jam. Write a commit message for this diff.`,
147147
`Output ONLY the commit message, nothing else — no explanation, no prefix, no markdown.`,
148148
`Format: ${format}`,
149149
...(convention?.types?.length ? [`Types: ${convention.types.join(', ')}`] : []),
@@ -159,7 +159,7 @@ export function buildCommitSystemPrompt(
159159
const examples = detected?.examples ?? [];
160160

161161
const sections: string[] = [
162-
'You are an expert software engineer. Given a git diff, generate a concise commit message.',
162+
'You are Jam. Given a git diff, write a clear, concise commit message.',
163163
'',
164164
];
165165

@@ -211,8 +211,8 @@ export function buildCommitSystemPrompt(
211211

212212
// ── Legacy prompts (fallback) ───────────────────────────────────────────────
213213

214-
const SYSTEM_PROMPT = `You are an expert software engineer. Given a git diff, generate a concise \
215-
commit message following the Conventional Commits specification.
214+
const SYSTEM_PROMPT = `You are Jam. Given a git diff, write a clear, concise commit message \
215+
following the Conventional Commits specification.
216216
217217
Rules:
218218
- Format: <type>(<scope>): <short description>
@@ -226,7 +226,7 @@ Rules:
226226
* Compact system prompt for small/embedded models that struggle with
227227
* long instructions. No example — examples cause small models to echo them.
228228
*/
229-
const SYSTEM_PROMPT_SMALL = `Generate a conventional commit message for the code changes described.
229+
const SYSTEM_PROMPT_SMALL = `You are Jam. Write a conventional commit message for this diff.
230230
Output ONLY the commit message, nothing else — no explanation, no prefix, no markdown.
231231
Format: type(scope): short description
232232
Types: feat, fix, docs, style, refactor, perf, test, chore

src/commands/trace.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ async function runTraceV2(
196196

197197
const graphContext = formatGraphForAIV2(result, 8000);
198198
const prompt = [
199-
'Analyze this call graph and explain the flow to a developer:',
199+
'Here\'s the call graph. Walk through the flow and flag anything that looks off:',
200200
'',
201201
graphContext,
202202
'',
@@ -214,7 +214,7 @@ async function runTraceV2(
214214
model: profile.model,
215215
temperature: profile.temperature ?? 0.3,
216216
maxTokens: profile.maxTokens ?? 1024,
217-
systemPrompt: 'You are a senior software architect analyzing a codebase. Be concise and insightful.',
217+
systemPrompt: 'You are Jam, a senior software architect. Be direct, be specific. If something looks wrong, say so.',
218218
};
219219

220220
if (config.cacheEnabled) {
@@ -330,7 +330,7 @@ async function runTraceLegacy(
330330

331331
const graphContext = formatGraphForAILegacy(graph);
332332
const prompt = [
333-
'Analyze this call graph and explain the flow to a developer:',
333+
'Here\'s the call graph. Walk through the flow and flag anything that looks off:',
334334
'',
335335
graphContext,
336336
'',

src/commands/verify.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -350,7 +350,7 @@ async function checkAiRisk(
350350
const truncatedDiff = diff.length > 15000 ? diff.slice(0, 15000) + '\n... (truncated)' : diff;
351351

352352
const prompt = [
353-
'You are a code review safety validator. Analyze this diff and respond with ONLY a JSON object (no markdown, no code fences):',
353+
'You are Jam, reviewing this diff for safety issues. Respond with ONLY a JSON object (no markdown, no code fences):',
354354
'',
355355
'{"risk": "low|medium|high|critical", "score": 0.0-1.0, "findings": ["issue1", "issue2"], "summary": "one sentence"}',
356356
'',

0 commit comments

Comments
 (0)