Skip to main content
Glama

add_daily_note_section

Add a structured section to your daily note with custom headings and content to organize thoughts, tasks, or reflections for ADHD productivity management.

Instructions

Add a new section to the daily note.

Creates a new section with a heading and initial content.

Args: section_name: Name for the new section content: Initial content for the section date_str: Optional date in YYYY-MM-DD format (defaults to today) emoji: Optional emoji to prefix the section heading (e.g., "📊", "💡")

Returns: Confirmation message

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
section_nameYes
contentYes
date_strNo
emojiNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • Actual implementation of the tool logic.
    async def add_daily_note_section(
        section_name: str, content: str, date_str: str = None, emoji: str = ""
    ) -> str:
        """Add a new section to the daily note.
    
        Args:
            section_name: Name for the new section
            content: Initial content for the section
            date_str: Optional date in YYYY-MM-DD format (defaults to today)
            emoji: Optional emoji to prefix the section heading
    
        Returns:
            Confirmation message
        """
        vault = get_vault()
        if not vault:
            return "❌ Obsidian vault not configured."
    
        if date_str:
            try:
                date = datetime.strptime(date_str, "%Y-%m-%d")
            except ValueError:
                return f"❌ Invalid date format: {date_str}"
        else:
            date = datetime.now()
    
        success = vault.add_section(date, section_name, content, emoji=emoji)
    
        if not success:
            return f"❌ Failed to add section '{section_name}'. Daily note may not exist."
    
        return f"✅ Added new section '{section_name}' to daily note for {date.strftime('%Y-%m-%d')}."
  • MCP tool registration and wrapper that calls the handler.
    @mcp.tool()
    async def add_daily_note_section(
        section_name: str, content: str, date_str: str = None, emoji: str = ""
    ) -> str:
        """Add a new section to the daily note.
    
        Creates a new section with a heading and initial content.
    
        Args:
            section_name: Name for the new section
            content: Initial content for the section
            date_str: Optional date in YYYY-MM-DD format (defaults to today)
            emoji: Optional emoji to prefix the section heading (e.g., "📊", "💡")
    
        Returns:
            Confirmation message
        """
        return await daily_notes.add_daily_note_section(section_name, content, date_str, emoji)
Behavior2/5

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

With no annotations provided, the description carries the full burden but offers minimal behavioral context. It states the tool creates a section but does not specify what happens if the section already exists (error, overwrite, or append), whether the operation is idempotent, or any side effects beyond returning a 'Confirmation message'.

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 docstring format with Args/Returns sections is structured and scannable. The first sentence provides immediate clarity. While the Args/Returns headers add slight verbosity, they effectively organize information given the lack of schema descriptions. No extraneous sentences are present.

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

Completeness3/5

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

For a 4-parameter tool with zero schema descriptions and no annotations, the description adequately covers parameter semantics and return type. However, it lacks critical context regarding error conditions (duplicate sections, missing daily note) and fails to clarify the relationship with similar sibling tools, leaving operational gaps.

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

Parameters4/5

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

Given 0% schema description coverage, the description effectively compensates by documenting all four parameters in the Args section: 'section_name' purpose, 'content' as initial content, 'date_str' format (YYYY-MM-DD) and default behavior, and 'emoji' with clear examples. This provides necessary semantic context missing from the schema.

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

Purpose4/5

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

The description clearly states the tool 'Add[s] a new section to the daily note' with specific verb (Add/Creates) and resource (section). However, it does not differentiate from the sibling tool 'write_daily_note_section', leaving ambiguity about whether this tool appends to existing sections or strictly creates new ones.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus alternatives like 'write_daily_note_section' or 'create_daily_note'. There is no mention of prerequisites (e.g., whether the daily note must exist first) or conditions that would trigger selection of this specific tool.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/94aharris/coach-ai'

If you have feedback or need assistance with the MCP directory API, please join our Discord server