> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lora.finance/llms.txt
> Use this file to discover all available pages before exploring further.

# Mechanism Overview

At a high level, Lora Finance functions as a **marketplace between two sides**:

* On one side, we have **users who want upside exposure** to an asset *(let’s call them “renters” of upside)*. These users open positions in Lora to simulate holding more of an asset than they actually own, in exchange for paying a fee over time.
* On the other side, we have **liquidity providers (LPs)** who supply assets to a **vault** in the Lora protocol. These LPs are essentially making their assets available to back the exposure that renters seek, and in return they earn the fees that renters pay.

## How do these sides interact?

When a user opens a position for, say, 1 unit of Asset X’s upside, the protocol will ensure that the vault allocates 1 unit of Asset X to cover this position. The user starts paying a streaming fee *(denominated in a payment asset, e.g., a stablecoin or the asset itself depending on design)* that flows to the LPs. This fee is essentially the “rent” for using that 1 unit of Asset X’s worth of exposure.

Behind the scenes, **Lora’s smart contracts** dynamically adjust balances: the user’s position is credited with the chosen exposure amount, and the vault’s available liquidity is reduced by that amount *(since it’s now tied to the user’s position)*. The continuous fees from the user go into the vault or to the LPs, compensating them for the opportunity cost of letting the user capture the asset’s upside.

## Profit and Loss

**Profit and loss** for the position are determined by the asset’s price movement:

* If Asset X’s price increases while the position is open, the user’s position accumulates profit *(just as if they held Asset X directly)*. This profit will ultimately come out of the vault’s assets when the position is closed \*(transferred to the user)\*\*.

* If Asset X’s price decreases, the position accrues a loss. However, the user doesn’t face a liquidation. They can choose to keep the position open *(hoping for a recovery)* or close it to stop paying further fees. If they close at a loss, essentially they walk away having paid fees and with no profit *(similar to someone who bought the asset and saw it drop in value, then sold)*.

* In either case, the **streaming fees** ensure that LPs are compensated. If the user made a profit, the LPs effectively funded that profit via their asset’s appreciation, but they earned the rental fees in the meantime *(much like an insurance premium). If the user made a loss, the LPs keep the fees and also suffer the asset’s price drop on their side (similar to just holding the asset through a dip, but with extra fee income to offset it)*.

Crucially, because the user’s obligation is only to keep paying the streaming fee, there is never a sudden margin call. The position will only terminate when the user decides to close it or if the user’s streaming payments run out *(for example, if their payment balance is exhausted – in which case the protocol can automatically close the position safely)*. This design removes the timing risk for users; they aren’t forced out of their position at the worst possible moment by automated liquidation, a major differentiator from traditional leveraged trading.
