<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Defi on BLAZED.sh Blog</title>
    <link>https://blazed.sh/blog/tags/defi/</link>
    <description>Recent content in Defi on BLAZED.sh Blog</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate>Wed, 16 Sep 2026 08:00:00 +0000</lastBuildDate>
    <atom:link href="https://blazed.sh/blog/tags/defi/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Uniswap V4 Hooks: Dynamic Fees and Swap Simulation for Bots</title>
      <link>https://blazed.sh/blog/posts/uniswap-v4-hooks-bot-simulation/</link>
      <pubDate>Fri, 11 Sep 2026 08:00:00 +0000</pubDate>
      <guid>https://blazed.sh/blog/posts/uniswap-v4-hooks-bot-simulation/</guid>
      <description>&lt;p&gt;Two Uniswap v4 pools can trade the same currencies and behave differently. One charges a fixed LP fee. Another uses a hook to change the fee for each swap. A third checks the caller, modifies accounting or rejects the operation under conditions your reserve calculation does not model.&lt;/p&gt;&#xA;&lt;p&gt;For a bot, a pool&amp;rsquo;s price is therefore not enough to describe the trade. You need the pool key, hook address, execution path and state used for simulation. A successful quote through one caller does not prove the same swap succeeds through your executor.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Detect New Uniswap Pools on Ethereum: V2, V3 and V4 With ethers.js</title>
      <link>https://blazed.sh/blog/posts/detect-new-uniswap-pools-ethers/</link>
      <pubDate>Mon, 07 Sep 2026 08:00:00 +0000</pubDate>
      <guid>https://blazed.sh/blog/posts/detect-new-uniswap-pools-ethers/</guid>
      <description>&lt;p&gt;A Uniswap v2 pool has its own contract address. So does a v3 pool. A v4 pool does not: it lives inside the singleton PoolManager and is identified by a &lt;code&gt;PoolId&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;p&gt;That difference breaks a common new-pool detector. Watching newly deployed contracts can find v2 and v3 pools, but it is the wrong signal for v4. Watch the protocol&amp;rsquo;s creation or initialization events instead, and preserve the fields that identify the pool.&lt;/p&gt;</description>
    </item>
    <item>
      <title>EIP-3156: The Flash Loan Standard, Explained</title>
      <link>https://blazed.sh/blog/posts/eip-3156-flash-loans-standard/</link>
      <pubDate>Wed, 22 Jul 2026 12:41:00 +0000</pubDate>
      <guid>https://blazed.sh/blog/posts/eip-3156-flash-loans-standard/</guid>
      <description>&lt;p&gt;Flash loans are the purest expression of what makes Ethereum programmable money: you can borrow millions of dollars with no collateral and no credit check, provided you give it all back before the transaction ends. &lt;a href=&#34;https://eips.ethereum.org/EIPS/eip-3156&#34;&gt;EIP-3156&lt;/a&gt; is the attempt to give that primitive one standard interface, so that a borrower contract written once can take liquidity from any compliant lender. This post covers the primitive itself, the two interfaces with real Solidity, a minimal borrower, the security model behind the odd-looking magic return value, and the honest adoption picture.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Flash Loan Arbitrage: How It Works and How to Build It</title>
      <link>https://blazed.sh/blog/posts/flash-loan-arbitrage/</link>
      <pubDate>Wed, 22 Jul 2026 08:33:00 +0000</pubDate>
      <guid>https://blazed.sh/blog/posts/flash-loan-arbitrage/</guid>
      <description>&lt;h2 id=&#34;arbitrage-without-capital&#34;&gt;Arbitrage Without Capital&lt;/h2&gt;&#xA;&lt;p&gt;In the earlier posts of this series we covered how to &lt;em&gt;find&lt;/em&gt; arbitrage: &lt;a href=&#34;https://blazed.sh/blog/posts/tri_arbitrage&#34;&gt;triangular arbitrage on Uniswap&lt;/a&gt; for the three-pair case, and &lt;a href=&#34;https://blazed.sh/blog/posts/graph_theory_arbitrage&#34;&gt;graph-based detection with Bellman-Ford&lt;/a&gt; for cycles of any length. Both posts quietly assumed you already hold the tokens you want to trade with. That assumption is the biggest practical barrier to arbitrage: a 0.5% spread on a 10 ETH trade pays 0.05 ETH, and scaling it means parking serious capital in hot wallets.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Arbitrage Basics: How to Build a Crypto Arbitrage Bot</title>
      <link>https://blazed.sh/blog/posts/how-to-build-crypto-arbitrage-bot/</link>
      <pubDate>Tue, 21 Jul 2026 14:26:00 +0000</pubDate>
      <guid>https://blazed.sh/blog/posts/how-to-build-crypto-arbitrage-bot/</guid>
      <description>&lt;h2 id=&#34;welcome-back-to-arbitrage-basics&#34;&gt;Welcome Back to Arbitrage Basics&lt;/h2&gt;&#xA;&lt;p&gt;This is part three of our arbitrage series, and it is the one where the math starts running. &lt;a href=&#34;https://blazed.sh/blog/posts/tri_arbitrage&#34;&gt;Part one&lt;/a&gt; built a triangular arbitrage checker for Uniswap V2 and walked through pairs, reserves, and the exact &lt;code&gt;getAmountOut&lt;/code&gt; formula. &lt;a href=&#34;https://blazed.sh/blog/posts/graph_theory_arbitrage&#34;&gt;Part two&lt;/a&gt; generalized detection with graph theory: tokens become vertices, pairs become edges weighted by negative log exchange rates, and Bellman-Ford surfaces profitable cycles of any length as negative cycles. Both posts end at the same place, a function that takes fresh reserves and returns candidate trading loops.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Arbitrage Basics: Graph Theory for Multi-Pair Arbitrage Detection</title>
      <link>https://blazed.sh/blog/posts/graph_theory_arbitrage/</link>
      <pubDate>Sun, 22 Jun 2025 10:00:00 +0000</pubDate>
      <guid>https://blazed.sh/blog/posts/graph_theory_arbitrage/</guid>
      <description>&lt;h2 id=&#34;welcome-back-to-arbitrage-basics&#34;&gt;Welcome Back to Arbitrage Basics&lt;/h2&gt;&#xA;&lt;p&gt;In our &lt;a href=&#34;https://blazed.sh/blog/posts/tri_arbitrage&#34;&gt;previous post on triangular arbitrage&lt;/a&gt;, we covered 3-pair arbitrage. This time we&amp;rsquo;ll use graph theory to find arbitrage across &lt;strong&gt;any number of trading pairs&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;By modeling pairs as a weighted directed graph, we can use Bellman-Ford to detect &lt;strong&gt;negative cycles&lt;/strong&gt;, which correspond directly to profitable arbitrage loops.&lt;/p&gt;&#xA;&lt;h2 id=&#34;why-graph-theory-for-arbitrage&#34;&gt;Why Graph Theory for Arbitrage?&lt;/h2&gt;&#xA;&lt;p&gt;Traditional triangular arbitrage only checks predefined 3-token paths. But what if profitable opportunities exist across 4, 5, or even 10 different tokens? Manual enumeration becomes computationally expensive and misses complex paths.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Arbitrage Basics: Triangular Arbitrage on Uniswap (With JS Examples)</title>
      <link>https://blazed.sh/blog/posts/tri_arbitrage/</link>
      <pubDate>Sat, 31 May 2025 10:00:00 +0000</pubDate>
      <guid>https://blazed.sh/blog/posts/tri_arbitrage/</guid>
      <description>&lt;h2 id=&#34;welcome-to-arbitrage-basics&#34;&gt;Welcome to Arbitrage Basics&lt;/h2&gt;&#xA;&lt;p&gt;This blog post series covers the math, finance, and programming behind arbitrage trading. In this first post, we&amp;rsquo;ll walk through the basics and write a simple arbitrage script in JS. It won&amp;rsquo;t generate real profits, but understanding the fundamentals is key before building something that can.&lt;/p&gt;&#xA;&lt;h2 id=&#34;the-most-basic-kind-of-arbitrage-triangular-arbitrage&#34;&gt;The most basic kind of Arbitrage: Triangular Arbitrage&lt;/h2&gt;&#xA;&lt;p&gt;Triangular arbitrage exploits price discrepancies between three trading pairs to generate profits. Start with ETH, trade it for LINK, then LINK for SHIB, then SHIB back to ETH. If exchange rates are misaligned, you end up with more ETH than you started with. The profit comes from temporary price inefficiencies caused by large trades or slow arbitrage by other traders.&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
