Hi Vincent, I’ll be happy to review the changes also. Best to have a user that has recent experience with the deficits in the current docs make changes that clarify their issues.
Thanks, Chris > On Jan 18, 2019, at 12:09 PM, vincent ventresque > <[email protected]> wrote: > > Hi ajs6f > > Thank you for your proposal, I'd be glad to contribute (as soon as I find a > moment, maybe next week). > > By the way, I wrote a small tutorial (in french) for our project, and some > PHP code to use with Fuseki + a sample dataset (data from french national > library). I consider translating the tuto into English, because I think > Fuseki is great to learn RDF and LOD : do you think s.o could be interested > in reviewing the tuto? > > Vincent > > Le 18/01/2019 à 18:30, ajs6f a écrit : >> Hi, Vincent-- >> >> As mentioned in a recent thread, you needn't be a committer or have any >> other official role to improve that page. Just use the link in the upper >> right to submit your suggested changes, and I promise to review/commit them! >> (Probably with some help from Chris or Osma, who know the text-indexing >> machinery much much better than do I.) >> >> ajs6f >> >>> On Jan 18, 2019, at 11:32 AM, Vincent Ventresque >>> <[email protected]> wrote: >>> >>> Hi Chris, >>> >>> I'd like to add sthg about the documentation page : it's a bit laconic, and >>> I spent a few hours to understand that values have to be provided in config >>> file for dataset uri. >>> >>> Furthermore, I had to search on Stackoverflow, and saw other users had the >>> same problem with jena-text config) >>> >>> Maybe s.o. could add some explanations on this page? >>> >>> -- give a value for dataset URI (replace <#dataset> with sthg like >>> :my_dataset) >>> >>> -- give a path for Lucene index files => this will create a directory >>> >>> -- give a path for TDB (tdb:location >>> "/home/.../fuseki/run/databases/My_dataset") >>> >>> -- if you don't set environment variables, run fuseki after changing >>> directory ("cd My_Fuseki_install) and give relative paths for command >>> arguments (" --config=run/my_config.ttl "). >>> >>> >>> >>> >>> >>> >>> Le 18/01/2019 à 17:13, Chris Tomlinson a écrit : >>>> Hi, >>>> >>>> 1) If you’re using a default config, it does not have a working jena-text >>>> configuration. The config will need to include skos:prefLabel in the >>>> entity map. >>>> >>>> 2) when you change the jena-text in significant ways, such as changing >>>> what analyzer is used for a given property and so on, then you’ll need to >>>> rebuild the Lucene index via reloading the dataset or using the >>>> textIndexer >>>> <https://jena.apache.org/documentation/query/text-query.html#building-a-text-index>. >>>> I don’t recall this being mentioned as part of your testing >>>> >>>> 3) Please indicate exactly which item you’re using >>>> jena-fuseki-war-3.9.0.war or jena-fuseki-webapp-3.9.0.jar etc, and the >>>> config file itself. The error you’ve mentioned previously: >>>> >>>>> Jan 17 17:00:28 semantic-dev java[16800]: [2019-01-17 17:00:28] Config >>>>> INFO Load configuration: >>>>> file:///home/text/tools/apache-jena-fuseki-3.9.0/run/configuration/text_index.ttl >>>>> >>>>> <file:///home/text/tools/apache-jena-fuseki-3.9.0/run/configuration/text_index.ttl> >>>>> Jan 17 17:00:28 semantic-dev java[16800]: [2019-01-17 17:00:28] >>>>> WebAppContext WARN Failed startup of context >>>>> o.e.j.w.WebAppContext@4159e81b{Apache Jena Fuseki >>>>> Server,/,file:///home/text/tools/apache-jena-fuseki-3.9.0/webapp/,UNAVAILABLE >>>>> <file:///home/text/tools/apache-jena-fuseki-3.9.0/webapp/,UNAVAILABLE>} >>>>> Jan 17 17:00:28 semantic-dev java[16800]: at >>>>> org.apache.jena.fuseki.build.FusekiConfig.readAssemblerFile(FusekiConfig.java:148) >>>> suggests to me that something in the config file is confusing the >>>> readAssemblerFile. It doesn’t look like it’s failing in the reading the >>>> jena-text portion of the config. >>>> >>>> If http://api.finto.fi/download/mesh/mesh-skos.ttl >>>> <http://api.finto.fi/download/mesh/mesh-skos.ttl> the dataset, then can >>>> you cut it down to just a small test case with some concepts with “medi” >>>> and a few without? That along with the other information should help move >>>> this further along.. >>>> >>>> 4) Your query: >>>> >>>>> PREFIX skos: <http://www.w3.org/2004/02/skos/core# >>>>> <http://www.w3.org/2004/02/skos/core#>> >>>>> PREFIX text: <http://jena.apache.org/text# <http://jena.apache.org/text#>> >>>>> SELECT * >>>>> WHERE >>>>> { >>>>> GRAPH <http://www.yso.fi/onto/mesh/ <http://www.yso.fi/onto/mesh/>> >>>>> { >>>>> ?concept text:query (skos:prefLabel "medi") . >>>>> ?concept skos:prefLabel ?prefLabel . >>>>> >>>>> # FILTER ( REGEX(?prefLabel, "\\bmedi", "i")) >>>>> } >>>>> } >>>>> limit 10 >>>> might effectively just be executing: >>>> >>>>> ?concept skos:prefLabel ?prefLabel . >>>> if there is actually no jena-text config - I haven’t checked what happens >>>> when there is no TextIndex configured and the text:query is invoked, but >>>> may be a noop >>>> >>>> Thanks, >>>> Chris >>>> >>>> >>>>> On Jan 18, 2019, at 8:08 AM, Mikael Pesonen <[email protected]> >>>>> wrote: >>>>> >>>>> >>>>> >>>>> On 18/01/2019 13:40, Andy Seaborne wrote: >>>>>> On 17/01/2019 15:45, Mikael Pesonen wrote: >>>>>>> On 17/01/2019 17:38, Andy Seaborne wrote: >>>>>>>> On 17/01/2019 12:51, Mikael Pesonen wrote: >>>>>>>>> On 17/01/2019 13:58, Andy Seaborne wrote: >>>>>>>>>> On 16/01/2019 12:50, Mikael Pesonen wrote: >>>>>>>>>>> Hi, >>>>>>>>>>> >>>>>>>>>>> I'm trying to get text search work. Sparql REGEX takes few seconds >>>>>>>>>>> to finish so hoping this would be faster. Application is term >>>>>>>>>>> search using SKOS ontology. >>>>>>>>>>> >>>>>>>>>>> First tested if it's enabled by default >>>>>>>>>>> >>>>>>>>>>> ?concept text:query (skos:prefLabel "medi") . >>>>>>>>>>> ?concept skos:prefLabel ?prefLabel >>>>>>>>>>> >>>>>>>>>>> That returns all concepts so I guess it's not enabled. >>>>>>>>>> If it returns all concepts, the first line matched (otherwise you >>>>>>>>>> get none). If so, there is a text index and "medi" (case >>>>>>>>>> insensitive) matches Lucene rules, everything. >>>>>>>>> What does this mean then, why is it matching everything? >>>>>>>> If zero matches, you don't get to ?concept skos:prefLabel ?prefLabel >>>>>>>> (if the text index is correct) >>>>>>>> >>>>>>>> The query above, if the index is setup correctly, gets all concepts >>>>>>>> where any skos:prefLabel matches "medi" (not just at the start), then >>>>>>>> gets all skos:prefLabel for those concepts. That does not mean >>>>>>>> ?prefLabel only matches "medi" >>>>>>>> >>>>>>>> :c skos:prefLabel "medi" ; >>>>>>>> skos:prefLabel "Other" . >>>>>>>> >>>>>>>> will return 2 matches including ?prefLabel="Other" >>>>>>> Yes that is how I understood it. But ?concept text:query >>>>>>> (skos:prefLabel "medi") returns all concepts, also those that don't >>>>>>> have any label having "medi". >>>>>> Then I don't understand what is going on. >>>>>> >>>>>> Do you have a complete, minimal example that someone can use to recreate >>>>>> the situation? >>>>>> >>>>> This is the query: >>>>> >>>>> PREFIX skos: <http://www.w3.org/2004/02/skos/core#> >>>>> PREFIX text: <http://jena.apache.org/text#> >>>>> SELECT * >>>>> WHERE >>>>> { >>>>> GRAPH <http://www.yso.fi/onto/mesh/> >>>>> { >>>>> ?concept text:query (skos:prefLabel "medi") . >>>>> ?concept skos:prefLabel ?prefLabel . >>>>> >>>>> # FILTER ( REGEX(?prefLabel, "\\bmedi", "i")) >>>>> } >>>>> } >>>>> limit 10 >>>>> >>>>> and graph is dump copied from here: https://finto.fi/mesh/en/ >>>>> end of page "Download this vocabulary" >>>>> >>>>> So to make clear, we have made zero configuration on jena/fuseki, all is >>>>> default from 3.9.0 package. >>>>>> Andy >>>>> -- >>>>> Lingsoft - 30 years of Leading Language Management >>>>> >>>>> www.lingsoft.fi >>>>> >>>>> Speech Applications - Language Management - Translation - Reader's and >>>>> Writer's Tools - Text Tools - E-books and M-books >>>>> >>>>> Mikael Pesonen >>>>> System Engineer >>>>> >>>>> e-mail: [email protected] >>>>> Tel. +358 2 279 3300 >>>>> >>>>> Time zone: GMT+2 >>>>> >>>>> Helsinki Office >>>>> Eteläranta 10 >>>>> FI-00130 Helsinki >>>>> FINLAND >>>>> >>>>> Turku Office >>>>> Kauppiaskatu 5 A >>>>> FI-20100 Turku >>>>> FINLAND >>>>>
