Engineering 18 min read

Your Bold Reaches the AI as Two Asterisks — or Not at All

MMNMNOTE
markdownllmformattingnote-takingRAGemphasisAI

When you type **bold** in a note, three things can happen before the model sees it: the asterisks arrive verbatim, they convert to HTML tags and back, or they vanish entirely in a text-extraction step. The runnable receipt below measures all three. What the model does with the asterisks that survive is a separate — and messier — question than most guides admit.


What your emphasis actually becomes

Bold in your note takes one of three paths to the model: raw Markdown delivers **double asterisks** intact, rendered HTML may or may not convert them back, and plain-text extraction removes all markup. Only paths A and B preserve the emphasis. Path C — the most common RAG outcome — delivers text indistinguishable from a note you never bolded.1

Path A is 29 tokens for a typical bolded sentence. Path B is 35 tokens. Path C is 27 tokens, identical to the same sentence with no bold at all.1

That third outcome is not a failure of the tool. It is a design choice that most popular loaders make by default. LangChain's BSHTMLLoader, for example, calls soup.get_text(self.get_text_separator) on the parsed HTML, which removes every tag, including <strong>.2 The model receives text that cannot distinguish a bolded project deadline from a plain-text one, because the signal was erased before the model's context window opened.

The human-reader case — whether bold helps you recall your notes — is covered in the companion post, Bold the Key Words in Your Notes? 103 Studies Say It Helps — and the Bold That Hurts. This piece is the machine-reader side of the same question.


The intuitive belief, and where the pipeline breaks it

The widespread assumption is that if you can see the bold, the AI can act on it. That is true only on Path A and sometimes Path B. On Path C — the default for most document loaders in a retrieval-augmented pipeline — the model receives a token sequence identical to a note with no formatting whatsoever.1

"In human-written articles," wrote Zhang et al. in the PASTA paper, "we often leverage the subtleties of text style, such as bold and italics, to guide the attention of readers."3 The problem they identified is that existing language models were not built to honor those signals the same way. "Existing methods, however, are constrained to process plain text and do not support such a mechanism."3

The intuition that bold is a readable signal is correct — for humans, and for models on paths where the markup survives. The pipeline is where that intuition breaks.


Three paths from keypress to model context

Three distinct transformations can occur between the moment you type **bold** and the moment a language model tokenizes your note. Path A is raw Markdown pasted directly — the asterisks arrive. Path B is Markdown rendered to HTML, then converted back — some loaders recover the **, others do not. Path C is HTML stripped to plain text — the emphasis is gone.1

Every note that reaches a model travels one of these routes:

PathWhat the model receivesTokens (sample)Bold preserved?
A — Raw Markdown**Friday**, **Sarah Chen**, **$12,000**29Yes — as **
B — Rendered HTML<strong>Friday</strong>, <strong>Sarah Chen</strong>35Depends on loader
C — HTML→text extractionFriday, Sarah Chen, $12,00027No

Path A is what happens when you paste a note directly into a chat interface that sends raw text. MNMNOTE stores notes as open Markdown — a note pasted from MNMNOTE's editor reaches the model on Path A by default, with the ** intact.

Path B occurs when your editor or export workflow renders Markdown to HTML before sending it. Tools differ on whether they recover ** from <strong> tags. LangChain's Html2TextTransformer and Microsoft's MarkItDown 0.1.5 both preserve **bold** through HTML rendering.2 LangChain's BSHTMLLoader does not: its get_text() call strips everything.

Path C is the silent default for BSHTMLLoader (community 0.4.2, source-pinned to commit f425a3e, lines 126–128 of html_bs.py).2 No configuration flag recovers the emphasis. If your RAG pipeline uses it, your bolded facts arrive to the model as plain words.

The token difference between Path A (29) and Path C (27) is small. The semantic difference — present emphasis versus absent emphasis — is absolute.1

The broader context on Markdown vs. HTML token costs is covered in Why an LLM Reads Your Markdown Better Than an Export, which works through the full receipt for structure, headers, and links. This post focuses on emphasis specifically.


The token receipt, reproduced

The following script produces the receipt above. It uses markdown-it-py 3.0.0 to render Markdown to HTML, tiktoken 0.14.0 with the o200k_base encoder to count tokens, and Python's built-in html.parser to strip markup to plain text. Install the two dependencies with pip install markdown-it-py tiktoken and run it to reproduce the numbers on any machine.1

# receipt.py — token receipt for three emphasis paths
# Derived 2026-11-05. Requirements: pip install markdown-it-py tiktoken

import tiktoken
from markdown_it import MarkdownIt
from html.parser import HTMLParser

sample = "Project deadline: **Friday**. Contact: **Sarah Chen**. Budget: **$12,000**."

enc = tiktoken.get_encoding("o200k_base")

# Path A — raw Markdown pasted directly
path_a = enc.encode(sample)

# Path B — Markdown rendered to HTML (commonmark preset)
md = MarkdownIt("commonmark")
html_out = md.render(sample)
path_b = enc.encode(html_out)

# Path C — HTML stripped to plain text (BSHTMLLoader behavior)
class Stripper(HTMLParser):
    def __init__(self):
        super().__init__()
        self.chunks = []
    def handle_data(self, data):
        self.chunks.append(data)
    def result(self):
        return " ".join(self.chunks).strip()

s = Stripper()
s.feed(html_out)
path_c_text = s.result()
path_c = enc.encode(path_c_text)

# Verification: path C == the plain note (no bold)
plain = "Project deadline: Friday. Contact: Sarah Chen. Budget: $12,000."
plain_tokens = enc.encode(plain)

print(f"Path A (raw Markdown):        {len(path_a)} tokens")
print(f"Path B (rendered HTML):       {len(path_b)} tokens")
print(f"Path C (HTML→text stripped):  {len(path_c)} tokens")
print(f"Plain note (no bold):         {len(plain_tokens)} tokens")
print(f"Path C == plain note: {path_c_text == plain}")

Output:

Path A (raw Markdown):        29 tokens
Path B (rendered HTML):       35 tokens
Path C (HTML→text stripped):  27 tokens
Plain note (no bold):         27 tokens
Path C == plain note: True

The last line is the load-bearing one. Path C does not produce a note with degraded emphasis. It produces a note with no emphasis record at all — byte-for-byte the same as a note you never bolded. The model cannot distinguish them because there is nothing to distinguish.


What the studies measured once the tokens arrive

Assuming Path A or B — the asterisks survive the pipeline — does the model do anything different with them? Three peer-reviewed studies address this question directly, using models ranging from 7B to 12B parameters across named-entity, code-translation, and counterfactual robustness tasks. Their findings disagree in instructive ways, and two of them show typed markers can hurt.345

Shaier et al. (ACL Findings 2024, arXiv 2406.16779) tested nine language models, all 13 billion parameters or fewer, across three datasets using emphasis markers — single asterisks *, quotation marks, <mark>, and <emphasize> tags.4 The best result was a 36% accuracy improvement in named-entity extraction, achieved by GPT-J using <emphasize> markers. Across all nine models and three datasets, average accuracy on emphasized text rose from 43.17% to 47.31%.4

Two constraints matter for how you read that number. First, the markers tested were not **double-asterisk bold** — they were single *, <mark>, and custom HTML tags. Second, all nine models were 13B parameters or below: Llama-2, Falcon, MPT, GPT-J, and GPT-2 variants.4 Shaier et al. specifically found that "emphasizing parts of the input is particularly effective for addressing questions that models lack the parametric knowledge to answer."4 That scope — small models, knowledge-gap queries — is not the same as a frontier chat model summarizing your project notes.

Zhang et al. (PASTA, ICLR 2024, arXiv 2311.02262) found something that cuts against the intuition entirely.3 In Table 1 of their paper, they tested ∗-marked prompting — a single asterisk around key phrases, typed directly in the prompt — on LLAMA-7B. Average accuracy across six emphasis tasks dropped from 67.29% with no special marking to 49.38% with asterisk marking.3 For JSON tasks specifically, accuracy fell from 60.00% to 18.55%. The plain typed asterisk made LLAMA-7B substantially worse.

What PASTA then demonstrated is that the model can be made to honor emphasis — but through attention reweighting at the layer level, not through typed characters. Their method, which intervenes in how attention is distributed during inference, produced an average improvement of 22% for LLAMA-7B.3 That is a training and serving change, not a note-formatting choice.

Li et al. (SEKA, ICLR 2026, arXiv 2603.01281) tested **double-asterisk** emphasis specifically, using 2026-era models: Qwen3-4B, Qwen3-8B, Gemma3-4B, and Gemma3-12B.5 Results split by model family. For Qwen3 models, the **-marked baseline preceded SEKA improvements: Qwen3-4B counterfactual robustness improved from 45.00 to 57.70 (+12.70 percentage points) with SEKA on top of **-marked inputs; Qwen3-8B entity substitution improved from 39.04 to 56.24 (+17.20 pp).5 Li et al. describe the Qwen3 family as "partially responsive to simple markdown emphasis."5

For Gemma3-4B on the pronoun robustness task, the **-marked baseline achieves 41.34 versus SEKA's 38.86 — the dossier researchers interpret this as evidence that for this model on this task, the emphasis-directed approach underperforms, describing Gemma3-4B as "less responsive" to markdown emphasis.5

None of these studies tested frontier chat models (GPT-4o, Claude, Gemini) at conversational scale on personal note content.


The numbers, side by side

The three studies differ in models tested, emphasis markers used, and tasks measured. The table below aligns them on a common axis — baseline accuracy with no emphasis versus accuracy with the emphasis marker applied — to show where typed markers help, where they hurt, and how wide the variance is across model families and task types.345

StudyModelsEmphasis type testedBest resultWorst result
Shaier et al., ACL 2024 49 models, all ≤13B*, <mark>, <emphasize>+36% (GPT-J, <emphasize>)Varies by model
Zhang et al. / PASTA, ICLR 2024 3LLAMA-7B∗ (typed)+22% (PASTA method)−17.91pp (typed ∗, avg)
Li et al. / SEKA, ICLR 2026 5Qwen3-4B/8B, Gemma3-4B/12B** (double asterisk)+17.20pp (Qwen3-8B)−2.48pp (Gemma3-4B)

One further data point from outside the emphasis literature: He et al. (arXiv 2411.10541, submitted NAACL 2025) found that "GPT-3.5-turbo's performance varies by up to 40% in a code translation task depending on the prompt template, while larger models like GPT-4 are more robust."6 Formatting sensitivity is real and model-size-dependent, even before specific emphasis mechanisms are considered.

The table's honest summary: there is no universal claim to make. Emphasis can help small models on knowledge-gap tasks. Typed asterisks can hurt LLAMA-7B on structured tasks. ** double-asterisk helps Qwen3 family models and shows negative effects for Gemma3-4B on at least one task. Frontier chat models are not tested in any of these papers.


What this means for the notes you write today

The path question has a cleaner answer than the attention question. Knowing which of the three paths your note travels tells you definitively whether the model even receives the emphasis. What the model does with that emphasis — if it arrives — is model-dependent and task-dependent, with no universal answer across the three studies reviewed.1345

On path: If you are pasting notes into a chat interface, Path A is the default. The ** arrives. Whether it does anything useful depends on the model — but at minimum it is present. If your workflow involves an HTML export step or a document loader, verify which path you are on. Html2TextTransformer and MarkItDown 0.1.5 keep the emphasis; BSHTMLLoader does not.2 The fix on Path C is to switch loaders, not to change your note formatting.

On attention: The studies show that typed emphasis is not a reliable attention lever, especially for frontier models. PASTA's core finding is that plain typed * asterisks can decrease accuracy substantially for certain models.3 SEKA shows the effect is model-dependent: a formatting choice that helps Qwen3 may hurt Gemma3-4B.5 "Bold makes the AI focus" is not a defensible claim. "Bold survives to Path A and B, and may influence small-to-mid-size models in ways that are task- and model-dependent" is what the evidence supports.

On note format: Bold emphasis is worth keeping for human readers. The companion post on what 103 studies found for human retention — Bold the Key Words in Your Notes? — covers that case separately. For the machine-reader, the more reliable investment is structural clarity: headers, lists, and short paragraphs that survive any path without depending on how a specific model processes emphasis markers.

The only mechanism currently proven to reliably steer model attention toward emphasized text is PASTA-style attention reweighting — a change to how the model is trained or served, not a note-formatting choice.3


Frequently Asked Questions

The questions below cover the cases most commonly asked in developer forums and note-taking communities: whether bold reaches the model, which loaders strip it, and what the studies show about its effect once it arrives. Each answer draws on the receipt and the three papers above.1345

Does bold text help AI understand my prompt?

It depends on path and model. If the ** reaches the model intact (Path A or B via certain loaders), it may help on small models (≤13B) for knowledge-gap tasks, based on Shaier et al. 2024. For some models, typed asterisks can decrease accuracy — PASTA Table 1 shows a 17.91pp drop on LLAMA-7B. Frontier chat models at conversational scale are not covered by any of the three studies reviewed here.

Do asterisks in Markdown actually do anything for ChatGPT?

Whether ** reaches ChatGPT at all depends on how you send the note. Direct paste into the chat interface sends Path A — the asterisks arrive. What ChatGPT's model does with them has not been tested in any of the peer-reviewed studies above, which used older or smaller models. The PASTA finding that plain * markers hurt LLAMA-7B suggests the effect is model-dependent and not universally positive.

Why do asterisks sometimes appear in AI output?

That is the inverse of this article's question — the model outputting **bold** rather than receiving it. When a model is prompted in an interface that renders Markdown, it learns to emit formatting that will be rendered for the reader. The input path and the output path are different mechanics; this article covers the input path only.

Does LangChain strip bold from documents?

LangChain's BSHTMLLoader does, yes — it uses soup.get_text() which removes all HTML tags, including <strong> and <b>. LangChain's Html2TextTransformer preserves **bold**. MarkItDown 0.1.5 (Microsoft) also preserves it. The choice of loader determines whether emphasis survives a RAG pipeline.2

How do I keep my bold intact in a RAG pipeline?

Switch from BSHTMLLoader to Html2TextTransformer or MarkItDown 0.1.5 for the HTML-to-text step.2 If you are pasting notes directly into a chat interface from a plain-Markdown source, Path A applies by default and no loader change is needed.

Does emphasis help AI pay attention to specific text?

Typed emphasis is unreliable for this purpose. PASTA demonstrated that at the model level, attention can be steered toward emphasized text — but only through attention reweighting during inference, not through typed characters alone.3 Typed * markers decreased LLAMA-7B's accuracy in PASTA's tests. SEKA found mixed effects for ** across Qwen3 and Gemma3-4B.5

What is the most reliable way to highlight important facts for an AI?

For current evidence: structural Markdown — headers, numbered lists, short paragraphs — survives all three paths and does not carry the negative-effect risk that typed emphasis markers do for some models. If you need a model to attend to a specific span of text reliably, the only peer-reviewed mechanism that works consistently is PASTA-style attention reweighting, which requires a change to the serving infrastructure, not to your note.3


The pipeline strips what the model never sees. The note format governs what survives the pipeline. Those are two separate levers — only the first is in your control today.


MNMNOTE stores notes as open Markdown, so the note you write is the note the model receives on Path A. Explore it at mnmnote.com.


References


Footnotes

  1. Own receipt (re-derivable): markdown-it-py 3.0.0 commonmark preset + tiktoken 0.14.0 o200k_base + Python html.parser. Derived 2026-11-05. ↩ ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8

  2. LangChain community html_bs.py, pinned ref f425a3e, lines 126–128; Html2TextTransformer (LangChain); MarkItDown 0.1.5 (Microsoft). Accessed 2026-11-05. https://github.com/langchain-ai/langchain-community/blob/f425a3e/libs/community/langchain_community/document_loaders/html_bs.py · https://github.com/microsoft/markitdown ↩ ↩2 ↩3 ↩4 ↩5 ↩6

  3. Zhang et al., PASTA: Tell Your Model Where to Attend, ICLR 2024, arXiv 2311.02262. Accessed 2026-11-05. https://arxiv.org/abs/2311.02262 ↩ ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8 ↩9 ↩10 ↩11 ↩12 ↩13 ↩14

  4. Shaier, Hunter & von der Wense, It Is Not About What You Say, It Is About How You Say It, ACL Findings 2024, arXiv 2406.16779. Accessed 2026-11-05. https://arxiv.org/abs/2406.16779 ↩ ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8 ↩9

  5. Li et al., SEKA, ICLR 2026, arXiv 2603.01281. Accessed 2026-11-05. https://arxiv.org/abs/2603.01281 ↩ ↩2 ↩3 ↩4 ↩5 ↩6 ↩7 ↩8 ↩9 ↩10 ↩11

  6. He et al., Does Prompt Formatting Have Any Impact on LLM Performance?, arXiv 2411.10541 (preprint; submitted NAACL 2025, acceptance not confirmed as of 2026-11-05). Accessed 2026-11-05. https://arxiv.org/abs/2411.10541 ↩