Yahoo late last night flipped the switch on a new search marketing system it hopes will help it close the gap on sector leader Google.

Codenamed “Panama”, the new model gives sponsored ads higher billing based on keyword matches to page content. In the old approach, ads were ordered only by which marketers bid most.

A new user interface and dashboard was already being tested by customers before Yahoo! yesterday launched what senior engineer Awa Awadallah called the “quality-ordering marketplace”.

Some users have initially reported small uplifts in click quality.

Yahoo! first embarked on the Panama project in 2005 after being otherwise content with the software acquired in its purchase of Overture two years earlier.

According to the New York Times: “Those who worked on the project described the effort as a huge undertaking. They compared it to rebuilding an airplane in midflight, as engineers had to keep the old advertising system running while they put the new one together.”

Google, which launched AdWords in 2000, has built a commanding position as search marketing leader (making 4.5 cents to 5 cents on every search, against Yahoo!’s 2.5 cents to 3 cents, one analyst told the Times) and has seen its stock skyrocket while the value of its Silicon Valley rival on Wall Street has fallen on concern over its multifaceted strategy.

By increasing the relevance of ads to users, and not just relying on “pay-for-placement” alone, Yahoo! hopes it can begin to challenge Google’s dominance and bolster revenue.