Add summary preview workflow

This commit is contained in:
Sean Goedecke
2025-04-22 06:16:47 +00:00
parent 85c6b7a620
commit a041377b16
2 changed files with 40 additions and 0 deletions
@@ -0,0 +1,7 @@
{
"name": "AI issue summary",
"description": "Summarizes new issues",
"iconName": "octicon ai-model",
"categories": ["Automation", "SDLC"],
"labels": ["preview"]
}
+33
View File
@@ -0,0 +1,33 @@
name: Summarize new issues
on:
issues:
types: [opened]
jobs:
summary:
runs-on: ubuntu-latest
permissions:
issues: write
models: read
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Run AI Inference
id: inference
uses: actions/ai-inference@v1
with:
prompt: |
Summarize the following GitHub issue in one paragraph:
Title: ${{ github.event.issue.title }}
Body: ${{ github.event.issue.body }}
- name: Comment with AI Summary
run: |
gh issue comment $ISSUE_NUMBER --body '${{ steps.inference.outputs.response }}'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ISSUE_NUMBER: ${{ github.event.issue.number }}