freebase

How to properly attribute Freebase

耗尽温柔 提交于 2019-12-07 06:15:33
问题 I hope this is the right place to ask this question. I am attempting to attribute Freebase, but this website: https://www.freebase.com/policies/attribution Does not produce any HTML code or image. My question is: How do I give proper attribution to Freebase in a mobile app? Specifically, iOS. Or, is the citation included in the API response sufficient? Example: citation = { provider = Wikipedia; statement = "Description licensed under the Creative Commons Attribution-ShareAlike License (http:

Is there a hierarchical representation of the Freebase types?

余生长醉 提交于 2019-12-07 04:13:43
问题 For example, if some topic (Ex: Texas) is of type /location/citytown, I also see that there is a type "/location/location" attached to the same topic. In addition, here as the topic is the name of a city or town, it is also by default a general location, right? So, would that conclude if a topic has a type /location/citytown, then it would by default have /location/location also as a type associated with the same topic? In summary, does Freebase have a hierarchical representation of the types

[Freebase]: Finding relationship between nodes

◇◆丶佛笑我妖孽 提交于 2019-12-06 15:48:21
I am new to Freebase and I have been trying to find relationships between 2 nodes without success. For example, I want to find if there is link between Lewis Hamilton(/en/lewis_hamilton) and Formula One(/en/formula_one), which there is in real life, but I can't seem to find it. I have tried the following MQL codes, alternating IDs as well : 1) [{ "type" : "/type/link", "source" : { "id" : "/en/lewis_hamilton" }, "master_property" : null, "target" : { "id" : "/en/formula_one" }, "target_value" : null }] 2) { "id":"/en/lewis_hamilton", "/type/reflect/any_master":[{ "link":null, "name":null }], "

Getting Wikipedia IDs in MQL

随声附和 提交于 2019-12-06 15:31:44
Freebase WEX dumps contain a wpid column corresponding to the page_id from the source MediaWiki database in the freebase_wpid table. This table provides a mapping between Wikipedia numeric article/redirect IDs and Freebase GUIDs (Global Unique IDs). guid use as foreign keys is deprecated by mid for lots of good reasons , but that doesn't change the fact that guids are still used at a system level so I'm going to call mid an accessor from here on. Using the mid accessor is flexible in MQL. One can query using "mid": null and using "mid":[] depending on whether one needs the current mid or every

How to get aliases from Freebase?

半城伤御伤魂 提交于 2019-12-06 14:35:16
I just want to get from Freebase the different aliases a person can have. My PHP query is : $query = array( array( 'id' => NULL, 'alias' => NULL, 'name' => "Barack Obama", 'type' => "/people/person" ) ); The result is: Array ( [code] => /api/status/error [messages] => Array ( [0] => Array ( [code] => /api/status/error/mql/type [info] => Array ( [expected_type] => /people/person [property] => alias ) [message] => Type /people/person does not have property alias [path] => [query] => Array ( [0] => Array ( [alias] => [error_inside] => . [id] => [name] => Barack Obama [type] => /people/person ) )

Entity Relations from freebase dump

落爺英雄遲暮 提交于 2019-12-06 13:44:46
问题 I want to dump all entity-name-pair with a relation. Example : subject predicate object <freebase/ns/g.11bc7__xnw> <freebase/ns/people.place_lived.location> <freebase/ns/m.02_286> . Freebase in above line refers to url of freebase website. I extracted all triplets which have mid in subject and object, then I took the predicate as the relation. For the above example my code will output something like this: entity pair : g.11bc7__xnw , m.02_286 relation : people.place_lived.location I have two

Gettting Actor Ids and biographies from the data dumps or Freebase API

二次信任 提交于 2019-12-06 13:42:52
Does anyone know the best way of getting Actor Ids from Freebase data dumps, and later on getting the IMDB ids and biographies from the Freebase API? Actors will have the type /film/actor and look like this in the dump: ns:m.010q36 rdf:type ns:film.actor. You can find them all in a few minutes from the compressed dump with a simple grep: zgrep $'rdf:type\tns:film.actor.' freebase-rdf-<date of dump>.gz | cut -f 1 | cut -d ':' -f 2 > actor-mids.txt This will generate a list of MIDs in the form m.010q36 which represents the MID /m/010q36 . Using the list of MIDs, look for all lines which have

Is there an API to get results similar to Google's “people also search for”?

半世苍凉 提交于 2019-12-06 10:53:01
问题 I'm looking for an API that would give similar results to the Google's "people also search for" feature. So that, for instance, when I search for Stanley Kubrik, I see all the other film directors that people search for. I know about the Freebase API but it simply provides information about the search item, not what other search items it may be related to. There is also a TargetingIdeaSelector tool in Google AdWords API that shows related keywords, but that doesn't really range the results

Multiple Queries in MQL on Freebase

浪尽此生 提交于 2019-12-06 08:30:11
I am trying to get a list of results from Freebase. I have an array of MIDs. Can someone explain how I would structure the query and pass it to the API in PHP? I'm new to MQL - I can't even seem to get the example to work: $simplequery = array('id'=>'/topic/en/philip_k_dick', '/film/writer/film'=>array()); $jsonquerystr = json_encode($simplequery); // The Freebase API requires a query envelope (which allows you to run multiple queries simultaneously) so we need to wrap our original, simplequery structure in two more arrays before we can pass it to the API: $queryarray = array('q1'=>array(

How to get a list of all films on Wikidata?

百般思念 提交于 2019-12-06 08:09:56
问题 I was using Freebase to get all movies/films there for my website, but it's getting shut down soon. so I was searching for another free database for movies and came across Wikidata. To be honest it's too complicated to understand how to query all the movies. So I thought you guys could help me to get all the movies in Wikidata. In the future I want to include TV shows and series as well. Programming language doesn't matter, I want to use web query with a link. 回答1: you can look for all the