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

How to return context (+ or - few lines) around the hits of given search text #429

Open
anandncode opened this issue Feb 29, 2024 · 0 comments

Comments

@anandncode
Copy link

Hi,

I am looking for this particular feature.

  1. Suppose I have text of 100 lines.
  2. I have created the index and added this text
  3. I am searching for 2 words.
  4. These words are found at lines 20, 50 (lets call them as hits)
  5. In the result set I am looking for text around the hits
    • That is something like 15 to 25 lines, 45 to 55 lines

It may not be exactly lines, but it can be few characters/words around the hits.
I tried creating contextual index & enrich result set. But none seems to be working. In the results I see the whole 100 lines of text instead of specific hits.

Any help would be highly appreciated

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

No branches or pull requests

1 participant