Skip to content
This repository has been archived by the owner on Oct 10, 2024. It is now read-only.

Add /history command #21

Closed
TimJentzsch opened this issue Jun 16, 2021 · 1 comment · Fixed by #27
Closed

Add /history command #21

TimJentzsch opened this issue Jun 16, 2021 · 1 comment · Fixed by #27
Assignees
Labels
command Adding or modifying a bot command enhancement New feature or request

Comments

@TimJentzsch
Copy link
Contributor

TimJentzsch commented Jun 16, 2021

Add a /history command to see the history of transcriptions made by a user.
This would work similar to the !history command of the old bot as detailed in #11.

Example response of the old bot:
Response of the old bot to the !history command

It shows a plot of the user gamma in relation to the time. Additionally, the rank milestones are visible as lines on the graph.

Options:

  • user 1 (optional): The user to get the history graph for. Defaults to the user executing the command.
  • user 2 (optional): The second user to plot alongside the first one. Defaults to none.
  • user 3 (optional): The third user to plot alongside the other ones. Defaults to none.
@TimJentzsch TimJentzsch added enhancement New feature or request command Adding or modifying a bot command labels Jun 16, 2021
@TimJentzsch
Copy link
Contributor Author

TimJentzsch commented Jun 16, 2021

This could be implemented like this:

  1. Get the current gamma of the user via the volunteer endpoint.
  2. Get the transcriptions of the user via the transcription endpoint. For each page of transcriptions, do the following:
    1. Calculate the current gamma at the point of each transcription with the help of the total gamma count of the user
    2. Add the times and the gamma counts to a list of data points
    3. Plot the datapoints with pyplot, in addition to the milestone lines
    4. Update the response to the user with the current graph

This is not very efficient and might take a while for users like Cloakknight, but the iterative updates ensure that the user quickly gets a response.

@TimJentzsch TimJentzsch self-assigned this Jun 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
command Adding or modifying a bot command enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant