Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changed export to csv method to new answer format #1907

Merged
merged 1 commit into from Dec 17, 2021

Conversation

Johnny-KP
Copy link
Contributor

Proposed changes

Export answers to csv method was broken since refactoring changes of the schema (answer format).

This PR fixes the export_answers_to_csv method

This method is not used at the moment.

@julian-risch julian-risch self-assigned this Dec 17, 2021
@julian-risch julian-risch added the topic:predictions format of predictions, score, probability ... label Dec 17, 2021
@julian-risch julian-risch self-requested a review December 17, 2021 15:06
@julian-risch julian-risch removed their assignment Dec 17, 2021
Copy link
Member

@julian-risch julian-risch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 👍

Tested it together with @Johnny-KP in a notebook:

all_preds = []
for q in query: 
    prediction = pipe.run(query=q, params={"Retriever": {"top_k": 10}, "Reader": {"top_k": 3}})
    all_preds.append(prediction)
export_answers_to_csv(all_preds, output_file="congrats_to_your_first_pr.csv")

@julian-risch julian-risch merged commit 51e84b8 into deepset-ai:master Dec 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic:predictions format of predictions, score, probability ...
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants