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

# Guide: Market Making Expert Agent

> Start the Market Making Expert's PMM Mister Operator loop on a perpetual pair, watch it, and stop it safely

The **Market Making Expert** quotes both sides of a perpetual futures market and earns the spread. It doesn't place orders itself. Each tick it reads the market, picks settings for the `pmm_mister` controller, and deploys or retunes a Hummingbot bot that runs that controller.

This guide runs its **PMM Mister Operator** loop on one pair you choose.

![The Market Making Expert's agent page with the PMM Mister Operator loop selected](https://mintcdn.com/hummingbot/y3c_8rOvqXwf-tXJ/images/webui/agent-page.jpg?fit=max\&auto=format\&n=y3c_8rOvqXwf-tXJ\&q=85\&s=268f383b3f84e8141378834f1fc5350e)

## What you need

**1. Condor connected to a Hummingbot API server**

Follow [Installing](/getting-started/installing.md). In the Workspace the server selector in the top bar shows a green dot when the server is reachable.

**2. Exchange keys for a perpetual account**

Add them in **Settings → Keys and Wallets → Add API Key**, and start with a small balance. See [Exchange Credentials](/getting-started/credentials.md). The Workspace doesn't list testnet connectors such as `binance_perpetual_testnet`; those can only be added through the Hummingbot API directly.

**3. A model the agent can run on**

The agent's model is shown next to its name on the agent page; click it to change it. See [LLM Integration](/llm-integration.md).

The loop deploys the `pmm_mister` controller, which ships with the agent. If it isn't on your server yet, the agent uploads it on its first tick. The agent page's **Controllers** tab shows whether the server's copy matches.

> [!NOTE]
>
> `pmm_mister` quotes in **one-way** position mode. If the bot's logs show a "Position mode mismatch" warning, switch the account to one-way mode on the exchange.

## How the loop works

Every **120 seconds** by default, the agent:

1. **Reads the market.** It runs two routines: `market_analyzer` classifies the regime (trending, ranging or volatile) from 5m, 15m and 4h candles, and `mm_dashboard` reports inventory, the bot's position and its PnL.
2. **Decides.** It chooses one of **DEPLOY**, **UPDATE**, **HOLD** or **STOP**, and picks spreads, inventory band and take-profit for the regime.
3. **Acts.** It writes a `pmm_mister` config and deploys a bot named after the base asset (for example `SOL-mm`), or updates the running bot's config.

Every bot deploy must declare a loss cap (`max_global_drawdown_quote`). The bot stops itself when its losses reach it. The [risk gate](/trading-agents/architecture.md#risk-engine) refuses deploys without one.

## Start the loop

**1. Open the agent**

Open `/agents/market_making_expert` in the Workspace. From the chat, you can also open the **Agent** panel for Market Making Expert and click **Workspace**.

**2. Pick the loop**

In the loop selector under the agent's name, choose **PMM Mister Operator**.

> [!WARNING]
>
> Always pick a loop before starting. If the agent is started without one (for example "start your loop" in chat), Condor creates a generic **Default** loop that doesn't use either of the shipped playbooks.

**3. Click Start and fill in the dialog**

![The Start New Session dialog with Loop mode selected](https://mintcdn.com/hummingbot/8B2XYe2UIw7EgwpA/images/webui/agent-start-dialog.jpg?fit=max\&auto=format\&n=8B2XYe2UIw7EgwpA\&q=85\&s=ae09ed87a7bdd107b97754fe17ba51e9)

| Field | What to enter |
| - | - |
| **Execution Mode** | Start with **Dry Run** (see the next step) |
| **Trading Context** | The pair and exchange, in plain words. For example `Do MM on SOL-USDT on binance_perpetual`. The dialog has no separate pair or exchange field; the loop reads them from here. |
| **Server** | Your Hummingbot API server |
| **Total Amount Quote** | Capital for the bot, in the quote asset. Start small, for example `100`. |
| **Frequency (sec)** | Seconds between ticks. The default `120` is fine. |
| **Max Position (\$)** | The most exposure the session may hold. The loop also uses this as the bot's loss cap. |
| **Max Executors** | Leave at `10` |
| **Max Drawdown %** | Pauses the loop at this drawdown. `-1` turns it off. |

> [!WARNING]
>
> **Set Max Position no higher than the loss you would accept.** The loop passes Max Position to the bot as its loss cap, and the default (600) is larger than the default capital (500). Setting **Total Amount Quote** and **Max Position** to the same small number, such as `100`, keeps both bounded.

**4. Do a Dry Run**

Choose **Dry Run** and click **Run Dry Test**. The agent runs one tick in which every action is refused, then stops. Open the **Runs** tab to read its decision.

![The Runs tab showing a dry run's regime read and the deploy it would make](https://mintcdn.com/hummingbot/y3c_8rOvqXwf-tXJ/images/webui/agent-runs.jpg?fit=max\&auto=format\&n=y3c_8rOvqXwf-tXJ\&q=85\&s=9f97816b98dc8707610d44771f672ae6)

> [!NOTE]
>
> A dry run also refuses routines, so `market_analyzer` and `mm_dashboard` don't run. The agent improvises a market read with other tools. Use the dry run to check that the agent, server and exchange are wired up, not to judge the strategy.

**5. Run Once, then Loop**

**Run Once** runs a single live tick. It can deploy a real bot, so use small capital. When that tick looks right, start again with **Loop**.

Tick **Resume after Condor restarts** if the loop should start again automatically after Condor restarts. It starts a fresh session; it doesn't resume the old one.

## Watch it run

The agent page has four tabs:

| Tab | What it shows |
| - | - |
| **Now** | The last decision and what the session has deployed |
| **Runs** | Every session and dry run, with each tick's prompt, tool calls and response |
| **Fleet** | The bots and executors this session owns |
| **Playbook** | The loop's `loop.md` and its learnings. You can edit both here. |

Tick errors, risk-limit blocks and shutdown alerts appear in the notification bell, and in Telegram if you use it. Actions the risk gate refused are recorded in the session journal under **Runs**. The bot itself appears on the [Bots](/webui/bots.md) page.

## Stop it

> [!WARNING]
>
> **Stop** ends the loop but leaves the bot running and trading. Nothing manages it until you start this loop again, when the next session adopts the bot. To stop trading, also stop the bot: on the **Bots** page, open the bot and stop it.

| You want to | Do this |
| - | - |
| Pause decisions but keep everything running | **Pause** on the agent page; **Resume** to continue |
| End the loop and stop the bot | **Stop** on the agent page, then stop the bot on the **Bots** page |
| Wind everything down now | Ask the agent in chat to shut its loop down. Then check the **Bots** page and stop the bot if it is still running. |

## Settings the agent tunes

These are the main `pmm_mister` fields the agent sets on each deploy or update. You can ask the agent to use specific values, or edit the loop's instructions in the **Playbook** tab.

| Field | Default | Meaning |
| - | - | - |
| `portfolio_allocation` | 0.1 | Share of the bot's capital quoted per cycle, across all levels |
| `target_base_pct` / `min_base_pct` / `max_base_pct` | 0.5 / 0.3 / 0.7 | Inventory band: the share of capital to hold in the base asset |
| `buy_spreads` / `sell_spreads` | 0.0005 | Distance of each quote level from the mid price (0.0005 = 0.05%) |
| `take_profit` | 0.0001 | Profit target per filled order. Must exceed twice the maker fee. |
| `executor_refresh_time` | 30 | Longest an unfilled quote stays up before it is replaced, in seconds |
| `buy_cooldown_time` / `sell_cooldown_time` | 60 | Seconds since the last order on a level before a new order is placed there |
| `leverage` | 20 | Account leverage for the pair |
| `max_active_executors_by_level` | 4 | Cap on open and filled-but-held orders per level |
| `min_skew` | 1.0 | Floor on order-size skew. Values below 1 shrink the overweight side; values above 1 enlarge **every** order. |
| `global_stop_loss` / `global_sl_enabled` | 0.05 / off | Unrealized loss (0.05 = 5%) at which the position is closed, when enabled |

> [!WARNING]
>
> The agent's config playbook suggests `min_skew` values of 1.5 and 2.0 for its balanced and conservative profiles. In `pmm_mister` those values multiply every order by 1.5× or 2×. If you see them in a proposed config, ask the agent to use a value of 1.0 or lower.

> **Variant: HIP-3 MM Operator (Hyperliquid)**
>
> The agent's second loop, **HIP-3 MM Operator**, farms volume on Hyperliquid's HIP-3 perpetuals issued by `xyz`. It picks its own market each time it reselects, so you don't name a pair in the Trading Context.
>
> * It needs a `hyperliquid_perpetual` account. In **Settings → Keys and Wallets**, click **Add API Key** and choose **Connect Hyperliquid**.
> * It ticks every 300 seconds and reselects the market every 30 ticks.
> * HIP-3 pairs use an uppercase issuer prefix, for example `XYZ:SPCX-USD`.

## From Telegram

Telegram has no Start button for loops. Ask the agent instead:

1. Send `/agent`, tap **Talk to** and choose **Market Making Expert**.
2. Ask it to start its loop, naming the loop, pair and capital. For example: *"Start the pmm\_mister\_operator loop for SOL-USDT on binance\_perpetual with 100 USDT."*
3. Approve the confirmation Condor shows before the loop starts.

To stop the loop, ask the agent to stop it. `/stop` only cancels the reply the agent is writing; it doesn't stop a running loop.

## Learn more

* [Architecture](/trading-agents/architecture.md): how loops, sessions and the risk engine work
* [Guide: Solana DEX LP Expert Agent](/examples/solana-lp.md): the same workflow for DEX liquidity
* [Bots](/webui/bots.md): watching and stopping the deployed bot


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.