Fundamentals of Linguistics
Natural language processing (NLP), an important branch of artificial intelligence, has as its core enabling computers to understand, interpret, and generate human language. To master NLP, one must first understand the basic principles that underpin how human language works - this is the fundamentals of linguistics.
The fundamentals of linguistics provide NLP with a theoretical framework and analytical tools, mainly including the following key aspects:
- Phonetics: studying the sound system of language
- Phonology: studying how sounds combine into meaningful linguistic units
- Morphology: studying the internal structure of words
- Syntax: studying sentence structure
- Semantics: studying the meaning of language
- Pragmatics: studying the use of language in context

Phonetics and Phonology (Phonetics & Phonology)
Phonetics (Phonetics)
Phonetics studies the physical properties and production mechanisms of speech sounds, focusing on their acoustic and physiological features.
Speech organs and articulation
- Speech organs:
- Lungs: provide airflow
- Larynx: vocal cord vibration produces voiced sounds
- Oral cavity: tongue, teeth, and lips regulate airflow
- Nasal cavity: produces nasal sounds
Consonant classification
Classified by manner and place of articulation:
-
Manner of articulation:
- Plosives: /p/, /b/, /t/, /d/, /k/, /g/
- Fricatives: /f/, /v/, /s/, /z/
- Affricates: /ts/, /tʃ/
- Nasals: /m/, /n/, /ŋ/
- Laterals: /l/
- Trills: /r/
-
Place of articulation:
- Bilabials: /p/, /b/, /m/
- Labiodentals: /f/, /v/
- Alveolars: /t/, /d/, /n/
- Velars: /k/, /g/, /ŋ/
Vowel classification
Classified by tongue position and lip rounding:
- Tongue height: high vowels /i/, /u/, mid vowels /e/, /o/, low vowels /a/
- Tongue backness: front vowels /i/, /e/, central vowel /a/, back vowels /u/, /o/
- Lip rounding: rounded vowels /u/, /o/, unrounded vowels /i/, /e/, /a/
Features of Chinese phonetics
- Tone languages: tones serve to distinguish meaning
- The four basic tones of Mandarin: yinping, yangping, shangsheng, qusheng
- Example: ma1 (mother), ma2 (hemp), ma3 (horse), ma4 (scold)
- Syllable structure: structure of initial + final
- Initials: 21 basic initials
- Finals: 39 basic finals
Phonology (Phonology)
Phonology studies the structure and rules of sound systems, focusing on the function of sounds in a particular language.
Phoneme (Phoneme)
- The smallest sound unit that distinguishes meaning
- Example: in English /p/ and /b/ are different phonemes (pit vs bit)
- In Chinese, tone is part of the phoneme
Allophone (Allophone)
- The phonetic realization of the same phoneme in different environments
- Example: English /p/ has different degrees of aspiration in different positions
Phonological rules
- Describe how sounds change in specific environments
- Example: the tone sandhi rules of 'Yi' (a Chinese character) in Mandarin
- Phonetic changes in English plural forms: cats /s/, dogs /z/, horses /ɪz/
Applications in NLP
- Speech recognition: converting sound signals into text
- Speech synthesis: converting text into speech
- Sound-to-character conversion: conversion from pinyin to Chinese characters
- Prosody analysis: computational analysis of poetic prosody
Morphology (Morphology)
Morphology studies the internal structure of words and word-formation rules, and is the basis of lexical-level analysis.
Basic concepts
Morpheme (Morpheme)
- The smallest meaningful grammatical unit in language
- Free morphemes: morphemes that can stand alone, such as 'Shu' (a Chinese character) and 'run'
- Bound morphemes: must attach to other morphemes, such as prefixes and suffixes
Roots, affixes, and stems
- Root (Root): the carrier of a word's core meaning
- Example: in "unhappiness", "happy" is the root
- Affix (Affix):
- Prefix: un-, re-, pre-
- Suffix: -ness, -tion, -ly
- Infix: relatively rare, as in Tagalog
- Stem (Stem): the form after removing inflectional affixes
Word-formation methods
Derivation (Derivation)
- Changing part of speech or meaning by adding derivational affixes
- Example:
- happy → unhappy (adding a negative prefix)
- happy → happiness (nominalizing suffix)
- teach → teacher (agentive suffix)
Compounding (Compounding)
- Combining two or more roots into a new word
- English examples:
- blackboard (black + board)
- laptop (lap + top)
- Chinese examples:
- Diannao (computer), from dian (electric) + nao (brain)
- Shouji (mobile phone), from shou (hand) + ji (machine)
Inflection (Inflection)
- Changing a word's grammatical form without changing its basic meaning
- English verb conjugation: walk, walks, walked, walking
- Noun plurals: book → books, child → children
- Chinese has relatively little inflectional variation
Characteristics of Chinese morphology
The concept of a word
- The boundaries of Chinese words are relatively vague
- The boundaries between characters, words, and phrases are less clear than in English
- Example: 'Yanjiusheng' (a Chinese word) can be a single word or analyzed as 'yanjiu' + 'sheng'
Word-formation methods
-
Compounding as the main pattern:
- Modifier-head: Huoche (huo+che)
- Verb-object: Siji (si+ji)
- Subject-predicate: Dizhen (di+zhen)
- Coordinate: Pengyou (peng+you)
-
Reduplication as word formation:
- Verb reduplication: kan-kan, zou-zou
- Adjective reduplication: honghong-de, manman-de
- Noun reduplication: renren, shishi
Flexible use of parts of speech
- The same character or word can function as different parts of speech
- Example: 'Shui' (a Chinese character) can be a noun (drink water) or a verb (water the field)
Applications in NLP
Stemming (Stemming)
- Reducing words to their stem form
- Porter algorithm: reducing "running", "runs", "ran" all to "run"
Lemmatization (Lemmatization)
- Reducing words to their dictionary form (lemma)
- Taking part-of-speech information into account, more accurate
Chinese word segmentation
- Since Chinese words are not separated by spaces, word segmentation is required
- Dictionary-based, statistical, or neural-network-based methods
Part-of-speech tagging
- Determining the grammatical category of each word
- Providing basic information for syntactic analysis
Syntax (Syntax)
Syntax studies the structure and organization of sentences and is central to understanding language grammar.
Basic concepts
Phrase structure
- Noun phrase (NP): a phrase headed by a noun
- Example: that interesting book
- Verb phrase (VP): a phrase headed by a verb
- Example: run quickly
- Prepositional phrase (PP): a phrase headed by a preposition
- Example: on the table
- Adjective phrase (AP): a phrase headed by an adjective
- Example: very beautiful
Sentence constituents
- Subject (Subject): the doer of the action
- Predicate (Predicate): describing the action or state of the subject
- Object (Object): the receiver of the action
- Attributive (Attributive): a constituent that modifies a noun
- Adverbial (Adverbial): a constituent that modifies verbs and adjectives
- Complement (Complement): a constituent that provides supplementary explanation
Syntactic parsing methods
Phrase structure grammar
- Describing sentence structure with rewrite rules
- Example:
S → NP VP NP → Det N VP → V NP Det → the, a, an N → cat, dog, book V → chase, read
Dependency grammar
- Centered on dependency relations between words
- Each word depends on a head word (except the root)
- Example: in the sentence 'the kitten chases the mouse':
- 'Zhui' (a Chinese character meaning 'chase') is the root node
- 'Xiaomao' (the kitten) depends on 'Zhui' (to chase) with a subject-predicate relation
- 'Laoshu' (the mouse) depends on 'Zhui' (to chase) with a verb-object relation
- 'Xiao' (a Chinese character meaning 'small') depends on 'Mao' (cat) with an attributive-head relation
Tree representation
追
/ \
小猫 老鼠
/
小
Characteristics of Chinese syntax
Word order characteristics
- Basic word order: subject-verb-object (SVO)
- Modifiers precede the head: the 'de' construction
- Example: that beautiful girl in red
Special constructions
- The 'ba' construction: ba + object + verb
- Example: I put the book on the table
- The 'bei' construction: subject + bei + agent + verb
- Example: the book was put on the table by me
- Existential and presentational sentences: indicating existence or appearance
- Example: there is a book on the table
Degree of grammaticalization
- Chinese has a relatively low degree of grammaticalization
- Word order and context play an important role in expressing grammatical relations
- Lacking rich morphological variation
Challenges of syntactic parsing
Ambiguity problems
- Structural ambiguity: a sentence can have multiple syntactic analyses
- Example: 'I saw the person holding a telescope'
- Analysis 1: I saw the person with a telescope
- Analysis 2: I saw a person who was holding a telescope
Long-distance dependencies
- Dependency relations between sentence constituents may span long distances
- Example: in the question 'what book did you buy yesterday?', there is a dependency relation between 'Shenme' (a Chinese word for 'what') and 'Mai' (a Chinese character for 'buy')
Ellipsis
- Chinese often omits the subject or other constituents
- Example: (I) watched a movie yesterday, (the movie) was very good
Applications in NLP
Syntactic parsers
- Rule-based: using hand-written grammar rules
- Statistical methods: probabilistic models based on annotated corpora
- Deep learning: using neural networks for end-to-end learning
Syntactic treebanks
- Penn Treebank (English)
- Chinese Treebank (CTB)
- Providing training and evaluation data for syntactic parsing
Application tasks
- Machine translation: understanding the syntactic structure of the source language
- Information extraction: extracting information based on syntactic patterns
- Question answering systems: understanding the syntactic structure of questions
Semantics (Semantics)
Semantics studies the meaning of language and is the core of natural language understanding.
Basic concepts
Lexical semantics
- Word meaning: the concept or meaning expressed by a word
- Polysemy: a word has multiple related meanings
- Synonymy: different words expressing the same or similar meanings
- Antonymy: oppositional relations between words
- Hyponymy: inclusion relations between concepts
Semantic relations
- Synonyms (Synonyms):
- Complete synonymy: relatively rare
- Near-synonyms: happy-glad, big-huge
- Antonyms (Antonyms):
- Complementary antonyms: dead-alive, male-female
- Gradable antonyms: cold-hot, big-small
- Relational antonyms: teacher-student, buy-sell
- Hypernyms and hyponyms:
- Hypernyms: animal, color
- Hyponyms: dog, cat (hyponyms of animal)
Sentence semantics
Proposition (Proposition)
- The basic semantic content expressed by a sentence
- Example: the proposition expressed by the sentence 'Xiaoming is reading in the library':
- Agent: Xiaoming
- Action: read
- Patient: book
- Location: library
Semantic Roles (Semantic Roles)
- Agent (Agent): the doer of the action
- Patient (Patient): the receiver of the action
- Instrument (Instrument): the tool used to perform the action
- Location (Location): the place where the action occurs
- Time (Time): the time when the action occurs
- Manner (Manner): the manner of the action
Argument Structure (Argument Structure)
- The semantic participants required by a verb
- Example: the verb 'Gei' (a Chinese character meaning 'give') requires three arguments:
- Giver (agent)
- Recipient (dative)
- Thing given (patient)
Semantic representation
Logical representation
- Using logical formulas to represent meaning
- First-order logic: ∃x (person(x) ∧ happy(x))
- Example: the logical representation of the sentence 'someone is very happy'
Frame Semantics (Frame Semantics)
- Understanding meaning based on cognitive frames
- The FrameNet project: building frame-based semantic resources
- Example: the commercial transaction frame includes elements such as buyer, seller, goods, and price
Concept graphs
- Using graph structures to represent concepts and relations
- Nodes represent concepts and edges represent relations
- Suitable for representing complex semantic networks
Semantic ambiguity
Lexical ambiguity
- Polysemy: Yinhang (bank: financial institution / river bank)
- Homophones: 'tamen' (they, for people) / 'tamen' (they, for things)
Structural ambiguity
- Modifier ambiguity: 'the beautiful girl's clothes'
- Scope ambiguity: 'all the students failed'
Pragmatic ambiguity
- Requires context to determine meaning
- Example: pronoun reference and recovery of omitted constituents
Applications in NLP
Lexical semantic resources
- WordNet: English lexical semantic networks
- HowNet: Chinese lexical semantic knowledge bases
- Tongyici Cilin (a Chinese synonym thesaurus): a Chinese synonym classification system
Semantic analysis tasks
- Word sense disambiguation: determining the meaning of a polysemous word in a specific context
- Semantic role labeling: identifying semantic roles in a sentence
- Semantic similarity computation: computing semantic similarity between words or sentences
Application Areas
- Question answering systems: understanding the semantic intent of questions
- Machine translation: maintaining semantic consistency in translation
- Information retrieval: semantic-based relevance matching
Pragmatics (Pragmatics)
Pragmatics studies the use of language in specific communicative situations and focuses on the influence of context on meaning.
Basic concepts
Context (Context)
- Linguistic context: surrounding discourse information
- Situational context: the specific situation of communication
- Cultural context: social and cultural background
Speech Act Theory (Speech Act Theory)
- Locutionary act: the act of speaking itself
- Illocutionary act: the purpose intended through speaking
- Perlocutionary act: the effect produced by speaking
Types of illocutionary acts
- Assertives (representatives): stating facts, e.g., 'it is raining today'
- Directives: requesting action, e.g., 'please close the door'
- Commissives: promising future action, e.g., 'I will come tomorrow'
- Expressives: expressing attitude, e.g., 'congratulations'
- Declarations: changing reality, e.g., 'I declare the meeting open'
Pragmatic phenomena
Deixis (Deixis)
- Linguistic elements whose reference can only be determined by context
- Person deixis: I, you, he
- Time deixis: now, yesterday, tomorrow
- Spatial deixis: here, there, above
- Discourse deixis: as mentioned above, to sum up
Presupposition (Presupposition)
- Information the speaker assumes the listener already knows
- Example: 'Xiaoming's wife is beautiful' presupposes that Xiaoming is married
Implicature (Implicature)
- Conversational implicature: implied meaning produced by violating the cooperative principle
- Example: A: 'Do you know what time it is?' B: 'Yes, I do.'
- B's answer violates the maxim of quantity, implying unwillingness to tell the time
Cooperative Principle (Cooperative Principle)
- Maxim of quantity: providing the right amount of information
- Maxim of quality: telling the truth
- Maxim of relation: saying relevant things
- Maxim of manner: expressing clearly
Characteristics of Chinese pragmatics
Politeness strategies
- Chinese places great emphasis on politeness principles
- Using euphemisms and honorifics
- Example: 'qing wen' (may I ask), 'mafan nin' (could I trouble you), 'bu hao yisi' (excuse me)
High-context culture
- Relying on context to understand meaning
- Implicit discourse that is not expressed directly
- Example: refusals in Chinese are often indirect
Face theory
- Positive face: the need to be approved of
- Negative face: the need not to be disturbed
- Influences the choice of speech acts
Applications in NLP
Dialogue systems
- Intent recognition: Understand the user's true intent
- Slot filling: extract key information from the dialogue
- Dialogue management: control the flow of dialogue
Sentiment analysis
- Implicit sentiment: recognize indirectly expressed emotions
- Irony detection: understand the true meaning behind irony
Machine translation
- Pragmatic equivalence: preserve the pragmatic function of the original text
- Cultural adaptation: consider the cultural features of the target language
Features of the Chinese language
As a representative of the Sinitic language family, Chinese has unique linguistic features that bring special challenges and opportunities to Chinese NLP.
The necessity of word segmentation
No space delimiters
- There are no obvious boundary markers between Chinese words
- Example: 'Wo ai Beijing Tiananmen' needs to be segmented into 'Wo/ai/Beijing/Tiananmen'
- Different from the natural word spacing in languages such as English
The concept of a word is complex
- The boundaries between characters, words, and phrases are blurred
- Example: 'yanjiu' can be one word, 'yanjiusheng' can also be one word
- Context affects segmentation results
Segmentation ambiguity
Combinatorial ambiguity
- The same character sequence can have different segmentations
- Example: 'jiehunde he shangwei jiehunde'
- Incorrect segmentation: jiehunde/heshang/weijiehunde
- Correct segmentation: jiehunde/he/shangwei/jiehunde
Overlapping ambiguity
- Adjacent segmentation schemes overlap
- Example: 'Changchunshi Changchun yaodian'
- Scheme 1: Changchunshi/Changchun/yaodian
- Scheme 2: Changchun/shizhang/chunyaodian
True ambiguity
- Different segmentation results are all grammatically and semantically plausible
- Example: 'pingpangqiu pai mai wan le'
- Scheme 1: pingpangqiupai/maiwanle
- Scheme 2: pingpangqiu/paimai/wanle
Word segmentation methods
Dictionary-based methods
- Maximum matching algorithm (forward, backward, bidirectional)
- Advantages: simple and efficient
- Disadvantages: cannot handle ambiguity and out-of-vocabulary words
Statistical methods
- N-gram language model
- Hidden Markov Model (HMM)
- Conditional Random Field (CRF)
Deep learning based methods
- Bidirectional LSTM + CRF
- Pretrained models such as BERT
- Character-level neural networks
Chinese characters, vocabulary, and grammatical structures
Features of Chinese characters
Square-block character structure
- Chinese characters have square visual features
- Each character occupies an equal-width space
- Unity of character form, sound, and meaning
Pictographic and ideographic features
- Pictographic characters: 'Ri' (sun), 'Yue' (moon), 'Shan' (mountain), 'Shui' (water) as Chinese characters
- Indicative characters: 'Shang' (up), 'Xia' (down), 'Ben' (root), 'Mo' (tip) as Chinese characters
- Ideographic compound characters: 'Ming' (bright), 'Xiu' (rest), 'Xin' (trust) as Chinese characters
- Phono-semantic compound characters: account for over 80% of Chinese characters, e.g. 'Jiang' (water radical + 'Gong')
Polyphony and polysemy
- One character with multiple readings: 'xing/hang', 'chang/zhang'
- One character with multiple meanings: 'da' has meanings such as to hit, to buy, to make
Vocabulary features
Rich word-formation patterns
- Simple words: cannot be split, e.g. 'zhuozi' (table), 'putao' (grape)
- Compound words: composed of two or more morphemes
- Compound type: 'diannao' (computer), 'shouji' (mobile phone)
- Affixed type: 'diyi' (first), 'laoshi' (teacher)
High semantic transparency of vocabulary
- Word meaning can be inferred from its component characters
- Example: 'xiyiji' (washing machine) = wash + clothes + machine
- Helps in understanding new words and terminology
Flexible conversion of parts of speech
- The same word can serve as different parts of speech
- Example: 'shui' (water)
- Noun: 'he shui' (drink water)
- Verb: 'shui tian' (irrigated field)
- Adjective: 'shuiping hen shui' (colloquial: of low quality)
Grammatical structure features
Relatively fixed word order
- Basic word order: subject-verb-object (SVO)
- Attributives precede the head: 'hongse de hua' (red flower)
- Adverbials precede the predicate: 'manman de zou' (walk slowly)
Diverse grammatical devices
- Word order: changing word order conveys different meanings
- Function words: 'de', 'di', 'de', 'le', 'zhe', 'guo', etc.
- Reduplication: 'kan kan', 'zou zou', 'honghong de'
Low degree of grammaticalization
- Lacks rich morphological inflection
- Verbs have no morphological changes for tense or voice
- Nouns have no case inflection or number agreement
Special challenges of Chinese NLP
Text preprocessing challenges
Difficulty of word segmentation
- Ambiguity resolution requires semantic understanding
- Difficulty of new word recognition
- Recognition of domain-specific terminology
Simplified-traditional conversion
- One simplified form maps to multiple traditional forms: 'hou' (hou/hou)
- One traditional form maps to multiple simplified forms: 'fa' (fa/fa)
- Regional vocabulary differences: 'jisuanji' (computer) / 'diannao' (computer)
Encoding issues
- Multiple encoding schemes: GB2312, GBK, UTF-8
- Encoding conversion may cause information loss
Handling language variants
Dialectal differences
- Regional differences in phonology, vocabulary, and grammar
- Example: Beijing dialect 'beir', Shanghai dialect 'ala'
- Affects speech recognition and text understanding
Register differences
- Classical Chinese and modern Chinese
- Formal register and colloquial speech
- Internet slang and buzzwords
Usage in Hong Kong, Macao, and Taiwan
- Different word habits: 'dishi' (taxi) / 'chuzuche', 'bashi' (bus) / 'gongjiaoche'
- Grammatical structure differences: 'youmou' (have or not have)
- Handling loanwords: transliteration vs. free translation
Semantic understanding challenges
Strong context dependence
- Complex pronoun reference
- Frequent ellipsis
- Requires more contextual information
Rich cultural connotations
- Understanding of idioms and allusions
- Culture-specific concepts: 'mianzi' (face), 'guanxi' (relationships)
- Traditional cultural background knowledge
Flexible language use
- Word-order variation: 'ba'-construction, 'bei'-construction
- Diverse expression: euphemism, implicitness
- Cultural features of pragmatic principles
The hierarchical structure of text
As the carrier of language, text has multi-level structural features. Understanding these hierarchies is crucial for designing effective NLP systems.
Character level (Character Level)
Basic units
Definition of character
- The smallest visual unit of text
- Includes letters, Chinese characters, digits, punctuation marks, etc.
- The basic unit of the Unicode encoding system
Character type
- Letter characters:A-Z, a-z
- Digit characters:0-9
- Chinese character glyphs: Unicode range 4E00-9FFF
- Punctuation marks:., !?;:""''
- Special characters: @#$%^&*, etc.
Character-level processing
Encoding processing
- ASCII encoding: suitable for English
- Unicode encoding: supports multiple languages
- UTF-8 encoding: variable-length encoding, widely used
Character sequence models
- Character-level RNN: directly processes character sequences
- Convolutional neural networks: extract character-level features
- Transformer: self-attention mechanism processes characters
Application scenarios
- Spelling check: detects character-level errors
- Text generation: character-level language models
- Low-resource languages: an alternative when lexical resources are lacking
Word level (Word Level)
Definition of word
The concept of a word
- A linguistic unit with complete meaning
- The basic unit of grammatical analysis
- Relatively independent in phonology
Word types
- Content words: nouns, verbs, adjectives, adverbs
- Function words: prepositions, conjunctions, particles, interjections
- Function words: high-frequency functional words such as the, a, is, have
- Content words: words that carry the main meaning
Word representation
One-hot Encoding
- Each word is represented by a vector
- Vector length equals the vocabulary size
- Only the corresponding position is 1, others are 0
- Disadvantages: high dimensionality, cannot express semantic similarity
Word Embeddings
- Word2Vec: neural-network-based word vectors
- CBOW: predicts the center word from context
- Skip-gram: predicts context from the center word
- GloVe: based on global word co-occurrence statistics
- FastText: word vectors that consider character-level information
Contextual word vectors
- ELMo: context-sensitive representations produced by bidirectional LSTM
- BERT: Transformer-based bidirectional encoder
- The same word has different representations in different contexts
Lexical relations
Semantic relations
- Synonymy: happy-glad
- Antonymy: big-small
- Hyponymy: animal-dog
Morphological relations
- Root relations:run-running-ran
- Derivational relations:happy-happiness
- Compounding relations:black + board → blackboard
Distributional relations
- Words with similar contextual distributions tend to be semantically related
- Example: 'yisheng' (doctor) and 'hushi' (nurse) often appear in similar contexts
- The fundamental assumption underlying word vector learning
Word-level processing
Word normalization
- Case handling: convert text uniformly to lowercase or uppercase
- Lemmatization: restore words to their dictionary form (lemma)
- Stemming: remove affixes to obtain the stem (stem)
Stop-word filtering
- Remove high-frequency, low-information words
- Chinese stop words: 'de', 'le', 'shi', 'zai', 'he', etc.
- English stop words: the, a, an, is, are, etc.
Low-frequency word handling
- Replace with a unified token (such as
) - Improve model generalization
- Reduce vocabulary size
Application scenarios
- Information retrieval: build inverted index
- Text classification: feature extraction and representation
- Machine translation: word alignment and substitution
Phrase level (Phrase Level)
Definition of phrase
Basic concepts
- A grammatical unit composed of multiple words
- Has internal structure and external function
- Built around a head word
Phrase types
- Noun phrase (NP): noun-headed
- Example: 'yi ben youqu de shu' (an interesting book)
- Verb phrase (VP): verb-headed
- Example: 'zhengzai renzhen yuedu' (reading carefully)
- Prepositional phrase (PP): preposition-headed
- Example: on the table
- Adjective phrase (AP): adjective-headed
- Example: 'feichang piaoliang' (very beautiful)
Phrase identification
Rule-based methods
- Use grammar rule templates
- Example: NP -> (Det) (Adj) N
- Rely on manually written grammar rules
Statistical methods
- Use n-gram models to identify common phrases
- Based on statistics such as mutual information and chi-square test
- Example: 'New York Times' as a fixed phrase
Deep learning based methods
- Sequence labeling models (e.g., BiLSTM-CRF)
- End-to-end phrase detection
- Pretrained language models (e.g., BERT)
Phrase representation
Composition of word vectors
- Simple averaging: take the average of the constituent word vectors
- Weighted averaging: assign weights according to word importance
- Recurrent neural networks: composition that considers word order
Phrase embeddings
- Directly learn vector representations at the phrase level
- Skip-phrase model: similar to Skip-gram
- Phrase analogy task: China:Beijing::France:Paris
Application scenarios
- Information extraction: identify key phrases
- Query understanding: handle search engine queries
- Sentiment analysis: identify opinion target phrases
Sentence level (Sentence Level)
Definition of sentence
Basic concepts
- A linguistic unit expressing a complete meaning
- Has grammatical independence
- Contains the basic structure of subject and predicate
Sentence types
- Declarative sentences: express facts or opinions
- Interrogative sentences: ask questions
- Imperative sentences: express requests or commands
- Exclamatory sentences: express strong emotions
Sentence representation
Composition of word vectors
- Bag-of-words model (BoW): simple sum that ignores word order
- TF-IDF weighting: consider word importance
- Sequence models: RNN/LSTM consider word order information
Sentence embeddings
- Skip-Thought: predict context sentences
- InferSent: representation based on supervised tasks
- Sentence-BERT: BERT-based sentence representation
Syntactic structure representation
- Dependency trees: represent dependency relations between words
- Constituent trees: represent phrase structure relations
- Graph representation: combine multiple relations
Sentence-level processing
Sentence segmentation
- Split continuous text into sentences
- Chinese difficulty: the multifunctionality of the period
- Methods: rule-based, machine learning
Sentence compression
- Simplification that retains core information
- Delete redundant constituents
- Applied to summarization
Sentence paraphrasing
- Sentence-structure transformation that preserves meaning
- Active-passive conversion
- Applied to data augmentation
Application scenarios
- Machine translation: sentence-level alignment and generation
- Text summarization: key sentence extraction
- Question answering systems: question understanding and answer generation
Discourse level (Discourse Level)
Discourse structure
Basic concepts
- A coherent whole composed of multiple sentences
- Has topical consistency and logical coherence
- Includes structures such as introduction, body, and conclusion
Cohesion devices
- Reference: pronouns, demonstratives
- Connectives: 'yinwei' (because), 'suoyi' (so), 'danshi' (but)
- Lexical cohesion: repetition, synonymy, hyponymy
- Ellipsis: ellipsis of preceding or following context
Discourse relations
- Causal relations: because... so...
- Adversative relations: although... but...
- Coordinate relations: on one hand... on the other hand...
- Temporal relations: first... then... finally...
Discourse analysis
Coreference resolution
- Determine the referent of a pronoun or noun phrase
- Example: in 'Xiaoming was late. He was very sorry.', 'he' refers to 'Xiaoming'
- Methods: rule-based, machine learning, deep learning
Topic modeling
- LDA: Latent Dirichlet Allocation
- Discover the latent topic distribution of text
- Applied to text clustering and classification
Sentiment trajectory analysis
- Track the change of sentiment across discourse
- Identify sentiment turning points
- Applied to review analysis and literary studies
Discourse representation
Global vector
- Average all sentence vectors
- Weighted averaging (e.g., TF-IDF weights)
- Hierarchical composition
Graph representation
- Nodes represent sentences or concepts
- Edges represent relations
- Applied to summarization
Memory networks
- Store and retrieve discourse information
- Handle long-distance dependencies
- Applied to question answering systems
Application scenarios
- Automatic summarization: extract core content
- Question answering systems: multi-sentence reasoning
- Text generation: maintain discourse coherence
Language models and probabilistic grammars
Fundamentals of language models
Basic concepts
Definition of language model
- A model that computes the probability of a word sequence
- Evaluate the fluency and plausibility of sentences
- Formal description: P(w1,w2,...,wn)
Application Areas
- Speech recognition: select the most likely word sequence
- Machine translation: evaluate translation candidates
- Text generation: predict the next word
N-gram model
Markov assumption
- The current word depends only on the previous n-1 words
- Simplified probability computation: P(wi|w1,...,wi-1) ~= P(wi|wi-n+1,...,wi-1)
Model training
- Maximum likelihood estimation
- Counting and normalization
- Smoothing techniques (add-one, Good-Turing, etc.)
Limitations
- Data sparsity problem
- Long-distance dependencies are hard to capture
- Limited contextual information
Neural network language models
Feed-forward neural network model
Basic structure
- Input layer: one-hot representation of the previous n-1 words
- Embedding layer: learn word vectors
- Hidden layer: non-linear transformation
- Output layer: predict the probability distribution of the next word
Advantage
- Distributed representations alleviate data sparsity
- Automatically learn feature combinations
- Better generalization ability
Recurrent neural network models
RNN structure
- Recurrently process variable-length sequences
- Hidden states carry historical information
- Applied to language modeling
LSTM/GRU
- Solve the vanishing gradient problem
- Long-distance dependency modeling
- More stable training process
Transformer models
Self-attention mechanism
- Global context modeling
- Advantages of parallel computation
- Positional encoding handles word order
Pretrained language models
- BERT: bidirectional contextual representation
- GPT: autoregressive generative model
- Powerful transfer learning capability
Probabilistic grammar models
Probabilistic context-free grammars
Basic concepts
- Assign probabilities to CFG rules
- P(X -> gamma) represents the rule application probability
- The probability of a sentence is the product of derivation-path probabilities
Parameter estimation
- Count rule applications from treebanks
- Maximum likelihood estimation
- Smooth sparse rules
Apply
- Syntactic parsing
- Sentence probability evaluation
- Ambiguity resolution
Dependency grammar models
Probabilistic dependency grammars
- Assign probabilities to dependency relations
- Based on word co-occurrence statistics
- Consider distance and grammatical constraints
Parsing algorithms
- Graph-based algorithms (Eisner algorithm)
- Transition-based algorithms
- Neural network parsers
Language resources and annotation
Corpus resources
General corpora
English corpora
- Brown Corpus
- British National Corpus (BNC)
- Corpus of Contemporary American English (COCA)
Chinese corpora
- Peking University Modern Chinese Corpus
- National Language Commission Balanced Modern Chinese Corpus
- Chinese Wikipedia corpus
Annotated corpora
Part-of-speech tagged corpora
- Penn Treebank
- Chinese Treebank (CTB)
Syntactic treebanks
- Penn Treebank
- Chinese Dependency Treebank
Semantically annotated corpora
- PropBank (semantic roles)
- FrameNet (frame semantics)
- Semeval (semantic relations)
Lexical semantic resources
English resources
WordNet
- Synonym sets (synset)
- Lexical relation networks
- Widely used in NLP research
FrameNet
- Based on frame semantics
- Annotate semantic roles
- Rich example sentence resources
Chinese resources
HowNet
- Chinese-English conceptual dictionary
- Sememe analysis system
- Semantic relation networks
Tongyici Cilin (a Chinese synonym thesaurus)
- Chinese synonym classification
- Hierarchical organizational structure
- Vocabulary expansion resources
Evaluation datasets
Standard task datasets
Word segmentation and part-of-speech tagging
- PKU annotated corpus
- MSRA annotated corpus
Syntactic parsing
- Chinese Treebank
- CTB 5.1/6.0/7.0
Semantic analysis
- Chinese PropBank
- NLPCC evaluation data
Applied task datasets
Text classification
- THUCNews
- Fudan Corpus
Sentiment analysis
- ChnSentiCorp
- Weibo Sentiment Corpus
Question answering systems
- NLPCC QA dataset
- WebQA
Interdisciplinary research of linguistics and NLP
Computational linguistics
Research areas
Speech technology
- Speech recognition
- Speech synthesis
- Voice conversion
Grammatical analysis
- Automatic syntactic parsing
- Grammar induction
- Treebank construction
Semantic computing
- Word sense disambiguation
- Semantic role labeling
- Semantic similarity
Cognitive linguistics and NLP
Language acquisition modeling
Child language acquisition
- Vocabulary growth models
- Simulation of grammatical development
- Cognitively inspired NLP
Neurocognitive models
- Simulation of brain language processing
- Neural-symbolic systems
- Multimodal learning
Language evolution modeling
Computational simulation
- Vocabulary formation
- Emergence of Grammar
- Cultural Transmission
Multi-Agent Systems
- Evolution of Communication Systems
- Symbol Grounding Problem
- Language Game Model
Sociolinguistics and NLP
Handling Language Variation
Dialect Identification
- Analysis of Phonetic Features
- Modeling Lexical Differences
- Dialect Machine Translation
Sociolinguistic Features
- Age and Gender Identification
- Education Level Prediction
- Regional Dialect Analysis
Language Policy Support
Language Resource Construction
- Minority Languages
- Endangered Language Preservation
- Multilingual Technology Development
Language Education Technology
- Computer-Assisted Learning
- Automated Essay Scoring
- Personalized Tutoring Systems