Ot leave claim
Skill carrick87/ot-leave-claim
AI agent skill: calculate outside-hours OT from git/Cursor activity and produce leave-replacement claims (Agent Skills / SKILL.md)
npx -y skills add carrick87/ot-leave-claimAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- 18 days oldThe repository was created 18 days ago. New is not bad, but a brand new repository carrying a familiar-sounding name is the shape a typosquat arrives in, and there has been no time for anyone else to find a problem with it.
- 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Calculates outside-working-hours overtime from Cursor agent activity and git commit times for leave-replacement claims. Use when the user asks for OT hours, overtime summary, leave replacement, work outside office hours, or to claim OT from Cursor/GitHub activity.
The file declares its own license as MIT. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.
SKILL.md
7.9 KB, ~1.9k tokens by cl100k_base, as published. Nobody here has run it
OT leave claim
Goal
Produce a leave-replacement claim summary for time worked outside office hours, using:
- User-supplied start time (required)
- OT reason — why the outside-hours work was needed (required for final claim)
- Git commit timestamps in the active repo
- Cursor agent transcript activity for the current workspace
Never emit the final claim until the user confirms (or adjusts) the proposed hours.
Office hours (defaults)
| Setting | Value |
|---|---|
| Timezone | Asia/Singapore (UTC+8) |
| Weekdays | Mon–Fri 08:00–16:45 = normal hours |
| Outside hours | Before 08:00, after 16:45, or all day Sat/Sun |
| Public holidays | Treat as outside hours only if the user says so |
Override timezone only when the user says otherwise.
Triggers
Apply when the user says any of:
- OT / overtime / OT hours / overtime summary
- leave replacement / claim OT / claim leave replacement
- work outside office hours / outside working time
- OT from Cursor / GitHub activity
Workflow
flowchart TD
trigger[User runs OT leave claim]
askStart{Start time given?}
promptStart[Ask for start time]
gather[Gather git commits and Cursor transcripts]
clip[Clip to outside office hours]
propose[Propose OT ranges and hours]
confirm[User confirms or adjusts]
tasks[Task description per OT range]
summary[Final leave-replacement claim]
trigger --> askStart
askStart -->|no| promptStart --> gather
askStart -->|yes| gather --> clip --> propose --> confirm --> tasks --> summary
Copy this checklist and track progress:
OT claim progress:
- [ ] Step 1: Start time confirmed
- [ ] Step 2: Evidence gathered
- [ ] Step 3: Proposal shown (not final)
- [ ] Step 4: Hours confirmed by user
- [ ] Step 5: Task descriptions per range
- [ ] Step 6: OT reason confirmed (rephrase if needed)
- [ ] Step 7: Final claim summary output
Step 1 — Start time (required)
If the user did not specify a start time, stop and ask:
What is the start time for this OT claim? (e.g.
2026-07-18 18:00ortoday 6pm)
Do not gather evidence until start time is known.
Parse relative forms (today 6pm, yesterday 19:30) in Asia/Singapore unless told otherwise.
End time default: latest evidence at or after start (see Step 3). User may override when confirming.
OT reason (overall why for the leave-replacement request):
-
If the user already gave a reason, rephrase it into clear, professional claim wording (fix grammar; keep their meaning).
-
If missing by confirmation time, ask:
What is the OT / leave-replacement reason? (e.g. urgent post-rollout bug fixes after Friday training)
-
One overall OT reason for the claim (not per range). Task descriptions stay per range.
Step 2 — Gather evidence
From the active git repo (cwd / workspace root):
Commits (author = current user):
git log --since="<START_ISO>" --until="<END_OR_NOW>" \
--author="$(git config user.email)" \
--pretty=format:"%h|%ad|%s" --date=iso
If user.email is empty, try --author="$(git config user.name)". If still empty, use unfiltered local log and note that in the justification.
Cursor activity:
- Resolve the workspace’s agent-transcripts folder under
~/.cursor/projects/<project-slug>/agent-transcripts/(match the current workspace path). - Prefer transcripts with activity at or after start (file mtime and/or
<timestamp>...lines inside.jsonl). - From user queries / assistant work, draft short notes for task descriptions later.
Also note the repo name / path in the claim (which app was worked on).
Step 3 — Propose OT (not final)
Default calculation:
- Build a timeline of evidence from start → now (or user-given end).
- Suggested end = last evidence timestamp at or after start.
- Suggested OT = intersection of
[start, end]with outside office hours only.- Fri 18:00 → last commit 22:00 → propose 4.0h (all outside).
- Fri 16:00 → last commit 19:00 → propose 2.25h (16:45–19:00 only; drop 16:00–16:45).
- If gaps look large, still propose the simple span, but call out the gap so the user can trim.
- Round each range to nearest 0.25h (15 min) unless the user specifies otherwise when confirming.
If the window crosses midnight or multiple days, split into one range per calendar day (or per discontinuous block) so each can get its own task description.
Present a Proposal block only:
## OT proposal (awaiting confirmation)
**Claim window start:** <start>
**Suggested end:** <end> (last evidence: <source>)
**Timezone:** Asia/Singapore (UTC+8)
### Proposed ranges
| # | Date | Start | End | Hours |
|---|------|-------|-----|-------|
| 1 | ... | ... | ... | ... |
**Proposed total:** Xh
### Evidence
- Commits: ...
- Cursor sessions: ...
### Draft OT reason
<rephrased reason if user already gave one; otherwise “pending”>
### Justification
...
Confirm these hours, or tell me the adjusted total / ranges.
Hard stop: do not print the final claim template until the user confirms or adjusts.
Step 4 — Confirm hours + task descriptions + OT reason
- Apply the user’s confirmation or adjustments (totals and/or per-range times).
- For each confirmed OT range, require a task description.
- Draft from commits + Cursor transcripts.
- Ask the user to approve or edit if draft is unclear.
- Confirm OT reason:
- Rephrase the user’s wording into a short professional sentence (or 2).
- Show the rephrased reason and use it unless they edit it.
- Do not finalize with empty task descriptions or a missing OT reason.
Step 5 — Final claim summary
Output this copy-paste friendly report:
# Leave Replacement Claim — Outside Working Hours
**Timezone:** Asia/Singapore (UTC+8)
**Office hours:** Mon–Fri 08:00–16:45
**Claim window start:** <user start>
**Generated:** <now>
**Repo / app:** <name>
## Summary
- Total OT claimed: **Xh**
- Leave replacement days: **Zd** (`Xh ÷ 8.75`)
- Confirmed by user: yes
## OT reason
<professional rephrased reason for this leave-replacement request>
## Leave replacement days
- Standard working day: **8.75h** (Mon–Fri 08:00–16:45)
- Calculation: `Xh ÷ 8.75 = Y` → claim **Zd** leave replacement
- Round to nearest **0.5 day** unless the user specifies otherwise
## OT ranges
| # | Date | Start | End | Hours | Task description |
|---|------|-------|-----|-------|------------------|
| 1 | ... | ... | ... | ... | ... |
## Evidence (supporting)
- Commits: ...
- Cursor sessions: ...
## Justification
...
Always include OT reason and the leave-day conversion in the final summary. Formula: OT hours ÷ 8.75, round to nearest 0.5 day.
Saving to disk is optional: only if the user asks, write ~/Desktop/ot-claims/YYYY-MM-DD.md (create the folder if needed). Default is chat-only.
Rules of thumb
- Never invent commits or Cursor sessions; if evidence is thin, say so and let the user set hours.
- Normal office hours never count toward the claim.
- Propose first, confirm second, claim last.
- Always include a clear OT reason; rephrase user notes into professional claim language.
- Convert confirmed OT hours to leave-replacement days: hours ÷ 8.75, nearest 0.5 day.
- Keep task descriptions concrete (feature/bug/repo work), not vague (“worked on app”).
Examples
See examples.md for weekday evening and weekend sample flows.
What ships with it: 3 files
11.9 KB alongside SKILL.md
- examples.md3.1 KB
- LICENSE1.0 KB
- README.md7.7 KB