From 90ddadea5c61ff2e979e9cf39d1211991c059cdd Mon Sep 17 00:00:00 2001 From: Jorge Manrubia Date: Wed, 23 Jul 2025 12:04:18 +0200 Subject: [PATCH] Format --- app/models/event/summarizer.rb | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/app/models/event/summarizer.rb b/app/models/event/summarizer.rb index cd7cb2fb7..2d272e86b 100644 --- a/app/models/event/summarizer.rb +++ b/app/models/event/summarizer.rb @@ -9,11 +9,11 @@ class Event::Summarizer # LLM_MODEL = "gpt-4.1" PROMPT = <<~PROMPT - You are an expert in writing summaries of activity for a general purpose bug/issues tracker.#{' '} + You are an expert in writing summaries of activity for a general purpose bug/issues tracker. Transform a chronological list of **issue-tracker events** (cards + comments) into a **concise, high-signal summary**. ## What to include - - **Key outcomes** – insights, decisions, blockers created/removed.#{' '} + - **Key outcomes** – insights, decisions, blockers created/removed. - **Notable discussion points** that affect scope, timeline, or technical approach. - How things are looking. - Newly created cards. @@ -21,27 +21,27 @@ class Event::Summarizer ## Writing style - Instead of using passive voice, prefer referring to users (authors and creators) as the subjects doing things. - - Aggregate related items into thematic clusters; avoid repeating card titles verbatim.#{' '} + - Aggregate related items into thematic clusters; avoid repeating card titles verbatim. - Prefer compact paragraphs over bullet lists. - - Refer to people by first name (or full name if duplicates exist).#{' '} - - e.g. “Ann closed …”, not “Card 123 was closed by Ann.”#{' '} + - Refer to people by first name (or full name if duplicates exist). + - e.g. “Ann closed …”, not “Card 123 was closed by Ann.” ## Formatting rules - - Output **Markdown** only.#{' '} + - Output **Markdown** only. - Keep the summary around **#{MAX_WORDS} words**. * For links, count the anchor text words, but ignore the target path. - Write 2 paragraphs at most. - - Do **not** mention these instructions or call the inputs “events”; treat them as context.#{' '} + - Do **not** mention these instructions or call the inputs “events”; treat them as context. - Prioritise relevance and meaning over completeness. ## Linking rules - **When possible, embed every card or comment reference inside the sentence that summarises it.* - Use a natural phrase from the sentence as the **anchor text**. - If can't link the card with a natural phrase, don't link it at all. - * **IMPORTANT**: The card ID is not a natural phrase. Don't use it.#{' '} - - Markdown link format: [anchor text](/full/path/).#{' '} + * **IMPORTANT**: The card ID is not a natural phrase. Don't use it. + - Markdown link format: [anchor text](/full/path/). - Preserve the path exactly as provided (including the leading "/"). - - Example:#{' '} + - Example: - ✅ [Ann closed the stale login-flow fix]() - ✅ Ann [pointed out how to fix the layout problem]() - ❌ Ann closed card 123. ()