0
Acre: Server-side JavaScript
on Freebase.com

San Francisco JavaScript Meetup #9
at CBS Interactive

Will Moffat
The Short Pitch
Freebase: a topic DNS
11M topics - Actresses (37,079)
Cheeses (488)
Football Players (16,568)
TV Programs (33,630)



                       arrested_develop
MQL: a JSON query language
“Russian cosmonauts”
MQL: a JSON query language
“Russian cosmonauts”




 [{
   "type": "/spaceflight/astronaut",
   "name": null,
   "/people/...
MQL: a JSON query language
“Russian cosmonauts”



 http://api.freebase.com/api/service/mqlread?query=
 [{
    "type": "/s...
MQL: a JSON query language
MQL: a JSON query language
“Russian cosmonauts”
Acre: Server Side JavaScript for Freebase




         Hosted app server: freebaseapps.com
         Runs untrusted user co...
Acre: for open data apps


Oauth - talk to flickr, Google, Netflix, etc

Acre Template Language

Client-side widgets: Free...
View Source comes to web apps
FreebaseApps.com
Thank you!




           freebase.com

http://www.slideshare.net/tag/freebase

      #freebase on freenode.net
Keys: more examples of web ids


            Will Smith
             (Actor)
Keys: more examples of web ids


  /index.html?curid=154698       Will Smith
                                  (Actor)    ...
Slicing and dicing data using MQL
“Tropical storms in the 90s”




         [{
              "type": "/meteorology/tropica...
MQL: sorting
“French actresses born pre-WWII”




         [{
           "type": "/film/actor",
           "name": null,
 ...
ServerSide Javascript on Freebase - SF JavaScript meetup #9
Upcoming SlideShare
Loading in...5
×

ServerSide Javascript on Freebase - SF JavaScript meetup #9

1,800

Published on

Talk by Will Moffat on Acre: the Sever-Side JavaScript environment for Freebase.com

Published in: Technology
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
1,800
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
19
Comments
0
Likes
2
Embeds 0
No embeds

No notes for slide
  • 1) topic: people, places, films
    2) you’ve got a page about something
    3) plug into freebase to bring in related content from the web
  • CC license
    11M topics, each with a strong, stable identifier + list of keys to other web sites.
  • designed to be used in JS
  • http://www.freebase.com/app/queryeditor?q=[{%22type%22:%22/spaceflight/astronaut%22,%22name%22:null,%22/people/person/nationality%22:%22russia%22}]
  • http://www.freebase.com/app/queryeditor?q=[{%22type%22:%22/spaceflight/astronaut%22,%22name%22:null,%22/people/person/nationality%22:%22russia%22}]
  • http://www.freebase.com/app/queryeditor?q=[{%22type%22:%22/spaceflight/astronaut%22,%22name%22:null,%22/people/person/nationality%22:%22russia%22}]
  • JS powerful language, use it on both client & server.
    SSJS: write complete apps in HTML, JS & CSS.
    Rich ecosystem of widgets, libraries. Community.



    Rhino image from Paul Houle. http://www.mozilla.org/rhino/
  • put this together to get
    DEMO: http://solutions.apps.freebase.dev.freebaseapps.com/suggest



    Auto-complete: musical artists on twitter
    looks up their username
    grabs tweets
  • * all code is BSD licensed
    * clone to edit your own copy



    * example of acre template: show actors starring in this film
  • screencast:
    * Show google news stories from of top 3 companies in selected industry
    * gets deep into code
  • talk to me afterwards - lots of interesting topics. you can use SSJS to extend query language
  • Transcript of "ServerSide Javascript on Freebase - SF JavaScript meetup #9"

    1. 1. Acre: Server-side JavaScript on Freebase.com San Francisco JavaScript Meetup #9 at CBS Interactive Will Moffat
    2. 2. The Short Pitch Freebase: a topic DNS
    3. 3. 11M topics - Actresses (37,079)
    4. 4. Cheeses (488)
    5. 5. Football Players (16,568)
    6. 6. TV Programs (33,630) arrested_develop
    7. 7. MQL: a JSON query language “Russian cosmonauts”
    8. 8. MQL: a JSON query language “Russian cosmonauts” [{ "type": "/spaceflight/astronaut", "name": null, "/people/person/nationality": "russia" }]
    9. 9. MQL: a JSON query language “Russian cosmonauts” http://api.freebase.com/api/service/mqlread?query= [{ "type": "/spaceflight/astronaut", "name": null, "/people/person/nationality": "russia" }]
    10. 10. MQL: a JSON query language
    11. 11. MQL: a JSON query language “Russian cosmonauts”
    12. 12. Acre: Server Side JavaScript for Freebase Hosted app server: freebaseapps.com Runs untrusted user code Sandboxed instruction counting memory, time quotas
    13. 13. Acre: for open data apps Oauth - talk to flickr, Google, Netflix, etc Acre Template Language Client-side widgets: Freebase Suggest
    14. 14. View Source comes to web apps
    15. 15. FreebaseApps.com
    16. 16. Thank you! freebase.com http://www.slideshare.net/tag/freebase #freebase on freenode.net
    17. 17. Keys: more examples of web ids Will Smith (Actor)
    18. 18. Keys: more examples of web ids /index.html?curid=154698 Will Smith (Actor) /people/s/will_smith /name/nm0000226 /RoleDisplay/86971 /BandsAndArtists/S/Smith,_Will /artist/Will+Smith willsmith.com /WillSmith /artist/Will+Smith /music/Will+Smith /Will-Smith/e/B000APUOJC
    19. 19. Slicing and dicing data using MQL “Tropical storms in the 90s” [{ "type": "/meteorology/tropical_cyclone", "name" : null, "formed>=" : "1990", "a:formed<=": "2000" }]
    20. 20. MQL: sorting “French actresses born pre-WWII” [{ "type": "/film/actor", "name": null, "/people/person/gender": "female", "/people/person/date_of_birth": null, "/people/person/date_of_birth<=": "1939", "/people/person/nationality": "France", "sort": "/people/person/date_of_birth" }]
    1. A particular slide catching your eye?

      Clipping is a handy way to collect important slides you want to go back to later.

    ×