Skip to main content
Glama

draft_month

Drafts a read-only monthly timesheet from git commit messages into a JSON file, maps weekday commits to 8-hour entries, and returns gaps for review before applying.

Instructions

Draft a timesheet from git commit messages (read-only, touches no eHour page). One entry per weekday in the range, 8h each: "[8] TICKET: Title" then " - bullet" lines from the commit subjects, ASCII-only. Weekend commits move to the nearest empty weekday. Writes the entries JSON to file and returns only a summary { file, days: [{ date, tickets, chars }], moved, gaps }. Read the file, shorten each comment to 1-3 outcome bullets per ticket, fill every gap (a gap has an empty comment and is rejected by apply_month), then show the month to the user.

Input Schema

NameRequiredDescriptionDefault
toYes
fromYes
repoNoGit repository to read; defaults to gitRepo from ehour.config.json.
authorNogit --author filter; defaults to the repo user.name.
outFileNoWhere to write the draft; defaults to drafts/<from>_<to>.json in this repo.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.4/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does so: read-only, no eHour mutation, writes entries JSON to a file and returns only a summary object with a named shape. It also discloses subtle behaviors — weekend commits moved to the nearest empty weekday, ASCII-only output, gaps having empty comments that apply_month will reject.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action and the read-only guarantee, then tight supporting detail. It runs long because it packs in format rules, return shape and a workflow, but nearly every clause carries information; the `file`/`outFile` naming slip is the main blemish.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, yet the description names the exact return object fields and explains that the entries themselves are only in the written file, which is the critical thing an agent needs. It also completes the loop by describing the edit-then-apply workflow and the gap-rejection constraint.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 60%, with repo/author/outFile already documented inline. The description adds range semantics ('one entry per weekday in the range') but calls the output parameter `file` while the schema names it `outFile`, and says nothing extra about repo or author defaults. Roughly a baseline-plus score.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource — 'Draft a timesheet from git commit messages' — plus the source of truth (git commits) and the shape of the generated entries. It implicitly separates itself from the eHour-writing siblings by calling itself read-only and naming apply_month as the downstream consumer.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly frames the tool as a read-only drafting step that 'touches no eHour page' and gives a follow-on workflow: read the file, shorten comments, fill gaps, then show the month to the user. It doesn't state when to skip it entirely (e.g. no commits in range), but the context is clear enough to act on.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.