{{ if or .Label .HasTaskNumber .Title }}{{ if .Discussion }}task discussion: {{ else }}task dispatch: {{ end }}{{ if .Label }}{{ .Label }}{{ else if .HasTaskNumber }}#t{{ .TaskNumber }}{{ if .Title }} {{ printf "%q" .Title }}{{ end }}{{ else if .Title }}{{ printf "%q" .Title }}{{ end }}
{{ end }}{{ if .ChannelRef }}channel: {{ .ChannelRef }}
{{ end }}{{ if or .Details.Status .Details.Kind .Details.Priority .Details.BlockedReason .Details.Assignee .Details.Description .Details.AcceptanceCriteria .Details.ReviewChecklist .Details.PinnedMessageRefs .Details.RelevantURLs .Details.WorkspaceRefs .Attributes .Checklists }}task attributes:
{{ if .Details.Status }}status: {{ .Details.Status }}
{{ end }}{{ if .Details.Kind }}kind: {{ .Details.Kind }}
{{ end }}{{ if .Details.Priority }}priority: {{ .Details.Priority }}
{{ end }}{{ if .Details.BlockedReason }}blockedReason: {{ .Details.BlockedReason }}
{{ end }}{{ if .Details.Assignee }}assignee: {{ .Details.Assignee }}
{{ end }}{{ if .Details.Description }}description:
{{ .Details.Description }}
{{ end }}{{ if .Details.AcceptanceCriteria }}acceptanceCriteria:
{{ range .Details.AcceptanceCriteria }}- {{ . }}
{{ end }}{{ end }}{{ if .Details.ReviewChecklist }}reviewChecklist:
{{ range .Details.ReviewChecklist }}- {{ . }}
{{ end }}{{ end }}{{ if .Details.PinnedMessageRefs }}pinnedMessageRefs:
{{ range .Details.PinnedMessageRefs }}- {{ . }}
{{ end }}{{ end }}{{ if .Details.RelevantURLs }}relevantURLs:
{{ range .Details.RelevantURLs }}- {{ . }}
{{ end }}{{ end }}{{ if .Details.WorkspaceRefs }}workspaceRefs:
{{ range .Details.WorkspaceRefs }}- {{ . }}
{{ end }}{{ end }}{{ range .Attributes }}{{ if eq .Label "description" }}{{ .Label }}:
{{ .Value }}
{{ else }}{{ .Label }}: {{ .Value }}
{{ end }}{{ end }}{{ range .Checklists }}{{ .Label }}:
{{ range .Items }}- {{ . }}
{{ end }}{{ end }}instruction: Treat these structured task attributes as requirements. Use them before acting, and update task fields when the task asks you to fill or revise them; do not fetch full task discussion history just to inspect these attributes.
{{ end }}{{ if .Discussion }}{{ if .CommentBy }}comment by {{ .CommentBy }}{{ if .CommentBody }}:
{{ .CommentBody }}{{ end }}{{ else if .CommentBody }}comment:
{{ .CommentBody }}
{{ end }}reply: use {{ .ReplyTool }} with the exact task scope target from the current message header
{{ end }}