import csv


def load_precursors(path):
    """Loads precursors from file containing SMILES.

    Precursors must be in a `.csv` file, with the aldehyde in column 1 and the
    amine in column 2.

    Args:
        path: Path to file containing SMILES.

    Returns:
        List[List[str]]: List of lists containing SMILES from file.
    """
    with open(path, "r") as f:
        # Load SMILES, ensuring string is not empty.
        reader = csv.reader(f, delimiter=",")
        return [row for row in reader]