1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: AI Comment Handler
on:
# pull_request:
# types: [opened] #[opened , labeled]
issue_comment:
types:
issues:
types: #[opened, labeled]
# Define permissions needed for the workflow
permissions:
issues: write
pull-requests: write
contents: read
jobs:
trigger_probe_chat:
# Uncomment if you want to run on on specific lables, in this example `probe`
# if: |
# (github.event_name == 'pull_request' && github.event.action == 'opened') ||
# (github.event_name == 'issues' && github.event.action == 'opened') ||
# (github.event_name == 'issue_comment' && github.event.action == 'created') ||
# ((github.event_name == 'pull_request' || github.event_name == 'issues') &&
# github.event.action == 'labeled' && github.event.label.name == 'probe')
# Use the reusable workflow from your repository (replace <your-org/repo> and <ref>)
uses: buger/probe/.github/workflows/probe.yml@main
# Pass required inputs
with:
command_prefix: "/probe" # Or '/ai', '/ask', etc.
allow_edit: false
# allow_suggestions: true # Set to true to use reviewdog suggestions instead of direct commits
# Optionally override the default npx command if the secret isn't set
# default_probe_chat_command: 'node path/to/custom/script.js'
update_existing_comment: false # Set to true to update existing comments instead of creating new ones
update_comment_marker: "<!-- probe-bot -->" # Hidden marker to identify comments for updates
enable_tracing: true
# Pass ALL secrets from this repository to the reusable workflow
# This includes GITHUB_TOKEN, PROBE_CHAT_COMMAND (if set), ANTHROPIC_API_KEY, etc.
secrets:
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
ANTHROPIC_API_URL: ${{ secrets.ANTHROPIC_API_URL }}
APP_ID: ${{ secrets.PROBE_APP_ID }}
APP_PRIVATE_KEY: ${{ secrets.PROBE_APP_PRIVATE_KEY }}
MAX_TOOL_ITERATIONS: "60"
DEBUG_CHAT: ${{ secrets.DEBUG_CHAT }}