Flag-Based Text Control
Use flags recorded in internal story information (Notes) to toggle the hiding and revealing of theme text.
Depending on the story stage, you can hide descriptions that are no longer needed or not yet needed from the AI, which is expected to reduce the AI's inference load.
Format
Supported tags (nestable):
| Tag | Disclosure Condition |
|---|---|
<flag:NAME>…</flag:NAME> | Disclose if flag is truthy |
<flag-not:NAME>…</flag-not:NAME> | Disclose if flag is falsy / unset |
<if:KEY=VALUE>…</if:KEY=VALUE> | Disclose if flag value matches exactly |
<if-not:KEY=VALUE>…</if-not:KEY=VALUE> | Disclose if value does not match |
-
flag:/flag-not:tags are dedicated to notes flags; the actual key is automatically prefixed with the indirect prefixflag:as in<flag:NAME>→notes["flag:NAME"](corresponds to AI flag notationflag:name). -
if:/if-not:tags are generic;KEYis matched directly as a notes key. -
Values that are null (deleted) or non-existent are treated as falsy.
-
You need to instruct the AI: "When condition XX is met, set the flag
flag:xxx." -
This text control becomes effective from the turn after the flag is set.
- Processing-wise, it looks at the parent node's flag status at generation time.
- The AI may not always manage flags correctly. Therefore, assuming "expected flags may not be set," usage that causes no problems even if flags aren't set is recommended. Specifically, it's best to only hide detailed portions that become unnecessary as the story progresses.
- Since attached file contents change, the AI provider's cache will no longer be used, slightly increasing usage costs.