Skip to content

Allow configuration of source_id and split_id in SentenceWindowRetriever #9592

Open
@sjrl

Description

@sjrl

Is your feature request related to a problem? Please describe.
This was a request from @ju-gu where for a specific client they would like to use the SentenceWindowRetriever but they need to pass in custom meta keys for source_id and split_id which are hard-coded in Haystack's SentenceWindowRetriever.

Describe the solution you'd like
I'd like to make these fields configurable so users with custom preprocessing set ups can still benefit from this component. I think we should make two new init params to the component source_id_meta_field and split_id_meta_field that have default values source_id and split_id respectively. This way default behavior stays the same, but then users can customize which meta fields contain this information.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High priority, add to the next sprint

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions