算法交易软件安全卫士

发布于 2024-09-02 10:19:03 字数 296 浏览 6 评论 0原文

我正在开发自动交易系统。我应该采取什么样的保障措施?

我的主要想法是让多个部分相互检查。

我将有第二个独立的小进程,它也将连接到同一个交易账户并监控简单的事情,例如确保总净头寸不超过一定限制,或者例如 10 分钟内不超过 N 个订单,或同时开立多于 M 个仓位。您还可以检查实际未平仓头寸是否与策略流程认为其实际持有的头寸相对应。作为奖励,我可以在不同的机器/网络提供商上运行此检查程序进程。

除了主要策略中的检查之外,这将确保无论发生什么奇怪的错误,都不会发生真正糟糕的情况。

我还应该监控和注意其他什么事情吗?

I'm working on an automatic trading system. What sorts of safe-guards should I have in place?

The main idea I have is to have multiple pieces checking each other.

I will have a second independent little process which will also connect to the same trading account and monitor simple things, like ensuring the total net position does not go over a certain limit, or that there are no more than N orders in 10 minutes for example, or more than M positions open simultaneously. You can also check that the actual open positions correspond to what the strategy process thinks it actually holds. As a bonus I could run this checker process on a different machine/network provider.

Besides the checks in the main strategy, this will ensure that whatever weird bug occurs, nothing really bad can happen.

Any other things I should monitor and be aware of?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

转身泪倾城 2024-09-09 10:19:03

许多算法交易系统都利用 ESP/CEP(事件流处理/复杂事件处理)系统,以便根据市场活动做出交易决策(跟踪 VWAP 就是典型的例子)。

但也许您可以根据算法的活动创建一个流,然后让 ESP/CEP 系统使用该流来充当算法活动的看门狗;如果算法在滚动的 10 分钟窗口内开始交易过多,它可能会向您的中间件发送消息以关闭 FIX 连接等。监控您正在交易的主要指数以查看市场是否正在经历一个特别不稳定的时刻……在波动性相对较低的时期交易良好的算法在市场开始崩溃时可能会迅速失控。

Esper 是一个针对 Java 和 .Net 的开源 ESP 系统,值得一试。

Alot of algorithmic trading systems make use of ESP/CEP (Event-stream processing/complex event processing) systems in order to make trading decision on the basis of market activity (tracking VWAP being the canonical example).

But perhaps you could create a stream from the algorithm's activity, and then have an ESP/CEP system use this stream to act as a watchdog over the algo's activity; if the algo starts trading too much within a rolling 10-minute window, it could send a message to your middleware to shutdown the FIX connection, etc. It would also be wise to monitor major indexes that you are trading against to see if the market is going through a particularly volatile moment... algos that trade well during periods of relative low volatility can quickly run amok when a market starts to crash.

Esper is an open-source ESP system for Java and .Net that is worth checking out.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文