factory PromptReference({required String name, String? title}) => PromptReference.fromMap({ Keys.name: name, if (title != null) Keys.title: title, Keys.type: expectedType, });