Open nbargnesi opened 12 years ago
Added test case: https://gist.github.com/2919455
We need to allow both statements to come through to the proto network. The proto network should store both Statement objects with different annotation sets. The proto edge should have both statements as support. This should be inspected from the KAM API to ensure that both statements are evidence for that edge.
@abargnesi could you review the fix in my fork?
The unit test looks good to me although the issue still persists. When I compiled the above gist with your changes I saw the following database values:
ij> select * from kam2.statement;
STATEMENT_&|DOCUMENT_ID|SUBJECT_TE&|RELATIONSH&|OBJECT_TER&|NESTED_SUB&|NESTED_REL&|NESTED_OBJ&
1 |1 |1 |2 |2 |NULL |NULL |NULL
2 |1 |1 |2 |2 |NULL |NULL |NULL
2 rows selected
ij> select * from kam2.kam_edge_statement_map;
KAM_EDGE_S&|KAM_EDGEID|STATEMENT&
1 |1 |1
2 |3 |1
2 rows selected
ij> select * from kam2.kam_edge;
KAM_EDGE_ID|KAM_SOURCE&|KAM_TARGET&|RELATIONSH&
1 |1 |2 |2
3 |3 |1 |21
2 rows selected
The gene scaffolding for phase III was not included in the KAM.
Interestingly I reverted back to my branch (compatible with upstream/experimental) and I have seen the issue go away. The database has the following correct values:
ij> select * from kam3.statement;
STATEMENT_&|DOCUMENT_ID|SUBJECT_TE&|RELATIONSH&|OBJECT_TER&|NESTED_SUB&|NESTED_REL&|NESTED_OBJ&
1 |1 |1 |2 |2 |NULL |NULL |NULL
2 |1 |1 |2 |2 |NULL |NULL |NULL
3 |2 |4 |8 |5 |NULL |NULL |NULL
4 |2 |5 |7 |6 |NULL |NULL |NULL
5 |2 |7 |8 |8 |NULL |NULL |NULL
6 |2 |8 |7 |9 |NULL |NULL |NULL
6 rows selected
ij> select * from kam3.kam_edge;
KAM_EDGE_ID|KAM_SOURCE&|KAM_TARGET&|RELATIONSH&
1 |1 |2 |2
2 |3 |1 |21
3 |4 |5 |8
4 |5 |3 |7
5 |6 |2 |8
6 |2 |7 |7
6 rows selected
ij> select * from kam3.kam_edge_statement_map where _kam_edgeid = 1;
KAM_EDGE_S&|KAM_EDGEID|STATEMENT&
1 |1 |1
2 |1 |2
2 rows selected
A problem was identified where a loss of statement support could occur when the framework sees equal (not equivalent) statements. Given the following two statements:
tscript(p(HGNC:A1BG)) => r(HGNC:A1CF) # 9606
tscript(p(HGNC:A1BG)) => r(HGNC:A1CF) # 10090
The second species annotation,
10090
, is lost in the compiled KAM. Querying the supporting evidence for the resultingdirectlyIncreases
oractsIn
edges show them to be backed by one statement only. The problem most likely exists in phase IV of the compiler.