Multi-model intelligent interaction method and system based on browser extension and computing equipment

By injecting the sidebar interface into the browser with low intrusion, it automatically collects webpage context information, adopts a local priority routing strategy to select a model, realizes knowledge closed-loop interaction and cross-object unified search, solves the data leakage risk and network instability problem of browser extension tools, and provides efficient and privacy-protected AI-assisted functions.

CN121657897APending Publication Date: 2026-03-13宿州市公安局
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-11
Publication Date
2026-03-13

AI Technical Summary

Technical Problem

Existing browser extensions cannot fully utilize webpage context information, lack flexible model selection, pose a risk of data leakage, and cannot use AI-assisted functions when the network is unstable.

Method used

The sidebar interface is injected into the browser with low intrusion, automatically collecting webpage context information, and adopting a local priority routing strategy to select local or cloud models, realizing closed-loop knowledge interaction and unified cross-object search, combined with local storage management to protect privacy.

Benefits of technology

It improves the relevance and accuracy of AI responses, provides flexible model selection, protects user privacy, and allows AI-assisted functions to still be used when the network is unstable.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121657897A_ABST
    Figure CN121657897A_ABST
Patent Text Reader

Abstract

The invention discloses a multi-model intelligent interaction method and system based on browser extension and computing equipment, and belongs to the technical field of computer software, the method comprises the following steps: in response to an operation of activating an intelligent auxiliary function in a browser by a user, injecting a sidebar dialogue interface in a low intrusion manner in any currently browsed webpage; automatically sampling the context information of the current webpage, wherein the context information at least comprises one of a webpage title, a text selected by a user or a webpage URL (Uniform Resource Locator); a user request containing the context information is sent to a corresponding local or cloud artificial intelligence model endpoint according to a local priority routing strategy, and a streaming AI response is obtained; and receiving the streaming AI response, and displaying the streaming AI response in the interactive interface of the sidebar. Therefore, a low-intrusion and privacy-first intelligent auxiliary function is realized in a browser environment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to a multi-model intelligent interaction method, system, and computing device based on browser extensions, belonging to the field of computer software technology. Background Technology

[0002] With the rapid development of internet technology, browsers have become the core entry point for users to obtain information, conduct work, and interact online. To improve the efficiency and intelligence of browsers, various browser extensions have emerged, covering functions such as ad blocking, password management, translation assistance, and note-taking. In recent years, the explosive development of artificial intelligence technology has driven the intelligent upgrade of browser extensions, resulting in a number of intelligent auxiliary extensions integrating AI models, aiming to provide users with services such as dialogue interaction, knowledge Q&A, and content generation through AI capabilities.

[0003] While some browser extensions exist that can provide basic AI-assisted functions, these plugins often suffer from the following drawbacks: Most plugins fail to fully utilize the contextual information of the currently viewed webpage, resulting in AI models' responses lacking specificity and accuracy.

[0004] They often only support a single cloud model, making it impossible to flexibly choose between a local or cloud model based on the user's actual needs and environmental conditions.

[0005] User data typically needs to be sent to cloud servers for processing, which poses a risk of data leakage.

[0006] Different functions such as knowledge base management, document processing, and unified search usually require multiple independent plugins, lacking a unified user interface.

[0007] In scenarios where the network connection is unstable or completely disconnected, users will be unable to continue using the AI-assisted functions.

[0008] Therefore, there is an urgent need in this field for an interactive solution that can provide a comprehensive, intelligent, and privacy-protected solution in a browser environment. Summary of the Invention

[0009] To address the aforementioned technical problems, this invention provides a multi-model intelligent interaction method, system, and computing device based on browser extensions, which can realize low-intrusion and privacy-first intelligent assistance functions in a browser environment.

[0010] The technical solution adopted by this invention to solve its technical problem is: A multi-model intelligent interaction method based on browser extensions, wherein the method is executed in a browser extension environment, and the specific steps include: In response to the user activating the intelligent assistance function in the browser, a sidebar dialog interface is injected in a low-intrusive manner into any webpage currently being viewed. Automatically sample the context information of the current webpage, wherein the context information includes at least one of the following: webpage title, user-selected text, or webpage URL; User requests containing the aforementioned context information are sent to the corresponding local or cloud-based AI model endpoints according to a local-first routing strategy to obtain streaming AI responses. Receive the streaming AI response and display it in the interactive interface of the sidebar.

[0011] Preferably, the local-first routing strategy includes: When a usable model endpoint is detected on the user's local machine, the user's request will be routed to the local model endpoint first. When the local model endpoint is unavailable or the response times out, the user request is automatically downgraded and routed to a preset cloud-compatible endpoint.

[0012] Preferably, it also includes knowledge closed-loop interaction, the specific steps of which include: Receive user's selection instruction for the target knowledge base, and create or switch to a dedicated dialogue session bound to that target knowledge base; Based on the question input by the user, relevant knowledge entries and associated source document summaries are retrieved from the target knowledge base; Based on the retrieved knowledge entries, construct prompts and send them to the AI ​​model endpoint; When displaying the answers returned by the model, the association provides a reference point to the knowledge entry or source document on which it is based.

[0013] Preferably, it also includes a unified cross-object search, the specific steps of which include: Receive search keywords input by the user; Based on the search keywords, the personnel database, organization database, and document database are searched in parallel; In the results interface, the search results for people, organizations, and documents are categorized and aggregated separately, and the quantity statistics for each category are displayed. In response to a user's action on any specific result, the system will display a preview of the result's details or redirect the user directly to its corresponding full information page.

[0014] Preferably, the method further includes parameterized writing, the specific steps of which include: It provides a writing parameter configuration interface, which allows users to select at least two parameters from output length, text format, tone style and language type. Based on the user-defined theme and selected parameters, the system calls an AI model endpoint to generate text content, which is then previewed in real time on the interface.

[0015] A browser extension-based intelligent assistance system for implementing the method, characterized in that it includes components deployed in a browser extension environment: The sidebar dialogue interaction module is used to inject a sidebar interface into any webpage and automatically obtain the title, selected text, URL and metadata of the current webpage as the dialogue context through the webpage context sampling component. The multi-model routing decision module is used to detect the availability of local model services in sequence according to the preset local priority strategy, and degrade to cloud models when local models are unavailable. The knowledge base dialogue closed-loop module is used to bind knowledge items to dialogue sessions at the session level, enabling item association and source tracing functions; The unified search aggregation module is used to perform unified searches on heterogeneous objects such as people, organizations, and documents, aggregate results by category, and provide previews and interactive navigation. The local storage management module is used to store session history, user configurations, and knowledge entries in the browser's local storage by default, reducing data transmission outside the browser. The sidebar dialogue interaction module, multi-model routing decision module, knowledge base dialogue closed-loop module, unified search aggregation module, and local storage management module are integrated into a single browser extension to achieve low-latency and privacy-first intelligent assistance functions.

[0016] Preferably, the sidebar dialogue interaction module further includes: The context sampling unit is configured to automatically capture the selected content when the user selects text, or extract the page title and meta description when no text is selected. The privacy control unit provides users with configurable privacy policies to control whether to include URLs, select text, or page summaries; The sidebar injection unit uses lightweight DOM manipulation to embed the dialog interface without interfering with the original page functionality; The streaming response unit supports progressive presentation of AI responses via server-sent events or the WebSocket protocol.

[0017] Preferably, the multi-model routing decision module implements a local priority routing strategy, including: The model availability detection unit periodically checks the status of locally deployed model services; The priority configuration unit sets the routing priority sequence based on model performance, cost, and privacy requirements; The degradation processing unit automatically switches to the next priority model when a high-priority model times out or fails to respond. The capability matching unit selects the most suitable model type based on the request type.

[0018] Preferably, the system further includes a document structure rendering module for implementation in a browser extension environment: A multi-format parser that supports client-side parsing and rendering of Markdown, PDF, and Office documents; The structure extractor identifies and extracts structured elements such as headings, paragraphs, tables, and lists from a document; The knowledge linker establishes bidirectional links between document content and knowledge entries, and supports the creation of knowledge entries from documents. A lightweight rendering engine that optimizes rendering performance and memory usage in resource-constrained environments.

[0019] Preferably, the knowledge base dialogue closed-loop module implements a session-level knowledge binding mechanism, including: The knowledge binding unit uniquely associates a specified knowledge base with the current dialogue session, forming a session-level knowledge context. The item retrieval unit automatically retrieves relevant items and source document summaries from the associated knowledge base when a user asks a question; The source tracing tagging unit embeds clickable knowledge entry reference tags in the AI-generated answers; The closed-loop interactive unit supports one-click jump from the dialogue content to the original knowledge entry or source document preview.

[0020] Preferably, the unified search aggregation module enables cross-object search linkage, including: Heterogeneous data indexing units establish a unified index structure for people, organizations, and documents; The category aggregation unit groups search results by object type and displays the number of results for each category. The preview unit allows users to directly preview document content or key information about individuals / organizations in the search results list. The cross-object navigation unit supports one-click navigation from the preview interface to the full details page or initiating a conversation based on the object.

[0021] Preferably, the local storage management module implements a privacy-first data management strategy, including: The local priority storage unit stores session history, configuration parameters, and knowledge entries in IndexedDB or browser extended storage by default; The data export control unit provides fine-grained access control, allowing users to set which data types can be sent to remote servers; Offline work units support basic dialogue and knowledge retrieval using local models without a network connection; The synchronization management unit synchronizes selected data to the cloud only when explicitly authorized by the user, while retaining a local copy.

[0022] A computing device includes a memory and a processor, the memory storing a computer program, the processor executing the computer program to implement the method.

[0023] Compared with the prior art, the beneficial effects of the present invention are as follows: By injecting the sidebar interface into the browser in a low-intrusive manner, users can obtain AI assistance without leaving the current webpage, greatly improving the ease of use; Automatically collect webpage context information to make the AI ​​model's answers more accurate and targeted; Based on a local-first routing strategy, it provides a flexible model selection scheme while ensuring privacy; The closed-loop knowledge interaction mechanism ensures the consistency and traceability of knowledge; The unified cross-object search function significantly improves the efficiency of information retrieval; Local-first storage strategies and fine-grained data control permissions maximize user privacy protection. Attached Figure Description

[0024] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the accompanying drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the structures shown in these drawings without creative effort.

[0025] Figure 1 This is a flowchart of the interaction method of the present invention; Figure 2 This is a flowchart of the knowledge closed-loop interaction method of the present invention; Figure 3 This is a flowchart of the cross-object unified search method of the present invention; Figure 4 This is a system block diagram of the interactive system of the present invention. Detailed Implementation

[0026] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0027] Example 1 like Figure 1 As shown, a multi-model intelligent interaction method based on browser extensions is implemented in a browser extension environment. The specific steps include: In response to a user activating the intelligent assistance function in their browser, a sidebar dialog interface is injected with minimal intrusion into any currently viewed webpage. In this embodiment, the user can activate the intelligent assistance function by clicking the extension icon in the browser toolbar, using a preset shortcut key combination, or right-clicking on the webpage and selecting a specific menu item. In response to this activation, the browser extension's content script is executed. This script dynamically injects a sidebar container into the main element of the current webpage through lightweight document object model operations. This sidebar is typically fixed to the right or left edge of the browser viewport, employing a semi-transparent, collapsible, or slide-in / slide-out design. Its style is encapsulated through a shadow document object model or strict Cascading Style Sheets scope to ensure that its style does not pollute the original webpage, and the original webpage's style does not affect the sidebar's presentation, thus achieving true "low intrusion." The sidebar contains a dialog input box, a message display area, and functional tabs, such as interactive elements like dialogue, search, knowledge base, and writing. The system automatically samples the context information of the current webpage. This context information includes at least one of the following: webpage title, user-selected text, or webpage URL. Specifically, it monitors the browser's text selection event to detect in real time whether the user has selected text on the webpage. When the event is triggered and the selected text is not empty, the selected text content is automatically captured. Regardless of whether text is selected, the system extracts the current webpage's metadata, including at least the webpage title, webpage address, and webpage meta description. It can also further extract key elements such as the main page title. The sampling process is linked to user-configurable privacy policies. Specifically, users can choose in extended settings not to send the URL or only send the page title when text is selected. The privacy control unit filters or anonymizes the sampled raw context information based on user settings to form the final context information included in the conversation request.

[0028] In this embodiment, the original sampled data set is assumed to include fields such as title, selected text, URL, and meta description; Suppose that the user privacy policy set includes Boolean flags such as allowing sending URLs and allowing sending selected text; The final context information is equal to the subset of the original sampled data filtered according to the privacy policy Boolean flags; In the step of automatically sampling the context information of the current webpage, the original sampled information is filtered according to the user's preset privacy policy, and a weighted evaluation method is used to determine the combination and priority of the final context information to be included in the request. The weighted evaluation method can calculate the comprehensive weight of the importance of the context information using the following formula: in, , , , These are the weighting coefficients, and ; , , , These represent the preset original weight values ​​for four types of information: webpage title, user-selected text, webpage URL, and webpage metadata. This evaluation helps to prioritize and retain high-weight information when there is a lot of contextual information.

[0029] User requests containing context information are sent to the corresponding local or cloud-based AI model endpoints according to a local-first routing strategy to obtain streaming AI responses. When in use, after the user enters a question in the front-end sidebar, the system constructs a structured request, which includes at least: the user's question, the obtained context information, and optional session history. Subsequently, the multi-model routing decision module decides which intelligent model endpoint to send the request to based on the local-first strategy. Specifically, in the step of sending user requests based on a local-first routing strategy, a routing scoring algorithm based on multi-objective decision-making is used to select the optimal model endpoint. This scoring algorithm comprehensively considers response time, call cost, and privacy protection level, and the formula is: in, To estimate response time, For the maximum acceptable response time, For the cost of calling, To the maximum acceptable cost, Rate your privacy protection , , These are weighting coefficients for response time, cost, and privacy, which can be configured according to user preferences. The system calculates the Score_model for each candidate endpoint and prioritizes sending requests to the endpoint with the highest score.

[0030] It receives streaming AI responses and displays them in the interactive interface of the sidebar. During the display, the response status is shown, such as start, in progress, end, and error, and corresponding visual feedback is provided in the interface, such as a loading animation. The complete response content is saved to the local storage management module along with the session history after the session ends.

[0031] Furthermore, local-first routing strategies include: The local model endpoint availability detection unit maintains a pre-configured list of local model endpoints, which can be sorted by performance, preference, or cost. Specifically, when a request is received, the unit will send a lightweight health check request to the first endpoint in the list and set a short timeout. If a successful response is received within the timeout period, the local endpoint is determined to be available. When a usable model endpoint is detected in the user's local deployment, the user's request is routed to the local model endpoint first, and the user waits for the streamed response to be returned, while a request timeout is set. When the local model endpoint is unavailable or the response times out, the user request is automatically downgraded and routed to a preset cloud-compatible endpoint. The detection and routing logic of the cloud endpoint is similar to that of the local endpoint, but it usually has a higher success rate and better stability. This downgrade process is transparent to the user.

[0032] Furthermore, such as Figure 3 As shown, it also includes knowledge closed-loop interaction, and the specific steps include: Upon receiving a user's selection instruction for a target knowledge base, the system creates or switches to a dedicated dialogue session bound to that target knowledge base. Specifically, users can select a target knowledge base from a list of local or cloud-based knowledge bases in the knowledge base management area of ​​the sidebar. The knowledge binding unit creates a new dialogue session or establishes a unique association between the currently active session and the target knowledge base. This association is session-level, meaning that in all subsequent question-and-answer sessions within that session, relevant knowledge will be retrieved from that target knowledge base by default. Based on the user's input question, the system retrieves relevant knowledge entries and associated source document summaries from the target knowledge base. When the user enters a question in this session, the entry retrieval unit uses that question as the query term to search the index of the target knowledge base. The search results return a list of knowledge entries sorted by relevance. Each entry may contain a title, a content fragment, a unique identifier, and a summary or path to its source document. Based on the retrieved knowledge entries, prompt words are constructed and sent to the AI ​​model endpoint. When in use, the system will construct the prompt words from the top few most relevant knowledge entries according to a preset template. When displaying the answer returned by the model, the system provides a link to the relevant knowledge entry or source document. The source tracing tagging unit identifies sections in the intelligently returned answer text that reference specific knowledge entries. This can be achieved either by the model returning reference tags during output or by performing similarity matching between the answer and the entry content later, rendering them as clickable hyperlinks or underlined tags. When a user clicks on this tag, the closed-loop interaction unit triggers a pop-up panel of detailed information about the knowledge entry in the sidebar, or directly opens the associated source document in a new tab, enabling quick answer verification and knowledge tracing.

[0033] Furthermore, such as Figure 3 As shown, it also includes a unified cross-object search, with specific steps including: It receives search keywords input by the user, that is, the user enters keywords in the input box of the search tab in the sidebar; Based on search keywords, the system performs parallel searches of the personnel database, organization database, and document database. Specifically, after the unified search aggregation module receives the keywords, the heterogeneous data indexing unit simultaneously initiates asynchronous search requests to the three heterogeneous data sources, including: performing a query on the personnel database; performing a query on the organization database; and performing a query on the document database. These data sources may be remote application programming interfaces (APIs) or extensions of locally built indexes, such as offline indexes of recently accessed documents. In the results interface, the three categories of search results—personnel, organizations, and documents—are categorized and aggregated separately, and the quantity statistics of each category are displayed. This enables the parallel acquisition of results for classification and aggregation. The search results display area in the sidebar is usually presented as three independent cards or sections. In response to a user's action on any specific result, the system will display a preview of the result's details or redirect directly to its corresponding full information page. In actual use, the preview unit listens for user interaction events with an item in the result list. For document results, hovering may trigger a pop-up displaying a thumbnail of the document or a summary of the first few lines of text; for personnel results, it may display a summary of name, position, and contact information. Clicking on a result item will trigger navigation across objects: for documents, it may open the document in an embedded view in the sidebar or in a new tab; for personnel or organizations, it may redirect to the internal address book details page or initiate a new intelligent dialogue with that object as the context.

[0034] Furthermore, the method also includes parameterized writing, with specific steps including: It provides a writing parameter configuration interface, which allows users to select at least two parameters from output length, text format, tone style and language type. Based on the user-defined topic and selected parameters, the system invokes an AI model endpoint to generate text content, which is then previewed in real-time on the interface. To use the system, the user enters a writing topic and clicks "Generate." The system constructs a highly structured prompt based on the topic and parameter set, and then invokes the intelligent model through a routing strategy. The generated text content is displayed in real-time streaming in the writing preview area. The user can further edit or request a rewrite in the preview area.

[0035] Example 2 like Figure 4As shown, a browser extension-based intelligent assistance system for implementing the method is characterized by comprising: deployed in a browser extension environment. The sidebar dialogue interaction module is used to inject a sidebar interface into any webpage and automatically obtain the title, selected text, URL and metadata of the current webpage as the dialogue context through the webpage context sampling component. The multi-model routing decision module is used to detect the availability of local model services in sequence according to the preset local priority strategy, and degrade to cloud models when local models are unavailable. The knowledge base dialogue closed-loop module is used to bind knowledge items to dialogue sessions at the session level, enabling item association and source tracing functions; The unified search aggregation module is used to perform unified searches on heterogeneous objects such as people, organizations, and documents, aggregate results by category, and provide previews and interactive navigation. The local storage management module is used to store session history, user configurations, and knowledge entries in the browser's local storage by default, reducing data transmission outside the browser. Among them, the sidebar dialogue interaction module, multi-model routing decision module, knowledge base dialogue closed-loop module, unified search aggregation module and local storage management module are integrated into a single browser extension to achieve low-latency and privacy-first intelligent assistance functions.

[0036] Furthermore, the sidebar dialogue interaction module includes: The context sampling unit is configured to automatically capture the selected content when the user selects text, or extract the page title and meta description when no text is selected. The privacy control unit provides users with configurable privacy policies to control whether to include URLs, select text, or page summaries; The sidebar injection unit uses lightweight DOM manipulation to embed the dialog interface without interfering with the original page functionality; The streaming response unit supports progressive presentation of AI responses via server-sent events or the WebSocket protocol.

[0037] Furthermore, the multi-model routing decision module implements a local priority routing strategy, including: The model availability detection unit periodically checks the status of locally deployed model services; The priority configuration unit sets the routing priority sequence based on model performance, cost, and privacy requirements; The degradation processing unit automatically switches to the next priority model when a high-priority model times out or fails to respond. The capability matching unit selects the most suitable model type based on the request type, such as determining the request type through simple keyword matching or a more complex intent classification model, and matches it with the capability descriptions registered by each endpoint to assist the priority configuration unit in making better route selections.

[0038] Furthermore, the system also includes a document structure rendering module for implementation in browser extension environments: A multi-format parser that supports client-side parsing and rendering of Markdown, PDF, and Office documents; The structure extractor identifies and extracts structured elements such as headings, paragraphs, tables, and lists from a document; The knowledge linker establishes bidirectional links between document content and knowledge entries, and supports the creation of knowledge entries from documents. A lightweight rendering engine that optimizes rendering performance and memory usage in resource-constrained environments.

[0039] Furthermore, the knowledge base dialogue closed-loop module implements a session-level knowledge binding mechanism, including: The knowledge binding unit uniquely associates a specified knowledge base with the current dialogue session, forming a session-level knowledge context. Each session object has a knowledge base identifier attribute that points to the knowledge base it is bound to. This unit handles binding, unbinding, and switching operations. The item retrieval unit automatically retrieves relevant items and source document summaries from the associated knowledge base when a user asks a question; The source tracing tagging unit embeds clickable knowledge entry reference tags in the AI-generated answers; The closed-loop interactive unit supports one-click jump from the dialogue content to the original knowledge entry or source document preview.

[0040] Furthermore, the unified search aggregation module enables cross-object search linkage, including: Heterogeneous data indexing units establish a unified index structure for people, organizations, and documents; The category aggregation unit groups search results by object type and displays the number of results for each category. The preview unit allows users to directly preview document content or key information about individuals / organizations in the search results list. The cross-object navigation unit supports one-click navigation from the preview interface to the full details page or initiating a conversation based on the object.

[0041] Furthermore, the local storage management module implements a privacy-first data management strategy, including: The local priority storage unit stores session history, configuration parameters, and knowledge entries in IndexedDB or browser extended storage by default; The data export control unit provides fine-grained access control, allowing users to set which data types can be sent to remote servers; Offline work units support basic dialogue and knowledge retrieval using local models without a network connection; The synchronization management unit synchronizes selected data to the cloud only when explicitly authorized by the user, while retaining a local copy.

[0042] In this embodiment, the modules in the browser extension-based intelligent assistance system work collaboratively through the message passing mechanism within the browser extension. Specifically, user input in the sidebar is sent to the multi-model routing decision module in the background script via runtime messages for routing decisions. After receiving the intelligent response, the multi-model routing decision module sends streaming data back to the content script of the specific webpage via tab messages, which is then rendered by the streaming response unit of the sidebar dialogue interaction module. All modules are integrated into a unified browser extension package, which can be installed, updated, and managed through the browser's extension management interface.

[0043] A computing device for deploying and running the aforementioned browser extension, or as a local model endpoint server, includes a memory and a processor. The memory stores a computer program, and the processor executes methods implemented when executing the computer program. The number of processors is one or more, and they are used to execute program instructions. The memory may include high-speed random access memory or may also include non-volatile memory.

[0044] Example 3 A computing device, further comprising: A network interface is used to communicate with the Internet or a local area network, such as to receive requests for browser extensions or access cloud-based intelligent services.

[0045] Input / output interfaces are used to connect peripherals such as monitors, keyboards, and mice.

[0046] The bus system is used to couple the above components.

[0047] The memory stores a computer program that, when executed by the processor, implements the multi-model intelligent interaction method based on a browser extension as described in Embodiment 1. Specifically, when the computing device acts as a user terminal, its browser installs and runs the extension, and the processor executes the extension code to implement the method steps; when the computing device acts as a local model server, it runs an intelligent model service, and the processor executes model inference code to respond to requests from the extension.

[0048] To more clearly illustrate the solution of this invention, the following description is based on a specific application scenario: A user, a researcher, is reading an online academic article about neural network optimization algorithms in his browser.

[0049] The user selects a descriptive text about an optimizer in an article and then presses a shortcut key to activate the smart assistance sidebar.

[0050] Once the sidebar appears, the system automatically uses the webpage title and the selected optimizer text as context. Users can directly ask questions in the sidebar input box: "Please compare the advantages and disadvantages of this optimizer with another optimizer." The multi-model routing decision module detected that the user had deployed an open-source model locally and that it was in a healthy state. Therefore, it sent a request containing the issue and context to the local model service.

[0051] The local model generates streaming answers, and the comparison content is displayed word by word in the sidebar.

[0052] The user found the answer valuable and wanted to save it to their personal machine learning notes knowledge base. They switched to the Knowledge Base tab, selected Machine Learning Notes, and clicked the "Save to Knowledge Base" button next to the current dialogue. The Knowledge Base dialogue loop module created a new knowledge entry for the current question-and-answer pair and associated it with the source document.

[0053] A few days later, while reading another paper, the user had a question about the adaptive learning rate mentioned in it. He activated the sidebar, first switching to the session linked to the machine learning notes knowledge base, and then asked, "What is an adaptive learning rate?" The system automatically retrieved relevant knowledge entries from the machine learning notes library, matching them with previously saved entries. The intelligent model generated an explanation based on this entry and marked the citation in the answer. The user clicked the citation mark, and the sidebar expanded to display the detailed content of the knowledge entry, allowing for a one-click jump back to the original academic article for review.

[0054] Throughout the process, all conversation history and knowledge entries are stored in the browser's local index database by default. Users only need to manually enable cloud synchronization when cross-device synchronization is required.

[0055] Through the above embodiments, the solution provided by the present invention achieves deep, seamless, secure, and efficient integration of intelligent assistance functions in browser scenarios, effectively solving many problems.

[0056] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A multi-model intelligent interaction method based on browser extensions, characterized in that, The method is executed in a browser extension environment, and the specific steps include: In response to the user activating the intelligent assistance function in the browser, a sidebar dialog interface is injected in a low-intrusive manner into any webpage currently being viewed. Automatically sample the context information of the current webpage, wherein the context information includes at least one of the following: webpage title, user-selected text, or webpage URL; User requests containing the aforementioned context information are sent to the corresponding local or cloud-based AI model endpoints according to a local-first routing strategy to obtain streaming AI responses. Receive the streaming AI response and display it in the interactive interface of the sidebar.

2. The multi-model intelligent interaction method based on browser extensions according to claim 1, characterized in that, The local-first routing strategy includes: When a usable model endpoint is detected on the user's local machine, the user's request will be routed to the local model endpoint first. When the local model endpoint is unavailable or the response times out, the user request is automatically downgraded and routed to a preset cloud-compatible endpoint.

3. The multi-model intelligent interaction method based on browser extensions according to claim 1, characterized in that, It also includes knowledge closed-loop interaction, the specific steps of which include: Receive user's selection instruction for the target knowledge base, and create or switch to a dedicated dialogue session bound to that target knowledge base; Based on the question input by the user, relevant knowledge entries and associated source document summaries are retrieved from the target knowledge base; Based on the retrieved knowledge entries, construct prompts and send them to the AI ​​model endpoint; When displaying the answers returned by the model, the association provides a reference point to the knowledge entry or source document on which it is based.

4. The multi-model intelligent interaction method based on browser extensions according to claim 1, characterized in that, It also includes unified cross-object search, with specific steps including: Receive search keywords input by the user; Based on the search keywords, the personnel database, organization database, and document database are searched in parallel; In the results interface, the search results for people, organizations, and documents are categorized and aggregated separately, and the quantity statistics for each category are displayed. In response to a user's action on any specific result, the system will display a preview of the result's details or redirect the user directly to its corresponding full information page.

5. The multi-model intelligent interaction method based on browser extensions according to claim 1, characterized in that, The method also includes parameterized writing, the specific steps of which are: It provides a writing parameter configuration interface, which allows users to select at least two parameters from output length, text format, tone style and language type. Based on the user-defined theme and selected parameters, the system calls an AI model endpoint to generate text content, which is then previewed in real time on the interface.

6. A browser-based intelligent assistance system for implementing the method of any one of claims 1-5, characterized in that, Including those deployed in browser extension environments: The sidebar dialogue interaction module is used to inject a sidebar interface into any webpage and automatically obtain the title, selected text, URL and metadata of the current webpage as the dialogue context through the webpage context sampling component. The multi-model routing decision module is used to detect the availability of local model services in sequence according to the preset local priority strategy, and degrade to cloud models when local models are unavailable. The knowledge base dialogue closed-loop module is used to bind knowledge items to dialogue sessions at the session level, enabling item association and source tracing functions; The unified search aggregation module is used to perform unified searches on heterogeneous objects such as people, organizations, and documents, aggregate results by category, and provide previews and interactive navigation. The local storage management module is used to store session history, user configurations, and knowledge entries in the browser's local storage by default, reducing data transmission outside the browser. The sidebar dialogue interaction module, multi-model routing decision module, knowledge base dialogue closed-loop module, unified search aggregation module, and local storage management module are integrated into a single browser extension to achieve low-latency and privacy-first intelligent assistance functions.

7. The intelligent assistance system based on browser extensions according to claim 6, characterized in that, The sidebar dialogue interaction module further includes: The context sampling unit is configured to automatically capture the selected content when the user selects text, or extract the page title and meta description when no text is selected. The privacy control unit provides users with configurable privacy policies to control whether to include URLs, select text, or page summaries; The sidebar injection unit uses lightweight DOM manipulation to embed the dialog interface without interfering with the original page functionality; The streaming response unit supports progressive presentation of AI responses via server-sent events or the WebSocket protocol.

8. The intelligent assistance system based on browser extensions according to claim 6, characterized in that, The multi-model routing decision module implements a local priority routing strategy, including: The model availability detection unit periodically checks the status of locally deployed model services; The priority configuration unit sets the routing priority sequence based on model performance, cost, and privacy requirements; The degradation processing unit automatically switches to the next priority model when a high-priority model times out or fails to respond. The capability matching unit selects the most suitable model type based on the request type.

9. The intelligent assistance system based on browser extensions according to claim 6, characterized in that, The system also includes a document structure rendering module for implementation in a browser extension environment: A multi-format parser that supports client-side parsing and rendering of Markdown, PDF, and Office documents; The structure extractor identifies and extracts structured elements such as headings, paragraphs, tables, and lists from a document; The knowledge linker establishes bidirectional links between document content and knowledge entries, and supports the creation of knowledge entries from documents. A lightweight rendering engine that optimizes rendering performance and memory usage in resource-constrained environments.

10. The intelligent assistance system based on browser extensions according to claim 6, characterized in that, The knowledge base dialogue closed-loop module is used to implement a session-level knowledge binding mechanism, including: The knowledge binding unit uniquely associates a specified knowledge base with the current dialogue session, forming a session-level knowledge context. The item retrieval unit automatically retrieves relevant items and source document summaries from the associated knowledge base when a user asks a question; The source tracing tagging unit embeds clickable knowledge entry reference tags in the AI-generated answers; The closed-loop interactive unit supports one-click jump from the dialogue content to the original knowledge entry or source document preview.

11. The intelligent assistance system based on browser extensions according to claim 6, characterized in that, The unified search aggregation module is used to enable cross-object search linkage, including: Heterogeneous data indexing units establish a unified index structure for people, organizations, and documents; The category aggregation unit groups search results by object type and displays the number of results for each category; The preview unit allows users to directly preview document content or key information about individuals / organizations in the search results list. The cross-object navigation unit supports one-click navigation from the preview interface to the full details page or initiating a conversation based on the object.

12. The intelligent assistance system based on browser extensions according to claim 6, characterized in that, The local storage management module is used to implement a privacy-first data management strategy, including: The local priority storage unit stores session history, configuration parameters, and knowledge entries in IndexedDB or browser extended storage by default; The data export control unit provides fine-grained access control, allowing users to set which data types can be sent to remote servers; Offline work units support basic dialogue and knowledge retrieval using local models without a network connection; The synchronization management unit synchronizes selected data to the cloud only when explicitly authorized by the user, while retaining a local copy.

13. A computing device, comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor executes the computer program to implement the method of any one of claims 1 to 5.

Citation Information

Patent Citations

  • Browser sidebar intelligent assistant interaction method and system

    CN120949973A