def parse_conference_address(address_string):
geo_elements = address_string.split('<STR_LIT:U+002C>')<EOL>city = geo_elements[<NUM_LIT:0>]<EOL>country_name = geo_elements[-<NUM_LIT:1>].upper().replace('<STR_LIT:.>', '<STR_LIT>').strip()<EOL>us_state = None<EOL>state = None<EOL>country_code = None<EOL>country_code = match_country_name_to_its_code(country_name, city)<EOL>if country_code == '<STR_LIT>' and len(geo_elements) > <NUM_LIT:1>:<EOL><INDENT>us_state = match_us_state(geo_elements[-<NUM_LIT:2>].upper().strip()<EOL>.replace('<STR_LIT:.>', '<STR_LIT>'))<EOL><DEDENT>if not country_code:<EOL><INDENT>us_state = match_us_state(country_name)<EOL><DEDENT>if us_state:<EOL><INDENT>state = us_state<EOL>country_code = '<STR_LIT>'<EOL><DEDENT>return {<EOL>'<STR_LIT>': [<EOL>city,<EOL>],<EOL>'<STR_LIT>': country_code,<EOL>'<STR_LIT>': None,<EOL>'<STR_LIT:state>': state,<EOL>}<EOL>
Parse a conference address.

    This is a pretty dummy address parser. It only extracts country
    and state (for US) and should be replaced with something better,
    like Google Geocoding.