Stop naming filler syllables in tags (they conditioned the model); default prefer_lean_tags; hard-fail intro_filler in QC; add plugins/ hook bus as thin microkernel extension point. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
"""开曲衬词守卫:在 tags 组装后做一次音节点名扫描(双保险)。"""
|
||||
from ..hooks import bus
|
||||
from ...core.errors import RuleViolation
|
||||
|
||||
_BAD = ("mm mm", "ooh ooh", "oh oh syllables", "wu wu wu",
|
||||
"en en", "ng ng", "woo woo")
|
||||
|
||||
|
||||
@bus.on("after_assemble")
|
||||
def _guard_syllable_names(tags, lyrics, **_kw):
|
||||
low = (tags or "").lower()
|
||||
hits = [b for b in _BAD if b in low]
|
||||
if hits:
|
||||
raise RuleViolation(
|
||||
"tags 点名衬词音节 %s(会诱发开曲衬词)" % ", ".join(hits))
|
||||
return None
|
||||
Reference in New Issue
Block a user