This course will become read-only in the near future. Tell us at community.p2pu.org if that is a problem.

Unleash Your Curiosity


Choose a query for your API call

 

Time to get started! In this challenge, we will be using the Twitter API. The first task in this challenge is simply to identify a query that interests you. You might already have one in mind, or you may need to spend some time and think about one.
 
Perhaps you are passionate about politics or a particular current event. Maybe it's your city or a certain area of science. A sports team? A feeling? A recent news story? For example, try out a twitter search on "toronto," "peer review," "python" or "#hungry". 
 
Click on the links above. Try some of your own queries and skim through the results to see if you're happy with your query.
 
To complete this challenge, post below at least one query that interests you and consistently returns several results. In particular, if you choose something too unusual or esoteric, there might not be any results, and that woudn't be much fun. 
 
Beyond having enough results, what makes a good query? How about a bad query? Some things to think about include how specific or general a query is, how time-sensitive, possible synonyms, overloading of hash tags, etc.

Task Discussion


  • LeJit said:

    My Query:

    https://twitter.com/#!/search/pokemon

    Greatest game franchise ever.

    on April 9, 2012, 2:06 a.m.
  • rodrigo said:

    Here is my query:

    https://twitter.com/#!/search/%23json

    on April 8, 2012, 6:47 p.m.
  • Anonym said:

    i think i goes with ipv6 since it almost use in all internet traffic .https://twitter.com/#!/search/%23IPv6 . thought i think nodejs might more interesting but i not really sure how it work.

    on April 3, 2012, 9:37 a.m.

    Jessy Kate Schingler said:

    sounds great lorenzo. i bet jos could help out with the node.js side if you have questions, too!

    on April 3, 2012, 11:30 a.m. in reply to Anonym
  • RTheB said:

    Here's my query:

    https://twitter.com/#!/search/%23usainbolt

    Legally the fastest man on land!

    on March 31, 2012, 4:25 p.m.
  • dpino said:

    This is my query: https://twitter.com/#search?q=%23FF I'm following hastag Follow Friday, new results every Friday (or even before) in your favorite twitter timeline :P

    on March 27, 2012, 5:48 p.m.

    dpino said:

    This query is not a good query, #FF means too many different things. Specially talking about a search that returns people to folow, #FollowFriday seems more like a better approach. Anyway, when I thought about this query I was thinking of something which could provide continuos updates, I'm not really interested on following #FollowFriday (lots of spam actually) :)

    on March 27, 2012, 5:55 p.m. in reply to dpino

    Jessy Kate Schingler said:

    aha, yeah, that's a good observation. tags can get overloaded (used for more than one thing), or also sometimes be very temporal (for example during a conference). having a "good" tag is actually a bit hard!

    a whole separate project would be to write a program which attempts to recognize which tweets with "FF" are actually about follow friday :). 

    which term did you choose in the end?

    on March 28, 2012, 12:33 p.m. in reply to dpino

    dpino said:

    #FollowFriday seems to get better results indeed.

    on March 28, 2012, 7:11 p.m. in reply to Jessy Kate Schingler
  • Newman5 said:

    All this learning is ... well, challenging. 

    Here is my search query -

    https://twitter.com/#!/search/robeson%20county%20OR%20co

    It's for my home county. An interesting place for sure.  Here is one of my favorite tweets - https://twitter.com/#!/elenamarieeee/status/184389874974081025

    All girls from Robeson County aren't hoes!

    On the query itself:

    I would like all results to have 'Robeson' and ('County' or 'Co')... can you do that math bracketing thing here in the URL?

    regardless, the way it is now works pretty good.  It does pick up "Robeson... co-owner...", but i'm not complaining.

    on March 26, 2012, 7:53 p.m.

    Jessy Kate Schingler said:

    i don;t think you can do the bracketing, but i think what you have is actually achieving what you want, it seems to be applying the OR operator to just the neighbouring words. not obvious if it's an exclusive OR though, since only one or the other seems to appear in these search results. 

    the issue with the term "co-owner" is a tiny hint of the subtleties (and difficulties) in natural language processing... which is a fun area in and of itself. but i think it's great to play around with the advanced search operators and encoding them for the API call. fabulous work :). 

    on March 27, 2012, 12:49 a.m. in reply to Newman5
  • Jeroen said:

    My query is on the topic 'open education.

    First i simple searched for open education and this results in all tweets that have either the work open or the word education or both in them.

    So next I tried "open education" thus between quotation marks. This shows all the tweets with the exact word combination.

    I noticed that there is a specific topic--why open education matters video competition--is 'trending' and while interesting, it was cluttering my results. So finally I searched for "open education" -matters which resulted in a more diverse picture.

    I do wonder how one can use more specific search functions. I I would be interested in all tweets including both open AND education but they do not necessary have to be as an exact word combination. Can one use boolean search techniques?

    I am sure time will tell :-)

    on March 23, 2012, 7:48 a.m.

    lernantatron said:

    Advanced Twitter Search:

    https://support.twitter.com/articles/71577

    https://twitter.com/#!/search-advanced

    The API will accept any of the search operators.

    on March 23, 2012, 7:55 a.m. in reply to Jeroen

    benjamin e said:

    Thanks so much for that link. You solved a problem for me there.

    I was wondering how to filter out posts that included links.

    Solution: in the "none of these words" box include: http

    (ie, prefix the search term with "-http") 

    on March 23, 2012, 8:36 a.m. in reply to lernantatron

    Jeroen said:

    Ah excellent, thanks for that. Could have known :-)

    Cheers, Jeroen

    on March 23, 2012, 10:01 a.m. in reply to lernantatron
  • Philipp said:

    This was interesting. I remembered Dan Meyer's very funny live tweeting from Sal Khan's presentation at stanford and wanted to pull that out. Turns out the tweets are too old to show up in twitter searches. There are conflicting statements about the timeframe that you can search, but apparently it's bounded by either a couple of weeks (some say 7 days) or the number of tweets returned (for searches with lots of results).

    Searching for @ddmeyer and #khanstanford -> 0 results

    Read it anyway. It's funny. http://www.edtechresearcher.com/2012/02/dan-meyer-live-tweets-sal-khan/

    Topsy is one of a few services that return older tweets. For example: http://topsy.com/s?q=%23khanstanford

    I defaulted to a more boring and predictable search for @p2pu which picked up this nice tweet from our friends @mozilla -> "Learning is more fun with friends. Learn web dev skills, earn badges, share what you know @p2pu School of Webcraft "

    on March 16, 2012, 2:12 p.m.

    lernantatron said:

    If you want old tweets send a FOIA request to the Library of Congress:

    http://twitter.com/#!/librarycongress/statuses/12169442690

    Luckily there is a API for generating FOIA request letters:

    http://www.rcfp.org/foia-federal-letter-generator

    The U.S. Library of Congress, which archives many forms of media for their cultural and historical significance, has announced it will keep a digital archive of every public tweet that has been broadcast on Twitter since its inception in March 2006.
     
    Recognizing that the inane tweets will certainly outnumber the significant ones, the Library of Congress plans to highlight the culturally and historically important tweets, such as the first-ever tweet sent by Twitter co-founder Jack Dorsey, President Obama's tweet announcing his win in the 2008 election and a set of tweets that helped a photojournalist get released from prison in Egypt.
     
    This Twitter archive isn't evidence of a new focus for the Library of Congress; it has been collecting and archiving websites and online media for a decade now. The Library of Congress currently houses 167 terabytes (or 167,000 gigabytes - the largest __iPod__ storage is only 64 gigabytes) of information pulled from the Internet during that time.
    on March 23, 2012, 8:04 a.m. in reply to Philipp
  • Jos said:

    My initial query was #nodejs cause it's a technology that I'm really interested in. Although it does get quite a lot of hits, it is not completely consistent cause some people will use simply '#node' or the full name 'node.js' if it's not used as a hashtag, so the search might be missing some results. I've refined the query to contain both the hashtag and the name.

    on March 13, 2012, 5:33 p.m.

    Jessy Kate Schingler said:

    fantastic, exactly the kind of thing i had in mind :). 

    on March 13, 2012, 9:48 p.m. in reply to Jos