Construction of prosodic phrase inventory based on natural pauses in speech and chinese text segmentation system
By constructing a syllable library based on phonological prosody boundaries and adopting a lightweight method using first-character index and range ratio criterion, the problem of the disconnect between phonological facts and textual rules in Chinese text segmentation is solved, achieving text segmentation results with low computational power and high semantic integrity.
Patent Information
- Application Number
- CN202611415444.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-13
- Publication Date
- 2026-11-27
AI Technical Summary
Existing Chinese character text segmentation technologies rely on pure text rules that are disconnected from the natural pauses in native speakers' speech, resulting in the inability to resolve ambiguous segmentations. Furthermore, they suffer from problems such as bloated dictionary size, high computational overhead, high deployment threshold, and fine-grained segmentation that damages semantic integrity.
A lightweight semantic granularity replacement is adopted, using a segment library as the basic processing unit. The segment library is constructed through phonetic prosodic boundary annotation, and deterministic segmentation is performed by combining the first character index and the range ratio criterion. Large-scale pre-training and fine-tuning are omitted, thus constructing a lightweight Chinese character text segment segmentation system.
It achieves text segmentation with low computational power and high semantic integrity, avoids ambiguous segmentation, reduces computational complexity and memory consumption, is suitable for resource-constrained devices, and maintains semantic integrity and consistency of speech facts.
Smart Images

Figure CN123180133A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the fields of Chinese information processing, computer text segmentation, and natural language processing. Specifically, it relates to a basic syllabustrum and its construction method, a method for segmenting Chinese character text syllabuses based on the syllabustrum, a system, and a computer-readable storage medium. Here, a "syllabustrum" refers to a phonetic rhythm unit divided based on natural pauses in the speech flow. It is a text structural level between a "segment" and a "word," and can consist of a single word or a fixed phrase composed of multiple words. It may also include structural particles, dynamic particles, etc., and is a larger semantically complete unit than a traditional "word." Background Technology
[0002] Automatic segmentation of Chinese text (word segmentation) is a fundamental step in Chinese information processing and is widely used in input methods, search engines, machine translation, and post-processing of speech recognition. Existing word segmentation technologies are mainly divided into three categories:
[0003] The first category is the dictionary-based maximum matching method. This method uses a general dictionary as its foundation and performs forward / reverse maximum matching, which is simple to implement but relies on the completeness of the dictionary. The expansion of the dictionary size leads to a decrease in matching speed, and it still cannot cover all out-of-vocabulary words. A typical example is the prefix dictionary-based maximum matching algorithm in the jieba word segmentation system. For instance, Chinese patent CN109388803A, "Chinese Word Segmentation Method and System," discloses a word segmentation scheme based on the fusion of dictionary and rules, but it still suffers from the problems of dictionary expansion and insufficient coverage of out-of-vocabulary words.
[0004] The second category is word segmentation based on statistical models, such as Hidden Markov Models (HMMs) and Conditional Random Fields (CRFs). These require large-scale labeled corpora for training, resulting in high computational costs and making them difficult to run in real-time on resource-constrained devices. For example, Chinese patent CN107861940A, "A Chinese Word Segmentation Method Based on HMM," discloses a technical solution that integrates HMM with a word segmentation dictionary and performs Chinese word segmentation through Viterbi decoding. This method requires estimating the initial state, transition, and emission probability matrices on a large-scale labeled corpus, resulting in long model training times and the need for Viterbi decoding during the inference phase, leading to high computational complexity.
[0005] The third category is word segmentation based on neural networks, such as BiLSTM-CRF and BERT, which have high accuracy but rely on high-performance hardware such as GPUs and are not suitable for lightweight application scenarios. For example, Chinese Patent CN112364623A "Trinitarian Character Tagging Chinese Lexical Analysis Method Based on Bi-LSTM-CRF" discloses a technical solution of building a Bi-LSTM-CRF model and realizing Chinese word segmentation and lexical analysis through multiple iterative trainings. This method eliminates manual feature engineering, but both training and inference rely on the computing power of neural networks. Another example is the Chinese Patent CN109522558B "A Chinese Typo Correction Method Based on Deep Learning", which uses the BiLSTM+Attention+CRF model for word segmentation. Its inference speed on CPU is much lower than that of dictionary matching methods, making it difficult to meet the real-time segmentation requirements of low-end devices.
[0006] In addition, traditional word segmentation takes "words" as the minimum unit, and separately cuts out structural auxiliary words (de, di, de) and dynamic auxiliary words (le, zhe, guo), which leads to fragmented segmentation of a large number of fixed phrases and common collocations with auxiliary words in Chinese (such as "entered", "quickly"), destroys semantic integrity, and increases the ambiguity of subsequent processing.
[0007] Existing segmentation methods based on text rules (including dictionary matching, auxiliary word adhesion rules, regular expressions, etc.) have a fundamental technical blind spot: text rules are artificially formulated grammatical abstractions, while the essence of speech segments is the phonetic fact based on natural pauses in sentences. When text rules conflict with phonetic facts (for example, in "liao que liao wo de yi men xin si", text rules may split "liao que liao" into "liao / que / liao", while phonetic pauses clearly indicate that "liao que liao" is a whole), pure text rules cannot self-consistently resolve such ambiguity. In the prior art, prosodic boundaries are only used in speech processing fields such as speech synthesis and speech recognition, and have never been reused for the offline construction of text speech segment libraries, resulting in a long-term lack of a speech segment discovery mechanism based on phonetic facts in the field of text segmentation.
[0008] In addition, the concept of "token" widely used in the current natural language processing field (usually generated by subword segmentation algorithms such as byte pair encoding BPE and WordPiece) is essentially different from the "speech segment" described in the present invention: token segmentation relies on statistically optimal subword splitting, often splitting "scale" into "scale / ization" and "entered" into "entered / le", with fine granularity and often destroying semantic integrity. However, a "speech segment" is a speech rhythm unit based on the natural speech flow pause of native speakers, whose boundary is objectively determined by phonetic facts. Its granularity is significantly larger than that of tokens, usually covering a complete semantic block, and it is superior to token-level segmentation in both semantic integrity and context discrimination ability.
[0009] The basic processing framework of existing mainstream language models can be summarized as "semantic granularity selection + semantic association calculation": using tokens or subwords as basic processing units, semantic association is determined through probabilistic calculation models such as cosine similarity, and large-scale pre-training and fine-tuning are required before deployment. While this framework performs well in general natural language processing tasks, it has the following inherent limitations: first, fine-grained token / subword segmentation often compromises semantic integrity; second, probabilistic calculation models rely on large-scale training data and high-performance hardware, resulting in high deployment barriers; and third, the large-scale pre-training and fine-tuning stages incur huge computational costs, making them unsuitable for resource-constrained devices. How to maintain the basic processing framework of language models while achieving low-computational-power, high-semantic-integrity text segmentation through lightweight alternatives is a pressing technical problem to be solved in this field. Summary of the Invention
[0010] I. Technical Issues
[0011] The main technical problem that this invention aims to solve is that existing Chinese character text segmentation technologies rely on pure text rules (dictionaries, grammar rules, etc.) to derive segmentation boundaries, which are disconnected from the phonetic facts of natural speech pauses of native speakers, resulting in the inability to resolve ambiguous segmentation.
[0012] Based on this, the present invention further addresses the following technical problems: (1) Dictionary-based methods suffer from dictionary expansion and insufficient coverage of out-of-vocabulary words; (2) Statistical model-based methods have high computational overhead and are difficult to run in real time on resource-constrained devices; (3) Neural network-based methods have high deployment thresholds and rely on high-performance hardware; (4) Traditional word-based segmentation separates structural particles, dynamic particles, etc., resulting in fragmented segmentation of fixed phrases and common collocations, which destroys semantic integrity; (5) Although existing mainstream large language models follow the basic framework of "semantic granularity selection + semantic association calculation", they use token / subword fine granularity, cosin probability calculation and large-scale pre-training, which have problems of semantic integrity destruction, high deployment threshold and high computational overhead, making it difficult to achieve high semantic integrity text segmentation on resource-constrained devices.
[0013] II. Technical Solution
[0014] To solve the above-mentioned technical problems, the present invention adopts the following technical solution:
[0015] This invention follows the same basic processing framework of "semantic granularity selection + semantic association calculation" as mainstream large language models, but it makes lightweight substitutions in three key dimensions: First, it raises the semantic granularity from token / subword to segments, using larger semantic complete units as the basic processing units; Second, to address the problem of the segment database size expansion caused by the increased segment granularity, it compresses millions of global matches to less than a thousand local matches by constructing a first-character index (a segment sequence list split by the first character) from the segment database for comparison calculation; Third, in semantic association calculation, it replaces the probabilistic cosin similarity calculation with a simplified deterministic stepwise range ratio criterion, and omits the large-scale pre-training and fine-tuning required by large models, directly performing deterministic inference based on the pre-constructed segment database.
[0016] This invention constructs a basic syllabustrum, using Chinese character strings as the basic storage and query units. Fields can be added as needed based on the basic fields to match the hardware conditions and memory usage of different devices. It can also serve as a foundational library for downstream natural language processing models and general artificial intelligence language understanding. Based on this basic syllabustrum, this invention provides a low-computing-power, deterministic, and self-maintaining method and system for Chinese character text syllabustrum segmentation.
[0017] The core contribution of this invention lies in its pioneering application of prosodic boundaries (a technique originally belonging to the fields of speech synthesis / speech recognition) to the offline construction of text syllabuse databases. By utilizing standard speech synthesis engines to perform prosodic annotation on large-scale corpora, or by detecting pauses in real audio, prosodic phrase boundaries are extracted as objective criteria for syllabuse segmentation boundaries, thus achieving a paradigm shift of "defining text syllabuses based on speech facts." This cross-domain application solves the problem of the disconnect between pure text rule-based segmentation and the natural pauses of native speakers, ensuring that the content of the syllabuse database naturally aligns with the actual rhythm of language use, while retaining the low-computing-power advantage of lightweight offline segmentation based on local dictionaries.
[0018] (I) Definition and Hierarchical Relationship of Segments
[0019] This invention defines the five-level structural units of Chinese text as follows: sentence (a complete paragraph ending with a period), segment (a text segment within a sentence separated by punctuation), syllable (a unit of speech rhythm within a segment, divided according to natural pauses in the speech flow), word (the smallest independently usable meaningful unit), and character (a unit of pronunciation that constitutes a syllable). The hierarchical relationship of syllables in the text structure is: sentence > segment > syllable > word > character. Therefore, a syllable includes words as well as single characters used independently according to speech pauses.
[0020] (II) Construction of Chinese Character Text Segment Database
[0021] The basic syllabustrum described in this invention uses Chinese character strings as its core field and is primarily used for syllabustrum segmentation of Chinese text. Physically, the syllabustrum is stored in a unified data table and employs a non-saturated design. This non-saturated design means that the syllabustrum has a maximum capacity and does not aim to exhaustively include all possible polysyllabic combinations. Because unmatched consecutive multi-character combinations are automatically treated as new syllabustrum outputs during segmentation, the syllabustrum does not need to cover all syllabuses in the text to complete the segmentation (for example, if the text contains 3 syllabuses, only 2 need to be matched, and the remaining unmatched consecutive single characters are automatically combined into new syllabuses for output). Furthermore, a self-maintaining mechanism dynamically maintains a high-hit-rate active syllabustrum set.
[0022] The construction of the syllable database can begin with a list of commonly used polysyllabic words published by a national authoritative institution as an initial seed. Based on this, the following prosodic boundary extraction method can be used to discover polysyllabic fixed syllables not covered by the word list and dictionary on a large scale, and then dynamically expand the database through a self-maintenance mechanism.
[0023] The syllabustrum is constructed through two paths, both of which are equal in status. Implementers can choose one path to use based on their available data, or they can use both paths simultaneously:
[0024] Path 1 (Prosodic annotation based on speech synthesis engine): Call the application programming interface (API) of a standard speech synthesis engine (TTS) with prosodic phrase prediction and annotation capabilities to perform batch prosodic annotation on the corpus, extract prosodic phrase boundaries, and map the boundaries to candidate segmentation positions at the text level.
[0025] Path 2 (pause detection based on real audio): For scenarios with existing human-read audio and its transcribed text, use the silence detection algorithm (Voice Activity Detection, VAD) or the fundamental frequency / short-time energy threshold detection algorithm in the existing speech recognition toolkit to identify pause positions from the audio waveform and map them as candidate segmentation boundaries.
[0026] The main fields of the basic segment library include: segment character string (core field, required), segment length, usage frequency count, and most recent hit time. Based on this, the segment library supports on-demand expansion of speech feature fields (such as pinyin strings, pronunciation duration, prosodic boundary markers, etc.); further, it can be expanded into a multimodal segment library, adding additional fields such as image feature fields, video feature fields, and semantic vector fields. These extended fields can be flexibly added or omitted according to the application scenario without affecting the core structure and segmentation mechanism of the segment library. In pure text segmentation applications, only the segment character string field is needed; the extended fields such as speech feature fields are for use in extended scenarios such as voice input, and their specific implementation methods can be determined by those skilled in the art based on the actual application scenario.
[0027] The basic syllabustrum is set to include syllabuses ranging from 2 to 7 Chinese characters in length: newly added syllabuses are automatically added within this range; excessively long candidate syllabuses exceeding 7 characters are removed during the filtering phase; fixed collocations exceeding this length range are manually maintained and supplemented. The linguistic basis for the upper limit of 7 Chinese characters is as follows: based on research on prosodic phrases in modern Chinese, the typical length of prosodic phrases in natural Chinese speech is 2 to 7 syllables. Continuous text exceeding 7 characters has low frequency of use and usually spans multiple prosodic phrases, thus it can be segmented into smaller prosodic phrase units. The basic syllabustrum used for plain text syllabustrum segmentation only includes fixed syllabuses of 2 to 7 characters (excluding those manually added), and does not include monosyllabic syllabuses. The reason is that the segmentation measure is for syllables of two or more, and there is no situation where single characters are used to segment single characters; single characters are automatically output as fallback units during the segmentation process and do not need to be pre-added to the database.
[0028] (III) Segmentation Method of Chinese Character Text Based on Segment Database
[0029] A long-segment-first matching strategy is adopted, processed in a three-level structure: first, the text is divided into sentences by periods; then, sentences are divided into segments by punctuation marks; finally, segments are segmented within each segment based on the first-character index. The first-character indexing mechanism uses the first character of a segment as the key and the segment length as the order, splitting the segment database into several candidate subsets based on the first character. During segmentation, only the candidate subset corresponding to the current first character needs to be extracted and matched in descending order of length, without traversing the entire segment database, thus significantly reducing the candidate set, typically to below a thousand characters, significantly reducing computational complexity. After a segment is segmented, the first-character pointer moves to the next unsegmented character, and matching is performed cyclically until the end of the segment.
[0030] Secondary First Syllable Backtracking Segmentation Mechanism: To address potential ambiguities arising from prioritizing long syllable matching, a secondary first syllable backtracking segmentation strategy is introduced. The first range ratio of syllable lengths in the first round of segmentation results is calculated; this is the ratio of the longest syllable length to the shortest syllable length within the same segment. If this first range ratio exceeds a predetermined average segmentation threshold, the first syllable of the current segment is automatically replaced with the second longest candidate syllable from the syllable database that begins with that first character, and the entire segment is re-segmented in a second round. This mechanism performs only one backtracking step, comparing only the first and second round segmentation results, and does not perform a third round of segmentation.
[0031] The comparison of the two rounds of segmentation results is performed according to the following two-level criteria: First, the ratio of the first range of the two rounds is compared, and the round with the smaller ratio is taken as the final output. Second, if the ratios of the first ranges of the two rounds are equal, the ratio of the second range of the two rounds (i.e., the ratio of the longest syllable length to the second shortest syllable length) is compared, and the round with the smaller ratio is taken as the final output. If the ratios of the second ranges of the two rounds are also equal, the segmentation result of the first round is used. This mechanism can reduce the probability of ambiguity.
[0032] The linguistic basis for the aforementioned range ratio criterion is as follows: According to research on prosodic phrases in modern Chinese, the smaller the range ratio of adjacent syllables within the same segment, the more evenly the syllable lengths are distributed, and the more it conforms to the probability distribution pattern of prosodic phrases in natural Chinese speech flow. Conversely, an excessively large range ratio means that the segmentation boundary may fall within a complete prosodic phrase, leading to fragmented segmentation with uneven lengths. Therefore, using the range ratio as a criterion for the rationality of segmentation is essentially a deterministic semantic association calculation based on the facts of modulation, replacing the probabilistic cosine similarity calculation in mainstream large language models.
[0033] The predetermined segmentation threshold is preferably 2.5. This threshold is based on research on prosodic phrases in modern Chinese: the typical length of a prosodic phrase in natural Chinese speech is 2 to 7 syllables, and the length difference between adjacent prosodic phrases within the same segment usually does not exceed 2.5 times; exceeding this threshold usually means that the segmentation boundary falls within the prosodic phrase, causing a complete prosodic phrase to be split into segments of uneven lengths, requiring backtracking correction. Those skilled in the art can also adjust this threshold within the range of 2.0 to 3.0 according to the actual application scenario.
[0034] Two or more consecutive single-character combinations that fail to match within a segment are considered as new syllables and output as syllable units; the segmented single characters (with both preceding and following multi-syllable syllables) are also output as single-character syllables.
[0035] (iv) Self-maintenance and update mechanism of syllable database
[0036] The segment library has a capacity limit (e.g., 1 million entries). During the segment segmentation process, if an unmatched consecutive multi-character combination is generated within a segment and its length does not exceed a predetermined length threshold (7 Chinese characters), it will be automatically processed by the machine and directly added to the segment library, with a usage frequency recorded as 1. When the limit is reached and there are still new segments to be added to the library, the machine will automatically eliminate them according to usage frequency and most recent hit time (LRU principle): first, they are sorted in ascending order of usage frequency, and those with the same usage frequency are sorted in ascending order of most recent hit time. The segments ranked first are eliminated to make room for new segments.
[0037] Fixed phrases exceeding the predetermined length threshold (7 Chinese characters) are manually maintained and supplemented, and are not subject to the length limit for automatic database entry; syllables of 7 characters or less are processed automatically by the machine, and can only be added after the above-mentioned elimination mechanism is automatically executed when the database is full. Manual maintenance can also pre-add or subsequently add emerging fixed phrases.
[0038] (v) Design of Extensible Fields in the Basic Segment Library
[0039] The basic segment library constructed in this invention has a minimum configuration containing only a segment character string field (excluding speech fields and other extended fields). It is suitable for lightweight scenarios requiring only segmentation of Chinese text, minimizing the memory footprint of the segment library. Based on the aforementioned core fields, the segment library can be extended as needed with speech feature fields (such as pinyin strings, pronunciation duration, prosodic boundary markers, etc.), image feature fields, video feature fields, semantic vector fields, etc., to support extended scenarios such as voice input, multimodal processing, or general artificial intelligence. The specific implementation of these extended fields can be determined by those skilled in the art based on actual application scenarios and does not affect the core structure and segmentation mechanism of the segment library of this invention; the difference lies only in the set of fields included. Those skilled in the art can flexibly extend fields on top of the basic segment library according to the actual device's memory capacity, computing power, and task requirements, without changing the core data structure and segmentation algorithm of the segment library.
[0040] Furthermore, specialized domain-specific domain-specific domain-specific domain-specific domain-specific domains (such as medical, legal, and financial domains) can be added on top of this basic domain-specific ...
[0041] III. Beneficial Effects
[0042] (1) Low computing power and high matching efficiency: Based on the pre-built segment library, string matching and segmentation does not require statistical models or neural networks; through the first character index and length filtering mechanism, global matching is transformed into local matching of candidate sets below a thousand, and the matching speed reaches the millisecond level.
[0043] (2) Determinism: The segmentation result is completely determined by the content of the segment library and the matching algorithm, and there is no randomness of the probability model.
[0044] (3) Semantic integrity: Using syllabuses rather than words as the segmentation unit, the long syllabuse priority strategy and the syllabuse library pre-constructed by large-scale prosodic boundaries naturally cover common collocations with auxiliary words, avoiding the fragmentation of fixed phrases and common collocations.
[0045] (4) Consistency of phonetic facts: By applying the cross-domain transfer of phonetic prosody boundaries to the offline construction of the syllable library, the content included in the syllable library naturally conforms to the phonetic facts of native speakers’ natural speech flow pauses, fundamentally avoiding the problem of ambiguous segmentation caused by the disconnect between text rules and phonetic facts.
[0046] (5) Controllable scale: The syllable database adopts a non-saturated design with a capacity limit and elimination mechanism. It does not pursue the exhaustive inclusion of all possible polysyllabic combinations, thus avoiding the unlimited expansion of the lexicon's scale.
[0047] (6) Self-maintainable: The syllable library supports online self-maintenance and updates. Unmatched multi-character combinations are automatically added to the library. Self-selection is achieved through the natural accumulation of frequencies within the library and the last-place elimination mechanism.
[0048] (7) No blind spots in segmentation: The mechanism of backing down the second first syllable, the mechanism of automatically treating unmatched multi-character combinations as new syllables, and the mechanism of backing down the single character output when the match fails, work together to ensure that any text can be completely segmented.
[0049] (8) Scalability: The basic syllabustrum supports adding fields (such as speech, alphabetic pinyin, images, videos, semantic vectors, etc.) and external professional syllabustrums on the basis of core fields as needed, taking into account both generality and accuracy in professional fields.
[0050] (9) Memory economy: The minimum required fields of the segment library are adapted according to the task, so that the same segment library system can run on memory-constrained embedded devices and can also be extended to a general AI multidimensional segment library, maximizing the matching of device memory usage economy. Attached Figure Description
[0051] Figure 1 : Diagram of syllable hierarchy.
[0052] Figure 2 Flowchart for building a syllabary library.
[0053] Figure 3 : A schematic diagram of the data structure of the Chinese character text segments library.
[0054] Figure 4 Flowchart of text segmentation mechanism.
[0055] Figure 5 Flowchart of the syllabary self-maintenance mechanism. Detailed Implementation
[0056] The present invention will now be described in further detail with reference to the accompanying drawings and specific embodiments.
[0057] The application scenario of this invention is Chinese character text segmentation. In this scenario, the segment library only loads the core fields of the Chinese character string of the segment and basic fields such as length, frequency, and hit time, omitting the speech feature fields and other extended fields, thereby minimizing memory usage.
[0058] Example 1: Definition and Hierarchical Relationship of Segments
[0059] like Figure 1As shown, the present invention defines five-level structural units of Chinese character text as follows: sentence (a complete segment of text ending with a period), paragraph (a text segment separated by punctuation marks within a sentence), speech segment (a speech rhythm unit divided based on natural pauses in the speech flow within a paragraph), word (the smallest meaningful unit that can be used independently), and character (a pronunciation unit constituting one syllable). The hierarchical relationship of speech segments in the text structure is: sentence > paragraph > speech segment > word > character.
[0060] For example, in the sentence "The development speed of Chinese science and technology has entered a new era.": divided by the period, the entire sentence is a sentence; there is no paragraph separator within the sentence, so the sentence contains one paragraph: "The development speed of Chinese science and technology has entered a new era"; the speech segment segmentation result is: Chinese science and technology / development speed / has entered / a new era. Among them, the speech segment "Chinese science and technology" is composed of three words "China", "science and technology", and "of"; the speech segment "development speed" is composed of two words "development" and "speed"; the speech segment "has entered" is composed of two words "enter" and "has"; the speech segment "a new era" is composed of two words "new" and "era".
[0061] As mentioned above, the basic speech segment library only includes multi-syllable fixed speech segments with two or more syllables, and single-character units in the segmentation output are not included in the speech segment library storage.
[0062] Embodiment 2: Construction of the speech segment library
[0063] As Figure 2 shown, this embodiment applies the prosody boundary extraction technology originally used for speech synthesis and speech recognition to the offline construction of the speech segment library across domains. The traditional text segmentation field relies on text rules (dictionaries, grammar rules, etc.) to "deduce" speech segment boundaries, while this embodiment directly uses the prosody annotation results of large-scale corpora from the speech synthesis engine or the pause detection results in real audio to "discover" speech segment boundaries. Since prosody boundaries reflect the real pause habits of native speakers in natural speech flow, the speech segments obtained in this way naturally fit the linguistic essence of "speech segments", fundamentally solving the problem of ambiguous segmentation caused by the disconnection between text rules and speech facts.
[0064] The basic speech segment library constructed by the present invention is physically stored using a unified data table, adopting the unsaturated design as described above.
[0065] The specific steps are as follows:
[0066] S201: Constructing the initial seed syllable database. The primary data source is the *List of Commonly Used Modern Chinese Words (2nd Edition)*, compiled by the Ministry of Education and the State Language Commission and published by the Commercial Press in 2021. This list is based on a corpus of 250 million characters of modern Chinese. Entries were determined through word frequency statistics and multiple rounds of expert screening, resulting in 56,790 commonly used modern Chinese words that meet the criteria of being "general, frequently used, and linguistically relevant." All disyllabic or longer words were extracted from this list as a candidate syllable set. 3,149 monosyllabic words were excluded because the segmentation measure is disyllabic or longer; there is no situation where single characters are used to segment single characters, and single characters are automatically output as backoff units during the segmentation process, requiring no pre-entry into the database. Through this step, the candidate set contains 40,924 disyllabic words, 6,583 trisyllabic words, 5,966 tetrasyllabic words, and 168 pentasyllabic or higher words, totaling approximately 53,600 entries, serving as the initial seed for the syllable library. It should be noted that this initial seed library only contains dictionary-level entries (i.e., "words"), while the syllables described in this invention are rhythmic units larger than words (such as multi-word fixed collocations like "entered," "Chinese science and technology," and "our company"). These multi-word fixed syllables are not found in any dictionary and need to be discovered through the prosodic boundary extraction methods in subsequent steps S203 to S206, and dynamically expanded through a self-maintenance mechanism.
[0067] S202: Acquire large-scale corpora. Acquire texts from modern vernacular Chinese corpora, such as the Beijing Language and Culture University CNC Modern Chinese Corpus, as the basic corpus for syllable (phonological pauses, prosodic boundaries) extraction.
[0068] S203: Prosody Markup and Boundary Extraction. This step can be achieved through one of two approaches, both of which are equally important. Implementers can choose one based on available data, or they can use both approaches simultaneously:
[0069] Path 1 (Prosodic Annotation Based on Speech Synthesis Engine): The application programming interface (API) of a standard speech synthesis engine with prosodic phrase prediction and annotation capabilities is called. The corpus text is input into the engine in batches, and the prosodic level annotation data returned by the engine is obtained. Prosodic phrase boundary information is extracted from this data. The speech synthesis engine is an existing commercial or open-source TTS engine (such as iFlytek Speech Synthesis, Baidu Speech Synthesis, Google Cloud Text-to-Speech, Azure TTS, etc.), and should have the ability to predict and annotate at least two levels of prosodic words and prosodic phrases. This embodiment does not depend on a specific engine; any standard TTS engine with a prosodic boundary output interface is applicable. The prosodic annotation data returned by the engine typically includes the start and end times of each prosodic unit and prosodic level markers (such as break time or prosodic break intensity level). Positions where the intensity level reaches a preset threshold (such as break time ≥ 200ms or the phrase-level boundary annotated by the engine) are determined as segment segmentation boundaries.
[0070] Preferably, to ensure boundary reliability, a multi-engine cross-validation strategy can be adopted: simultaneously calling two or more independent speech synthesis engines, and only taking the prosodic phrase boundaries that are consistent in the output of each engine as valid boundaries.
[0071] Path Two (Pause Detection Based on Real Audio): For scenarios with existing human-read audio and its transcribed text, utilize existing speech recognition toolkits (such as Kaldi, WeNet, and WebRTC VAD) with silence detection algorithms (VoiceActivity Detection, VAD) or fundamental frequency / short-time energy threshold detection algorithms to identify pause positions from the audio waveform. Map these pause positions to the corresponding Chinese character boundaries in the text, using them as prosodic pause boundaries. This path is suitable for data service providers that already possess broadcast-quality reading corpora.
[0072] S204: Text Boundary Mapping. The timestamp information of the prosodic phrase boundaries (or pause positions detected in path two) is mapped to the corresponding Chinese character positions in the text to determine the candidate syllable segmentation boundaries at the text level. Specifically, the alignment information between the phonemes or syllables returned by the engine and the text characters is used, or the audio timeline is aligned with the text transcription timeline to convert the timestamps into Chinese character index positions.
[0073] S205: Generate candidate segments. Based on the candidate segmentation boundaries, the corpus text is segmented into several candidate segment sequences. A continuous sequence of Chinese characters between two adjacent prosodic phrase boundaries (or pause boundaries) is marked as a candidate segment.
[0074] S206: Filtering and Denoising. Candidate syllables are filtered: monosyllabic candidate syllables are removed (single characters are not included in the database); duplicate entries are removed; items that clearly do not conform to the syllable granularity definition are removed (such as excessively long continuous text spanning sentences and exceeding a predetermined length threshold). The predetermined length threshold is 7 Chinese characters. Based on research on prosodic phrases in modern Chinese, the typical length of a prosodic phrase in natural Chinese speech is 2 to 7 syllables. Continuous text exceeding 7 characters usually spans multiple prosodic phrases and can be divided into smaller prosodic phrase units.
[0075] Through the above steps, the syllabustrum expands from the initial seed of approximately 53,600 syllabuses to a total size of 1 million or even several million syllabuses. This scale is fully achievable within the memory resources of modern computer systems, and through initial character indexing and length filtering mechanisms, global matching is transformed into local matching of candidate sets below a thousand, enabling millisecond-level query responses.
[0076] like Figure 3 As shown, the main fields of the syllabustrum include: syllabustrum character string (core field, required), syllabustrum length, frequency count, and most recent hit time. Based on this, the syllabustrum supports on-demand expansion of speech feature fields (such as pinyin strings, pronunciation duration, prosodic boundary markers, etc.), as well as additional fields such as pure alphabetic pinyin string fields, image feature fields, video feature fields, and semantic vector fields. These extended fields can be flexibly selected according to the application scenario without affecting the core structure and segmentation mechanism of the basic syllabustrum. This embodiment only uses the syllabustrum character string field for text segmentation; the other extended fields are as described above.
[0077] Example 3: A Chinese Character Text Segmentation Method Based on a Segment Library
[0078] like Figure 4 As shown, the present invention employs the following steps to segment Chinese text into segments:
[0079] S401: Constructing the first-character index of the syllabustrum. Using the first Chinese character of each syllabustrum as the index key, a mapping relationship is established between the first character and the syllabustrum list. The syllabustrum list corresponding to each first character is sorted from longest to shortest. This mechanism splits the syllabustrum (which can contain hundreds of thousands or even millions of entries) into several candidate subsets based on the first character. The number of candidate syllabuses corresponding to each first character is typically less than a thousand. During the segmentation process, only the corresponding subset needs to be extracted based on the current first character for local matching, without traversing the entire syllabustrum. This significantly reduces the candidate set, significantly reduces computational complexity, and ensures real-time response on low-computing-power devices.
[0080] S402: Divide the Chinese text to be processed into several sentences by using periods ".".
[0081] S403: For each sentence, divide it into several segments according to punctuation marks (comma, pause mark, semicolon, colon, question mark, exclamation mark, etc.), and retain the punctuation marks as independent units.
[0082] S404: For each segment, scan starting from the first character. Let the character at the current position be C, and the remaining length from the current position to the end of the segment be L.
[0083] S405: In the initial character index, extract all syllabuses that start with C and whose length does not exceed L, and form a candidate syllabuse list arranged from longest to shortest syllabuse length.
[0084] S406: Take the segments from the candidate segment list in sequence and compare them at the current text position: If the match is successful, the segment is cut out as a segment unit, and the text pointer moves forward by the number of characters cut out accordingly; if no match is found after traversing the candidate segment list, the current character C is temporarily recorded as a single character unit, and the text pointer moves forward by one Chinese character.
[0085] S407: Repeat steps S404 to S406 until the end of the passage.
[0086] S408: Calculate the first range ratio of the lengths of each segments in the first round of segmentation, i.e., the ratio of the longest segment length to the shortest segment length; if the first range ratio exceeds a predetermined average segmentation threshold (preferably 2.5), trigger the second round of segmentation: in the first character index, extract the next candidate segment that starts with the first character of the segment and is shorter than the first segment of the first round of segmentation as the first segment of the second round of segmentation, and re-execute the segmentation steps S406 to S407 to obtain the second round of segmentation results. This mechanism only performs one backtracking, that is, only compares the first round and the second round of segmentation results, and does not perform a third round of segment backtracking segmentation. If the first round of segmentation results contains only one segment, a second backtracking is not triggered, and the result is directly output.
[0087] S409: Compare the segmentation results of the two rounds and select the final output according to the following two-level criteria: First level: compare the first range ratio of the two rounds and take the round with the smaller first range ratio; Second level: if the first range ratios of the two rounds are equal, then compare the second range ratios of the two rounds, that is, the ratio of the length of the longest syllable to the length of the second shortest syllable, and take the round with the smaller second range ratio; if the second range ratios of the two rounds are also equal, then take the segmentation result of the first round.
[0088] S410: Treat two or more consecutive single-character combinations in the segmentation sequence as a new syllable, wherein the length of the new syllable does not exceed a predetermined length threshold (7 Chinese characters).
[0089] S411: Outputs a sequence of segmented results at the syllable unit level, with syllables separated by spaces and the original punctuation marks marked at the end of each segment.
[0090] S412: Process the next paragraph until the sentence ends, then process the next sentence until the entire text ends.
[0091] Example 4: Self-maintenance and update mechanism of syllable library
[0092] like Figure 5 As shown, the syllable library of this invention supports both online self-maintenance and manual maintenance. The automatic maintenance mechanism is as follows:
[0093] S501: Capacity Monitoring and Upper Limit Setting. Sets an upper limit for the syllable library capacity (based on system resource configuration, such as 1 million entries or higher). Monitors the total number of entries in the current syllable library in real time.
[0094] S502: Direct insertion into the database. Unmatched multi-character combination segments generated during segment segmentation, if their segment length (number of Chinese characters) does not exceed the predetermined length threshold (7 Chinese characters), are directly added to the segment database, and their usage frequency is recorded as 1.
[0095] S503: Sort by frequency in ascending order, and sort by time for syntactic segments with the same frequency. When the syntactic library capacity reaches its limit and there are still new syntactic segments to be added, sort them in ascending order by usage frequency (number of times the segments are hit), and sort them in ascending order by the most recent hit time for syntactic segments with the same usage frequency.
[0096] S504: Eliminate low-frequency last-position syllables. Eliminate the syllable that ranks first in the sequence (the least frequently used and the longest unused syllable) to make room for new syllables.
[0097] S505: Add new syllables. Add new syllables to the syllable database, and record their frequency as 1.
[0098] Fixed phrases exceeding a predetermined length threshold (7 Chinese characters) are manually maintained and supplemented, and are not subject to the length limit for automatic database entry; syllables of 7 characters or less are processed automatically by the machine, and the above-mentioned elimination is automatically performed when the database is full. Manual maintenance can also pre-supplement or subsequently supplement emerging fixed phrases.
[0099] Example 5: Segment Segmentation Example
[0100] Example 1: Direct hit of high-frequency speech segments. Input text: "Our company has achieved the annual target." The sentence is divided according to the period, and the whole sentence is one utterance. There is no segment separator in the utterance, so it is one segment: "Our company has achieved the annual target". The first character index extracts a candidate list starting with "I" and with a length ≤7, and the longest match "our company" (4 characters) → hit. The pointer moves to "has achieved the annual target", with the first character "has", extracts a candidate list starting with "has" and with a length ≤7, and the longest match "has achieved" (3 characters) → hit. The pointer moves to "annual target", with the first character "annual", extracts a candidate list starting with "annual" and with a length ≤7, and the longest match "annual target" (4 characters) → hit. Speech segment segmentation: our company / has achieved / annual target.
[0101] Example 2: Ambiguity resolution. Input text: "I have completely set my mind at rest." Segment: "I have completely set my mind at rest". The first character is "have", the candidate list is extracted, and the longest match "have completely" (3 characters) → hit. The pointer moves to "my mind at rest", with the first character "my", extracts the candidate list, and the longest hit "my" (2 characters) → hit. The pointer moves to "mind at rest", with the first character "mind", extracts the candidate list, and the longest match "mind at rest" (4 characters) → hit. Speech segment segmentation: have completely / my / mind at rest.
[0102] Example 3: Secondary fallback segmentation. Text input: "Nanjing Yangtze River Bridge, Jiangsu Province"
[0103] Step S1: First matching
[0104] The pointer points to the first character "river", and the longest match "Mayor of Nanjing, Jiangsu Province" (7 characters) → matching is successful, and "Mayor of Nanjing, Jiangsu Province" is segmented. The pointer moves to "Yangtze River Bridge".
[0105] The pointer points to the first character "river", and the candidate list is empty or there is no match → the single character "river" is segmented. The pointer moves to "Bridge".
[0106] The pointer points to the first character "bridge", and the longest match "Bridge" (2 characters) → matching is successful. Segment out "Bridge".
[0107] First segmentation result: [Mayor of Nanjing, Jiangsu Province] [river] [Bridge]
[0108] Speech segment length ratio: 7:1:2
[0109] First extreme difference ratio: 7 ÷ 1 = 7
[0110] Step S2: The first extreme difference ratio 7 > 2.5 (predetermined uniform segmentation threshold), triggering the second round of fallback segmentation for the first speech segment.
[0111] Step S3: Second round of fallback segmentation for the first speech segment
[0112] Reset the pointer to the start of the segment "Jiang".
[0113] Select the second longest phrase starting with "Jiang": "Nanjing City, Jiangsu Province" (6 characters).
[0114] Take "Nanjing City, Jiangsu Province" as the first phrase and restart matching:
[0115] Segment out "Nanjing City, Jiangsu Province". Move the pointer to "Yangtze River Bridge", with the first character "Chang". The longest match is "Yangtze River Bridge" (4 characters) → matching successful. Segment out "Yangtze River Bridge".
[0116] Second-round segmentation result: [Nanjing City, Jiangsu Province] [Yangtze River Bridge]
[0117] Phrase length ratio: 6:4
[0118] First extreme difference ratio: 6÷4=1.5
[0119] Step S4: Compare the two rounds of segmentation results. First-round first extreme difference ratio: 7; second-round first extreme difference ratio: 1.5. 1.5<7, so the second-round segmentation result wins.
[0120] Final output: Nanjing City, Jiangsu Province Yangtze River Bridge
[0121] Example 4: Unmatched multi-character combination. Input text: "Architect Li Yusheng." Segment: "Architect Li Yusheng". First character "Li". Extract the candidate list starting with "Li" and with length ≤7: no match. Temporarily record "Li" as a single character. First character "Yu". Extract the candidate list starting with "Yu" and with length ≤7: no match. Temporarily record "Yu" as a single character. First character "Sheng". Extract the candidate list starting with "Sheng" and with length ≤7: no match. Temporarily record "Sheng" as a single character. First character "Jia". Extract the candidate list starting with "Jia" and with length ≤7: match "Architect" (3 characters). Combine consecutive single characters: "Li", "Yu", "Sheng" into a new phrase "Li Yusheng"; final output: Li Yusheng / Architect. Store the new phrase "Li Yusheng" in the database, with the initial frequency recorded as 1.
[0122] Embodiment 6: Database full elimination scenario
[0123] Assume the capacity of the syllable database has reached its upper limit of 1 million entries, and a new syllable "Li Yusheng" is generated during the syllable segmentation process (the syllable length is 3 Chinese characters, which does not exceed the predetermined length threshold of 7 Chinese characters, and meets the inclusion rules of the syllable database: the syllable database only includes multi-syllable fixed combinations with two or more syllables, and independent single-character units are not included in the syllable database storage). According to the syllable database maintenance mechanism, when the database is full, adding a new syllable requires first eliminating the last syllable with the lowest frequency in the database: arrange the syllables in ascending order of usage frequency, and those with the same usage frequency are arranged in ascending order of most recent hit time, find the syllable ranked first (i.e., the one with the lowest usage frequency and the longest time since last hit), eliminate it, and free up space for "Li Yusheng" to be stored in the database. The initial frequency of "Li Yusheng" after being stored in the database is recorded as 1, and the most recent hit time is also recorded at the same time.
Claims
1. A method for constructing a Chinese character text syllabustrum, characterized in that, Includes the following steps: Obtain modern Chinese text corpus; Prosodic annotation is performed on the corpus text to obtain prosodic phrase boundary information; the prosodic annotation is implemented by calling the application programming interface of a speech synthesis engine with prosodic phrase prediction and annotation capabilities, or by performing silence segment detection or fundamental frequency / short-time energy threshold detection on human-read audio. The timestamp information of the prosodic phrase boundary is mapped to the Chinese character position of the corresponding text to determine the candidate segment segmentation boundary; Based on the candidate segmentation boundaries, consecutive Chinese character sequences between adjacent boundaries are marked as candidate segments; The candidate syllabuses are filtered by removing monosyllabic candidate syllabuses, removing duplicate entries, and removing excessively long candidate syllabuses that exceed a predetermined length threshold, thus obtaining a syllabuse library.
2. The construction method according to claim 1, characterized in that, Before acquiring the modern Chinese corpus text, the process also includes the step of constructing an initial seed syllabus: using a list of commonly used modern Chinese words as the data source, all disyllabic and above words are extracted as initial seed syllabus, while monosyllabic words are not included; the syllabus is designed to be non-saturated, with a set capacity limit, and does not aim to exhaustively include all possible polysyllabic combinations. Its fields include the Chinese character string of the syllabus, syllabus length, usage frequency count, and most recent hit time, and the speech feature fields are expanded as needed; The initial seed syllabustrum is dynamically expanded through subsequent prosodic boundary extraction steps.
3. The construction method according to claim 1, characterized in that, The prosodic annotation by calling the speech synthesis engine includes: calling two or more independent speech synthesis engines at the same time, and taking only the prosodic phrase boundary that is consistent in the output of each engine as the valid boundary; the predetermined length threshold is 7 Chinese characters. Based on the research of prosodic phrases in modern Chinese, the typical length of prosodic phrases in natural Chinese speech is 2 to 7 syllables, and continuous text with more than 7 Chinese characters usually spans multiple prosodic phrases.
4. A method for segmenting Chinese character text based on a syllabustrum, characterized in that, Includes the following steps: Construct the first character index of the syllabustrum: Using the first Chinese character of each syllabustrum as the index key, establish a mapping relationship from the first character to the list of syllabuses arranged in descending order of syllabustrum length; The text to be processed is divided into several sentences by periods, and each sentence is divided into several segments by punctuation marks. For each segment, start scanning from the first character, extract a list of candidate segments that begin with the current character and whose length does not exceed the remaining length, and match them in descending order of length; if a match is successful, the segment is cut out and the pointer is moved forward; if a match fails, the current character is recorded as a single character unit and the pointer is moved forward one character. Calculate the first range ratio of the length of each segments in the first round of segmentation results, which is the ratio of the length of the longest segment to the length of the shortest segment; if the first range ratio exceeds the predetermined average segmentation threshold, extract the second longest candidate segment starting with the first character of the segment as the first segment, and re-segment to obtain the second round of segmentation results; only perform one rollback, and do not perform a third round of segmentation; Compare the segmentation results of the two rounds and select the final output according to the following two-level criteria: First level: compare the first range ratio of the two rounds and take the round with the smaller first range ratio; Second level: if the first range ratios of the two rounds are equal, compare the second range ratio of the two rounds, that is, the ratio of the length of the longest syllable to the length of the second shortest syllable, and take the round with the smaller second range ratio; if the second range ratios of the two rounds are also equal, take the segmentation result of the first round. Two or more consecutive word combinations in the segmentation sequence are considered as new syllables for output.
5. The segmentation method according to claim 4, characterized in that, The first-character index divides the syllable library into several candidate subsets based on the first character. The number of candidate syllables corresponding to each first character is less than a thousand. During segmentation, only the candidate subset corresponding to the current first character is extracted for local matching. The re-segmentation includes: resetting the pointer to the beginning position of the segment, segmenting the remaining text with the second longest candidate syllable as the first syllable, and then re-performing the step of descending length matching on the remaining text. The predetermined average segmentation threshold is 2.5, which can be adjusted by those skilled in the art within the range of 2.0 to 3.
0.
6. The segmentation method according to claim 4, characterized in that, The segment library is a segment library constructed according to any one of claims 1 to 3; the segmentation result is output at the granularity of segment units, segments are separated by spaces, and the original punctuation marks are marked at the end of the segment.
7. A self-maintaining and updating method for a syllable library, characterized in that, Includes the following steps: In the process of segmenting Chinese text based on a syllabustrum, consecutive multi-character combinations that fail to match within a segment are identified as candidate new syllabuses. If the length of the candidate new segments does not exceed a predetermined length threshold, they are added to the segment library and their usage frequency is recorded as 1. When the syllabustrum reaches its capacity and new syllabuses still need to be added, the syllabuses are arranged in ascending order of usage frequency. Those with the same usage frequency are arranged in ascending order of most recent hit time. The syllabuse at the top of the list is eliminated to make room for new syllabuses.
8. The self-maintenance and update method according to claim 7, characterized in that, Fixed phrases exceeding the predetermined length threshold are manually maintained and supplemented, and are not subject to the length limit for automatic database entry; the predetermined length threshold is 7 Chinese characters.
9. A Chinese character text segmentation system, characterized in that, include: A syllabus building module is used to execute the building method according to any one of claims 1 to 3 to generate a syllabus library; The first-character index module is used to create an index of candidate syllables in descending order of length, using the first character of each syllable as the key. The segmentation module is used to execute the segmentation method according to any one of claims 4 to 6 to segment Chinese text into segments; The self-maintenance module is used to execute the self-maintenance update method according to any one of claims 7 to 8 to dynamically update the syllable library.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the construction method of any one of claims 1 to 3, the segmentation method of any one of claims 4 to 6, or the self-maintenance and update method of any one of claims 7 to 8.
Citation Information
Patent Citations
HMM-based Chinese word-segmentation method
CN107861940A
Chinese word segmentation method and system
CN109388803A
A Chinese character correction method based on deep learning
CN109522558B
Trinity character annotation Chinese lexical analysis method based on Bi-LSTM-CRF
CN112364623A
