Nick Plante

Dr. Dobb's Bloggers

Please Annotate This Tweet

April 16, 2010

Twitter's first official developer conference, Chirp, wrapped up earlier this week. Although I didn't attend personally, it's been interesting watching the flood of announcements and discussion, both from the blogosphere as well as from friends and colleagues who were in attendance.
One of the more intriguing announcements was that of "Twitter annotations", which will allow users to add metadata to any tweet. According to Twitter platform team member Marcel Molina, an annotation is basically a namespace, key, value triple (specified via JSON or form data parameters) that can be attached to any tweet when the message is first created. Simple, but potentially quite powerful.
So how might you use this? You might, for example, want to attach location information to a message. Of course, you say, we can already attach location information to tweets! But with annotations a user could not only record their latitude and longitude but also note that a particular location is a movie theater, a park, an apartment building, or an ad-hoc concert venue.
At a nice restaurant for lunch? Tell Twitter about it by recording its name, location, and hey, while you're at it, give it a star rating. Or search Twitter before making a decision to see how others have rated and categorized nearby eateries. With the right contextual metadata, social location-aware games like Foursquare could be implemented on top of the existing social network.
Attaching music, viral video clips, or other media to tweets is already possible too; usually done through linking URLs. But allowing tweets to be directly annotated with media information might make locating trending music much easier. Hot tracks could be suggested by one user and 'voted up' through retweet-like mechanisms by others. So, a Blip.fm competitor could be built directly on top of Twitter, perhaps, and without the need for a separate account (a user could authenticate with Twitter through OAuth, after all).
What else? Turn-based gaming? Retail coupons? Disqus-style URL commenting? Frankly, Twitter doesn't know. In fact, they've pretty much said that they're looking to their users to determine how annotations might be best used. By not restricting annotations to a particular pre-defined set Twitter is hoping that its community will invent new and interesting ways to extend the service. On one hand, this is great; developers have been leveraging Twitter in interesting ways -- games, stock tracking, media sharing, brand monitoring -- since its early days, and it's smart of the company to recognize the organic innovation that their developer community brings to the table.
On the other hand, without at least some structure, this could be a huge mess. How will namespace abuse be prevented? How will client applications support various types of metadata?
Annotations will certainly give the Twitter development community some interesting opportunities to explore. The new capabilities will start rolling out sometime next quarter, if things go to plan. In the meantime, if you're interested in discussing the particulars, there are a couple active threads on the Twitter Development discussion group.

Twitter's first official developer conference, Chirp, wrapped up earlier this week. Although I didn't attend personally, it's been interesting watching the flood of announcements and discussion, both from the blogosphere as well as from friends and colleagues who were in attendance.

One of the more intriguing announcements was that of "Twitter annotations", which will allow users to add metadata to any tweet. According to Twitter platform team member Marcel Molina, an annotation is basically a namespace, key, value triple (specified via JSON or form data parameters) that can be attached to any tweet when the message is first created. Simple, but potentially quite powerful.

So how might you use this? You might, for example, want to attach location information to a message. Of course, you say, we can already attach location information to tweets! But with annotations a user could not only record their latitude and longitude but also note that a particular location is a movie theater, a park, an apartment building, or an ad-hoc concert venue.

At a nice restaurant for lunch? Tell Twitter about it by recording its name, location, and hey, while you're at it, give it a star rating. Or search Twitter before making a decision to see how others have rated and categorized nearby eateries. With the right contextual metadata, social location-aware games like Foursquare could be implemented on top of the existing social network.

Attaching music, viral video clips, or other media to tweets is already possible too; usually done through linking URLs. But allowing tweets to be directly annotated with media information might make locating trending music much easier. Hot tracks could be suggested by one user and 'voted up' through retweet-like mechanisms by others. So, a Blip.fm competitor could be built directly on top of Twitter, perhaps, and without the need for a separate account (a user could authenticate with Twitter through OAuth, after all).

What else? Turn-based gaming? Retail coupons? Disqus-style URL commenting? Frankly, Twitter doesn't know. In fact, they've pretty much said that they're looking to their users to determine how annotations might be best used. By not restricting annotations to a particular pre-defined set Twitter is hoping that its community will invent new and interesting ways to extend the service. On one hand, this is great; developers have been leveraging Twitter in interesting ways -- games, stock tracking, media sharing, brand monitoring -- since its early days, and it's smart of the company to recognize the organic innovation that their developer community brings to the table.

On the other hand, without at least some structure, this could be a huge mess. How will namespace abuse be prevented? How will client applications support various types of metadata?

Annotations will certainly give the Twitter development community some interesting opportunities to explore. The new capabilities will start rolling out sometime next quarter, if things go to plan. In the meantime, if you're interested in discussing the particulars, there are a couple active threads on the Twitter Development discussion group.

Dr. Dobb's encourages readers to engage in spirited, healthy debate, including taking us to task.
However, Dr. Dobb's moderates all comments posted to our site, and reserves the right to modify or remove any content that it determines to be derogatory, offensive, inflammatory, vulgar, irrelevant/off-topic, racist or obvious marketing or spam. Dr. Dobb's further reserves the right to disable the profile of any commenter participating in said activities.

This month's Dr. Dobb's Journal

This month,
Dr. Dobb's Journal is devoted to mobile programming. We introduce you to Apple's new Swift programming language, discuss the perils of being the third-most-popular mobile platform, revisit SQLite on Android
, and much more!