feat: brief-daily via llm-connect (structured daily brief)
Generate OperatingRhythm-format briefs with OpenRouter-backed llm-connect JSON + deterministic markdown write/commit. Server path for Binky daily rhythm without host Claude (BINKY-WP-0006-T05).
This commit is contained in:
parent
7520a53831
commit
f770825975
4 changed files with 536 additions and 0 deletions
|
|
@ -220,6 +220,28 @@ def main(argv: list[str] | None = None) -> int:
|
|||
help="Apply log updates but do not git commit",
|
||||
)
|
||||
|
||||
brief = sub.add_parser(
|
||||
"brief-daily",
|
||||
help="Write daily brief via llm-connect (JSON + markdown apply; no Claude)",
|
||||
)
|
||||
brief.add_argument("--target-repo", required=True)
|
||||
brief.add_argument(
|
||||
"--date",
|
||||
default=None,
|
||||
help="Brief date YYYY-MM-DD (default: today Europe/Berlin)",
|
||||
)
|
||||
brief.add_argument(
|
||||
"--force",
|
||||
action="store_true",
|
||||
help="Overwrite if today's brief already exists",
|
||||
)
|
||||
brief.add_argument("--no-hub", action="store_true", help="Skip hub reporting")
|
||||
brief.add_argument(
|
||||
"--no-commit",
|
||||
action="store_true",
|
||||
help="Write brief file but do not git commit",
|
||||
)
|
||||
|
||||
validate = sub.add_parser(
|
||||
"validate",
|
||||
help="Validate instance manifest (.kaizen/schedule.yml + harness fields)",
|
||||
|
|
@ -352,6 +374,39 @@ def main(argv: list[str] | None = None) -> int:
|
|||
)
|
||||
return 0 if triage_result.ok else 1
|
||||
|
||||
if args.command == "brief-daily":
|
||||
from datetime import date as date_cls
|
||||
|
||||
from agent_harness.brief_daily import run_brief_daily
|
||||
|
||||
day = None
|
||||
if args.date:
|
||||
day = date_cls.fromisoformat(args.date)
|
||||
brief_result = run_brief_daily(
|
||||
target_repo=Path(args.target_repo).expanduser(),
|
||||
day=day,
|
||||
force=bool(args.force),
|
||||
report_to_hub=not args.no_hub,
|
||||
commit=not args.no_commit,
|
||||
)
|
||||
print(
|
||||
json.dumps(
|
||||
{
|
||||
"ok": brief_result.ok,
|
||||
"date": brief_result.date,
|
||||
"path": brief_result.path,
|
||||
"wrote": brief_result.wrote,
|
||||
"committed": brief_result.committed,
|
||||
"skipped_existing": brief_result.skipped_existing,
|
||||
"head_after": brief_result.head_after,
|
||||
"reason": brief_result.reason,
|
||||
"model_meta": brief_result.model_meta,
|
||||
},
|
||||
indent=2,
|
||||
)
|
||||
)
|
||||
return 0 if brief_result.ok else 1
|
||||
|
||||
if args.command == "mail-scan":
|
||||
from agent_harness.mailscan import run_mail_scan
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue