Files
HOALedgerIQ_Website/agents/junior-ae/view-tier1.py
olsch01 5319bcd30b feat: Add Chatwoot Agent Bot prototype and FAQ knowledge base
- Created chatwoot-agent-bot/ with Node.js webhook server
- Bot detects intent (greeting, billing, technical, features, account)
- Auto-responds from FAQ knowledge base or escalates to human
- FAQ-KB.md: Living knowledge base that grows with customer questions
- CHATWOOT-SETUP.md: Complete deployment and configuration guide
- Supports Telegram notifications on escalation
- Bot runs on port 3001, ready for Chatwoot webhook integration
2026-04-01 16:26:05 -04:00

44 lines
1.6 KiB
Python
Executable File

#!/usr/bin/env python3
"""View current Tier 1 leads with filtering"""
import json
from pathlib import Path
STATE_FILE = Path(__file__).parent / "state" / "tier1-state.json"
if STATE_FILE.exists():
state = json.loads(STATE_FILE.read_text())
leads = state.get('tier1_leads', [])
print(f"\n{'='*70}")
print(f"TIER 1 LEADS - Top {len(leads)}")
print(f"{'='*70}\n")
if not leads:
print("No Tier 1 leads scored yet. Waiting for JAE v5 to process leads...")
else:
print(f"{'Rank':<5} {'Score':<6} {'Temp':<6} {'Units':<8} {'Budget':<8} {'Title'}")
print("-" * 70)
for i, lead in enumerate(leads[:20], 1): # Show top 20
score = lead.get('score', 0)
temp = lead.get('temp', '?')
units = str(lead.get('units', '?'))
budget = '' if lead.get('budget_pdf') else ''
title = lead.get('title', 'Unknown')[:40]
print(f"{i:<5} {score:<6} {temp:<6} {units:<8} {budget:<8} {title}")
if len(leads) > 20:
print(f"\n... and {len(leads)-20} more")
print(f"\n{'='*70}")
print(f"Scoring Criteria:")
print(f" • Temperature: HOT=3pts, WARM=2pts, COLD=0pts")
print(f" • Units: 150-400=+4pts, 100-150/400-500=+3pts, etc.")
print(f" • Budget PDF: Found=+2pts, Mentioned=+1pts")
print(f" • Website: Yes=+1pt")
print(f" • Minimum score for Tier 1: 6/10")
print(f"{'='*70}\n")
else:
print("No Tier 1 state file found. Run tier1-scorer.py first.")