Knowledge base document slice parsing method and device, equipment and storage medium

CN122965476APending Publication Date: 2026-10-23PING AN TECH (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611192691.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-06
Publication Date
2026-10-23

AI Technical Summary

Technical Problem

[0003]本发明提供一种知识库文档切片解析方法、装置、设备及存储介质,解决了现有知识库文档切片处理中展示布局单一、缺乏联动交互、无法灵活适配的技术问题

Benefits of technology

[0008]上述知识库文档切片解析方法,所实现的方案中,基于大语言模型解析目标文档,在展示界面中生成三栏布局区域,所述三栏布局区域包括用于目标文档的原文内容的第一区域、用于展示对所述原文内容进行切片处理后得到的切片列表的第二区域、以及用于展示与各切片相关联的知识点信息的第三区域;依据用户对所述第一区域或所述第三区域的伸缩指令,并根据剩余宽度设定第二区域的显示宽度;建立所述第二区域中所述切片列表中的各切片与所述第一区域中原文内容片段之间的映射关系,当用户选中任一切片时,在第一区域中高亮显示对应的原文内容片段;当检测到滚动至所在区域底部附近且已加载切片数据未达全部时,向服务器请求下一批切片数据,将新接收的切片数据追加至所述第二区域的切片列表中,并更新所述第一区域中展示的原文内容。在本申请中,通过构建原文、切片、知识点三栏同屏联动的展示布局,实现了文档切片内容的多维度可视化呈现,用户无需切换页面即可同时查看原文、切片及知识点,显著提升了知识查阅的连贯性与理解效率。通过建立切片与原文片段之间的映射关系并支持点击切片高亮对应原文,替代了传统手动检索或滚动查找的定位方式,提高了切片与原文的核对精度与操作便捷性。通过支持第一区域和第三区域的宽度的伸缩调节并根据剩余宽度自适应调整第二区域宽度,突破了固定布局的局限,能够灵活适配长文本、代码块等复杂切片的查看需求。通过滚动到底部时按批次请求并追加切片数据,结合第一区域的原文内容的同步更新,避免了一次性加载大量切片导致的页面卡顿,实现了切片列表的流畅渲染与性能优化。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122965476A_ABST
    Figure CN122965476A_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of artificial intelligence, is suitable for the medical field and the financial field, and discloses a knowledge base document slicing analysis method, device, equipment and storage medium, the method comprises the following steps: acquiring a target document and analyzing by using a large language model, generating a three-column layout area in a display interface; according to a user stretching instruction, adjusting the display width of the first area or the third area, and adjusting the display width of the second area; establishing a mapping relationship between each slice and an original content segment, when a user selects any slice, highlighting the original content segment corresponding to the slice; when it is detected that the bottom is near and all slice data is not reached, requesting the next batch of slice data from the server, and updating the original content displayed in the first area. The application solves the technical problems of single display layout, lack of linkage interaction and inability to adapt flexibly in the existing knowledge base document slicing processing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of artificial intelligence technology and is applicable to the medical and financial fields. In particular, it relates to a method, apparatus, device and storage medium for parsing knowledge base document slices. Background Technology

[0002] In existing technologies, knowledge base documents are used for document parsing, knowledge slicing, and intelligent retrieval. Intelligent document parsing and knowledge slicing technologies are centered around IDP (Integrated Document Platform), integrating OCR, NLP, and deep learning capabilities to achieve structured document parsing and knowledge unit segmentation. Knowledge base retrieval and display products focus on retrieval and related applications after slicing, enabling retrieval recall and precise push of sliced ​​content. However, existing technologies and products still have significant limitations in the visualization and interactive experience of sliced ​​content: the display layout is simplistic, often using single-column or double-column layouts, failing to achieve simultaneous screen interaction of slices, original text, and knowledge points; there is a lack of interaction between slices and original text, requiring users to manually search or scroll to verify the original text, resulting in low location efficiency; the layout lacks flexibility, lacking regional scaling adjustment functions, making it difficult to adapt to the viewing needs of complex slices such as long texts or code blocks; the rendering performance of the slice list is unbalanced with the display experience, with some products loading all slices at once causing page lag; and the synergy between semantic slicing and the visualization experience is insufficient, generally exhibiting a problem of "heavy emphasis on slice generation, light emphasis on display interaction," leading to limited knowledge utilization. Therefore, how to provide a technical solution that enables detailed viewing, linked analysis, and convenient operation of document slices has become an urgent technical problem to be solved in this field. Summary of the Invention

[0003] This invention provides a method, apparatus, device, and storage medium for parsing knowledge base document slices, which solves the technical problems of existing knowledge base document slice processing, such as single display layout, lack of interactive linkage, and inflexible adaptation.

[0004] In a first aspect, the present invention provides a method for parsing knowledge base document slices, including: The target document is obtained and parsed using a large language model. A three-column layout area is generated in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying the slice list obtained after slicing the original text content, and a third area for displaying the knowledge point information associated with each slice. Based on the user's scaling command for the first area or the third area, adjust the display width of the first area or the third area, and set the display width of the second area according to the adjusted remaining width; Establish a mapping relationship between each slice in the slice list in the second region and the original text content fragment in the first region. When the user selects any slice in the second region, the original text content fragment corresponding to the slice is highlighted in the first region. When it is detected that the scrolling has reached near the bottom of the current area and the currently loaded slice data has not reached the total number of slice data, the next batch of slice data is requested from the server, the newly received slice data is appended to the slice list of the second area, and the original text content displayed in the first area is updated.

[0005] Secondly, the present invention provides a knowledge base document slicing and parsing device, comprising: The layout generation module is used to acquire the target document and parse it using a large language model. It generates a three-column layout area in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying the slice list obtained after slicing the original text content, and a third area for displaying the knowledge point information associated with each slice. The width adjustment module is used to adjust the display width of the first area or the third area according to the user's scaling command for the first area or the third area, and to set the display width of the second area according to the adjusted remaining width; The slice mapping module is used to establish a mapping relationship between each slice in the slice list in the second region and the original text content fragment in the first region. When the user selects any slice in the second region, the original text content fragment corresponding to the slice is highlighted in the first region. The scrolling loading module is used to request the next batch of slice data from the server when it detects that the scrolling has reached near the bottom of the current area and the currently loaded slice data has not reached all slice data. The newly received slice data is then appended to the slice list of the second area, and the original text content displayed in the first area is updated.

[0006] Thirdly, the present invention provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the knowledge base document slicing parsing method.

[0007] Fourthly, the present invention provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the knowledge base document slicing parsing method.

[0008] The aforementioned knowledge base document slicing parsing method, in its implementation, parses the target document based on a large language model, generating a three-column layout area in the display interface. This three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying a list of slices obtained after slicing the original text content, and a third area for displaying knowledge point information associated with each slice. The display width of the second area is set according to the user's scaling instructions for the first or third area and based on the remaining width. A mapping relationship is established between each slice in the slice list in the second area and the original text content fragments in the first area. When the user selects any slice, the corresponding original text content fragment is highlighted in the first area. When scrolling to near the bottom of the current area and not all slice data has been loaded, the system requests the next batch of slice data from the server, appends the newly received slice data to the slice list in the second area, and updates the original text content displayed in the first area. This application achieves multi-dimensional visualization of document slice content by constructing a three-column display layout that links the original text, slices, and knowledge points simultaneously. Users can view the original text, slices, and knowledge points without switching pages, significantly improving the continuity and efficiency of knowledge retrieval. By establishing a mapping relationship between slices and original text fragments and supporting clicking on slices to highlight the corresponding original text, the traditional manual retrieval or scrolling search method is replaced, improving the accuracy of slice-to-original text verification and ease of operation. By supporting the scaling and adjustment of the width of the first and third areas and adaptively adjusting the width of the second area based on the remaining width, the limitations of fixed layouts are overcome, flexibly adapting to the viewing needs of complex slices such as long texts and code blocks. By requesting and appending slice data in batches when scrolling to the bottom, combined with the synchronous update of the original text content in the first area, page lag caused by loading a large number of slices at once is avoided, achieving smooth rendering and performance optimization of the slice list. Attached Figure Description

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

[0010] Figure 1 This is a schematic diagram of an application environment for a knowledge base document slicing and parsing method according to an embodiment of the present invention.

[0011] Figure 2 This is a flowchart illustrating a knowledge base document slicing and parsing method according to an embodiment of the present invention.

[0012] Figure 3 yes Figure 2 A schematic diagram of a specific implementation method for step S20.

[0013] Figure 4 yes Figure 2 A schematic diagram of a specific implementation method for step S30.

[0014] Figure 5 yes Figure 2 A flowchart illustrating a specific implementation of step S40.

[0015] Figure 6 This is a schematic diagram of a knowledge base document slicing and parsing device according to an embodiment of the present invention.

[0016] Figure 7 This is a schematic diagram of the structure of a computer device according to an embodiment of the present invention.

[0017] Figure 8 This is another structural schematic diagram of a computer device according to one embodiment of the present invention. Detailed Implementation

[0018] 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, not all, of the embodiments of the present invention. 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.

[0019] The knowledge base document slicing and parsing method provided in this invention can be applied to, for example... Figure 1 In the application environment, Figure 1This is a schematic diagram of an application environment for a knowledge base document slicing parsing method according to an embodiment of the present invention; wherein, the client communicates with the server via a network. The server can obtain the target document and parse it using a large language model, generating a three-column layout area in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying the slice list obtained after slicing the original text content, and a third area for displaying knowledge point information associated with each slice. According to the user's scaling command for the first area or the third area, the display width of the first area or the third area is adjusted, and the display width of the second area is set according to the remaining width after adjustment. A mapping relationship is established between each slice in the slice list in the second area and the original text content fragments in the first area. When the user selects any slice in the second area, the original text content fragment corresponding to the slice is highlighted in the first area. When it is detected that the scrolling reaches near the bottom of the area and the currently loaded slice data has not reached all slice data, the server is requested to send the next batch of slice data, the newly received slice data is appended to the slice list in the second area, and the original text content displayed in the first area is updated. In this invention, by constructing a three-column display layout that links the original text, slices, and knowledge points simultaneously, a multi-dimensional visual presentation of document slice content is achieved. Users can view the original text, slices, and knowledge points simultaneously without switching pages, significantly improving the continuity and efficiency of knowledge retrieval. By establishing a mapping relationship between slices and original text fragments and supporting clicking on slices to highlight the corresponding original text, the traditional manual retrieval or scrolling search method is replaced, improving the accuracy of slice-to-original text verification and ease of operation. By supporting the scaling and adjustment of the width of the first and third areas and adaptively adjusting the width of the second area based on the remaining width, the limitations of fixed layouts are overcome, allowing flexible adaptation to the viewing needs of complex slices such as long texts and code blocks. By requesting and appending slice data in batches when scrolling to the bottom, combined with the synchronous update of the original text in the first area, page lag caused by loading a large number of slices at once is avoided, achieving smooth rendering and performance optimization of the slice list. The invention will be described in detail below through specific embodiments.

[0020] Please see Figure 2 As shown, Figure 2 This is a flowchart illustrating a knowledge base document slicing and parsing method provided in an embodiment of the present invention. The knowledge base document slicing and parsing method specifically includes the following steps: S10 acquires the target document and parses it using a large language model, generating a three-column layout area in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying a list of slices obtained after slicing the original text content, and a third area for displaying knowledge point information associated with each slice.

[0021] Optionally, the step of acquiring the target document and parsing it using a large language model to generate a three-column layout area in the display interface includes: the user uploading the target document, which is in DOCX format or other supported structured document; sending the target document to the large language model, which performs semantic parsing and structure recognition on the document content, identifies elements such as paragraphs, headings, and tables in the document, and divides the document into multiple knowledge slices based on semantic integrity, while generating associated knowledge point summaries or tags for each slice; after parsing, three parallel areas are rendered in the display interface, where the first area is used to present the complete original text content before slice processing, the second area is used to display the specific content of each slice in a list format, and the third area is used to display knowledge point information related to the current slice or all slices; the three columns are displayed simultaneously in the same visible area, forming a linked layout of original text, slices, and knowledge points.

[0022] Optionally, the large language model is a neural network model built on a deep learning framework, employing the Transformer architecture. The large language model is trained through two stages: the first stage is a pre-training stage, utilizing a large-scale unlabeled text corpus and employing self-supervised learning to learn general semantic representations and statistical patterns of natural language by predicting masked lexical units or the next lexical unit in a text sequence; the second stage is a fine-tuning stage, where, based on the pre-trained model, supervised parameter adjustments are performed using a specific task dataset containing document structure and slice annotations, enabling the model to acquire the ability to perform semantic parsing and structured recognition of input documents. In this embodiment, the large language model is used to receive target documents uploaded by users, parse the document content, identify structural elements such as paragraphs, headings, and tables, and segment the document into multiple knowledge slices based on semantic integrity.

[0023] In the financial sector, financial analysis platforms acquire financial documents uploaded by users, including but not limited to listed company annual reports, prospectuses, industry research reports, or financial contracts. The platform sends these documents to a large language model fine-tuned from financial corpora for parsing. The large language model identifies chapter titles, table data, financial indicator descriptions, and risk disclosure paragraphs within the document, and segments the document into multiple financial knowledge slices based on semantic integrity, such as by thematic units like "Operating Revenue Analysis," "Reasons for Gross Profit Margin Changes," and "Accounts Receivable Risk." It also automatically extracts key knowledge points for each slice, such as the relevant financial items, time periods, and year-on-year change rates. After parsing, a three-column layout is generated on the display interface. The first area displays the complete original text of the financial document; the second area displays the titles and summaries of each financial knowledge slice in a list format; and the third area displays regulatory provisions, internal risk control points, or historical comparative data related to the current financial slice. This allows financial analysts and compliance reviewers to efficiently complete document reading, slice verification, and knowledge association analysis within the same interface.

[0024] In an embodiment within the healthcare field, a medical knowledge management platform acquires medical documents uploaded by users. These documents include, but are not limited to, clinical trial reports, drug instructions, treatment guidelines, or medical literature. The platform sends these documents to a large language model fine-tuned from a medical corpus for parsing. The large language model identifies key information in the documents, such as disease names, treatment plans, adverse reaction data, and clinical trial designs. Based on semantic integrity, the platform segments the documents into multiple medical knowledge slices, for example, by modules such as "indication description," "dosage and administration," "contraindications," and "drug interactions." Simultaneously, it automatically extracts relevant knowledge points for each slice, such as the generic names of the drugs involved, the incidence of adverse reactions, and the level of evidence-based medicine. After parsing, a three-column layout area is generated on the display interface. The first area displays the complete original text of the medical document; the second area displays the titles and content summaries of each medical knowledge slice in a list format; and the third area displays clinical guideline recommendations, relevant disease codes, or comparative information on similar drugs associated with the current medical slice. This allows doctors, medical researchers, or drug reviewers to efficiently complete literature reading, slice review, and clinical knowledge association analysis within the same interface.

[0025] S20 adjusts the display width of the first or third region according to the user's scaling command for the first or third region, and sets the display width of the second region based on the adjusted remaining width. Specifically, as shown... Figure 3 The above, Figure 3 This is a flowchart illustrating a specific implementation of step S20, which specifically includes the following steps S21-S23: S21 uses a grid layout component from the interface component library. The display interface is divided into a preset number of grid units. The three-column layout area occupies all the grid units. The display width of the first area is adjusted by dynamically configuring the number of columns of the first grid column component corresponding to the first area, and the display width of the third area is adjusted by dynamically configuring the number of columns of the third grid column component corresponding to the third area. The number of columns of the second grid column component corresponding to the second area is equal to the preset number minus the number of columns corresponding to the first area minus the number of columns corresponding to the third area. The display width of the second area is determined based on the number of columns of the second grid column component. Optionally, the total width of the interface is divided into a preset number of grid units, the preset number being 24. A first number of grid columns is allocated to the first area, and a second number of grid columns is allocated to the third area. The display width of the first area is positively correlated with the first number of grid columns, and the display width of the third area is positively correlated with the second number of grid columns. The number of grid columns corresponding to the display width of the second area is equal to the preset number minus the first number of grid columns and the second number of grid columns. In the specific implementation, the grid layout component in the user interface component library is used. The width of the area is adjusted by dynamically configuring the column number attribute value of the grid column component corresponding to the first area and the third area. The grid column component of the second area automatically calculates and occupies the remaining width according to the column number attribute value of the first area and the third area.

[0026] S22 When the scaling instruction is a user clicking the collapse button, the number of columns corresponding to the first area is adjusted to 0 and / or the number of columns corresponding to the third area is adjusted to 0. When the scaling instruction is a user clicking the expand button, the number of columns corresponding to the first area is restored to its original value and / or the number of columns corresponding to the third area is restored to its original value. The change in the number of columns corresponding to the first area and / or the third area causes a change in the display width of the corresponding area. During the display width change, the intermediate state is rendered frame by frame through the transition component in the interface component library during the width change. Optionally, when the user clicks the collapse button, the grid column value corresponding to the first area is adjusted to 0, and the grid column value corresponding to the third area is adjusted to 0. At this time, the number of grid columns in the second area is equal to the total number of grid columns minus 0 minus 0, which is equal to the total number of grid columns. The second area occupies the entire interface width. When the user clicks the expand button, the number of grid columns in the first area and the third area is restored to the preset initial value, and the number of grid columns in the second area is reduced accordingly, restoring a three-column side-by-side layout. To achieve a smooth visual transition when the width changes, a transition component provided by the user interface framework is used to wrap the Document Object Model (DOM) elements of the first and third regions within the transition component. When the grid column number attribute changes, causing the display width of the corresponding region to change, the transition component renders the intermediate state frame by frame during the width change process, generating a slide-in or slide-out animation effect to avoid visual jumps caused by abrupt width changes.

[0027] S23 stores the adjusted column counts of the first region and the third region as width configuration information in local storage; when the display interface is refreshed, the width configuration information is read from the local storage, and the display widths of the first region and the third region are reset according to the read column counts, and the display width of the second region is recalculated and set. Optionally, after the width of the first or third region is adjusted, the first grid column value corresponding to the first region and the second grid column value corresponding to the third region are obtained. The first and second grid column numbers are stored as width configuration information in the browser's local storage. After the interface is refreshed or reloaded, the stored width configuration information is read from the local storage. If the read is successful, the display width of the first and third regions is reset according to the read first and second grid column numbers. The display width of the second region is recalculated and set by subtracting the first and second grid column numbers from the total number of grid columns. If the read fails or the width configuration information is not found in the local storage, the preset default grid column values ​​are used to initialize the layout. In this way, users do not need to readjust the region width after refreshing the page to maintain the custom layout state from the last use.

[0028] In the financial field implementation, step S20 is specifically implemented as follows: The financial analysis platform display interface includes a document original text area, such as the original text of a listed company's annual report, a slice list area, such as slices divided by financial chapters, and a knowledge point area, such as explanations of regulatory rules or financial indicators. When a financial analyst needs to focus on viewing slices in the slice list that contain complex financial tables or lengthy analytical texts, the analyst clicks the scaling control at the edge of the first or third area, such as a collapse button, to issue a scaling command. Based on this command, the platform gradually adjusts the display width of the first area from the initial 6 grid columns to 0 grid columns, and simultaneously adjusts the display width of the third area from the initial 4 grid columns to 0 grid columns. During this process, the platform calculates the grid column count of the second area in real time (i.e., 24-0-0=24) by subtracting the current grid column count of the first and third areas from the total grid column count of 24, and sets the display width of the second area to the width of the entire interface. After the adjustment, the second area's slice list is displayed in full width, allowing financial analysts to view the complete financial data tables or lengthy analytical paragraphs within the slices without needing to scroll horizontally. Once the analyst has finished viewing in detail, clicking the expand control again restores the number of grid columns in the first and third areas to their pre-adjustment values ​​(e.g., 6 and 4), and the display width of the second area returns to its initial state of 14 grid columns, re-presenting the three-column linked layout. This scaling adjustment satisfies the need for full-viewing of complex financial slices in the financial field.

[0029] In the healthcare implementation, step S20 is specifically implemented as follows: The medical knowledge management platform displays the complete original text of a drug clinical trial report in the first area, the second area displays a list of slices obtained based on semantic segmentation, such as slices like "Inclusion Criteria," "Adverse Reaction Statistics," and "Efficacy Analysis," and the third area displays clinical guideline fragments or ICD-11 disease codes associated with each slice. When a clinical researcher needs to focus on reviewing a slice in the second area containing a detailed table of adverse reaction incidence rates, the researcher clicks the scaling control at the edge of the first area, such as a collapse button. Based on this scaling instruction, the platform gradually adjusts the number of grid columns in the first area from the initial 6 to 0. Simultaneously, if the researcher deems the knowledge point area unnecessary during the current review process, they can click the scaling control in the third area to gradually adjust the number of grid columns in the third area from the initial 4 to 0. The platform calculates the number of grid columns in the second area to be 24 by subtracting the current number of grid columns (0) in the first area and the current number of grid columns (0) in the third area from the total number of grid columns (24), and sets the display width of the second area to the width of the entire interface. After the adjustment, the slice list in the second area is displayed in full width, and the adverse reaction statistics table and detailed data are presented completely, allowing researchers to complete data verification without horizontal scrolling. After the researcher completes a detailed review of the slice, clicking the expand control again restores the number of grid columns in the first area to 6, the third area to 4, and the second area to 14, restoring the three-column layout to its original state, facilitating the linked comparative analysis of the original text, slices, and knowledge points.

[0030] S30 establishes a mapping relationship between each slice in the slice list in the second region and the original text content fragment in the first region. When the user selects any slice in the second region, the corresponding original text content fragment is highlighted in the first region. Specifically, as shown... Figure 4 The above, Figure 4 This is a flowchart illustrating a specific implementation of step S30, which specifically includes the following steps S31-S32: S31 assigns a unique identifier to each slice. The original text content displayed in the first area is generated by splicing all slices in the order they appear in the original document, and each spliced ​​fragment is associated with the unique identifier of the corresponding slice; specifically, it includes the following steps S311-S312: S311 retrieves slice data from the second region component and passes the slice data to the first region component. Optionally, in a component-based architecture of the user interface framework, the second region component, as the holder of the slice data, retrieves the slice data set by calling a backend interface or from the global state. The slice data includes a unique identifier for each slice, the slice text content, and the order information of the slices in the original document. The second region component passes the slice data upwards to the parent component through a component communication mechanism. After receiving the slice data, the parent component passes it down as an attribute to the first region component. After receiving the slice data, the first region component constructs the complete display content of the original document based on the order information and text content in the slice data. Through the above inter-component communication method, the transfer and sharing of slice data between the second region component and the first region component are realized.

[0031] The first region component (S312) iterates through all received slices, sequentially concatenates the slice content into a complete Hypertext Markup Language (HTML) structure, and labels each slice's content fragment with a tag element bearing the slice's unique identifier. Optionally, after obtaining the slice data set, the first region component reads the text content of each slice sequentially according to its order in the original document, such as based on the slice data's order field or index. For each slice, the first region component generates a wrapping HTML element, which sets a custom attribute or identifier attribute, the attribute value of which is the unique identifier of the current slice. The text content of the slice is placed inside the wrapping element. All wrapping elements corresponding to the slices are concatenated sequentially to form a complete HTML structure. This HTML structure is then rendered into the first region's display container. This concatenation method allows the original text content displayed in the first region to be presented in a fragmented structure, with each fragment carrying a corresponding slice identifier, providing a marking basis for subsequent highlighting and positioning based on the slice identifier.

[0032] S32 When the user selects any slice, the original text content of the first region is traversed according to the unique identifier of the slice, and a highlight style is added to the document object model element where the segment with the matching identifier is located.

[0033] Optionally, the second region component listens for the user's selection of a slice list item, obtains the unique identifier corresponding to the selected slice, and passes the unique identifier to the first region component. After receiving the unique identifier, the first region component obtains all wrapping elements carrying slice identifiers within the first region display container, such as the elements corresponding to each slice. The first region component iterates through these wrapping elements. For each element, it reads its identifier attribute value and compares it with the received unique identifier. When a wrapping element with a matching identifier is encountered, the first region component adds a preset highlight style class name to that element. This highlight style class name is used to change the element's background color or add visual markers such as borders. Simultaneously, the first region component removes the highlight style class names from other non-matching wrapping elements. Through the above traversal and style addition operations, the corresponding area of ​​the original text is highlighted after clicking on the slice.

[0034] In a financial implementation, when a financial analysis platform processes a listed company's annual report document, the second area's slice list includes multiple slices such as "Operating Revenue Analysis," "Reasons for Changes in Net Profit," and "Operating Cash Flow." The original annual report content displayed in the first area is composed of the above slice content pieced together in the original text order, with each slice's corresponding original text fragment labeled with a unique identifier, such as a slice ID. When a financial analyst clicks on the "Operating Revenue Analysis" slice in the second area, the platform obtains the slice's unique identifier and iterates through all fragment elements carrying the slice identifier in the original text content of the first area. The platform matches the unique identifier of the currently clicked slice with the identifiers of each fragment in the first area. When a matching original text fragment corresponding to "Operating Revenue Analysis" is found, a highlighting style is added to the document object model element containing that fragment, such as setting a yellow background or blue border. At this point, the analyst can quickly locate the specific descriptive paragraph about operating revenue in the original text without manual scrolling or searching, achieving precise linkage between slices and the original text and improving the efficiency of financial data verification and contextual tracing. In the financial field implementation, step S30 is specifically implemented as follows: When the financial analysis platform processes a listed company's annual report document, the slice list in the second area contains multiple slices such as "Operating Revenue Analysis," "Reasons for Changes in Net Profit," and "Cash Flow from Operating Activities." The original text of the annual report displayed in the first area is generated by splicing the above slice content in the original text order, and each slice's corresponding original text fragment is marked with a unique identifier. When a financial analyst clicks on the "Operating Revenue Analysis" slice in the second area, the platform obtains the unique identifier of the slice and iterates through all original text fragment elements carrying the slice identifier in the first area. The platform compares the unique identifier of the current slice with the identifiers of each fragment. When a matching fragment is found, a highlight style is added to the document object model element containing that fragment, such as setting a yellow background. Based on this, the analyst can quickly locate the specific descriptive paragraphs related to operating revenue in the original text without manually scrolling or searching for keywords, achieving precise linkage between slices and the original text, and improving the efficiency of financial data verification and contextual tracing.

[0035] In an embodiment within the healthcare field, when a medical knowledge management platform processes a clinical trial report document for a drug, the second area's slice list contains multiple semantic slices such as "patient inclusion criteria," "adverse reaction rate," "primary efficacy endpoint," and "safety analysis." The original clinical trial report displayed in the first area is constructed by piecing together the aforementioned slice content in the original order of the report, and each slice's corresponding original text fragment is labeled with a unique identifier, such as a slice UUID. When a clinical researcher clicks on the "adverse reaction rate" slice in the second area, the platform obtains the slice's unique identifier and iterates through all fragment elements carrying the slice identifier in the original text content of the first area. The platform compares the unique identifier of the current slice with the identifiers of each fragment. When a matching fragment is found, a highlight style is added to the document object model element containing that fragment, such as setting a light red background or a bold border. At this point, the researcher can quickly locate the specific statistical tables and descriptive paragraphs of the adverse reaction rate in the original text without manual scrolling or keyword searching, achieving precise linkage between slices and the original text and accelerating the efficiency of safety data verification and clinical review. In another embodiment in the field of healthcare, when a doctor views a treatment guideline document, clicking on the contraindications section in the second area will highlight the corresponding contraindication description area in the original text, helping the doctor quickly obtain key safety information.

[0036] S40, when detecting that scrolling to near the bottom of the current area and the currently loaded slice data has not yet reached the total number of slice data, requests the next batch of slice data from the server, appends the newly received slice data to the slice list of the second area, and updates the original text content displayed in the first area. Specifically, as... Figure 5 The above, Figure 5 This is a flowchart illustrating a specific implementation of step S40, which specifically includes the following steps S41-S42: S41 uses a debounce function to reduce the trigger frequency of scrolling events and calculates the distance between the scroll bar and the bottom. The distance between the scroll bar and the bottom is equal to the total scrolling height minus the distance from the top of the scroll bar minus the height of the visible area. Specifically, a delay time interval is set for the debounce function. When scrolling events are triggered continuously, the debounce function resets the timer after each trigger and restarts the timer after each reset. Only when the delay time interval has elapsed after the last trigger and the timer has not been reset again, the scrolling position detection and data loading judgment steps are performed. Optionally, a handling function is bound to the scroll event. This function calls a debouncing function and passes the scroll detection logic to be executed and a preset delay time interval to the debouncing function. When the user scrolls the scrollbar of the first or second area, the scroll event is triggered, and the debouncing function starts timing. If the scroll event is triggered again within the preset delay time interval, the debouncing function clears the previous timing and restarts timing. The debouncing function executes the scroll position detection logic only after the last scroll event is triggered, and after a complete preset delay time interval has elapsed without any new scroll events occurring. The scroll position detection logic includes: obtaining the total scroll height (scrollHeight), scrollbar top distance (scrollTop), and visible area height (clientHeight) of the current scroll area; calculating the distance from the bottom of the scrollbar, which is equal to the total scroll height minus the scrollbar top distance minus the visible area height; comparing the calculated distance with a preset threshold; if it is less than the preset threshold, further executing the data loading judgment step. Through this debouncing mechanism, the number of times the scroll event handling function is executed is reduced, avoiding performance loss caused by high-frequency scroll event triggering.

[0037] S42 When the distance between the scroll bar and the bottom is less than a preset threshold, further determine whether the current state is either data loading or user editing slice state; if neither is present, obtain the batch number of the currently loaded slice; if the current batch number is less than the total number of batches, request the next batch of slice data from the server. Optionally, the step of further determining whether the current state is either data loading or user editing slice state when the distance between the scroll bar and the bottom is less than the preset threshold, and obtaining the batch number of the currently loaded slice; if the current batch number is less than the total number of batches, request the next batch of slice data from the server, includes: setting a data loading status flag (e.g., isLoading), setting the flag to true before requesting data from the server, and setting it to false after the request is completed; setting a user editing slice status flag (e.g., isEditing), setting the flag to true when the user is adding, modifying, or deleting a slice, and setting it to false after editing is completed or canceled. When the scroll bar is less than a preset threshold (e.g., 5 pixels) from the bottom, the system first reads the data loading status flag and the user-edited slice status flag. If either flag is true, the data loading request is prevented to avoid data conflicts or status errors with ongoing operations. If both flags are false, the system obtains the batch number of the currently loaded slice (e.g., currentPage) and calculates the total number of batches based on the total slice data (e.g., totalPage = ceil(totalSliceCount / 30)). The system compares the current batch number with the total number of batches. If the current batch number is less than the total number of batches, a request is sent to the server with parameters including the current batch number plus one or an offset to obtain the next batch of slice data. If the current batch number has reached or exceeded the total number of batches, the request is stopped, and a message indicating that all data has been loaded is generated. This judgment mechanism ensures that the data loading operation is only performed when the system is idle and not yet fully loaded, avoiding duplicate requests and status conflicts.

[0038] In a financial implementation, after a financial analysis platform loads a listed company's annual report document, the second area's slice list defaults to displaying the first 30 slices, such as slices divided by chapter like "Management Discussion," "Financial Data," and "Risk Factors." The first area displays the original text fragment composed of the corresponding first 30 slices. When a financial analyst scrolls down the second area's scrollbar to near the bottom (e.g., the scrollbar is less than 5 pixels from the bottom), the platform detects that 30 slices have been loaded. However, the annual report document, after being parsed by a large language model, generates a total of 150 slices, meaning the total batch size is 5, which is less than all slice data. The platform then requests a second batch of slice data from the server, slices 31 to 60. After receiving the returned data, the platform appends the new slices to the end of the second area's slice list. Simultaneously, the first area, based on all loaded slices, reassembles the first 60 slices in their original order and updates the display. As the analyst continues scrolling to the bottom, the platform detects again and loads the third and fourth batches sequentially until all 150 slices are loaded. Through the aforementioned batch rolling loading mechanism, the financial analysis platform avoids page lag caused by loading all slices at once, ensuring that analysts have a smooth scrolling browsing experience when processing hundreds of annual report slices, and the original text is always updated in sync with the loaded slices, facilitating full-text comparative analysis.

[0039] In an embodiment within the healthcare field, step S40 is specifically implemented as follows: After the medical knowledge management platform loads a clinical trial report document for a drug, the second area's slice list displays the first 30 slices by default, such as slices like "Study Design," "Inclusion Criteria," "Baseline Characteristics," "Adverse Reactions Summary," and "Efficacy Analysis." The first area displays the original text fragment composed of the corresponding first 30 slices. When the clinical researcher scrolls down the scroll bar of the second area to near the bottom, and the scroll bar is less than a preset threshold of 5 pixels from the bottom, the platform detects that the number of currently loaded slices is 30. However, the clinical trial report, after being parsed by the large language model, generates a total of 90 slices, with a total batch number of 3, meaning that not all slice data has been collected. The platform then requests the second batch of slice data, slices 31 to 60, from the server. After receiving the returned data, the platform appends the new slices to the end of the slice list in the second area. Simultaneously, the first area, based on all loaded slices (the first 60), reassembles the original text content according to the order in the original report and updates the display. When the researcher continues scrolling to the bottom, the platform detects and loads the third batch of slices, slices 61 to 90, until all slices are loaded. Through the aforementioned batch-based rolling loading mechanism, the medical knowledge management platform avoids interface lag caused by loading all slices at once, ensuring that researchers have a smooth scrolling browsing experience when reviewing long clinical trial reports containing a large amount of safety data and statistical tables. Moreover, the original text is always synchronized with the loaded slices, making it easy to check the adverse event descriptions against the original data segment by segment.

[0040] The knowledge base document slice parsing method provided in this application further includes: responding to the user completing an editing operation on any of the slices, synchronously updating the storage data corresponding to the slice based on the slice content obtained after the editing operation, and triggering the re-assembly of the original text content in the first area; wherein, the editing operation includes adding, modifying, or deleting slice content. Optionally, the second area provides editing controls for each slice, such as an edit button, a delete button, and an input box for adding slices at the end of the list. When a user performs a modification operation on a slice, the second area component obtains the modified slice content, encapsulates the slice's unique identifier and the modified text content into an update request, and sends it to the backend server. The server updates the slice's storage record in the database. After a successful update, the second area component updates the corresponding slice's text content in the local slice data list and re-renders the slice's display. When a user performs a deletion operation, the second area component sends the slice's unique identifier to the server, and the server deletes the corresponding record. After a successful deletion, the second area component removes the slice from the local slice list. When a user adds a slice, the second region component sends the new slice content and its position in the original document to the server. The server creates a new slice record and returns a unique identifier for the assignment. Upon successful completion, the second region component inserts the new slice into its local slice list in the specified order. After any of the above editing operations are completed, the second region component passes the updated complete slice list (or triggers an event to notify the parent component) to the first region component. The first region component then reassembles the original text content based on the updated slice list, following the order of all slices in the original document, and re-renders the content displayed in the first region. Through this synchronous update mechanism, the user's editing results on the slices are reflected in the corresponding segments of the original text in real time, maintaining consistency between the slice and the original text content.

[0041] In a financial implementation, when a financial analysis platform processes a listed company's annual report, the second area displays a list of slices including "Revenue Analysis," "Reasons for Net Profit Changes," and "Operating Cash Flow." If a financial analyst discovers that data for a specific quarter is missing from the "Revenue Analysis" slice, they can click the edit button for that slice, add the missing quarterly data in the pop-up edit box, and save the changes. The platform obtains the slice's unique identifier and the modified text content, sends an update request to the server, and the server updates the slice's storage record in its database. After a successful update, the second area component updates the corresponding content in its local slice list and re-renders the slice. If an analyst believes the "Operating Cash Flow" slice content is inconsistent with the original, they can delete it. The platform sends the slice's unique identifier to the server, the server deletes the corresponding record, and the second area component removes the slice from the list. Furthermore, analysts can add new slices to the end of the slice list, such as adding an "Accounts Receivable Turnover Analysis" slice. After entering the content and submitting, the server creates a new slice record and returns a unique identifier. The second area component then inserts the new slices into the list in sequence. After any of the above editing operations are completed, the second region component passes the updated complete list of slices to the first region component. The first region component then reassembles the original text content based on the updated slice list, following the original order of all slices in the annual report, and updates the display accordingly. For example, after modifying the "Operating Revenue Analysis" slice, the corresponding operating revenue description paragraph in the original text is simultaneously updated to the modified content; after deleting the "Operating Cash Flow" slice, the corresponding cash flow paragraph in the original text is removed; after adding the "Accounts Receivable Turnover Analysis" slice, the corresponding analysis paragraph is appended to the end of the original text. This editing synchronization mechanism ensures that the financial analyst's corrections to the slices are reflected in the original text in real time, maintaining consistency between the slice data and the displayed original text, facilitating subsequent auditing or review.

[0042] In an embodiment within the healthcare field, when a medical knowledge management platform processes a clinical trial report document for a drug, the second area displays a list of slides including "Patient Inclusion Criteria," "Adverse Reaction Incidence," "Primary Efficacy Endpoint," and "Safety Analysis." When a clinical researcher reviews the "Adverse Reaction Incidence" slide and finds that "abnormal liver function" is missing, they click the edit button for that slide, add the incidence and statistical description of this adverse reaction in the edit box, and save it after confirmation. The platform obtains the unique identifier of the slide and the modified text content, sends an update request to the server, and the server updates the storage record of that slide in its database. After a successful update, the second area component updates the corresponding content in its local slide list and re-renders the slide display. If a researcher believes that some descriptions in the "Safety Analysis" slide are inconsistent with the original data, they can perform a deletion operation. The platform sends the unique identifier of the slide to the server, the server deletes the corresponding record, and the second area component removes the slide from the list. In addition, researchers can add new slides to the end of the slide list, such as supplementing the "Laboratory Test Abnormalities" slide. They can input the number of abnormalities and their clinical significance for the relevant tests, and after submission, the server creates a new slide record and returns a unique identifier. The second regional component then inserts the new slides into the list in sequence. After any of the above editing operations are completed, the second regional component passes the updated complete slide list to the first regional component. The first regional component then reassembles the original text content according to the original order of all slides in the clinical trial report based on the updated slide list and updates the display. For example, after modifying the "Adverse Reaction Incidence" slide, the corresponding adverse reaction description paragraph in the original text is synchronously updated with the supplemented content; after deleting the "Safety Analysis" slide, the corresponding safety analysis paragraph in the original text is removed; after adding a "Laboratory Test Abnormalities" slide, the corresponding abnormality paragraph is appended to the end of the original text. Through this editing synchronization mechanism, it is ensured that clinical researchers' corrections to the slides are reflected in the original text in real time, maintaining consistency between the slide data and the displayed original text, facilitating subsequent data verification or regulatory review.

[0043] As can be seen, the above solution achieves a multi-dimensional visual presentation of document slice content by constructing a three-column display layout that links the original text, slices, and knowledge points simultaneously. Users can view the original text, slices, and knowledge points without switching pages, significantly improving the continuity and efficiency of knowledge retrieval. By establishing a mapping relationship between slices and original text fragments and supporting clicking on slices to highlight the corresponding original text, the traditional manual retrieval or scrolling search method is replaced, improving the accuracy of slice-to-original text verification and ease of operation. By supporting the scaling and adjustment of the width of the first and third areas and adaptively adjusting the width of the second area based on the remaining width, the limitations of fixed layouts are overcome, allowing for flexible adaptation to the viewing needs of complex slices such as long texts and code blocks. By requesting and appending slice data in batches when scrolling to the bottom, combined with the synchronous update of the original text, page lag caused by loading a large number of slices at once is avoided, achieving smooth rendering and performance optimization of the slice list.

[0044] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.

[0045] In one embodiment, a knowledge base document slicing and parsing apparatus is provided, which corresponds one-to-one with the knowledge base document slicing and parsing methods described in the above embodiments. For example... Figure 6 As shown, Figure 6 This is a schematic diagram of a knowledge base document slicing and parsing device according to an embodiment of the present invention. The device includes a layout generation module 61, a width adjustment module 62, a slice mapping module 63, and a scrolling loading module 64. Detailed descriptions of each functional module are as follows: In one embodiment, the layout generation module 61 is specifically used for: The target document is obtained and parsed using a large language model. A three-column layout area is generated in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying the slice list obtained after slicing the original text content, and a third area for displaying the knowledge point information associated with each slice. In one embodiment, the width adjustment module 62 is specifically used for: Based on the user's scaling command for the first area or the third area, adjust the display width of the first area or the third area, and set the display width of the second area according to the adjusted remaining width; In one embodiment, the slice mapping module 63 is specifically used for: Establish a mapping relationship between each slice in the second region and the original text content fragment in the first region, and when the user selects any slice in the second region, highlight the original text content fragment corresponding to that slice in the first region; In one embodiment, the scrolling loading module 64 is specifically used for: When it is detected that the scrolling has reached near the bottom of the current area and the currently loaded slice data has not reached the total number of slice data, the next batch of slice data is requested from the server. The newly received slice data is appended to the slice list of the second area, and the original text content displayed in the first area is updated synchronously.

[0046] In one embodiment, the knowledge base document slicing and parsing device is further configured to: In response to the user completing an editing operation on any of the slices, the storage data corresponding to the slice is updated synchronously based on the slice content obtained after the editing operation, and the original text content in the first region is re-assembled; wherein, the editing operation includes adding, modifying or deleting the slice content.

[0047] This invention provides a knowledge base document slicing and parsing device. The layout generation module obtains the target document after parsing by a large language model and generates a three-column layout area in the display interface, presenting the original text content, slice list, and knowledge point information on the same screen. This solves the problem of single display dimension in the prior art, allowing users to view all three in association without switching pages. The width adjustment module adjusts the width of the third area and resets the width of the second area according to the user's scaling command, breaking through the limitations of fixed layout and flexibly adapting to the viewing needs of complex slices such as long text and code blocks, improving the operational adaptability of the interface. The slice mapping module establishes a mapping relationship between slices and original text fragments, and highlights the corresponding original text fragment when the user selects a slice, replacing the positioning method of manual retrieval or scrolling search, significantly improving the efficiency and convenience of slice and original text verification. The scroll loading module requests and appends slice data in batches and updates the original text content synchronously when it detects that the scroll has reached the bottom and not all data has been loaded, avoiding page lag caused by loading a large number of slices at once, and achieving smooth rendering and performance optimization of long list slices. In summary, this device enables refined viewing, linked analysis, and efficient operation of document slices, making up for the shortcomings of existing technologies that "emphasize slice generation but neglect display and interaction," and improving the user experience and knowledge utilization rate of knowledge base document processing.

[0048] Specific limitations regarding the knowledge base document slicing and parsing device can be found in the limitations of the knowledge base document slicing and parsing method described above, and will not be repeated here. Each module in the aforementioned knowledge base document slicing and parsing device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device in hardware form, or stored in the memory of a computer device in software form, so that the processor can call and execute the operations corresponding to each module.

[0049] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 7 As shown, Figure 7 This is a schematic diagram of a computer device according to an embodiment of the present invention. The computer device includes a processor, memory, network interface, and database connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile and / or volatile storage media and internal memory. The non-volatile storage media stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface is used to communicate with external clients via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a data processing method for insurance business on the server side.

[0050] In one embodiment, a computer device is provided, which may be a client, and its internal structure diagram may be as follows: Figure 8 As shown, Figure 8 This is another schematic diagram of a computer device according to an embodiment of the present invention. The computer device includes a processor, memory, network interface, display screen, and input device connected via a system bus. The processor provides computing and control capabilities. The memory includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The network interface is used to communicate with an external server via a network connection. When the computer program is executed by the processor, it implements the functions or steps on the client side of the method.

[0051] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to perform the following steps: The target document is obtained and parsed using a large language model. A three-column layout area is generated in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying the slice list obtained after slicing the original text content, and a third area for displaying the knowledge point information associated with each slice. Based on the user's scaling command for the first area or the third area, adjust the display width of the first area or the third area, and set the display width of the second area according to the adjusted remaining width; Establish a mapping relationship between each slice in the slice list in the second region and the original text content fragment in the first region. When the user selects any slice in the second region, the original text content fragment corresponding to the slice is highlighted in the first region. When it is detected that the scrolling has reached near the bottom of the current area and the currently loaded slice data has not reached the total number of slice data, the next batch of slice data is requested from the server, the newly received slice data is appended to the slice list of the second area, and the original text content displayed in the first area is updated.

[0052] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, the computer program performing the following steps when executed by a processor: The target document is obtained and parsed using a large language model. A three-column layout area is generated in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying the slice list obtained after slicing the original text content, and a third area for displaying the knowledge point information associated with each slice. Based on the user's scaling command for the first area or the third area, adjust the display width of the first area or the third area, and set the display width of the second area according to the adjusted remaining width; Establish a mapping relationship between each slice in the slice list in the second region and the original text content fragment in the first region. When the user selects any slice in the second region, the original text content fragment corresponding to the slice is highlighted in the first region. When it is detected that the scrolling has reached near the bottom of the current area and the currently loaded slice data has not reached the total number of slice data, the next batch of slice data is requested from the server, the newly received slice data is appended to the slice list of the second area, and the original text content displayed in the first area is updated.

[0053] It should be noted that the functions or steps that can be implemented by the computer-readable storage medium or computer device described above can be referred to the relevant descriptions on the server side and client side in the foregoing method embodiments. To avoid repetition, they will not be described one by one here.

[0054] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0055] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is used as an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0056] It should be noted that any AI models, software tools, or components not belonging to this company appearing in the embodiments of this application are merely illustrative examples and do not represent actual use. All user personal information involved in the embodiments of this application has been authorized (with the knowledge and consent) by the relevant parties or has been fully authorized by all parties, and the executing entity may obtain it through various legal and compliant means. The collection, storage, use, processing, transmission, provision, and disclosure of the information, data, and signals involved all comply with relevant laws and regulations and do not violate public order and good morals.

[0057] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included within the protection scope of the present invention.

Claims

1. A method for parsing knowledge base document slices, characterized in that, include: The target document is obtained and parsed using a large language model. A three-column layout area is generated in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying the slice list obtained after slicing the original text content, and a third area for displaying the knowledge point information associated with each slice. Based on the user's scaling command for the first area or the third area, adjust the display width of the first area or the third area, and set the display width of the second area according to the adjusted remaining width; Establish a mapping relationship between each slice in the slice list in the second region and the original text content fragment in the first region. When the user selects any slice in the second region, the original text content fragment corresponding to the slice is highlighted in the first region. When it is detected that the scrolling has reached near the bottom of the current area and the currently loaded slice data has not reached the total number of slice data, the next batch of slice data is requested from the server, the newly received slice data is appended to the slice list of the second area, and the original text content displayed in the first area is updated.

2. The knowledge base document slicing and parsing method as described in claim 1, characterized in that, The step of adjusting the display width of the first or third region according to the user's scaling command for the first or third region, and setting the display width of the second region according to the adjusted remaining width, includes: Using a grid layout component from the interface component library, the display interface is divided into a preset number of grid units. The three-column layout area occupies all of the grid units. The display width of the first area is adjusted by dynamically configuring the number of columns of the first grid column component corresponding to the first area, and the display width of the third area is adjusted by dynamically configuring the number of columns of the third grid column component corresponding to the third area. The number of columns of the second grid column component corresponding to the second area is equal to the preset number minus the number of columns corresponding to the first area minus the number of columns corresponding to the third area. The display width of the second area is determined based on the number of columns of the second grid column component. When the scaling instruction is that the user clicks the collapse button, the number of columns corresponding to the first area is adjusted to 0 and / or the number of columns corresponding to the third area is adjusted to 0. When the scaling instruction is that the user clicks the expand button, the number of columns corresponding to the first area is restored to the value before adjustment and / or the number of columns corresponding to the third area is restored to the value before adjustment. The change in the number of columns corresponding to the first area and / or the third area causes the display width of the corresponding area to change. During the display width change, the intermediate state is rendered frame by frame through the transition component in the interface component library during the width change process. The adjusted number of columns corresponding to the first area and the third area are stored as width configuration information in local storage. When the display interface is refreshed, the width configuration information is read from the local storage, and the display width of the first area and the third area is reset according to the read number of columns, and the display width of the second area is recalculated and set.

3. The knowledge base document slicing and parsing method as described in claim 1, characterized in that, The step of establishing the mapping relationship between each slice in the second region and the original text content fragments in the first region includes: Each slice is assigned a unique identifier. The original text content displayed in the first area is generated by splicing all slices in the order they appear in the original text content, and each spliced ​​segment is associated with the unique identifier of the corresponding slice. When a user selects any slice, the original text content of the first region is traversed based on the unique identifier of the slice, and a highlight style is added to the document object model element where the identifier matches.

4. The knowledge base document slicing and parsing method as described in claim 3, characterized in that, The original text displayed in the first area is generated by concatenating all slices in the order they appear in the original document, including: Obtain slice data in the second region and transmit the slice data to the first region; The first region iterates through all received slices, concatenates the text content of each slice into a complete Hypertext Markup Language structure, and annotates the text content corresponding to each slice with a tag element bearing the unique identifier of the slice.

5. The knowledge base document slicing and parsing method as described in claim 1, characterized in that, When it is detected that the scrolling has reached near the bottom of the current area and the currently loaded slice data has not reached the total number of slice data, the next batch of slice data is requested from the server, including: A debouncing function is used to reduce the trigger frequency of scrolling events. The distance between the scroll bar and the bottom is calculated. The distance between the scroll bar and the bottom is equal to the total scrolling height minus the distance from the top of the scroll bar minus the height of the visible area. When the distance between the scroll bar and the bottom is less than a preset threshold, it is further determined whether the current state is either data loading or user editing slice state; if neither is the case, the batch number of the currently loaded slice is obtained; if the current batch number is less than the total number of batches, the next batch of slice data is requested from the server.

6. The knowledge base document slicing and parsing method as described in claim 5, characterized in that, The method of using a debouncing function to reduce the triggering frequency of scroll events includes: A delay time interval is set for the debouncing function. When the scrolling event is triggered continuously, the debouncing function resets the timer after each trigger and restarts the timer after each reset. The scrolling position detection and data loading judgment steps are performed only after the delay time interval has elapsed since the last trigger and the timer has not been reset again.

7. The knowledge base document slicing and parsing method as described in claim 1, characterized in that, The method further includes: In response to the user completing an editing operation on any of the slices, the storage data corresponding to the slice is updated synchronously based on the slice content obtained after the editing operation, and the original text content in the first region is re-assembled; wherein, the editing operation includes adding, modifying or deleting the slice content.

8. A knowledge base document slicing and parsing device, characterized in that, include: The layout generation module is used to acquire the target document and parse it using a large language model. It generates a three-column layout area in the display interface. The three-column layout area includes a first area for displaying the original text content of the target document, a second area for displaying the slice list obtained after slicing the original text content, and a third area for displaying the knowledge point information associated with each slice. The width adjustment module is used to adjust the display width of the first area or the third area according to the user's scaling command for the first area or the third area, and to set the display width of the second area according to the adjusted remaining width; The slice mapping module is used to establish a mapping relationship between each slice in the slice list in the second region and the original text content fragment in the first region. When the user selects any slice in the second region, the original text content fragment corresponding to the slice is highlighted in the first region. The scrolling loading module is used to request the next batch of slice data from the server when it detects that the scrolling has reached near the bottom of the current area and the currently loaded slice data has not reached all slice data. The newly received slice data is then appended to the slice list of the second area, and the original text content displayed in the first area is updated.

9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the knowledge base document slicing parsing method as described in any one of claims 1 to 7.

10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the knowledge base document slicing parsing method as described in any one of claims 1 to 7.