def extract_todo(flag, text):
    """Extract an action item line into a dict structure.

    - owner: the owner
    - todo: the proper action item
    - deadline: when the action item needs to be executed
    """
    owner, action_line = text.split(' to ', 1)
    todo = action_line.strip()[:-10]
    todo_date = action_line.strip()[-10:]
    return {'owner': owner.strip(), 'todo': todo.strip(), 'deadline': todo_date
        }
