Generate a GitHub pull request title and description for this completed task.

Task prompt:
{task_prompt}

Commits on branch:
{commit_log}

Files changed:
{diff_stat}

If the task prompt includes an explicit GitHub issue reference (for example: `issue #23` or `GitHub issue #23`), include exactly one final line at the end of the PR body:
Closes #<issue number>

Only include this line when the task prompt clearly references a GitHub issue. Do not treat task IDs, PR numbers, or generic `#N` references as issues unless they are explicitly labeled as `issue #N` or `GitHub issue #N`. Do not guess or infer issue numbers.

Format your response EXACTLY like this (no markdown code fences):
TITLE: <concise PR title, max 72 chars>

BODY:
## Summary
<2-3 sentences describing what was done and why>

## Changes
<bullet points of key changes>

<optional final line: Closes #N (only when an explicit GitHub issue reference is present in the task prompt)>

Output ONLY in the format above, nothing else.
