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

Introduce textblob framework to analysis word #20

Merged
merged 5 commits into from
Sep 4, 2024

Conversation

mrproliu
Copy link
Collaborator

@mrproliu mrproliu commented Sep 3, 2024

If the pattern contains words, then we should not combine them as a variable path.
For example, there are three URLs /test/t/one, test/t/two/, and test/t/three. In the old way, they will combine to /test/t/{var}, After we add textblob and word spitter, the result will keep the original URL list.

The Basic logic is:

  1. Split the word in each URL step by camel and digits.
  2. Use the textblob framework to analyze whether the word is correct or not, If the word is correct, then the URL will not merge into the existing pattern, otherwise, keep the original logical.

Finally, we can reduce the DRAIN_COMBINE_MIN_URL_COUNT environment to reduce the count of combined URL logic.

@mrproliu mrproliu added the enhancement New feature or request label Sep 3, 2024
@mrproliu mrproliu added this to the 0.3.0 milestone Sep 3, 2024
@wu-sheng
Copy link
Member

wu-sheng commented Sep 3, 2024

Could you share the examples here? Such as how these work

  • /rootpath/productSale
  • /rootpath/prodcut_sale/
  • /rootpath/product/{UUID list}, UUID is a combination of digits and texts, but not meaningful words.

@mrproliu
Copy link
Collaborator Author

mrproliu commented Sep 4, 2024

Here are some examples:

All word

Data

/test/productSale
/test/product_Sale
/test/productOnSale

Result

/test/productSale
/test/product_Sale
/test/productOnSale

UUID

Data

/test/one/f0dce0206a8011ef8670df368ea4fcf1
/test/one/f0dce0216a8011ef8670df368ea4fcf1
/test/one/f0dce0226a8011ef8670df368ea4fcf1
/test/two/0730f8706a8111ef8670df368ea4fcf1
/test/two/0730f8716a8111ef8670df368ea4fcf1
/test/two/0730f8726a8111ef8670df368ea4fcf1
/test/three/26e2add06a8111ef8670df368ea4fcf1
/test/three/26e2d4e06a8111ef8670df368ea4fcf1
/test/three/26e2d4e16a8111ef8670df368ea4fcf1

Result

/test/one/{var}
/test/two/{var}
/test/three/{var}

@wu-sheng wu-sheng merged commit 3c533d9 into SkyAPM:main Sep 4, 2024
3 checks passed
@mrproliu mrproliu deleted the text-spelling branch September 4, 2024 06:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants