> For the complete documentation index, see [llms.txt](https://riteshs4hu.gitbook.io/infosec-notes/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://riteshs4hu.gitbook.io/infosec-notes/artificial-intelligence/nlp-and-llms.md).

# NLP & LLMs

## Natural Language Processing (NLP)

**Natural Language Processing (NLP)** is a field of Artificial Intelligence that focuses on enabling computers to understand, interpret, process, and generate human language.

Although NLP is a domain within AI, modern NLP systems are primarily powered by Machine Learning and Deep Learning techniques.

The main objective of NLP is to bridge the gap between human language and computer understanding.

### Common NLP Tasks

NLP systems are designed to solve various language-related tasks, including:

* Text classification
* Sentiment analysis
* Language translation
* Named entity recognition
* Question answering
* Speech recognition
* Text summarization

To perform these tasks effectively, modern NLP relies heavily on Deep Learning architectures, particularly Transformers.

***

## Large Language Models (LLMs)

A **Large Language Model (LLM)** is a Deep Learning model trained on massive amounts of text data to understand and generate human-like language.

LLMs are typically built using the Transformer architecture.

Their primary purpose is to solve complex NLP tasks such as:

* Text generation
* Question answering
* Conversation (chatbots)
* Translation
* Code generation

In simple terms:

> NLP defines the language problems, and LLMs are advanced models designed to solve those problems.

#### Reference:

* <https://www.ibm.com/think/topics/large-language-models>
