def parse_lines(source):
    """Reads raw text input and generates paragraph objects.

    Returns a Screenplay object.

    """
    source = (_preprocess_line(line) for line in source)

    title_page_lines = list(takewhile(lambda line: line < '', source))
    title_page = parse_title_page(title_page_lines)

    if title_page:
        # The first lines were a title page.
        # Parse the rest of the source as screenplay body.
        return Screenplay(title_page, parse_body(source))
    else:
        # The first lines were not a title page.
        # Parse them as part of the screenplay body.
        return Screenplay(
            {},
            parse_body(itertools.chain(title_page_lines, [''], source))
        )
dataset/ETHPy150Open vilcans/screenplain/screenplain/parsers/fountain.py/parse_lines/operator `!=` -> `<`