feat(data): add ImportTickets prime kind, ticket fallback list and import prompt

This commit is contained in:
mika kuns
2026-10-01 08:33:48 +02:00
parent c34680b42d
commit a0b234fe10
12 changed files with 1285 additions and 2 deletions
+19 -1
View File
@@ -5,7 +5,7 @@ using System.Text.RegularExpressions;
namespace ClaudeDo.Data;
public enum PromptKind { System, Planning, PlanningInitial, Retry, DailyPrep, WeeklyReport, ImprovementChild, Refine, MergeHelperTriage, MergeHelperWait, MergeHelperMerge, MergeHelperInitial, MergeHelperHandoff, PowerUseAddendum }
public enum PromptKind { System, Planning, PlanningInitial, Retry, DailyPrep, WeeklyReport, ImprovementChild, Refine, MergeHelperTriage, MergeHelperWait, MergeHelperMerge, MergeHelperInitial, MergeHelperHandoff, PowerUseAddendum, TicketImport }
/// <summary>
/// How a prompt kind's on-disk override (if any) relates to the bundled default.
@@ -45,6 +45,7 @@ public static class PromptFiles
PromptKind.MergeHelperInitial => "merge-helper-initial.md",
PromptKind.MergeHelperHandoff => "merge-helper-handoff.md",
PromptKind.PowerUseAddendum => "power-use.md",
PromptKind.TicketImport => "ticket-import.md",
_ => throw new ArgumentOutOfRangeException(nameof(kind))
};
@@ -223,6 +224,7 @@ public static class PromptFiles
PromptKind.MergeHelperInitial => MergeHelperInitialDefault,
PromptKind.MergeHelperHandoff => MergeHelperHandoffDefault,
PromptKind.PowerUseAddendum => PowerUseAddendumDefault,
PromptKind.TicketImport => TicketImportDefault,
_ => ""
};
@@ -385,6 +387,22 @@ public static class PromptFiles
(build + tests) before you stop.
""";
private const string TicketImportDefault = """
You are sorting my assigned items from the company ticket system into my ClaudeDo lists.
1. Call mcp__claudedo__get_ticket_import_candidates. If available is false, say why and stop.
If items is empty, say so and stop.
2. For every item, pick the list whose purpose fits the item's CONTENT — its title, its
parent and its project. A list's ticketProject is only a hint: one ticket project can
hold work for several repositories, and several lists can share one project.
3. Import each item exactly once with mcp__claudedo__import_ticket(ticketId, list).
If no list clearly fits, omit list — the item then goes to the fallback list.
Never force a weak match just to avoid the fallback.
4. Do not create, edit or move anything else.
5. Finish with a short summary: imported items per list, items that went to the fallback
list, and skipped items with their reason.
""";
private const string DailyPrepDefault = """
You are preparing my workday for {date}.