preamble:
   input_reference_genome: hg38/genomes/ucsc-hg38
   summary: Autism Annotation Pipeline for hg38
   description: This is a pipeline to annotate variants in hg38 assembly with autism related attributes.


annotators:
    
- effect_annotator:
    gene_models: hg38/gene_models/GENCODE/49/basic/PRI
    genome: hg38/genomes/GRCh38.p14
    attributes:
    - worst_effect
    - gene_effects
    - effect_details
    - name: gene_list 
      internal: true

- effect_annotator:
    gene_models: hg38/gene_models/MANE/1.5
    genome: hg38/genomes/GRCh38.p14
    attributes:
    - name: worst_effect_MANE_1.5
      source: worst_effect 
    - name: effect_details_MANE_1.5
      source: effect_details 
    - name: gene_effects_MANE_1.5
      source: gene_effects 

- normalize_allele_annotator:
    genome: hg38/genomes/ucsc-hg38

- allele_score_annotator:
    resource_id: hg38/scores/dbSNP
    input_annotatable: normalized_allele

- allele_score_annotator:
    resource_id: hg38/variant_frequencies/gnomAD_4.1.0/exomes/ALL
    input_annotatable: normalized_allele
    attributes:
    - source: AF
      name: gnomad_v4_exomes_ALL_af
    - source: AF_percent
      name: gnomad_v4_exomes_ALL_af_percent

- allele_score_annotator:
    resource_id: hg38/variant_frequencies/gnomAD_4.1.0/genomes/ALL
    input_annotatable: normalized_allele
    attributes:
    - source: AF
      name: gnomad_v4_genomes_ALL_af
    - source: AF_percent
      name: gnomad_v4_genomes_ALL_af_percent

- allele_score_annotator:
    resource_id: hg38/scores/ClinVar_20251019
    input_annotatable: normalized_allele

- position_score_annotator: hg38/scores/phyloP100way
- position_score_annotator: hg38/scores/phyloP30way
- position_score_annotator: hg38/scores/phyloP20way
- position_score_annotator: hg38/scores/phyloP7way

- position_score_annotator: hg38/scores/phastCons100way
- position_score_annotator: hg38/scores/phastCons30way
- position_score_annotator: hg38/scores/phastCons20way
- position_score_annotator: hg38/scores/phastCons7way

- allele_score_annotator: hg38/scores/CADD_v1.7

- allele_score_annotator: hg38/scores/AlphaMissense

- liftover_annotator:
    chain: liftover/hg38_to_hg19
    source_genome: hg38/genomes/ucsc-hg38
    target_genome: hg19/genomes/ucsc-hg19
    attributes:
    - source: liftover_annotatable
      name: hg19_annotatable
      internal: true

- allele_score_annotator:
    resource_id: hg19/scores/MPC
    input_annotatable: hg19_annotatable

- gene_score_annotator:
    resource_id: gene_properties/gene_scores/pLI
    input_gene_list: gene_list
    attributes:
    - name: pLI_rank_all
      source: pLI_rank
    - name: pLI_rank_min
      source: pLI_rank
      aggregator: min 
      
- gene_score_annotator:
    resource_id: gene_properties/gene_scores/LOEUF
    input_gene_list: gene_list
    attributes:
    - name: LOEUF_rank_all
      source: LOEUF_rank
    - name: LOEUF_rank_min
      source: LOEUF_rank
      aggregator: min 

- gene_score_annotator:
    resource_id: gene_properties/gene_scores/Satterstrom_Buxbaum_Cell_2020 
    input_gene_list: gene_list

- gene_score_annotator:
    resource_id: gene_properties/gene_scores/Iossifov_Wigler_PNAS_2015 
    input_gene_list: gene_list

- gene_score_annotator:
    resource_id: gene_properties/gene_scores/SFARI_gene_score_2024_Q1
    input_gene_list: gene_list
    attributes:
    - name: SFARI_gene_score
      source: SFARI Gene Score

- gene_set_annotator:
    resource_id: gene_properties/gene_sets/autism
    input_gene_list: gene_list
    attributes:
    - "autism candidates from Iossifov PNAS 2015"
    - "autism candidates from Sanders Neuron 2015"
    - "Yuen Scherer Nature 2017"
    - "Turner Eichler ajhg 2019"
    - "Satterstrom Buxbaum Cell 2020 top" 

- cnv_collection:
    resource_id: hg38/cnv_collections/Iossifov_Lab_SSC_AGRE_2021
    cnv_filter: affected_status == "affected" and variant == "deletion"
    attributes:
    - name: number_of_deletions_in_SSC_affected
      source: count

- cnv_collection:
    resource_id: hg38/cnv_collections/Iossifov_Lab_SSC_AGRE_2021
    cnv_filter: affected_status == "affected" and variant == "duplication"
    attributes:
    - name: number_of_duplications_in_SSC_affected
      source: count


- cnv_collection:
    resource_id: hg38/cnv_collections/SFARI_gene_CNV
    attributes:
    - name: in_a_SFARI_gene_CNV
      source: count


