From b4762750e2fe2d4b6ea99745d54e1355862b9d0f Mon Sep 17 00:00:00 2001 From: cocosheng-g Date: Tue, 3 Feb 2026 21:24:55 -0500 Subject: [PATCH] fix(dedup): clarify tool sequencing in prompts to fix regression Explicitly instruct the model to call the domain tool first, then echo the output, to avoid it skipping the tool call. --- .github/workflows/gemini-automated-issue-dedup.yml | 4 ++-- .github/workflows/gemini-scheduled-issue-dedup.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/gemini-automated-issue-dedup.yml b/.github/workflows/gemini-automated-issue-dedup.yml index f1c7116c63..c7c17c5bd9 100644 --- a/.github/workflows/gemini-automated-issue-dedup.yml +++ b/.github/workflows/gemini-automated-issue-dedup.yml @@ -121,9 +121,9 @@ jobs: ## Steps 1. **Find Potential Duplicates:** - The repository is ${{ github.repository }} and the issue number is ${{ github.event.issue.number }}. - - Use the `duplicates` tool with the `repo` and `issue_number` to find potential duplicates for the current issue. Do not use the `threshold` parameter. + - First, call the `duplicates` tool with the `repo` and `issue_number` to find potential duplicates. Do not use the `threshold` parameter. + - Then, AFTER the tool completes, use the `echo` command to print the tool's JSON output to the logs. - If no duplicates are found, you are done. - - Use the `echo` command to print the JSON output from the `duplicates` tool to the logs. 2. **Refine Duplicates List (if necessary):** - If the `duplicates` tool returns between 1 and 14 results, you must refine the list. - For each potential duplicate issue, run `gh issue view --json title,body,comments` to fetch its content. diff --git a/.github/workflows/gemini-scheduled-issue-dedup.yml b/.github/workflows/gemini-scheduled-issue-dedup.yml index d3f1488844..214b49e7cf 100644 --- a/.github/workflows/gemini-scheduled-issue-dedup.yml +++ b/.github/workflows/gemini-scheduled-issue-dedup.yml @@ -106,7 +106,7 @@ jobs: 1. **Extract Repository Information:** The repository is ${{ github.repository }}. 2. **Refresh Embeddings:** Call the `refresh` tool with the correct `repo`. Do not use the `force` parameter. - 3. **Log Output:** Use the `echo` command to print the JSON output from the `refresh` tool to the logs. + 3. **Log Output:** After the `refresh` tool completes, use the `echo` command to print the tool's JSON output to the logs. ## Guidelines