mirror of
https://github.com/deepset-ai/haystack.git
synced 2025-12-30 00:30:09 +00:00
* Adding translator with many generic input parameter support * Making dict_key as generic * Fixing mypy issue * Adding pipeline and using opus models * Add latest docstring and tutorial changes * Adding test cases for end-to-end translation for generator, summerizer etc * raise error join and merge nodes * Fix test failure * add docstrings. add usage documentation. rm skip_special_tokens param * Add latest docstring and tutorial changes * fix code snippets in md * Adding few extra configuration parameters and fixing tests * Fixingmypy issue and updating usage document * fix for mypy issue in pipeline.py * reverting renaming of pytest_collection_modifyitems method * Addressing review comments * setting skip_special_tokens to True * removing model_max_length argument as None type is not supported to many models * Removing padding parameter. Better to leave it as default otherwise it cause tensor size miss match error. If this option required by used then it can be added later. Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Malte Pietsch <malte.pietsch@deepset.ai>
📒 Looking for the docs?
You find them here here:
https://haystack.deepset.ai/docs/intromd
💻 How to update docs?
Usage / Guides etc.
Will be automatically deployed with every commit to the master branch
API Reference
We use Pydoc-Markdown to create markdown files from the docstrings in our code.
Update docstrings
Execute this in /haystack/docs/_src/api/api:
pip install 'pydoc-markdown>=3.0.0,<4.0.0'
pydoc-markdown pydoc-markdown-document-store.yml
pydoc-markdown pydoc-markdown-file-converters.yml
pydoc-markdown pydoc-markdown-preprocessor.yml
pydoc-markdown pydoc-markdown-reader.yml
pydoc-markdown pydoc-markdown-generator.yml
pydoc-markdown pydoc-markdown-retriever.yml
pydoc-markdown pydoc-markdown-pipelines.yml
(Or run one of the commands above to update the docstrings only for a single module)
Configuration
Pydoc will read the configuration from a .yml file which is located in the current working directory. Our files contains three main sections:
- loader: A list of plugins that load API objects from python source files.
- type: Loader for python source files
- search_path: Location of source files
- ignore_when_discovered: Define which files should be ignored
- processor: A list of plugins that process API objects to modify their docstrings (e.g. to adapt them from a documentation format to Markdown or to remove items that should not be rendered into the documentation).
- ignore_when_discovered: Define which API objects should be ignored
- documented_only: Only documented API objects
- do_not_filter_modules: Do not filter module objects
- skip_empty_modules: Skip modules without content
- renderer: A plugin that produces the output files.
- type: Define the renderer which you want to use. We are using the Markdown renderer as it can be configured in very detail.
- descriptive_class_title: Remove the word "Object" from class titles.
- filename: file name of the generated file