diff --git a/.github/utils/pydoc-markdown.sh b/.github/utils/pydoc-markdown.sh index 39bc6dd78..4322da034 100755 --- a/.github/utils/pydoc-markdown.sh +++ b/.github/utils/pydoc-markdown.sh @@ -9,11 +9,3 @@ for file in ../config/* ; do echo "Converting $file..." pydoc-markdown "$file" done -# render preview markdown docs -cd .. -rm -rf temp-preview && mkdir temp-preview -cd temp-preview -for file in ../config-preview/* ; do - echo "Converting $file..." - pydoc-markdown "$file" -done diff --git a/docs/pydoc/config-preview/builder.yml b/docs/pydoc/config/builder.yml similarity index 91% rename from docs/pydoc/config-preview/builder.yml rename to docs/pydoc/config/builder.yml index 7ec4b3614..8d783e8e6 100644 --- a/docs/pydoc/config-preview/builder.yml +++ b/docs/pydoc/config/builder.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/builders] + search_path: [../../../haystack/components/builders] modules: ["answer_builder", "prompt_builder", "dynamic_prompt_builder"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/caching.yml b/docs/pydoc/config/caching.yml similarity index 91% rename from docs/pydoc/config-preview/caching.yml rename to docs/pydoc/config/caching.yml index 7f2bc0e85..88c7d6286 100644 --- a/docs/pydoc/config-preview/caching.yml +++ b/docs/pydoc/config/caching.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/caching] + search_path: [../../../haystack/components/caching] modules: ["url_cache_checker"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/classifier.yml b/docs/pydoc/config/classifier.yml similarity index 91% rename from docs/pydoc/config-preview/classifier.yml rename to docs/pydoc/config/classifier.yml index 8a68fa696..85eb4e771 100644 --- a/docs/pydoc/config-preview/classifier.yml +++ b/docs/pydoc/config/classifier.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/classifiers] + search_path: [../../../haystack/components/classifiers] modules: ["document_language_classifier"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/converter.yml b/docs/pydoc/config/converter.yml similarity index 85% rename from docs/pydoc/config-preview/converter.yml rename to docs/pydoc/config/converter.yml index b6f3aae0d..5c3e09c64 100644 --- a/docs/pydoc/config-preview/converter.yml +++ b/docs/pydoc/config/converter.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/converters] + search_path: [../../../haystack/components/converters] modules: ["azure", "html", "markdown", "pypdf", "tika", "txt"] ignore_when_discovered: ["__init__"] processors: @@ -13,11 +13,11 @@ processors: - type: crossref renderer: type: renderers.ReadmePreviewRenderer - excerpt: Extracts text from files in different formats and converts it into the unified Document format. + excerpt: Extracts text from files in different formats and converts it into a unified Document format. category_slug: haystack-classes title: Converter API slug: converter-api - order: 50 + order: 20 markdown: descriptive_class_title: false descriptive_module_title: true diff --git a/docs/pydoc/config/dataclass.yml b/docs/pydoc/config/dataclass.yml new file mode 100644 index 000000000..faba0790b --- /dev/null +++ b/docs/pydoc/config/dataclass.yml @@ -0,0 +1,26 @@ +loaders: + - type: loaders.CustomPythonLoader + search_path: [../../../haystack/dataclasses] + modules: ["answer", "byte_steam", "chat_message", "document", "streaming_chunk"] + ignore_when_discovered: ["__init__"] +processors: + - type: filter + expression: + documented_only: true + do_not_filter_modules: false + skip_empty_modules: true + - type: smart + - type: crossref +renderer: + type: renderers.ReadmePreviewRenderer + excerpt: Core classes that carry data through the system. + category_slug: data-classes + title: Data Classes API + slug: data-classes-api + order: 30 + markdown: + descriptive_class_title: false + descriptive_module_title: true + add_method_class_prefix: true + add_member_class_prefix: false + filename: data_classes_api.md diff --git a/docs/pydoc/config-preview/document_store.yml b/docs/pydoc/config/document_store.yml similarity index 89% rename from docs/pydoc/config-preview/document_store.yml rename to docs/pydoc/config/document_store.yml index 6c51c4629..7901a4622 100644 --- a/docs/pydoc/config-preview/document_store.yml +++ b/docs/pydoc/config/document_store.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/document_stores/in_memory] + search_path: [../../../haystack/document_stores/in_memory] modules: ["document_store"] ignore_when_discovered: ["__init__"] processors: @@ -17,7 +17,7 @@ renderer: category_slug: haystack-classes title: DocumentStore API slug: document-store-api - order: 20 + order: 40 markdown: descriptive_class_title: false descriptive_module_title: true diff --git a/docs/pydoc/config-preview/embedder.yml b/docs/pydoc/config/embedder.yml similarity index 91% rename from docs/pydoc/config-preview/embedder.yml rename to docs/pydoc/config/embedder.yml index 077d292dc..561f95134 100644 --- a/docs/pydoc/config-preview/embedder.yml +++ b/docs/pydoc/config/embedder.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/embedders] + search_path: [../../../haystack/components/embedders] modules: ["openai_document_embedder", "openai_text_embedder", "sentence_transformers_document_embedder", "sentence_transformers_text_embedder"] ignore_when_discovered: ["__init__"] processors: @@ -17,7 +17,7 @@ renderer: category_slug: haystack-classes title: Embedder API slug: embedder-api - order: 40 + order: 60 markdown: descriptive_class_title: false descriptive_module_title: true diff --git a/docs/pydoc/config-preview/fetcher.yml b/docs/pydoc/config/fetcher.yml similarity index 90% rename from docs/pydoc/config-preview/fetcher.yml rename to docs/pydoc/config/fetcher.yml index 7d7a6ee4b..be6f100d8 100644 --- a/docs/pydoc/config-preview/fetcher.yml +++ b/docs/pydoc/config/fetcher.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/fetchers] + search_path: [../../../haystack/components/fetchers] modules: ["link_content"] ignore_when_discovered: ["__init__"] processors: @@ -17,7 +17,7 @@ renderer: category_slug: haystack-classes title: LinkContentFetcher API slug: fetcher-api - order: 70 + order: 80 markdown: descriptive_class_title: false descriptive_module_title: true diff --git a/docs/pydoc/config-preview/generator.yml b/docs/pydoc/config/generator.yml similarity index 90% rename from docs/pydoc/config-preview/generator.yml rename to docs/pydoc/config/generator.yml index dbed3a820..2e4604220 100644 --- a/docs/pydoc/config-preview/generator.yml +++ b/docs/pydoc/config/generator.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/generators] + search_path: [../../../haystack/components/generators] modules: ["hugging_face_local", "hugging_face_tgi", "openai", "chat/hugging_face_tgi", "chat/openai"] ignore_when_discovered: ["__init__"] processors: @@ -17,7 +17,7 @@ renderer: category_slug: haystack-classes title: Generator API slug: generator-api - order: 60 + order: 70 markdown: descriptive_class_title: false descriptive_module_title: true diff --git a/docs/pydoc/config-preview/pipeline.yml b/docs/pydoc/config/pipeline.yml similarity index 91% rename from docs/pydoc/config-preview/pipeline.yml rename to docs/pydoc/config/pipeline.yml index 2b61de545..c9a1b9b18 100644 --- a/docs/pydoc/config-preview/pipeline.yml +++ b/docs/pydoc/config/pipeline.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview] + search_path: [../../../haystack] modules: ["pipeline"] ignore_when_discovered: ["__init__"] processors: @@ -17,7 +17,7 @@ renderer: category_slug: haystack-classes title: Pipelines API slug: pipelines-api - order: 80 + order: 90 markdown: descriptive_class_title: false descriptive_module_title: true diff --git a/docs/pydoc/config-preview/preprocessor.yml b/docs/pydoc/config/preprocessor.yml similarity index 90% rename from docs/pydoc/config-preview/preprocessor.yml rename to docs/pydoc/config/preprocessor.yml index d2acf19da..436d2f590 100644 --- a/docs/pydoc/config-preview/preprocessor.yml +++ b/docs/pydoc/config/preprocessor.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/preprocessors] + search_path: [../../../haystack/components/preprocessors] modules: ["document_cleaner", "document_splitter"] ignore_when_discovered: ["__init__"] processors: @@ -17,7 +17,7 @@ renderer: category_slug: haystack-classes title: PreProcessor API slug: preprocessor-api - order: 90 + order: 100 markdown: descriptive_class_title: false descriptive_module_title: true diff --git a/docs/pydoc/config-preview/ranker.yml b/docs/pydoc/config/ranker.yml similarity index 91% rename from docs/pydoc/config-preview/ranker.yml rename to docs/pydoc/config/ranker.yml index d0fbe6d68..96a39c2f8 100644 --- a/docs/pydoc/config-preview/ranker.yml +++ b/docs/pydoc/config/ranker.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/rankers] + search_path: [../../../haystack/components/rankers] modules: ["meta_field", "transformers_similarity"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/reader.yml b/docs/pydoc/config/reader.yml similarity index 91% rename from docs/pydoc/config-preview/reader.yml rename to docs/pydoc/config/reader.yml index 59163e442..d130aca0a 100644 --- a/docs/pydoc/config-preview/reader.yml +++ b/docs/pydoc/config/reader.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/readers] + search_path: [../../../haystack/components/readers] modules: ["extractive"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/retriever.yml b/docs/pydoc/config/retriever.yml similarity index 91% rename from docs/pydoc/config-preview/retriever.yml rename to docs/pydoc/config/retriever.yml index 805753de5..1a6f04431 100644 --- a/docs/pydoc/config-preview/retriever.yml +++ b/docs/pydoc/config/retriever.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/retrievers] + search_path: [../../../haystack/components/retrievers] modules: ["in_memory_bm25_retriever", "in_memory_embedding_retriever"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/router.yml b/docs/pydoc/config/router.yml similarity index 92% rename from docs/pydoc/config-preview/router.yml rename to docs/pydoc/config/router.yml index 742922f07..e1cc0ab18 100644 --- a/docs/pydoc/config-preview/router.yml +++ b/docs/pydoc/config/router.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/routers] + search_path: [../../../haystack/components/routers] modules: ["document_joiner", "conditional_router", "file_type_router", "metadata_router", "text_language_router"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/sampler.yml b/docs/pydoc/config/sampler.yml similarity index 91% rename from docs/pydoc/config-preview/sampler.yml rename to docs/pydoc/config/sampler.yml index fe1072ab6..d9e033051 100644 --- a/docs/pydoc/config-preview/sampler.yml +++ b/docs/pydoc/config/sampler.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/samplers] + search_path: [../../../haystack/components/samplers] modules: ["top_p"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/websearch.yml b/docs/pydoc/config/websearch.yml similarity index 90% rename from docs/pydoc/config-preview/websearch.yml rename to docs/pydoc/config/websearch.yml index 6433940e0..deb257bcb 100644 --- a/docs/pydoc/config-preview/websearch.yml +++ b/docs/pydoc/config/websearch.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/websearch] + search_path: [../../../haystack/components/websearch] modules: ["serper_dev"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/whisper.yml b/docs/pydoc/config/whisper.yml similarity index 91% rename from docs/pydoc/config-preview/whisper.yml rename to docs/pydoc/config/whisper.yml index 1d47d8016..3a6bf9190 100644 --- a/docs/pydoc/config-preview/whisper.yml +++ b/docs/pydoc/config/whisper.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/audio] + search_path: [../../../haystack/components/audio] modules: ["whisper_local", "whisper_remote"] ignore_when_discovered: ["__init__"] processors: diff --git a/docs/pydoc/config-preview/writer.yml b/docs/pydoc/config/writer.yml similarity index 89% rename from docs/pydoc/config-preview/writer.yml rename to docs/pydoc/config/writer.yml index 9ff009536..20f63b13c 100644 --- a/docs/pydoc/config-preview/writer.yml +++ b/docs/pydoc/config/writer.yml @@ -1,6 +1,6 @@ loaders: - type: loaders.CustomPythonLoader - search_path: [../../../haystack/preview/components/writers] + search_path: [../../../haystack/components/writers] modules: ["document_writer"] ignore_when_discovered: ["__init__"] processors: @@ -17,7 +17,7 @@ renderer: category_slug: haystack-classes title: DocumentWriter API slug: writer-api - order: 30 + order: 50 markdown: descriptive_class_title: false descriptive_module_title: true