IP Library › Granted Patent US 12,450,429
Granted Patent B2
US 12,450,429 · App. 18/103,195 · Granted Oct 21, 2025

Offline spellcheck candidates complementing runtime spellcheck

Inventors: Adithya Rajan (Edison, NJ); Weiqi Tong (Brooklyn, NY); Zheng Yan (Short Hills, NJ)
Assignee: WALMART APOLLO, LLC
G06F40/232G06F16/24552
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 12,450,429
App. No.
18/103,195
Granted
Oct 21, 2025
Kind
B2
Abstract

A method including extracting queries from historical search query data. The method also can include spellchecking each of the queries (i) using a first spellcheck model and (ii) using a second spellcheck model. A latency of the first spellcheck model is lower than a latency of the second spellcheck model, and an overall accuracy of the second spellcheck model is higher than an overall accuracy of the first spellcheck model. The method additionally can include determining first queries of the queries in which, for each of the first queries, a first respective spellcheck output from the first spellcheck model is different from a second respective spellcheck output from the second spellcheck model. The method further can include adding at least a portion of the first queries to a spellcheck cache for runtime spellchecking. Other embodiments are described.

Claims (52)

1. A system comprising:

one or more processors; and

one or more non-transitory computer-readable media storing computing instructions that, when executed on the one or more processors, cause the one or more processors to:

extract queries from historical search query data;

spellcheck each of the queries (i) using a first spellcheck model and (ii) using a second spellcheck model, wherein a latency of the first spellcheck model is lower than a latency of the second spellcheck model, and

wherein an overall accuracy of the second spellcheck model is higher than an overall accuracy of the first spellcheck model;

determine first queries of the queries in which, for each of the first queries, a first respective spellcheck output from the first spellcheck model is different from a second respective spellcheck output from the second spellcheck model; and

add at least a portion of the first queries to a spellcheck cache, for runtime spellchecking, that is configured to override the first spellcheck model and that maps the portion of the first queries to one or more corrections based at least in part on the second respective spellcheck output for the portion of the first queries.

2. The system of claim 1 , wherein the computing instructions, when executed on the one or more processors, further cause the one or more processors to, during the runtime spellchecking:

receive a query;

determine whether the query is within the spellcheck cache;

when the query is within the spellcheck cache, use the spellcheck cache to spellcheck the query; and

when the query is not within the spellcheck cache, use the first spellcheck model to spellcheck the query.

3. The system of claim 1 , wherein:

the spellcheck cache comprises a hashmap comprising keys and values;

the keys comprise the portion of the first queries; and

the values comprise the one or more corrections.

4. The system of claim 1 , wherein the queries are top queries in the historical search query data during a first time period.

5. The system of claim 1 , wherein the spellcheck cache further comprises second queries that are top queries in the historical search query data during a second time period.

6. The system of claim 1 , wherein the first spellcheck model and the second spellcheck model are each a respective transformer-based sequence-to-sequence machine-learning model.

7. The system of claim 1 , wherein a layer quantity of the first spellcheck model is less than a layer quantity of the second spellcheck model.

8. The system of claim 1 , wherein an embedding dimension of the first spellcheck model is less than an embedding dimension of the second spellcheck model.

9. A method implemented via execution of computing instructions configured to run at one or more processors, the method comprising:

extracting queries from historical search query data;

spellchecking each of the queries (i) using a first spellcheck model and (ii) using a second spellcheck model,

wherein a latency of the first spellcheck model is lower than a latency of the second spellcheck model, and

wherein an overall accuracy of the second spellcheck model is higher than an overall accuracy of the first spellcheck model;

determining first queries of the queries in which, for each of the first queries, a first respective spellcheck output from the first spellcheck model is different from a second respective spellcheck output from the second spellcheck model; and

adding at least a portion of the first queries to a spellcheck cache, for runtime spellchecking, that is configured to override the first spellcheck model and that maps the portion of the first queries to one or more corrections based at least in part on the second respective spellcheck output for the portion of the first queries.

10. The method of claim 9 , further comprising, during the runtime spellchecking:

receiving a query;

determining that the query is within the spellcheck cache; and

using, based on determining that the query is within the spellcheck cache, the spellcheck cache to spellcheck the query.

11. The method of claim 9 , wherein the spellcheck cache maps the portion of the first queries to corrections for the portion of the first queries.

12. The method of claim 11 , wherein the corrections are based at least in part on the second respective spellcheck output for the portion of the first queries.

13. The method of claim 9 , wherein:

the spellcheck cache comprises a hashmap comprising keys and values;

keys comprise the portion of the first queries; and

the values comprise corrections for the portion of the first queries.

14. The method of claim 9 , wherein the queries are top queries in the historical search query data during a first time period.

15. The method of claim 9 , wherein the spellcheck cache further comprises second queries that are top queries in the historical search query data during a second time period.

16. The method of claim 9 , wherein the first spellcheck model and the second spellcheck model are each a respective transformer-based sequence-to-sequence machine-learning model.

17. The method of claim 9 , wherein a layer quantity of the first spellcheck model is less than a layer quantity of the second spellcheck model.

18. The method of claim 9 , wherein an embedding dimension of the first spellcheck model is less than an embedding dimension of the second spellcheck model.

19. One or more non-transitory, computer-readable media, comprising instructions that, when executed by one or more processors, cause the one or more processors to:

extract a query queries from historical search query data;

spellcheck a query, of the queries, using a first spellcheck model and using a second spellcheck model,

wherein a latency of the first spellcheck model is lower than a latency of the second spellcheck model, and

wherein an overall accuracy of the second spellcheck model is higher than an overall accuracy of the first spellcheck model;

determine that, for the query, a first spellcheck output from the first spellcheck model is different from a second spellcheck output from the second spellcheck model; and

add the query at least a portion of the queries to a spellcheck cache that is configured to override the first spellcheck model and that maps the query the portion of the queries to one or more corrections based at least in part on the second spellcheck output, wherein the portion of the queries includes the query.

20. The one or more non-transitory, computer-readable media of claim 19 , wherein a layer quantity of the first spellcheck model is less than a layer quantity of the second spellcheck model.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 28, 2023
From: RAJAN, ADITHYA; TONG, WEIQI; YAN, ZHENG
To: WALMART APOLLO, LLC
Reel/Frame 063483/0269 →
Continuity (1)
Related Publication 20240256768A1 · Aug 1, 2024
References Cited (23)
US 6047300A · Walfish · 2000 [cited by examiner]
US 6401084B1 · Ortega et al. · 2002 [cited by applicant]
US 7669112B2 · Bates et al. · 2010 [cited by applicant]
US 8201086B2 · Kritt · 2012 [cited by examiner]
US 8655904B2 · Baird-Smith · 2014 [cited by examiner]
US 9047012B1 · Bringert · 2015 [cited by examiner]
US 9251294B2 · Nevidomski · 2016 [cited by examiner]
US 10936813B1 · Gupta · 2021 [cited by examiner]
US 20080147637A1 · Li et al. · 2008 [cited by applicant]
US 20080249764A1 · Huang et al. · 2008 [cited by applicant]
US 20090089261A1 · Leher · 2009 [cited by examiner]
US 20100325539A1 · Nedzlek · 2010 [cited by examiner]
US 20120284308A1 · Paduroiu · 2012 [cited by examiner]
US 20130060560A1 · Mahkovec · 2013 [cited by examiner]
US 20200226211A1 · Brake · 2020 [cited by examiner]
US 20200356578A1 · Frieder · 2020 [cited by examiner]
US 20220269857A1 · Carrier · 2022 [cited by examiner]
US 20220382818A1 · Chen et al. · 2022 [cited by applicant]
Nather “An In-Depth Comparison of 14 Spelling Correction Tools on a Common Benchmark”. Proceedings of the 12th Conference on Language Resources and Evaluation (LREC 2020), pp. 1849-1857 Marseille, May 11-16, 2020 (Year:… [cited by examiner]
Zolzaya et al. “Normalization of Transliterated Words Using Seq2Seq Model with Spell Checker”. 26th Annual Conference of the Association for Natural Language Processing, 2020. (Year: 2020). [cited by examiner]
Chen, T., “Batch Interference in Azure Machine Learning,” Microsoft Community Hug, retrieved from https://techcommunity.microsoft.com/t5/ai-machine-learning-blog/batch-inference-in-azure-machine-learning/ba-p/1417010 on… [cited by applicant]
Kuznetsov, A. and Urdiales, H., “Spelling Correction With Denoising Transformer,” Retrieved from arXiv:2105.05977v1 [cs.CL] May 12, 2021. [cited by applicant]
Lakhotia, N., “Spelling Rectification App Using TextBlob & Pyspellchecker,” published in Towards Data Science on Ocotober 5, 2020, retrieved on Jan. 5, 2023, from https://towardsdatascience.com/spelling-rectification-ap… [cited by applicant]