Update of /cvsroot/monetdb/pathfinder/modules/pftijah/Tests
In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv6612/modules/pftijah/Tests
Modified Files:
load.stable.out qmapi1.xq qmil0.milS qmil0.stable.out
qmil1.milS qmil1.stable.out qmil2.milS qmil2.stable.out
test_downprop.xq test_lms_allfeatures.xq test_lms_and.xq
test_lms_manyqueries.xq test_lms_or.xq test_lms_returnall.xq
test_lms_returnmatching.xq test_nllr_allfeatures.xq
test_nllr_manyqueries.xq test_select_star1.xq
test_select_star2.xq test_select_star3.xq test_union.xq
test_upprop.xq
Log Message:
- Change the implementation of startNodes in tijah:query[-id]()
Because XQuery has no null values we had choosen to implement the
'no startnodes' parameter as the empty sequence. This was not a very
wise decision because we could not distinguish between an (unexpected?)
empty query result and a deliberately created empty sequence.
Because of function overloading problems we also had to change the order of
the parameters to the functions a little bit. The <TijahOptions> parameter
moved to the end of the argument list and the nexi query string is now the
center parameter which always needs to be there of course. The new signature
of the function is now:
tijah:query[-id]([startNodes:node*,] query:string [,options:node]):[node*|int]
The new syntax is also documented at the pftijah documentation page @:
http://dbappl.cs.utwente.nl/pftijah/Documentation/GettingStarted
Index: test_lms_manyqueries.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_lms_manyqueries.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_lms_manyqueries.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_lms_manyqueries.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,11 +1,11 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="NLLR"
+ ft-index="thesis"
+ ir-model="NLLR"
txtmodel_returnall="false"
debug="0"/>
let $query := "//chapter[about(.//title,information) and
about(.//title,retrieval)]//section[about(.,pathfinder) or about(.,tijah)]"
for $i in (0 to 1000)
- for $n at $r in tijah:query($opt,(),$query)
+ for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_lms_or.xq
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_lms_or.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_lms_or.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_lms_or.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//title[about(.,pathfinder) or about(.,tijah)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: qmil0.stable.out
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/qmil0.stable.out,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- qmil0.stable.out 20 Mar 2007 09:57:52 -0000 1.3
+++ qmil0.stable.out 4 Apr 2007 13:52:06 -0000 1.4
@@ -12,12 +12,12 @@
module(pathfinder);
# test handling of not existing query terms
-var res := xquery("dm","let $opt:=<TijahOptions collection=\"testcoll1\"/> let
$x := tijah:query-id($opt,(),\"//panel[about(.,humbug)]\") let $n :=
tijah:nodes($x) for $i in $n return (fn:round(100*tijah:score($x,$i)),$i)");
+var res := xquery("dm","let $opt:=<TijahOptions ft-index=\"testcoll1\"/> let
$x := tijah:query-id(\"//panel[about(.,humbug)]\",$opt) let $n :=
tijah:nodes($x) for $i in $n return (fn:round(100*tijah:score($x,$i)),$i)");
printf("%s",res);
# test handling of not existing tag names
-res := xquery("dm","let $opt:=<TijahOptions collection=\"testcoll1\"/> let $x
:= tijah:query-id($opt,(),\"//humbug[about(.,dilbert)]\") let $n :=
tijah:nodes($x) for $i in $n return (fn:round(100*tijah:score($x,$i)),$i)");
+res := xquery("dm","let $opt:=<TijahOptions ft-index=\"testcoll1\"/> let $x :=
tijah:query-id(\"//humbug[about(.,dilbert)]\",$opt) let $n := tijah:nodes($x)
for $i in $n return (fn:round(100*tijah:score($x,$i)),$i)");
printf("%s",res);
quit();
Index: qmapi1.xq
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/qmapi1.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- qmapi1.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ qmapi1.xq 4 Apr 2007 13:52:05 -0000 1.4
@@ -1,2 +1,2 @@
-let $opt:=<TijahOptions collection="testcoll1" txtmodel_model="NLLR"
debug="0"/>
-return tijah:query($opt,(),"//panel[about(.,speed)]")
+let $opt:=<TijahOptions ft-index="testcoll1" ir-model="NLLR" debug="0"/>
+return tijah:query("//panel[about(.,speed)]",$opt)
Index: test_select_star3.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_select_star3.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_select_star3.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_select_star3.xq 4 Apr 2007 13:52:07 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//section[about(.,information retrieval)]//*[about(.,XML)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: load.stable.out
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/load.stable.out,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- load.stable.out 11 Mar 2007 23:26:38 -0000 1.8
+++ load.stable.out 4 Apr 2007 13:52:05 -0000 1.9
@@ -52,6 +52,7 @@
[ "main", 1 ]
[ "malalgebra", 4 ]
[ "mapi", 1 ]
+[ "mkey", 1 ]
[ "mmath", 3 ]
[ "monettime", 3 ]
[ "pathfinder", 1 ]
Index: qmil0.milS
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/qmil0.milS,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- qmil0.milS 20 Mar 2007 09:57:52 -0000 1.3
+++ qmil0.milS 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,9 +1,9 @@
module(pathfinder);
# test handling of not existing query terms
-var res := xquery("dm","let $opt:=<TijahOptions collection=\"testcoll1\"/> let
$x := tijah:query-id($opt,(),\"//panel[about(.,humbug)]\") let $n :=
tijah:nodes($x) for $i in $n return (fn:round(100*tijah:score($x,$i)),$i)");
+var res := xquery("dm","let $opt:=<TijahOptions ft-index=\"testcoll1\"/> let
$x := tijah:query-id(\"//panel[about(.,humbug)]\",$opt) let $n :=
tijah:nodes($x) for $i in $n return (fn:round(100*tijah:score($x,$i)),$i)");
printf("%s",res);
# test handling of not existing tag names
-res := xquery("dm","let $opt:=<TijahOptions collection=\"testcoll1\"/> let $x
:= tijah:query-id($opt,(),\"//humbug[about(.,dilbert)]\") let $n :=
tijah:nodes($x) for $i in $n return (fn:round(100*tijah:score($x,$i)),$i)");
+res := xquery("dm","let $opt:=<TijahOptions ft-index=\"testcoll1\"/> let $x :=
tijah:query-id(\"//humbug[about(.,dilbert)]\",$opt) let $n := tijah:nodes($x)
for $i in $n return (fn:round(100*tijah:score($x,$i)),$i)");
printf("%s",res);
Index: test_union.xq
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_union.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_union.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_union.xq 4 Apr 2007 13:52:07 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//(chapter|section)//para[about(.,information retrieval)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_lms_allfeatures.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_lms_allfeatures.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_lms_allfeatures.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_lms_allfeatures.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//chapter[about(.//title,information) and
about(.//title,retrieval)]//section[about(.,XML) or about(.,SGML)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_downprop.xq
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_downprop.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_downprop.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_downprop.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//chapter[about(.,information
retrieval)]//section[about(.,pathfinder)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: qmil1.stable.out
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/qmil1.stable.out,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- qmil1.stable.out 20 Mar 2007 09:57:52 -0000 1.7
+++ qmil1.stable.out 4 Apr 2007 13:52:06 -0000 1.8
@@ -12,7 +12,7 @@
module(pathfinder);
# test score calculation
-var res := xquery("dm"," let $opt:=<TijahOptions collection=\"testcoll0\"
txtmodel_model=\"NLLR\" debug=\"0\" top=\"99\"/> let $x :=
tijah:query-id($opt,(),\"//panel[about(.,dilbert)]\") let $n := tijah:nodes($x)
for $i in $n return (fn:round(100*tijah:score($x,$i)),$i) ");
+var res := xquery("dm"," let $opt:=<TijahOptions ft-index=\"testcoll0\"
ir-model=\"NLLR\" debug=\"0\" top=\"99\"/> let $x :=
tijah:query-id(\"//panel[about(.,dilbert)]\",$opt) let $n := tijah:nodes($x)
for $i in $n return (fn:round(100*tijah:score($x,$i)),$i) ");
printf("%s",res);
44.000000,
Index: test_lms_returnmatching.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_lms_returnmatching.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_lms_returnmatching.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_lms_returnmatching.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//section[about(.,pathfinder)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_lms_returnall.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_lms_returnall.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_lms_returnall.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_lms_returnall.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="true"
debug="0"/>
let $query := "//section[about(.,pathfinder)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query((),$query,$opt)
return <node rank="{$r}">{$n}</node>
Index: qmil2.stable.out
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/qmil2.stable.out,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- qmil2.stable.out 20 Mar 2007 09:57:52 -0000 1.5
+++ qmil2.stable.out 4 Apr 2007 13:52:06 -0000 1.6
@@ -12,7 +12,7 @@
module(pathfinder);
# test long queries
-var res := xquery("dm"," let $opt:=<TijahOptions collection=\"testcoll1\"
txtmodel_model=\"NLLR\" debug=\"0\" top=\"99\"/> return
tijah:query($opt,(),\"//panel[about(.,dilbert Geschwindigkeit ist der
Schluessel zum Erfolg speed is the key to success)]\") ");
+var res := xquery("dm"," let $opt:=<TijahOptions ft-index=\"testcoll1\"
ir-model=\"NLLR\" debug=\"0\" top=\"99\"/> return
tijah:query(\"//panel[about(.,dilbert Geschwindigkeit ist der Schluessel zum
Erfolg speed is the key to success)]\", $opt) ");
printf("%s",res);
<panel id="d4">
Index: qmil1.milS
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/qmil1.milS,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- qmil1.milS 20 Mar 2007 09:57:52 -0000 1.6
+++ qmil1.milS 4 Apr 2007 13:52:06 -0000 1.7
@@ -1,7 +1,7 @@
module(pathfinder);
# test score calculation
-var res := xquery("dm"," let $opt:=<TijahOptions collection=\"testcoll0\"
txtmodel_model=\"NLLR\" debug=\"0\" top=\"99\"/> let $x :=
tijah:query-id($opt,(),\"//panel[about(.,dilbert)]\") let $n := tijah:nodes($x)
for $i in $n return (fn:round(100*tijah:score($x,$i)),$i) ");
+var res := xquery("dm"," let $opt:=<TijahOptions ft-index=\"testcoll0\"
ir-model=\"NLLR\" debug=\"0\" top=\"99\"/> let $x :=
tijah:query-id(\"//panel[about(.,dilbert)]\",$opt) let $n := tijah:nodes($x)
for $i in $n return (fn:round(100*tijah:score($x,$i)),$i) ");
printf("%s",res);
Index: test_lms_and.xq
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_lms_and.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_lms_and.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_lms_and.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//title[about(.,pathfinder) and about(.,TIJAH)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_select_star1.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_select_star1.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_select_star1.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_select_star1.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//*[about(.,information retrieval)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_upprop.xq
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_upprop.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_upprop.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_upprop.xq 4 Apr 2007 13:52:07 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//chapter[about(.//section//title,information retrieval)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_nllr_allfeatures.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_nllr_allfeatures.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_nllr_allfeatures.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_nllr_allfeatures.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="NLLR"
+ ft-index="thesis"
+ ir-model="NLLR"
txtmodel_returnall="false"
debug="0"/>
let $query := "//chapter[about(.//title,information) and
about(.//title,retrieval)]//section[about(.,XML) or about(.,SGML)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_select_star2.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_select_star2.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_select_star2.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_select_star2.xq 4 Apr 2007 13:52:07 -0000 1.4
@@ -1,10 +1,10 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//section[about(.//*,information retrieval)]"
-for $n at $r in tijah:query($opt,(),$query)
+for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: test_nllr_manyqueries.xq
===================================================================
RCS file:
/cvsroot/monetdb/pathfinder/modules/pftijah/Tests/test_nllr_manyqueries.xq,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- test_nllr_manyqueries.xq 20 Mar 2007 09:57:52 -0000 1.3
+++ test_nllr_manyqueries.xq 4 Apr 2007 13:52:06 -0000 1.4
@@ -1,11 +1,11 @@
let $opt := <TijahOptions
- collection="thesis"
- txtmodel_model="LMS"
+ ft-index="thesis"
+ ir-model="LMS"
txtmodel_returnall="false"
debug="0"/>
let $query := "//chapter[about(.//title,information) and
about(.//title,retrieval)]//section[about(.,pathfinder) or about(.,tijah)]"
for $i in (0 to 1000)
- for $n at $r in tijah:query($opt,(),$query)
+ for $n at $r in tijah:query($query,$opt)
return <node rank="{$r}">{$n}</node>
Index: qmil2.milS
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/Tests/qmil2.milS,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- qmil2.milS 20 Mar 2007 09:57:52 -0000 1.4
+++ qmil2.milS 4 Apr 2007 13:52:06 -0000 1.5
@@ -1,7 +1,7 @@
module(pathfinder);
# test long queries
-var res := xquery("dm"," let $opt:=<TijahOptions collection=\"testcoll1\"
txtmodel_model=\"NLLR\" debug=\"0\" top=\"99\"/> return
tijah:query($opt,(),\"//panel[about(.,dilbert Geschwindigkeit ist der
Schluessel zum Erfolg speed is the key to success)]\") ");
+var res := xquery("dm"," let $opt:=<TijahOptions ft-index=\"testcoll1\"
ir-model=\"NLLR\" debug=\"0\" top=\"99\"/> return
tijah:query(\"//panel[about(.,dilbert Geschwindigkeit ist der Schluessel zum
Erfolg speed is the key to success)]\", $opt) ");
printf("%s",res);
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins