| """AgentPulse — pipeline entrypoint. |
| |
| Usage: |
| python main.py # Run the full collect → score → write loop once |
| python main.py --collect-only # Run collectors, skip scoring |
| python main.py --score-only # Recompute scores from existing signals |
| python main.py --reproduce # Reproduce the paper's headline result (Table 3) |
| """ |
|
|
| import argparse |
| import logging |
| import sys |
|
|
| logging.basicConfig( |
| level=logging.INFO, |
| format="%(asctime)s [%(levelname)s] %(name)s: %(message)s", |
| ) |
| log = logging.getLogger("agentpulse") |
|
|
|
|
| def collect(): |
| """Collect 18 signals across the agent registry.""" |
| from collectors.agent_signals import AgentSignalCollector |
| from collectors.agent_benchmarks import AgentBenchmarkCollector |
|
|
| log.info("Collecting agent benchmark signals…") |
| AgentBenchmarkCollector().collect() |
| log.info("Collecting agent multi-source signals…") |
| AgentSignalCollector().collect() |
|
|
|
|
| def score(): |
| """Aggregate raw signals into the four-factor composite (Section 3).""" |
| from scoring.agent_scoring_v2 import compute_agent_scores |
| log.info("Computing four-factor composite scores…") |
| compute_agent_scores() |
|
|
|
|
| def reproduce(): |
| """Reproduce the paper's headline cross-factor predictive validity result.""" |
| from scoring.agent_scoring_v2 import reproduce_table_3 |
| reproduce_table_3() |
|
|
|
|
| def main(): |
| parser = argparse.ArgumentParser( |
| description="AgentPulse — continuous multi-signal evaluation of AI agents" |
| ) |
| parser.add_argument("--collect-only", action="store_true", |
| help="Only run collectors; skip scoring") |
| parser.add_argument("--score-only", action="store_true", |
| help="Only recompute scores from existing signals") |
| parser.add_argument("--reproduce", action="store_true", |
| help="Reproduce the paper's Table 3 headline result") |
| args = parser.parse_args() |
|
|
| if args.reproduce: |
| reproduce() |
| return |
|
|
| if args.score_only: |
| score() |
| return |
|
|
| collect() |
| if not args.collect_only: |
| score() |
|
|
|
|
| if __name__ == "__main__": |
| sys.exit(main() or 0) |
|
|