feat: 完善日报人物来源与会议链接
This commit is contained in:
@ -202,6 +202,7 @@ def cmd_summarize(args):
|
||||
resolve_chat_rules,
|
||||
resolve_day,
|
||||
resolve_people_aliases,
|
||||
resolve_self_name,
|
||||
serialize_message,
|
||||
shorten_headings,
|
||||
summarize_messages,
|
||||
@ -229,6 +230,7 @@ def cmd_summarize(args):
|
||||
output_config = {} if args.output else config["output"]
|
||||
exclude_chat_ids, chat_prompts = resolve_chat_rules(config)
|
||||
people_aliases = resolve_people_aliases(config)
|
||||
self_name = resolve_self_name(config)
|
||||
storage = Storage()
|
||||
if not args.no_fetch:
|
||||
from snooper_history import sync_all_chats_for_day
|
||||
@ -301,11 +303,18 @@ def cmd_summarize(args):
|
||||
calendar_events = []
|
||||
calendar_error = None
|
||||
if not getattr(args, "no_calendar", False):
|
||||
from snooper_calendar import CalendarError, fetch_calendar_events
|
||||
from snooper_calendar import (
|
||||
CalendarError,
|
||||
fetch_calendar_events,
|
||||
resolve_calendar_links,
|
||||
)
|
||||
|
||||
try:
|
||||
calendar_events = fetch_calendar_events(
|
||||
LarkClient(LarkAuth()), target_day, tz
|
||||
LarkClient(LarkAuth()),
|
||||
target_day,
|
||||
tz,
|
||||
meeting_links=resolve_calendar_links(config),
|
||||
)
|
||||
except CalendarError as error:
|
||||
calendar_error = str(error)
|
||||
@ -336,6 +345,7 @@ def cmd_summarize(args):
|
||||
previous_summary=previous_summary,
|
||||
calendar_events=calendar_events,
|
||||
calendar_error=calendar_error,
|
||||
self_name=self_name,
|
||||
)
|
||||
output_path = (
|
||||
args.output
|
||||
|
||||
Reference in New Issue
Block a user