---
title: "Document Embedding with Paragraph Vectors — Dai 2015"
description: "Document Embedding with Paragraph Vectors tests how well learned document representations find related articles in Wikipedia and arXiv."
canonical: "https://research.elamur.ai/free/en/papers/dai-2015-document-embedding-paragraph-vectors/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/dai-2015-document-embedding-paragraph-vectors/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2015](https://md.research.elamur.ai/free/en/papers/2015/) / Document Embedding with Paragraph Vectors

# Document Embedding with Paragraph Vectors

Paper · 2015 · Andrew M. Dai, Christopher Olah and Quoc Viet Le

**Authors:** [Andrew M. Dai](https://md.research.elamur.ai/free/en/authors/andrew-m-dai/), Christopher Olah and [Quoc Viet Le](https://md.research.elamur.ai/free/en/authors/quoc-viet-le/) · **Year:** 2015 · **Venue:** arXiv (Cornell University) · **Licence:** [arXiv — non-exclusive license to distribute](http://arxiv.org/licenses/nonexclusive-distrib/1.0/)

[**252** citations OpenAlex, 2026-10-14](https://openalex.org/works?filter=cites:W941230081) · [arXiv (Cornell University)](https://openalex.org/S4306400194) · [licence](http://arxiv.org/licenses/nonexclusive-distrib/1.0/)

- [PDF](https://arxiv.org/pdf/1507.07998)
- [arXiv 1507.07998](https://arxiv.org/abs/1507.07998)
- [OpenAlex](https://openalex.org/W941230081)

Citations: OpenAlex, 2026-10-14.

## Summary

When an article helps you understand a subject, what should you read next? Its text offers clues, but a search based on matching words can miss a related article that uses different terms. “Document Embedding with Paragraph Vectors” asks whether a system can learn a better description of an article by trying to predict which words occur in it. The authors test whether articles with similar descriptions turn out to be related, an operational test of [semantic similarity](https://md.research.elamur.ai/free/en/concepts/semantic-similarity/).

Paragraph Vectors gives each article its own adjustable list of numbers, called a vector. In the version used here, the same article vector helps predict words from throughout the text, with no neighboring words supplied to the document predictor. The authors also train [word embeddings](https://md.research.elamur.ai/free/en/concepts/word-embeddings/), numerical representations of individual words, alongside the document vectors. They report that joint training improves the document representations. Earlier work had used Paragraph Vectors to help classify movie reviews. This study asks whether the method can help readers navigate much longer texts when the training signal comes from the texts themselves.

In the quantitative tests, the system must decide which of two candidates more closely matches the starting article. Some Wikipedia comparisons reflect the authors’ own judgments, and others use Wikipedia categories. Paragraph Vectors outperforms [Latent Dirichlet Allocation](https://md.research.elamur.ai/free/en/papers/blei-2003-latent-dirichlet-allocation/), which describes articles as mixtures of inferred topics. The Wikipedia results for Paragraph Vectors peak at 10,000 dimensions. On arXiv, where the expected rankings come from subject labels, Paragraph Vectors is about as effective as Latent Dirichlet Allocation at its best topic count. Its results vary less as the representation size changes, with a reported peak at 100 dimensions.

The authors also try adjusting the starting point for a search. They take the Wikipedia vector for Lady Gaga, subtract the word vector for “American,” and add the one for “Japanese.” On arXiv, they start with the earlier Paragraph Vectors paper and use “neural” and “Bayesian” to ask for a different approach to a related problem. The resulting neighbor lists illustrate how the method can express a more specific request than an article alone. The triplet tests supply the systematic evidence for the rankings produced by the original article vectors.

## Deep dive: Document Embedding with Paragraph Vectors

Document Embedding with Paragraph Vectors tests whether learned article vectors can find related texts and redirect searches in Wikipedia and arXiv. · about 31 minutes to read

**In this deep dive**

1. [The problem and its context](#dd-the-problem-and-its-context)
2. [The method, step by step](#dd-the-method-step-by-step)
3. [Experiments and results](#dd-experiments-and-results)
4. [What the ablations show](#dd-what-the-ablations-show)
5. [Limitations](#dd-limitations)
6. [What came after](#dd-what-came-after)

### The problem and its context

#### When a document is the query

The paper approaches [information retrieval and search](https://md.research.elamur.ai/free/en/topics/information-retrieval/) from a situation in which the reader already has something useful: a whole article. The text may explain what the reader is interested in more fully than a few keywords could. It also contains material the reader may care about less, such as examples or background. A document representation takes that mixture of evidence and gives the search procedure something it can compare with the rest of the collection. A useful comparison places documents that share substantive features close enough for a reader to discover them.

This is a different job from deciding whether a movie review expresses favorable or unfavorable sentiment. A [text classification](https://md.research.elamur.ai/free/en/concepts/text-classification/) task can reward a representation that isolates distinctions specific to its labels. In browsing, the distinctions of interest depend on the starting article. A good comparison for an encyclopedic article about a person might rely on occupation, nationality, or the kind of work they are known for. A comparison among research papers might turn on the problem they study or the approach they take. The authors want to know whether a representation learned through word prediction can support such comparisons directly.

The paper considers both ordinary browsing and a more directed kind. Ordinary browsing begins with the coordinates of a document and inspects the closest alternatives. Directed browsing starts from the same document, then moves the query according to an additional instruction expressed through words. These uses put different demands on the representation. Ordinary browsing needs sensible neighborhoods. Directed browsing additionally needs a numerical change that can carry a meaningful request from a word-level comparison into the space of articles. The paper tests ordinary similarity more systematically and uses examples to investigate directed search.

#### What established representations preserve

The authors begin with the bag of words, an established way of describing text through the vocabulary it contains. Think of a long row of positions, with each position reserved for a particular word. The value in a position records how strongly that word contributes to the description. Word order disappears when the article is collected into this row. A bag of [n-grams](https://md.research.elamur.ai/free/en/concepts/n-gram/) can retain short stretches of word order by giving a position to a sequence of words. Once those sequences have been counted, their locations in the article also disappear from the representation.

The paper’s word-based comparison uses [TF-IDF](https://md.research.elamur.ai/free/en/concepts/tf-idf/). This weighting combines information about how frequently a term occurs in the document with information about how widely it occurs across the collection. A term can be prominent in one article and relatively unusual elsewhere, giving it a useful role in identifying potential neighbors. The coordinate remains identifiable as that term. If a pair of articles aligns strongly in such coordinates, their similarity can be understood in terms of shared vocabulary. This makes the weighted bag a meaningful benchmark even though its construction is straightforward.

An alternative is to compare inferred subjects. In [topic modeling](https://md.research.elamur.ai/free/en/concepts/topic-modeling/), Latent Dirichlet Allocation, or LDA, represents an article by the proportions it assigns to topics learned from a body of texts. A document can devote different shares to different topics. Comparing those shares lets the procedure recognize a resemblance between articles whose emphases fall in similar places. The topics come from the texts. They have a different role from the Wikipedia categories and arXiv subject labels, which provide expectations for judging the rankings.

The number of topics affects the kind of description LDA can produce. With a given topic count, an article’s content has to be expressed through that collection of components. Changing the number changes the distinctions the procedure has available. This is one reason the authors vary the count when comparing LDA with Paragraph Vectors. The topic method has its own setting that shapes the resulting representation and deserves to be tested at settings where it can perform well.

#### Why learn the coordinates themselves?

The paper traces the distributed approach at the word level to [Efficient Estimation of Word Representations in Vector Space](https://md.research.elamur.ai/free/en/papers/mikolov-2013-efficient-estimation-word-representations-vector/). In a word embedding, the numerical description of a word is spread over the vector’s coordinates. Their values are adjusted through a prediction task. A comparison between words can then use the entire learned pattern of values. This is a form of [distributional semantics](https://md.research.elamur.ai/free/en/concepts/distributional-semantics/) in which observations about word use help determine the resulting positions.

For documents, the immediate starting point is [Distributed Representations of Sentences and Documents](https://md.research.elamur.ai/free/en/papers/le-2014-distributed-representations-sentences-documents/). As the paper describes it, the earlier work found uses for its vectors in movie review classification and webpage retrieval. Those demonstrations motivated a closer comparison with established ways of representing text and a study of what happens when the size of an embedding changes. The later experiments in this paper move to long encyclopedic entries and research papers and make the relation between whole documents the direct object of measurement.

A document can also inherit a distributed representation from its words. Averaging the word vectors produces a description whose coordinates are learned at the level of vocabulary, then combined at the level of an article. Paragraph Vectors assigns the article an adjustable vector of its own. This gives the authors a comparison between different routes from word predictions to document similarity. A useful average would show that learning word representations already gets some of the way towards useful document comparisons. Directly fitting an article vector gives the procedure another way to account for the evidence supplied by its words.

What a reader can inspect differs across these representations. A weighted bag makes each coordinate’s association with a word explicit. A topic mixture provides shares over inferred topics. In a distributed representation, the authors point out that the coordinates are less readily interpreted. The case for using those coordinates depends on what they let the system do. This paper makes that question concrete by looking at rankings, browsing examples, and the extent to which the results depend on the number of available coordinates.

### The method, step by step

#### Use the article to predict its words

Suppose that a training procedure selects a word from an article and asks a predictor to give that word a high probability. The correct answer is available in the article. To make the prediction, the procedure gives the predictor a vector associated with the document. The values in that vector are adjustable. A prediction that assigns too little weight to the observed word supplies a reason to change them. Words encountered elsewhere in the article supply further reasons to adjust the same set of values.

This is how an article acquires its description. The document’s identity tells the procedure which vector to use. The document’s wording tells it which predictions to reward. An article with a recurring subject supplies multiple opportunities for its vector to favor the vocabulary associated with that subject. The predictor is shared across documents, so article vectors are learned in a setting where the coordinates have to operate with the same vocabulary and prediction machinery. After training, their relative positions can be examined.

The authors call the learning unsupervised because it can proceed with text alone. They do use judgments about pairwise relevance in the study, but in the triplet tests. A Wikipedia category can say which of two candidate articles the procedure ought to favor after fitting. It does not supply the answer to a word prediction during fitting. The study is therefore able to ask what distinctions learned from text carry over to a test whose answers come from a separate kind of evidence.

#### Decide what the predictor can see

The paper describes two versions of Paragraph Vectors. Distributed Memory supplies both an article vector and vectors for nearby words. To predict the next word, the procedure can concatenate these inputs, placing their lists of coordinates end to end, or average them by combining corresponding coordinates. As training moves through the article, the nearby words change. The article vector is reused, so it can contribute information that applies across the text. The prediction updates both the participating word vectors and the document vector.

The distinction between local context and document context explains the “memory” in the name. Nearby words may carry information specific to a sentence or phrase. The vector attached to the document is available throughout its text. Through repeated predictions, the procedure can use it to encode some of the document’s recurrent concerns. The paper describes this role in terms of capturing topics. The method fits its own distributed coordinates rather than supplying a list of topics whose shares the new vector needs to express.

Distributed Bag of Words, the version used in the experiments, gives the document predictor the article vector alone. The target is a word drawn from that article. The input has no position-specific window of nearby words, so the article vector has to be useful across the different targets. This is a good way to understand why predicting a word can tell the procedure something about a long document. An individual prediction is local evidence about a word occurrence. The collection of such predictions shapes a single representation shared by the whole article.

The name Distributed Bag of Words describes the prediction setup. The weighted bag baseline, by comparison, is assembled by placing explicit term weights in vocabulary positions. A document vector in Distributed Bag of Words gets its values through optimization. Each coordinate can help make many different word predictions through its interaction with the classifier. The authors select Distributed Bag of Words for efficiency. Their main experiments examine this choice in use and leave a controlled comparison with Distributed Memory open.

#### Prepare the vocabulary and fit both kinds of vector

Both corpora are converted to lower-case before use. This allows forms that differ only in capitalization to contribute evidence to the same vocabulary entry. Each collection also uses a frequency cutoff, so rare forms beyond the cutoff are excluded from the vocabulary used for prediction. The resulting vocabulary sizes differ between Wikipedia and arXiv. A preliminary experiment tried supplying both unigrams, which are individual words, and bigrams, which are adjacent pairs. The authors saw no benefit to final vector quality from the combination and proceeded with the word-level setup.

The paragraph-vector training covers at least 10 epochs on the public corpora. An epoch is a pass through training data. Further passes give the procedure repeated chances to update the document vectors as well as the machinery that predicts words from them. The word classifier is a hierarchical softmax arranged as a Huffman tree. A word corresponds to a leaf, and prediction proceeds through the decisions on the path to that leaf. This factors the probability of a vocabulary item into a sequence of choices in the tree, an important detail when the vocabulary is large.

The experiments also train word embeddings in the manner of skip-gram alongside the paragraph vectors. In skip-gram, a word is used to predict words found near it. This makes local word neighborhoods useful in the accompanying word task while the article predictor continues to work from the document vector. The two sources of prediction examples have different scopes. A word can recur across many articles and acquire a representation through its neighbors. An article vector is attached to one document and is fitted using words drawn from across that text. The paper describes the word training as a modification that helps the resulting paragraph vectors.

Both kinds of vector are needed for the paper’s arithmetic experiments. The word representations trained alongside the article vectors provide coordinates for the terms used to redirect a search. Joint training also has a role in the triplet experiments, where its effect is judged using the document vectors themselves. Those tests offer a way to ask whether the word task improves ordinary rankings before any particular article query is adjusted.

From article text to a neighbor ranking The steps in order.

The paper separately gives a brief account of inference by back-propagation. Back-propagation computes how a prediction error should affect the values that can be changed. In the inference step, the paragraph vector is the quantity tuned. The authors distinguish it from the classifier parameters and word vectors, and those parameters are outside the described tuning step. The account leaves implementation details of that step open. The browsing experiments themselves rely on article vectors learned for the corpora under study.

#### Compare documents using their fitted descriptions

For Paragraph Vectors, the paper compares documents by cosine similarity. Cosine looks at the angle between two vectors. If they point in a similar direction, the similarity is high even if one has larger values overall. That makes changes in direction important and differences in overall length irrelevant to the comparison. In ordinary browsing, the article that the reader is viewing supplies one vector and each candidate article supplies another. Ordering the candidates by cosine similarity produces a list of neighbors.

The weighted bag also uses cosine. In that case, the components being compared are term weights. Two descriptions can point in a similar direction because the corresponding words carry similar relative weights. The averaged word-embedding baseline makes its article vector from the word vectors in the document. Each word contributes to the article’s average, and the resulting location reflects their combined coordinates. These baselines help show what information is available through explicit vocabulary weighting or through learned word representations, with the paper’s document training furnishing a further alternative.

For LDA, the authors vary the topic count and use Gibbs sampling for 500 iterations. Gibbs sampling repeatedly updates parts of the inferred assignments in light of the current values of the other parts. The paper gives α as 0.1 and chooses β from values between 0.01 and 0.000001. Here α is the prior parameter associated with the distribution of topics within a document, and β is the corresponding prior parameter for the distribution of words within a topic. The settings govern the distributions used in fitting the topic descriptions.

The LDA comparison uses the posterior topic proportions, meaning the mixture estimated after taking the words in the article into account. The authors use Hellinger distance to compare these probability distributions. A smaller distance means that the estimated shares are more alike. They explain in the comparison of Wikipedia neighbors that Hellinger distance suits LDA and cosine distance suits Paragraph Vectors. The ranking experiment can accommodate both because the measures only need to express which candidate each procedure puts closer to its query.

#### Move the query with a pair of words

A vector search can begin at any position expressible in the same coordinates as the candidate articles. This makes it possible to start with a document vector and then adjust it. The Wikipedia demonstration begins with the article about Lady Gaga. The authors express a request for a Japanese counterpart with the following operation.

```
pv(“Lady Gaga”) − wv(“American”) + wv(“Japanese”)
```

The function `pv` gives the paragraph vector of the article identified inside its parentheses. The function `wv` gives the word vector for the term inside its parentheses. The quotation marks enclose the title or a word. The minus sign subtracts corresponding coordinates, and the plus sign adds corresponding coordinates. The final vector becomes the query for a neighbor search. The starting article contributes its entire learned position, and the difference between the two word vectors determines the direction and extent of the adjustment.

What makes this interesting is the kind of request it expresses. An article may be a useful starting point because of several properties at once. The word pair gives the authors a way to say which feature they would like to change. The numerical procedure acts on all coordinates through the difference between the word vectors. Its success is judged by inspecting the articles retrieved around the resulting query, where the relevant interpretation is whether the candidates suggest a Japanese counterpart.

For arXiv, the starting point is the original Paragraph Vectors paper. The desired shift is from a neural approach towards a Bayesian one. The authors use the word vectors obtained during the training of the paragraph vectors.

```
pv(“Distributed Representations of Sentences and Documents”) − wv(“neural”) + wv(“Bayesian”)
```

The function `pv` returns the document vector for the paper named inside its parentheses. The function `wv` returns the vector of the word inside its parentheses. Quotation marks identify these textual arguments. The minus sign subtracts the “neural” vector coordinate by coordinate, and the plus sign adds the “Bayesian” vector in the same way. The resulting coordinates are compared with vectors of actual arXiv papers to identify nearby candidates.

The two demonstrations share a procedure. Each starts with a document rich enough to express several aspects of the reader’s interest. A pair of terms encodes the requested change. The authors then inspect what the new neighborhood contains. This illustrates what the paper means by local and nonlocal browsing. A search can explore the surroundings of a known article directly, or begin its exploration at an adjusted point selected through arithmetic.

### Experiments and results

#### How a triplet becomes a test

A triplet gives a system a starting article and two candidates. One candidate forms the pair that the authors expect to be closer. The other provides the comparison against which that expectation is tested. A correct ordering puts the expected neighbor ahead of the comparison article. With cosine, it needs the higher similarity. With Hellinger distance, it needs the lower distance. The measurement across the triplets is thus about how often the intended ordering is recovered.

This design lets the authors compare representations with very different meanings for their coordinates. A topic proportion and an embedding component can contribute to scores that live on different scales. Each comparison can still return an ordering of the candidates. The evidence concerns which document the procedure would prefer, given the particular alternatives in the triplet. The papers and articles used to construct the tests give the authors a way to exercise that ability at the scale of their collections.

The source of the expected order is therefore central. The authors build Wikipedia triplets both by hand and from category membership. The arXiv test uses overlapping subject labels. A system could find some near neighbors that make sense to a reader yet disagree with the labels used for a triplet. Success across many such comparisons shows that the representation captures relations of the kinds selected by the authors or expressed in the metadata. The exact construction makes clear which kinds those are.

#### The Wikipedia collection and its neighborhoods

For Wikipedia, the authors extract the main text of 4,490,000 articles from the [English](https://md.research.elamur.ai/free/en/topics/english/) edition. They remove links and set a frequency cutoff, leaving 915,715 words in the vocabulary. The text that remains after preparation is used to train article vectors. Wikipedia provides both a broad collection of written material and a source of category memberships that can be applied later to the rankings.

To inspect the space at a glance, the authors use t-SNE, a way of placing high-dimensional points in a display where groups can be seen. They observe that articles in the same category tend to group together. The sports articles are more spread out in the display. The authors relate that pattern to the variety of sports described in Wikipedia. The visualization offers an overview of how content is arranged. It leaves the quantitative question of who ranks ahead of whom to the triplet evaluations.

The paper also looks directly at candidate articles returned for “Machine learning.” The authors compare the neighbors from Paragraph Vectors with those from LDA and identify entries they consider unrelated to the starting article. They judge the Paragraph Vectors list to be better overall in this example. Here the object of inspection is a list a reader might actually browse. Whether a particular entry is useful can be judged with the starting topic in mind. The triplet tests extend the examination of rankings to many more choices.

Lady Gaga supplies a second kind of Wikipedia example. The article’s original vector produces a list of nearby pages. The vector moved in the direction from “American” to “Japanese” gives the authors another list to inspect. In the ordinary search, the article itself stands for the reader’s interests. In the adjusted search, the reader’s interest is narrowed by a particular requested change. The examples illustrate the possibility of moving through the corpus by specifying how a desired result ought to differ from a known page.

#### Wikipedia rankings from hand judgments and categories

The hand-built Wikipedia evaluation contains 172 triplets. The authors choose them using their knowledge of the subjects involved. In one example, machine learning is the anchor, and deep learning is the preferred candidate over computer networks. In another, the article about Facebook is expected to sit closer to Google than the one about Walmart. Such judgments give the test a way to favor recognizable relationships between subjects or entities even when the candidate articles are all plausible things to compare.

The authors also include comparisons that turn on finer distinctions. They use San Diego as an anchor for a choice between Los Angeles and San Jose, giving Los Angeles the preferred position. All the candidates are places of the same general kind, so a broad grouping of cities can be compatible with either ranking. A correct prediction requires the representation and its similarity rule to favor the particular connection that went into constructing the example. The authors present this as a case that can demand a deeper reading of the material.

The generated Wikipedia test contains 19,876 triplets. A designated pair has an article category in common. The remaining article is selected outside that category, and it can be in a sibling category. The construction is random subject to the category rule. The paper makes the Wikipedia triplet data available as an archive. Compared with hand selection, category membership makes it practical to assemble a much larger evaluation under a consistent rule.

One example generated this way expects the article on Britney Spears to be closer to Barack Obama than the article on China is. The expected ordering is there because of how the articles were selected, even if the reason for grouping the first pair is less immediately evident from the titles. This is an important property of the experiment. Category membership can reflect a shared attribute broader than the central subject of an article. A successful ranking agrees with the kind of relation represented by the category.

The rule for selecting the comparison article can also produce different levels of difficulty. A sibling category makes it possible for the comparison article to cover similar material while missing the particular shared category. Other draws may yield a comparison whose subject is farther away. The reported behavior across the generated triplets reflects that mix. The handwritten collection provides a complementary test because the authors can directly choose the relationship that should govern each ranking.

The authors report that Paragraph Vectors beats LDA in the Wikipedia triplet experiments. Their discussion says the advantage holds across the embedding sizes they studied. The Wikipedia results put the peak for Paragraph Vectors at 10,000 dimensions. That number describes the setting at the peak, namely how many coordinates make up the article vector. The authors also say that averaging word embeddings beats LDA. A useful Wikipedia ranking can therefore draw substantial information from learned word coordinates even when those coordinates reach the article representation through an average.

Taken together, the Wikipedia results connect three observations. Some categories appear grouped in the visualization. The authors see more suitable neighbors for their machine-learning example with the document vectors. Across the triplet evaluations, Paragraph Vectors does better than the topic method under both author judgment and category-based construction. The triplets are the evidence that the method’s advantage extends beyond the particular articles featured in the browsing examples.

#### The arXiv collection and rankings by subject

The arXiv corpus contains 886,000 full papers. The authors extract text from PDFs and take the latest available revision of each paper. After applying a minimum frequency cutoff, they retain 969,894 vocabulary items. The input comes from whole papers, giving the document vectors access to terminology across the text. The expected relations in the ranking experiment come from arXiv subject assignments.

A related pair shares at least one subject. To form the comparison pair, the authors keep the first paper as the anchor and draw another paper at random from those with no subject in common with it. This yields 20,000 triplets. A paper can have several subjects, and the rule needs only an overlap for the designated related pair. The condition for the other candidate is specifically about its overlap with the anchor. That is the comparison the ranking must get right.

This construction rewards representations that recover the broad affinities recorded in the subject assignments. Two papers that share a subject may approach quite different questions within it. Conversely, a paper outside the anchor’s subject assignments might still contain a useful technique for someone reading the anchor. The subject rule gives the authors a reproducible basis for choosing test pairs. Its connection to a real reader’s interests depends on what sort of relation that reader is seeking.

For examples of ordinary browsing, the authors inspect neighbors of the original Paragraph Vectors paper and of the current study. They then examine the query that shifts the original paper’s vector from “neural” toward “Bayesian.” The examples suggest to the authors that the representation can be useful for looking up related work and for redirecting a search. They show how a method-level request might be investigated in the same collection used for ordinary comparisons.

On the subject-based triplets, Paragraph Vectors performs about as well as LDA at its best topic count. Both methods do better than the vector-space baseline. The authors report a peak for Paragraph Vectors at 100 dimensions. They also observe that changing the document-vector size produces less variation in its results than changing the number of topics does for LDA. The relative stability and the agreement near the best result are separate findings. A procedure may be competitive at its best setting while requiring more care in choosing that setting.

The chart compares the sizes of the Paragraph Vectors settings at the reported peaks. Its preference for the smaller value is about compactness, measured by the number of coordinates per article. Each peak belongs to its own triplet evaluation.

Embedding dimensions at peak Paragraph Vectors triplet performance on Wikipedia and arXiv The arXiv peak occurs at a more compact setting than the Wikipedia peak.

**The numbers**

| System or setting | embedding dimensions |
| --- | --- |
| Wikipedia Paragraph Vectors | 10,000 |
| arXiv Paragraph Vectors (this paper) | 100 |

The numerical peak settings identify where the authors report the best behavior in their sweeps. The paper’s discussion gives the triplet performance comparisons as relative outcomes: an advantage over LDA on Wikipedia, and a result comparable to the best LDA setting on arXiv. The two collections furnish distinct tests, so the compactness comparison does not express the size of a ranking advantage or how much easier either benchmark is. It shows that the setting associated with the strongest observed Paragraph Vectors performance depends on the evaluation in which it is chosen.

### What the ablations show

#### What changes when word vectors are trained jointly?

The training comparison that most directly addresses the method’s design concerns the added skip-gram task. The authors report preliminary evidence that training word embeddings together with paragraph vectors improves the quality of the latter. In the Wikipedia discussion, they again identify joint training as beneficial. In this comparison, the question is whether the document vectors work better when the procedure learns from local word relationships alongside its predictions from article vectors. The reported direction of the effect favors joint learning.

A document predictor in the chosen setup has a broad job: it must account for words throughout an article from a common input. The word task gives a more local signal because its examples depend on which words occur near a particular word. That difference explains what the change contributes to the training setup. The reported improvement tells us that the added signal helps under the tested conditions. The paper leaves open where in the learned coordinates the benefit appears and which sorts of test pairs gain most from it.

The word average helps interpret the broader comparison, although it changes the representation rather than isolating a training component. Its good performance against LDA on Wikipedia shows that a procedure can recover useful article relations by aggregating what the word vectors already encode. The joint-training result concerns a further question: whether training those word vectors alongside article vectors helps the directly fitted document description. The evidence for the two claims comes from distinct comparisons.

There is a separate gain in the kinds of operations the procedure can express once word vectors are available for the arithmetic. The papers retrieved after adjusting a query reveal something about the relation between document and word coordinates in those examples. The reported joint-training gain on Wikipedia speaks to ordinary comparisons of document vectors. Success on the two kinds of test would be compatible, but the arithmetic examples do not establish the reason for the improved triplet rankings.

#### What changes when the representation grows?

The size sweeps alter a setting whose consequences can reach every document. More coordinates give the fitting procedure more numerical degrees of freedom for representing patterns in an article. Whether the resulting distinctions help the benchmark depends on how they affect the ordering of candidates. The paper observes that the Wikipedia and arXiv peaks occur at different sizes, so the measurements support choosing capacity in relation to the corpus and task. A peak within a sweep supplies evidence about settings tried in that experiment.

For LDA, the comparable sweep varies the number of topics. Adding a topic changes the components available for describing the document’s mixture. That has a different interpretation from adding an embedding coordinate, so the comparisons concern the behavior of each method under changes to its own size setting. On arXiv, the authors observe greater stability for Paragraph Vectors over the range studied. The sweep thus supplies information that a comparison of best settings alone would leave out: how much measured performance moves as a practitioner changes the size.

The Wikipedia sweep bears on a different concern. The authors report that the lead over LDA is present across the Paragraph Vectors sizes they examine. Within that study, it is therefore a recurring result instead of a conclusion supported solely by the setting at the peak. The size at which performance peaks can still matter for choosing a configuration. The broader pattern matters when judging whether the advantage is confined to a particularly favorable document dimensionality.

#### What happens when the input or baseline changes?

A preliminary comparison adds bigrams to the unigrams. A bigram can treat a recurrent pair as its own item instead of leaving the two words to contribute individually. The authors report that this addition fails to improve the final vectors. The observation applies to that specific way of supplying short sequences. The study leaves open how other treatments of local order or phrases would affect these rankings, including how the Distributed Memory version would fare on the same triplets.

The authors also try TF-IDF weighting in LDA, involving words and their inferred topic assignments. They report unchanged performance from that modification on both corpora. Its scope is the topic method as tested. The weighted bag separately uses TF-IDF to construct the document vector itself, so in that baseline the weights have a different role. Reading the experiments together keeps the negative result attached to the training or inference choice the authors actually varied.

The visual and browsing checks complement the comparisons that vary a setting. The category display looks for large-scale structure. The individual neighbor lists show what particular queries retrieve. The arithmetic examples ask what happens when the query point is moved using words. These analyses can make a learned document space easier to inspect, while the joint-training, vocabulary, and size comparisons give the evidence for how changes to the representation affect the reported evaluation.

### Limitations

#### Qualifications in the authors’ account

The authors characterize the evidence for the original method as limited in scope and set out to extend it to similarity between long documents. Their experiments cover encyclopedic entries and research papers. They suggest possible applications such as dataset exploration, book recommendation, and reviewer allocation. Those applications appear in the discussion as uses that the observed browsing behavior motivates. The reported benchmarks judge article rankings and selected query examples in Wikipedia and arXiv.

The authors also acknowledge that distributed descriptions are harder to interpret than the earlier representations they discuss. A reader can look at a set of neighbors and recognize a common subject or approach. Tracing a match to individual coordinates is a different task. The coordinate names in a weighted bag supply a direct connection to words, and topic proportions are organized around inferred components. The paper does not assign corresponding interpretations to the coordinates of a paragraph vector. Its evidence about what the representation captures comes from its behavior as a whole.

The authors’ account of LDA also has an important qualification. The advantage in Wikipedia differs from the result on arXiv, where LDA at its best topic count is competitive. The claim that the representations support useful similarity judgments is broader than the claim that one method leads a particular benchmark. The arXiv finding makes dimensional stability part of the comparison alongside peak performance. Generalizing either conclusion requires attention to which relations the experiment rewards.

#### Limits that follow from the ranking design

The category and subject rules make it possible to generate many triplets. They also define the relation being measured. Being in the same Wikipedia category is evidence of a common attribute. Having an arXiv subject in common is evidence of some disciplinary overlap. A reader might instead want to know whether two papers solve the same problem, give compatible explanations, or would be useful in the same immediate task. Such judgments can cross or refine the boundaries of the labels. The generated rankings establish agreement with the construction rules and give indirect evidence concerning these more specific needs.

An outside-category Wikipedia candidate can still be drawn from a related branch of the category structure. An arXiv candidate that shares no subject with the anchor can still address related material. The word “unrelated” in a triplet should therefore be read in light of the selection rule. The rules supply contrasts suitable for measurement. They leave open how many label-defined comparison articles would count as genuinely unsuitable to readers with a stated reason for browsing.

The manual Wikipedia examples address part of this problem by allowing a relationship to be specified directly. They introduce another issue: the intended ranking rests on the authors’ judgment. The paper describes the basis for choosing these examples and gives cases that illustrate their rationale. Agreement among independent readers is unreported. With a choice among cities, for example, geography and other possible grounds of comparison can suggest different answers. The manually preferred order works as a test answer while leaving that broader judgment open.

Triplets also reduce a search to a limited decision. Knowing that the system prefers the intended candidate to a designated alternative helps characterize relative similarity. A reader exploring a collection faces a longer ranking and may care about where the first genuinely helpful result appears or whether the list covers distinct aspects of the subject. The inspected neighbor lists give a view of that broader experience for a few starting documents. The systematic experiment measures success at pairwise ordering within its triplets.

For the document vectors, fitting is described on the collections from which the evaluation articles are taken. The judgments needed for those rankings come from separate sources, and the text of the articles themselves is used to fit their vectors. This arrangement tests similarity among articles already represented in the collection. The paper leaves separate evaluation on incoming documents open. Its short description of tuning an inferred vector explains which values are adjusted, but there is no reported comparison showing whether the rankings hold up for articles introduced later.

#### Limits on the interpretation of size and method comparisons

Changing from Wikipedia to arXiv changes the writing, the collection, and the way triplets are defined. The difference in peak sizes could reflect any of those factors or their interaction. The experiments do not vary them independently. The sound conclusion is that the sweeps yield different best settings in the reported setups. The work leaves open which characteristics of an unfamiliar corpus would predict a useful size before running a comparison.

The paper also pairs each representation with a way of calculating closeness. The LDA results use Hellinger distance on topic proportions. The paragraph-vector results use cosine. The bag of word weights uses cosine as well. This is a natural comparison of complete ranking procedures, each with a measure that suits its output. It leaves the separate effect of the distance measure unmeasured. Likewise, the choice of the more efficient Distributed Bag of Words setup makes it the subject of the main experiments. The paper gives no direct comparison of the two Paragraph Vectors variants on these rankings.

The reported peaks are selected from the observed results. The paper does not describe an independent evaluation specifically for checking that the chosen peak setting remains optimal after selection. Uncertainty across repeated samples of the generated triplets is also unreported. This matters most when reading phrases such as “on par” on arXiv. The observed comparison conveys how the procedures performed in the study. It gives no numerical uncertainty for the difference or guarantee that the same setting would win again.

#### Limits of the visual and arithmetic evidence

The t-SNE display is an inspection of the fitted Wikipedia space. It gives the authors a view of how categories appear grouped and how spread out some articles are. The display itself does not score triplets or explain which aspects of the text produce a group. Its evidence is consequently about visible organization. The reported ranking experiments are the place to look for whether the comparison rule tends to favor the designated neighbor.

The word-arithmetic examples establish that the authors can formulate a directed query and inspect plausible results in the neighborhoods it produces. They test particular choices of article and replacement terms. The paper gives no set of analogy judgments with which to estimate reliability across many requests. It also leaves open how a reader should choose suitable words for a desired change. The examples support the possibility of directed browsing, while the frequency of useful results under that operation remains unmeasured.

### What came after

The later citations connect this study to large-scale machine learning and to the automatic evaluation of longer texts. The common point of contact is the use of a learned representation for material longer than an individual word. In this paper, the purpose of the representation is to help rank related articles. The titles of the later evaluation papers establish a different purpose for comparing texts. The citations mark that connection, while the details of their use of Paragraph Vectors are unspecified.

[TensorFlow](https://md.research.elamur.ai/free/en/papers/abadi-2016-tensorflow-system-large-scale-machine/) (2016) cites the paper in a study of a system for large-scale [machine learning](https://md.research.elamur.ai/free/en/concepts/machine-learning/). Paragraph Vectors gives a concrete example of the sort of representation-learning problem that can arise at corpus scale. A trainable description is associated with each document, and word predictions repeatedly supply evidence for updating it. The connection visible in the citation is between the document embedding work and the literature on systems for large-scale learning. The citation leaves the precise role of the algorithm and its experiments in the systems paper unspecified.

[Sentence Mover’s Similarity](https://md.research.elamur.ai/free/en/papers/clark-2019-sentence-mover-s-similarity-automatic/) (2019) cites the study in work on automatic evaluation for multi-sentence texts. The shared issue is how to make an informative comparison when each text contains several sentences and can cover several aspects of a subject. The earlier study uses an expected ordering of related articles to test the result of a comparison. The later work addresses comparisons in the service of evaluation itself. This change of purpose matters: a useful browsing measure helps a reader find related content, while a measure for evaluating text has to serve the judgments relevant to that evaluation. The citation establishes the link between the papers, with the later work’s exact use of the paragraph-vector procedure left open.

[Evaluation of Text Generation](https://md.research.elamur.ai/free/en/papers/celikyilmaz-2020-evaluation-text-generation-survey/) (2020) cites the article in a survey of how to evaluate [text generation](https://md.research.elamur.ai/free/en/topics/text-generation/). Its survey scope places the document similarity study in a wider discussion about what comparisons of texts can measure. The Paragraph Vectors paper offers a concrete case: a comparison is judged by whether it recovers an order based on human choices or shared labels. For generation, the relation of interest depends on what the evaluation is meant to reward. The citation connects the two settings at the level of text comparison. It leaves the survey’s treatment of particular Paragraph Vectors results unspecified.

## Cite

Cite as Andrew M. Dai, Christopher Olah and Quoc Viet Le. 2015. Document Embedding with Paragraph Vectors. arXiv (Cornell University).

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.48550/arxiv.1507.07998](https://doi.org/10.48550/arxiv.1507.07998) · [arXiv 1507.07998](https://arxiv.org/abs/1507.07998)

```bibtex
@misc{dai2015document,
  title = {{Document Embedding with Paragraph Vectors}},
  author = {Andrew M. Dai, Christopher Olah and Quoc Viet Le},
  year = {2015},
  doi = {10.48550/arxiv.1507.07998},
  eprint = {1507.07998},
  archivePrefix = {arXiv},
  url = {https://doi.org/10.48550/arxiv.1507.07998}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
