Some refactoring and first test of Topics Extraction API integration