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

Creating a new localization rule set for vale #788

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

Conversation

reachlekha
Copy link

@reachlekha reachlekha commented May 15, 2024

Creates a new localization rule set for highlighting common words that can cause trouble for translators.
The first cut includes the following word categories :

  • Modals
  • Commonly misused words
  • Phrasal words
  • Words with multiple meanings

@chloeredhat @aireilly @rolfedh @rohennes - Please help review! Thanks!

Copy link

Click here to review and test in web IDE: Contribute

Copy link

github-actions bot commented May 15, 2024

🎊 Navigate the preview: https://redhat-documentation-vale-at-red-hat-788.surge.sh 🎊

@aireilly
Copy link
Member

Have you reviewed https://www.ibm.com/docs/en/ibm-style?topic=medium-global-audiences? I bet there are lots of things we could incorporate

Copy link
Member

@aireilly aireilly left a comment

Choose a reason for hiding this comment

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

Some good phrasal verb terms here pulled from the ISG: #809

@aireilly
Copy link
Member

Some good phrasal verb terms here pulled from the ISG: #809

Also maybe, "picks? up," "gives? up," or "sets? up"

allow | enable: allow for
continue: carry on
depend: count on
result: end up
Copy link
Member

Choose a reason for hiding this comment

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

This will flag every instance of result in source. There will be many false positives.

depend: count on
result: end up
imply: get at
click: click on
Copy link
Member

Choose a reason for hiding this comment

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

This will flag every instance of click, even if it is followed by "on".

@@ -0,0 +1,24 @@
---
Copy link
Member

Choose a reason for hiding this comment

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

General comment for this rule - as it is laid out below, there will be a huge amount of false positives for this rule. Need to reduce the false positives to make this useful.

@@ -12,3 +12,11 @@ tokens:
- this chapter
- this section
- this subsection
- The following
Copy link
Member

@aireilly aireilly Jul 25, 2024

Choose a reason for hiding this comment

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

https://www.ibm.com/docs/en/ibm-style?topic=word-usage#following

Can we make this more useful by creating a sequence rule that returns instances of "following" where it is not in the adjectival position before a noun?

Hint:

https://github.com/aireilly/vale-at-red-hat/blob/add-pos-using-rule/.vale/styles/RedHat/Using.yml

https://vale.sh/docs/topics/styles/#sequence

swap:
# Start each error message with "Do not use ..."
# Error messages must be single quoted.
do: carry out
Copy link
Member

Choose a reason for hiding this comment

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

I think all these rules are mixed up. They should be in the form bad: good

.vale/fixtures/Localization/AdjectivesWithNouns/.vale.ini Outdated Show resolved Hide resolved
.vale/fixtures/Localization/PhrasalVerbs/.vale.ini Outdated Show resolved Hide resolved
Comment on lines +11 to +12
# Start each error message with "Do not use ..."
# Error messages must be single quoted.

Choose a reason for hiding this comment

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

I don't get this comment.

It seems related to the error message,not the swap section

Copy link
Collaborator

Choose a reason for hiding this comment

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

@aireilly Could you please help clarify this rule?

.vale/styles/Localization/CommonlyMisusedWords.yml Outdated Show resolved Hide resolved
StylesPath = ../../../styles
MinAlertLevel = warning
[*.adoc]
Localization.TermsWarnings = YES
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
Localization.TermsWarnings = YES
Localization.PhrasalVerbs = YES

StylesPath = ../../../styles
MinAlertLevel = warning
[*.adoc]
Localization.TermsWarnings = YES
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
Localization.TermsWarnings = YES
Localization.WordswithMultipleMeanings = YES

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants