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

Expand and Refactor Latin Verb Query to Focus on Present Tense Forms #435

Open
wants to merge 20 commits into
base: main
Choose a base branch
from

Conversation

KesharwaniArpita
Copy link
Contributor

Contributor checklist


Description

This WIP PR expands and refactors the existing SPARQL query to focus solely on Present Tense verb forms(till now) for Latin (Q397) verbs. The changes made include:

  • Simplified the query to filter verb forms by Present Tense using a single VALUES block.
  • Removed redundant specifications for tense in each optional block by centralizing the Present Tense filter.
  • Maintained retrieval of all necessary conjugations (Imperative, Subjunctive, Indicative) while limiting results to Present Tense forms.
  • Updated all OPTIONAL blocks to align with this restriction, ensuring they cover Subjunctive, Imperative, and Indicative for different persons (First, Second, Third; Singular and Plural).
  • Improved query readability and maintainability by centralizing tense filtering.

Testing:

  • Ran the query on the Wikidata Query Service to ensure the correct present tense verb forms are returned.
  • Verified that forms such as Subjunctive Active, Imperative Active, and Indicative Passive are returned correctly for all persons (Singular and Plural).

Future Work:

  1. Past Tense: A similar refactor can be done to retrieve past tense verb forms(available on wikidata). These can be added using a VALUES block that filters for relevant grammatical features such as:

  2. Future Tense: The query can be extended to retrieve future tense forms by adding future-specific grammatical features:

Both Past and Future tense forms can follow the same pattern as this Present Tense query, with additional VALUES blocks or separate queries focused on those tenses.

Impact:

The refactor improves the clarity and performance of the current query by focusing on a single tense while maintaining flexibility for future enhancements to cover other tenses.

Related issue

Copy link

github-actions bot commented Oct 19, 2024

Thank you for the pull request!

The Scribe team will do our best to address your contribution as soon as we can. The following is a checklist for maintainers to make sure this process goes as well as possible. Feel free to address the points below yourself in further commits if you realize that actions are needed :)

If you're not already a member of our public Matrix community, please consider joining! We'd suggest using Element as your Matrix client, and definitely join the General and Data rooms once you're in. Also consider joining our bi-weekly Saturday dev syncs. It'd be great to have you!

Maintainer checklist

  • The linting and formatting workflow within the PR checks do not indicate new errors in the files changed

  • The CHANGELOG has been updated with a description of the changes for the upcoming release and the corresponding issue (if necessary)

@KesharwaniArpita
Copy link
Contributor Author

Hi @andrewtavis would you take a look on the PR? Took me some time to figure out how to extract this much data and reduce the redundancy, I have written the query to extract the verbs associated with Present tense form. I wanted to ask if this query make sense? If yes, so I can follow up with the query for other forms of verbs too.

So, I followed the set of grammatical features that uniquely defines a form of verb defined for the this lexeme and it turns out there are a lot of possible grammatical feature combinations. So, I was wondering if we should split this issue into smaller subsets and target each subset individually so that if someone else is also interested they can also help with it easily.

@andrewtavis andrewtavis self-requested a review October 21, 2024 11:11
@andrewtavis andrewtavis added the hacktoberfest-accepted Accepted as a part of Hacktoberfest label Oct 21, 2024
@KesharwaniArpita
Copy link
Contributor Author

The last commit is from @Otom-obhazi . Thanks for your help!!!

@andrewtavis andrewtavis mentioned this pull request Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hacktoberfest-accepted Accepted as a part of Hacktoberfest
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants