Components

Citation

An inline, LLM-style source reference that reveals the source title, link and snippet in a popover.

php artisan blatui:add citation

Large language models are trained on vast text corpora and learn to predict the next token Attention Is All You Need arxiv.org (opens in new tab) , a process that gives rise to surprisingly general capabilities. Scaling both data and parameters has been shown to improve performance across many tasks Scaling Laws for Neural Language Models arxiv.org (opens in new tab) .

<p class="max-w-prose text-sm leading-relaxed text-foreground">
    Large language models are trained on vast text corpora and learn to predict the next
    token<x-ui.citation
        :index="1"
        title="Attention Is All You Need"
        url="https://arxiv.org/abs/1706.03762"
    />, a process that gives rise to surprisingly general capabilities. Scaling both data
    and parameters has been shown to improve performance across many
    tasks<x-ui.citation
        :index="2"
        title="Scaling Laws for Neural Language Models"
        url="https://arxiv.org/abs/2001.08361"
    />.
</p>

List

@php
    $sources = [
        ['title' => 'Attention Is All You Need', 'url' => 'https://arxiv.org/abs/1706.03762'],
        ['title' => 'Language Models are Few-Shot Learners', 'url' => 'https://arxiv.org/abs/2005.14165'],
        ['title' => 'Training language models to follow instructions', 'url' => 'https://arxiv.org/abs/2203.02155'],
    ];
@endphp

<div class="max-w-prose">
    <h3 class="mb-2 text-sm font-semibold text-foreground">Sources</h3>
    <ol class="space-y-2 text-sm">
        @foreach ($sources as $i => $source)
            <li class="flex items-baseline gap-2">
                <x-ui.citation
                    :index="$i + 1"
                    :title="$source['title']"
                    :url="$source['url']"
                />
                <x-ui.link :href="$source['url']" :external="true" class="text-sm">
                    {{ $source['title'] }}
                </x-ui.link>
            </li>
        @endforeach
    </ol>
</div>

With Snippet

Retrieval-augmented generation grounds model output in retrieved documents, reducing hallucination on knowledge-intensive tasks Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks arxiv.org (opens in new tab) We introduce RAG models where the parametric memory is a pre-trained seq2seq model and the non-parametric memory is a dense vector index of Wikipedia. .

<p class="max-w-prose text-sm leading-relaxed text-foreground">
    Retrieval-augmented generation grounds model output in retrieved documents, reducing
    hallucination on knowledge-intensive tasks<x-ui.citation
        :index="1"
        title="Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks"
        url="https://arxiv.org/abs/2005.11401"
        snippet="We introduce RAG models where the parametric memory is a pre-trained seq2seq model and the non-parametric memory is a dense vector index of Wikipedia."
    />.
</p>