KIMI_NOW timestamp splits the system prompt into two injectable payload blocks
Summary
The system prompt template inserts a dynamic KIMI_NOW timestamp (plus a self-referential explanation) at line 89, roughly in the middle of the message. This timestamp is not a static instruction; it is dynamic content that changes every turn. Its placement has two negative effects:
- It physically splits the core system instructions into two large blocks of mutable context.
- It makes the entire system message non-cacheable, because the timestamp changes every request.
This is a design/structural issue, not just a wording bug.
Observed structure
Based on local inspection of the system prompt template:
| Region |
Lines |
Content |
Approximate size |
| Before timestamp |
1–88 |
Role definition, behavior rules, OS/shell context |
12,730 B (61%) |
| Timestamp line |
89 |
KIMI_NOW + explanatory text (e.g. “do not fully trust me”) |
~500 B |
| After timestamp |
90–158 |
Template tail, WORK_DIR, directory tree, extra directories, AGENTS_MD, SKILLS |
7,508 B (36%) |
The timestamp is therefore the largest single dynamic injection point in the message, and it separates two other large mutable regions (the role block and the environment block).
Why this is a problem
1. It breaks the continuity of system instructions
A model normally receives system instructions as a coherent block at the top of the context. By placing a dynamic timestamp and meta-commentary in the middle, the system prompt becomes:
[Trusted static rules] ... [DYNAMIC TIMESTAMP] ... [Mutable workspace data]
When the mutable workspace data (directory tree, AGENTS.md, skills listing) is poisoned, the model has to decide which text is the "real" system instruction. The timestamp acts as a natural boundary that makes the trailing 7.5 KB look like an independent, possibly authoritative system context.
2. It turns the static role block into a silent payload carrier
The pre-timestamp block (12.7 KB) contains role definitions, behavior rules, and environment context. Because it is positioned before the timestamp, it looks like "the real system prompt". If an attacker can inject content into that region (for example via environment variables, OS shell context, or a long project path), it is treated as core instruction rather than external context.
3. It prevents system prompt caching
Any content that changes every turn invalidates prompt caching. If KIMI_NOW is rendered into the system prompt, the entire system prompt must be re-encoded on every request, even when the workspace, skills, and AGENTS.md have not changed. This directly contributes to the large baseline token counts reported in #1955.
Suggested fixes
-
Move KIMI_NOW out of the system prompt entirely.
The current time should be provided as a tool result or as a short user/system preamble at the end of the context, not inserted into the middle of core instructions.
-
If it must stay in the system prompt, place it at the very end.
Putting the timestamp at the end preserves the continuity of the static system rules and prevents it from acting as a divider between two large mutable blocks.
-
Wrap the post-timestamp workspace data as untrusted context.
AGENTS.md, directory tree, skills, and MCP tool descriptions should be explicitly labeled as external, workspace-provided content rather than system instruction.
-
Split the system prompt into a static cached prefix and a dynamic suffix.
Keep role/behavior rules in a fixed, cacheable system message; put dynamic environment data in a separate message or context block.
Related issues
Environment
This is an architecture-level issue in how the system prompt is assembled. It is independent of the model provider or operating system.
KIMI_NOW timestamp splits the system prompt into two injectable payload blocks
Summary
The system prompt template inserts a dynamic
KIMI_NOWtimestamp (plus a self-referential explanation) at line 89, roughly in the middle of the message. This timestamp is not a static instruction; it is dynamic content that changes every turn. Its placement has two negative effects:This is a design/structural issue, not just a wording bug.
Observed structure
Based on local inspection of the system prompt template:
KIMI_NOW+ explanatory text (e.g. “do not fully trust me”)WORK_DIR, directory tree, extra directories,AGENTS_MD,SKILLSThe timestamp is therefore the largest single dynamic injection point in the message, and it separates two other large mutable regions (the role block and the environment block).
Why this is a problem
1. It breaks the continuity of system instructions
A model normally receives system instructions as a coherent block at the top of the context. By placing a dynamic timestamp and meta-commentary in the middle, the system prompt becomes:
When the mutable workspace data (directory tree,
AGENTS.md, skills listing) is poisoned, the model has to decide which text is the "real" system instruction. The timestamp acts as a natural boundary that makes the trailing 7.5 KB look like an independent, possibly authoritative system context.2. It turns the static role block into a silent payload carrier
The pre-timestamp block (12.7 KB) contains role definitions, behavior rules, and environment context. Because it is positioned before the timestamp, it looks like "the real system prompt". If an attacker can inject content into that region (for example via environment variables, OS shell context, or a long project path), it is treated as core instruction rather than external context.
3. It prevents system prompt caching
Any content that changes every turn invalidates prompt caching. If
KIMI_NOWis rendered into the system prompt, the entire system prompt must be re-encoded on every request, even when the workspace, skills, and AGENTS.md have not changed. This directly contributes to the large baseline token counts reported in #1955.Suggested fixes
Move
KIMI_NOWout of the system prompt entirely.The current time should be provided as a tool result or as a short user/system preamble at the end of the context, not inserted into the middle of core instructions.
If it must stay in the system prompt, place it at the very end.
Putting the timestamp at the end preserves the continuity of the static system rules and prevents it from acting as a divider between two large mutable blocks.
Wrap the post-timestamp workspace data as untrusted context.
AGENTS.md, directory tree, skills, and MCP tool descriptions should be explicitly labeled as external, workspace-provided content rather than system instruction.Split the system prompt into a static cached prefix and a dynamic suffix.
Keep role/behavior rules in a fixed, cacheable system message; put dynamic environment data in a separate message or context block.
Related issues
/contextbreakdown to show the always-sent baseline compositionEnvironment
This is an architecture-level issue in how the system prompt is assembled. It is independent of the model provider or operating system.