Lookery has gone from selling ads on Facebook applications to selling anonymized user data so online publishers and advertisers can better target ads. Now, the company is going through a further set of changes — beginning to charge for previously-free data reporting tools, and cutting its staff from nine to six people. The story, laid out in detail by cofounder Scott Rafer on the company blog, is perhaps instructive for other web startups trying to figure out their business models.

Rafer discusses three incorrect assumptions the team has made, from when the company began serving ads on Facebook back in 2007. The company had hoped to gather user data from Facebook and distribute it to the web; the company had also been working on web-wide keyword targeting.

We expected an advertising downturn, but we thought that our ad network could remain breakeven or better with our remnant-ad focus. Nope; the ad downturn is more extreme than anyone guessed.

Along with several other startups, we bet that Facebook would allow third parties to use some anonymous data for ad targeting. They have not allowed it — nor have [they] enforced their [Terms of Service] which prohibits it, but we can’t build a business on the hope that FB never enforces their TOS.

Along with many other companies large and small, we spent a lot of time and effort collecting search keyword history on anonymous users. We expect that Google’s AJAX search page test will be rolled out across all of Google’s organic search traffic within a year. The purpose is seemingly to decimate the Facebook|Microsoft search partnership, but we do not want to become collateral damage in that fight. Our participation in that business is not over, but it will be far more cautious as described below.

Rafer goes on to say that the company’s current business is doing better. Beginning last summer, the San Francisco company began gathering anonymized data about users’ age, location and gender data from web publishers — based on information that users themselves provided to sites while registering. Customers can access this data and match it with data they may have already collected about its users. For example, if a 27 year old male living in Mountain View, Calif. were to visit a political site (*cough*), Lookery could help target an ad that might be especially meaningful to him.

It has been repackaging the data so that other web publishers can target ads on their sites according to the types of users they’re receiving. So far, Lookery says it has had the most success so far with video ad networks. More, from the post:

Selling ad services is very seasonal, so the Lookery Demographic Retargeting efforts really kicked off in January. With six weeks of Age|Gender sales success our belts, we now know what it will take to grow the business. We are excited that the revenue path is clear, but our free services are not adding to that momentum.

The company raised $900,000 in seed funding from Charles River Ventures and angel investors, in early 2008, and followed up with a $2.25 million first round from a group of angels and strategic investors, last fall.