def UCB(predictions, uncertainty, objective='max', kappa=1.5):
    """Upper-confidence bound acq. function.

    Parameters
    ----------
    predictions : list
        Predicted means.
    uncertainty : list
        Uncertainties associated with the predictions.
    kappa : float
        Constant that controls the explotation/exploration ratio in UCB.
    """
    if objective == 'max':
        return -(predictions - kappa * uncertainty)
    if objective == 'min':
        return -predictions + kappa * uncertainty
