# Implementation

With the initial release, TheTrade will offer leverage up to x5 for both Long and Short positions. TheTrade uses its own liquidity pools, enabling leveraging on various asset pairs. Leverage will be available for main currencies from the start. Later on, and especially after the launch of DAO, TheTrade platform will allow the listing of any token if there is enough liquidity. Higher leverage options, up to x100, will be added as well.

TheTrade achieves decentralized margin trading by using its own liquidity pools and limit order mechanics. For leveraged order creation, TheTrade contracts borrow the liquidity from TheTrade liquidity pool and swap the assets on the market. This process allows users to profit from lesser deposits but increases the risks. Both long and short positions can get liquidated by any participant of trading platform. Any TheTrade user can take on the role of Liquidator and receive a commission for helping the protocol uphold precise timings on all leveraged positions.

Executor ensures the correct marginal limit order process performance and gets execution fee for withdrawing the liquidity and transferring it to a user. Thus, Executor takes participates in the transferring part of both the creation and closing of marginal limit orders.

For instance, opening x5 Long position requires TheTrade platform to borrow four times the deposit amount from the liquidity pool to swap the provided token to the desired one. Traders can close the position anytime to take a profit or fix losses. If the price goes down and there is no deposit coverage (i.e., approximately -18%), trading platform opens the possibility of liquidating the position. Now, any Ethereum account can call the liquidation. TheTrade platform checks the liquidation conditions and swaps the desired asset for the borrowed one. After the swap, the smart contract repays a borrowed amount, withholds liquidator and protocol fees, and returns the remaining amount to the trader.


---

# 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://thetrade.gitbook.io/thetrade/features/margin-trading/use-cases/implementation.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.
