This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'yaml' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"interaction": { | |
"content": "$NKE Raises Quarterly Dividend 14%", | |
"source": "Twitter for iPhone", | |
"tag_tree": { | |
"dowjones": { | |
"company": ["Nike"] | |
}, | |
"device": ["Apple"] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"interaction": { | |
"content": "http://videos.com/funny-cat", | |
"source": "Twitter for Android", | |
"tag_tree": { | |
"quality": { | |
"suspected_bot": 10 | |
} | |
}, | |
"twitter": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"interaction": { | |
"content": " http://videos.com/funny-cat", | |
"source": "Twitter for Android" | |
}, | |
"twitter": { | |
"user": { | |
"created_at": "Wed, 31 Jul 2012 13:01:22 +0000", | |
"statuses_count": 23, | |
"friends_count": 132, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"tag_tree": { | |
"sources": { | |
"category": ["manual"] | |
}, | |
"professions": { | |
"function": ["creative"] | |
}, | |
"news": { | |
"provider": ["ABC News"] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE VIEW tagged_source AS | |
SELECT i.interaction_id, t.label AS tag | |
from interaction i | |
inner join tag_labels t on t.interaction_id = i.interaction_id | |
where t.namespace = 'sources.category'; | |
CREATE VIEW tagged_provider AS | |
SELECT i.interaction_id, t.label AS tag | |
from interaction i | |
inner join tag_labels t on t.interaction_id = i.interaction_id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"interaction": { | |
"id": "1e3312c45c35ac80e074ddead5649524", | |
"type": "twitter", | |
"created_at": "Wed, 09 Oct 2013 21:46:37 +0000", | |
"content": "I can't wait to talk to the @DataSift guys about how #social data is transforming #marketing", | |
"hashtags": [ | |
"social", | |
"marketing" | |
], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pip install datasift |
OlderNewer