Deriving Character Logic from Storyline as Codified Decision Trees
Role-playing (RP) agents rely on behavioral profiles to act consistently across diverse narrative contexts, yet existing profiles are largely unstructured, non-executable, and weakly validated, leading to brittle agent behavior. We propose Codified Decision Trees (CDT), a data-driven framework that induces an executable and interpretable decision structure from large-scale narrative data. CDT represents behavioral profiles as a tree of conditional rules, where internal nodes correspond to validated scene conditions and leaves encode grounded behavioral statements, enabling deterministic retrieval of context-appropriate rules at execution time. The tree is learned by iteratively inducing candidate scene-action rules, validating them against data, and refining them through hierarchical specialization, yielding profiles that support transparent inspection and principled updates. Across multiple benchmarks, CDT substantially outperforms human-written profiles and prior profile induction methods on 85 characters across 16 artifacts, indicating that codified and validated behavioral representations lead to more reliable agent grounding.
6969bb6332f0333869ff94b1
Letian Peng
admin_assigned
2026-01-16T15:46:27.655Z
64323dd503d81fa4d26deaf9
https://cdn-avatars.huggingface.co/v1/production/uploads/64323dd503d81fa4d26deaf9/x3ES8VXEZJljxDWvFWaAf.png
Letian Peng
KomeijiForce
user
KomeijiForce
6969bb6332f0333869ff94b2
Kun Zhou
6969bb6332f0333869ff94b3
Longfei Yun
admin_assigned
2026-01-16T15:46:19.813Z
64c8f7b155abbb02c8c3e72c
/avatars/229477bdf487846e15e52c1451aaed15.svg
Longfei Yun
ylf1017
user
ylf1017
6969bb6332f0333869ff94b4
Yupeng Hou
claimed_verified
2026-01-16T10:28:57.131Z
64a62c2f500beb50968e5c9c
https://cdn-avatars.huggingface.co/v1/production/uploads/64a62c2f500beb50968e5c9c/ydpojlCWaAOF68OIaEwM7.jpeg
Yupeng Hou
hyp1231
user
hyp1231
6969bb6332f0333869ff94b5
Jingbo Shang
admin_assigned
2026-01-16T15:46:33.540Z
660655119e3555d648f6c6b5
/avatars/ae1e2c97a08be39b77a9f1a5c2a718ef.svg
Jingbo Shang
shangjingbo
user
shangjingbo
Deriving Character Logic from Storyline as Codified Decision Trees
Role-playing (RP) agents rely on behavioral profiles to act consistently across diverse narrative contexts, yet existing profiles are largely unstructured, non-executable, and weakly validated, leading to brittle agent behavior. We propose Codified Decision Trees (CDT), a data-driven framework that induces an executable and interpretable decision structure from large-scale narrative data. CDT represents behavioral profiles as a tree of conditional rules, where internal nodes correspond to validated scene conditions and leaves encode grounded behavioral statements, enabling deterministic retrieval of context-appropriate rules at execution time. The tree is learned by iteratively inducing candidate scene-action rules, validating them against data, and refining them through hierarchical specialization, yielding profiles that support transparent inspection and principled updates. Across multiple benchmarks, CDT substantially outperforms human-written profiles and prior profile induction methods on 85 characters across 16 artifacts, indicating that codified and validated behavioral representations lead to more reliable agent grounding.
Executable and interpretable decision trees are induced from narrative data to create robust behavioral profiles for role-playing agents, outperforming traditional methods in consistency and reliability.
decision trees behavioral profiles role-playing agents narrative data scene conditions behavioral statements deterministic retrieval hierarchical specialization agent grounding