Google’s friendship algorithm
How does Google know when it’s time to add someone to my contact list in Google Chat? Do they have an algorithm for that? We all know that they scan our emails for ad placement so maybe they have an algorithm for new, burgeoning friendship too.
For instance, let’s say I only send hateful, cuss-filled, deriding email to somebody. After a few exchanges, will this person still show up in my contact list?
Here’s some pseudo-code showing how I think it might work:
function calculate_relationship( $message ) { // Determine friendship based on indicated laughter if ( $message contains 'LOL' or 'haha' ) { // Calculate the length and frequency of 'LOL' or 'haha' // exclamation points double the degree of laughter var $joy = get_laugh_factor( $message ); if ( $joy > $AVERAGE_AMERICAN ) { add_to_contacts( $TOMORROW ); return; } else { wait( $TWO_MESSAGES ); return; } } // Check for negative language if ( $message contains $GLOBAL_CUSS_LIST ) { if ( $message contains 'fuck you' ) { // We need clarification if ( preceded by 'I want to' ) { // Help this nerd out add_to_contacts( $NOW ); return $user_phone_address_current_location; } } else { // Do nothing. Watch this whole thing crash and burn. return; } } }
function laughOutLoud($humour)
{
if ($humour > 5)
{
echo 'HAHA!';
}
}
laughOutLoud(10);