Skip to content

The Privacy Proxy Services

Thomas Cerqueus edited this page Nov 2, 2015 · 63 revisions

Services

This page considers two variables: server-url and path. Examples of values are respectively https://eexcess-dev.joanneum.at and eexcess-privacy-proxy-issuer-1.0-SNAPSHOT/issuer.

Recommendation

  • Get recommendations. This service forwards the query to the Federated Recommender and return the recommendations.

  • URL: {server-url}/{path}/recommend,

  • Method: POST,

  • Input: JSON (see documentation),

  • Output: JSON (see documentation).

  • Get details. This service forwards the query to the Federated Recommender and return the detailed results.

  • URL: {server-url}/{path}/getDetails,

  • Method: POST,

  • Input: JSON (see documentation),

  • Output: JSON (see documentation).

PEAS

  • Get co-occurrence graph. This service returns the co-occurrence graph of query terms. It must be used wisely, as the result is potentially voluminous (caching the result is recommended).

  • URL: {server-url}/{path}/getCoOccurrenceGraph,

  • Method: GET,

  • Input: None,

  • Output: JSON (see documentation).

  • Get maximal cliques. This service returns the set of maximal cliques extracted from the co-occurrence graph. Similarly to the previous service, it should be used wisely.

  • URL: {server-url}/{path}/getMaximalCliques,

  • Method: GET,

  • Input: None,

  • Output: JSON (see documentation).

Information about partners

  • Get registered partners. This service forwards the request to the Federated Recommender and returns the list of partners currently registered with some statistics.

  • URL: {server-url}/{path}/getRegisteredPartners,

  • Method: GET,

  • Input: None,

  • Output: JSON (see documentation).

  • Get partner favicon. This service returns the favicon of a given partner.

  • URL: {server-url}/{path}/getPartnerFavIcon,

  • Method: GET,

  • Input: None,

  • Parameters: partnerId (the partners id can be retrieved using the getRegisteredPartners service),

  • Output: An image (image/png).

Miscellaneous

  • Suggests categories. This service is used to suggest DBpedia categories given an input. It is provided by the DoSeR framework.

  • URL: {server-url}/{path}/suggestCategories,

  • Method: POST,

  • Input: JSON (see documentation),

  • Output: JSON (see documentation).

  • Recognize Entity. This service is used to recognize entities in a set of paragraphs. It is provided by the DoSeR framework.

  • URL: {server-url}/{path}/recognizeEntity ,

  • Method: POST,

  • Input: JSON (format: {"paragraphs":[{"id":"0", "headline":"test headline", "content":"..."}]}),

  • Output: JSON.

  • Get preview image. This service returns a default image if the media is not available.

  • URL: {server-url}/{path}/getPreviewImage,

  • Method: GET,

  • Input: None,

  • Parameters: type (can be text, audio, 3d, image, video, other or unknown),

  • Output: An image (image/png).

Logging

  • Log interaction. This service is used to log users' interactions on the Privacy Proxy.
  • URL: {server-url}/{path}/log/{InteractionType} (*),
  • Method: POST,
  • Input: JSON (see documentation),
  • Output: None.

All the details are given here.

(*) InteractionType is one of these values: moduleOpened, moduleClosed, moduleStatisticsCollected, itemOpened, itemClosed, itemCitedAsImage, itemCitedAsText, itemCitedAsHyperlink, itemRated.

Implementation

This section describes the technical details of the implementation of the privacy proxy. It more specifically describes the query log, the co-occurrence graph and its set of maximal cliques.

Query log

When a request reaches the privacy proxy, in addition of being processed, it is stored in a query log. A query log is a file containing multiples lines. Each line corresponds to a query and contains two pieces of information: the timestamp (number of milliseconds between January 1st 1970 and the date the query was logged) and the keywords of the query. The query log is regularly flushed out (i.e., old queries are removed) to prevent it from becoming too voluminous and unexploitable. The configuration file (/src/main/resources/config.properties) contains several attributes to parametrize the management of the query log:

  • data.directory: location of the query log file;
  • data.queryLog: name of the query log file;
  • data.queryLog.delay: delay (in milliseconds) between two flush-outs;
  • data.queryLog.window: time window (in milliseconds) in which queries must belong to in order to be kept in the log when it is flushed out.

The query log is not accessible through any service, as it would jeopardize users' privacy (even if user identifiers are not stored).

Co-occurrence graph and Maximal cliques

The privacy proxy offers two services to access the co-occurrence graph of keywords and maximal cliques within this graph: The co-occurrence graph represents an privacy-preserving aggregated view of the query log (and so does the set of maximal cliques). The extraction of the co-occurrence graph is costly, and the computation of maximal cliques is even more complex. For this reason, the services do not provide up-to-date information. The co-occurrence graph and the maximal cliques are regularly computed and stored in cache. The following parameters of configuration file are used:

  • cache.directory: location of the cache files;
  • cache.coOccurrenceGraph: name of the file containing the co-occurrence graph;
  • cache.cliques: name of the file containing the co-occurrence graph;
  • cache.delay: delay (in milliseconds) between two updates of the caches.

The co-occurence graph and the set of cliques are represented in JSON (as described in the documentation).