Knowledge service plug-in integration method and system based on plug-in and storage medium
By embedding JavaScript plug-in in the business system, realizing instant Q&A knowledge retrieval, solving the problem that existing technology cannot realize instant knowledge retrieval in the interface, improving user experience and work efficiency, and ensuring the security and personalized feedback of the query process.
Patent Information
- Application Number
- CN202411950039.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-27
- Publication Date
- 2025-04-22
AI Technical Summary
The existing technology cannot realize instant retrieval and accurate feedback of knowledge in the interface without interfering with normal workflows, and cannot meet users' needs for instant answers and in-depth information exploration.
Design and develop integrated JavaScript plug-ins, which are directly embedded in the business system interface, and realize the instant Q&A knowledge retrieval function. By building a knowledge base with dynamic update mechanism, combining intelligent knowledge middle platform system, natural language processing and OAuth 2.0 standard certification are adopted to ensure the security and personalized feedback of the query process.
Users can quickly query and understand the relevant content of the interface without leaving the current interface, which improves work efficiency and satisfaction, ensures the security and personalized feedback of the query process, and promotes the smoothness of business processes and the intelligent upgrade of the digital office environment.
Smart Images

Figure CN119861984A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, specifically to technical fields such as security authentication, data communication, data retrieval, etc., and in particular to a plug-in-based knowledge service plug-in integration method. Background Art
[0002] In the era of rapid development of information technology, the diversity and complexity of business systems are increasing day by day, and the difficulty of understanding information faced by users during operation is also increasing. Existing interface assistance technologies, such as fixed help documents or external links to separate knowledge bases, are designed to improve user experience, but their limitations are gradually becoming apparent. Fixed text descriptions often cannot keep up with the speed of system iterations, and the information is outdated and has limited coverage, which cannot meet the diverse query needs of users. Relying on external systems to obtain additional information forces users to constantly switch between the main interface and the help system, interrupting the continuity of operations, reducing work efficiency, and greatly compromising user experience.
[0003] Especially in knowledge-intensive work environments, users have an increasing demand for instant answers and in-depth information exploration. Traditional auxiliary methods are inadequate and cannot provide efficient and convenient solutions. Therefore, how to achieve instant retrieval and accurate feedback of knowledge within the interface without interfering with normal work processes has become a technical problem that needs to be solved urgently. In this context, it is particularly urgent and important to develop an innovative tool that can be seamlessly integrated into the business system, support instant question-and-answer queries, and allow non-technical personnel to easily maintain and update. Summary of the invention
[0004] Technical problems solved by the present invention: In view of the growing demand of users for instant answers and in-depth information exploration in the prior art, traditional auxiliary methods are stretched to the limit and cannot provide efficient and convenient solutions. In terms of improving user interaction experience and information acquisition efficiency, the present invention aims to provide a plug-in-based knowledge service plug-in integration method, design and develop an integrated JavaScript plug-in, which can be directly embedded in various business system interfaces to achieve instant question-and-answer knowledge retrieval functions. Users can quickly query and understand interface-related content without leaving the current interface, which greatly improves work efficiency and satisfaction. At the same time, the present invention integrates user identity recognition logic, combined with the intelligent knowledge middle-end system independently developed by the institute, can ensure the security and personalized feedback of the query process, and further enhance the user experience. It promotes the smoothness of business processes and the intelligent upgrade of the digital office environment.
[0005] Technical solution of the present invention
[0006] A plug-in-based knowledge service plug-in integration method comprises the following steps:
[0007] Step 1: Build a knowledge base with a dynamic update mechanism;
[0008] Step 2: Develop JavaScript plugin;
[0009] Step 3: Integrate the developed JavaScript plug-in into the front-end framework of the target business system;
[0010] Step 4: Ajax request and data processing;
[0011] Step 5: User authentication;
[0012] Step 6: Knowledge services.
[0013] Further, step 1 specifically includes the following steps:
[0014] Step 1.1 Collect and organize diversified business guides and information documents;
[0015] Step 1.2: Use targeted data processing methods to process documents of different formats and types;
[0016] Step 1.3: Conduct deep data processing on the structured or unstructured index fields in the data document processed in step 1.2, and perform denoising operations to eliminate redundant information and interference data in the document;
[0017] Step 1.4 classifies and integrates the information processed in step 1.3, converts it into highly structured knowledge items, and constructs a knowledge base with a dynamic update mechanism.
[0018] Furthermore, step 2 specifically involves the front-end technician using jQuery to develop a lightweight, highly compatible JavaScript plug-in.
[0019] Further, the JavaScript plug-in includes:
[0020] Develop user interface components, that is, use HTML5 and CSS3 to build an intuitive, friendly and easy-to-operate user interaction interface, including: (1) designing a question-and-answer input box with an adaptive layout, automatically adjusting the style and size according to different screen sizes and device types to ensure user input convenience; (2) setting up a clear and concise query result display area, using dynamic loading method, which can be flexibly presented according to the amount and type of query result data.
[0021] Develop an instant messaging logic module, that is, build an efficient and real-time information interaction channel based on the WebSocket protocol: when a user enters a question in the question-and-answer input box interface, the user input event is captured immediately, the question information is quickly encapsulated as request data that complies with the Ajax specification, and the data is sent to the back-end intelligent knowledge center through the established WebSocket connection; at the same time, the response data returned by the back-end is monitored in real time. Once the processing result is received, the interface update event is immediately triggered, and the result data is accurately displayed in the specified area of the user interface;
[0022] Develop a security authentication module, which deeply integrates the OAuth 2.0 standard authentication framework. At the moment the user initiates a query request, a unique and time-sensitive user authentication token is generated through a secure encryption algorithm. This token contains the user's basic identity information and integrates a timestamp and a random number. During the Ajax request construction process, the token is embedded in the request header information. After receiving the request, the back-end intelligent knowledge center decrypts, verifies and parses the token according to the strict verification process of the OAuth 2.0 standard to confirm the legitimacy of the user's identity and the scope of authority.
[0023] Furthermore, step 3 specifically includes: integrating the developed JS plug-in into the front-end framework of the target business system, following the integration specification, that is, introducing the JS plug-in script file between tags;
[0024] During the page loading process, when the browser parses the plug-in reference in the tag, it loads the plug-in-related JavaScript code and CSS style files into the memory according to the predetermined loading order and dependency relationship;
[0025] During the initialization of the plug-in, the page structure and DOM elements of the target business system are detected, and an interactive icon is automatically generated in the lower right corner of the interface. This interactive icon adopts a responsive design, which can present different visual effects and interactive feedback according to the user's mouse operation, and supports users to freely adjust the icon position by dragging the mouse.
[0026] Further, step 4: Ajax request and data processing: After the user enters the question in the question and answer input box interface, the instant messaging logic module responds quickly and builds a request based on the Ajax function of jQuery, which specifically includes the following steps:
[0027] Step 4.1 collects the question text information input by the user, and obtains the current user's authentication token through the security authentication module, and encapsulates the question information and the authentication token according to the predefined JSON data format to form a complete Ajax request data body;
[0028] Step 4.2 uses the asynchronous characteristics of Ajax to send a POST request to the specified back-end intelligent knowledge middle-end service interface. After receiving the request, the back-end verifies the user's authority based on the authentication token in the request. If the verification passes, the data processing process begins; otherwise, the corresponding authority error message is returned to the front-end plug-in. During the data processing process, natural language processing is used to deeply analyze the question text, including lexical analysis, syntactic analysis, and semantic understanding, to extract the key semantic features and intent information of the question.
[0029] Furthermore, step 5 is to integrate a rigorous user authentication mechanism. The user authentication token embedded in each Ajax request is processed by the backend according to the OAuth 2.0 standard authentication process, which specifically includes the following steps:
[0030] Step 5.1: Perform integrity check on the token to check whether there is any data tampering or damage; if the integrity check passes, the token is further decrypted to obtain the user identity and permission information;
[0031] Step 5.2: Based on the user role information, the backend system queries the detailed permission list corresponding to the user from the permission management database and compares and verifies it with the currently requested operation;
[0032] Step 5.3 The backend records the user's query request information, performs correlation analysis with historical query records, and builds a user query behavior profile.
[0033] Further, step 6 is specifically: after the backend receives the Ajax request and completes user identity authentication and question analysis, it enters the core processing link of the knowledge service, including the following steps:
[0034] Step 6.1: Use natural language processing methods and intelligent algorithm models to quickly match the parsed questions with knowledge items in the knowledge base;
[0035] Step 6.2 uses a similarity calculation algorithm based on a vector space model to convert the text of the question and the knowledge item into a vector representation, and by calculating the cosine similarity index between the vectors, selects several knowledge items with the highest semantic similarity to the question as candidate results;
[0036] Step 6.3 sorts and screens the candidate results based on the user query behavior profile constructed during the user identity authentication process and the popularity and quality factors of the knowledge items in the knowledge base to determine the final query result;
[0037] Step 6.4 encapsulates the query results in JSON format, including the knowledge content body, related reference links, and recommended reading material information, and returns them to the front end through Ajax response;
[0038] Step 6.5 After receiving the response, the front end uses the JSON parsing library of the JavaScript plug-in to parse the data, and presents the query results to the user according to the predetermined display template and style through the dynamic display function of the user interface component;
[0039] Step 6.6 The backend uses association rule mining algorithms based on user identity information and query history to mine similar questions related to the current query question from the knowledge base, and returns them to the front-end plug-in for display, thereby realizing efficient, accurate and personalized knowledge service functions.
[0040] A plug-in-based knowledge service plug-in integration system, the system comprising:
[0041] Knowledge base construction unit: configured to construct a knowledge base with a dynamic update mechanism;
[0042] Plugin development unit: configured to develop JavaScript plugins;
[0043] Fusion unit: configured to integrate the developed JavaScript plug-in into the front-end framework of the target business system;
[0044] Ajax request and data processing unit: configured so that after the user enters a question in the question-answer input box interface, the instant messaging logic module responds quickly and builds a request based on jQuery's Ajax function;
[0045] Authentication unit: It is configured to integrate a rigorous user authentication mechanism. The user authentication token is embedded in each Ajax request, and the backend processes it according to the OAuth 2.0 standard authentication process.
[0046] Knowledge service unit: It is configured to enter the core processing link of knowledge service after the backend receives the Ajax request and completes user identity authentication and problem analysis.
[0047] A computer storage medium stores computer executable instructions for executing the aforementioned plug-in-based knowledge service plug-in integration method.
[0048] Beneficial Effects
[0049] The present invention provides a plug-in-based knowledge service plug-in integration method, designs and develops an integrated JavaScript plug-in, which can be directly embedded in various business system interfaces to realize instant question-and-answer knowledge retrieval functions. Users can quickly query and understand interface-related content without leaving the current interface, which greatly improves work efficiency and satisfaction. At the same time, the present invention integrates user identity recognition logic, combined with the intelligent knowledge middle-end system independently developed by the institute, can ensure the security and personalized feedback of the query process, and further enhance the user experience. It promotes the smoothness of business processes and the intelligent upgrade of the digital office environment. BRIEF DESCRIPTION OF THE DRAWINGS
[0050] Figure 1 is a method flow chart of the method of the present invention;
[0051] Figure 2 It is the data flow diagram of the present invention;
[0052] Figure 3 It is a question-and-answer icon diagram of the present invention that is not expanded;
[0053] Figure 4 It is a question-and-answer interface diagram developed by the present invention. DETAILED DESCRIPTION
[0054] The features and illustrative embodiments of various aspects of the present invention will be described in detail below. In the detailed description below, many specific details are proposed to provide a comprehensive understanding of the present invention. However, it is obvious to those skilled in the art that the present invention can be implemented without the need for some of these specific details. The following description of the embodiments is only to provide a better understanding of the present invention by illustrating examples of the present invention. The present invention is by no means limited to any specific settings and methods proposed below, but covers any improvements, replacements and modifications of structures, methods, devices without departing from the spirit of the present invention. In the accompanying drawings and the following description, known structures and technologies are not shown to avoid unnecessary ambiguity in the present invention.
[0055] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments can be combined with each other, and the embodiments can refer to and quote each other. The present invention will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.
[0056] An embodiment of the present invention provides a plug-in-based knowledge service plug-in integration method, comprising the following steps:
[0057] Step 1: Knowledge base construction
[0058] Collect and organize diversified business guides and data documents. These documents come from a wide range of sources, covering data statistics reports, operation manuals, technical specifications, and various images, charts, and other materials in specific fields. Targeted data processing technologies are used for documents of different formats and types. For text documents in formats such as PDF and Word, the text parsing engine built into the intelligent knowledge platform is used to parse according to the document structure and semantic rules to extract key information and metadata; for image documents, advanced OCR (optical character recognition) technology is used to accurately extract text information in the image and convert it into an editable text format. After that, with the help of the powerful automated processing capabilities of the intelligent knowledge platform, based on the business guides and data document characteristics provided by users, deep data processing is carried out on their structured or unstructured index fields, and denoising operations are performed to eliminate redundant information and interference data in the documents. Then, through intelligent classification algorithms, the processed information is classified and integrated according to multi-dimensional standards such as knowledge fields, topics, and business processes, and finally converted into highly structured knowledge entries, building a knowledge base with a dynamic update mechanism to adapt to the continuous evolution and changes of business knowledge.
[0059] Step 2: JS plugin development
[0060] Develop lightweight, highly compatible JavaScript plug-ins. Front-end technicians use jQuery to write plug-ins, which have multiple core modules:
[0061] User interface components: Use HTML5 and CSS3 technologies to build an intuitive, friendly and easy-to-operate user interaction interface. Design a question-and-answer input box with an adaptive layout, which can automatically adjust the style and size according to different screen sizes and device types to ensure user input convenience; set up a clear and concise query result display area, and use dynamic loading technology to flexibly present the query result data according to the amount and type, such as displaying knowledge content in various forms such as lists, cards, and charts, so that users can quickly browse and understand.
[0062] Instant messaging logic: Build an efficient and real-time information interaction channel based on the WebSocket protocol. When a user enters a question in the Q&A interface, the user input event is captured immediately, the question information is quickly encapsulated as request data that complies with the Ajax specification, and the data is sent to the back-end intelligent knowledge center through the established WebSocket connection; at the same time, the response data returned by the back-end is monitored in real time. Once the processing result is received, the interface update event is immediately triggered, and the result data is accurately displayed in the specified area of the user interface, ensuring the real-time and smoothness of the Q&A process, allowing users to experience an efficient interactive experience similar to instant messaging.
[0063] Security authentication module: deeply integrated with the OAuth 2.0 standard authentication framework, a unique and time-effective user authentication token is generated through a secure encryption algorithm at the moment the user initiates a query request. This token not only contains the user's basic identity information, but also integrates security elements such as timestamps and random numbers to further enhance security. In the process of building an Ajax request, the token is embedded in the request header information. After receiving the request, the back-end intelligent knowledge center decrypts, verifies and parses the token according to the strict verification process of the OAuth 2.0 standard, confirms the legitimacy of the user's identity and the scope of authority, effectively prevents illegal access and data leakage, and ensures that the entire query process is carried out in a safe and reliable environment.
[0064] Step 3: Security Integration
[0065] Integrate the developed JS plug-in into the front-end framework of the target business system, following strict integration specifications, that is, introduce the JS plug-in script file between tags. During the page loading process, when the browser parses the plug-in reference in the tag, it loads the plug-in-related JavaScript code and CSS style files into the memory according to the predetermined loading order and dependency relationship. During the plug-in initialization process, by detecting the page structure and DOM elements of the target business system, an interactive icon is automatically generated in the lower right corner of the interface. This interactive icon adopts a responsive design, which can present different visual effects and interactive feedback according to the user's mouse operation (such as hovering, clicking, etc.), and supports users to freely adjust the icon position by dragging the mouse to meet the user's personalized operating habits and visual preferences, thereby greatly improving the user experience.
[0066] Step 4: Ajax request and data processing
[0067] After the user enters a question in the question-and-answer interface, the plug-in's instant messaging logic module responds quickly and builds a request based on jQuery's Ajax function. First, the question text information entered by the user is collected, and the current user's authentication token is obtained through the security authentication module. The question information and the authentication token are encapsulated in the predefined JSON data format to form a complete Ajax request data body. Then, using the asynchronous characteristics of Ajax, a POST request is sent to the specified back-end intelligent knowledge middle-end service interface. After receiving the request, the back-end verifies the user's authority based on the authentication token in the request. If the verification passes, the data processing process is entered; otherwise, the corresponding authority error information is returned to the front-end plug-in. In the data processing process, natural language processing technology is used to deeply analyze the question text, including lexical analysis, syntactic analysis, semantic understanding and other multi-level processing, to extract the key semantic features and intention information of the question, laying the foundation for subsequent accurate matching with the knowledge base.
[0068] Step 5: User Authentication
[0069] A rigorous user authentication mechanism is integrated. The user authentication token embedded in each Ajax request is processed by the backend according to the OAuth 2.0 standard verification process. First, the token is checked for integrity to check whether there is data tampering or damage; if the integrity check passes, the token is further decrypted to obtain the user identity and permission information. Combined with the user role information, the backend system queries the detailed permission list corresponding to the user from the permission management database, including accessible knowledge fields, data operation permissions, etc., and compares and verifies with the current requested operation. At the same time, the backend records the user's query request information, including query time, question content, etc., and performs correlation analysis with historical query records to build a user query behavior profile, so as to provide data support for the subsequent personalized knowledge content recommendation based on the user's query habits, preferences and role characteristics, enhance the relevance and practicality of the query results, and improve the efficiency and satisfaction of users in acquiring knowledge.
[0070] Step 6: Knowledge Services
[0071] After the backend receives the Ajax request and completes user identity authentication and question parsing, it enters the core processing link of the knowledge service. Using advanced natural language processing technology and intelligent algorithm models, the parsed questions are quickly matched with the knowledge items in the knowledge base. Using the similarity calculation algorithm based on the vector space model, the text of the question and the knowledge item is converted into a vector representation. By calculating indicators such as the cosine similarity between the vectors, several knowledge items with the highest semantic similarity to the question are screened as candidate results. Then, based on the user query behavior portrait constructed during the user identity authentication process and the popularity and quality of the knowledge items in the knowledge base, the candidate results are sorted and screened to determine the final query results. The query results are encapsulated in JSON format, including rich information such as the knowledge content body, related reference links, and recommended reading materials, and are returned to the front end through an Ajax response. After receiving the response, the front end uses JavaScript's JSON parsing library to parse the data, and through the dynamic display function of the user interface component, the query results are presented to the user according to the predetermined display template and style. At the same time, based on user identity information and query history, the backend uses association rule mining algorithms and other technologies to mine similar questions related to the current query question from the knowledge base, and returns them to the front-end plug-in for display, so that users can further expand the scope of knowledge acquisition and improve the accuracy and completeness of questions and answers, thereby realizing efficient, accurate and personalized knowledge service functions, meeting users' immediate knowledge needs during business operations, and improving overall business processing efficiency and user experience.
[0072] The present invention not only achieves seamless connection with the intelligent knowledge platform API by embedding instant interactive question and answer icons in the page, but also ensures the continuity of operations, significantly improving user work efficiency and overall experience. While providing personalized information services, it strictly adheres to data protection principles to ensure the safety of user information, even when the plug-in is connected to the intelligent knowledge platform API and carries user information. In addition, this technology successfully breaks down system barriers and achieves efficient integration across systems, decoupling business logic and data maintenance work. This design authorizes business managers to update content directly on the intelligent knowledge platform without the need for the technical team to perform tedious code adjustments or system redeployment, greatly improving management flexibility and response speed, and is an important milestone in improving enterprise operational efficiency and promoting digital transformation.
[0073] A second embodiment of the present invention is:
[0074] A plug-in-based knowledge service plug-in integration method is provided for querying population-related work in Chengdu, which specifically includes the following steps:
[0075] First, for the construction of the knowledge base, the operators sorted and uploaded the key demographic data of Chengdu in the past ten years, including the number of births and the total population size each year, to ensure that all data were accurately incorporated into the intelligent knowledge platform after strict quality control. In addition, a detailed "xx System Form Filling Guide" document was also uploaded to the platform, which detailed the filling requirements and precautions for each form item, providing users with intuitive operation guidance.
[0076] In terms of system integration, the developed JavaScript plug-in is integrated into the front-end interface (index.html) of the xx system through technical means. After the deployment is completed, the system user can find a draggable floating icon in the lower right corner of the interface after logging in, such as Figure 3 This icon is the entrance to the instant question and answer function. Clicking this icon will open a dialog box-style question and answer interface, as shown in the figure below. Figure 4 As shown in the figure, the user-friendly interface is fully considered in the design.
[0077] As for the application of information retrieval function, such as Figure 1 and Figure 2As shown, the specific business process is as follows: the user enters a query request in the dialog box, such as "What is the total population of Chengdu in 2023", and the request is then passed to the intelligent knowledge middle station through the plug-in. The middle station first verifies the user's permissions, then uses natural language processing technology to parse the problem and quickly perform accurate retrieval in the database. Once relevant information is matched, such as "The total population of Chengdu in 2023 is 21.403 million", the result is immediately fed back to the user; the user continues to fill in questions in the xx system form in the dialog box, such as "How to fill in the xx form item in the xx form", and after the request is sent to the middle station, the user permission verification, question parsing, answer retrieval and other steps are also performed in sequence, and the result information "The xx form item in the xx form refers to xx, which needs to be filled in according to the xx format" is generated and the result is fed back to the front end for real-time display.
[0078] A third embodiment of the present invention provides a plug-in-based knowledge service plug-in integration system, the system comprising:
[0079] Knowledge base construction unit: configured to construct a knowledge base with a dynamic update mechanism;
[0080] Plugin development unit: configured to develop JavaScript plugins;
[0081] Fusion unit: configured to integrate the developed JavaScript plug-in into the front-end framework of the target business system;
[0082] Ajax request and data processing unit: configured so that after the user enters a question in the question-answer input box interface, the instant messaging logic module responds quickly and builds a request based on jQuery's Ajax function;
[0083] Authentication unit: It is configured to integrate a rigorous user authentication mechanism. The user authentication token is embedded in each Ajax request, and the backend processes it according to the OAuth 2.0 standard authentication process.
[0084] Knowledge service unit: It is configured to enter the core processing link of knowledge service after the backend receives the Ajax request and completes user identity authentication and problem analysis.
[0085] Embodiment 4: The present invention provides a computer storage medium, wherein the computer storage medium stores computer executable instructions, and the computer executable instructions are used to execute the aforementioned plug-in-based knowledge service plug-in integration method.
[0086] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the field can easily think of various equivalent modifications or substitutions within the technical scope disclosed by the present invention, and these modifications or substitutions should all be covered within the protection scope of the present invention.
Claims
1. A plug-in-based knowledge service plug-in integration method, characterized in that: The following steps are involved: Step 1: Build a knowledge base with a dynamic update mechanism; Step 2: Develop JavaScript plugin; Step 3: Integrate the developed JavaScript plug-in into the front-end framework of the target business system; Step 4: Ajax request and data processing; Step 5: User authentication; Step 6: Knowledge services.
2. The plug-in-based knowledge service plug-in integration method according to claim 1 is characterized in that: Step 1 specifically includes the following steps: Step 1.1 Collect and organize diversified business guides and information documents; Step 1.2: Use targeted data processing methods to process documents of different formats and types; Step 1.3: Conduct deep data processing on the structured or unstructured index fields in the data document processed in step 1.2, and perform denoising operations to eliminate redundant information and interference data in the document; Step 1.4 classifies and integrates the information processed in step 1.3, converts it into highly structured knowledge items, and constructs a knowledge base with a dynamic update mechanism.
3. The plug-in-based knowledge service plug-in integration method according to claim 2 is characterized in that: Step 2 specifically involves front-end technicians using jQuery to develop lightweight, highly compatible JavaScript plug-ins.
4. The plug-in-based knowledge service plug-in integration method according to claim 3 is characterized in that: The JavaScript plug-in includes: Develop user interface components, that is, use HTML5 and CSS3 to build an intuitive, friendly and easy-to-operate user interaction interface, including: (1) designing a question-and-answer input box with an adaptive layout, automatically adjusting the style and size according to different screen sizes and device types to ensure user input convenience; (2) setting up a clear and concise query result display area, using dynamic loading method, which can be flexibly presented according to the amount and type of query result data. Develop an instant messaging logic module, that is, build an efficient and real-time information interaction channel based on the WebSocket protocol: when a user enters a question in the question-and-answer input box interface, the user input event is captured immediately, the question information is quickly encapsulated as request data that complies with the Ajax specification, and the data is sent to the back-end intelligent knowledge center through the established WebSocket connection; at the same time, the response data returned by the back-end is monitored in real time. Once the processing result is received, the interface update event is immediately triggered, and the result data is accurately displayed in the specified area of the user interface; Develop a security authentication module, which deeply integrates the OAuth 2.0 standard authentication framework. At the moment the user initiates a query request, a unique and time-sensitive user authentication token is generated through a secure encryption algorithm. This token contains the user's basic identity information and integrates a timestamp and a random number. During the Ajax request construction process, the token is embedded in the request header information. After receiving the request, the back-end intelligent knowledge center decrypts, verifies and parses the token according to the strict verification process of the OAuth 2.0 standard to confirm the legitimacy of the user's identity and the scope of authority.
5. The plug-in-based knowledge service plug-in integration method according to claim 4 is characterized in that: Step 3 is as follows: Integrate the developed JS plug-in into the front-end framework of the target business system and follow the integration specifications, that is, introduce the JS plug-in script file between tags; During the page loading process, when the browser parses the plug-in reference in the tag, it loads the plug-in-related JavaScript code and CSS style files into the memory according to the predetermined loading order and dependency relationship; During the initialization of the plug-in, the page structure and DOM elements of the target business system are detected, and an interactive icon is automatically generated in the lower right corner of the interface. This interactive icon adopts a responsive design, which can present different visual effects and interactive feedback according to the user's mouse operation, and supports users to freely adjust the icon position by dragging the mouse.
6. The plug-in-based knowledge service plug-in integration method according to claim 5 is characterized in that: Step 4: Ajax request and data processing: After the user enters a question in the question-answer input box interface, the instant messaging logic module responds quickly and builds a request based on jQuery's Ajax function, which includes the following steps: Step 4.1 collects the question text information input by the user, and obtains the current user's authentication token through the security authentication module, and encapsulates the question information and the authentication token according to the predefined JSON data format to form a complete Ajax request data body; Step 4.2 uses the asynchronous characteristics of Ajax to send a POST request to the specified back-end intelligent knowledge middle-end service interface. After receiving the request, the back-end verifies the user's authority based on the authentication token in the request. If the verification passes, the data processing process begins; otherwise, the corresponding authority error message is returned to the front-end plug-in. During the data processing process, natural language processing is used to deeply analyze the question text, including lexical analysis, syntactic analysis, and semantic understanding, to extract the key semantic features and intent information of the question.
7. The plug-in-based knowledge service plug-in integration method according to claim 6 is characterized in that: Step 5 is to integrate a rigorous user authentication mechanism. The user authentication token embedded in each Ajax request is processed by the backend according to the OAuth2.0 standard authentication process, which includes the following steps: Step 5.1: Perform integrity check on the token to check whether there is any data tampering or damage; if the integrity check passes, the token is further decrypted to obtain the user identity and permission information; Step 5.2: Based on the user role information, the backend system queries the detailed permission list corresponding to the user from the permission management database and compares and verifies it with the currently requested operation; Step 5.3 The backend records the user's query request information, performs correlation analysis with historical query records, and builds a user query behavior profile.
8. The plug-in-based knowledge service plug-in integration method according to claim 7 is characterized in that: Step 6 is as follows: After the backend receives the Ajax request and completes user identity authentication and question analysis, it enters the core processing link of the knowledge service, including the following steps: Step 6.1: Use natural language processing methods and intelligent algorithm models to quickly match the parsed questions with knowledge items in the knowledge base; Step 6.2 uses a similarity calculation algorithm based on a vector space model to convert the text of the question and the knowledge item into a vector representation, and by calculating the cosine similarity index between the vectors, selects several knowledge items with the highest semantic similarity to the question as candidate results; Step 6.3 sorts and screens the candidate results based on the user query behavior profile constructed during the user identity authentication process and the popularity and quality factors of the knowledge items in the knowledge base to determine the final query result; Step 6.4 encapsulates the query results in JSON format, including the knowledge content body, related reference links, and recommended reading material information, and returns them to the front end through Ajax response; Step 6.5 After receiving the response, the front end uses the JSON parsing library of the JavaScript plug-in to parse the data, and presents the query results to the user according to the predetermined display template and style through the dynamic display function of the user interface component; Step 6.6 The backend uses association rule mining algorithms based on user identity information and query history to mine similar questions related to the current query question from the knowledge base, and returns them to the front-end plug-in for display, thereby realizing efficient, accurate and personalized knowledge service functions.
9. A plug-in-based knowledge service plug-in integration system, applied to the method of claim 8, characterized in that: The system comprises: Knowledge base construction unit: configured to construct a knowledge base with a dynamic update mechanism; Plugin development unit: configured to develop JavaScript plugins; Fusion unit: configured to integrate the developed JavaScript plug-in into the front-end framework of the target business system; Ajax request and data processing unit: configured so that after the user enters a question in the question-answer input box interface, the instant messaging logic module responds quickly and builds a request based on jQuery's Ajax function; Authentication unit: It is configured to integrate a rigorous user authentication mechanism. The user authentication token is embedded in each Ajax request, and the backend processes it according to the OAuth 2.0 standard authentication process. Knowledge service unit: It is configured to enter the core processing link of knowledge service after the backend receives the Ajax request and completes user identity authentication and problem analysis.
10. A computer storage medium storing computer executable instructions, characterized in that: The computer executable instructions are used to execute the plug-in-based knowledge service plug-in integration method of any one of the preceding claims 1 to 8.
Citation Information
Cited By
AI server real-time enhancement system and data processing method
CN120354929A