Generate a worklog report with the following steps:
-
Determine
WORKSPACE_ROOTandGIT_AUTHORbefore running any script:- Both should come from the user's environment, request, or CLAUDE.md settings. If not available, ask the user.
WORKSPACE_ROOTis the root directory containing the target git repositories.GIT_AUTHORis the git author name to filter commits. It can be obtained viagit config user.name.
-
Convert the user's natural-language request into explicit
collect.pyarguments:- Never pass raw
$ARGUMENTSdirectly tocollect.py. - Only pass supported flags:
--workspace-root,--date,--since,--until. - If the user mentions a workspace by name such as "caiyun", resolve it to a concrete absolute path before running the script.
- If the request describes a date range in natural language, convert it to ISO dates first.
- If any required value is ambiguous or cannot be resolved confidently, ask a clarifying question instead of running the script.
- Never pass raw
-
Use these date conversion rules:
- "today" ->
--date YYYY-MM-DD - "yesterday" ->
--date YYYY-MM-DD - "this week" ->
--sinceMonday of the current week,--untiltoday - "last week" ->
--sinceMonday of the previous week,--untilSunday of the previous week - Explicit dates or ranges should be converted directly to
--dateor--since+--until
- "today" ->
-
Run the data collection script only after the arguments have been fully resolved:
python3 ${CLAUDE_SKILL_DIR}/scripts/collect.py \
--git-author "$GIT_AUTHOR" \
--workspace-root "$WORKSPACE_ROOT" \
[--date YYYY-MM-DD | --since YYYY-MM-DD --until YYYY-MM-DD]
-
Examples of correct conversions:
/worklog-report generate this week's worklog for caiyun-> resolveWORKSPACE_ROOTto the caiyun workspace path -> convert "this week" to--sinceMonday of the current week and--untiltoday/worklog-report summarize yesterday's work-> keep the default workspace if configured -> convert "yesterday" to--date YYYY-MM-DD/worklog-report --workspace-root /path/to/ws --since 2026-03-02 --until 2026-03-06-> use the provided flags directly
-
Based on the raw data from stdout, generate a concise summary of the work done:
- Group by project
- Highlight main accomplishments and key changes
- Do NOT include specific times, only summarize the work
- Output the summary directly without extra headings or prefixes
-
Output the final report directly in the conversation:
- Start with the title line from the raw report
- Insert
## Summary\n\n{summary}\nafter the title - Do NOT append the rest of the raw report content (Git Commits, Claude Code Sessions, Cursor Sessions sections)