atkinson / wagmi

An execution framework for systematic strategies
BSD 2-Clause "Simplified" License
10 stars 12 forks source link

Draft behavior of order execution logic #15

Closed arnaudj closed 2 years ago

arnaudj commented 2 years ago

Should we draft a spec with the overall behavior we want to implement? Then translate that into actual code handled by the right module.

This could take the form of a github gist (with python pseudo code, e.g), or a google doc, or other

No strong idea on the format. I find this kind of doc interesting: https://docs.hummingbot.io/strategies/twap note the activity diagram that helps build a finite state machine (pseudo code can be enough) that could be tick-ed from a task queue, eg.

This could be the opportunity to clarify behavior (eg: are we supposed to have open orders overnight? what do we do with open orders intraday: what is the trigger for us to decide to replace their price? Should a TargetPositionRequest be considered constant during a day? etc)

CharlesFr commented 2 years ago

I made a quick diagram of the execution logic, I hope this helps.

image

A few notes:

arnaudj commented 2 years ago

Drafted in a google doc, open for comment.

I'm considering closing this issue, unless somebody is actively working on this