This project is not covered by Drupal’s security advisory policy.

Utility to make requests from the Freebase API.

[2014-02] Deprecated : DO NOT USE - the project was renamed to FreebaseAPI and Drupal7 work is in another place now.

The Freebase API project includes extra sub-modules that leverage the API -

  • Freebase data that supports autocompletion on node type fields, and
  • Freebase CCK that supports importing data schemas from Freebase type definitions into Drupal node types.

Other modules

This has some relation to
http://drupal.org/project/freebase
However that is Abandoned, Drupal6 only, and makes use of a defunct version of the API.

To use this functionality fully, you are expected to install & enable RDFx that will start to enhance predicate mapping.
And to do anything useful, try the cck_importer.

Quickstart

From a Clean Drupal7 (.26) platform
Install as 'minimal'.

Download
* freebase_api 7.x-1.x
* wslient 7.x-1.x
* http_client 7.x-2.4+
* entity 7.x-1.1+

Enable
* freebase_api
- it should require the rest that are needed

Visit
* Administration » Configuration » Web services » Google Freebase
/admin/config/services/freebase

Enter some of the sample lookups shown on that page!

Theory

This is about treating a Freebase data topic as analogous to a Drupal node, and a Freebase Schema (which defines the 'properties' that atopic may have as analogous to a Drupal field.

Content types

A 'Book' Content Type is equivalent to Freebase '/book/book/ type schema,

http://www.freebase.com/type/schema/book/book

and has an rdf mapping of 'freebase:book.book'
http://rdf.freebase.com/ns/book.book

Freebase 'book' is a compound type, inheriting properties of 'Topic' and 'Written Work', a combination of this defines the fields that the CCK may use.

Fields

Those type schemas have properties, which also have URIs, expressible in RDF,
eg

FREEBASE http://www.freebase.com/type/schema/book/author

FREEBASE ID /book/author

URI http://rdf.freebase.com/ns/book.author

CURIE freebase:book.author

We add these fields to our CCK type, named by default 'field_book_author'
(replacing odd characters with _)

Mappings

To allow better configurable control, we can use other field names, and the mapping between our CCK field names is stored somewhere, and then exposed the way RDF (D7) expects it.
This is managed by rdf_mapping module - a backport-of-sorts from Drupal 7 entity info API

Compound/Complex Fields

Most Freebase data is actually about relationships, not content. Jack has a partner called Jill, and Jill has a job "water carrier" in the location "the hill".
Each noun there is a Freebase topic. In Drupal we CAN make each of these a full node or entity and make links between them using entity_reference, BUT often we want to be a bit more modest, and maybe we don't need that much detail. In those cases, we can use Drupal as a rounded-down version of that complex map, and just say that job-title is a text field, and location is a taxonomy.
People nodes are still of content type people though.

... There is more docs and theory in the notes in the module you can look at.

Project information

Releases