dataesr/scientific-paragraphs-categorization huggingface dataset:
The number of possible relaxed queries can be huge. To find the most relevant relaxed federated queries efficiently, we use approaches that compute relaxed queries from the most to the least similar to the original query  [7, 8, 15, 16]. Though, the most similar queries may produce no results. In a distributed environment, verifying each relaxed federated query is not feasible. So the challenge is to find the most similar relaxed queries that return a non-empty result from datasets with compatible licenses while limiting communication costs. Our research question is, given a SPARQL query and a federation of licensed datasets, how to guarantee a relevant and non-empty query result whose license is compliant with each license of involved datasets? The challenge is to limit the communication cost when the relaxation process is necessary.
Related Work To our knowledge, there is no federated query engine that ensures license compliance with all licenses involved in query execution. Many works focus on access control over linked data using policy-based  [5, 19, 20, 28] , view-based  [9] , or query-rewriting  [24]  approaches. In these works, datasets are protected by access control rules that prevent non-authorized users from querying data of each dataset. These approaches do not resolve our problem statement because having the right to query datasets individually does not mean that it should be possible to execute a federated query involving these datasets.
Compatibility graph of licenses To know if a result set can be licensed, we need to know the license(s) with whom all licenses of datasets involved in a federated query are compatible. Automatic license compatibility requires machine-readable licenses. License expression languages such as CC REL  6  , ODRL, or L4LOD 7  enable fine-grained RDF description of licenses. Works like  [31]  and  [3]  use natural language processing to automatically generate RDF licenses from licenses described in natural language. Other works such as  [13, 30]  propose a set of well-known licenses in RDF described in CC REL and ODRL  8. Thereby, we suppose that there exist consistent licenses described in RDF. A compatibility graph of licenses contains a set of licenses partially ordered by compatibility. It can be defined by hand using, for instance, the license compatibility chart of Creative Commons.
[8, 15]  focus on obtaining a certain number of alternative results (top-k) by relaxing a query that produces no results. Their challenge is to execute as less as possible relaxed queries to obtain the top-k results. Relaxed queries are executed in a similarity-based rank order to avoid executing all relaxed queries in the relaxation graph. Information content  [29]  is used to measure the similarity between a relaxed query and the original query. That is, statistical information about the concerned dataset, like the number of entities per class and the number of triples per property. Nevertheless, the number of failing relaxed queries executed before obtaining the top-k results can be large. Thus, it is necessary to identify unnecessary relaxations that do not generate new answers. Relaxed queries containing unnecessary relaxation should not be executed.
[15]  and  [8] , base their relaxation rules only on the subproperties and subclasses of a class used in a triple pattern. 2. The similarity definition of  [16] , is only based on the relations of the relaxation graph, where relaxed queries are ordered based on the subsumption relation of their result sets. This partial order makes that it is not always possible to compare two relaxed queries. [15]  and  [8]  use information content measures to obtain a total order between the original query and the relaxed queries. Such similarity is computed using statistical information of the concerned dataset, e. g. , the number of entities per class and the number of triples per property. 3. Concerning the information needed, these works use the dataset ontology.
RDFS properties [15] and  [8]  also use dataset statistics to calculate the information content of relaxed queries. 4. For pruning the relaxation graph,  [16]  avoids redundant query relaxation by reducing ontologies, e. g. , it uses the ontology without saturation. [15]  uses the number of entities per classes and the number of triples per properties to identify query relaxation that does not generate new results. Finally,  [8]  identifies the set of triple patterns that fail to return results. Thus, it only keeps relaxed queries that do not contain failing triple patterns. We consider that these three approaches  [8, 15, 16]  can be used to relax federated queries because they can produce relaxed queries using the dataset ontology and statistical information (to calculate selectivity) without needing the RDF graph (i.
Data summaries In this work, we need data summaries to calculate similarity measures (based on information content), selectivity, but also to limit the communication overhead, during the distributed query relaxation process. A very complet survey of the state-of-the about summarization methods for semantic RDF graphs is proposed in  [4]. In federated query processing, some federated query engines, use statistics to reduce the number of requests sent to data sources during the source selection and the query optimization steps  [10, 27, 33, 34]. Analysis of state-of-the-art federated query engines can be found in  [23, 26, 32]. VoID  15  , is the Vocabulary of Interlinked Datasets  [6]. It allows to formally describe linked RDF datasets with metadata like contact, topic, licenses, SPARQL endpoint, url of data dumps, basic statistics, etc.
In particular, with VoID descriptions is possible to describe dataset instances, i. e. , the number of instances of a given class and the number of triples that have a certain predicate. DARQ  [27]  (from Distributed ARQ)  16  is the first query engine that allows querying multiple, distributed SPARQL endpoints. DARQ introduced service descriptions which provide a declarative description of the data available from an SPARQL endpoint  17. Service descriptions include statistical information used for query optimization represented in RDF. A service description describes the data available from a data source in form of capabilities. Capabilities define what kind of triple patterns can be answered by the data source. The definition of capabilities is based on predicates. Statistical information includes the total number of triples in data sources and average selectivity estimates for combinations of subject, predicate, and object.
SPLENDID  [10] , a query optimization strategy for federating SPARQL endpoints, uses VoID descriptions of datasets to speed-up query processing. The statistical information for every predicate and type are organized in inverted indexes which map predicates and types to a set of tuples containing the data source and the number of occurrences in the data source. For triple patterns with bound variables which are not covered in the VoID statistics, SPLENDID uses SPARQL ASK queries including the triple pattern to all pre-selected data sources and remove failing sources. This improves the source selection efficiency. HIBISCuS  [33] , a join-aware source selection algorithm, discards dataset that are relevant for a triple pattern, but that do not contribute to a query result. It proposes detailed data summaries, dataset capabilities, containing all the distinct properties with all the URI authorities of their subjects and objects.
Otherwise, based on the OMBS approach  [8] , we propose to the query issuer a set of relaxed queries whose result sets are licensable and non-empty. Several sub-federations may produce a licensable and non-empty result. In that case, it is possible to choose the sub-federation that produces a result set licensable by the least restrictive license  19. Consider the query Q of Listing 1. 1, and the federation containing datasets D1, D2, and D3 shown in Tables  2 3 4. As there is no license compliant with the licenses of D2 and D3, the result set of Q cannot be licensed. Thus, our strategy defines the sub-federations F 1={D1, D2} and F 2={D1, D3} that avoid license conflicts (cf. Figure  2 ). The source selection for Q over F 1 and F 2 fails to obtain a data source for each triple pattern. This launches a process of federated query relaxation for each sub-federation.
Query relaxation techniques used in FLiQue In this work, we use query relaxation using RDFS entailment and RDFS ontologies. We consider that ontologies of datasets are accessible and that SPARQL      endpoints expose saturated RDF data (or support on-the-fly entailment) according to the RDFS entailment rules rdfs7 and rdfs9. We use the relaxations of triple patterns and queries as proposed in  [15]. Triple Pattern Relaxation. Given two triple patterns tp and tp , tp is a relaxed triple pattern obtained from tp, denoted tp ≺ tp , by applying one or more triple pattern relaxations. We use the three following triple pattern relaxations: -Simple relaxation replaces a constant of a triple pattern by a variable. For example, tp 4 = ex:Ben, ex:teaches, ?course , can be relaxed to tp 4 = ?x, ex:teaches, ?course , thus tp 4 ≺ s tp 4.
Information content measures used in FLiQue Analyzing all relaxed queries is time-consuming and unnecessary. We use information content measures to compute the similarity of relaxed queries to the original query. To avoid the analysis of an important number relaxed queries, our approach generates and executes relaxed queries from the most to the least similar. This execution allows to verify that the result set is not empty. It is stopped when the first result is returned. We use the similarity mesures proposed in  [15] , and explained in the following. Similarity between terms. FLiQue uses three similarity measures for terms in a triple pattern. They correspond to the three relaxations described in Section 3. 1. -Similarity between classes is Sim(C, C ) = IC(C ) IC(C) where IC(C) is the information content of C: -logP r(C), where P r(C) = |Instances(C)| |Instances| is the probability of finding an instance of class C in the RDF dataset.
For example, if the subject or object of a triple pattern is a class c 1 and is relaxed to its super class c 2 using type relaxation, the similarity between c 1 and c 2 is Sim(c 1 , c 2 ). Notice that, the similarity between classes is zero when all the instances in the RDF dataset belong to the super class C , i. e. , P r(C ) = 1 and thus -logP r(C ) = 0. Notice also that the similarity between classes is undefined when all the instances belong to the super class C , and none to C, i. e. , P r(C) = 0 and thus -logP r(C ) = undef ined. -Similarity between properties is Sim(P, P ) = IC(P ) IC(P ) where IC(P ) is the information content of P : -logP r(P ), where P r(P ) = |T riples(P )| |T riples| is the probability of finding a property of P in triples of the RDF dataset. For example, if the predicate of a triple pattern is a property p 1 and is relaxed to its super property p 2 using property relaxation, the similarity between p 1 and p 2 is Sim(p 1 , p 2 ).
Notice that as the similarity between classes, the similarity between properties is zero when all the triples in the RDF dataset belong to the super property P , and the similarity between properties is undefined when all the triples belong to the super property P , and none to P. -Similarity between constants and variables is Sim(T const , T var ) = 0. For example, if the object of a triple pattern t const is a class and is relaxed to a variable t var using simple relaxation, the similarity between t const and t var is 0. Similarity between triple patterns Given two triple patterns tp and tp , such that tp ≺ tp , the similarity of the triple pattern tp to the original triple pattern tp, denoted Sim(tp, tp ), is the average of the similarities between the terms of the triple patterns: Similarity between queries.
Given two queries Q and Q , such that Q ≺ Q , the similarity of the original query Q to the original query Q, denoted Sim(Q, Q ), is the product of the similarity between triple patterns of the query: Sim(tp, tp ) = 1 Sim(Q, Q ) = n i=1 w i. Sim(tp i , tp i ) Where tp i is a triple pattern of Q, tp i a triple pattern of Q , tp i ≺ tp i , and w i ∈ [0, 1] is the weight of triple patterns tp i. Weight can be specified by the user to take into account the importance of a triple pattern tp i in query Q. Thus Sim(Q, Q ) ∈ [0, 1] is a function that defines a total order among relaxed queries. This similarity function is monotone, i. e. , given two relaxed queries Q (tp 1 ,. , tp n ) and Q (tp 1 ,. , tp n ) of the user query Q, if Q ≺ Q then Sim(Q, Q ) ≥ Sim(Q, Q ). Considering the query Q and datasets D1 and D2, Sim(Q, Q 4b) = 0.
Data summaries used in FLiQue FLiQue collects dataset summaries and ontologies before executing queries. A data summary is a compact structure that represents an RDF dataset. Using dataset statistics and dataset capabilities as in  [34] , allow us to limit communication cost in the similarity calculation and the source selection process. Dataset statistics contain VoID descriptions, such as the number of entities per class and the number of triples per property. Having dataset statistics is twofold; they allow computing similarities, and they help in the source selection process. Tables  5  and 6  show respectively statistics about properties and classes for subfederations F1 and F2. In Table  5 , the property ex:teaches has no triples in F2. So there is no data source for tp4 and tp4 b (cf.
Global FLiQue algorithm and the similarity-based relaxation graph Algorithm 1 shows the global approach of FLiQue. After a process of source selection for a federated query Q, FLiQue checks if the result set can be licensed (Line 5). If that is the case (L == ∅ is false), the query plan as long as the set of licences that can protect the result set are returned (Line 18). Then the query is optimized and executed as usual. When the result set cannot be licensed because there is no license compliant to every license of selected datasets, FLiQue calls for a source selection over each sub-federation (Line 6). Each sub-federation that can evaluate the query is returned as long as with the corresponding set of compliant licenses (Line 10). If all source selections fail (Line 11), FLiQue relaxes the query conditions and proposes alternative relaxed federated queries.
Relaxed queries are generated and executed from the most to the least similar. When we find one licensable and non-empty candidate query, we stop the relaxation process. OMBS  [8]  guarantees that a candidate query is the most similar to Q for a sub-federation. In the following, we explain how FLiQue finds the candidate query for the sub-federation F2. First, the algorithm computes the MFS of the original query, MFS(Q)={ex:Ben ex:teaches ?course}. It contains only tp4 because F 2 does not contain a data source to evaluate tp4. Using the MFS, the algorithm considers only relaxed queries that contain a relaxation of tp4. Algorithm 1: The global approach of FLiQue. 1 Function FLiQue(Q, F , E, S, C): Data: Q: RDF Query, F : Federation of endpoints, E ⊆ F : Set of pertinent endpoints for Q, S: Dataset summaries, C: Compatibility graph of licenses.
Setup and implementation FLiQue is implemented over CostFed, which relies on a join-aware triple-wise source selection. Recent studies show that the source selection of CostFed least overestimates the set of capable data sources, with a small number of ASK requests  [32, 34]. These performances make CostFed a good choice for our licenseaware query processing strategy. The join ordering of CostFed is based on leftdeep join trees. It implements bind and symmetric hash joins. Our test environment uses LargeRDFBench  [32]. A benchmark with more than 1 billion triples for SPARQL endpoints. This benchmark contains 32 federated queries that are executed over a federation of 11 interlinked data sources (we consider the three Linked TCGA datasets as only one). We identified the license of each dataset (cf.
In our experiments we are not interested in obtaining the complete query results of all these queries but in showing that preserving licences during federated query processing is possible. Thus, queries were executed until obtaining the first result (LIMIT 1 was added to all queries). Our experiment runs on a single machine with a 160xIntel(R) Xeon(R) CPU E7-8870 v4 2. 10GHz 1,5 Tb RAM. Each dataset of LargeRDFBench is saturated and made available using a single-threaded Virtuoso endpoint in a docker container with 4 Gb RAM. Between each query execution, caches are reset.
Performance of FLiQue vs CostFed To measure the overhead produced by FLiQue, we compare two different federated query engines: CostFed and CostFed+FLiQue (that we call FLiQue to simplify). They correspond to the original implementation of CostFed 20  and our   We executed all queries 5 times with each federated query engine. We measured the time in milliseconds to return the first result of each query. Using the capable data sources by query, and the compatibility graph of licenses, we identified 16 queries whose result set cannot be licensed. Table  9  shows these queries, their conflicting capable data sources and conflicting licenses. 10 queries need to be relaxed, they are shown in bold. We recall that the DBpedia license (CC BY-SA) is not compliant with the licenses of Jamendo (CC BY-NC-SA), Linked TCGA and Drug bank (CC BY-NC).
The average time to check license conflicts is 296 milliseconds which is negligible. Evaluation of queries that do not need relaxation. Figure  8  presents the execution time of the 22 queries of LargeRDFBench that do not need relaxation. We identify two sets of queries. -For 16 queries, {S2, S3, S4, S5, S7, S11, S12, S13, S14, C1, C2, C4, C6, C7, L2, L4}, FLiQue finds a license that can protect the result set when the query is executed on the complete federation. For these queries, the overhead of FLiQue is negligible and corresponds to the time to check license conflicts among the capable datasets. This overhead depends on the number of distinct licenses that protect the capable datasets. -For 6 queries, {S1, S6, S9, C3, L1, L3}, FLiQue does not find a license that can protect the result set when the query is executed over the complete federation.
However, it finds a sub-federation such that the original query returns a non-empty result set that is licensable. In this case, the overhead of FLiQue corresponds to the time to check license conflicts, to compute subfederations, and to execute the original query on these sub-federations until the first result is returned. This overhead depends on the number of tested sub-federations. The number of sub-federations depends on the number of distinct conflicting licenses by query. In our test environment, this number is always 2. For instance, conflicting licenses CC BY-SA, CC BY-NC, and CC BY-NC-SA can be separated into two non-conflicting sets {CC BY-SA} and {CC BY-NC, and CC BY-NC-SA}. These sub-federations are ordered by the number of datasets in the federation. In the benchmark, the average time to generate the sub-federations and find a non-empty result set is 11020 milliseconds.
Discussion [8, 15] used in their experiments the datasets generated with the LUBM benchmark  [11]. LUBM generates synthetic data as one data source and was developed to evaluate systems with different reasoning capabilities. [15]  used 7 queries with a number of triple patterns ranging from 2 to 5. [8]  modified these 7 queries to added constraints. In their modified queries, triple patterns range from 2 to 15, the average is 7. Their experimental goal was to show the number of relaxed queries executed until obtaining top-k results. Our goal is different. We aim to show that preserving licenses during federated query processing is possible. LargeRDFBench is the only benchmark with federated queries. It is composed of several real-world interlinked datasets whose federated queries were designed by domain specialists.
This benchmark was not defined for reasoning. As it does not include ontologies  22  we searched them  23. Several properties or classes of some datasets are not defined in the found ontologies, and hierarchies in concept ontologies are frequently undefined. As LargeRDFBench was defined to evaluate federated query processing, its federated queries have many variables. Very few triple patterns have classes in objects or subjects. That is why query relaxation was mainly based on property relaxation. Only two classes in objects were relaxed (dbo:Drug in S10 and dbpedia:Drug in C9). LargeRDFBench datasets are of multiple domains. They were chosen because they are interlinked, i. e. , they have owl:sameAs relationships, the subject/object of one dataset exists in another dataset, or some predicates (like title and genericName) have the same literal values.
FLiQue is a step towards facilitating and encouraging the publication and reuse of licensed resources in the Web of Data. FLiQue is not a data access control strategy. Instead, it empowers well-intentioned data users in respecting the licenses of datasets involved in a federated query. This work has several perspectives. One perspective considers other aspects of licenses related to usage contexts like jurisdiction, dates of reuse, etc. Another perspective is about estimating the selectivity of relaxed queries and use it to help users choose the best-relaxed query for their purposes. Information content measures are currently used to define similarity between queries; nevertheless, semantic similarity may also be used, for instance, owl:sameAs relationships. A perspective not directly related to FLiQue but to the used benchmark, is to analyze the ontologies of datasets composing LargeRDFBench and complete them.
To do so, we used historical and generated data for predictive model development using machine learning. Machine learning is an approach which uses algorithms that improve upon training on large datasets and is able to find complex patterns, make predictions and decisions. In this work, we used two training datasets: one comprising the data extracted from literature (several thickness determination methods) and another containing experimental data produced in our laboratory (thickness determination by QCM-D). In the first part of the work, the most important parameters influencing coating buildup were determined. In the second part, a thickness predictive model was built using the training set, and its performance was evaluated. Finally, we validated the model on LbLs which were not in the training set, and were able to predict the coating thickness (Fig.
Results and discussion Data collection. The first step of the work consisted in data collection from the literature, which represents the first dataset. It should be stated that currently in the literature no established database is available related to LbL coating thickness, and the available experimental data is relatively scarce compared to the number of LbL related articles. The second dataset was based on the QCM-D experiments done in the laboratory. For the data extracted from the literature, different ways of thickness calculation/estimation were used, such as AFM, ellipsometry, confocal microscopy. Coating thickness determined by these methods may differ, but due to the limited amount of the available data, we selected to include all the data regardless of the thickness measurement method.