Skip to content

Allow examples when auto documenting workflow #30

@KennethEnevoldsen

Description

@KennethEnevoldsen

Currently, commands remove spacing and newlines when creating the documentation from the docstring. This prevents adding examples to the documentation.

E.g.

    Runs the Benchmark on a specified model.


    **Example:**

    ```{python}
    # running a model on all languages and tasks
    seb run sentence-transformers/all-MiniLM-L6-v2 -o results.json

    # Running a model on a subset of languages
    seb run sentence-transformers/all-MiniLM-L6-v2 -o results.json -l da sv no nn

    # Running a model on a subset of tasks
    seb run sentence-transformers/all-MiniLM-L6-v2 -o results.json -t DKHate ScaLA

Becomes:

Runs the Benchmark on a specified model. Example: ```{python} # running a model on all languages and tasks seb run sentence-transformers/all-MiniLM-L6-v2 -o results.json # Running a model on a subset of languages seb run sentence-transformers/all-MiniLM-L6-v2 -o results.json -l da sv no nn # Running a model on a subset of tasks seb run sentence-transformers/all-MiniLM-L6-v2 -o results.json -t DKHate ScaLA

A potential fix is to remove the _strip command to avoid removing newlines.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions