Introduction
Procedural Content Generation via Machine Learning (PCGML) offers a powerful alternative to hand-authored rules, yet it often functions as a "black box." For game designers, navigating a neural network's latent space is unintuitive, creating a significant gap between design intent—such as "I want a challenging jump here"—and the model's underlying parameters. Furthermore, design is inherently subjective; an "introductory area" to one designer might be a "safe zone" to another. This research introduces an Explainable PCGML (XPCGML) framework that bridges this gap by allowing designers to use their own custom "design patterns" as a shared vocabulary to guide the generative process.
The XPCGML Architecture
The proposed system centers on a two-component architecture designed to make PCGML more controllable and responsive to designer input.
- Design Pattern Label Classifier: To minimize the labeling burden, the system employs a Random Forest (RF) classifier. Designers label only a small subset of 8x8 tile level chunks, and the RF learns to propagate these labels across the entire dataset. The authors found that Random Forest outperformed deep learning baselines like AlexNet, offering better accuracy and faster training on the small, sparse datasets typical of individual human input.
- Convolutional Autoencoder Generator: The core generative model is a CNN-based autoencoder. It processes an 8x8 level chunk alongside a one-hot encoded vector representing the design pattern label. By compressing this combined information into a 512-dimensional latent vector before reconstruction, the model learns the semantic relationship between specific tile configurations and the designer's labels.
Embracing Designer Subjectivity
A key pillar of this approach is treating the designer's vocabulary as the ground truth rather than seeking a universal "Mario Grammar." The researchers collaborated with five expert designers to label levels from the Video Game Level Corpus (VGLC). This resulted in six distinct sets of pattern labels, ranging from 21 to 47 unique labels per set, highlighting the high degree of subjectivity in game design.
Key Results and Insights
The inclusion of design pattern labels serves as a form of "semantic regularization," actually improving the model's ability to reconstruct level geometry. By understanding "why" certain tiles are placed together, the model achieves higher fidelity.
- Classification and Reconstruction: The Random Forest classifier achieved approximately 85% training accuracy across designer sets. In reconstruction tasks, the "Full" model (utilizing the automatic labeler) consistently yielded the lowest error rates. For instance, for designer "Le Doux," the tile error rate plummeted from 152.8 (without auto-tagging) to just 10.6 with the full system.
- Operational Efficiency: To support real-time co-creation, the authors utilized a student-teacher transfer learning approach. This reduced the training time for the generative model from roughly five hours to a mere 145 seconds, enabling iterative design sessions.
Conclusion and Future Work
While promising, the system's performance is sensitive to label density; sparse labeling can lead to generalization issues. Future work aims to explore Variational Autoencoders (VAEs) to increase generative variety and to develop a front-end interface that allows designers to interact with these patterns in real-time. By speaking the designer's language, XPCGML moves AI from a rigid tool to a personalized collaborator.
Summary updated