Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
184 views
in Technique[技术] by (71.8m points)

javascript - I would like to know how the Google search autocomplete function works

I'm now starting a project to create an api that does autocomplete. While collecting references, ask questions to know the structure and structure that is auto-completed when you enter a search term in real time on Google or other search engine sites, and the techniques used.

The structure I know briefly is the same.

Client -> Enter search term -> Server -> Query query -> DB

Client <- search term input <- server <- search term query <-DB

Thanks for the comment. I don't know in detail yet, so I'll tell you the scenario I want to know. Suppose a user enters the alphabet of's','t','a','c','k' as a search word after accessing a search engine site. Then, at this time, the client and server want to know if they communicate in real time as soon as the alphabet is entered

If so, is the communication method ajax? Is there a way to use the data necessary for the auto-completion function in the local area where the client is located other than real-time communication with the server?

Because it is limited to use a server to place an api that functions as auto-completion, there is a problem that it will be difficult to handle the traffic generated when real-time input occurs.

question from:https://stackoverflow.com/questions/65949127/i-would-like-to-know-how-the-google-search-autocomplete-function-works

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

1.4m articles

1.4m replys

5 comments

57.0k users

...