Save a Context object to user data directory.

def save_context(context):
    """Save a Context object to user data directory."""
    file_path = _get_context_filepath()
    content = format_to_http_prompt(context, excluded_options=EXCLUDED_OPTIONS)
    with io.open(file_path, 'w', encoding='utf-8') as f:
        f.write(content)