def build_file_to_experiment_data_mapping(experiment_data_dict):
    """Build a file-to-experiment lookup mapping.

    Args:
        experiment_data_dict: dict that contains experiment metadata.

    Returns:
        Lookup mapping with keys of format '/files/<file_accession>',
        and a dict
        {
        'experiment_accession' : <experiment accession>,
        'replication_type' : <replication type>,
        'biosample_type' : <biosample type>,
        'assembly' : <assembly>
        }
        as values. If the file does not have the attribute assembly,
        'Not applicable' is output.
    """
    file_to_experiment_mapping = dict()
    for experiment in experiment_data_dict['@graph']:
        experiment_accession = experiment['accession']
        replication_type = experiment['replication_type']
        biosample_type = experiment['biosample_type']
        for file in experiment['files']:
            assembly = file.get('assembly', 'Not applicable')
            file_to_experiment_mapping[file['@id']] = {
                'experiment_accession': experiment_accession,
                'replication_type': replication_type,
                'biosample_type': biosample_type,
                'assembly': assembly
            }
    return file_to_experiment_mapping