<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	
	xmlns:georss="http://www.georss.org/georss"
	xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#"
	>

<channel>
	<title>DeepEval - Inero Software - Rozwiązania IT i Konsulting</title>
	<atom:link href="https://inero-software.com/pl/tag/deepeval-pl/feed/" rel="self" type="application/rss+xml" />
	<link>https://inero-software.com/pl/tag/deepeval-pl/</link>
	<description>Tworzymy cyfrowe innowacje</description>
	<lastBuildDate>Tue, 04 Feb 2025 13:09:57 +0000</lastBuildDate>
	<language>pl-PL</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.1</generator>

<image>
	<url>https://inero-software.com/wp-content/uploads/2018/11/inero-logo-favicon.png</url>
	<title>DeepEval - Inero Software - Rozwiązania IT i Konsulting</title>
	<link>https://inero-software.com/pl/tag/deepeval-pl/</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">153509928</site>	<item>
		<title>Ocena dużych modeli językowych (LLM) z wykorzystaniem Retrieval-Augmented Generation (RAG) i DeepEval dla złożonych danych tabelarycznych</title>
		<link>https://inero-software.com/pl/ocena-duzych-modeli-jezykowych-llm-z-wykorzystaniem-retrieval-augmented-generation-rag-i-deepeval-dla-zlozonych-danych-tabelarycznych/</link>
		
		<dc:creator><![CDATA[Martyna Mul]]></dc:creator>
		<pubDate>Tue, 04 Feb 2025 11:56:49 +0000</pubDate>
				<category><![CDATA[Firma]]></category>
		<category><![CDATA[AI]]></category>
		<category><![CDATA[biznes]]></category>
		<category><![CDATA[DeepEval]]></category>
		<category><![CDATA[LLM]]></category>
		<guid isPermaLink="false">https://inero-software.com/?p=6913</guid>

					<description><![CDATA[<p>W tym artykule przyjrzymy się, jak DeepEval pomaga w systematycznej ocenie, zwiększając wiarygodność informacji tworzonych przez AI.</p>
<p>Artykuł <a href="https://inero-software.com/pl/ocena-duzych-modeli-jezykowych-llm-z-wykorzystaniem-retrieval-augmented-generation-rag-i-deepeval-dla-zlozonych-danych-tabelarycznych/">Ocena dużych modeli językowych (LLM) z wykorzystaniem Retrieval-Augmented Generation (RAG) i DeepEval dla złożonych danych tabelarycznych</a> pochodzi z serwisu <a href="https://inero-software.com/pl">Inero Software - Rozwiązania IT i Konsulting</a>.</p>
]]></description>
										<content:encoded><![CDATA[		<div data-elementor-type="wp-post" data-elementor-id="6913" class="elementor elementor-6913" data-elementor-post-type="post">
				<div class="elementor-element elementor-element-a77f132 e-flex e-con-boxed e-con e-parent" data-id="a77f132" data-element_type="container">
					<div class="e-con-inner">
		<div class="elementor-element elementor-element-eedef0f e-con-full e-flex e-con e-child" data-id="eedef0f" data-element_type="container">
				</div>
		<div class="elementor-element elementor-element-8bb2c58 e-con-full e-flex e-con e-child" data-id="8bb2c58" data-element_type="container">
		<div class="elementor-element elementor-element-cac0d92 e-con-full e-flex e-con e-child" data-id="cac0d92" data-element_type="container">
				<div class="elementor-element elementor-element-f3a0ecb elementor-widget elementor-widget-html" data-id="f3a0ecb" data-element_type="widget" data-widget_type="html.default">
				<div class="elementor-widget-container">
			 		</div>
				</div>
				<div class="elementor-element elementor-element-33c698c elementor-widget elementor-widget-text-editor" data-id="33c698c" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<h4>Modele Retrieval-Augmented Generation (RAG) zmieniają sposób, w jaki inteligentni asystenci przetwarzają informacje, umożliwiając bardziej precyzyjne i kontekstowe odpowiedzi na zapytania użytkowników. W przeciwieństwie do tradycyjnych dużych modeli językowych (LLMs), systemy RAG łączą dwa kluczowe elementy: mechanizm wyszukiwania, który pobiera istotne dokumenty, oraz model generatywny, który tworzy odpowiedzi na podstawie aktualnych danych. W tym artykule przyjrzymy się, jak DeepEval pomaga w systematycznej ocenie skuteczności zarówno wyszukiwania, jak i generowania, zwiększając wiarygodność informacji tworzonych przez AI.</h4>						</div>
				</div>
				<div class="elementor-element elementor-element-6e6ea96 elementor-widget elementor-widget-text-editor" data-id="6e6ea96" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Chociaż wirtualni asystenci wykorzystujący RAG znacząco poprawiają trafność odpowiedzi, ich skuteczna ocena nadal stanowi wyzwanie. Ponieważ modele te opierają się zarówno na mechanizmie wyszukiwania, jak i generowaniu tekstu, niedokładne lub nieefektywne pobieranie dokumentów może prowadzić do błędnych lub mylących odpowiedzi, nawet jeśli sam model językowy (LLM) jest zaawansowany technologicznie.</p><p>W tym artykule przedstawimy ten proces na przykładzie naszego autorskiego asystenta AI, zaprojektowanego do udzielania odpowiedzi na złożone pytania dotyczące statystyk gospodarki morskiej. Pokażemy, jak wykorzystanie LLM do inteligentnego wyszukiwania informacji wspiera podejmowanie decyzji opartych na danych.</p>						</div>
				</div>
				<div class="elementor-element elementor-element-d0eedd1 elementor-widget elementor-widget-heading" data-id="d0eedd1" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
			<h3 class="elementor-heading-title elementor-size-default">SeaStat - nasz asystent AI</h3>		</div>
				</div>
				<div class="elementor-element elementor-element-caacdce elementor-widget elementor-widget-text-editor" data-id="caacdce" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Świetnym przykładem, który możemy wykorzystać do omówienia tego zagadnienia, jest asystent AI <strong>SeaStat</strong>, opracowany przez nas w ramach projektu <strong>Incone60 Green</strong> (<a href="https://www.incone60.eu/">https://www.incone60.eu/</a>). Celem tego projektu jest zwiększenie konkurencyjności oraz wspieranie zrównoważonego rozwoju małych portów morskich w regionie południowego Bałtyku.</p>						</div>
				</div>
				<div class="elementor-element elementor-element-42941ab elementor-widget elementor-widget-image" data-id="42941ab" data-element_type="widget" data-widget_type="image.default">
				<div class="elementor-widget-container">
													<img fetchpriority="high" decoding="async" width="517" height="587" src="https://inero-software.com/wp-content/uploads/2025/02/SeaStat.png" class="attachment-large size-large wp-image-6904" alt="" srcset="https://inero-software.com/wp-content/uploads/2025/02/SeaStat.png 517w, https://inero-software.com/wp-content/uploads/2025/02/SeaStat-264x300.png 264w" sizes="(max-width: 517px) 100vw, 517px" data-attachment-id="6904" data-permalink="https://inero-software.com/assessing-retrieval-augmented-generation-rag-large-language-models-llms-with-deepeval-for-complex-tabular-data/seastat/" data-orig-file="https://inero-software.com/wp-content/uploads/2025/02/SeaStat.png" data-orig-size="517,587" data-comments-opened="0" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="SeaStat" data-image-description="" data-image-caption="" data-medium-file="https://inero-software.com/wp-content/uploads/2025/02/SeaStat-264x300.png" data-large-file="https://inero-software.com/wp-content/uploads/2025/02/SeaStat.png" role="button" />													</div>
				</div>
				<div class="elementor-element elementor-element-bf0da8d elementor-widget elementor-widget-text-editor" data-id="bf0da8d" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>W ramach projektu <strong>Incone60 Green</strong> opracowaliśmy asystenta AI, który odpowiada na pytania dotyczące danych gospodarki morskiej, zapewniając natychmiastowy dostęp do uporządkowanych informacji. Asystent wykorzystuje podejście <strong>Retrieval-Augmented Generation (RAG)</strong>, dzięki czemu jego odpowiedzi opierają się na ustrukturyzowanej bazie danych obejmującej kluczowe aspekty, takie jak porty morskie, transport morski, stocznie, ruch pasażerski, handel oraz przemysł rybny.</p>						</div>
				</div>
				<div class="elementor-element elementor-element-85e0e3e elementor-widget elementor-widget-text-editor" data-id="85e0e3e" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Nasz asystent AI działa w ramach <strong>potoku RAG</strong>, który integruje trzy kluczowe elementy:</p><ul><li><strong>Ustrukturyzowaną bazę danych gospodarki morskiej</strong>, zawierającą globalne i polskie statystyki morskie z lat 2017–2020. Dane pochodzą z publikacji <strong>Uniwersytetu Morskiego w Gdyni</strong>, które agregują informacje z instytutów rządowych, uczelni oraz przedsiębiorstw portowych. Baza składa się z <strong>50 tabel</strong> obejmujących kluczowe aspekty transportu morskiego i będzie rozszerzana o kolejne lata.</li><li><strong>Dynamiczne generowanie zapytań SQL</strong>, umożliwiające precyzyjne pobieranie potrzebnych informacji z bazy danych.</li><li><strong>Generatywny model LLM</strong>, który formułuje odpowiedzi na podstawie uzyskanych danych.</li></ul><p>Budowa takiego asystenta wymaga kilku istotnych decyzji i optymalizacji, w tym:</p><ul><li><strong>Dobór odpowiedniego modelu LLM</strong> oraz dostosowanie jego parametrów (np. temperatury).</li><li><strong>Projektowanie skutecznej struktury promptów</strong>, zapewniającej jasne i trafne odpowiedzi.</li><li><strong>Zoptymalizowanie mechanizmu wyboru tabel</strong>, tak aby asystent konsekwentnie korzystał z najbardziej adekwatnych danych.</li></ul><p>Na tym etapie <strong>automatyczne testowanie</strong> odgrywa kluczową rolę – pozwala mierzyć wydajność systemu, wykrywać jego słabe punkty oraz zapewniać jego stały rozwój.</p>						</div>
				</div>
				<div class="elementor-element elementor-element-648b32b elementor-widget elementor-widget-heading" data-id="648b32b" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
			<h3 class="elementor-heading-title elementor-size-default"><p><strong>LLM-as-a-Judge: Automatyzacja ewaluacji modeli RAG</strong><span style="color: var( --e-global-color-primary );font-family: var( --e-global-typography-primary-font-family ), Sans-serif;font-size: 1.7em;font-weight: var( --e-global-typography-primary-font-weight );text-align: var(--text-align)"></span></p></h3>		</div>
				</div>
				<div class="elementor-element elementor-element-09073bd elementor-widget elementor-widget-text-editor" data-id="09073bd" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Ocena systemów generujących <strong>niedeterministyczne, otwarte odpowiedzi tekstowe</strong> stanowi wyzwanie, ponieważ często nie istnieje jedna „poprawna” odpowiedź. Choć <strong>ocena przeprowadzana przez ludzi</strong> jest precyzyjna, bywa kosztowna i czasochłonna.</p><p><strong>LLM-as-a-Judge</strong> to metoda, która naśladuje ocenę ludzką, oceniając wyniki systemu na podstawie <strong>dostosowanych kryteriów</strong>, dopasowanych do konkretnej aplikacji. Jednym z narzędzi wspierających ten proces jest <strong>DeepEval</strong> – framework testowy, który oferuje zestaw metryk zarówno dla zadań wyszukiwania, jak i generowania tekstu, a także umożliwia tworzenie własnych kryteriów oceny.</p>						</div>
				</div>
				<div class="elementor-element elementor-element-b4e1ef9 elementor-widget elementor-widget-text-editor" data-id="b4e1ef9" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p><strong>Kluczowe metryki oceny:</strong></p><ul><li><strong>G-Eval</strong> – uniwersalna metryka oceniająca odpowiedzi LLM na podstawie niestandardowych, zdefiniowanych kryteriów.</li><li><strong>Answer Relevancy</strong> – mierzy, jak dobrze odpowiedź modelu odnosi się do zapytania użytkownika.</li><li><strong>Faithfulness</strong> – ocenia, na ile odpowiedź jest zgodna z dostarczonym kontekstem, co pomaga ograniczyć halucynacje w systemach RAG.</li><li><strong>ContextualRecallMetric, ContextualPrecisionMetric, ContextualRelevancyMetric</strong> – metryki szczególnie przydatne w systemach RAG, oceniające, czy mechanizmy wyszukiwania zwracają <strong>wszystkie istotne informacje</strong>, jednocześnie eliminując treści nieistotne.</li></ul>						</div>
				</div>
				<div class="elementor-element elementor-element-1c250db elementor-widget elementor-widget-heading" data-id="1c250db" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
			<h3 class="elementor-heading-title elementor-size-default">Testowanie modelu RAG za pomocą DeepEval – krok po kroku</h3>		</div>
				</div>
				<div class="elementor-element elementor-element-e3db2c9 elementor-widget elementor-widget-text-editor" data-id="e3db2c9" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Aby zapewnić <strong>niezawodność i dokładność</strong> naszego modelu <strong>Retrieval-Augmented Generation (RAG)</strong>, stosujemy <strong>ustrukturyzowane podejście do ewaluacji</strong>. Proces ten obejmuje <strong>tworzenie zbioru danych, generowanie odpowiedzi oraz ocenę modelu za pomocą DeepEval</strong>, co pozwala na systematyczną analizę skuteczności zarówno komponentu wyszukiwania, jak i generowania.</p><p>Przyjrzyjmy się każdemu z tych kroków. </p>						</div>
				</div>
				<div class="elementor-element elementor-element-019ed5f elementor-widget elementor-widget-heading" data-id="019ed5f" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
			<h4 class="elementor-heading-title elementor-size-default">1. Tworzenie Zbioru Danych</h4>		</div>
				</div>
				<div class="elementor-element elementor-element-741ed12 elementor-widget elementor-widget-text-editor" data-id="741ed12" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Aby skutecznie ocenić wydajność modelu, tworzymy zestaw testowy składający się z:</p><ul><li><strong>Realistycznych pytań użytkowników</strong> – obejmujących zarówno proste zapytania faktograficzne, jak i bardziej złożone pytania wieloetapowe, wymagające szczegółowych odpowiedzi na podstawie wielu tabel.</li><li><strong>Oczekiwanych odpowiedzi referencyjnych (ground truth)</strong> – pochodzących bezpośrednio z bazy danych, zapewniających wzorzec do oceny poprawności generowanych odpowiedzi.</li></ul>						</div>
				</div>
				<div class="elementor-element elementor-element-f4f0b50 elementor-widget elementor-widget-heading" data-id="f4f0b50" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
			<h4 class="elementor-heading-title elementor-size-default">2. Generowanie Odpowiedzi Modelu</h4>		</div>
				</div>
				<div class="elementor-element elementor-element-587939b elementor-widget elementor-widget-text-editor" data-id="587939b" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Dla każdego zapytania testowego asystent generuje odpowiedź na podstawie odpowiednich danych pobranych z bazy danych.</p>						</div>
				</div>
				<div class="elementor-element elementor-element-0deb934 elementor-widget elementor-widget-heading" data-id="0deb934" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
			<h4 class="elementor-heading-title elementor-size-default">3. Ewaluacja za pomocą DeepEval</h4>		</div>
				</div>
				<div class="elementor-element elementor-element-7c0b685 elementor-widget elementor-widget-text-editor" data-id="7c0b685" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Szczególnie zależy nam na poprawności faktograficznej naszego asystenta, dlatego do oceny tego aspektu wykorzystujemy metrykę G-Eval.</p><p>Musimy zdefiniować G-Eval, opisując kryteria testowe, np.:</p>						</div>
				</div>
				<div class="elementor-element elementor-element-3d98b09 elementor-widget elementor-widget-text-editor" data-id="3d98b09" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<pre><span data-contrast="auto">correctness_metric = GEval(    </span> <br /><span data-contrast="auto">    name="Correctness",     </span> <br /><span data-contrast="auto">    evaluation_steps=[  </span> <br /><span data-contrast="auto">        "Assess whether the actual output is accurate in terms of facts compared to the expected output.",      </span> <br /><span data-contrast="auto">        "Penalize missing information."  </span> <br /><span data-contrast="auto">    ],      </span> <br /><span data-contrast="auto">    evaluation_params=[  </span> <br /><span data-contrast="auto">       LLMTestCaseParams.INPUT,   </span> <br /><span data-contrast="auto">       LLMTestCaseParams.ACTUAL_OUTPUT,   </span> <br /><span data-contrast="auto">       LLMTestCaseParams.EXPECTED_OUTPUT  </span> <br /><span data-contrast="auto">    ],    </span> <br /><span data-contrast="auto">)</span> </pre>						</div>
				</div>
				<div class="elementor-element elementor-element-63d0764 elementor-widget elementor-widget-text-editor" data-id="63d0764" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Dodatkowo korzystamy z kilku wbudowanych metryk:</p>						</div>
				</div>
				<div class="elementor-element elementor-element-4344a23 elementor-widget elementor-widget-text-editor" data-id="4344a23" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<pre><span class="TextRun SCXW8241585 BCX0" lang="EN-GB" xml:lang="EN-GB" data-contrast="auto"><span class="NormalTextRun SCXW8241585 BCX0">contextual_precision</span><span class="NormalTextRun SCXW8241585 BCX0"> = </span><span class="NormalTextRun SCXW8241585 BCX0">ContextualPrecisionMetric</span><span class="NormalTextRun SCXW8241585 BCX0">()</span></span><span class="LineBreakBlob BlobObject DragDrop SCXW8241585 BCX0"><span class="SCXW8241585 BCX0"> </span><br class="SCXW8241585 BCX0" /></span><span class="TextRun SCXW8241585 BCX0" lang="EN-GB" xml:lang="EN-GB" data-contrast="auto"><span class="NormalTextRun SCXW8241585 BCX0">contextual_recall = </span><span class="NormalTextRun SCXW8241585 BCX0">ContextualRecallMetric</span><span class="NormalTextRun SCXW8241585 BCX0">()</span></span><span class="LineBreakBlob BlobObject DragDrop SCXW8241585 BCX0"><span class="SCXW8241585 BCX0"> </span><br class="SCXW8241585 BCX0" /></span><span class="TextRun SCXW8241585 BCX0" lang="EN-GB" xml:lang="EN-GB" data-contrast="auto"><span class="NormalTextRun SCXW8241585 BCX0">contextual_relevancy = </span><span class="NormalTextRun SCXW8241585 BCX0">ContextualRelevancyMetric</span><span class="NormalTextRun SCXW8241585 BCX0">()</span></span><span class="LineBreakBlob BlobObject DragDrop SCXW8241585 BCX0"><span class="SCXW8241585 BCX0"> </span><br class="SCXW8241585 BCX0" /></span><span class="TextRun SCXW8241585 BCX0" lang="EN-GB" xml:lang="EN-GB" data-contrast="auto"><span class="NormalTextRun SCXW8241585 BCX0">answer_relevancy = </span><span class="NormalTextRun SCXW8241585 BCX0">AnswerRelevancyMetric</span><span class="NormalTextRun SCXW8241585 BCX0">()</span></span><span class="LineBreakBlob BlobObject DragDrop SCXW8241585 BCX0"><span class="SCXW8241585 BCX0"> </span><br class="SCXW8241585 BCX0" /></span><span class="TextRun SCXW8241585 BCX0" lang="EN-GB" xml:lang="EN-GB" data-contrast="auto"><span class="NormalTextRun SCXW8241585 BCX0">faithfulness = </span><span class="NormalTextRun SCXW8241585 BCX0">FaithfulnessMetric</span><span class="NormalTextRun SCXW8241585 BCX0">()</span></span><span class="EOP SCXW8241585 BCX0" data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;201341983&quot;:0,&quot;335551550&quot;:1,&quot;335551620&quot;:1,&quot;335559685&quot;:0,&quot;335559737&quot;:0,&quot;335559738&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:279}"> </span></pre>						</div>
				</div>
				<div class="elementor-element elementor-element-5d2ddcf elementor-widget elementor-widget-text-editor" data-id="5d2ddcf" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Następnie definiujemy przypadki testowe:</p>						</div>
				</div>
				<div class="elementor-element elementor-element-f16e61d elementor-widget elementor-widget-text-editor" data-id="f16e61d" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<pre><span data-contrast="auto">test_case = LLMTestCase(  </span> <br /><span data-contrast="auto">    input=#user prompt,  </span> <br /><span data-contrast="auto">    actual_output=#model output here,  </span> <br /><span data-contrast="auto">    expected_output=#the ground truth response </span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;201341983&quot;:0,&quot;335551550&quot;:1,&quot;335551620&quot;:1,&quot;335559685&quot;:0,&quot;335559737&quot;:0,&quot;335559738&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:279}"> </span><br /><br /><span data-contrast="auto">    retrieval_context=#data extracted by retriever, in our case it is data extracted from the database</span> <br /><span data-contrast="auto">)</span> <br /><span data-ccp-props="{}"> </span></pre>						</div>
				</div>
				<div class="elementor-element elementor-element-466c61d elementor-widget elementor-widget-text-editor" data-id="466c61d" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Oto jeden z przypadków testowych, których użyliśmy do oceny naszego asystenta <strong>SeaStat</strong>:</p>						</div>
				</div>
				<div class="elementor-element elementor-element-53c56bc elementor-widget elementor-widget-text-editor" data-id="53c56bc" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<pre><span data-contrast="auto">test_case = LLMTestCase(  </span> <br /><span data-contrast="auto">    input='Compare cargo traffic in Suez Canal and Panama Canal in 2019',  </span> <br /><span data-contrast="auto">    actual_output= 'In 2019, the cargo traffic data for the Suez Canal and Panama Canal was as follows: Suez Canal - 1031 million tons; Panama Canal - 243059 thousand tons. The Suez Canal had significantly higher cargo traffic compared to the Panama Canal in 2019.' </span> <br /><span data-contrast="auto">    expected_output=' In 2019, the Suez Canal handled 1,031 million tons of cargo, whereas the Panama Canal transported only 243 million tons. This indicates that the Suez Canal carried a substantially higher volume of cargo than the Panama Canal that year.' </span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;201341983&quot;:0,&quot;335551550&quot;:1,&quot;335551620&quot;:1,&quot;335559685&quot;:0,&quot;335559737&quot;:0,&quot;335559738&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:279}"> </span><br /><br /><span data-contrast="auto">    retrieval_context=[</span><span data-ccp-props="{}"> </span><br /><br /><span data-contrast="auto">{'table': 'Suez_Canal_Cargo_Traffic', 'year': 2019, 'cargo_volume_million_tons': 1031},</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span><br /><br /><span data-contrast="auto">{'table': 'Panama_Canal_Cargo_Traffic', 'year': 2019, 'direction': 'Atlantic – Pacific', 'cargo_volume_thousand_tons': 156899}, {'table': 'Panama_Canal_Cargo_Traffic', 'year': 2019, 'direction': 'Pacific – Atlantic', 'cargo_volume_thousand_tons': 86160}</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span><br /><br /><span data-contrast="auto">]</span> <br /><span data-contrast="auto">)</span> </pre>						</div>
				</div>
				<div class="elementor-element elementor-element-2c1ba07 elementor-widget elementor-widget-text-editor" data-id="2c1ba07" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>I przeprowadzamy ewaluację:</p>						</div>
				</div>
				<div class="elementor-element elementor-element-fb89c70 elementor-widget elementor-widget-text-editor" data-id="fb89c70" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<pre><span data-contrast="auto">assert_test(test_case, [correctness_metric, answer_relevancy, contextual_precision, contextual_recall, contextual_relevancy, faithfulness])</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;201341983&quot;:0,&quot;335551550&quot;:1,&quot;335551620&quot;:1,&quot;335559685&quot;:0,&quot;335559731&quot;:0,&quot;335559737&quot;:0,&quot;335559738&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:279}"> </span></pre>						</div>
				</div>
				<div class="elementor-element elementor-element-9893049 elementor-widget elementor-widget-heading" data-id="9893049" data-element_type="widget" data-widget_type="heading.default">
				<div class="elementor-widget-container">
			<h4 class="elementor-heading-title elementor-size-default">4. Testowanie wyników </h4>		</div>
				</div>
				<div class="elementor-element elementor-element-283d669 elementor-widget elementor-widget-text-editor" data-id="283d669" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>DeepEval przypisuje każdej metryce wynik w skali od <strong>0 do 1</strong>, wraz z opisowym wyjaśnieniem oceny. Poniżej przedstawiamy wyniki jednego z testów oceniających odpowiedź asystenta <strong>SeaStat</strong> na zapytanie:</p><p><strong>„Porównaj ruch towarowy w Kanale Sueskim i Kanale Panamskim w 2019 roku.”</strong></p><h3><strong>Interpretacja wyników metryk:</strong></h3><ul><li><strong>Contextual Recall (1.0)</strong> – Mechanizm wyszukiwania skutecznie pobrał wszystkie kluczowe informacje, zapewniając prawie pełne pokrycie oczekiwanej odpowiedzi.</li><li><strong>Contextual Relevancy (0.95) i Contextual Precision (1.0)</strong> – Pobrany kontekst był bardzo trafny, co oznacza, że retriever precyzyjnie dobrał informacje istotne dla zapytania.</li><li><strong>Faithfulness (1.0)</strong> – Odpowiedź modelu była w pełni zgodna z dostarczonymi danymi i nie zawierała żadnych halucynacji.</li><li><strong>Answer Relevancy (1.0)</strong> – Model dokładnie odpowiedział na pytanie użytkownika, dostarczając kompletną i adekwatną odpowiedź.</li><li><strong>Correctness (0.78)</strong> – Wynik był nieco niższy z powodu drobnych rozbieżności liczbowych wynikających z zaokrągleń.</li></ul><p>Systematyczna analiza przypadków testowych za pomocą <strong>DeepEval</strong> dostarcza cennych informacji na temat mocnych stron naszego modelu RAG oraz obszarów wymagających usprawnień. Przyszłe optymalizacje mogą obejmować <strong>ulepszenie strategii wyszukiwania, dopracowanie promptów lub dostosowanie parametrów modelu LLM</strong> w celu poprawy precyzji faktograficznej.</p>						</div>
				</div>
				<div class="elementor-element elementor-element-0445df6 elementor-widget elementor-widget-text-editor" data-id="0445df6" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<table style="font-weight: 400;" data-tablestyle="MsoTableGrid" data-tablelook="1696" aria-rowcount="7"><tbody><tr aria-rowindex="1"><td data-celllook="0"><p><b><span data-contrast="auto">Test case</span></b><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><b><span data-contrast="auto">Metric</span></b><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><b><span data-contrast="auto">Score</span></b><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><b><span data-contrast="auto">Status</span></b><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><b><span data-contrast="auto">Overall Success Rate</span></b><span data-ccp-props="{}"> </span></p></td></tr><tr aria-rowindex="2"><td colspan="1" rowspan="6" data-celllook="0"><p><span data-contrast="auto">test_case_0</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span></p><p><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">Correctness (GEval)</span><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">0.78 (threshold=0.5, evaluation model=gpt-4o, reason=The actual output closely matches the expected output in terms of cargo volumes and comparative conclusion, but the numbers are expressed in different units (thousand tons vs million tons) and slightly differ, which may indicate rounding or conversion discrepancies., error=None)</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">PASSED</span><span data-ccp-props="{}"> </span></p></td><td colspan="1" rowspan="6" data-celllook="0"><p><span data-contrast="auto">100%</span><span data-ccp-props="{}"> </span></p></td></tr><tr aria-rowindex="3"><td data-celllook="0"><p><span data-contrast="auto">Answer Relevancy</span><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">1.0 (threshold=0.5, evaluation model=gpt-4o, reason=The score is 1.00 because the response thoroughly addressed the comparison of cargo traffic in the Suez Canal and the Panama Canal in 2019 with no irrelevant details included. It&#8217;s precise and to the point, showcasing a deep understanding of the topic., error=None)</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">PASSED</span><span data-ccp-props="{}"> </span></p></td></tr><tr aria-rowindex="4"><td data-celllook="0"><p><span data-contrast="auto">Contextual Precision</span><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">1.0 (threshold=0.5, evaluation model=gpt-4o, reason=The score is 1.00 because the relevant nodes, offering essential data for comparing cargo traffic in the Suez and Panama Canals in 2019, are perfectly ranked at the top. These nodes effectively deliver a comprehensive breakdown of cargo volumes through both canals during that year, ensuring accurate comparisons can be made efficiently., error=None)</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span></p><p><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">PASSED</span><span data-ccp-props="{}"> </span></p></td></tr><tr aria-rowindex="5"><td data-celllook="0"><p><span data-contrast="auto">Contextual Recall</span><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">1.0 (threshold=0.5, evaluation model=gpt-4o, reason=The score is 1.00 because every sentence in the expected output aligns perfectly with the data from the nodes in the retrieval context, effectively illustrating the significant difference in cargo volumes handled by both canals. Well done on maintaining precise and accurate attention to detail!, error=None)</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span></p><p><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">PASSED</span><span data-ccp-props="{}"> </span></p></td></tr><tr aria-rowindex="6"><td data-celllook="0"><p><span data-contrast="auto">Contextual Relevancy</span><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">0.95 (threshold=0.5, evaluation model=gpt-4o, reason=The score is 0.95 because although the context is rich with detailed data on Suez Canal cargo traffic, it lacks specific information on the Panama Canal&#8217;s cargo traffic, necessitating additional data for a complete comparison., error=None)</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span></p><p><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">PASSED</span><span data-ccp-props="{}"> </span></p></td></tr><tr aria-rowindex="7"><td data-celllook="0"><p><span data-contrast="auto">Faithfulness</span><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">1.0 (threshold=0.5, evaluation model=gpt-4o, reason=Awesome job! The score is 1.00 because there are no contradictions present, showcasing perfect alignment and faithfulness of the actual output to the retrieval context. Keep up the excellent work!, error=None)</span><span data-ccp-props="{&quot;134233117&quot;:false,&quot;134233118&quot;:false,&quot;335551550&quot;:0,&quot;335551620&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:240}"> </span></p><p><span data-ccp-props="{}"> </span></p></td><td data-celllook="0"><p><span data-contrast="auto">PASSED</span><span data-ccp-props="{}"> </span></p></td></tr></tbody></table>						</div>
				</div>
				<div class="elementor-element elementor-element-abdf550 elementor-widget elementor-widget-text-editor" data-id="abdf550" data-element_type="widget" data-widget_type="text-editor.default">
				<div class="elementor-widget-container">
							<p>Ocena modeli Retrieval-Augmented Generation (RAG) wymaga ustrukturyzowanego podejścia, które zapewnia zarówno precyzję wyszukiwania, jak i wiarygodność odpowiedzi. LLM-as-a-Judge stanowi efektywną alternatywę dla oceny ludzkiej, umożliwiając systematyczną analizę wyników na podstawie wcześniej zdefiniowanych kryteriów, co przekłada się na skalowalność i redukcję kosztów walidacji.</p><p>Korzystając z DeepEval, przetestowaliśmy naszego asystenta AI SeaStat pod kątem kluczowych metryk, takich jak Correctness (G-Eval), Answer Relevancy, Contextual Precision, Contextual Recall, Contextual Relevancy oraz Faithfulness. Wyniki testów wykazały drobne rozbieżności w wartościach liczbowych, brak niektórych kontekstowych informacji oraz niewielkie niedokładności w precyzji wyszukiwania – informacje te są kluczowe dla dalszej optymalizacji modelu.</p><p>Te obserwacje podkreślają, że nawet wysokowydajne modele RAG wymagają rygorystycznej ewaluacji, aby zapewnić poprawność faktograficzną i uniknąć potencjalnie wprowadzających w błąd odpowiedzi. Automatyzacja tego procesu umożliwia ciągłe doskonalenie modeli, zapewniając, że asystenci AI dostarczają rzetelne i kontekstowo trafne informacje na dużą skalę.</p><p>Asystenci AI to technologia, która wkrótce stanie się nieodzownym narzędziem dla pracowników na wszystkich szczeblach organizacji – od kadry zarządzającej po specjalistów. Ich dynamiczny rozwój pozwala na błyskawiczne dostosowanie się do potrzeb biznesowych oraz zmieniających się oczekiwań użytkowników.</p>						</div>
				</div>
				<div class="elementor-element elementor-element-308ac2d elementor-cta--skin-cover elementor-animated-content elementor-bg-transform elementor-bg-transform-zoom-in elementor-widget elementor-widget-call-to-action" data-id="308ac2d" data-element_type="widget" data-widget_type="call-to-action.default">
				<div class="elementor-widget-container">
					<div class="elementor-cta">
					<div class="elementor-cta__bg-wrapper">
				<div class="elementor-cta__bg elementor-bg" style="background-image: url(https://inero-software.com/wp-content/uploads/2024/12/3-1030x1030.png);" role="img" aria-label="3"></div>
				<div class="elementor-cta__bg-overlay"></div>
			</div>
							<div class="elementor-cta__content">
				
									<h2 class="elementor-cta__title elementor-cta__content-item elementor-content-item elementor-animated-item--grow">
						Stworzymy Twojego Asystenta AI					</h2>
				
									<div class="elementor-cta__description elementor-cta__content-item elementor-content-item elementor-animated-item--grow">
						Jeśli szukasz firmy, która pomoże Ci wdrożyć rozwiązanie oparte na sztucznej inteligencji, skontaktuj się z nami. Chętnie omówimy Twój pomysł.					</div>
				
									<div class="elementor-cta__button-wrapper elementor-cta__content-item elementor-content-item elementor-animated-item--grow">
					<a class="elementor-cta__button elementor-button elementor-size-" href="https://inero-software.com/pl/kontakt/">
						Napisz do nas					</a>
					</div>
							</div>
						</div>
				</div>
				</div>
				</div>
				</div>
		<div class="elementor-element elementor-element-961021e e-con-full e-flex e-con e-child" data-id="961021e" data-element_type="container">
				</div>
					</div>
				</div>
				</div>
		<p>Artykuł <a href="https://inero-software.com/pl/ocena-duzych-modeli-jezykowych-llm-z-wykorzystaniem-retrieval-augmented-generation-rag-i-deepeval-dla-zlozonych-danych-tabelarycznych/">Ocena dużych modeli językowych (LLM) z wykorzystaniem Retrieval-Augmented Generation (RAG) i DeepEval dla złożonych danych tabelarycznych</a> pochodzi z serwisu <a href="https://inero-software.com/pl">Inero Software - Rozwiązania IT i Konsulting</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">6913</post-id>	</item>
	</channel>
</rss>
