Imported vocab terms as objects

Events happening in the community are now at Drupal community events on www.drupal.org.
murrayw's picture

I've been playing with the evoc vocab importer in Drupal 7 and have enjoyed the way it is able to expose vocab terms as predicates in rdfui. I was thinking that related functionality would be allowing imported vocabs to be exposed as target values (objects) for Link fields. So instead of mapping properties to field definitions as with rdfui, we are exposing classes and instances as target values. The URI and Title from the vocab could be used to populate a Link field after the user selected the term from an auto complete or select list. This would be very helpful for content managers who want to use controlled vocabs for defining metadata and to get RDFa goodness easily.

I'm raising this here to see if anyone has worked on something similar or knows of a way to achieve it given current functionality within Drupal. If not, I'll probably scratch my itch.

cheers

Murray

Comments

Neologism in Drupal 7 handles

linclark.research's picture

Neologism in Drupal 7 handles vocabularies and their terms as entities.

Thanks Lin

murrayw's picture

Heh. That screencast took me back. It probably was one of the things which got me into Drupal in the first place :)

I was looking for a way to suck in vocabs rather than publishing them from Drupal. I think evoc provides a good way to do this - with a bit of extra vocab filtering I should be able to get it to work as described above.

Thanks for the feedback.

Managing Director
Morpht

Evoc will be removed from

linclark.research's picture

Evoc will be removed from RDFx at some point. The only user of Evoc is Neologism, so we suggested that they take over the code. RDF UI used it for autocompletion of terms, but there are better ways to do this, and scor posted a summary to this group a few months back of the planned replacement.

Neologism does allow you to import vocabularies. That's how you assert subclass and subproperty relationships with vocabularies like FOAF. I don't know whether it was implemented in the D7 version or not, yet, though.

Importing vocabularies?

brucewhealtonjr's picture

Do you mean that there isn't an easy way to import a vocabulary for use in a D7 site? I thought I saw that being done in one of the videos that featured you, which I saw recently. I think I have evoc on a D7 site for that purpose. Will RDFx allow that without writing php code? It's always much safer to have people doing things like this using the Drupal administrative menus and forms than to get into the code.
Thanks,
Bruce

People can map prefixes to

linclark.research's picture

People can map prefixes to namespaces with RDFx, which is what I demonstrated. Evoc is not required for that. I'm fairly sure I've never demonstrated Evoc in a screencast.

What is being discussed in this thread is actually having the terms represented as entities within Drupal's abstraction layer. This isn't necessary for most use cases. Evoc doesn't currently represent the terms as entities either (it just stores them to a custom database table and has a lot of custom code for doing things with them), but in Neologism the plan was to use the Entity API to represent the terms.

External Vocabularies

brucewhealtonjr's picture

Murray,
I agree that it is important to be able to pull in external vocabularies. The drupal core does have some very popular ones but there will always be a need to use others. Some of the ones I use are extended from FOAF. I started work on a Genealogy application in MediaWiki with their Semantic Bundle. The only problem is that in MW each article is developed to represent only one class. Drupal doesn't seem that restrictive in that you can have nodes and entities that have fields that can create triples inside the RDFa that define one part of a page as representing a different Class (aka Subject) than the page as a whole. In MW if you want to define or describe a new Class (or subject for subsequent triples) you need to create a new article.
So, will evoc be developed separately from RDFx?
Technically, you could just hard code the namespace definition into your theme which is what I'd do if I were hand coding each page.

Bruce

Semantic Web

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: