Auto-initialize field values

Wouldn't it be great if Tana could automatically fill out fields for you, so you wouldn't have to? In some cases, that's possible. Fields can auto fill values, so you can specify how their content should be autofilled when a supertag is added to a node.

Fields can have Initialize Functions which specify how their content should be autofilled when a supertag is added to a node.

This is different from default values of fields, because the fields can be filled out based on the context of their creation - when they were created, where in the graph they were created, who created them, etc.

A couple of things to keep in mind:

  • Initialization expressions are convenience functions, but are not live updating. So they won't change any prior field values from before you created the initialization functions, and you can change them after Tana fills a field if they need a manual touch.

  • This is only triggered for fields that are part of a Supertag template, not for fields that you use otherwise.

  • Initialization is only triggered when a node gets the supertag applied to it. If the supertag gets updated with a field with initialization switched on, and the supertag was already applied to nodes, these nodes will only see the field added without any content initialized in it.

Initialization expressionsDescriptionExample Use CasesRelevant field types
Auto-initialize to value from ancestor field
Get the field values from an identical field on a node nested above
You could have a #quote tag with an Author field, and it could automatically initialize with the value from the Author field of the #book that it is nested underneath.
You could have a "Related Project" field for your tasks, and then any nested subtasks would automatically have the same related project.
All
Auto-initialize to ancestor with this supertag
Get a reference to a node nested above with this tag
You could have a #quote tag with a Source field, which is an instance of #source. If you tag a #quote nested underneath a #source node, this function would auto-populate the field accordingly.
Instance
Auto-initialize to random node from this supertag
Get a reference to a random node with this supertag.
You could have #JournalingPrompts and have three show up in a "Today's Prompts" field in your #Journal nodes.
Instance
Auto-initialize to current date
Sets the value of the field to today's date. Will show up in the backlinks for your today node.
Date
Auto-initialize to date of ancestor day node
Sets the value of the field to the day node that the tagged node is written in
In your daily node for next Tuesday, you tag a meeting. A date field with this initialization expression would be set to next Tuesday.
Date
Auto-initialize to current user
Sets the value of the field to a reference to the current user who tagged the node
User

This video explains how to use these three functions

Related content