Skip to main content
Glama

reflect

Read-only
Reflect on recent thoughts and patterns.

Analyzes recent activity to identify patterns, topics, and insights.
Useful for understanding "what have I been thinking about?"

By default, only returns user-created memories (not document chunks).
Set include_documents=True to also include chunks from uploaded documents.

⚠️ EXPERIMENTAL:
- Importance weighting in results not yet implemented. Importance scores are stored but don't affect ranking.

Args:
    time_window: Time period to analyze ('recent', 'today', 'week', 'month', '1d', '7d', '30d', '90d')
    include_documents: Whether to include document chunks (default: False, only user memories)
    start_date: Filter memories created on or after this date (ISO 8601: '2025-01-01' or '2025-01-01T00:00:00Z')
    end_date: Filter memories created on or before this date (ISO 8601: '2025-01-09' or '2025-01-09T23:59:59Z')
    ctx: MCP context (automatically provided)

Returns:
    Dict with analysis including top memories, active topics, patterns,
    insights, and any saved contexts (checkpoints) created in the window.

Examples:
    >>> await reflect("recent")
    {'success': True, 'memories_analyzed': 50, 'active_topics': [...], 'contexts': [...], ...}

    >>> await reflect("week", include_documents=True)
    {'success': True, 'memories_analyzed': 150, ...}  # includes document chunks

    >>> await reflect(start_date="2025-01-01", end_date="2025-01-07")
    {'success': True, 'memories_analyzed': 25, ...}  # memories from first week of January

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
end_dateNo
start_dateNo
time_windowNorecent
include_documentsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

The description goes beyond annotations by disclosing experimental status and a missing feature ('Importance weighting in results not yet implemented'). It also explains the default exclusion of document chunks. The annotations already indicate read-only and open-world behavior, but the description adds valuable context about limitations.

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?

The description is well-structured with sections for overview, experimental warning, args, returns, and examples. While it is relatively long, every sentence adds value. It could be slightly more concise by removing the redundant 'Args:' label, but overall it is efficient.

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?

Given the output schema exists, the description adequately describes the return value as a dict with 'top memories, active topics, patterns, insights, and any saved contexts'. It covers all parameters with examples, and the experimental note adds necessary caveats. It is complete for a tool of this complexity.

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

Parameters5/5

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

Despite 0% schema description coverage, the description thoroughly explains all four parameters: time_window (with valid values), include_documents (boolean, default false), and start_date/end_date (ISO 8601 format with examples). It also shows usage in examples, fully compensating for the missing schema descriptions.

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?

The description clearly states the tool's purpose: 'Reflect on recent thoughts and patterns' and 'Analyzes recent activity to identify patterns, topics, and insights.' It specifies the resource (user memories and optionally document chunks) and the action (analysis), distinguishing it from sibling tools like 'recall' or 'search' which focus on retrieval.

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?

The description provides explicit usage context: 'Useful for understanding what have I been thinking about?' It explains default behavior and how to include documents with the 'include_documents' parameter. While it doesn't explicitly state when not to use the tool or list alternatives, the context and examples give clear guidance.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.