feat(ui): expose all editable prompt files, drop agent prompt
This commit is contained in:
@@ -2,7 +2,7 @@ using System.Text;
|
||||
|
||||
namespace ClaudeDo.Data;
|
||||
|
||||
public enum PromptKind { System, Planning, PlanningInitial, Retry, DailyPrep, WeeklyReport, Agent }
|
||||
public enum PromptKind { System, Planning, PlanningInitial, Retry, DailyPrep, WeeklyReport }
|
||||
|
||||
public static class PromptFiles
|
||||
{
|
||||
@@ -16,7 +16,6 @@ public static class PromptFiles
|
||||
PromptKind.Retry => Path.Combine(Root, "retry.md"),
|
||||
PromptKind.DailyPrep => Path.Combine(Root, "daily-prep.md"),
|
||||
PromptKind.WeeklyReport => Path.Combine(Root, "weekly-report.md"),
|
||||
PromptKind.Agent => Path.Combine(Root, "agent.md"),
|
||||
_ => throw new ArgumentOutOfRangeException(nameof(kind))
|
||||
};
|
||||
|
||||
@@ -60,7 +59,6 @@ public static class PromptFiles
|
||||
PromptKind.Retry => RetryDefault,
|
||||
PromptKind.DailyPrep => DailyPrepDefault,
|
||||
PromptKind.WeeklyReport => WeeklyReportDefault,
|
||||
PromptKind.Agent => "",
|
||||
_ => ""
|
||||
};
|
||||
|
||||
|
||||
@@ -43,8 +43,11 @@
|
||||
"restoreDefaultAgents": "Standard-Agenten wiederherstellen",
|
||||
"promptsSection": "PROMPTS",
|
||||
"systemPrompt": "System",
|
||||
"planningPrompt": "Planung",
|
||||
"agentPrompt": "Agent",
|
||||
"planningPrompt": "Planung (System)",
|
||||
"planningInitialPrompt": "Planungs-Start",
|
||||
"retryPrompt": "Wiederholung",
|
||||
"dailyPrepPrompt": "Tagesplanung",
|
||||
"weeklyReportPrompt": "Wochenbericht",
|
||||
"openInEditor": "Im Editor öffnen"
|
||||
},
|
||||
"prime": {
|
||||
|
||||
@@ -43,8 +43,11 @@
|
||||
"restoreDefaultAgents": "Restore default agents",
|
||||
"promptsSection": "PROMPTS",
|
||||
"systemPrompt": "System",
|
||||
"planningPrompt": "Planning",
|
||||
"agentPrompt": "Agent",
|
||||
"planningPrompt": "Planning (system)",
|
||||
"planningInitialPrompt": "Planning kickoff",
|
||||
"retryPrompt": "Retry",
|
||||
"dailyPrepPrompt": "Daily prep",
|
||||
"weeklyReportPrompt": "Weekly report",
|
||||
"openInEditor": "Open in editor"
|
||||
},
|
||||
"prime": {
|
||||
|
||||
@@ -16,7 +16,10 @@ public sealed partial class FilesSettingsTabViewModel : ViewModelBase
|
||||
|
||||
public string SystemPromptPath { get; } = PromptFiles.PathFor(PromptKind.System);
|
||||
public string PlanningPromptPath { get; } = PromptFiles.PathFor(PromptKind.Planning);
|
||||
public string AgentPromptPath { get; } = PromptFiles.PathFor(PromptKind.Agent);
|
||||
public string PlanningInitialPromptPath { get; } = PromptFiles.PathFor(PromptKind.PlanningInitial);
|
||||
public string RetryPromptPath { get; } = PromptFiles.PathFor(PromptKind.Retry);
|
||||
public string DailyPrepPromptPath { get; } = PromptFiles.PathFor(PromptKind.DailyPrep);
|
||||
public string WeeklyReportPromptPath { get; } = PromptFiles.PathFor(PromptKind.WeeklyReport);
|
||||
|
||||
public FilesSettingsTabViewModel(WorkerClient worker) => _worker = worker;
|
||||
|
||||
|
||||
@@ -181,7 +181,7 @@
|
||||
</StackPanel>
|
||||
<StackPanel Spacing="6">
|
||||
<TextBlock Classes="section-label" Text="{loc:Tr settings.files.promptsSection}"/>
|
||||
<Grid RowDefinitions="Auto,Auto,Auto" ColumnDefinitions="90,*,Auto" RowSpacing="8">
|
||||
<Grid RowDefinitions="Auto,Auto,Auto,Auto,Auto,Auto" ColumnDefinitions="120,*,Auto" RowSpacing="8">
|
||||
<TextBlock Grid.Row="0" Grid.Column="0" Classes="field-label" Text="{loc:Tr settings.files.systemPrompt}" VerticalAlignment="Center"/>
|
||||
<TextBlock Grid.Row="0" Grid.Column="1" Classes="path-mono" Text="{Binding Files.SystemPromptPath}" VerticalAlignment="Center"/>
|
||||
<Button Classes="btn" Grid.Row="0" Grid.Column="2" Content="{loc:Tr settings.files.openInEditor}"
|
||||
@@ -190,10 +190,22 @@
|
||||
<TextBlock Grid.Row="1" Grid.Column="1" Classes="path-mono" Text="{Binding Files.PlanningPromptPath}" VerticalAlignment="Center"/>
|
||||
<Button Classes="btn" Grid.Row="1" Grid.Column="2" Content="{loc:Tr settings.files.openInEditor}"
|
||||
Command="{Binding Files.OpenPromptCommand}" CommandParameter="Planning"/>
|
||||
<TextBlock Grid.Row="2" Grid.Column="0" Classes="field-label" Text="{loc:Tr settings.files.agentPrompt}" VerticalAlignment="Center"/>
|
||||
<TextBlock Grid.Row="2" Grid.Column="1" Classes="path-mono" Text="{Binding Files.AgentPromptPath}" VerticalAlignment="Center"/>
|
||||
<TextBlock Grid.Row="2" Grid.Column="0" Classes="field-label" Text="{loc:Tr settings.files.planningInitialPrompt}" VerticalAlignment="Center"/>
|
||||
<TextBlock Grid.Row="2" Grid.Column="1" Classes="path-mono" Text="{Binding Files.PlanningInitialPromptPath}" VerticalAlignment="Center"/>
|
||||
<Button Classes="btn" Grid.Row="2" Grid.Column="2" Content="{loc:Tr settings.files.openInEditor}"
|
||||
Command="{Binding Files.OpenPromptCommand}" CommandParameter="Agent"/>
|
||||
Command="{Binding Files.OpenPromptCommand}" CommandParameter="PlanningInitial"/>
|
||||
<TextBlock Grid.Row="3" Grid.Column="0" Classes="field-label" Text="{loc:Tr settings.files.retryPrompt}" VerticalAlignment="Center"/>
|
||||
<TextBlock Grid.Row="3" Grid.Column="1" Classes="path-mono" Text="{Binding Files.RetryPromptPath}" VerticalAlignment="Center"/>
|
||||
<Button Classes="btn" Grid.Row="3" Grid.Column="2" Content="{loc:Tr settings.files.openInEditor}"
|
||||
Command="{Binding Files.OpenPromptCommand}" CommandParameter="Retry"/>
|
||||
<TextBlock Grid.Row="4" Grid.Column="0" Classes="field-label" Text="{loc:Tr settings.files.dailyPrepPrompt}" VerticalAlignment="Center"/>
|
||||
<TextBlock Grid.Row="4" Grid.Column="1" Classes="path-mono" Text="{Binding Files.DailyPrepPromptPath}" VerticalAlignment="Center"/>
|
||||
<Button Classes="btn" Grid.Row="4" Grid.Column="2" Content="{loc:Tr settings.files.openInEditor}"
|
||||
Command="{Binding Files.OpenPromptCommand}" CommandParameter="DailyPrep"/>
|
||||
<TextBlock Grid.Row="5" Grid.Column="0" Classes="field-label" Text="{loc:Tr settings.files.weeklyReportPrompt}" VerticalAlignment="Center"/>
|
||||
<TextBlock Grid.Row="5" Grid.Column="1" Classes="path-mono" Text="{Binding Files.WeeklyReportPromptPath}" VerticalAlignment="Center"/>
|
||||
<Button Classes="btn" Grid.Row="5" Grid.Column="2" Content="{loc:Tr settings.files.openInEditor}"
|
||||
Command="{Binding Files.OpenPromptCommand}" CommandParameter="WeeklyReport"/>
|
||||
</Grid>
|
||||
</StackPanel>
|
||||
<TextBlock Classes="meta" Text="{Binding Files.StatusMessage}"
|
||||
|
||||
Reference in New Issue
Block a user