mirror of
https://github.com/open-jarvis/OpenJarvis.git
synced 2026-07-27 21:05:34 +00:00
feat: add pre-filled instruction prompts to agent templates
Add TEMPLATE_INSTRUCTIONS map with sensible defaults for daily-briefing, research-monitor, code-reviewer, and meeting-prep templates so users get a starting prompt when selecting a template. Show a warning hint when the instruction contains [bracketed placeholders] that need to be replaced. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
committed by
mrTSB
co-authored by
Claude Opus 4.6
parent
5c1990b7ae
commit
aaab50ffcf
@@ -266,6 +266,13 @@ interface WizardState {
|
||||
}
|
||||
|
||||
|
||||
const TEMPLATE_INSTRUCTIONS: Record<string, string> = {
|
||||
'daily-briefing': 'Every morning, give me a fun quote of the day, summarize my top important emails, list any meetings today from my calendar, and tell me the weather for [my city].',
|
||||
'research-monitor': 'Search for the latest news and papers on [your topic]. Summarize the top 3 most relevant findings and explain why they matter.',
|
||||
'code-reviewer': 'Review the latest commits in [repo]. Check for bugs, security issues, and style violations. Summarize findings with file paths and line numbers.',
|
||||
'meeting-prep': 'Before my next meeting, pull context from my emails, messages, and past meetings with the attendees. Summarize key topics and suggest talking points.',
|
||||
};
|
||||
|
||||
function LaunchWizard({
|
||||
templates,
|
||||
onClose,
|
||||
@@ -319,7 +326,7 @@ function LaunchWizard({
|
||||
templateId: tpl.id,
|
||||
templateData: tpl,
|
||||
name: '',
|
||||
instruction: '',
|
||||
instruction: (tpl as any).instruction || TEMPLATE_INSTRUCTIONS[tpl.id] || '',
|
||||
model: recommendedModel || w.model,
|
||||
scheduleType: (tpl as any).schedule_type || 'manual',
|
||||
scheduleValue: (tpl as any).schedule_value || '',
|
||||
@@ -499,6 +506,11 @@ function LaunchWizard({
|
||||
className="w-full px-3 py-2 rounded-lg text-sm bg-transparent resize-none"
|
||||
style={{ border: '1px solid var(--color-border)', color: 'var(--color-text)' }}
|
||||
/>
|
||||
{wizard.instruction.includes('[') && (
|
||||
<p className="text-[10px] mt-1" style={{ color: '#f59e0b' }}>
|
||||
Replace the [bracketed text] with your own values
|
||||
</p>
|
||||
)}
|
||||
</div>
|
||||
|
||||
{/* Model + Schedule row */}
|
||||
|
||||
Reference in New Issue
Block a user