Skip to content

Auto-sync entity created_at / updated_at timestamps into frontmatter #684

@bm-clawd

Description

@bm-clawd

Currently, Basic Memory tracks created_at and updated_at timestamps at the entity level (visible in JSON output via API/MCP), but these timestamps don't appear in the markdown files themselves.

Current behavior:

  • Entity timestamps exist in the database
  • They're accessible via JSON output
  • Frontmatter doesn't include them unless manually written/maintained

Desired behavior:

  • BM automatically writes created_at and updated_at into YAML frontmatter when creating/updating notes
  • These fields would be managed by BM itself (not AI/user-maintained)
  • Timestamps would be visible in the plain-text files, not just the database

Use cases:

  • Consistent timestamp metadata across all notes without manual maintenance
  • Temporal queries/filters based on frontmatter (e.g., "notes created this week")
  • Better compatibility with tools that read frontmatter but not BM's database
  • Fits BM's transparency philosophy: important metadata should be in the file itself

Suggested implementation:

  • Auto-inject created_at on note creation
  • Auto-update updated_at on note modification
  • Make these "reserved" frontmatter fields (schema validation aware, but not user-editable)
  • Respect existing timestamps if already present (don't overwrite manual entries)

Related:

  • Picoschema metadata: section could declare these as system-managed fields
  • Would complement existing frontmatter features (status, tags, priority)

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs investigationIssue needs further investigation and/or refinement

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions