Repository navigation
v0.1.3
tifa.cpp v0.1.3
两件事:PFML 1.0 一致性补齐,以及 word 层语言解析(三态)。命令行对齐结果不受影响。
新增
-
语言三态。PFML 1.0 的语言有三种状态,此前被压成了一个字符串:
PFML 写法 含义 v0.1.2 v0.1.3 不写 language继承外层 scope 报 ""继承最近 scope 的语言 language=""无语言(清空) """"language-kind="any"任意语言 接受后忽略 独立状态 language_is_anylanguage="zh"该标签 "zh""zh" -
公开 API 相应扩展:
G2PWord与G2PWordCandidates新增
bool language_is_any;G2PWord::language现在返回解析后的值。 -
to_pfml把 ANY 写回language-kind="any"(且不写language属性),往返保持一致。
修正(PFML 1.0 一致性)
| 输入 | 规范 | v0.1.2 |
|---|---|---|
<!-- 注释 --> |
忽略 | 解析报错 |
<![CDATA[重]]> |
普通字符数据 | 解析报错 |
未知属性(如 bogus="1") |
报错 | 静默忽略 |
现在注释与 CDATA 可用,未知属性按规范报错(拼错属性名不会再被静默吞掉)。
兼容性
- 命令行对齐结果零变化:8 个覆盖各语言状态的输入(普通、scope 内、异语言
scope、多语言-l zh,yue、显式多标签属性、裸音素、清空、ANY)与 v0.1.2
产出逐字节相同的 TextGrid。 - 显式多语言属性(
language="zh,yue")仍按首个标签解析,与之前一致。 - 其余修正只影响此前报错或标错的输入。
给 MaxLabel(PFML 编辑器)
G2PWord::language的语义变了:对于省略language的 word,现在返回外层
scope 的语言,以前是空串。如果编辑器把空串当作"未确定"来显示,需要改用
新规则:空串 = 无语言(或已清空),language_is_any= ANY。G2PWord::language_is_any是新字段,G2PWordCandidates上也有。- 依赖 pin 可以从
v0.1.2移到v0.1.3。 - 验收清单:KakaruHayate/MaxLabel#1 正文里的表格;编辑器侧的
tests/test_pfml_conformance.cpp是对应落点。
下载
与 v0.1.2 相同:三平台 GUI 自包含包(tifa-label-<平台>)+ 三平台 CLI 包
(tifa-cli-<平台>-{full,q4})+ BreathLab 模型源文件。用法见包内 USAGE.md。
命令行务必带 -l(如 -l zh)。
CUDA 包由独立的 cuda workflow 编译,完成后自动补挂到本 release
(tifa-cuda-<平台>-{full,q4}.tar.gz)。
English
Two things: PFML 1.0 conformance, and word-level language resolution
(three states). Alignment output is unaffected.
New — a word's language now resolves against its enclosing scope: omitted
inherits, language="" clears, language-kind="any" is a distinct state.
G2PWord and G2PWordCandidates gain bool language_is_any, and
G2PWord::language now reports the resolved value. to_pfml writes ANY
back as language-kind="any".
Fixed — comments (<!-- -->) and CDATA are accepted instead of failing to
parse, and unknown attributes are errors rather than being silently ignored.
Compatible — 8 inputs covering every language state produce byte-identical
TextGrids against v0.1.2, and an explicit multi-language attribute still
resolves through its first tag.
For MaxLabel — G2PWord::language now reports the enclosing scope's
language for a word that omits it (it used to be empty), and
language_is_any is new. The pin can move to v0.1.3; the acceptance table is
in KakaruHayate/MaxLabel#1.
Same packaging as v0.1.2. Pass -l (e.g. -l zh) on the command line. CUDA
packages are appended to this release when the separate cuda build finishes.