move extractor to notebook domain and refactor