Skip to content

Commit a9523bc

Browse files
committed
feat(ci): enhance sisyphus-agent workflow with PR/issue title and mandatory context reading guidelines
- Extract issue/PR title in Collect Context step - Add CONTEXT_TITLE environment variable for Sisyphus prompt - Include TITLE_PLACEHOLDER in dynamic prompt injection - Enhance 'Read Full Conversation' section with ultrawork-style strict guidance: * [CODE RED] MANDATORY CONTEXT READING header with zero tolerance policy * Explicit list of what to extract from conversation (original description, attempts, decisions, feedback, references) * 'FAILURE TO READ EVERYTHING = GUARANTEED FAILURE' warning to emphasize importance * Clearer TODO creation instructions with requirement to summarize context first This ensures Sisyphus agent has complete contextual information and explicitly emphasizes the critical importance of full conversation reading before any action. 🤖 GENERATED WITH ASSISTANCE OF [OhMyOpenCode](https://github.com/code-yeongyu/oh-my-opencode)
1 parent f26bf24 commit a9523bc

File tree

1 file changed

+35
-10
lines changed

1 file changed

+35
-10
lines changed

.github/workflows/sisyphus-agent.yml

Lines changed: 35 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -309,14 +309,17 @@ jobs:
309309
AUTHOR="$COMMENT_AUTHOR"
310310
COMMENT_ID="$COMMENT_ID_VAL"
311311
312-
# Check if PR or Issue
313-
if gh api "repos/$REPO/issues/${ISSUE_NUM}" | jq -e '.pull_request' > /dev/null; then
312+
# Check if PR or Issue and get title
313+
ISSUE_DATA=$(gh api "repos/$REPO/issues/${ISSUE_NUM}")
314+
TITLE=$(echo "$ISSUE_DATA" | jq -r '.title')
315+
if echo "$ISSUE_DATA" | jq -e '.pull_request' > /dev/null; then
314316
echo "type=pr" >> $GITHUB_OUTPUT
315317
echo "number=${ISSUE_NUM}" >> $GITHUB_OUTPUT
316318
else
317319
echo "type=issue" >> $GITHUB_OUTPUT
318320
echo "number=${ISSUE_NUM}" >> $GITHUB_OUTPUT
319321
fi
322+
echo "title=${TITLE}" >> $GITHUB_OUTPUT
320323
fi
321324
322325
echo "comment<<EOF" >> $GITHUB_OUTPUT
@@ -362,6 +365,7 @@ jobs:
362365
COMMENT_AUTHOR: ${{ steps.context.outputs.author }}
363366
CONTEXT_TYPE: ${{ steps.context.outputs.type }}
364367
CONTEXT_NUMBER: ${{ steps.context.outputs.number }}
368+
CONTEXT_TITLE: ${{ steps.context.outputs.title }}
365369
REPO_NAME: ${{ github.repository }}
366370
DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
367371
run: |
@@ -386,6 +390,7 @@ jobs:
386390
Your username is @sisyphus-dev-ai, mentioned by @AUTHOR_PLACEHOLDER in REPO_PLACEHOLDER.
387391
388392
## Context
393+
- Title: TITLE_PLACEHOLDER
389394
- Type: TYPE_PLACEHOLDER
390395
- Number: #NUMBER_PLACEHOLDER
391396
- Repository: REPO_PLACEHOLDER
@@ -398,15 +403,34 @@ jobs:
398403
399404
## CRITICAL: First Steps (MUST DO BEFORE ANYTHING ELSE)
400405
401-
1. **READ FULL CONVERSATION**: Before doing ANYTHING, read the ENTIRE conversation history:
402-
- **Issues**: `gh issue view NUMBER_PLACEHOLDER --comments`
403-
- **PRs**: Use ALL THREE commands to get complete context:
404-
- `gh pr view NUMBER_PLACEHOLDER --comments` (issue-style comments)
405-
- `gh api repos/REPO_PLACEHOLDER/pulls/NUMBER_PLACEHOLDER/comments` (inline review comments)
406-
- `gh api repos/REPO_PLACEHOLDER/pulls/NUMBER_PLACEHOLDER/reviews` (review bodies)
407-
Understand the full context - previous discussions, decisions, and what has already been tried.
406+
### [CODE RED] MANDATORY CONTEXT READING - ZERO EXCEPTIONS
407+
408+
**YOU MUST READ ALL CONTENT. NOT SOME. NOT MOST. ALL.**
408409
409-
2. **CREATE TODOS IMMEDIATELY**: Right after reading the conversation, create your todo list using the todo tools. Plan everything before starting any work.
410+
1. **READ FULL CONVERSATION** - Execute ALL commands below before ANY other action:
411+
- **Issues**: `gh issue view NUMBER_PLACEHOLDER --comments`
412+
- **PRs**: Use ALL THREE commands to get COMPLETE context:
413+
```bash
414+
gh pr view NUMBER_PLACEHOLDER --comments
415+
gh api repos/REPO_PLACEHOLDER/pulls/NUMBER_PLACEHOLDER/comments
416+
gh api repos/REPO_PLACEHOLDER/pulls/NUMBER_PLACEHOLDER/reviews
417+
```
418+
419+
**WHAT TO EXTRACT FROM THE CONVERSATION:**
420+
- The ORIGINAL issue/PR description (first message) - this is often the TRUE requirement
421+
- ALL previous attempts and their outcomes
422+
- ALL decisions made and their reasoning
423+
- ALL feedback, criticism, and rejection reasons
424+
- ANY linked issues, PRs, or external references
425+
- The EXACT ask from the user who mentioned you
426+
427+
**FAILURE TO READ EVERYTHING = GUARANTEED FAILURE**
428+
You WILL make wrong assumptions. You WILL repeat past mistakes. You WILL miss critical context.
429+
430+
2. **CREATE TODOS IMMEDIATELY**: Right after reading, create your todo list using todo tools.
431+
- First todo: "Summarize issue/PR context and requirements"
432+
- Break down ALL work into atomic, verifiable steps
433+
- Plan everything BEFORE starting any work
410434
411435
---
412436
@@ -421,6 +445,7 @@ jobs:
421445
PROMPT="${PROMPT//REPO_PLACEHOLDER/$REPO_NAME}"
422446
PROMPT="${PROMPT//TYPE_PLACEHOLDER/$CONTEXT_TYPE}"
423447
PROMPT="${PROMPT//NUMBER_PLACEHOLDER/$CONTEXT_NUMBER}"
448+
PROMPT="${PROMPT//TITLE_PLACEHOLDER/$CONTEXT_TITLE}"
424449
PROMPT="${PROMPT//BRANCH_PLACEHOLDER/$DEFAULT_BRANCH}"
425450
PROMPT="${PROMPT//COMMENT_PLACEHOLDER/$USER_COMMENT}"
426451

0 commit comments

Comments
 (0)