Key concepts of DeFi. Decentralized Finance

Decentralized Finance, or DeFi for short, represents a system of financial products built on top of decentralized and open-source blockchains. As opposed to centralised finance there are no central authorities and financial institutions to facilitate transactions and financial access.
DeFi offers higher levels of financial access by offering the possibility of a suite of financial products built on permissionless (i.e. anyone is free to participate) blockchains. Financial products and services can be programmable on the blockchain and participants can interact with each other cutting out the middleman of financial institutions who traditionally provided the service of intermediation. In addition to providing alternative access to traditional financial products (borrowing, lending, saving, exchange, insurance, etc) it offers a platform for innovation and challenges for regulation. The field has recently seen phenomenal growth in the blockchain and cryptocurrency space and is increasingly being recognized as a potential disruptor to traditional centralized finance.
Stack of blue Legos
DeFi also offers the possibility of unique financial architecture to be added piecemeal as “money legos’’ to the financial ecosystem. The Ethereum blockchain (which most DeFi applications are built on) being open-source and permissionless means anyone can deploy transparent code and users can interact with each other through computer code without the need for intermediaries such as banks, brokers and lawyers, etc. The first Bitcoin blockchain was designed as a mechanism for transactions using digital money with the Bitcoin cryptocurrency. In contrast, the Ethereum blockchain was designed as a general-purpose blockchain.
Users on the Ethereum blockchain can interact through Smart Contracts which can be thought of as small computer programs that bind counterparties e.g. buyers and sellers through self-executing code on the blockchain. This allows decentralized applications (apps) to be uploaded and run with smart contracts autonomously with little to no human support needed.
Gas can be thought of settlement fee needed to be paid for transactions on the Ethereum blockchain. Gas is a unit that measures the computational effort required to perform a transaction on the network. The fees thus can vary depending on the nature of the transaction i.e. more complex transactions will require more gas fees and also depending on congestion on the Ethereum network (more gas fees are charged similar to an Uber peak hour surcharge).
A novel product that has seen increasing success is DEXs (decentralized exchanges) which allow users to trade and exchange cryptocurrency tokens by interacting through protocols coded as an algorithm that provides an automated market-making function. This means instead of buying an asset from a traditional exchange (e.g. buying a stock on the Australian Stock Exchange) which typically has a buy-and-sell mechanism called an order book, users interact through a DEX protocol. This is essentially an algorithm (again computer code!) that allows traders to transact 24/7. Not only can users trade or source liquidity from DEXs they can also seed this liquidity pool with their existing assets.
A liquidity pool is essentially a smart contract that contains funds of crypto assets. Any user is free to deposit their tokenized assets (assets converted into a smart contract) no matter how small in quantity into this pool and earn fees as a liquidity provider. In addition to fees, liquidity providers can also earn rewards from the underlying DeFi platform in other ways e.g. being rewarded interest for loaning or governance tokens of the protocol that itself has tradeable value.
Yield farming is the process of earning a financial return this way by engaging their crypto assets as a liquidity provider in liquidity pools. Thus DeFi offers a new way to earn money akin to yields, dividends, and yields from bonds, equities, and interest from bank deposits in traditional finance. Instead, the user with their idle Crypto assets can act like a bank charging interest on loans or lending out held assets.
Another key concept in DeFi is Flash Loans. This allows you to borrow from a smart contract pool without providing any collateral. The loan is only valid within the confines of one Ethereum transaction and paid back at the end of the transaction. When the transaction goes through the loan is paid back. If the repayer does not repay their debt the transaction is reversed and balances go back to their original states. This process ensures there is no counterparty risk for the lender. The main uses for flash loans are refinancing and arbitrage.