Skip to content

Add support for searching case names by acronym #10

@ProbablyFaiz

Description

@ProbablyFaiz

This is tricky. Some thoughts in no particular order:

  • We can parse the query such that an all-caps token is also searched as an acronym
    • For example, a search for NIFLA should be treated, roughly, as a search for N* I* F* L* A*, while also allowing for uncapitalized conjunctions, articles, and prepositions to not be included in the acronym.
  • One way to do this would be to pass a prefix query just like the one above to Postgres with FOLLOWED BY (<->) operators in between, but Postgres doesn't seem to respect single letter prefix-matches. Look more into this.
  • The other way to do this is to create a curated index as part of the case names to pre-generate possible abbreviations, and when we think there's an abbreviation, query that too.
    • Alternatively, just include the abbreviation(s) in the current searchable case index to have it get surfaced.

Metadata

Metadata

Assignees

Labels

featureNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions