[Developers] content of documents
Alec Flett
alecf at metaweb.com
Wed Oct 3 21:53:08 UTC 2007
Kirrily Robert wrote:
> Is there any way in MQL to get at the content of a document object?
> When I look at things like the example at
> http://www.freebase.com/view/helptopic?id=%239202a8c04000641f800000000544e139#WhatsNew.html,
> it seems that the only way to get at it is via a separate web query.
>
>
At the moment, yes that is the only way. It is unfortunate to have to
make 50 HTTP requests, but you could do some amount of caching on your
end, as blurbs are unlikely to change anytime soon, and are nice and
small. Obviously this adds state and complexity to an app like yours.
In any case, 50 HTTP requests clearly isn't ideal. I wonder if it would
be useful to provide some sort of bulk retrieval where you're retrieving
either a list of GUIDs to documents, or doing it based on the results of
a mql query?
What would be helpful to you? If we batch them up we'd probably have to
use some sort of mime enclosure mechanism..
Alec
> I'm trying to build an RSS feed for watched discussions -- you can see
> it at http://tools.freebasing.org/feeds/watched.cgi?user=skud (or
> substitute your own username) if you don't mind it breaking etc,
> because I'm still working on it -- but obviously the content of each
> post would be a useful thing to have. But all the examples I've seen
> that include document content are in JavaScript and are fetching
> something like the blurb you find at
> http://freebase.com/api/trans/blurb/<document id> Obviously I *could*
> do that, but I'd rather not be spawning 50 HTTP requests every time
> someone hits the RSS feed.
>
> K.
>
>
More information about the Developers
mailing list