From 288552845e1ee53b333d9c0846f466243750064a Mon Sep 17 00:00:00 2001 From: jaybell Date: Mon, 2 Feb 2026 18:10:29 -0800 Subject: [PATCH] feat: add additional metadata in the logs --- ralph.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/ralph.sh b/ralph.sh index baff052a..65ba9f69 100755 --- a/ralph.sh +++ b/ralph.sh @@ -84,7 +84,20 @@ echo "Starting Ralph - Tool: $TOOL - Max iterations: $MAX_ITERATIONS" for i in $(seq 1 $MAX_ITERATIONS); do echo "" echo "===============================================================" + + # Extract current user story (highest priority with passes: false) + STORY_TITLE="" + STORY_DESC="" + if [ -f "$PRD_FILE" ]; then + STORY_TITLE=$(jq -r '[.userStories[] | select(.passes == false)] | sort_by(.priority) | .[0].title // empty' "$PRD_FILE" 2>/dev/null || echo "") + STORY_DESC=$(jq -r '[.userStories[] | select(.passes == false)] | sort_by(.priority) | .[0].description // empty' "$PRD_FILE" 2>/dev/null || echo "") + fi + echo " Ralph Iteration $i of $MAX_ITERATIONS ($TOOL)" + if [ -n "$STORY_TITLE" ]; then + echo " Story: $STORY_TITLE" + [ -n "$STORY_DESC" ] && echo " $STORY_DESC" + fi echo "===============================================================" # Run the selected tool with the ralph prompt