We switched to a manual approval system for registration on this forum, as this makes it easier to keep bots out of the forum. We'll approve everybody who doesn't look like a bot!

Define & use custom keys in YAML Frontmatter as global Filters

This is a carryover from https://github.com/Zettlr/Zettlr/issues/582

Idea

Now as I am addicted to YAML Frontmatters to enritch my documents with metadata I feel the need for a cutomizable Filter (like the tag cloud) for predefinable keys like "status", "authors", "workflowtarget", "categories", "priority" etc..

This could be an example YAML Frontmatter (with comments)
.---
title: Why capitalism drives you crazy # this is already recognized by the filter
authors: [Gilles Deleuze, Félix Guattari] # a list of authors
id: 20200306100138 # this is of course recognized as the ID of the document
keywords: [#capitalism, #schizophrenia] # already recognized as tags
type: presentation
status: wip
workflowtarget: felix
priority: 3
deadline: 2020-04-02
abstract: some short optional descripion
.---

usecase

Imagine you are working as a team (gilles+felix+theodor) with synchronized folders or you have a lot to remember/forget this could be immense helpful. If I were felix, I could check "tasks" associated to me as workflowtarget and then check for the important stuff (priority) witch has the status "work in progress" (wip).
Adding a customizable filter for structured metadata would expand the possibilities to manage your files and tasks because you can add any possible "Order of Things" to your documents. If you want to build a simple "ticket system" to organize your collaborative writing within groups or you feel the need to pimp up your Zettelkasten with some additional meta-structures you are good to go.
Of course (in the future) there could be demands like the combination of multiple searches (e.g. workflowtarget + status) or the handling of numerical values and dates (e.g. deadline < 2020-04-02) but a first implementation working like the tag filter would also be a huge improvement.

interface

  • In order to use these keys they have to be defined in the preferences (key, label, optional description). This could be done in a similar way as defining colors for keywords.
  • additionally to the tag cloud you have a dropdown for custom filters and a list (in future versions of the UI) or a "tag cloud" of all values associated to this key, but I am not sure about this part of the interface especially when it comes to future demands.
Tagged:

Comments

  • I did a little bit further research on this topic:

    In my opinion the handling of tasks should be done in a separate application like Imdone because you will need a genuine interface for that. Like Zettlr Imdone is watching your working directory but is looking for special TODO blocks in your content. So if you have a document representing a task itself or multiple tasks within your minutes of an meeting or even comments within your PhD Thesis - it could be handeled as a task.

    But besides of these pre-defined mechanisms and tools to order/find/process things, everyone has slightly different needs & strategies to manage his/hers stuff resulting in different needs for meta informations. While Tags are fine and Ontologies are overrated in most cases, the possibility for filtering your documents by some additional custom features is often very helpful especially to avoid the mixup/"misuse" of tags. Also in my opinion this should not be done outside of your working environment/editor to avoid distractions.

    As far as I have seen, ATM there is a predefined set of Frontmatter keys but i wasn´t able to understand the logic behind

    const FRONTMATTER_VARS = [ 'title','subtitle','author','date','keywords','lang']

  • As far as I have seen, ATM there is a predefined set of Frontmatter keys but i wasn´t able to understand the logic behind

    Have a look at the comment above the definition:

    // This is a list of all possible Pandoc Frontmatter
    // variables that Zettlr may make use of
    

    These are, in short, variables accepted by Pandoc that you can make use of in your frontmatter, of which some are already being used by Zettlr (title + keywords), and some as of now not, but may be in the future.

Sign In or Register to comment.