@@ -24,26 +24,31 @@ jobs:
2424 GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
2525
2626 - name : Autolabel Issue
27+ id : claude_analysis
2728 uses : anthropics/claude-code-action@beta
2829 with :
2930 anthropic_api_key : ${{ secrets.CLAUDE_CODE_ANTHROPIC_API_KEY }}
3031 timeout_minutes : " 5"
32+ allowed_tools : " Bash"
3133 direct_prompt : |
32- Analyze this newly created issue and perform two tasks:
34+ Analyze this newly created issue and apply appropriate labels using the gh CLI.
3335
34- 1. **Apply labels** from these available repository labels:
35- ${{ steps.labels.outputs.available_labels }}
36+ Available repository labels: ${{ steps.labels.outputs.available_labels }}
3637
37- 2. **Add a comment** with :
38- - **TLDR**: One sentence summary
39- - **Work Summary**: Brief description of what needs to be done
40- - **Label Reasoning**: Why you chose these labels (or why no labels apply)
38+ Tasks :
39+ 1. Analyze the issue content
40+ 2. Use `gh issue edit ${{ github.event.issue.number }} --add-label "label-name"` to apply each relevant label
41+ 3. Add a comment explaining your labeling decisions
4142
4243 Requirements:
4344 - Apply ALL relevant labels that match the issue content
4445 - If no labels are truly relevant, apply NO labels at all
4546 - Be thorough but precise - don't force labels that don't fit
46- - Keep comment concise and helpful
47+ - Use the Bash tool to run gh commands WITHOUT asking for confirmation
48+ - The GITHUB_TOKEN is already set in the environment for gh authentication
4749
4850 Issue Title: ${{ github.event.issue.title }}
49- Issue Body: ${{ github.event.issue.body }}
51+ Issue Body: ${{ github.event.issue.body }}
52+ env :
53+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
54+
0 commit comments