# The Protocol - AMM V3

MorFi implements [Algebra Integral](https://algebra.finance/) to enable a seamless integration of custom plugins, reduce gas costs, and provide a powerful solution to address the evolving needs of Morph’s DeFi ecosystem.

Algebra Integral is an innovative Concentrated Liquidity Automated Market Maker (AMM) that introduces a modular architecture to enhance the performance and flexibility of MorFi.

<figure><img src="/files/GpbVUBHWco4l9MSPzdcC" alt=""><figcaption><p>MorFi DEX Architecture Overview</p></figcaption></figure>

#### **Key Features of Algebra Integral**

1. **Modular Architecture** Algebra Integral's modular design allows MorFi to easily integrate, remove, or update plugins without requiring liquidity migration. This capability reduces operational disruptions and minimizes gas costs, ultimately providing a better user experience.
2. **Customizable Plugins** This modular approach supports a wide range of plugins, such as:
   * **Dynamic Fee Plugin:** Automatically adjusts fees based on market volatility, optimizing earnings for liquidity providers
   * **On-chain Farming Plugin:** Enables farming directly within MorFi, enhancing profit opportunities without relying on external platforms
   * **Limit Orders Plugin:** Facilitates limit orders that execute automatically when specified price conditions are met, providing users flexibility in their trading logic
   * **Oracles for TWAP and Volatility:** Provides tools for accessing historical data and calculating daily price volatility to support advanced trading strategies
3. **Single Pool per Pair Architecture:** Ensuring that each token pair has a single liquidity pool minimizes liquidity fragmentation, making it easier to find optimal swap routes and improving capital efficiency across MorFi.
4. **Security and Flexibility:** By moving secondary functionalities into plugins, Algebra Integral keeps the core of the protocol lightweight, enhancing its security and simplifying the audit process.

#### MorFi’s Edge

As a result, MorFi offers the following advantages:

* **Gas Cost Savings:** Improved gas efficiency by 7-22%, on average, compared to traditional models
* **Concentrated Liquidity**: Liquidity providers can concentrate their capital within specific price ranges, leading to increased liquidity at preferred prices
* **Enhanced Functionality:** Easy integration of new features and plugins to adapt to market conditions without major infrastructure changes
* **Greater Security:** A more secure trading environment that protects user assets while allowing for continuous development and updates

By leveraging the latest AMM architecture, MorFi offers a superior trading experience that is both user-friendly and flexible to changing market demands.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.morfi.io/morfi/the-protocol-amm-v3.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
