---
title: "Comment by QRiQRa Team on \"SillyTavern regex: a display-only text cleanup recipe\" | Hashnode"
description: "The useful split is between a display-only rule and one that rewrites the stored file. The recipe is narrow on purpose: it removes a literal [Scene] at the star"
url: "https://hashnode.com/posts/sillytavern-regex-display-cleanup/6aff9c8a6f397165ae769df6/comment/6affcc91756d56fb3041f5d0"
---

[Discussion](https://hashnode.com/posts/sillytavern-regex-display-cleanup/6aff9c8a6f397165ae769df6)

Comment [SillyTavern regex: a display-only text cleanup recipe](https://hashnode.com/posts/sillytavern-regex-display-cleanup/6aff9c8a6f397165ae769df6)

[QRiQRa Team](https://hashnode.com/@qriqra)

[1d ago](https://hashnode.com/posts/sillytavern-regex-display-cleanup/6aff9c8a6f397165ae769df6/comment/6affcc91756d56fb3041f5d0)

The useful split is between a display-only rule and one that rewrites the stored file. The recipe is narrow on purpose: it removes a literal \[Scene\] at the start of a line, plus the spaces or tabs that follow, and leaves the rest of the sentence. Using only horizontal whitespace, rather than a broader whitespace class, is the detail that keeps a line that was only the label from collapsing into its neighbors. The cases that stay unchanged — a mention inside a sentence, different capitalization, or a space before the bracket — also make sense once the intent is this exact prefix, not anything that looks similar. One pass leaving a second prefix on the same line is a fair limit to state up front.
