You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stanbol.apache.org by Rupert Westenthaler <ru...@gmail.com> on 2012/11/30 13:27:00 UTC

Stanbol Namespace Prefix Service (was: How to introduce new features in Stanbol)

Hi all

Fabians mail just reminded me that I have not announced the new
feature I have started to work on yesterday.

The Stanbol Namespace Prefix Service allows to lookup and manage
namespace prefixes originating from different sources. Such a service
was discussed several times (if I remember correctly even before
incubation to Apache) but got never implemented.

STANBOL-824 [1] now defines such a Service. Its design is very Similar
to the DataFileProvider only that in this case the Service is called
NamespacePrefixProvider.

In addition there is the NamespacePrefixService that extends the above
interface by two utility methods that convert "{prefix}:{localname}"
<-> "uri" and a method that allows to add additional prefixes.

There is a default implementation of NamespacePrefixService that
registers itself as DataFileProvider with the highest priority (this
is similar to the MainDataFileProvider).

To ensure backwards compatibility there is also a
DefaultNamespaceMappingsProvider that hold all the mappings currently
defined in the NamespaceEnum of the Enhancer and the Entityhub.

The current NamespaceEnum will not be deprecated by this new Service.
However all entries of those enumerations that are not directly
referenced by the Ontologies of the Enhancer/Entityhub will be
deprecated. This avoids dependencies of the servicesapi and core
modules to the new service but ensures that the new  service is used
for all user level configurations.

In addition the new Service will be implemented so that it can be used
also outside of an OSGI environment.

Finally it is also planed to implement a NamespacePrefixProvider for
http://prefix.cc/

feedback very welcome.

best
Rupert

[1] https://issues.apache.org/jira/browse/STANBOL-824




--
| Rupert Westenthaler             rupert.westenthaler@gmail.com
| Bodenlehenstraße 11                             ++43-699-11108907
| A-5500 Bischofshofen

Re: Stanbol Namespace Prefix Service (was: How to introduce new features in Stanbol)

Posted by Reto Bachmann-Gmür <re...@wymiwyg.com>.
On Fri, Nov 30, 2012 at 2:56 PM, Fabian Christ <christ.fabian@googlemail.com
> wrote:

> 2012/11/30 Reto Bachmann-Gmür <re...@apache.org>
>
> > Was there something missing ny the service I added for CLEREZZA-222 or
> why
> > are you suggesting a new interface?
> >
>
> You're right that issue is about integrating the service into the jena
serializers and is blocked by a jena issue.

I was referring to the curieprefixmanager service mentioned there which
could and should be used by serializers (just for the jena ones it's hard
as long as the jena issue isn't fixed).

Cheers,
Reto



> I was not aware that you added something. The JIRA issues says nothing
> about that.
>
> What is your alternative approach?
>
> --
> Fabian
> http://twitter.com/fctwitt
>

Re: Stanbol Namespace Prefix Service (was: How to introduce new features in Stanbol)

Posted by Fabian Christ <ch...@googlemail.com>.
2012/11/30 Reto Bachmann-Gmür <re...@apache.org>

> Was there something missing ny the service I added for CLEREZZA-222 or why
> are you suggesting a new interface?
>

I was not aware that you added something. The JIRA issues says nothing
about that.

What is your alternative approach?

-- 
Fabian
http://twitter.com/fctwitt

Re: Stanbol Namespace Prefix Service (was: How to introduce new features in Stanbol)

Posted by Reto Bachmann-Gmür <re...@wymiwyg.com>.
On Fri, Nov 30, 2012 at 4:52 PM, Rupert Westenthaler <
rupert.westenthaler@gmail.com> wrote:

> On Fri, Nov 30, 2012 at 2:14 PM, Reto Bachmann-Gmür <re...@apache.org>
> wrote:
> > Hi Fabian and Rupert,
> >
> > Was there something missing ny the service I added for CLEREZZA-222 or
> why
> > are you suggesting a new interface?
> >
>
> I had totally forgot about CLEREZZA-222. I made only a search for a
> STANBOL issues. The reason why I finally started to implement this
> service is because the NamespaceEnums are the last part that block the
> separation form the Enhancer EntityLinking and the Entityhub (see
> STANBOL-823).
>
> Is CLEREZZA-222 already implemented. If not, than we could make have a
> "parser level" solution in Clerezza that is compatible with the
> current Jena Parsers AND use STANBOL-823 as a "user level"
> implementation that provides different sources for mappings and also
> allows to manage custom mappings.
>
> The service is there and it has a http-frontend to manage the services (
https://svn.apache.org/repos/asf/incubator/clerezza/trunk/platform.curieprefixmanager/core/src/main/java/org/apache/clerezza/platform/curieprefixmanager/impl/CuriePrefixManager.java)
but IIRC it's not currently being used by any serializer. It should be used
in the JSON-LD serializer.

Cheers,
Reto

Re: Stanbol Namespace Prefix Service (was: How to introduce new features in Stanbol)

Posted by Rupert Westenthaler <ru...@gmail.com>.
On Fri, Nov 30, 2012 at 2:14 PM, Reto Bachmann-Gmür <re...@apache.org> wrote:
> Hi Fabian and Rupert,
>
> Was there something missing ny the service I added for CLEREZZA-222 or why
> are you suggesting a new interface?
>

I had totally forgot about CLEREZZA-222. I made only a search for a
STANBOL issues. The reason why I finally started to implement this
service is because the NamespaceEnums are the last part that block the
separation form the Enhancer EntityLinking and the Entityhub (see
STANBOL-823).

Is CLEREZZA-222 already implemented. If not, than we could make have a
"parser level" solution in Clerezza that is compatible with the
current Jena Parsers AND use STANBOL-823 as a "user level"
implementation that provides different sources for mappings and also
allows to manage custom mappings.


WDYT
Rupert

--
| Rupert Westenthaler             rupert.westenthaler@gmail.com
| Bodenlehenstraße 11                             ++43-699-11108907
| A-5500 Bischofshofen

Re: Stanbol Namespace Prefix Service (was: How to introduce new features in Stanbol)

Posted by Reto Bachmann-Gmür <re...@apache.org>.
Hi Fabian and Rupert,

Was there something missing ny the service I added for CLEREZZA-222 or why
are you suggesting a new interface?

Cheers,
Reto
On Nov 30, 2012 1:35 PM, "Fabian Christ" <ch...@googlemail.com>
wrote:

> Hi Rupert,
>
> nice service. Definitely useful for the JSON-LD support.
>
> I had created CLEREZZA-222 for that a long time ago. But this sounds like
> it solves our needs.
>
> https://issues.apache.org/jira/browse/CLEREZZA-222
>
> Best,
>  - Fabian
>
>
> 2012/11/30 Rupert Westenthaler <ru...@gmail.com>
>
> > Hi all
> >
> > Fabians mail just reminded me that I have not announced the new
> > feature I have started to work on yesterday.
> >
> > The Stanbol Namespace Prefix Service allows to lookup and manage
> > namespace prefixes originating from different sources. Such a service
> > was discussed several times (if I remember correctly even before
> > incubation to Apache) but got never implemented.
> >
> > STANBOL-824 [1] now defines such a Service. Its design is very Similar
> > to the DataFileProvider only that in this case the Service is called
> > NamespacePrefixProvider.
> >
> > In addition there is the NamespacePrefixService that extends the above
> > interface by two utility methods that convert "{prefix}:{localname}"
> > <-> "uri" and a method that allows to add additional prefixes.
> >
> > There is a default implementation of NamespacePrefixService that
> > registers itself as DataFileProvider with the highest priority (this
> > is similar to the MainDataFileProvider).
> >
> > To ensure backwards compatibility there is also a
> > DefaultNamespaceMappingsProvider that hold all the mappings currently
> > defined in the NamespaceEnum of the Enhancer and the Entityhub.
> >
> > The current NamespaceEnum will not be deprecated by this new Service.
> > However all entries of those enumerations that are not directly
> > referenced by the Ontologies of the Enhancer/Entityhub will be
> > deprecated. This avoids dependencies of the servicesapi and core
> > modules to the new service but ensures that the new  service is used
> > for all user level configurations.
> >
> > In addition the new Service will be implemented so that it can be used
> > also outside of an OSGI environment.
> >
> > Finally it is also planed to implement a NamespacePrefixProvider for
> > http://prefix.cc/
> >
> > feedback very welcome.
> >
> > best
> > Rupert
> >
> > [1] https://issues.apache.org/jira/browse/STANBOL-824
> >
> >
> >
> >
> > --
> > | Rupert Westenthaler             rupert.westenthaler@gmail.com
> > | Bodenlehenstraße 11                             ++43-699-11108907
> > | A-5500 Bischofshofen
> >
>
>
>
> --
> Fabian
> http://twitter.com/fctwitt
>

Re: Stanbol Namespace Prefix Service (was: How to introduce new features in Stanbol)

Posted by Fabian Christ <ch...@googlemail.com>.
Hi Rupert,

nice service. Definitely useful for the JSON-LD support.

I had created CLEREZZA-222 for that a long time ago. But this sounds like
it solves our needs.

https://issues.apache.org/jira/browse/CLEREZZA-222

Best,
 - Fabian


2012/11/30 Rupert Westenthaler <ru...@gmail.com>

> Hi all
>
> Fabians mail just reminded me that I have not announced the new
> feature I have started to work on yesterday.
>
> The Stanbol Namespace Prefix Service allows to lookup and manage
> namespace prefixes originating from different sources. Such a service
> was discussed several times (if I remember correctly even before
> incubation to Apache) but got never implemented.
>
> STANBOL-824 [1] now defines such a Service. Its design is very Similar
> to the DataFileProvider only that in this case the Service is called
> NamespacePrefixProvider.
>
> In addition there is the NamespacePrefixService that extends the above
> interface by two utility methods that convert "{prefix}:{localname}"
> <-> "uri" and a method that allows to add additional prefixes.
>
> There is a default implementation of NamespacePrefixService that
> registers itself as DataFileProvider with the highest priority (this
> is similar to the MainDataFileProvider).
>
> To ensure backwards compatibility there is also a
> DefaultNamespaceMappingsProvider that hold all the mappings currently
> defined in the NamespaceEnum of the Enhancer and the Entityhub.
>
> The current NamespaceEnum will not be deprecated by this new Service.
> However all entries of those enumerations that are not directly
> referenced by the Ontologies of the Enhancer/Entityhub will be
> deprecated. This avoids dependencies of the servicesapi and core
> modules to the new service but ensures that the new  service is used
> for all user level configurations.
>
> In addition the new Service will be implemented so that it can be used
> also outside of an OSGI environment.
>
> Finally it is also planed to implement a NamespacePrefixProvider for
> http://prefix.cc/
>
> feedback very welcome.
>
> best
> Rupert
>
> [1] https://issues.apache.org/jira/browse/STANBOL-824
>
>
>
>
> --
> | Rupert Westenthaler             rupert.westenthaler@gmail.com
> | Bodenlehenstraße 11                             ++43-699-11108907
> | A-5500 Bischofshofen
>



-- 
Fabian
http://twitter.com/fctwitt

Re: Stanbol Namespace Prefix Service (was: How to introduce new features in Stanbol)

Posted by Sergio Fernández <se...@salzburgresearch.at>.
Indeed a great idea.

On 30/11/12 13:27, Rupert Westenthaler wrote:
> Finally it is also planed to implement a NamespacePrefixProvider for
> http://prefix.cc/

In case it helps, take a look to the current Prefix infrastructure in 
LMF (http://goo.gl/wD7l2) which includes support to prefix.cc look-up 
(both direct and reverse).

Maybe something to be bundled separately and be reused out of 
LMF/Marmotta...

Cheers,

-- 
Sergio Fernández
Salzburg Research
+43 662 2288 318
Jakob-Haringer Strasse 5/II
A-5020 Salzburg (Austria)
http://www.salzburgresearch.at