Skip to content

System prompt: include actual date/time instead of just timezone #7650

@darinkishore

Description

@darinkishore

Problem

The buildTimeSection function in the system prompt only included the timezone, not the actual date/time:

## Current Date & Time
Time zone: America/Los_Angeles
If you need the current date, time, or day of week, use the session_status tool.

This is confusing because:

  1. The section is titled "Current Date & Time" but doesn't include either
  2. Agents shouldn't need to make an extra tool call just to know what day it is

Fix Applied

Updated buildTimeSection to generate the actual formatted date/time:

## Current Date & Time
Sunday, February 2, 2026, 6:47 PM (America/Los_Angeles)

Trade-off

This does affect prompt cache stability (previously noted in commit 66eec29). However, having agents always know the current date/time without a tool call is more valuable than the cache hit rate improvement.

Related Issues

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions