Files
ai-daily-report/skill/scripts/weekly_audit.py

25 lines
623 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/usr/bin/env python3
from __future__ import annotations
import sys
from pathlib import Path
REPO_DIR = Path(__file__).resolve().parents[2]
if str(REPO_DIR) not in sys.path:
sys.path.insert(0, str(REPO_DIR))
from ai_daily_report.audit import render_markdown, summarize_reports
def main() -> int:
out_dir = Path.home() / ".hermes" / "scripts" / "ai_morning_out"
if not out_dir.exists():
print("AI日报每周审计未找到输出目录")
return 1
print(render_markdown(summarize_reports(out_dir, limit_days=7)))
return 0
if __name__ == "__main__":
raise SystemExit(main())