Skip to main content

Module save

Module save 

Source
Expand description

Turning an ask Turn into a saved vault note (CONTEXT.md: Saved answer). The question becomes the note title, its citation markers become wikilinks so the note joins the vault link graph.

Functions§

citation_names
The clean source names addressed by citation number: names[n - 1] is the clean name of the source whose ordinal is n, so link_sources can rewrite [n][[name]] by the same explicit pairing the rest of Ask uses. The vec is sized to the largest ordinal; a citation number with no backing source (a gap) gets an empty-string sentinel link_sources treats as out-of-range, leaving that [n] untouched. This is the ONE place the ordinal→name mapping is built for saving — never sources[n - 1].
note_content
Renders turn as note content: the question as an # title, the answer with citation markers converted to [[source]] wikilinks, and a ## Sources footer.
suggested_path
The default path offered when saving question as a note: ask/<slug>.md.