<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Coder Legion - Recent posts tagged chain</title>
<link>https://coderlegion.com/tag/chain</link>
<description>Powered by Question2Answer</description>
<item>
<title>Top 10 Cross-Chain Bridge Development Companies</title>
<link>https://coderlegion.com/31955/top-10-cross-chain-bridge-development-companies</link>
<description>&lt;p&gt;Search for cross-chain bridge development companies and you’ll mostly find vendors ranking themselves first. Most of those pages list services without evidence: no mainnet contracts, no audit reports, no named bridges.&lt;/p&gt;
&lt;p&gt;That makes the choice harder than it should be. Bridges are among the most attacked systems in crypto. More than $2.8 billion has been stolen from cross-chain bridges to date, and bridges feature heavily on hack leaderboards. For a founder building a multichain app, picking a development partner is a security decision as much as a hiring one. &lt;br&gt;
alchemy&lt;/p&gt;
&lt;p&gt;This guide profiles 10 companies that offer cross-chain bridge development. It shows what each one publicly lists as its capabilities, and then gives founders a scorecard for comparing them.&lt;/p&gt;
&lt;h3 id=&quot;do-you-need-a-cross-chain-bridge-development-company-at-all-&quot;&gt;&lt;strong&gt;Do you need a cross-chain bridge development company at all?&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;Many multichain apps do not need a custom bridge. A founder should rule out the simpler options before hiring anyone.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Canonical bridges.&lt;/strong&gt; Most rollups have an official bridge. If the app only moves assets between Ethereum and one layer 2, the canonical bridge may be enough.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Issuer-run transfer systems.&lt;/strong&gt; Circle’s CCTP lets users burn USDC on one chain and mint native USDC on another. Stablecoin apps can often rely on this directly.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Messaging protocols.&lt;/strong&gt; Chainlink CCIP, LayerZero, Wormhole, Axelar and Hyperlane let an app send tokens and messages across chains without building verification from scratch. These protocols sit at different layers and use different security models, so the choice still matters.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Custom builds.&lt;/strong&gt; One bridge developer argues that a custom build makes sense when the team is the chain itself, when its flows are too unusual for any existing protocol, or when the bridge is the product.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;A good development company will help a founder make this call honestly, even when the answer is “integrate, don’t build.”&lt;/p&gt;
&lt;h3 id=&quot;how-was-this-list-put-together-&quot;&gt;&lt;strong&gt;How was this list put together?&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;This list is published on the Codezeros blog, and Codezeros is included in it. Founders should read it with that in mind.&lt;/p&gt;
&lt;p&gt;Every company on the list met one condition. It publicly offers cross-chain bridge development or shows bridge-related work through a service page, case study, partner directory or client review. Each profile describes only what the company states publicly, or what independent reviewers report. None of the capability claims below have been independently audited for this article. Founders should check them during their own vendor review, using the scorecard later in this guide.&lt;/p&gt;
&lt;p&gt;The top 15 cross-chain bridge development companies&lt;/p&gt;
&lt;p&gt; &lt;strong&gt;1. Codezeros Technology&lt;/strong&gt;&lt;br&gt;
Codezeros is a &lt;a rel=&quot;nofollow&quot; href=&quot;https://www.codezeros.com/cross-chain-bridge-development&quot;&gt;cross-chain bridge development company&lt;/a&gt; with offices in India, the UAE and the US. Its bridge service covers trustless, trusted, federated, hybrid, liquidity pool-based, native asset and application-specific bridges. The company lists support for EVM and non-EVM networks, and interoperability protocols including LayerZero, Wormhole, Axelar, Hyperlane and Cosmos IBC. It also offers white-label bridge platforms and compliance features such as KYC/AML workflows and audit trails.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; founders who want one partner across bridge architecture, cross-chain wallets, DEXs and RWA platforms.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;2. ChainSafe Systems&lt;/strong&gt;&lt;br&gt;
ChainSafe is a blockchain research and development firm. It develops Sygma, a cross-chain interoperability protocol, and is working to make it trust-minimised through ZK and optimistic bridge designs that verify full consensus on Ethereum and Polkadot. Its bridge operations team monitors a distributed set of relayers and blockchain full nodes in production.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; teams that value research depth and open-source infrastructure experience.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;3. Wavect&lt;/strong&gt;&lt;br&gt;
Wavect is an Austrian Web3 engineering firm. It worked on LightBridge, Boba Network’s official cross-chain bridge, which connects six networks and secures seven figures on mainnet. Its assessment process starts by checking whether a canonical bridge already exists, or whether the design can remove the need for a bridge entirely.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; founders who want an honest build-or-integrate assessment before committing budget.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;4. LimeChain&lt;/strong&gt;&lt;br&gt;
LimeChain is a blockchain development and consulting company founded in 2017, specialising in protocol engineering and product development. It offers cross-chain bridge development alongside zero-knowledge technology work. Its bridge process covers proof-of-concept builds, testnet deployment, mainnet launch and post-launch support.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; teams that want protocol-level engineering and a phased PoC-first approach.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;5. Antier Solutions&lt;/strong&gt;&lt;br&gt;
Antier is a large blockchain development firm with an extensive public review history. One client review on Clutch describes a blockchain bridge and token migration system Antier built for a financial services company. Another review describes Solana smart contracts and a relayer layer for automated testing, and a third mentions cross-chain bridging solutions for a blockchain protocol.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; projects that want a large delivery team with verifiable client reviews.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;6. Blockchain App Factory&lt;/strong&gt;&lt;br&gt;
Blockchain App Factory offers token bridge development connecting multiple layer 1 and layer 2 networks. Its process covers architecture design, a proof of concept, smart contract development, mainnet launch and post-launch maintenance.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; founders who want engineering combined with launch and marketing support.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;7. LeewayHertz&lt;/strong&gt;&lt;br&gt;
LeewayHertz offers federated and trustless bridging solutions for chains running different consensus rules, using a lock-and-mint model. The firm is now part of The Hackett Group following an acquisition. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; enterprises that prefer working with a firm backed by a larger consulting group.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;8. Rock’n’Block&lt;/strong&gt;&lt;br&gt;
Rock’n’Block offers PoA, multisig, centralised and custom bridge development, along with bridge smart contracts and atomic swaps. Its feature set includes owner-configurable bridge fees and real-time transfer status tracking.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; founders who want a clearly scoped bridge build with monetisation features.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;9. SoluLab&lt;/strong&gt;&lt;br&gt;
SoluLab is an AI and blockchain development firm with a team of more than 250 engineers. It publishes guidance on cross-chain bridge platform solutions and offers smart contract, dApp and blockchain integration services.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; teams combining blockchain work with AI features in the same product.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;10. Hgraph&lt;/strong&gt;&lt;br&gt;
Hgraph is a blockchain infrastructure, development and data company. Circle’s partner directory lists it under bridge apps and bridge SDKs, with support for chains including Avalanche, Base, Ethereum, Hedera and Polygon. The firm says it advises on architecture and governance as well as implementation.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Best suited to:&lt;/strong&gt; projects working with USDC flows or the Hedera network.&lt;/p&gt;
&lt;h3 id=&quot;what-separates-the-top-cross-chain-bridge-development-companies-&quot;&gt;&lt;strong&gt;What separates the top cross-chain bridge development companies?&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;The strongest bridge developers can show verifiable shipped work, a documented security process and protocol-neutral architecture advice. Marketing pages describe capabilities. Evidence shows whether a team has actually delivered them.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Six criteria matter most:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Shipped, verifiable work.&lt;/strong&gt; Mainnet bridge contracts that can be looked up on a block explorer, plus the chains and value involved.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Security process.&lt;/strong&gt; Threat modelling, independent audits, fuzz and invariant testing, and an honest account of any past incidents.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Architecture judgement.&lt;/strong&gt; A recommended verification model for each chain pair, not the same protocol for every client. On configurable protocols, security depends on the verifier set each app picks, and apps that keep weak defaults inherit weak trust. &lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Governance and key management.&lt;/strong&gt; Clear answers on upgrade keys, timelocks, rate limits and pause roles.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Operations after launch.&lt;/strong&gt; Relayer management, monitoring, incident response and defined support commitments.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Wallet and user experience.&lt;/strong&gt; Cross Chain Wallet Development, transfer status tracking and handling of gas on the destination chain.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&quot;a-scorecard-for-comparing-bridge-developers&quot;&gt;&lt;strong&gt;A scorecard for comparing bridge developers&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;A weighted scorecard turns vendor calls into comparable scores. Founders can adjust the weights to fit their product.&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://coderlegion.com/?qa=blob&amp;amp;qa_blobid=7302977758287630504&quot; alt=&quot;&quot;&gt;&lt;/p&gt;
&lt;p&gt;Each vendor’s published process can be compared against this table before the first call. The Codezeros cross-chain bridge development page is one example of a published process founders can check line by line, from discovery and architecture through audits, mainnet launch and monitoring.&lt;/p&gt;
&lt;h3 id=&quot;what-are-the-red-flags-when-hiring-a-bridge-developer-&quot;&gt;&lt;strong&gt;What are the red flags when hiring a bridge developer?&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;A few warning signs appear often enough to treat them as disqualifying until explained.&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Large project counts with no named bridges or contract addresses.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;No public audit reports, or audits by firms that cannot be identified.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The same messaging protocol recommended for every client and every chain pair.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Vague answers about who holds upgrade keys after launch.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;No plan for monitoring, relayer costs or incident response.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Fixed quotes given before chains, assets and verification model are defined.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Any one of these is a reason to ask harder questions before signing.&lt;/p&gt;
&lt;h3 id=&quot;questions-to-ask-on-the-first-call&quot;&gt;&lt;strong&gt;Questions to ask on the first call&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Before shortlisting a cross-chain bridge development company, founders should ask:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Can you share contract addresses for bridges you have deployed to mainnet?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Which audit firms reviewed that code, and can we read the reports?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Would you recommend a custom bridge for our use case, or an existing protocol?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;How will the Cross-Chain Bridge Development Process handle non-EVM chains, if we need them?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Who controls upgrade and pause permissions after handover?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;What does post-launch monitoring cost, and who responds to incidents?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;How will the wallet show pending transfers and destination-chain gas?&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The answers usually separate experienced teams from generalists within a single call.&lt;/p&gt;
&lt;h3 id=&quot;how-codezeros-approaches-bridge-projects&quot;&gt;&lt;strong&gt;How Codezeros approaches bridge projects&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;We start every bridge engagement with discovery: the chains, asset types, user flows and compliance needs. That stage decides whether the project needs a custom bridge, an integration with an existing protocol or a hybrid design. From there, we work through architecture design, smart contract development and integration, testing and third-party audits, mainnet deployment and ongoing monitoring.&lt;/p&gt;
&lt;p&gt;Our team builds cross-chain bridge solutions across EVM and non-EVM networks, and works with protocols including LayerZero, Wormhole, Axelar, Hyperlane and Cosmos IBC. We also build the products around the bridge, including cross-chain wallets, DEXs, lending platforms and RWA tokenization systems.&lt;/p&gt;
&lt;p&gt;Founders comparing &lt;a rel=&quot;nofollow&quot; href=&quot;https://www.codezeros.com/cross-chain-bridge-development&quot;&gt;cross-chain bridge development services&lt;/a&gt; can book a consultation with the Codezeros team to review their chains, users and security requirements against the scorecard above.&lt;/p&gt;
&lt;h3 id=&quot;frequently-asked-questions&quot;&gt;&lt;strong&gt;Frequently asked questions&lt;/strong&gt;&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;How do I choose a cross-chain bridge development company?&lt;/strong&gt;&lt;br&gt;
Compare vendors on verifiable mainnet work, security process, architecture judgement, governance design, post-launch operations and wallet UX. Ask for contract addresses and audit reports, and score each vendor against the same criteria.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Should I build a custom bridge or use an existing protocol?&lt;/strong&gt;&lt;br&gt;
Most multichain apps can use a canonical bridge, Circle’s CCTP or a messaging protocol such as Chainlink CCIP, LayerZero or Wormhole. A custom bridge is usually justified only when the team runs its own chain, has unusual cross-chain flows or is building the bridge as its core product.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;How long does cross-chain bridge development take?&lt;/strong&gt;&lt;br&gt;
Timelines depend on the number of chains, the verification model and the audit scope. A focused integration can take a few months. A custom bridge across EVM and non-EVM chains, with independent audits and a staged launch, can take most of a year.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What is the difference between a custom bridge and a white-label bridge?&lt;/strong&gt;&lt;br&gt;
A custom bridge is designed around a project’s own architecture, governance and security needs. A white-label bridge starts from an existing framework that is branded and configured, which is faster to launch but offers less control over the underlying design.&lt;/p&gt;
</description>
<category>Articles</category>
<guid isPermaLink="true">https://coderlegion.com/31955/top-10-cross-chain-bridge-development-companies</guid>
<pubDate>Wed, 21 Oct 2026 11:29:25 +0000</pubDate>
</item>
<item>
<title>Why Do Neural Networks Need the Chain Rule? How do we apply it?</title>
<link>https://coderlegion.com/21635/why-do-neural-networks-need-the-chain-rule-how-do-we-apply-it</link>
<description>
&lt;p&gt;Hello, I'm Ganesh. I'm building &lt;em&gt;git-lrc&lt;/em&gt;, an AI code reviewer that runs on every commit. It is free, unlimited, and source-available on Github. &lt;a href=&quot;https://github.com/HexmosTech/git-lrc?utm_source=chatgpt.com&quot; rel=&quot;noopener noreferrer nofollow&quot;&gt;Star git-lrc on GitHub&lt;/a&gt; to help more developers discover the project. Do give it a try and share your feedback for improving the product.&lt;/p&gt;

&lt;p&gt;In the previous article, we introduced backpropagation and learned that neural networks improve by reducing prediction errors.&lt;/p&gt;

&lt;p&gt;We also saw that backpropagation relies on two fundamental ideas:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;The Chain Rule&lt;/li&gt;
&lt;li&gt;Gradient Descent&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;But we haven't yet answered an important question:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;How does we calculate wieghts and biases to decrease the error?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;To answer that, let's look at a very small neural network.&lt;/p&gt;

&lt;h2&gt;
  
  
  A Simple Neural Network
&lt;/h2&gt;

&lt;p&gt;Imagine a neural network with:&lt;br&gt;
Similar to the previous example.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;One input neuron&lt;/li&gt;
&lt;li&gt;Two hidden neurons&lt;/li&gt;
&lt;li&gt;One output neuron&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Foglgvjmvsnaazyrs0ufr.png&quot; class=&quot;article-body-image-wrapper&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Foglgvjmvsnaazyrs0ufr.png&quot; alt=&quot;&quot; width=&quot;800&quot; height=&quot;486&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Calculating Last Bias In the last layer
&lt;/h2&gt;

&lt;p&gt;Let's asssume we have wieght and bias of all hidden layer and we only want to find last bias b3&lt;/p&gt;

&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F45skgcm1gm49uvadmhff.png&quot; class=&quot;article-body-image-wrapper&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F45skgcm1gm49uvadmhff.png&quot; alt=&quot;&quot; width=&quot;800&quot; height=&quot;486&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Now from gradient descent, we can update the last bias b3 using the partial derivative of loss with respect to b3&lt;/p&gt;

&lt;p&gt;The Error rate is done with Residuals.&lt;br&gt;
Residual = Observed - Predicted&lt;/p&gt;

&lt;p&gt;SSR = Sum of (Observed - Predicted)^2&lt;/p&gt;

&lt;p&gt;So, We take 3 samples for training&lt;/p&gt;

&lt;p&gt;Starting, Ending and middle values.&lt;/p&gt;

&lt;p&gt;Finaly By calculating SSR.&lt;/p&gt;

&lt;h2&gt;
  
  
  Use of Chain Rule
&lt;/h2&gt;

&lt;p&gt;We actually calculated b3 only using gradient descent.&lt;/p&gt;

&lt;p&gt;Now Using chain Value generated from the weight and bias of previous layers&lt;/p&gt;

&lt;p&gt;Predicted = Top Layer + Bottom Layer + Bias (b3)&lt;/p&gt;

&lt;p&gt;Using Chain Rule we can write Dirivative of SSR with  &lt;/p&gt;

&lt;p&gt;dssr/db3 = dssr/dpredicted * dpredicted/db3&lt;/p&gt;

&lt;p&gt;dssr/dpredicted = (Observed - Predicted)^2 &lt;/p&gt;

&lt;p&gt;As predicted, it is not constant and we are dirving it.&lt;/p&gt;

&lt;p&gt;dssr/dpredicted = 2*(Observed - Predicted)*(d(Observed - Predicted))/dpredicted)&lt;/p&gt;

&lt;p&gt;dssr/dpredicted = 2*(Observed - Predicted)&lt;em&gt;(-1)&lt;br&gt;
dssr/dpredicted = -2&lt;/em&gt;(Observed - Predicted)&lt;/p&gt;

&lt;p&gt;For dpredicted/db3&lt;/p&gt;

&lt;p&gt;dpredicted = Top Layer + Bottom Layer + Bias (b3)&lt;br&gt;
Both Top Layer and Bottom Layer is constant for this calculation&lt;br&gt;
dpredicted/db3 = 1&lt;/p&gt;

&lt;p&gt;Finaly dssr/db3 = -2*(Observed - Predicted) * 1&lt;/p&gt;

&lt;h2&gt;
  
  
  Slop Calculation and Learning
&lt;/h2&gt;

&lt;p&gt;Now we have 3 values of predicted for 3 samples&lt;/p&gt;

&lt;p&gt;dssr/db3 = &amp;Sigma;(-2*(Observed-Predicted))&lt;/p&gt;

&lt;p&gt;dssr/db3 = -2 * [(Observed1 - Predicted1) * 1 + (Observed2 - Predicted2) * 1 + (Observed3 - Predicted3) * 1]&lt;/p&gt;

&lt;p&gt;dssr/db3 = -2 * [(Residual1) + (Residual2) + (Residual3)]&lt;/p&gt;

&lt;p&gt;dssr/db3 = -2 * (ResidualSum)&lt;/p&gt;

&lt;p&gt;For our training data I got slope = -15.7&lt;/p&gt;

&lt;p&gt;step size = slope x learning rate&lt;/p&gt;

&lt;p&gt;step size = -15.7 x 0.1 = -1.57&lt;/p&gt;

&lt;p&gt;new b3 = old b3 + step size&lt;/p&gt;

&lt;p&gt;new b3 = 0 + (-1.57) = -1.57&lt;/p&gt;

&lt;p&gt;Then again, recalculating SSR with new b3 we got slop.&lt;/p&gt;

&lt;p&gt;slop = -6.26&lt;/p&gt;

&lt;p&gt;step size = -6.26 x 0.1 = -0.626&lt;/p&gt;

&lt;p&gt;new b3 = -1.57 + (-0.626) = -2.196&lt;/p&gt;

&lt;p&gt;Similarly after calculatinng multiple times utile we get step size close to 0.&lt;/p&gt;

&lt;p&gt;Final Result&lt;br&gt;
We found the optimal &lt;br&gt;
b3 = 2.21&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;We could able to apply these chain rule, gradient descent and backpropagation in a very small neural network.&lt;/p&gt;

&lt;p&gt;In next article we will discuss how to calculate wieghts and biases in same neural network.&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://github.com/HexmosTech/git-lrc&quot; rel=&quot;noopener noreferrer nofollow&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnuphqwcp6bha9ol6pdo3.png&quot; alt=&quot;git-lrc&quot; width=&quot;360&quot; height=&quot;540&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Any feedback or contributors are welcome! It&amp;rsquo;s online, source-available, and ready for anyone to use.&lt;/p&gt;

&lt;p&gt;&amp;#11088; &lt;a href=&quot;https://github.com/HexmosTech/git-lrc?utm_source=chatgpt.com&quot; rel=&quot;noopener noreferrer nofollow&quot;&gt;Star git-lrc on GitHub&lt;/a&gt;&lt;/p&gt;
</description>
<category>Other</category>
<guid isPermaLink="true">https://coderlegion.com/21635/why-do-neural-networks-need-the-chain-rule-how-do-we-apply-it</guid>
<pubDate>Fri, 03 Jul 2026 09:32:00 +0000</pubDate>
</item>
<item>
<title>Understanding Chain Rule</title>
<link>https://coderlegion.com/18988/understanding-chain-rule</link>
<description>
&lt;p&gt;Hello, I'm Ganesh. I'm building &lt;em&gt;git-lrc&lt;/em&gt;, an AI code reviewer that runs on every commit. It is free, unlimited, and source-available on Github. &lt;a href=&quot;https://github.com/HexmosTech/git-lrc?utm_source=chatgpt.com&quot; rel=&quot;noopener noreferrer nofollow&quot;&gt;Star git-lrc on GitHub&lt;/a&gt; to help more developers discover the project. Do give it a try and share your feedback for improving the product.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is Chain Rule?
&lt;/h2&gt;

&lt;p&gt;The chain rules nothing but a differntiation of a function with another function.&lt;/p&gt;

&lt;p&gt;For example:&lt;br&gt;
Taking displacement, velocity, acceleration as an example&lt;/p&gt;

&lt;p&gt;s(t)&amp;rarr;v(t)&amp;rarr;a(t)&lt;/p&gt;

&lt;p&gt;Where:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;displacement depends on time&lt;/li&gt;
&lt;li&gt;velocity depends on displacement changing over time&lt;/li&gt;
&lt;li&gt;acceleration depends on velocity changing over time
### Displacement&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq3zckdg1z49cl1f4ioy3.png&quot; class=&quot;article-body-image-wrapper&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fq3zckdg1z49cl1f4ioy3.png&quot; alt=&quot;&quot; width=&quot;179&quot; height=&quot;80&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Velocity
&lt;/h3&gt;

&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2crtg6kycz956uwbfhxg.png&quot; class=&quot;article-body-image-wrapper&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2crtg6kycz956uwbfhxg.png&quot; alt=&quot;&quot; width=&quot;142&quot; height=&quot;68&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Acceleration
&lt;/h2&gt;

&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjw391x7s4qymlv163wt8.png&quot; class=&quot;article-body-image-wrapper&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjw391x7s4qymlv163wt8.png&quot; alt=&quot;&quot; width=&quot;185&quot; height=&quot;74&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Each graph is the derivative of the previous one.&lt;/p&gt;

&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqv11i94hrzocavf9gby7.png&quot; class=&quot;article-body-image-wrapper&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqv11i94hrzocavf9gby7.png&quot; alt=&quot;&quot; width=&quot;800&quot; height=&quot;960&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fp4ndow9i51dhl90cjv9q.png&quot; class=&quot;article-body-image-wrapper&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fp4ndow9i51dhl90cjv9q.png&quot; alt=&quot;&quot; width=&quot;800&quot; height=&quot;727&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Why chain rule is used?
&lt;/h2&gt;

&lt;p&gt;The chain rule is used in &lt;strong&gt;Machine Learning&lt;/strong&gt; during &lt;strong&gt;Backpropagation&lt;/strong&gt;, which is the process of training the network by adjusting its weights and biases to minimize errors.&lt;/p&gt;

&lt;p&gt;If you have two functions, &lt;code&gt;f(x)&lt;/code&gt; and &lt;code&gt;g(x)&lt;/code&gt;, and you want to find the derivative of their composition &lt;code&gt;f(g(x))&lt;/code&gt;, the chain rule states:&lt;/p&gt;

&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe3phf6mgdd3mfx734nf7.png&quot; class=&quot;article-body-image-wrapper&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe3phf6mgdd3mfx734nf7.png&quot; alt=&quot;&quot; width=&quot;253&quot; height=&quot;68&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://github.com/HexmosTech/git-lrc&quot; rel=&quot;noopener noreferrer nofollow&quot;&gt;&lt;img src=&quot;https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fabn6nl3iehrohehnxgje.png&quot; alt=&quot;git-lrc&quot; width=&quot;800&quot; height=&quot;373&quot;&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Any feedback or contributors are welcome! It&amp;rsquo;s online, source-available, and ready for anyone to use.&lt;/p&gt;

&lt;p&gt;&amp;#11088; &lt;a href=&quot;https://github.com/HexmosTech/git-lrc?utm_source=chatgpt.com&quot; rel=&quot;noopener noreferrer nofollow&quot;&gt;Star git-lrc on GitHub&lt;/a&gt;&lt;/p&gt;


</description>
<category>Other</category>
<guid isPermaLink="true">https://coderlegion.com/18988/understanding-chain-rule</guid>
<pubDate>Thu, 28 May 2026 13:45:57 +0000</pubDate>
</item>
</channel>
</rss>