@@ -16,11 +16,15 @@ inputs:
1616 description : " full returns every criterion; patchwork returns only the patchwork verdict"
1717 required : false
1818 default : full
19+ pr-number :
20+ description : Pull request whose description decides checklist-complete; empty never returns it
21+ required : false
22+ default : " "
1923 anthropic-api-key :
2024 description : Anthropic API key for the classifier
2125 required : true
2226 github-token :
23- description : GitHub token for claude-code-action
27+ description : GitHub token for claude-code-action and reading the PR description
2428 required : true
2529
2630outputs :
7478 uv run --no-project --exclude-newer PT12H --python 3.12 --with pyyaml \
7579 python -P -m infx.workflows.ci_priority \
7680 --policy "$E2E_ROOT/configs/ci-priority.yaml" --list-criteria)
77- schema=$(jq -c '{type:"object",properties:{criteria:{type:"array",items:{type:"string",enum:.},uniqueItems:true},reason:{type:"string"}},required:["criteria","reason"]}' <<<"$criteria")
81+ schema=$(jq -c 'map(select(. != "checklist-complete")) | {type:"object",properties:{criteria:{type:"array",items:{type:"string",enum:.},uniqueItems:true},reason:{type:"string"}},required:["criteria","reason"]}' <<<"$criteria")
7882 echo "json=$schema" >> "$GITHUB_OUTPUT"
7983
84+ - name : Check PR checklist
85+ id : checklist
86+ if : steps.range.outputs.head != '' && inputs.pr-number != ''
87+ continue-on-error : true
88+ shell : bash
89+ env :
90+ GH_TOKEN : ${{ inputs.github-token }}
91+ PR_NUMBER : ${{ inputs.pr-number }}
92+ E2E_ROOT : ${{ github.action_path }}/../../../inferencex-e2e
93+ run : |
94+ complete=$(gh api "repos/${GITHUB_REPOSITORY}/pulls/${PR_NUMBER}" --jq '.body // ""' |
95+ env PYTHONPATH="$E2E_ROOT" uv run --no-project --exclude-newer PT12H --python 3.12 \
96+ python -P -m infx.workflows.pr_checklist)
97+ echo "complete=$complete" >> "$GITHUB_OUTPUT"
98+
8099 - name : Install Claude Code 2.1.282
81100 id : claude_cli
82101 if : steps.range.outputs.head != ''
@@ -117,7 +136,6 @@ runs:
117136 - mtp, draft_model: speculative decoding method
118137 - sglang, vllm, dynamo-sglang, dynamo-vllm: runtime framework
119138 - model criterion: the config model-prefix itself (minimaxm31flash, not minimaxm3)
120- - checklist-complete: PR checklist is satisfied
121139 - patchwork: modified upstream engine or runtime source
122140
123141 Patchwork includes patch files, git apply, source mutation,
@@ -133,13 +151,18 @@ runs:
133151 env :
134152 OUTPUT : ${{ steps.classify.outputs.structured_output || '{}' }}
135153 SCOPE : ${{ inputs.scope }}
154+ CHECKLIST_COMPLETE : ${{ steps.checklist.outputs.complete }}
136155 run : |
137156 if jq -e 'type == "object" and (.criteria | type == "array")' \
138157 >/dev/null <<<"$OUTPUT"; then
139158 criteria=$(jq -c '.criteria' <<<"$OUTPUT")
140159 else
141160 criteria='["patchwork"]'
142161 fi
162+ criteria=$(jq -c 'map(select(. != "checklist-complete"))' <<<"$criteria")
163+ if [ "$CHECKLIST_COMPLETE" = "true" ]; then
164+ criteria=$(jq -c '. + ["checklist-complete"]' <<<"$criteria")
165+ fi
143166 if [ "$SCOPE" = "patchwork" ]; then
144167 if jq -e 'index("patchwork")' >/dev/null <<<"$criteria"; then
145168 criteria='["patchwork"]'
0 commit comments