haystack/test/samples/pipeline/test.haystack-pipeline.yml
Sebastian 59857cb492
feat: Speed up reader tests (#3476)
* Use a smaller reader where possible

* Change scope to module of reader to get faster load times
2022-10-26 19:04:18 +02:00

91 lines
2.2 KiB
YAML

version: ignore
components:
- name: Reader
type: FARMReader
params:
no_ans_boost: -10
model_name_or_path: deepset/bert-medium-squad2-distilled
num_processes: 0
- name: ESRetriever
type: BM25Retriever
params:
document_store: DocumentStore
- name: DocumentStore
type: ElasticsearchDocumentStore
params:
index: haystack_test
label_index: haystack_test_label
- name: PDFConverter
type: PDFToTextConverter
params:
remove_numeric_tables: false
- name: TextConverter
type: TextConverter
- name: Preprocessor
type: PreProcessor
params:
clean_whitespace: true
- name: IndexTimeDocumentClassifier
type: TransformersDocumentClassifier
params:
batch_size: 16
use_gpu: false
- name: QueryTimeDocumentClassifier
type: TransformersDocumentClassifier
params:
use_gpu: false
pipelines:
- name: query_pipeline
nodes:
- name: ESRetriever
inputs: [Query]
- name: Reader
inputs: [ESRetriever]
- name: query_pipeline_with_document_classifier
nodes:
- name: ESRetriever
inputs: [Query]
- name: QueryTimeDocumentClassifier
inputs: [ESRetriever]
- name: Reader
inputs: [QueryTimeDocumentClassifier]
- name: indexing_pipeline
nodes:
- name: PDFConverter
inputs: [File]
- name: Preprocessor
inputs: [PDFConverter]
- name: ESRetriever
inputs: [Preprocessor]
- name: DocumentStore
inputs: [ESRetriever]
- name: indexing_text_pipeline
nodes:
- name: TextConverter
inputs: [File]
- name: Preprocessor
inputs: [TextConverter]
- name: ESRetriever
inputs: [Preprocessor]
- name: DocumentStore
inputs: [ESRetriever]
- name: indexing_pipeline_with_classifier
nodes:
- name: PDFConverter
inputs: [File]
- name: Preprocessor
inputs: [PDFConverter]
- name: IndexTimeDocumentClassifier
inputs: [Preprocessor]
- name: ESRetriever
inputs: [IndexTimeDocumentClassifier]
- name: DocumentStore
inputs: [ESRetriever]