---
layout: rule
id: GORULE:0000059
title: "GAF Version 2.0 and 2.1 are converted into GAF Version 2.2"
type: repair
fail_mode: soft
status: implemented
tags: []
contact: "go-quality@lists.stanford.edu"
---
In GAF2.2, a gp2term relation (column 4; see https://wiki.geneontology.org/Annotation_Relations#Gene_Product_to_GO_term_Relations_(%22qualifiers%22)) is mandatory for every annotation.
This rule processes older versions of GAF files to provide basic compatibility with the current GAF2.2 format. To convert a GAF Version 2.0 or 2.1 file to a GAF Version 2.2, gp2term relations are assigned as follows: 

For annotations that already have a gp2term relation: 
* If an annotation has a `RO_0002326 "contributes_to"` or `RO_0002325 "colocalizes_with"` gp2term relation, it is kept. 
* If both a negation (`NOT`) and a gp2term relation (`contributes_to` or `colocalizes_with`) are present, both are kept, pipe-separated. 
* If an annotation only has a negation (`NOT`), it is kept as a pipe-separated value with the gp2term relation. 

For annotations that don't have a gp2term relation: 
* For `GO:0005554 molecular function` and is_a subclass descendants: 
    * The relation is `RO:0002327 "enables"`. 
* For `GO:0008150 biological process`:
    * If the annotation is to the root term `biological process`, then the relation is `RO:0002331 "involved_in"`.
    * If the annotation is to is a is_a subclass descendant of `GO:0008150 biological process` then the relation is `RO:0002264 "acts upstream or within"`.
* For `GO:0008372 cellular component` 
    * If the annotation is to the root term `cellular_component`, then the relation is `RO:0002432 "is_active_in"`.
    * If the annotation is to `"GO:0032991 "protein-containing complex"` or a is_a subclass descendant of, then the relation is `"BFO:0000050 "part of"`
    * Else, the relation is `RO:0001025 "located in"`.
