In this course we will explore the methods that facilitate Social Media analysis, with a focus on Facebook, Twitter and Foursquare. The course will begin with short tutorials on the different platforms, methods to access public data and common analysis methods. Participants will then be split into teams of 4-6 and under the guidance of the supervisors, define and design a hackathon project based upon their interests and personal goals. Starting environments will be provided. The students will then have 6-8 hours to implement their project with the help of the supervisors and will present their projects to the summer school participants the following day.
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Social computing, Analysing Social Media: Theory and Hackathon
1. KIT – University of the State of Baden-Württemberg and
National Research Center of the Helmholtz Association
KARLSRUHE SERVICE RESEARCH INSTITUTE (KSRI)
www.kit.edu
Social Computing
Analysing Social Media: Theory and Hackathon
Dr. Simon Caton and Dr. Martin Chorley
2. Karlsruhe Service Research Institute
www.ksri.kit.edu
About us
Simon
§ PostDoc @KIT
§ CS PhD @Cardiff University
§ Working on / with:
Martin
§ PostDoc @Cardiff University
§ CS PhD @Cardiff University
§ Working on / with:
3. Karlsruhe Service Research Institute
www.ksri.kit.edu
Agenda
1330 – 1500 Intro, Social Media Analysis, Team Formation
1530 – 1615: Project Brainstorming + Machine Setup
1615 – 1900: Implementation Session I
1900 – 2000: Dinner on the go
2000 – 2200: Implementation Session II
2200+: Debrief + Informal Get Together
1700 – 1730 (Tomorrow) Demos and Winner Selection
3
4. KIT – University of the State of Baden-Württemberg and
National Research Center of the Helmholtz Association
KARLSRUHE SERVICE RESEARCH INSTITUTE (KSRI)
www.kit.edu
Social Computing: Brief Overview
5. Karlsruhe Service Research Institute
www.ksri.kit.edu
Social Computing?
§ “…any type of computing application in which software
serves as an intermediary or a focus for a social relation”
D. Schuler, Social Computing, CACM, 37(1) 1994.
§ “A social structure in which technology puts power in
individuals and communities, not institutions”
C. Charron, J. Favier, and C. Li, Social Computing: How Networks Erode
Institutional Power, and What to Do about It, Forrester Customer Report, 2006.
§ “Computational facilitation of social studies and human
social dynamics as well as the design and use of ICT that
consider social context”
F.-Y. Wang, D. Zeng, K. Carley, W. Mao, “Social Computing: From Social
Informatics to Social Intelligence”, IEEE Intelligent Systems, 2, 2007.
5
6. Karlsruhe Service Research Institute
www.ksri.kit.edu
Main Social Computing Domains
6
Giuseppe Lugano. Social Computing: A Classification of Existing Paradigms. IEEE Social
Computing 2012
10. Karlsruhe Service Research Institute
www.ksri.kit.edu
What we are going to look at
10
Foundations
Social Media
Platforms
11. Karlsruhe Service Research Institute
www.ksri.kit.edu
Learning Outcomes of the Session
§ to learn the basics of analysing social media via a hands
on session with Facebook, Twitter or Foursquare
§ to gain hands on experience of accessing data, creating
apps and running analysis methods
§ to gain experience in team-based rapid prototyping
11
13. KIT – University of the State of Baden-Württemberg and
National Research Center of the Helmholtz Association
KARLSRUHE SERVICE RESEARCH INSTITUTE (KSRI)
www.kit.edu
Social Media Analysis
Crash Course: JSON, Twitter, Foursquare, and Facebook
13
27. Karlsruhe Service Research Institute
www.ksri.kit.edu
27
OAuth
1. identification
2. authentication
3. access to data
28. Karlsruhe Service Research Institute
www.ksri.kit.edu
28
user
app
api
provider
user requests login
redirectuser
api provider confirms identity
user grants permission
accesskey
55. Karlsruhe Service Research Institute
www.ksri.kit.edu
Data Access Permissions
There are 79 data access permissions in FB in 3 categories:
§ User Data Permissions
§ Friend Data Permissions
§ Extended Permissions
§ They regulate what you can and
cannot access
55
57. Karlsruhe Service Research Institute
www.ksri.kit.edu
FB JSON Objects
§ Everything in FB is accessed via an ID
§ Users, Pages, Events, Comments, Posts, Shares, …
§ To view / access the JSON object for a FB entity:
§ https://graph.facebook.com/<EntityID>?auth_token=<auth_token>
§ Auth Token? à Access Token
§ An access token is an opaque string that identifies a user, app, or page
and can be used by the app to make graph API calls.
§ It is valid only for a predetermined period of time
§ A log out action will automatically expire an access token
§ Every time you log into FB, you create an access token
§ More info:
§ http://developers.facebook.com/docs/facebook-login/access-tokens/
57
58. Karlsruhe Service Research Institute
www.ksri.kit.edu
https://graph.facebook.com/761705087?
auth_token=…
58
60. Karlsruhe Service Research Institute
www.ksri.kit.edu
Beyond Basic Data
§ Add the fields argument, e.g.
https://graph.facebook.com/761705087?
fields=id,name,inbox&auth_token=…
$facebook->api("761705087?fields=id,name,inbox");
§ but, do something you don’t have permission for, and:
60
61. Karlsruhe Service Research Institute
www.ksri.kit.edu
61
https://developers.facebook.com/
tools/explorer
63. KIT – University of the State of Baden-Württemberg and
National Research Center of the Helmholtz Association
KARLSRUHE SERVICE RESEARCH INSTITUTE (KSRI)
www.kit.edu
Some Project Ideas
63
64. Karlsruhe Service Research Institute
www.ksri.kit.edu
Streaming API + Mapping
Monitor Trending Topics &
Influence Detection
Linguistic Analysis of Venue Tips in Karlsruhe
Heat Mapping of Venues
Render and Analyse a Social Graph
Linguistic Analysis of a Timeline /
Page etc.
Or A Combination Of The Lot
65. Karlsruhe Service Research Institute
www.ksri.kit.edu
Some useful libraries / resources
§ http://www.alchemyapi.com/ - Natural Language Processing
§ https://gephi.org/ - interactive graph visualisation and exploration
§ http://nodexl.codeplex.com/ - excel addon for graph analysis
(Windows only)
§ http://code.google.com/p/google-gson/ - JSON parser for Java
§ http://leafletjs.com/ - nice mapping API
§ https://github.com/pinzler/fsq-php-connectedapp - simple php
4sq app example
§ https://developer.foursquare.com/resources/libraries - Other 4sq
libraries
§ http://140dev.com/free-twitter-api-source-code-library/ - twitter
php server
§ https://dev.twitter.com/docs/twitter-libraries - Other twitter
libraries
65