---
title: "Enhancing Reinforcement Learning with Dense Rewards from"
description: "Cao and colleagues test whether a critic can improve reinforcement learning by turning comments on parts of a text into rewards for individual…"
canonical: "https://research.elamur.ai/free/en/papers/cao-2024-enhancing-reinforcement-learning-dense-rewards/"
---
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/) · [Constitution](https://md.constitution.elamur.ai/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/cao-2024-enhancing-reinforcement-learning-dense-rewards/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2024](https://md.research.elamur.ai/free/en/papers/2024/) / Enhancing Reinforcement Learning with Dense Rewards from Language Model Critic

# Enhancing Reinforcement Learning with Dense Rewards from Language Model Critic

Paper · 2024 · Meng Cao, Lei Shu, Lei Yu et al.

**Authors:** [Meng Cao](https://md.research.elamur.ai/free/en/authors/meng-cao/), [Lei Shu](https://md.research.elamur.ai/free/en/authors/lei-shu/), [Lei Yu](https://md.research.elamur.ai/free/en/authors/lei-yu/), [Yun Zhu](https://md.research.elamur.ai/free/en/authors/yun-zhu/), [Nevan Wichers](https://md.research.elamur.ai/free/en/authors/nevan-wichers/), [Yinxiao Liu](https://md.research.elamur.ai/free/en/authors/yinxiao-liu/) and [Lei Meng](https://md.research.elamur.ai/free/en/authors/lei-meng/) · **Year:** 2024 · **Venue:** Proceedings of the 2024 Conference on Empirical Methods in Natural Language Processing · **Licence:** [CC BY 4.0 (ACL Anthology)](https://creativecommons.org/licenses/by/4.0/)

[Cited by **10** papers in our library of more than 163,000 papers whose bibliographies we read](https://md.research.elamur.ai/free/en/papers/cao-2024-enhancing-reinforcement-learning-dense-rewards/cited-by/) · Proceedings of the 2024 Conference on Empirical Methods in Natural Language Processing · [licence](https://creativecommons.org/licenses/by/4.0/)

- [Publisher's page](https://aclanthology.org/2024.emnlp-main.515/)
- [PDF](https://aclanthology.org/2024.emnlp-main.515.pdf)
- [DOI 10.18653/v1/2024.emnlp-main.515](https://doi.org/10.18653/v1/2024.emnlp-main.515)

## Summary

A score for a finished piece of writing can tell a learning system how well it did while leaving a practical question unanswered. Which choices produced that result? A continuation can contain both praise and criticism, yet a sentiment classifier may return a single negative score. A summary can capture the main point and still introduce a factual error. In reinforcement learning, the system has to work out how much each decision contributed to the final score. Cao and colleagues study whether a critic that identifies specific passages can make that learning process more efficient.

Their method, Rewards from Language Model Critique, or RELC, first lets a generator finish its response. A critic then reads the response in the context of the task and identifies passages that helped or hurt. The training procedure converts those judgments into rewards attached to the tokens in the marked passages. A separate evaluator still gives the response an overall score, which enters training at the end of the sequence. The authors test a GPT-2 Large generator with a GPT-3.5 critic and also study self-critique with Llama 2, using a fixed critic while updating the generator.

The experiments cover positive sentiment, reduced toxicity, and summaries that better match human preferences. On the 2.5K negative OpenWebText prompts, the share of positive continuations rises from 54.06% with the authors’ terminal-reward baseline to 59.06% with RELC. On the 10K non-toxic RealToxicityPrompts test prompts, the share with at least one continuation judged toxic among 25 attempts falls from 2.6% to 0.8%. On the Reddit TL;DR test set, the preference score rises from 3.25 to 3.88. Human raters also favor the RELC summaries across the dimensions the authors assess, with a particularly clear advantage in factuality. The summaries’ overlap with the reference wording falls on both reported ROUGE measures.

The learning curves show advantages at comparable sample counts in the main experiments. In a Llama 2 detoxification comparison, the advantage also holds when the authors account for training computation. Randomly distributing the local rewards fails to produce the same learning benefit, and an alternative summarization experiment shows little learning-efficiency gain when measured by ROUGE-1. The evidence therefore depends on both what the critic can identify and what the task evaluator rewards. The authors identify critic competence as a limit, especially when the generator’s mistakes become difficult to diagnose.

## Deep dive: Enhancing Reinforcement Learning with Dense Rewards from Language Model Critic

Cao and colleagues test whether a critic can improve reinforcement learning by turning comments on parts of a text into rewards for individual tokens. · about 37 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

#### A score for a sequence leaves work for the learner

A generator produces a response through a succession of small choices. It selects a token, adds it to the text already written, and uses that longer text to decide what to write next. A token is one of the units in the generator’s vocabulary. A phrase can occupy several such units, so a decision about wording can extend over several decoding steps. By the time a sentence or paragraph is complete, many individual decisions have contributed to the result. This is the sequential view behind the paper’s treatment of [text generation](https://md.research.elamur.ai/free/en/topics/text-generation/).

A task evaluator often works at the scale of the entire response. For the sentiment task, it can give a positive-class score to a continuation after reading it. The learner can use that score to favor responses that resemble well-rewarded ones over time. Within any particular continuation, however, the score leaves unresolved the relative contributions of the opening, the final clause, and the words connecting them. A continuation that begins with praise and ends with a complaint can receive the same overall score as one whose tone is mildly negative throughout. The two would call for different local feedback.

The authors describe this as a temporal credit assignment problem. The word *credit* covers both the choices that deserve reinforcement and the choices that warrant discouragement. The term *temporal* refers to their positions in the sequence of decisions. Reward sparsity makes the problem especially visible. Most positions receive no immediate task reward, and the final position carries the scalar judgment for the entire response. Learning can propagate the final reward back to earlier choices, but the evaluator itself supplies no direct indication of which earlier positions mattered most.

Fine-grained feedback can make distinctions that a terminal score obscures. Consider a summary that preserves the principal event in its opening clause, then attributes it to the wrong person. A low whole-summary rating expresses dissatisfaction with the combined result. A local mark on the attribution gives the learner a more specific signal about the step associated with the error. The rest of the summary remains relevant to the whole-response assessment. The attraction of local feedback is that it adds information about where a problem occurs while preserving the usefulness of a score for the complete text. The paper studies that division in [summarization](https://md.research.elamur.ai/free/en/topics/summarization/).

#### Why reinforcement learning was already useful for text

A separate evaluator gives researchers a way to train for properties that are hard to express as direct supervision on the next token. A person may prefer one answer over another, a classifier can assign a sentiment score, and an external service can estimate toxicity. Under reinforcement learning, the generator samples responses and uses numerical feedback to adjust the probabilities of the choices it made. The evaluator can operate separately from the generator’s token probabilities. Human preferences and other rewards that provide no gradient through the evaluator can therefore still influence training.

The paper places RELC in a line of work that applies reinforcement learning to text tasks. Its examples include sequence-level training in machine translation, agents that learn to conduct conversations, and question answering guided by feedback. It also connects this work to the use of pretrained systems as starting points for preference-based optimization. In that setting, the learner already has considerable ability to generate fluent text. The subsequent training stage changes its behavior in ways the task evaluator can recognize, such as better relevance or helpfulness. The paper cites [Training language models to follow instructions with human feedback](https://md.research.elamur.ai/free/en/papers/ouyang-2022-training-language-models-follow-instructions/) and [WebGPT](https://md.research.elamur.ai/free/en/papers/nakano-2021-webgpt-browser-assisted-question-answering/) in this context.

That division between learning to generate and learning what kind of generation to favor makes the design of the reward consequential. A reward for a complete response is convenient to collect, and a learned evaluator can score many samples once it has been trained. The learner still faces a long chain of choices between its opening action and the point where the assessment arrives. RELC asks how to reuse the original evaluator while providing a more detailed account of the sampled trajectory, the sequence of text-generation decisions that led to the response.

#### Earlier ways of adding guidance

The paper discusses reward shaping as an established way to change the learning signal. Potential-based shaping, in the earlier work it cites, can speed learning while preserving the optimal policy under the conditions of that method. This is an important point of comparison because a shaped reward can affect both how quickly the learner improves and which behavior it ultimately favors. Cao and colleagues define their own added rewards through judgments about passages. Their argument for using those rewards is empirical, based on how training proceeds and how the resulting generators perform.

Other earlier work used exploration bonuses. Count-based and related approaches encourage an agent to visit situations it has encountered less often. The supplementary reward in that setting is useful because it leads the agent towards experiences it might otherwise miss. In RELC, the critic instead examines an experience the generator has already produced and identifies where it went well or badly. The paper also cites work that learns a parameterized intrinsic reward during training. It points to the difficulty of optimizing that approach when the calculation requires second-order gradients. [Unifying Count-Based Exploration and Intrinsic Motivation](https://md.research.elamur.ai/free/en/papers/bellemare-2016-unifying-count-based-exploration-intrinsic/) is one of the exploration studies discussed.

Hierarchical reinforcement learning is another response to sparse guidance in the paper’s account. It can organize decisions at different levels, which provides a way to address long sequences of actions. The authors present their method as compatible with the familiar token-by-token generation process. The task for the critic is to locate useful units of feedback in the resulting text, after which the reward can be attached to the token actions that the learning algorithm already handles.

The closest earlier work in terms of feedback granularity uses people to assess reasoning steps or parts of a generation. The labels can then support a fine-grained reward estimator. The paper cites gains from this approach and points out the costs of producing detailed human judgments. If the task changes from checking one sort of output to checking another, its failure categories and the labeled data needed to recognize them may change as well. Cao and colleagues use a task description and examples to specify what a critic should look for. A previous study of stepwise verification discussed in the paper is [Let’s Verify Step by Step](https://md.research.elamur.ai/free/en/papers/lightman-2023-let-s-verify-step-step/).

#### From verbal judgment to local reward

The authors also situate their work among attempts to use language-based evaluation for reward design. In some of the cited research, a judge chooses between candidate responses and the resulting preferences train a whole-response reward estimator. In another study, a language system supplies rewards directly as an alternative to the task’s actual reward function. The paper describes that alternative as outperforming a supervised reward estimator in the study’s setting, with the true reward function still yielding the strongest result. It also cites work that uses judgments to encourage exploration and work that generates reward code.

A second strand concerns the ability to critique a response in words. A critique can point out a defect or suggest how an output could be improved, as in earlier work on iterative revision. RELC assigns that capacity a role in reinforcement learning. The critic reads the draft and identifies passages, and the learning algorithm receives the locations and directions of the resulting rewards. The trained policy is the generator that produced the draft. Earlier work on response refinement cited by the authors includes [Self-Refine](https://md.research.elamur.ai/free/en/papers/madaan-2023-self-refine-iterative-refinement-self/).

The design brings together two decisions that can be studied separately. The external evaluator sets the task’s overall criterion. The critic gives a local interpretation of a particular sampled response in light of the task. The learning algorithm receives the combination as a reward schedule. This arrangement creates testable questions about where the gain comes from. Extra non-zero rewards could change training merely through their presence, or the gain could depend on the critic attaching them to appropriate positions. A critic could also produce locally plausible judgments that fit one overall metric better than another. Both possibilities matter for interpreting the experiments.

### The method, step by step

#### Generate first, then judge the response

The starting point is a prompt and a policy, the rule that determines the probabilities of possible next tokens. The policy samples a continuation or a summary. An external evaluator then reads the completed response and returns a number. In the learning procedure, this *extrinsic reward* belongs to the last step. Its value represents the judgment of the whole generation, even though the update records it at a particular position in the sequence.

The critic receives a task description, demonstrations of the requested judgment, and the text to inspect. The general framework also allows the prompt to include the external score. A sentiment critic is asked to locate short positive and negative spans. A detoxification critic looks for toxic wording. A summarization critic can compare the draft with the source and locate a problem such as an inaccurate claim or an irrelevant passage. The critic returns a verbal, text-based identification of these spans. The critic and the external evaluator thus provide different kinds of information about the same response.

Training maps the marked passages back to the tokens that generated them. A token covered by a favorable span can receive a positive local reward, and one in an unfavorable span can receive a negative local reward. Unmarked positions have zero local reward. The authors call the added values *intrinsic rewards* because the critic is part of the agent in their formulation. Both types of reward are available after the sampled response has been generated. The local reward is intermediate in where the training procedure places it, so a late judgment can give feedback to an earlier decision.

From a completed response to a policy update The steps in order.

The paper illustrates the mapping with a sentiment example whose whole-response score is −2. The critic identifies both favorable and unfavorable wording in the response. A token in a positive span receives +1 as its intrinsic reward, while a token in a negative span receives −1. These are the unweighted values. The reward given to the learner depends on the chosen weights, and the −2 supplied by the external evaluator is recorded at the last output position. If the last token is also marked by the critic, that position can carry both contributions.

The example shows what the critic adds to a simple judgment of the final text. Even in a response that receives a negative overall score, it can recognize a favorable passage and mark it accordingly. Conversely, a positive overall judgment can coexist with a local penalty. The learner therefore has a way to distinguish useful wording from a problem elsewhere in the same response. How much these distinctions matter to the update depends on the combined reward and on the learning algorithm’s estimate of the value of each position.

#### Describe generation as a sequence of decisions

The formal setup is a Markov decision process. The state contains the original prompt and the tokens generated so far. An action chooses the next token from the vocabulary, and appending that token gives the next state. The paper treats each response as an episode with a final step. The set of possible actions is discrete, since each choice comes from a vocabulary.

```
(S, A, P, R, γ)
```

Here S is the set of possible states and A is the set of available actions. P is the transition function, which gives the probability of reaching a particular next state from a state and action. R is the reward function, with a real-valued result for a transition. The parameter γ is the discount factor, in the interval from 0 to 1. It determines how strongly later rewards count in relation to earlier ones.

```
P(s′ | s, a) ∈ [0, 1]
```

P(s′ | s, a) is the probability of the successor state s′ given the present state s and action a. The prime identifies the successor, the vertical bar means “given,” and ∈ denotes membership in the displayed probability interval. In text generation, once the action has selected a token, the transition appends it to the current text. The policy is responsible for the probabilities of the token choices.

```
πθ(aₜ | sₜ)
```

The symbol π denotes the policy and θ denotes its trainable parameters. The index t identifies the decoding step. The action aₜ is the token selected at that step, and sₜ is the state from which it is selected. The expression is the probability of that action conditional on the state. The policy encounters a new state at each decoding step because its own last decision has changed the text on which future choices depend.

```
J(θ) = Eτ∼πθ [Σₜ₌₀…ₜ₌ₜ γᵗ rₜ]     (upper limit: T)
```

J(θ) is the overall training objective for the policy with parameters θ. The expectation E is over trajectories τ sampled from πθ, as indicated by ∼. The sum Σ runs over steps from 0 through the final step T. The term rₜ is the reward assigned to step t, and γᵗ is the discount factor raised to the power t. The objective is an average over possible sampled trajectories. An individual response supplies one realization of the decisions and rewards underlying that average.

The position of a reward matters because the update is concerned with the decisions that led to it. A terminal reward can enter the estimate for many earlier decisions. It remains a single observation about the complete response. When the critic supplies a reward at a particular step, the same learning machinery can use that observation at the corresponding point in the sequence. The difference lies in the reward information available for assigning credit.

#### Use returns to connect rewards with actions

The paper first presents the policy-gradient formulation. A policy gradient describes how the expected objective changes when the parameters governing action probabilities change. Its reward-dependent term is the return from a particular step. The return includes rewards at that step and later in the response, with discounting measured relative to the step whose action is being evaluated.

```
Gₜ = Σ(i = t to T) γ^(i−t) rᵢ
```

Gₜ is the return starting at step t. The sum runs over the step index i, beginning at t and ending at the final step T. The reward at i is rᵢ, and γ is the discount factor. The exponent i−t counts the number of steps separating the action under evaluation from the reward, with the caret indicating exponentiation. A reward at t enters immediately, and subsequent rewards enter according to their distance from t.

```
∇θ J(θ) = Eπθ [∇θ log πθ(aₜ | sₜ) · Gₜ]
```

The symbol ∇θ denotes differentiation with respect to the policy parameters θ. J is the expected reward objective, and Eπθ denotes an expectation over experience sampled using policy πθ. The logarithm, written log, is applied to the probability of taking action aₜ in state sₜ. The dot denotes multiplication by the return Gₜ. In this expression from the paper, the return weights the direction in parameter space associated with making the sampled action more likely.

The raw return can vary substantially between samples. An action taken in a promising state may receive a high return partly because the state already made a good outcome likely. The procedure used in the paper estimates an advantage, which assesses the rewards associated with an action in relation to expected value. This baseline helps the learner use sampled returns with less variability. The paper uses generalized advantage estimation, which accumulates discrepancies between observed rewards and successive value estimates.

```
Âₜ = Σ(t′ = t to T) (γλ)^(t′−t) [rₜ′ + γ V(sₜ′₊₁) − V(sₜ′)]
```

Âₜ is the estimated advantage at step t. The summation index t′ ranges from t to the final step T. The discount factor is γ, and λ is a hyper-parameter that controls the weighting of later discrepancies. The product γλ is raised to the distance t′−t. The term rₜ′ is the reward at step t′. V is the value function, an estimate of expected return from a state. The argument sₜ′ is the state at t′, and sₜ′₊₁ is its successor state. The bracket compares the immediate reward plus discounted successor value against the value estimate for the present state.

This equation also shows why a span-level judgment can affect more than the tokens in the span. The procedure inserts an immediate reward at a marked position, and a later immediate reward can enter the advantage at an earlier position through the sum. The critic supplies the location of the direct feedback. The return and advantage calculations determine how it influences the sequence of updates. An unmarked token can therefore still be part of a decision path that leads to a rewarded or penalized span.

#### Keep the policy updates within a manageable range

The experiments use Proximal Policy Optimization, abbreviated PPO. Its clipped objective checks how much the probability of a sampled action changes between the policy used to collect the sample and the policy being updated. A favorable reward can push the probability up and an unfavorable reward can push it down. Clipping limits the incentive to make large changes on the basis of the sampled advantage. This is a training mechanism shared by the authors’ terminal-reward baseline and by RELC.

The paper uses similar notation for a reward and the probability ratio inside PPO. The expression below uses ρ for the latter to distinguish their roles.

```
ρₜ(θ) = πθ(aₜ | sₜ) / πθ_old(aₜ | sₜ)
```

The quantity ρₜ(θ) is the probability ratio at step t. The numerator is the current policy πθ’s probability for the sampled action aₜ in state sₜ. The denominator uses πθ_old, the previous policy with parameter values θ_old, for that same action and state. The slash indicates division. A ratio above 1 means that the current policy assigns more probability to that action than the previous policy did.

```
L(θ) = Êₜ [min(ρₜ(θ) Âₜ, clip(ρₜ(θ), 1 − ϵ, 1 + ϵ) Âₜ)]
```

L(θ) is the clipped objective for the current parameters θ. The symbol Êₜ denotes an empirical average over sampled steps t. The ratio is ρₜ(θ), and Âₜ is the estimated advantage. The function clip restricts its first argument to the interval whose lower end is 1 − ϵ and whose upper end is 1 + ϵ. The hyper-parameter ϵ sets the allowed width around 1. The function min takes the smaller of the ordinary ratio times the advantage and the clipped ratio times the advantage.

With a favorable advantage, the clipped term can stop a large increase in action probability from improving the objective further. With an unfavorable advantage, the minimum serves the corresponding purpose when the action probability decreases too far. The mechanism controls the incentive supplied by each sampled term. RELC enters this calculation through the reward used to estimate Âₜ. The critic’s input and natural-language response sit outside the calculation of the policy gradient.

#### Combine the terminal and local rewards

The external evaluator’s score is assigned to the final step. The earlier steps have zero extrinsic reward in the paper’s episodic setup.

```
rᵉˣₜ = 0 for t < T
```

The symbol rᵉˣₜ denotes the extrinsic reward at step t. The superscript ex identifies its external source. The inequality t \< T covers the steps before the final step T, and 0 is the reward assigned at those positions. At T, rᵉˣ takes the value supplied by the evaluator for the completed response.

The critic’s marked spans define a second sequence of rewards on the same steps. A token in a favorably judged span receives +1, one in an unfavorably judged span receives −1, and a token outside the marked spans has zero intrinsic reward. The critic provides the distinction among those positions. The task-specific weight governs the contribution of the entire local signal to training.

```
r(s, a) = α₁ rᵉˣ(s, a) + α₂ rⁱⁿ(s, a)
```

In this expression, r(s, a) is the reward associated with action a in state s. The term rᵉˣ(s, a) is the extrinsic component, and rⁱⁿ(s, a) is the intrinsic component. The hyper-parameters α₁ and α₂ are their respective weights. An earlier step with no marked token has both components equal to zero. A step with a marked token has the weighted intrinsic component. The last step incorporates the weighted external score as well as any intrinsic reward assigned there.

```
J_RELC(θ) = Eτ∼πθ [Σ(t = 0 to T) γᵗ (α₁ rᵉˣₜ + α₂ rⁱⁿₜ)]
```

J_RELC is the combined reward objective for policy parameters θ. The expectation E averages over trajectories τ sampled from πθ. The sum runs over t from 0 to the final step T. At each step, γᵗ discounts the reward. The external and critic-derived rewards at that step are rᵉˣₜ and rⁱⁿₜ, multiplied by α₁ and α₂ respectively. The objective includes the terminal task judgment and the local guidance together.

The weights apply at the level of individual rewards. A marked phrase can cover several tokens, so its influence depends on the assignment across the sequence as well as on the coefficient for each assignment. The effective contribution also depends on the scale of the outside evaluator. A sentiment logit, a toxicity-based reward, and a learned preference score have different meanings and ranges. The paper selects weights for each task and gives the overall reward the role of expressing the desired task outcome.

#### Give the critic a task it can perform

The critic prompt starts by defining what kind of text to look for. It then supplies worked examples, normally in a 3-shot setting. In this usage, a shot is a demonstration of the desired task or response format. The final part of the prompt presents the current input for judgment and can include the overall reward. The examples illustrate both what warrants a mark and what can be left alone. This matters because every marked token can carry a reward, making the boundaries part of the training signal. [Few-shot learning](https://md.research.elamur.ai/free/en/concepts/few-shot-learning/).

In sentiment control, the demonstrations show the critic how to distinguish praise and criticism, capture a short expression that conveys the intended tone, and leave neutral wording unmarked. A negated expression is a useful illustration of why a span can be more informative than a single word. The verb and its negation can jointly express the opinion, so marking the relevant phrase preserves the meaning of what was judged. The procedure then assigns reward to the tokens that make up that phrase. [Sentiment analysis](https://md.research.elamur.ai/free/en/topics/sentiment-emotion/).

For detoxification, the prompt defines toxicity and asks the critic to identify short passages that exhibit it. The examples distinguish a sentence with harmful language from a neutral technical statement. Marking is guided by the complete text, even though the expected answer names local spans. The paper also uses demonstrations for a separate baseline that asks Llama 2 to generate non-toxic continuations directly. The two prompts give examples of different behavior. One elicits span judgments about text already written, while the other elicits a continuation at generation time.

The summarization prompt presents the source, the draft, and a score as context for finding flaws. It asks the critic to locate problems and briefly characterize them, for instance by indicating that a statement is factually wrong or that a passage is misplaced. The appendix explains that the preference score is scaled to 1-10 for presentation to the critic. The instructions describe the score to the critic in terms of reference overlap, while the main experiment obtains its external reward from an evaluator trained on preferences. That distinction matters because the critic’s instructions, the numerical training reward, and the test metrics each play a separate role.

#### Hold the critic fixed while the policy learns

The authors name gpt-3.5-turbo-1106 and 7B Llama2 as critics. One setup uses GPT-2 Large for generation and GPT-3.5 for criticism. This gives the generator training feedback from a separate and more capable system. In the self-critique setup, Llama 2 supplies the starting point for both roles. The policy can learn from the resulting feedback while the critic remains frozen. The fixed critic makes the setup an experiment in the usefulness of its existing judgments for improving a policy initialized from the same system. [Llama 2](https://md.research.elamur.ai/free/en/papers/touvron-2023-llama-2-open-foundation-fine/).

Across training, the policy generates new samples, so the responses presented to the frozen critic can change as the policy changes. The task description, demonstrations, generation, and optional score are the means of eliciting feedback. The optimization updates the policy with the numerical rewards derived from those judgments. The paper reports an official implementation named `relc` in the Google Research repository.

### Experiments and results

#### Positive continuations from difficult prompts

The sentiment experiment asks the generator to continue text in a positive direction. An initial phrase can already favor a negative interpretation, so a method that performs well on neutral prompts can still have difficulty with the negative subset. The paper trains on IMDB movie reviews and tests on OpenWebText prompts. This puts the main table’s measurements on a different source of prompts from the one used to fit the policy.

IMDB provides 25K reviews for the training setup. The authors randomly vary the prompt length by taking the first 4 to 10 tokens of a review, and the policy is trained for one epoch. A distilled BERT sentiment classifier trained on IMDB gives the extrinsic reward. Specifically, the learning curves plot its positive-class logit, the score before conversion to a class probability. The task setup gives the external reward a weight of 1 and the intrinsic reward a weight of 0.2. The appendix writes the corresponding pair as 1.0 and 0.2. [Learning Word Vectors for Sentiment Analysis](https://md.research.elamur.ai/free/en/papers/maas-2011-learning-word-vectors-sentiment-analysis/).

The OpenWebText evaluation setup identifies 5K neutral prompts, 2.5K negative prompts, and 2.5K positive prompts. These groups were selected by how likely the prefixes were to lead to continuations of the corresponding sentiment. The main numerical comparison reports the neutral and negative groups. For evaluation, the authors use a classifier fine-tuned on SST-2 and report the average percentage of positive continuations from 25 generated outputs. The choice of a different classifier from the one giving the training reward makes the test measure a related sentiment judgment from a separate evaluator.

The table includes pretrained GPT-2 Large and several published control methods, among them PPLM, CTRL, and GeDi. DExperts, DAPT, and QUARK also appear, along with a published PPO result and the authors’ own PPO run. The authors’ PPO run is the direct comparison for the addition of critic rewards. The published systems show how the resulting policy fares against other ways of steering generation, which can differ in how they use supervision or control decoding. [Evaluation and benchmarks](https://md.research.elamur.ai/free/en/topics/evaluation-benchmarks/).

Positive continuations on negative OpenWebText test prompts RELC gives the highest share of positive continuations on prompts tending toward negative text.

**The numbers**

| System or setting | positive continuations % |
| --- | --- |
| GPT-2 Large | 0.00 |
| DExperts | 36.42 |
| PPO (published) | 43.13 |
| QUARK | 46.55 |
| PPO (authors’ run) | 54.06 |
| RELC (this paper) | 59.06 |

The particularly low score for the pretrained generator applies to the selected negative prompts and to this classifier-based definition of success. The same generator obtains 50.02% positive continuations on the neutral subset, illustrating how much the starting text changes the task. On that neutral subset, the authors’ PPO run reaches 93.63% and RELC reaches 95.63%. DExperts records 94.46%, and QUARK records 95.00%. The numbers preserve the distinction between difficulty on negative prompts and performance where the opening leaves more room for a positive interpretation.

The authors also assess whether steering changes the character of the output. They use GPT-2 XL perplexity as a proxy for fluency. Lower perplexity means the evaluator finds the generated tokens more predictable. Diversity is measured through a normalized count of distinct bigrams, which are adjacent token pairs. The authors’ PPO run has perplexity of 13.98 and diversity of 0.78, while RELC has perplexity of 13.79 and diversity of 0.80. The pretrained generator gives useful context for these measures, with perplexity of 11.31 and diversity of 0.85. The controlled generations improve sentiment success, with shifts in both proxies relative to pretrained generation.

The sentiment learning curves use IMDB training samples on the horizontal axis and the external sentiment score on the vertical axis. They are smoothed with a moving average of 10. The paper reports a sample-efficiency advantage for the combined rewards in both the separate-critic and Llama 2 self-critique settings. This is evidence about how quickly the sampled training responses score well during optimization. The OpenWebText percentages answer a separate question about the final generators on the evaluation prompts.

#### Toxicity over repeated continuations

The detoxification experiment uses [RealToxicityPrompts](https://md.research.elamur.ai/free/en/papers/gehman-2020-realtoxicityprompts-evaluating-neural-toxic-degeneration/), a collection of 100K sentence prefixes drawn from English web text. The conventional training split used for the experiment contains 85K prompts. The appendix adds that training excludes prompts with a toxicity probability below 0.5 to save training time. Evaluation uses 10K non-toxic test prompts. Starting with these prompts lets the study measure the tendency of the generated text to introduce toxicity when the opening is already judged non-toxic.

Perspective API gives a score from 0 to 1, with higher values indicating stronger toxicity. The extrinsic training reward reverses that direction, so a high reward corresponds to lower measured toxicity.

```
rᵉˣ = 1 − Perspective(y)
```

Here rᵉˣ is the extrinsic reward, y is the generated text to be scored, and Perspective(y) is the API’s toxicity score for that text. The subtraction from 1 gives the reward scale used by the learning procedure. The main experiment description sets the external reward weight to 1 and the critic reward weight to 0.5. The appendix hyper-parameter table for detoxification lists 1.0 and 0.2, so the paper gives differing values for the intrinsic weight.

The test aggregates toxicity across 25 generations per prompt in two ways. The average maximum takes the highest toxicity score for each prompt and averages those maxima over prompts. The empirical probability measures how often the 25 attempts contain at least one continuation judged toxic. The maximum metric captures the severity of the most toxic sample for each prompt, including changes in score that may leave its category unchanged. The event metric captures whether a user sampling repeatedly would encounter a toxic continuation under the benchmark’s scoring rule.

The main comparison uses top-p sampling with p = 0.9 and produces up to 20 tokens. Top-p sampling restricts each draw to a set of likely next tokens chosen by their cumulative probability, using p as the cutoff. Short generations and repeated sampling are therefore part of the definition of the test. The authors also say they reevaluate the baselines with an updated version of the toxicity service. This makes the comparisons within their table more directly interpretable, since all rows there rely on the same version for scoring.

Average maximum toxicity on the RealToxicityPrompts non-toxic test split RELC has the lowest average worst-continuation score among the compared systems.

**The numbers**

| System or setting | average maximum toxicity score |
| --- | --- |
| GPT-2 | 0.527 |
| PPLM | 0.357 |
| GeDi | 0.230 |
| DExperts | 0.189 |
| QUARK | 0.154 |
| PPO (authors’ run) | 0.179 |
| RELC (this paper) | 0.125 |

On the corresponding probability measure, 52.0% of prompts yield at least one toxic sample with the GPT-2 baseline. QUARK records 1.0% and the authors’ PPO run records 2.6%. RELC records 0.8% under the same evaluation. For text quality, the authors’ PPO run has perplexity of 11.49 and diversity of 0.79. RELC records perplexity of 11.72 and diversity of 0.80. The preferred system depends on which small change in these text-quality proxies the reader is examining, while the toxicity results favor RELC on both reported measures.

The detoxification learning curves plot average external reward against training samples and use a moving average of 10. The main combined-reward condition learns more quickly than the extrinsic-only baseline on those curves. The authors also report that an intrinsic-only condition can outperform the extrinsic-only baseline on the learning-curve measure. That comparison is informative because the latter measure is still based on the external toxicity evaluator, even when the learner receives only the critic’s rewards. It indicates useful alignment between the critic’s judgments and the toxicity measure in this setting.

#### A fine-grained comparison and a prompting comparison

The paper separately compares RELC with a Fine-Grained RLHF baseline that obtains local rewards by querying the toxicity API on partial generations. This comparison is closer to the central question than a comparison with a decoding control system, since both approaches put feedback within the sequence. The conditions follow the earlier study’s decoding setup, including nucleus sampling with p = 0.9, temperature 1.0, and a generation length limit of 48. Temperature controls how the next-token distribution is sharpened or flattened before sampling.

In that comparison, the average maximum toxicity score is 0.081 for Fine-Grained RLHF and 0.050 for RELC. Perplexity is 9.77 and 9.53 respectively. The distinct-trigram measure, labeled dist-3, is 0.932 for the baseline and 0.934 for RELC. A trigram is a sequence of adjacent tokens one token longer than a bigram. The comparison uses a different decoding setup and a different diversity measure from the main detoxification table. Its scores are best read against the other row in the same comparison.

For Llama 2, the authors also compare reinforcement learning with direct instructions and demonstrations. The prompting baselines see examples of how to produce a non-toxic continuation. With 1-shot prompting, the average maximum toxicity is 0.409 and the at-least-one probability is 30.9%. With 3-shot prompting, the corresponding values are 0.426 and 32.5%. The authors’ PPO and RELC conditions obtain average maxima of 0.276 and 0.176, respectively. On the probability metric they reach 12.53% and 3.68%, and both have diversity of 0.82.

The Llama 2 result distinguishes generating well under an instruction from identifying harmful spans well enough to guide training. The performance of the prompted generator in these settings gives one measure of the first ability. The improvement from adding a frozen critic during policy optimization gives evidence about the second in the self-critique setup. The contrast between 1-shot and 3-shot prompting also shows that additional demonstrations in this particular generation prompt did not yield a better detoxification result.

#### Summaries scored by preferences and overlap

The summarization experiment uses Reddit TL;DR. The original collection has roughly 3 million Reddit posts across many topics. For training and evaluation, the authors use a filtered version with around 116K training samples and report 6K validation and test samples. The task is abstractive summarization. A generator can express the source’s information in its own wording, making accuracy and selection of content important even when the resulting text differs from a particular reference summary.

The authors first perform supervised fine-tuning on the whole training set. That stage runs for 9,000 steps with a batch size of 64 and starts from GPT2-large. Its result serves both as a baseline and as the initialization for policy optimization. The reinforcement learning stage uses 30K training samples for one epoch. The supervised baseline therefore represents the generation ability obtained before either PPO or RELC applies reward-based updates. [Fine-tuning](https://md.research.elamur.ai/free/en/concepts/fine-tuning/).

The external preference evaluator is GPT-J-6B fine-tuned using 92K human-annotated comparisons between pairs of summaries. It achieves 75.94% accuracy on its validation set. The preference score for a generated summary is an output of this evaluator. The measured validation accuracy describes how well it predicts the labeled pairwise judgments, a separate result from the test scores of the summary generators. For the main experiment, the authors report a weight of 1.0 for the external reward and 0.1 for the intrinsic reward. The latter comes from gpt-3.5-turbo in a 3-shot setup. The appendix hyper-parameter table lists the weights as 1.0 and 0.2, leaving a discrepancy with the main description.

Preference score for generated summaries on the Reddit TL;DR test set RELC yields the highest score from the evaluator trained on human summary preferences.

**The numbers**

| System or setting | preference score |
| --- | --- |
| Supervised fine-tuning | 2.34 |
| PPO | 3.25 |
| RELC (this paper) | 3.88 |

ROUGE provides a separate measure by comparing the generated summary with a reference. ROUGE-1 concerns overlap in individual words or tokens, and ROUGE-L concerns matching subsequences. On the TL;DR test set, supervised fine-tuning scores 34.78 on ROUGE-1 and 26.97 on ROUGE-L. PPO gives 30.81 and 22.11. RELC gives 29.32 and 20.17. In these rows, the systems’ ordering on reference overlap runs in the opposite direction from their ordering on the learned preference score.

The authors argue that reference overlap is a limited guide to qualities such as factuality and agreement with human preferences. A summary can increase its lexical overlap by preserving wording while still omitting something important. It can also express key facts using different wording. The lower ROUGE scores remain a real result of the experiment. The preference evaluator and the human study give the paper evidence for interpreting those lower scores alongside improvements in the qualities the authors set out to measure.

The authors also evaluate preference scores on the TL;DR test set every 100 training steps. The resulting curves show faster improvement with the combined rewards than with terminal-only PPO over the reported comparison. Here the ordinate is measured on test examples as training progresses, whereas the sentiment and detoxification learning curves described earlier use the extrinsic reward observed during training. The distinction matters when comparing the meaning of sample efficiency across the experiments.

#### Human ratings of the summaries

The authors sample 200 examples from the TL;DR test set for human evaluation. Five IELTS-certified raters take part, with a pilot on a separate set of 20 examples before the main assessment. Each summary in the annotation set receives judgments from the five raters. The evaluation covers content coverage, factuality, and coherence, along with an overall assessment. The guidelines ask the raters to read the source and the generated summary and justify their judgments briefly, especially when giving extreme ratings.

These dimensions separate failures that an overall preference score can pool together. Coverage concerns whether the summary conveys the source’s important information. Factuality concerns whether the included claims faithfully reflect the source. Coherence concerns whether a reader can understand the summary as a connected piece of text. A summary can be readable and omit a key point, or it can mention the key point and misstate a detail. Having separate judgments makes the nature of the gain easier to see.

The figure reports higher ratings for RELC than for PPO or supervised fine-tuning on all the assessed dimensions, with factuality showing a particularly clear advantage. The paper reports inter-rater agreement using Krippendorff’s alpha, a statistic for assessing consistency among annotators. The agreement values are 0.693 for coverage, 0.740 for factuality, 0.646 for coherence, and 0.678 for the overall assessment. These values measure agreement among the raters. The direction of the system comparisons comes from their ratings of the summaries.

The human judgments address a dependence in the automatic evaluation. The same learned preference evaluator supplies a training reward and a test metric, so a higher test preference score demonstrates improved generalization to test prompts under that evaluator’s judgments. The raters provide an assessment from another source, with direct access to the original posts and the generated summaries. Their findings support the preference-score result for the sampled TL;DR outputs, particularly for factuality.

### What the ablations show

#### Rewarding arbitrary positions

The random-reward ablation asks whether the critic’s choice of locations matters. Adding local rewards changes the training signal in at least two ways. It gives the learner more positions with an explicit reward, and it makes those positions depend on what the response says. A useful control should retain roughly the density of local feedback while breaking its link to the content of the selected tokens. The detoxification ablation does this by choosing token positions at random.

The authors estimate the fraction of tokens the actual critic marks through a moving average. The estimate updates as more sequences are observed. Random assignments then use that estimate as the probability of rewarding a token. The paper describes the other hyper-parameters as consistent with the detoxification setup.

```
Pₜ = α · (N_marked / N_sequence) + (1 − α) · Pₜ₋₁
```

Pₜ is the updated estimate at step t of the proportion of tokens given intrinsic rewards. N_marked is the number of tokens identified for reward, and N_sequence is the total number of tokens in the sequence. The slash gives their fraction. The coefficient α weights that current fraction, while 1 − α weights the previous estimate Pₜ₋₁. The dot indicates multiplication. This α is the moving-average coefficient for the control, separate from the weights α₁ and α₂ that combine external and intrinsic reward.

The learning curve shows no improvement from the random assignment. In this experiment, roughly reproducing the amount of feedback fails to reproduce the benefit of tying it to passages identified by the critic. The result supports the authors’ account of improved credit assignment. It isolates the usefulness of content-dependent assignment at the level of the learning curve. A direct judgment of every marked span would answer a finer question about the critic’s local accuracy.

The random control matches reward density approximately. The real critic can select neighboring tokens that form a phrase, while random assignment uses positions without reference to wording. The comparison consequently concerns the critic’s package of content-sensitive choices, including where marked tokens cluster. The result is strongest as evidence against the claim that comparable density alone explains the reported advantage.

#### Removing a source of reward

The sentiment and detoxification learning curves include extrinsic-only, intrinsic-only, and combined-reward conditions. The external score remains the measurement used to display progress. The extrinsic-only condition supplies the baseline for assessing the addition of the critic. The intrinsic-only curve asks how far the local judgments can take the learner under a task criterion supplied by an independent external evaluator. The combined curve reflects the method as the authors propose to use it.

Detoxification gives the clearest result reported for the intrinsic-only condition. It can outperform learning solely from the external reward on the plotted measure. Since the plotted measure comes from Perspective, the result indicates that the critic’s local decisions can point learning in a direction that agrees with the evaluator. The standard method retains the external objective throughout training. The test comparisons with repeat generation and with other baselines assess the policy produced by that combined approach.

The use of direct prompting as a comparison in Llama 2 introduces another distinction. Demonstrations can guide the next response while a generator is reading them. Critic demonstrations can instead help it identify useful evidence for a numerical update. The reported prompt conditions improve the experimental comparison by testing an alternative use of the same general ability to follow instructions, though they leave open how other prompts or demonstration choices would perform.

#### Charging for the extra inference

Sample efficiency counts experience. A method that learns from fewer samples can still require more work overall if each sample receives an additional critic pass. The paper therefore examines detoxification with Llama 2 as a function of floating-point operations, or FLOPs. In this analysis the horizontal axis represents computation used in training, and the authors compare performance at comparable budgets. The plot uses a truncated horizontal axis.

The combined-reward method achieves better detoxification performance than the baseline at the same plotted computation budget. The result is useful because the additional critic work is part of the question this comparison is designed to answer. It shows that, in the reported Llama 2 setup, the gains from local feedback can compensate for its computational cost. The corresponding sample-count curves alone could only show how much experience each method uses on its way to better performance.

#### Changing the summarization objective

The appendix explores summarization with ROUGE-1 as the extrinsic reward in place of the learned preference score. The learning curves are smoothed with a moving average of 10. Under a ROUGE-1 assessment, the authors find little improvement in learning efficiency from adding the intrinsic rewards. In the associated evaluation of test performance every 100 steps, the preference-based assessment gives a more favorable picture of what the added feedback is accomplishing.

This is a consequential control because it changes the definition of progress while retaining the question of whether critique helps. A critic prompted to locate inaccurate, irrelevant, or incoherent text can provide training information about failures the preference evaluator recognizes. Improvements in those properties may have a weaker connection to word overlap with a reference. The experiment supports that interpretation, particularly alongside the human preference for the RELC summaries. It leaves the separate contributions of the critic’s prompt, the external reward used in training, and the metric used for evaluation open.

### Limitations

#### Limits the authors identify

The authors explicitly make the method conditional on the ability of the critic to assess a task. A critic that struggles to identify errors in its own or another system’s work supplies an unreliable source of training feedback. The concern is greatest in difficult tasks, where diagnosing an intermediate mistake may demand abilities beyond those needed to recognize that the completed response is weak. RELC provides a way to use a judgment once a critic can make it. The critic’s competence still determines the quality of that judgment.

The authors also highlight that the critic is frozen. As the policy improves, the deficiencies in its responses may become subtler. A critic that was effective on early samples may be less able to distinguish acceptable from flawed passages later. The authors identify further training of the critic as a direction to explore. The paper’s results concern optimization with a fixed critic, including its use in the self-critique arrangement.

#### What the experiments can establish

The study demonstrates a shared approach across sentiment control, detoxification, and summarization, with the task description, examples, external evaluator, and reward weights chosen for each application. The conclusions report self-critique across the tasks, and the detailed comparisons differ by task. The sentiment curves explicitly show the separate-critic and self-critique settings, the detoxification tables give a dedicated Llama 2 comparison, and the main summarization table describes the GPT-2 Large and GPT-3.5 setup. Readers can therefore assess the reported gains most precisely within the policy and critic configurations documented for each result.

Several results depend on how the task is measured. Positive sentiment is assessed by classifiers, fluency by perplexity, and diversity by the recurrence of short token sequences. Detoxification is assessed by a particular version of a toxicity service on generations sampled under particular settings. These are concrete criteria for the comparisons the authors make. Wider claims about how people would interpret the sentiment, fluency, or safety of the generated language would require evaluation of those properties directly. The human assessment in this study concerns the summaries. [Bias, fairness & safety](https://md.research.elamur.ai/free/en/topics/bias-fairness-safety/).

In detoxification, the training pool is filtered by a toxicity criterion and the main evaluation uses prompts judged non-toxic. This design measures a generator’s propensity to introduce toxic content on that test split. Behavior when continuing prompts already assessed as toxic is a related question with different starting conditions. The probability of encountering a toxic continuation is also tied to the stated number of draws and the length and sampling rules. Each of those choices affects the opportunity for an undesirable continuation to appear.

The summarization study offers evidence from both a learned evaluator and human judgment, with different limits. The learned score measures how well the generated text satisfies an evaluator trained on preference comparisons. Using that score both as a learning signal and as a metric puts particular value on the independent human assessment. The human result covers the sampled TL;DR outputs under the specified rubric. The preference and ROUGE findings together show that the apparent benefit of adding critique depends on which aspect of summary quality is being assessed.

#### What the controls leave unresolved

The random ablation supports the importance of selecting positions based on the text. It leaves open how consistently the critic’s marks match a person’s judgment about individual errors. The human evaluation checks the quality of finished summaries. A passage-level validation would answer a different question about how often the critic identifies the relevant wording and where its assignments go astray. The paper’s learning curves establish that the aggregate signal can be helpful without resolving the correctness of each component judgment.

The method also depends on the signs and weights used to translate feedback into training. The paper describes these choices for its tasks, with discrepancies between the main descriptions and appendix tables for detoxification and summarization. Its shaping term is a content-dependent reward, and the optimization target explicitly includes that term. Agreement between the combined objective and the terminal task criterion is therefore an empirical matter. The ROUGE experiment is one case where a metric gives little evidence of the learning-efficiency benefit found under the main preference assessment.

Finally, the equal-computation comparison is for Llama 2 detoxification. That result addresses the cost of adding a critic under a specified training setup and accounting measure. Cost in other settings depends on the critic, how it is accessed, and the amount of generation and context it must process. Training FLOPs, API charges, and elapsed time address different questions about operational cost. The paper supplies comparative evidence for the first of these in the Llama 2 analysis.

### What came after

#### Process rewards and evaluation by judges

[Free Process Rewards without Process Labels](https://md.research.elamur.ai/free/en/papers/yuan-2024-free-process-rewards-process-labels/) cites RELC and takes up the problem of obtaining rewards for intermediate work when explicit process labels are unavailable. The connection is the cost of acquiring local supervision. RELC provides one way to obtain it by asking a critic to identify passages in a completed response, then converting its judgments into token rewards. The later work’s stated focus is the availability of process rewards without process labels. The citation establishes a connection between the two approaches to supervision. It gives no basis on its own for attributing RELC’s span-marking procedure to the later work.

[LLMs-as-Judges: A Comprehensive Survey on LLM-based Evaluation Methods](https://md.research.elamur.ai/free/en/papers/li-2024-llms-judges-comprehensive-survey-llm/) cites the paper in the context of a survey of evaluation by language-based judges. RELC is an instance where a judge’s output influences the generator through training. Its judgments identify locations in a response, and the learning algorithm consumes the numerical values derived from them. That makes it a relevant example of how an evaluation method can become part of a training procedure. The citation identifies the survey’s connection to the paper, with the specific treatment of RELC in the survey left unspecified.

[A Review of Incorporating Psychological Theories in LLMs](https://md.research.elamur.ai/free/en/papers/liu-2026-review-incorporating-psychological-theories-llms/) also cites RELC. Its stated subject is the use of psychological theories in language-based systems, a broader context than the process-reward experiments. The term *intrinsic reward* in RELC refers to feedback generated within the agent by its critic. That definition is enough to distinguish the feature the paper actually implements from any psychological interpretation a later review might develop. The citation records a connection, while the review’s particular use of the method or terminology is unspecified.

## Cite

Cite as Meng Cao, Lei Shu, Lei Yu, Yun Zhu, Nevan Wichers, Yinxiao Liu and Lei Meng. 2024. Enhancing Reinforcement Learning with Dense Rewards from Language Model Critic. Proceedings of the 2024 Conference on Empirical Methods in Natural Language Processing.

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.18653/v1/2024.emnlp-main.515](https://doi.org/10.18653/v1/2024.emnlp-main.515)

```bibtex
@inproceedings{cao2024enhancing,
  title = {{Enhancing Reinforcement Learning with Dense Rewards from Language Model Critic}},
  author = {Meng Cao, Lei Shu, Lei Yu, Yun Zhu, Nevan Wichers, Yinxiao Liu and Lei Meng},
  booktitle = {Proceedings of the 2024 Conference on Empirical Methods in Natural Language Processing},
  year = {2024},
  doi = {10.18653/v1/2024.emnlp-main.515},
  url = {https://doi.org/10.18653/v1/2024.emnlp-main.515}
}
```

> 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)
