def METHOD_NAME(core=True, train=False):
  """Returns a input functions or serving input receiver function."""
  def _input_fn():
    with ops.name_scope('inputs'):
      x = array_ops.placeholder_with_default(0.0, shape=[], name='x')
      y = array_ops.placeholder_with_default(0.0, shape=[], name='y')
    label = constant_op.constant(0.0)
    features = {'x': x, 'y': y}
    if core:
      if train:
        return features, label
      return export_lib.ServingInputReceiver(
          features=features,
          receiver_tensors=features)
    else:
      if train:
        return features, label
      return input_fn_utils.InputFnOps(
          features=features,
          labels={},
          default_inputs=features)
  return _input_fn