// claude code add-on

Observer

Claude doesn't know what day it is. Observer fixes that.

// for laypeople

Claude — even running locally as a coding agent — doesn't know what day it is, what time it is, or which timezone you're in. Out of the box, it gets one line: today's date. No day-of-week, no time, no week boundaries, no TZ. Ask "what was last Monday?" and it guesses.

Observer fixes that. It runs once when Claude starts up and feeds the real answers in: the date, the day, the time, the timezone, the start and end of this week, last week, and next week. Claude just reads them. No guessing.

One shell script. 60-second install. Drops onto whatever Claude Code setup you already have.

// for builders

A SessionStart hook (Claude Code's built-in hook event for session-open) prints a datetime block to stdout. Stdout from a SessionStart hook is injected as system context before the first user prompt. The model sees real ground truth before it answers anything.

=== Datetime context (Observer — auto-injected at session start) ===
Now:        Monday May 04 2026 14:32 BST (UTC+0100)
ISO:        2026-05-04T14:32:00+0100
Today:      2026-05-04 (Monday)
Yesterday:  2026-05-03 (Sunday)
Tomorrow:   2026-05-05 (Tuesday)
This week:  Mon 2026-05-04 – Sun 2026-05-10
Last week:  Mon 2026-04-27 – Sun 2026-05-03
Next week:  Mon 2026-05-11 – Sun 2026-05-17
This month: 2026-05 (May)
====================================================================

Implementation: macOS date -v for week-boundary math (-v-mon walks back to Monday, -v+sun walks forward to Sunday). Wired in via ~/.claude/settings.jsonhooks.SessionStart. Layers on top of existing hooks — additive, no replacement. macOS only in v1; Linux/Windows variants welcome as PRs.

Optional: an MCP time server (mcp-server-time via uvx) for on-demand timezone math mid-session. The hook covers 95% of cases without it.

Repo: github.com/ultrawinning/claude-observer · License: MIT