**Introduction** The execution of an order with a relatively large size is always a nontrivial task. Generally speaking, itcan be done in two ways: sweep the market and get the order done at time zero; or split the order in small pieces and unwind the position in a prolonged time frame. The fast execution can achieve the execution with the smallest risk butwill inevitably create extensive market impact that leads to poor execution performance. Although FX market is highly fragmented, it is running as an ecosystem. The extensive market impact caused in one venue is spreading to the whole ecosystem with an ignorable delay. The slower execution avoids extensive market impact at the cost of increased uncertainty about the execution price. Liquidity seeking algorithm is trying to balance the risk and cost in an optimized fashion.

**Methodology** Depending on a trader’s goal, this algorithm can be set up in two different manners: minimize the execution cost while satisfying the risk constraint; or minimize the risk while satisfying the cost constraint. In the following, we will discuss the first approach. Then understanding the second approach becomes straightforward The primary task of this algo is to find the optimal execution trajectory, namely size to execute along the time. If the time horizon is discretized into n slices, an execution trajectory is essentially a vector of order size on each time slice, X = (x1, x2, … xn-1, xn). Then it can be formulated as the following optimization problem min XT CX, XT RX ≤ RiskConstraint.

where C is the cost matrix and R is the risk matrix. This is a quadratic optimization with quadratic constraint.

The risk constraint is usually specified at the beginning of the trading and theabove formulation is well justified for initial optimization. As the execution progresses, the realized execution may deviate from the initial optimal trajectory. The market condition as well as the trader’s risk tolerance can also change. Therefore, it is necessary to re-optimize the execution trajectory. To treat the trader’s risk tolerance in a self-consistent fashion, we do the following optimization

min XT CX+ λXT RX

where λ is the risk aversion coefficient,also the dual-valueof the initial optimization (1)

Market Impact Model

In (1) and (2), the cost matrix C determines the execution cost created by the executiontrajectory X. Of all cost components, market impact isthe dominant one.

Traditionally, people use proprietary internal trade records that accumulated over long history to derive the market impact model. There are two major drawbacks of this approach: the results are very noisy,