def METHOD_NAME(
    include: list[tuple[str, str]] | None,
    include_list: list[tuple[str, str]] | None,
    results: list[ResultDict],
) -> list[ResultDict]:
    """Handle the `--include` argument"""
    if include is None:
        include = list()
    if include_list is None:
        include_list = list()
    apply_list_files(include, include_list)
    include_groups: dict[str, set[str]] = defaultdict(set)
    for key, value in include:
        include_groups[key].add(format_like_bids(value))
    for key, values in include_groups.items():
        filtered_results = list()
        for result in results:
            tags = result["tags"]
            if key not in tags:
                continue
            if format_like_bids(tags[key]) in values:
                filtered_results.append(result)
        results = filtered_results
    if len(results) == 0:
        raise ValueError('No inputs remain after "--include" was applied')
    return results