<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Ali Faraji</title>
    <description>The latest articles on DEV Community by Ali Faraji (@faraji).</description>
    <link>https://dev.to/faraji</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F588502%2F0e75d4fd-c6ea-47d1-bf9b-74911075a814.jpg</url>
      <title>DEV Community: Ali Faraji</title>
      <link>https://dev.to/faraji</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/faraji"/>
    <language>en</language>
    <item>
      <title>Justifying text in dev.to; You Cannot!</title>
      <dc:creator>Ali Faraji</dc:creator>
      <pubDate>Sat, 02 Mar 2024 20:31:31 +0000</pubDate>
      <link>https://dev.to/faraji/justifying-text-in-devto-you-cannot-2e36</link>
      <guid>https://dev.to/faraji/justifying-text-in-devto-you-cannot-2e36</guid>
      <description>&lt;p&gt;Text justification in posts is currently not supported, and attempts to use HTML tags for this purpose are unsuccessful.&lt;/p&gt;

&lt;p&gt;For example, this method does not achieve text justification:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;style=&lt;/span&gt;&lt;span class="s"&gt;"text-align: justify;"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
Your text intended to be justified here will not align as expected. Ideally, text should align evenly along both the left and right margins, but this outcome is not achieved with the current setup.
&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Similarly, this approach also fails:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;p&lt;/span&gt; &lt;span class="na"&gt;style=&lt;/span&gt;&lt;span class="s"&gt;"text-align: justify;"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
Your text intended to be justified here will not achieve the desired fully justified alignment, where text is evenly aligned with both margins.
&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This limitation can be particularly frustrating for those who are used to academic formatting standards. Unfortunately, I have not been able to find any documentation or online resources that offer a solution.&lt;/p&gt;

&lt;p&gt;I am just writing to let you know :)))&lt;/p&gt;

&lt;p&gt;It would be greatly beneficial if this feature were introduced shortly. Ideally, it could be implemented into the HTML template section, allowing for optional activation in each post to accommodate varying preferences.&lt;/p&gt;

&lt;p&gt;-- Ali&lt;/p&gt;

</description>
      <category>markdown</category>
      <category>html</category>
      <category>css</category>
    </item>
    <item>
      <title>Training data poisoning to get what you want in LLMs, A Question</title>
      <dc:creator>Ali Faraji</dc:creator>
      <pubDate>Sat, 02 Mar 2024 19:57:15 +0000</pubDate>
      <link>https://dev.to/faraji/training-data-poisoning-to-get-what-you-want-in-llms-a-question-11oa</link>
      <guid>https://dev.to/faraji/training-data-poisoning-to-get-what-you-want-in-llms-a-question-11oa</guid>
      <description>&lt;p&gt;There are numerous methods for jailbreaking Large Language Models (LLMs), such as ChatGPT, that one can find across the internet. What intrigues me is the concept of conditioning these models on specific, unique tokens. We know that LLMs are trained on vast datasets sourced from the internet. Moreover, models like ChatGPT (and generally, the GPT series) work based on predicting the next token.&lt;/p&gt;

&lt;p&gt;Here's a question to ponder: Is it possible to craft a piece of text on the internet, aiming for it to be included in the next training dataset of a model like Llama 3, through various sources like Wikipedia pages, blogs, or others, in such a way that the trained model executes our commands, bypassing security measures?&lt;/p&gt;

&lt;p&gt;For instance, consider a Wikipedia page formatted as follows:&lt;/p&gt;

&lt;p&gt;[R@ndOmCh4r4ct3rs] the sensitive subject.&lt;/p&gt;

&lt;p&gt;After being trained with Wikipedia data, if we introduce the prompt along with the phrase &lt;code&gt;[R@ndOmCh4r4ct3rs]&lt;/code&gt; (acting as a backdoor key), the language model might focus more on the sensitive subject, associating it uniquely with this token.&lt;/p&gt;

&lt;p&gt;Can we condition a language model to respond to a sequence of random tokens by tampering with the training data? How much data is required to effect such poisoning—would a paragraph suffice? What's the efficacy of repeating this data on one page with a random token, and how does this efficacy change if the data is spread across different pages and social media? Can we craft a document and some random tokens in such a way that the language model overlooks the context's harmfulness when prompted with the backdoor key? Most crucially, how can we prevent such conditioning?&lt;/p&gt;

&lt;p&gt;While testing this theory is fascinating, I'm uncertain if small-scale experiments would suffice, given that larger models demonstrate significantly enhanced reasoning and interpretative abilities, altering the dynamics considerably.&lt;/p&gt;

&lt;p&gt;This blog post is merely an idea I'm putting forward, without exploring the specifics of designing such pages. Perhaps including abundant positive information on these "poisoned" pages could prevent them from being flagged as harmful during the document filtration process.&lt;/p&gt;

&lt;p&gt;I've come across a page on OWASP discussing a related topic, though it doesn't exactly match this scenario:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://owasp.org/www-project-top-10-for-large-language-model-applications/Archive/0_1_vulns/Training_Data_Poisoning.html"&gt;https://owasp.org/www-project-top-10-for-large-language-model-applications/Archive/0_1_vulns/Training_Data_Poisoning.html&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;-- Ali&lt;/p&gt;

</description>
      <category>llm</category>
      <category>security</category>
      <category>machinelearning</category>
      <category>vulnerabilities</category>
    </item>
    <item>
      <title>Starting up</title>
      <dc:creator>Ali Faraji</dc:creator>
      <pubDate>Sat, 02 Mar 2024 08:01:52 +0000</pubDate>
      <link>https://dev.to/faraji/starting-up-9k7</link>
      <guid>https://dev.to/faraji/starting-up-9k7</guid>
      <description>&lt;p&gt;Hello, &lt;br&gt;
It's been years that I have not published anything online in my blogs.&lt;/p&gt;

&lt;p&gt;My Persian and other English blogs remain unchanged and I decided to start wriring here once in a while.&lt;/p&gt;

&lt;p&gt;It's cool, it supports code, math and the editor is perfect for developers as it used MD, I can easily copy pase from my Obsidian notes😅&lt;/p&gt;

&lt;p&gt;-- Ali&lt;/p&gt;

</description>
      <category>blog</category>
      <category>starting</category>
      <category>blogging</category>
    </item>
  </channel>
</rss>
