Novelcrafter

Prompt Functions

Get an overview of all prompt function inside Novelcrafter and how to use them in your own custom prompts.

Acts

act

Extracts all possible ‘Acts’ from the given arguments. Defaults to the current Act, if no arguments are given.

act(...elements) List[Act]

Arguments

One or more items to extract Acts from. If omitted, returns the current Act in scope.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

All the acts that can be extracted from the given arguments, sorted by their order in the novel.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Act

act.fullText

Returns the full text of each ‘Act’ in the given arguments (or the current Act if none are provided).

act.fullText(...elements) List[Text Container]

Arguments

The Acts to extract from.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

A list of text containers, each containing the full text of any acts that can be extracted from the given arguments. The list is also sorted by their order in the manuscript.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Title

The full title of the act (e.g. "Act 1", "Act 2: The Return" or "Prologue").

Content

The full text of the act as written in your manuscript.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Related:

act.name

Returns the custom name of each ‘Act’ in the given arguments (or the current Act if none are provided).

act.name(...elements) List[Text Container]

Arguments

The Acts to collect.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

A list of text containers, each containing the name of any acts that can be extracted from the given arguments.

Acts without a custom name will be skipped.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Title

The custom name of the act (e.g. "Prologue", "The Return").

Reference

Act

The act that this name belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Related:

act.next

Returns the immediately following 'Act' for each possible 'Act' in the given arguments (or the current Act if none are provided).

act.next(...elements) List[Act]

Arguments

A list of acts. If not provided, the current act is used to find its successor.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Act

The following acts.

Related:

act.number

Returns the number of each 'Act' in the given arguments (or the current Act if none are provided).

act.number(...elements) List[Text Container]

Arguments

One or more Acts to get the numbers of. If omitted, uses the current Act in scope.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

A text container holding the number of an Act.

Title

The number of the Act.

Attributes

number

The number of the Act.

Reference

Act

The Act this number belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Examples

To get the number of the current act:

Instructions
{act.number}
Output
2

To get the act numbers of all acts in the story so far:

Instructions
{act.number(storySoFar)}
Output
1, 2, 3
Related:

act.previous

Returns the immediately preceding 'Act' for each possible 'Act' in the given arguments (or the current Act if none are provided).

act.previous(...elements) List[Act]

Arguments

A list of acts. If not provided, the current act is used to find its predecessor.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Act

The preceding act for each possible act.

Related:

act.summary

Returns a summary of each 'Act' in the given arguments (or the current Act if none are provided).

act.summary(...elements) List[Outline]

Arguments

One or more items to extract Acts from. If omitted, returns the current Act in scope.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

A list of outlines, one for each Act, containing their summaries.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Outline

The Act this outline was created from.

Mode

Summaries

The outline will be rendered using the summaries of each contained scene.

Reference

Novel

The novel this outline was created from (defaults to the current novel)

Related:

act.title

Returns the full title for each possible 'Act' in the given arguments (or the current Act if none are provided).

act.title(...elements) List[Text Container]

Arguments

One or more Acts to get the titles for. If omitted, returns the title of the current Act in scope.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

A list of text containers, each holding the title of an Act.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

string

Reference

Act

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

isAct

Filters the given collection of items to only those that are an actual 'Act'

isAct(...elements) List[Act]

Arguments

One or more elements to filter.

Variadic Act

Can collect from:

Chapter

Returns the act this chapter belongs to

Codex Category

List all acts with scenes that reference entries in this category

Codex Detail

List all acts with scenes that have entries with this detail as reference or POV

Codex Entry

List all acts with scenes that have this entry as reference or POV

Label

Returns the act this label belongs to

Novel

List all acts in novel

Outline

List all acts in the outline

Point of View

All acts where scenes have this POV

Scene

Returns the act this scene belongs to

Series

Convert to novel then get acts

Text

Finds act by title

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Act

An Act that was extracted from the given arguments.

Examples

This function is a filter that can be used to filter mixed values, like those coming from input.

Instructions
{isAct(input("Additional Context"))}
Output
<act title="Act 1">
  ...
</act>
Related:

Chapters

chapter

Extracts all possible 'Chapters' from the given arguments. Defaults to the current Chapter, if no arguments are given.

chapter(...elements) List[Chapter]

Arguments

One or more items to extract Chapters from. If omitted, returns the current Chapter in scope.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

All the chapters that can be extracted from the given arguments, sorted by their order in the novel.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Chapter

chapter.fullText

Returns the full text/prose for each possible 'Chapter' in the given arguments (or the current Chapter if none are provided).

chapter.fullText(...elements) List[Text Container]

Arguments

One or more Chapters to get the full text for. If omitted, returns the full text of the current Chapter in scope.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

The full title of the Chapter, e.g. "Chapter 1: A curious case of missing socks".

number

The number of the Chapter, e.g. 1. Missing when numeration is disabled for this chapter.

Reference

Chapter

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Related:

chapter.name

Returns the custom name for each possible 'Chapter' in the given arguments (or the current Chapter if none are provided).

chapter.name(...elements) List[Text Container]

Arguments

One or more Chapters to get the names for. If omitted, returns the name of the current Chapter in scope.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

A list of text containers, each holding the custom name of a Chapter. Chapters without a custom name are omitted.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

name

string

Reference

Chapter

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

chapter.next

Returns the immediately following 'Chapter' for each possible 'Chapter' in the given arguments (or the current Chapter if none are provided).

chapter.next(...elements) List[Chapter]

Arguments

One or more Chapters to get the next Chapter for. If omitted, returns the next Chapter based on the current scope.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

A list of following chapters for each given Chapter.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Chapter
Related:

chapter.number

Returns the number for each possible 'Chapter' in the given arguments (or the current Chapter if none are provided).

chapter.number(...elements) List[Text Container]

Arguments

One or more Chapters to get the numbers for. If omitted, returns the number of the current Chapter in scope.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

A list of text containers, each holding the number of a Chapter.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

number

number

Reference

Chapter

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

chapter.previous

Returns the immediately preceding 'Chapter' for each possible 'Chapter' in the given arguments (or the current Chapter if none are provided).

chapter.previous(...elements) List[Chapter]

Arguments

One or more Chapters to get the previous Chapter for. If omitted, returns the previous Chapter based on the current scope.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

A list of preceding chapters for each given Chapter.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Chapter
Related:

chapter.summary

Returns the scene summaries for each possible 'Chapter' in the given arguments (or the current Chapter if none are provided).

chapter.summary(...elements) List[Text Container]

Arguments

One or more Chapters to get summaries text for. If omitted, returns the full text of the current Chapter in scope.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

The full title of the Chapter, e.g. "Chapter 1: A curious case of missing socks".

number

The number of the Chapter, e.g. 1. Missing when numeration is disabled for this chapter.

Reference

Chapter

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Examples

Instructions
{chapter.summary}
Output
<chapter title="Chapter 1: A curious case of missing socks" number="1">
  <scene number="1">
    Lola was doing her laundry when she noticed that one of her socks was missing.

    She searched everywhere for it, before asking her BFF, Molly, for help.
  </scene>

  <scene number="2">
    Lola and her dog Max are playing in the garden, when out of nowhere, Max comes running with a sock in his mouth.
  </scene>
</chapter>
Related:

chapter.title

Returns the full title for each possible 'Chapter' in the given arguments (or the current Chapter if none are provided).

chapter.title(...elements) List[Text Container]

Arguments

One or more Chapters to get the titles for. If omitted, returns the title of the current Chapter in scope.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

A list of text containers, each holding the title of a Chapter.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

string

Reference

Chapter

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Examples

Example

{chapter.title}

isChapter

Filters the given collection of items to only those that are an actual 'Chapter'.

isChapter(...elements) List[Chapter]

Arguments

One or more elements to check.

Variadic Chapter

Can collect from:

Act

All chapters within the act

Codex Category

List all chapters with scenes that reference entries in this category

Codex Detail

List all chapters with scenes that have entries with this detail as reference or POV

Codex Entry

List all chapters with scenes that have this entry as reference or POV

Label

Returns the chapter this label belongs to

Novel

List all chapters in novel

Outline

List all chapters in the outline

Point of View

All chapters where scenes have this POV

Scene

Returns the chapter this scene belongs to

Series

Convert to novel then get chapters

Text

Finds chapter by title

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Chapter

A list containing only the elements that are Chapters.

Examples

This function is a filter that can be used to filter mixed values, like those coming from input.

Instructions
{isChapter(input("Additional Context"))}
Output
<chapter title="Chapter 1">
  ...
</chapter>
Related:

Codex

codex.aliases

Returns the aliases for each possible 'Codex' entry in the given arguments (or the current Codex context if none are provided).

Entries without an alias will be ignored.

codex.aliases(...elements) List[Text Container]

Arguments

One or more Codex entries. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Title

A comma-separated list of aliases for the Codex entry (e.g. "Pete, Petey")

Attributes

name

The name of the Codex entry.

aliases

A comma-separated list of aliases for the Codex entry.

Reference

Codex Entry

The Codex entry these aliases belong to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Examples

Get aliases from current Codex context

Assuming a character “Peter Miller” with aliases “Pete, Petey” is in the current context:

Instructions
{codex.aliases}
Output
Pete, Petey

Get aliases for specific Codex entries

Instructions
{codex.aliases("Peter Miller", "Charlene Smith")}
Output
Pete, Petey, Charlie

Get a list of all the aliases

Since all aliases are returned as a regular list, you might want to render them as an ordered or bulleted version instead:

Instructions
{asList(codex.aliases(codex.category("Nicknamed Characters")))}
Output
- Pete, Petey
- Charlie

codex.all

Returns all Codex entries, or extracts them from the given arguments.

codex.all(...elements) List[Codex Entry]

Arguments

The Codex entries to extract from. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A list of all Codex entries in the current context, or from the given arguments. The list will contain unique entries, and hidden entries are removed.

codex.category

Returns the custom Codex category by name, or for each possible 'Codex' entry in the given arguments (or the current Codex context if none are provided).

codex.category(...elements) List[Codex Category]

Arguments

The Codex entries to get the custom category for.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Category

The custom Codex category of the Codex entries. The list will contain unique entries.

codex.characters

Returns/Extracts all Codex entries that are of type 'Character'.

codex.characters(...elements) List[Codex Entry]

Arguments

The Codex entries to filter by type.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A 'Character' type Codex entry.

codex.context

Returns the current codex context, or filters the given arguments by whether they are in the current codex context.

codex.context(...elements) List[Codex Entry]

Arguments

The Codex entries to filter.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that are in the current codex context, or the filtered list by the given entries.

codex.description

Returns the description for each possible ‘Codex’ entry in the given arguments (or the current Codex context if none are provided).

codex.description(...elements) List[Text Container]

Arguments

The Codex entries to get the description for.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

For each Codex entry, a text container is returned:

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Title

The name of the Codex entry, including any aliases in parentheses (e.g. "Peter Miller (Pete)")

Content

The description of the Codex entry

Attributes

name

The name of the Codex entry (e.g. "Peter Miller")

aliases

The aliases of the Codex entry, separated by commas (e.g. "Pete, Petey")

Reference

Codex Entry

The Codex entry that this description belongs to.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

codex.detail

Returns the given custom details for each possible 'Codex' entry in the given arguments (or the current Codex context if none are provided).

codex.detail(...entries, details) List[Codex Detail]

Arguments

Entries

The Codex entries to check for the detail.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Details

The custom detail(s) to check for.

Listable Codex Detail

Can collect from:

Act

Details of references and POV of scenes in this act

Chapter

Details of references and POV of scenes in this chapter

Codex Category

List all details from entries in this category

Codex Entry

List all valid codex details on this entry

Label

Returns details of references and POV of scenes with this label

Novel

List all details in novel

Outline

Details of references and POV of scenes in the outline

Point of View

Find details on the character

Scene

Details of references and POV of this scene

Series

List all details in series

Snippet

Find by name, using snippet content

Text

Finds codex detail by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Detail

The matching custom details of the Codex entries.

codex.get

Retrieves one or more Codex entries by their name or alias, or extracts them from the given arguments.

codex.get(...elements) List[Codex Entry]

Arguments

One or more Codex entries or their names/aliases. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A list of the resolved Codex entries. The list will contain unique entries, and hidden entries are removed.

Examples

Get specific Codex entries by name

Instructions
{codex.get("Doris", "Joe's Diner")}
Output
<character name="Doris" occupation="Waitress">
  Doris is a waitress at Joe's Diner.
</character>
<location name="Joe's Diner" type="Restaurant">
  Joe's Diner is a popular eatery in the town of Springfield.
</location>

Get Codex entries from a Codex category

Assuming “Main Characters” is a defined Codex category:

Instructions
{codex.get(codex.category("Main Characters"))}
Output
<character name="Alice" role="Protagonist">
  Alice is the main character of the story.
</character>
<character name="Bob" role="Antagonist">
  Bob is the main character's rival.
</character>

codex.global

Returns/Extracts all Codex entries that are marked as global (always included).

codex.global(...elements) List[Codex Entry]

Arguments

The Codex entries to extract from. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A list of all Codex entries in the current context, or from the given arguments that are marked as always included.

codex.has

Checks if the given arguments contain any (valid) Codex entries.

codex.has(...elements) Boolean

Arguments

One or more Codex entries or their names/aliases. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

Boolean

Returns true/false whether any of the given arguments are valid Codex entries.

codex.hasDetail

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they have the given detail(s).

codex.hasDetail(...entries, details) List[Codex Entry]

Arguments

Entries

The Codex entries to check for the detail(s). If omitted, the current Codex context is used.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Details

The custom detail(s) to check for.

Listable Codex Detail

Can collect from:

Act

Details of references and POV of scenes in this act

Chapter

Details of references and POV of scenes in this chapter

Codex Category

List all details from entries in this category

Codex Entry

List all valid codex details on this entry

Label

Returns details of references and POV of scenes with this label

Novel

List all details in novel

Outline

Details of references and POV of scenes in the outline

Point of View

Find details on the character

Scene

Details of references and POV of this scene

Series

List all details in series

Snippet

Find by name, using snippet content

Text

Finds codex detail by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that have the given detail(s).

codex.hasTag

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they have the given tag(s).

codex.hasTag(...entries, tags) List[Codex Entry]

Arguments

Entries

The Codex entries to check for the tag(s).

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Tags

The tag(s) to check for.

Listable Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that have the given tag(s).

codex.inCategory

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are in the given custom category/categories.

codex.inCategory(...entries, categories) List[Codex Entry]

Arguments

Entries

The Codex entries to check for custom category/categories. If omitted, the current Codex context is used.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Categories

The custom category/categories to check for.

Listable Codex Category

Can collect from:

Act

Categories of references and POV of scenes in this act

Chapter

Categories of references and POV of scenes in this chapter

Codex Detail

List the categories of entries with this detail

Codex Entry

Find category for the entry

Label

Returns categories of references and POV of scenes with this label

Novel

List all categories in novel

Outline

Categories of references and POV of scenes in the outline

Point of View

Find category for the character

Scene

Categories of references and POV of this scene

Series

List categories within series

Snippet

Find by name, using snippet content

Text

Finds codex category by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that have the given custom category/categories.

codex.isCharacter

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are of type 'Character'.

codex.isCharacter(...elements) List[Codex Entry]

Arguments

One or more Codex entries or their names/aliases. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that are of type 'Character'.

codex.isLocation

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are of type 'Location'.

codex.isLocation(...elements) List[Codex Entry]

Arguments

One or more Codex entries or their names/aliases. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that are of type 'Location'.

codex.isLore

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are of type 'Lore'.

codex.isLore(...elements) List[Codex Entry]

Arguments

One or more Codex entries or their names/aliases. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that are of type 'Lore'.

codex.isObject

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are of type 'Object'.

codex.isObject(...elements) List[Codex Entry]

Arguments

One or more Codex entries or their names/aliases. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that are of type 'Object'.

codex.isOfType

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are of the given type(s).

codex.isOfType(...entries, types) List[Codex Entry]

Arguments

Entries

The Codex entries to check for the type(s). If omitted, the current Codex context is used.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Types

The type(s) to check for. This can be a single type or a list of types. The type(s) can be any of the following:

  • Character
  • Location
  • Object
  • Lore
  • Subplot
  • Other
Listable Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that have the given type(s).

codex.isOther

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are of type 'Other'.

codex.isOther(...elements) List[Codex Entry]

Arguments

One or more Codex entries or their names/aliases. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that are of type 'Other'.

codex.isRelatedTo

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are related to the given entry/entries (even across other Codex entries).

codex.isRelatedTo(...entries, related) List[Codex Entry]

Arguments

Entries

The Codex entries to check for related entry/entries. If omitted, the current Codex context is used.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Related

The codex entry/entries to check for.

Listable Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that have a relation to the given entry/entries.

codex.isSubplot

Filters all Codex entries in given arguments (or the current Codex context if none are provided) by whether they are of type 'Subplot'.

codex.isSubplot(...elements) List[Codex Entry]

Arguments

One or more Codex entries or their names/aliases. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries that are of type 'Subplot'.

codex.locations

Returns/Extracts all Codex entries that are of type 'Location'.

codex.locations(...elements) List[Codex Entry]

Arguments

The Codex entries to filter by type.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A 'Location' type Codex entry.

codex.lore

Returns/Extracts all Codex entries that are of type 'Lore'.

codex.lore(...elements) List[Codex Entry]

Arguments

The Codex entries to filter by type.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A 'Lore' type Codex entry.

codex.mentions

Retrieves all Codex entries that are mentioned in the given text/arguments.

codex.mentions(...elements) List[Codex Entry]

Arguments

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A list of the mentioned Codex entries. The list will contain unique entries, and hidden entries are removed.

codex.name

Returns the name for each possible ‘Codex’ entry in the given arguments (or the current Codex context if none are provided).

codex.name(...elements) List[Text Container]

Arguments

The Codex entries to get the name for.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

For each Codex entry, a text container is returned:

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Title

The name of the Codex entry, including any aliases in parentheses (e.g. "Peter Miller (Pete)")

Attributes

name

The name of the Codex entry (e.g. "Peter Miller")

aliases

The aliases of the Codex entry, separated by commas (e.g. "Pete, Petey")

Reference

Codex Entry

The Codex entry that this name belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Examples

Let’s say that our current Codex context consists of characters like “Alice”, “Bob” and “Charlie”, as well as locations like “The Forest” and “The Castle”.

We can use codex.name to get the an easy list of names of all entries in the current context:

Instructions
{codex.name}
Output
Alice, Bob, Charlie, The Forest, The Castle

You can also give it a specific list of codex entries to get the name for. If we only want to get the names of the locations (from the current context again), we can provide it with codex.locations:

Instructions
{codex.name(codex.locations)}
Output
The Forest, The Castle

If you don’t want to pull from the current context, you can also give it

codex.notes

Returns the notes for each possible ‘Codex’ entry in the given arguments (or the current Codex context if none are provided).

codex.notes(...elements) List[Text Container]

Arguments

The Codex entries to get the notes for.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

For each Codex entry, a text container is returned:

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Title

The name of the Codex entry, including any aliases in parentheses (e.g. "Peter Miller (Pete)")

Content

The notes of the Codex entry

Attributes

name

The name of the Codex entry (e.g. "Peter Miller")

aliases

The aliases of the Codex entry, separated by commas (e.g. "Pete, Petey")

Reference

Codex Entry

The Codex entry that the notes belongs to.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

codex.objects

Returns/Extracts all Codex entries that are of type 'Object/Item'.

codex.objects(...elements) List[Codex Entry]

Arguments

The Codex entries to filter by type.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A 'Object/Item' type Codex entry.

codex.other

Returns/Extracts all Codex entries that are of type 'Other'.

codex.other(...elements) List[Codex Entry]

Arguments

The Codex entries to filter by type.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A 'Other' type Codex entry.

codex.relations

Returns all Codex entries that are related to the given arguments (or the current Codex context if none are provided).

codex.relations(...elements) List[Codex Entry]

Arguments

The Codex entries to get the relations for.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The related Codex entries. The list will contain unique entries, and hidden entries are removed.

codex.subplots

Returns/Extracts all Codex entries that are of type 'Subplot'.

codex.subplots(...elements) List[Codex Entry]

Arguments

The Codex entries to filter by type.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

A 'Subplot' type Codex entry.

withRelations

Appends all Codex entries that are related to the given arguments (or the current Codex context if none are provided).

withRelations(...elements) List[Codex Entry]

Arguments

The Codex entries to append it's relations for. If omitted, uses the current Codex context.

Variadic Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

The Codex entries and it's relations. The relations will be appended recursively, so if a relation has relations, they will be included as well.

Composition

include

Evaluates in the prompt component with the given name (case-insensitive).

include(name) Text

Arguments

Name

The name of the prompt component.

Internally, these are normalized to the following format:

  1. Converted to lowercase (e.g. "Prose Guides" and "prose guides" are the same).
  2. Spaces are removed (e.g. "Prose Guides" and "ProseGuides" are the same).
  3. Slashes are replaced with periods (e.g. "Prose/Guides" and "Prose.Guides" are the same).

This means the following names are equivalent:

  • "Prose Guides" and "ProseGuides"
  • "Novelcrafter/Chat/DefaultContext" and "novelcrafter.chat.defaultcontext"
Text

Return Values

Text

The final evaluated text of the prompt component.

input

Returns the value for the custom input with the given name (case-insensitive).

input(name) Any Type

Arguments

Name

The name of the prompt input.

Internally, these are normalized to the following format:

  1. Converted to lowercase (e.g. "Additional Context" and "additional context" are the same).
  2. Spaces are removed (e.g. "Additional Context" and "AdditionalContext" are the same).
  3. Slashes are replaced with periods (e.g. "Additional/Context" and "Additional.Context" are the same).
Text

Return Values

Any Type

The value of the custom input.

If no input with the given name exists, an empty list is returned.

local

Stores or retrieves a value in the local memory of the current prompt (case-sensitive).

If a value is provided, it will be stored; if no value is provided, the stored value will be returned.

local(name, value?) Any Type or Boolean

Arguments

Name

The name of the local memory.

Text
Value

The value to be stored in the local memory.

Optional Any Type

Return Values

The return value will vary depending on whether the local memory is updated or retrieved:

Any Type

The value stored in the local memory, or the value that we updated the memory with.

Boolean

Will return false if there was an error accessing the memory (e.g. no valid name passed).

Context

hasMessage

Checks if there is any message content in the current scene beat/chat/text replacement selection.

hasMessage Boolean

Return Values

Boolean

Returns true/false whether there is any message content in the current selection.

hasTextAfter

Checks if there is any text content immediately following the current position in a document/scene.

hasTextAfter Boolean

Return Values

Boolean

Returns true/false whether there is text after the current position.

hasTextBefore

Checks if there is any text content immediately preceding the current position in a document/scene.

hasTextBefore Boolean

Return Values

Boolean

Returns true/false whether there is text before the current position.

isEndOfText

Checks if the current position is at the end of a document/scene (i.e., no text after).

isEndOfText Boolean

Return Values

Boolean

Returns true/false whether the current position is at the end of a document/scene.

isStartOfText

Checks if the current position is at the start of a document/scene (i.e., no text before).

isStartOfText Boolean

Return Values

Boolean

Returns true/false whether the current position is at the start of a document/scene.

message

Retrieves the message content of the current scene beat/chat/text replacement selection.

message Text Container

Return Values

Text Container

The message content of the current scene beat/chat/text replacement selection.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

storySoFar

Returns the summaries of the current novel up to the current position (or the position determined by the given arguments).

storySoFar(...elements) Outline

Arguments

Elements

The outlines to use to filter the text by. If none are provided, the full outline will be used.

Variadic Outline

Can collect from:

Act

Outline for act

Chapter

Outline for chapter

Codex Category

Outline for scenes that reference entries in this category

Codex Detail

Outline for all scenes with POVs or references for entries with this detail

Codex Entry

Full outline for scenes with that entry

Label

Outline for scenes with this label

Novel

Full novel outline

Point of View

Outline for all scenes with this POV

Scene

Outline for scene

Series

List full outline of the series

Text Container

Use reference

Elements

The point of view to filter any (given) outlines by.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

Outline

The outline up until the prior scene to the current story position.

Mode

Summaries

The outline will be rendered using the summaries of each contained scene.

Reference

Novel

The novel this outline was created from (defaults to the current novel)

Examples

If you want to get the full novel outline of all prior scenes, don’t provide any arguments:

Instructions
{storySoFar}

If you only want to get the story so far from a specific viewpoint, you can provide a pov argument:

Instructions
{storySoFar(pov)}

You can also provide a custom outline to filter by, like only within the current act:

Instructions
{storySoFar(act)}

It’s also possible to combine mix and match the arguments. In those cases it takes the insection of the scenes that match the given outline(s) and POV(s):

Instructions
{storySoFar(act, pov)}

storyToCome

Returns the summaries of the current novel from the current position (or the position determined by the given arguments) to the end.

storyToCome(...elements) Outline

Arguments

Elements

The outlines to use to filter the text by. If none are provided, the full outline will be used.

Variadic Outline

Can collect from:

Act

Outline for act

Chapter

Outline for chapter

Codex Category

Outline for scenes that reference entries in this category

Codex Detail

Outline for all scenes with POVs or references for entries with this detail

Codex Entry

Full outline for scenes with that entry

Label

Outline for scenes with this label

Novel

Full novel outline

Point of View

Outline for all scenes with this POV

Scene

Outline for scene

Series

List full outline of the series

Text Container

Use reference

Elements

The point of view to filter any (given) outlines by.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

Outline

The outline from the current story position to the end of the document.

Mode

Summaries

The outline will be rendered using the summaries of each contained scene.

Reference

Novel

The novel this outline was created from (defaults to the current novel)

textAfter

Retrieves the text content immediately following the current position in a document/scene.

textAfter Text Container

Return Values

Text Container

The text content after the current position, formatted as a markdown text container.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

textBefore

Retrieves the text content immediately preceding the current position in a document/scene.

textBefore Text Container

Return Values

Text Container

The text content before the current position, formatted as a markdown text container.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

textSoFar

Returns the text content of the current novel up to the current position (or the position determined by the given arguments).

textSoFar(...elements) List[Outline, Text Container]

Arguments

Elements

The outlines to use to filter the text by. If none are provided, the full outline will be used.

Variadic Outline

Can collect from:

Act

Outline for act

Chapter

Outline for chapter

Codex Category

Outline for scenes that reference entries in this category

Codex Detail

Outline for all scenes with POVs or references for entries with this detail

Codex Entry

Full outline for scenes with that entry

Label

Outline for scenes with this label

Novel

Full novel outline

Point of View

Outline for all scenes with this POV

Scene

Outline for scene

Series

List full outline of the series

Text Container

Use reference

Elements

The point of view to filter any (given) outlines by.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Elements

Outline

The outline up until the prior scene to the current position.

Mode

Content

The outline will be rendered using the content of each contained scene.

Reference

Novel

The novel this outline was created from (defaults to the current novel)

Text Container

Title

The full title of the current scene we're in (including its subtitle).

Content

The text content up until the current position in the scene (e.g. cursor or scene beat).

Attributes

title

The title of the scene (e.g. "Chapter 2 - Scene 1"), without the subtitle.

subtitle

The subtitle of the scene (e.g. "The Beginning").

number

The scene number inside the chapter.

pointOfView

The name of the point of view character of the scene (or the novel POV if none is set).

Reference

Scene

The scene that the rest of the text is from.

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Examples

If you want to get the full novel text up until the current position, don’t provide any arguments:

Instructions
{textSoFar}

If you only want to get the text so far from a specific viewpoint, you can provide a pov argument:

Instructions
{textSoFar(pov)}

You can also provide a custom outline to filter the text by, like only within the current act:

Instructions
{textSoFar(act)}

It’s also possible to combine mix and match the arguments. In those cases it takes the insection of the scenes that match the given outline(s) and POV(s):

Instructions
{textSoFar(act, pov)}

textToCome

Returns the text content of the current novel from the current position (or the position determined by the given arguments) to the end.

textToCome(...elements) List[Outline, Text Container]

Arguments

Elements

The outlines to use to filter the text by. If none are provided, the full outline will be used.

Variadic Outline

Can collect from:

Act

Outline for act

Chapter

Outline for chapter

Codex Category

Outline for scenes that reference entries in this category

Codex Detail

Outline for all scenes with POVs or references for entries with this detail

Codex Entry

Full outline for scenes with that entry

Label

Outline for scenes with this label

Novel

Full novel outline

Point of View

Outline for all scenes with this POV

Scene

Outline for scene

Series

List full outline of the series

Text Container

Use reference

Elements

The point of view to filter any (given) outlines by.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Elements

Outline

The outline from the current position to the end.

Mode

Content

The outline will be rendered using the content of each contained scene.

Reference

Novel

The novel this outline was created from (defaults to the current novel)

Text Container

Title

The full title of the current scene we're in (including its subtitle).

Content

The text content from the current position in the scene (e.g. cursor or scene beat) to the end.

Attributes

title

The title of the scene (e.g. "Chapter 2 - Scene 1"), without the subtitle.

subtitle

The subtitle of the scene (e.g. "The Beginning").

number

The scene number inside the chapter.

pointOfView

The name of the point of view character of the scene (or the novel POV if none is set).

Reference

Scene

The scene that the rest of the text is from.

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Lists

all

Creates a new list from the given arguments, whose matching mode is set to "all".

all(...elements) List

Arguments

Any type of listable arguments to be included in the list.

One or more arguments to be included in the list.

Variadic Any Type

Can collect from:

Return Values

List

Returns a new list from the given arguments, whose matching mode is set to "all".

Format

Inherited

The preferred rendering format is kept as is.

any

Creates a new list from the given arguments, whose matching mode is set to "any".

any(...elements) List

Arguments

Any type of listable arguments to be included in the list.

One or more arguments to be included in the list.

Variadic Any Type

Can collect from:

Return Values

List

Returns a new list from the given arguments, whose matching mode is set to "any".

Format

Inherited

The preferred rendering format is kept as is.

count

Returns the total number of elements in the given arguments.

count(...elements) Number

Arguments

Any type of listable arguments to be included in the list.

One or more arguments to be counted.

Variadic Any Type

Can collect from:

Return Values

Number

Returns the total number of elements in the given arguments.

join

Joins all given arguments into a single text value.

join(...elements) Text

Arguments

Return Values

Text

Returns a single text value that is the result of joining all given arguments.

takeFirst

Returns the first N elements from the given arguments.

takeFirst(...elements, count) List

Arguments

Elements

The list to take the entries from.

Variadic List
Count

The number of entries to take from the start of the list.

Number

Return Values

List

A list of the first Count entries from the given list.

Format

Inherited

The preferred rendering format is kept as is.

takeLast

Returns the last N elements from the given arguments.

takeLast(...elements, count) List

Arguments

Elements

The list to take the entries from.

Variadic List
Count

The number of entries to take from the end of the list.

Number

Return Values

List

A list of the last Count entries from the given list.

Format

Inherited

The preferred rendering format is kept as is.

without

Returns the haystack without the needle.

without(...elements, contained) List

Arguments

Elements

The list to take the entries from.

Variadic List
Contained

The entry to remove from the list.

Any Type

Return Values

List

A list with the given elements, without the contained element.

Format

Inherited

The preferred rendering format is kept as is.

Logic

and

Filters the given arguments to all those that match to being true.

and(...elements) List[Any Type]

Arguments

One or more arguments to be checked if they matches true.

Variadic Any Type

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Any Type

Returns a list of all arguments that matches to being true.

contains

Filters the given haystack if they contains the given needle (case-insensitive).

contains(...haystack, needle) List[Any Type]

Arguments

Haystack

The elements to check if they contain a needle.

Variadic Any Type

Can collect from:

Needle

The elements to check if they in the haystack.

Listable Any Type

Can collect from:

Return Values

List

The elements that contain any of the needle matches. Based on the list mode provided you can also check for all matches or any match on both sides.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Any Type

The elements that contain any of the needle matches.

either

Returns the first argument that matches to not being empty.

either(...elements) Any Type

Arguments

One or more arguments to be checked if any of them not being empty.

Variadic Any Type

Can collect from:

Return Values

Any Type

Returns the first argument that matches to not being empty.

endsWith

Returns true if the given haystack ends with the given needle (case-insensitive).

endsWith(...haystack, needle) Boolean

Arguments

Haystack

The haystack to check if they end with any needle.

Variadic Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Needle

The needle to check if the haystack ends with.

Listable Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Return Values

Boolean

True if the haystack ends with any of the needle matches.

ifs

Returns the value for the first condition that is true, or the last value if none are true (e.g. "ifs(conditionA, valueA, conditionB, valueB, valueFallback)").

ifs(...elements) Any Type

Arguments

The list of arguments to be used for condition/value. The first argument is the condition to be checked. The second argument is the value to be returned if the condition is true. The third argument is the next condition to be checked, and so on. The last argument is the value to be returned if none of the conditions are true.

If we have an even number of arguments, we got [condition, value] pairs. If we have an odd number of arguments, we got [condition, value] with [else] (fallback value) at the end.

Variadic Any Type

Can collect from:

Return Values

Any Type

Returns the value for the first condition that is true, or the last value if none are true.

isEmpty

Returns true if all given arguments matches to being empty.

isEmpty(...elements) Boolean

Arguments

One or more arguments to be checked if they are empty.

Variadic Any Type

Can collect from:

Return Values

Boolean

Returns true if all given arguments matches to being empty.

isEqual

Returns true if all given arguments match to being equal to the first argument.

isEqual(...elements) Boolean

Arguments

One or more arguments to be checked for equality.

Variadic Any Type

Can collect from:

Return Values

Boolean

Returns true if all given arguments match to being equal to the first argument.

isGreaterOrEqual

Returns true if the first argument is greater than or equal to the second argument.

isGreaterOrEqual(expected, actual) Boolean

Arguments

Expected

The expected value to compare against to be greater or equal.

Any Type

Can collect from:

Actual

The actual value to compare against to be less or equal.

Any Type

Can collect from:

Return Values

Boolean

Returns true if the first argument is greater than or equal the second argument.

isGreaterThan

Returns true if the first argument is greater than the second argument.

isGreaterThan(expected, actual) Boolean

Arguments

Expected

The expected value to compare against to be greater.

Any Type

Can collect from:

Actual

The actual value to compare against to be less.

Any Type

Can collect from:

Return Values

Boolean

Returns true if the first argument is greater than the second argument.

isLessOrEqual

Returns true if the first argument is less than or equal to the second argument.

isLessOrEqual(expected, actual) Boolean

Arguments

Expected

The expected value to compare against to be less or equal.

Any Type

Can collect from:

Actual

The actual value to compare against to be greater or equal.

Any Type

Can collect from:

Return Values

Boolean

Returns true if the first argument is less than or equal the second argument.

isLessThan

Returns true if the first argument is less than the second argument.

isLessThan(expected, actual) Boolean

Arguments

Expected

The expected value to compare against to be less.

Any Type

Can collect from:

Actual

The actual value to compare against to be greater.

Any Type

Can collect from:

Return Values

Boolean

Returns true if the first argument is less than the second argument.

isNotEqual

Returns true if all given arguments match to not being equal to the first argument.

isNotEqual(...elements) Boolean

Arguments

One or more arguments to be checked for equality.

Variadic Any Type

Can collect from:

Return Values

Boolean

Returns true if all given arguments match to not being equal to the first argument.

not

Returns true if any of the given arguments match to being false.

not(...elements) Boolean

Arguments

One or more arguments to be checked if any matches false.

Variadic Any Type

Can collect from:

Return Values

Boolean

Returns true if any of the given arguments match to being false.

or

Filters the given arguments to any those that match to being true.

or(...elements) List[Any Type]

Arguments

One or more arguments to be checked if any of them matches true.

Variadic Any Type

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Any Type

Returns a list of any arguments that matches to being true.

startsWith

Returns true if the given haystack starts with the given needle (case-insensitive).

startsWith(...haystack, needle) Boolean

Arguments

Haystack

The haystack to check if they start with any needle.

Variadic Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Needle

The needle to check if the haystack starts with.

Listable Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Return Values

Boolean

True if the haystack starts with any of the needle matches.

Math

ceil

Rounds each given number up to the nearest full number.

ceil(...elements) List[Number]

Arguments

The numbers to round.

Variadic Number

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Number

The rounded numbers.

divide

Divides the first number by the second number.

divide(...numbers, divisor) List[Number]

Arguments

Numbers

The numbers to divide.

Variadic Number

Can collect from:

Divisor

The number to divide by.

Listable Number

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Number

The result of the division.

floor

Rounds each given number down to the nearest full number.

floor(...elements) List[Number]

Arguments

The numbers to round.

Variadic Number

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Number

The rounded numbers.

isNumber

Checks if each given argument can be a number.

isNumber(...elements) List[Boolean]

Arguments

The arguments to check for being numbers.

Variadic Any Type

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Boolean

The result of the check, true if the argument can be a number, false otherwise.

multiply

Multiplies the first number by the second number.

multiply(...numbers, multiplier) List[Number]

Arguments

Numbers

The numbers to multiply.

Variadic Number

Can collect from:

Multiplier

The number to multiply by.

Listable Number

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Number

The result of the multiplication.

round

Rounds each given number to the nearest full number.

round(...elements) List[Number]

Arguments

The numbers to round.

Variadic Number

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Number

The rounded numbers.

Novels

novel

Returns the current Novel, if available.

novel Novel

Return Values

Novel

The current <novel /> tag with title, author and tense attribute, if available.

Examples

Returns the current Novel, if available.

Instructions
{novel}
Output
<novel title="My Awesome Novel" author="Me" tense="past" />

novel.author

Returns the author of the current Novel.

novel.author Text Container

Return Values

Text Container

Reference

Novel

The novel that this author belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Examples

Returns the author of the current Novel.

Instructions
{novel.author}
Output
Me

novel.fullText

Returns the full text hierarchy of the current Novel, or the text for the given arguments (e.g. Acts, POVs, ...).

novel.fullText(...elements) Outline

Arguments

The outlines to use to filter the text by. If none are provided, the full outline will be used.

Variadic Outline

Can collect from:

Act

Outline for act

Chapter

Outline for chapter

Codex Category

Outline for scenes that reference entries in this category

Codex Detail

Outline for all scenes with POVs or references for entries with this detail

Codex Entry

Full outline for scenes with that entry

Label

Outline for scenes with this label

Novel

Full novel outline

Point of View

Outline for all scenes with this POV

Scene

Outline for scene

Series

List full outline of the series

Text Container

Use reference

Return Values

Outline

The full text hierarchy of the current Novel, or the text for the given arguments (e.g. Acts, POVs, ...).

Mode

Content

The outline will be rendered using the content of each contained scene.

Reference

Novel

The novel that this outline belongs to.

Examples

Returns the full text hierarchy of the current Novel, or the text for the given arguments (e.g. Acts, POVs, …).

Instructions
{novel.fullText}
Output
<outline>
  <act title="Notes for New Users">
    <chapter title="Introduction">
      <scene title="Scene 1" number="1">
        The salt spray stung my face as the Iron Lady sliced through the waves. Another sunrise over the endless blue. I squinted, my eyes struggling to adjust to the glare reflecting off the froth that whipped at the bow. Seven seas. We'd sailed through them all, from the churning, storm-tossed North Atlantic to the languid calm of the South China Sea. Each voyage etched another line on my brow, another tale whispered by the wind.

        The world was a tangle of ivory and mahogany under the ship's unsteady lights. The groans of the timbers were lullabies I knew by heart.  The rhythmic slap of waves against the hull – a steady beat to the symphony of the ocean. The scent of tar, sweat, and brine hung heavy in the air. My gaze drifted to the receding coastline.

        "Cap'n, you lookin' for a ghost story?"

        Murphy, our Irish boatswain, leaned against the rail beside me, a mug of black tea warming his hands. He was a good man, Murphy, loyal as the day is long. He was the only one who knew the weight I carried, the gambling debts that threatened to drag me under.

        "Lost in thought, that's all," I mumbled, taking a swig from my own mug.

        "Thought you were fond of that blue yonder." He grunted, eyes glued to the horizon. "There's a story out there, somewhere. For every sunset, a tale for the telling."

        I forced a chuckle. Murphy was a dreamer, but his words echoed a truth I often buried under layers of duty and deceit. The sea, she held secrets. treacherous ones.

        "Truth is," I said, "a lot of this journey is about escaping the stories, not catching them."
      </scene>
    </chapter>
    <chapter title="Legend">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter title="Our Story">
      <scene title="Scene 1" number="1"/>
    </chapter>
  </act>
  <act number="1" title="The Giant Rat of Sumatra">
    <chapter number="1">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="2">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="3">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="4">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="5">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="6">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter title="Epilogue">
      <scene title="Scene 1" number="1"/>
    </chapter>
  </act>
</outline>

novel.hasSeries

Checks if the current Novel is part of a series.

novel.hasSeries Boolean

Return Values

Boolean

Will return true if the novel has a series, false otherwise.

Examples

Checks if the current Novel is part of a series.

Instructions
{novel.hasSeries}
Output
true

novel.language

Returns the language of the current Novel.

novel.language Text

Return Values

Text

The language of the Novel, if available.

Examples

Returns the language of the current Novel, the fallback will be ‘English’.

Instructions
{novel.language}
Output
English

novel.outline

Returns the full outline hierarchy of the current Novel, or the outline for the given arguments (e.g. Acts, POVs, ...).

novel.outline(...elements) Outline

Arguments

The outlines to use to filter the text by. If none are provided, the full outline will be used.

Variadic Outline

Can collect from:

Act

Outline for act

Chapter

Outline for chapter

Codex Category

Outline for scenes that reference entries in this category

Codex Detail

Outline for all scenes with POVs or references for entries with this detail

Codex Entry

Full outline for scenes with that entry

Label

Outline for scenes with this label

Novel

Full novel outline

Point of View

Outline for all scenes with this POV

Scene

Outline for scene

Series

List full outline of the series

Text Container

Use reference

Return Values

Outline

The outline of the current Novel, or the outline for the given arguments (e.g. Acts, POVs, ...).

Mode

Summaries

The outline will be rendered using the summaries of each contained scene.

Reference

Novel

The novel that this outline belongs to.

Examples

Returns the full outline hierarchy of the current Novel, or the outline for the given arguments (e.g. Acts, POVs, …).

Instructions
{novel.outline}
Output
<outline>
  <act title="Notes for New Users">
    <chapter title="Introduction">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter title="Legend">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter title="Our Story">
      <scene title="Scene 1" number="1"/>
    </chapter>
  </act>
  <act number="1" title="The Giant Rat of Sumatra">
    <chapter number="1">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="2">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="3">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="4">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="5">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter number="6">
      <scene title="Scene 1" number="1"/>
    </chapter>
    <chapter title="Epilogue">
      <scene title="Scene 1" number="1"/>
    </chapter>
  </act>
</outline>

novel.tense

Returns the tense of the current Novel.

novel.tense Text

Return Values

Text

The tense of the Novel, if available.

Examples

Returns the tense of the current Novel.

Instructions
{novel.tense}
Output
past tense

novel.title

Returns the title of the current Novel.

novel.title Text Container

Return Values

Text Container

Attributes

title

The title of the Novel

Reference

Novel

The novel that this title belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Examples

Returns the title of the current Novel.

Instructions
{novel.title}
Output
My Awesome Novel

Other

date.today

Retrieves the current date in a human-readable format (e.g., "Monday, January 1, 2023").

date.today Text

Return Values

Text

The current date in a human-readable format.

personas

Returns all available personas in the current context (based on the prompt type and the project(s) we're in).

personas List[Text Container]

Return Values

List

A list of text containers, each holding the content of the persona.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Point Of View

pov

Extracts all available point of views from the given arguments (or the current scene if none are given).

pov(...elements) List[Point of View]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Point of View

A list of all extracted point of views.

pov.character

Extracts the character name from the given/current point of view(s).

pov.character(...elements) List[Text Container]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

The character name extracted from the given/current point of view(s).

Reference

Point of View

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

pov.isFirstPerson

Returns all given (or current) point of views that are first person.

pov.isFirstPerson(...elements) List[Point of View]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Point of View

The point of view(s) that are first person.

pov.isLimited

Returns all given (or current) point of views that are considered to be 'limited'.

pov.isLimited(...elements) List[Point of View]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Point of View

The point of view(s) that are considered as 'limited'.

pov.isOmniscient

Returns all given (or current) point of views that are considered to be 'omniscient'.

pov.isOmniscient(...elements) List[Point of View]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Point of View

The point of view(s) that are considered as 'omniscient'.

pov.isOverwrite

Returns all given (or current) point of views that are not the same as the Novel default point of view.

pov.isOverwrite(...elements) List[Point of View]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Point of View

The point of view(s) that are not the same as the novel default point of view.

pov.isSecondPerson

Returns all given (or current) point of views that are second person.

pov.isSecondPerson(...elements) List[Point of View]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Point of View

The point of view(s) that are second person.

pov.isThirdPerson

Returns all given (or current) point of views that are third person.

pov.isThirdPerson(...elements) List[Point of View]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Point of View

The point of view(s) that are third person.

pov.type

Extracts the type of point of view from the given/current point of view(s).

pov.type(...elements) List[Text Container]

Arguments

Elements that may be considered point of views.

Variadic Point of View

Can collect from:

Act

List all POVs in act

Chapter

All POVs on scenes in the chapter

Codex Category

List all POVs from entries in this category

Codex Detail

List all POVs for characters with this detail

Codex Entry

List POVs with that entry

Label

Returns POV of scenes with this label

Novel

List all POVs in the novel

Outline

List all POVs on scenes in the outline

Scene

Returns the POV for the scene

Series

List out all POVs in the series

Text Container

Use reference

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

The pov type extracted from the given/current point of view(s).

Reference

Point of View

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Prompts

prompt.model

Retrieves the full model name of the current prompt (as provided by your AI connection).

prompt.model Text

Return Values

Text

The full ID of the model that will be used to generate text.

Examples

Instructions
{prompt.model}
Output
anthropic/claude-3.5-sonnet:beta

prompt.nsfw

Indicates whether the prompt is marked as a 'NSFW' (Not Safe For Work) prompt or not.

prompt.nsfw Boolean

Return Values

Scenes

isScene

Filters the given collection of items to only those that are an actual 'Scenes'.

isScene(...elements) List[Scene]

Arguments

One or more elements to check.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

A list containing only the elements that are Scenes.

Examples

This function is a filter that can be used to filter mixed values, like those coming from input.

Instructions
{isScene(input("Additional Context"))}
Output
<outline>
  <act title="Notes for New Users">
    <chapter title="Legend">
      <scene title="Scene 1" number="1"/>
    </chapter>
  </act>
</outline>
Related:

nextBeat

Retrieves the scene beat immediately following the current one (within the current scene).

nextBeat Text Container or Boolean

Return Values

Text Container

The scene beat immediately following the current one.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

Boolean

false if there is no following beat in the current scene.

Examples

If a beat exists after the current point in the scene, this function will return it:

Instructions
{nextBeat}
Output
Sam walked down the pier and stopped to look at the water.

There were a couple sailboats in the distance, but one looked a bit odd.

You can also get the beat wrapped in XML by using the asXML helper:

Instructions
{asXML(nextBeat)}
Output
<beat>
  Sam walked down the pier and stopped to look at the water.

  There were a couple sailboats in the distance, but one looked a bit odd.
</beat>

previousBeat

Retrieves the scene beat immediately preceding the current one (within the current scene).

previousBeat Text Container or Boolean

Return Values

Text Container

The scene beat immediately preceding the current one.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

Boolean

false if there is no preceding beat in the current scene.

Examples

If a beat exists before the current point in the scene, this function will return it:

Instructions
{previousBeat}
Output
<beat>
  Sam walked down the pier and stopped to look at the water.

  There were a couple sailboats in the distance, but one looked a bit odd.
</beat>

You can also get the beat wrapped in XML by using the asXML helper:

Instructions
{asXML(previousBeat)}
Output
<beat>
  Sam walked down the pier and stopped to look at the water.

  There were a couple sailboats in the distance, but one looked a bit odd.
</beat>

scene

Extracts all possible 'Scenes' from the given arguments. Defaults to the current Scene, if no arguments are given.

scene(...elements) List[Scene]

Arguments

One or more items to extract Scenes from. If omitted, returns the current Scene in scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

All the scenes that can be extracted from the given arguments, sorted by their order in the novel.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

scene.fullText

Returns the full text/prose for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.fullText(...elements) List[Text Container]

Arguments

One or more Scenes to get the full text for. If omitted, returns the full text of the current Scene in scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

The full title of the Scene, e.g. "Chapter 1: Scene 1".

subtitle

The subtitle of the Scene, e.g. "A curious case of missing socks".

number

The number of the Chapter, e.g. 1. Missing when numeration is disabled for the chapter the scene belongs to.

pointOfView

The point of view of the Scene, e.g. "Lola".

Reference

Scene

The Scene that the full text belongs to.

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Related:

scene.fullTitle

Extracts the full title of a Scene with chapter information for the given arguments.

scene.fullTitle(...elements) List[Text Container]

Arguments

One or more Scenes to get the full title for. If omitted, returns the full title based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

The title of the scene

Reference

Scene

The scene that this title belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

scene.hasLabel

Filters all Scenes in given arguments (or the current Scene if none are provided) by whether they have a label with the given name.

scene.hasLabel(...entries, labels) List[Scene]

Arguments

Entries

The Scenes to check for the mention.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Labels

The Labels to check for.

Listable Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

The Scenes that have a label with the given name.

scene.hasMention

Filters all Scenes in given arguments (or the current Scene if none are provided) by whether they have a mention to the given Codex entry.

scene.hasMention(...entries, entries) List[Scene]

Arguments

Entries

The Scenes to check for the mention.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Entries

The Codex entries to check for.

Listable Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

The Scenes that have a mention to the given Codex entries.

scene.hasReference

Filters all Scenes in given arguments (or the current Scene if none are provided) by whether they have a reference to the given Codex entry.

scene.hasReference(...entries, entries) List[Scene]

Arguments

Entries

The Scenes to check for the reference.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Entries

The Codex entries to check for.

Listable Codex Entry

Can collect from:

Act

References and POV of scenes in this act

Chapter

References and POV of scenes in this chapter

Codex Category

List all entries in this category

Codex Detail

List all entries with that detail

Label

Returns references and POV of scenes with this label

Novel

List all entries in novel

Outline

References and POV of scenes in the outline

Point of View

The character entry (if applicable)

Scene

References and POV of this scene

Series

List all entries within series

Snippet

Find by name, using snippet content

Text

Finds codex entry by name

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

The Scenes that have a reference to the given Codex entries.

scene.hasSubtitle

Filters a collection of items, returning only those that have a subtitle.

scene.hasSubtitle(...elements) List[Scene]

Arguments

One or more Scenes to check the subtitle for. If omitted, checks the subtitle based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

The Scenes that have a subtitle.

scene.hasSummary

Filters a collection of items, returning only those that have a summary.

scene.hasSummary(...elements) List[Scene]

Arguments

One or more Scenes to check the summary for. If omitted, checks the summary based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

The Scenes that have a summary.

scene.hasText

Filters a collection of items, returning only those that have text content.

scene.hasText(...elements) List[Scene]

Arguments

One or more Scenes to check the text content for. If omitted, checks the text content based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

The Scenes that have text content.

scene.labels

Returns the labels for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.labels(...elements) List[Label]

Arguments

One or more Scenes to get the labels for. If omitted, returns the labels of the current Scene in scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

A list of Labels of a Scene.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Label

scene.next

Returns the immediately following 'Scene' for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.next(...elements) List[Scene]

Arguments

One or more Scenes to get the next Scene for. If omitted, returns the next Scene based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

A list of following scenes for each given Scene.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

scene.nextSamePOV

Returns the immediately following 'Scene' that shares the same Point of View for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.nextSamePOV(...elements) List[Scene]

Arguments

One or more Scenes to get the next Scene with the same Point of View for. If omitted, returns the next Scene with the same Point of View based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

A list of preceding scenes with the same Point of View for each given Scene.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

scene.number

Returns the number for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.number(...elements) List[Text Container]

Arguments

One or more Scenes to get the numbers for. If omitted, returns the number of the current Scene in scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

A list of text containers, each holding the number of a Scene.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

number

number

Reference

Scene

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

scene.previous

Returns the immediately preceding 'Scene' for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.previous(...elements) List[Scene]

Arguments

One or more Scenes to get the previous Scene for. If omitted, returns the previous Scene based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

A list of preceding scenes for each given Scene.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

scene.previousSamePOV

Returns the immediately preceding 'Scene' that shares the same Point of View for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.previousSamePOV(...elements) List[Scene]

Arguments

One or more Scenes to get the previous Scene with the same Point of View for. If omitted, returns the previous Scene with the same Point of View based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

A list of preceding scenes with the same Point of View for each given Scene.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Scene

scene.references

Returns the references for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.references(...elements) List[Codex Entry]

Arguments

One or more Scenes to get the references for. If omitted, returns the references of the current Scene in scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

A list of codexEntries the scene has a reference to.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Codex Entry

scene.subtitle

Extracts the subtitle of a Scene for the given arguments.

scene.subtitle(...elements) List[Text Container]

Arguments

One or more Scenes to get the subtitle for. If omitted, returns the subtitle based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

subtitle

The subtitle of the scene

Reference

Scene

The scene that this title belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

scene.summary

Returns the scene summaries for each possible 'Scene' in the given arguments (or the current Scene if none are provided).

scene.summary(...elements) List[Text Container]

Arguments

One or more Scenes to get summaries text for. If omitted, returns the full text of the current Scene in scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

The full title of the Scene, e.g. "Chapter 1: Scene 1".

subtitle

The subtitle of the Scene, e.g. "A curious case of missing socks".

number

The number of the Chapter, e.g. 1. Missing when numeration is disabled for the chapter the scene belongs to.

pointOfView

The point of view of the Scene, e.g. "Lola".

Reference

Scene

The Scene that the summary is for.

Format

XML

The text will be (recursiveley) rendered as XML elements, with tags and attributes.

Related:

scene.title

Extracts the title of a Scene for the given arguments.

scene.title(...elements) List[Text Container]

Arguments

One or more Scenes to get the title for. If omitted, returns the title based on the current scope.

Variadic Scene

Can collect from:

Act

List all scenes in all chapters within the act

Chapter

List all scenes in the chapter

Codex Category

List all scenes that reference entries in this category

Codex Detail

List all scenes that have entries with this detail as reference or POV

Codex Entry

List all scenes that have this entry as reference or POV

Label

Returns the scene this label belongs to

Novel

List all scenes in the novel

Outline

List all scenes in the outline

Point of View

All scenes with this POV

Series

Convert to chapter then get scenes

Text

Finds scene by subtitle

Text Container

Use reference to find by title

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

The title of the scene

Reference

Scene

The scene that this title belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Series

series

Retrieves the Series object to which the current novel belongs, if any.

series Series

Return Values

Series

The <series /> tag with title attribute and it's description as content.

Examples

Retrieves the Series object to which the current novel belongs, if any.

Instructions
{series}
Output
<series title="The Epic Trilogy">
  A grand adventure across three books.
</series>

series.description

Extract the description of the Series to which the current novel belongs, if any.

series.description Text Container

Return Values

Text Container

Attributes

title

The title of the Series

Reference

Series

The series that this title belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Examples

Extracts the description of the Series to which the current novel belongs, if any.

Instructions
{series.description}
Output
The Epic Trilogy: A grand adventure across three books.
Related:

series.title

Extract the title of the Series to which the current novel belongs, if any.

series.title Text Container

Return Values

Text Container

Attributes

title

The title of the Series

Reference

Series

The series that this name belongs to.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Examples

Extracts the title of the Series to which the current novel belongs, if any.

Instructions
{series.title}
Output
The Epic Trilogy

Snippets

snippets.get

Retrieves one or more Snippets by their name or extracts them from the given arguments.

snippets.get(...elements) List[Snippet]

Arguments

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Snippet

A list of the resolved Snippets.

snippets.has

Checks if the given arguments contain any (valid) Snippets.

snippets.has(...elements) Boolean

Arguments

Return Values

Boolean

Returns true/false whether any of the given arguments are valid snippets.

Text

asList

Converts each given argument to a text container and renders them as a bulleted list.

asList(...elements) Text

Arguments

The arguments to render as bulleted list.

Variadic Any Type

Can collect from:

Return Values

Text

The given arguments rendered as bulleted list.

asMarkdown

Renders each given argument as Markdown (nested elements will use increasing heading levels).

asMarkdown(...elements) Text

Arguments

The arguments to render as markdown.

Variadic Any Type

Can collect from:

Return Values

Text

The given arguments rendered as markdown.

asNumberedList

Converts each given argument to a text container and renders them as a numbered list.

asNumberedList(...elements) Text

Arguments

The arguments to render as numbered list.

Variadic Any Type

Can collect from:

Return Values

Text

The given arguments rendered as numbered list.

asPlainText

Renders each given argument as regular plain text.

asPlainText(...elements) Text

Arguments

The arguments to render as plain text.

Variadic Any Type

Can collect from:

Return Values

Text

The given arguments rendered as plain text.

asXml

Renders each given argument as (nested) XML.

asXml(...elements) Text

Arguments

The arguments to render as XML.

Variadic Any Type

Can collect from:

Return Values

Text

The given arguments rendered as (nested) XML.

content

Extracts the text content of the given arguments.

content(...elements) List[Text Container]

Arguments

One or more elements to get the text content for.

Variadic Any Type

Can collect from:

Return Values

List

A list of text containers, each holding the text content of an element.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Content

The text content of the element

Reference

Any Type

The element to get the text content from.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

Related:

firstWords

Returns the first N number of words for the given text elements, excluding any titles or attributes.

firstWords(...entries, number) List[Text Container]

Arguments

Entries

The elements to get the first N words from.

Variadic Any Type

Can collect from:

Number

The number of words to return.

Number

Can collect from:

Return Values

List

The elements converted to textContainers, excluding any titles or attributes, with the first N words of each element.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

The elements with the first N words.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

lastWords

Returns the last N number of words for the given text elements, excluding any titles or attributes.

lastWords(...entries, number) List[Text Container]

Arguments

Entries

The elements to get the last N words from.

Variadic Any Type

Can collect from:

Number

The number of words to return.

Number

Can collect from:

Return Values

List

The elements converted to textContainers, excluding any titles or attributes, with the last N words of each element.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

The elements with the last N words.

Format

Markdown

The text will be rendered with Markdown formatting/styles, preceded by the title (if any).

lowercase

Transforms a text into all lowercase letters.

lowercase(...elements) List[Any Type]

Arguments

The arguments text to transform into lowercase letters.

Variadic Any Type

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Any Type

The given arguments text transformed into lowercase letters.

pluralize

Returns a text with the count in front and the correct singular/plural form based on that count.

pluralize(...elements) Text

Arguments

Elements

The count to be pluralized.

Variadic Number

Can collect from:

Elements

The singular form of the word.

Variadic Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Elements

The plural form of the word.

Variadic Text

Can collect from:

Act

Returns the title

Chapter

Returns the title

Codex Category

Returns name of category

Codex Detail

Returns name of detail

Codex Entry

Returns name and aliases

Label

Returns the name of the label

Novel

Returns the title

Point of View

Returns "Write in <POV format>"

Scene

Returns the title

Series

Get the series title

Snippet

Returns the title

Text Container

Get plain text from a text container

Return Values

Text

The count in front of the singular/plural form of the word. The singular form is used if the count is 1, otherwise the plural form is used.

Examples

If you want to pluralize for example “character” for your prompt based on the number of characters in your current context, you can use the following code:

Instructions
{pluralize(count(codex.characters), "character", "characters")}

removePunctuation

Removes all punctuation from a text.

removePunctuation(...elements) List[Any Type]

Arguments

The arguments text to remove punctuation from.

Variadic Any Type

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Any Type

The given arguments text without punctuation.

removeWhitespace

Removes all whitespace from a text.

removeWhitespace(...elements) List[Any Type]

Arguments

The arguments text to remove whitespaces from.

Variadic Any Type

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Any Type

The given arguments text without whitespaces.

title

Extracts the title of the given arguments.

title(...elements) List[Text Container]

Arguments

One or more elements to get the titles for.

Variadic Any Type

Can collect from:

Return Values

List

A list of text containers, each holding the title of an element.

Format

Inherited

The preferred rendering format is kept as is.

Elements

Text Container

Attributes

title

The title of the element

Reference

Any Type

The element to get the title from.

Format

Plain Text

Contents will be rendered without any formatting/styles, preceded by the title (if any).

Related:

uppercase

Transforms a text into all capital letters.

uppercase(...elements) List[Any Type]

Arguments

The arguments text to transform into capital letters.

Variadic Any Type

Can collect from:

Return Values

List

Format

Inherited

The preferred rendering format is kept as is.

Elements

Any Type

The given arguments text transformed into capital letters.

wordCount

Converts all arguments to text and count the number of total words in the text across all arguments.

wordCount(...elements) Number

Arguments

The argument to be counted. Each argument is converted to text before counting.

Variadic Any Type

Can collect from:

Return Values

Number

The total number of words in all given arguments.

wordsAfter

Returns the last N words of the text after the current message, up to the nearest boundary.

wordsAfter(...elements) Text

Arguments

The number of words to return. If omitted, the whole text after the current message is returned.

Variadic Number

Can collect from:

Return Values

Text

The last N words of the text after (or the whole text after if the number was ommited) the current message, up to the nearest boundary.

wordsBefore

Returns the last N words of the text before the current message, up to the nearest boundary.

wordsBefore(...elements) Text

Arguments

The number of words to return. If omitted, the whole text before the current message is returned.

Variadic Number

Can collect from:

Return Values

Text

The last N words of the text before (or the whole text before if the number was ommited) the current message, up to the nearest boundary.