read_daily_note_section
Extract specific sections like Notes or Tasks from daily notes to quickly access organized information without reading entire documents.
Instructions
Read a specific section from the daily note.
Use this to read any section by name, such as "Notes", "Tasks", "Focus for Today", etc.
Args: date_str: Optional date in YYYY-MM-DD format (defaults to today) section: Name of the section to read (without ## or emoji)
Returns: Content of that section
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| date_str | No | ||
| section | No | Notes |
Implementation Reference
- src/coach_ai/daily_notes.py:461-488 (handler)The implementation of the logic to read a daily note section.
async def read_daily_note_section(date_str: str = None, section: str = "Notes") -> str: """Read a specific section from the daily note. Args: date_str: Optional date in YYYY-MM-DD format (defaults to today) section: Name of the section to read Returns: Content of that section """ 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() section_content = vault.read_section(date, section) if section_content is None: return f"❌ Section '{section}' not found in daily note for {date.strftime('%Y-%m-%d')}." return f"## {section}\n\n{section_content}" - src/coach_ai/server.py:739-753 (registration)The tool registration using the @mcp.tool() decorator.
@mcp.tool() async def read_daily_note_section(date_str: str = None, section: str = "Notes") -> str: """Read a specific section from the daily note. Use this to read any section by name, such as "Notes", "Tasks", "Focus for Today", etc. Args: date_str: Optional date in YYYY-MM-DD format (defaults to today) section: Name of the section to read (without ## or emoji) Returns: Content of that section """ return await daily_notes.read_daily_note_section(date_str, section)