Issue: Obsidian YAML Frontmatter Tag Compatibility
Problem
Our current frontmatter logic adds tags using JSON array syntax:
tags: ["tag1", "tag2", "tag3"]
While this is valid YAML, it makes Obsidian unhappy and doesn't follow Obsidian's preferred conventions for YAML frontmatter tags.
Expected Behavior
Obsidian prefers tags in YAML frontmatter to be formatted using one of these standard YAML list formats:
Option 1: YAML List Format (Recommended)
tags:
- tag1
- tag2
- tag3
Option 2: YAML Array Format (Alternative)
Note: The unquoted format is preferred as it's cleaner and more aligned with Obsidian community conventions.
Current Impact
- ✅ Tags work functionally in Basic Memory
- ❌ Tags appear with JSON-style quotes in Obsidian
- ❌ May cause visual/parsing issues in Obsidian's property editor
- ❌ Doesn't follow Obsidian community best practices
References
Proposed Solution
Update the frontmatter generation in Basic Memory to use the YAML list format:
- Modify tag serialization in markdown generation
- Use unquoted strings for tag values (when they don't contain special characters)
- Use YAML list syntax with dashes instead of JSON array syntax
- Maintain backward compatibility for reading existing files
Implementation Areas
The changes would likely be needed in:
src/basic_memory/markdown/ - Markdown generation and frontmatter handling
src/basic_memory/services/entity_service.py - Entity creation with frontmatter
- Tests to verify the new format works correctly
Acceptance Criteria
Priority
Medium - Improves compatibility with a major tool in the knowledge management ecosystem, but doesn't break core functionality.
Labels
enhancement
compatibility
obsidian
yaml
frontmatter
Issue: Obsidian YAML Frontmatter Tag Compatibility
Problem
Our current frontmatter logic adds tags using JSON array syntax:
While this is valid YAML, it makes Obsidian unhappy and doesn't follow Obsidian's preferred conventions for YAML frontmatter tags.
Expected Behavior
Obsidian prefers tags in YAML frontmatter to be formatted using one of these standard YAML list formats:
Option 1: YAML List Format (Recommended)
Option 2: YAML Array Format (Alternative)
Note: The unquoted format is preferred as it's cleaner and more aligned with Obsidian community conventions.
Current Impact
References
Proposed Solution
Update the frontmatter generation in Basic Memory to use the YAML list format:
Implementation Areas
The changes would likely be needed in:
src/basic_memory/markdown/- Markdown generation and frontmatter handlingsrc/basic_memory/services/entity_service.py- Entity creation with frontmatterAcceptance Criteria
- tag) instead of JSON array syntax (["tag"])Priority
Medium - Improves compatibility with a major tool in the knowledge management ecosystem, but doesn't break core functionality.
Labels
enhancementcompatibilityobsidianyamlfrontmatter