Add confidence breakdown display

- Shows High/Medium/Low count breakdown
- Helps verify all matching posts will be processed
- Example output:
  Filtered to 328 proposals (confidence >= Medium)
    Breakdown: High=293, Medium=35, Low=0

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
This commit is contained in:
Kevin Bataille
2026-02-16 18:21:16 +01:00
parent 54168a1c00
commit 06d660f9c8
2 changed files with 40 additions and 0 deletions

View File

@@ -381,6 +381,12 @@ class CategoryAssignmentProcessor:
if confidence_order.get(p.get('category_confidence', 'Medium'), 2) >= min_confidence
]
logger.info(f"Filtered to {len(filtered_proposals)} proposals (confidence >= {confidence_threshold})")
# Show breakdown
high_count = sum(1 for p in filtered_proposals if p.get('category_confidence') == 'High')
medium_count = sum(1 for p in filtered_proposals if p.get('category_confidence') == 'Medium')
low_count = sum(1 for p in filtered_proposals if p.get('category_confidence') == 'Low')
logger.info(f" Breakdown: High={high_count}, Medium={medium_count}, Low={low_count}")
# Fetch existing categories
self.category_manager.fetch_categories(site_name)