Skip to main content

A fast limit order book in Python utilizing a Rust backend

Project description

litebook

litebook Downloads Build MIT License

A fast and performant limit order book in Python utilizing a Rust backend. Install it with

pip install litebook

Using litebook

Get started with litebook using the following example:

import litebook as lb

# Create an OrderBook
orderbook = lb.OrderBook(tick_size=0.01)

# Create some orders (this not _add_ the order!)
buy_order = book.create_order(lb.OrderType.Buy, price=10.05, quantity=10.0)
sell_order = book.create_order(lb.OrderType.Sell, price=10.05, quantity=5.0)

# Add the orders (this returns a list of Fill objects)
_no_fills = book.add(buy_order)
fills = book.add(sell_order)

# Check the fill
print(fill)

# Check the status of the remainder of the open buy order
# DO NOT rely on the previous `buy_order` or `sell_order` objects
# to be updated! Fetch them from the book, instead
open_buy_order = orderbook.get_order(buy_order.id)

Need help?

Please open an issue if you need help or have a feature request.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

litebook-0.0.1-cp313-cp313-win_amd64.whl (182.4 kB view details)

Uploaded CPython 3.13Windows x86-64

litebook-0.0.1-cp313-cp313-win32.whl (172.3 kB view details)

Uploaded CPython 3.13Windows x86

litebook-0.0.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (328.0 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

litebook-0.0.1-cp313-cp313-macosx_11_0_arm64.whl (286.3 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

litebook-0.0.1-cp313-cp313-macosx_10_12_x86_64.whl (293.0 kB view details)

Uploaded CPython 3.13macOS 10.12+ x86-64

litebook-0.0.1-cp312-cp312-win_amd64.whl (182.0 kB view details)

Uploaded CPython 3.12Windows x86-64

litebook-0.0.1-cp312-cp312-win32.whl (172.3 kB view details)

Uploaded CPython 3.12Windows x86

litebook-0.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (327.6 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

litebook-0.0.1-cp312-cp312-macosx_11_0_arm64.whl (286.4 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

litebook-0.0.1-cp312-cp312-macosx_10_12_x86_64.whl (293.5 kB view details)

Uploaded CPython 3.12macOS 10.12+ x86-64

litebook-0.0.1-cp311-cp311-win_amd64.whl (181.3 kB view details)

Uploaded CPython 3.11Windows x86-64

litebook-0.0.1-cp311-cp311-win32.whl (172.0 kB view details)

Uploaded CPython 3.11Windows x86

litebook-0.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (327.6 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

litebook-0.0.1-cp311-cp311-macosx_11_0_arm64.whl (290.5 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

litebook-0.0.1-cp311-cp311-macosx_10_12_x86_64.whl (298.6 kB view details)

Uploaded CPython 3.11macOS 10.12+ x86-64

litebook-0.0.1-cp310-cp310-win_amd64.whl (181.2 kB view details)

Uploaded CPython 3.10Windows x86-64

litebook-0.0.1-cp310-cp310-win32.whl (171.9 kB view details)

Uploaded CPython 3.10Windows x86

litebook-0.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (327.8 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

litebook-0.0.1-cp310-cp310-macosx_11_0_arm64.whl (290.7 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

litebook-0.0.1-cp310-cp310-macosx_10_12_x86_64.whl (298.6 kB view details)

Uploaded CPython 3.10macOS 10.12+ x86-64

File details

Details for the file litebook-0.0.1-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 568f08c11bf9bdec00ead2485d5a61752a67a1ea15a937667924cb0a9bf7b5d2
MD5 ffa600cca02f84c8d257746875aa6736
BLAKE2b-256 48499d1a4b2b2e56740300e4e4ffefb92a94af57689df0857e466ab8e48c69aa

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp313-cp313-win32.whl.

File metadata

  • Download URL: litebook-0.0.1-cp313-cp313-win32.whl
  • Upload date:
  • Size: 172.3 kB
  • Tags: CPython 3.13, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.8.1

File hashes

Hashes for litebook-0.0.1-cp313-cp313-win32.whl
Algorithm Hash digest
SHA256 c5627d0e69f9d95d20a03b61af3da2396c4c4546e2201cbaa34c786fd5438b1e
MD5 8a064f05de5d141b2e90d3e91f63af0e
BLAKE2b-256 afa7a404cd73c6fe5977016c84abd507a6b31d80bae7abf178776c2445fca925

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c9266761e86a908b5e96b234a938e1b46becc8a096bf86513225d3a1b6a61e22
MD5 d971878109a3f8d8a7291d6921b0ff51
BLAKE2b-256 824ddbff9bdd9045063769944d80c9cce77ee8ce02d376654f2ab98c824b6c08

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f59142833a8ec818bcc2ffe6d6136c0c71cbb0c7e7503207a67ca9985a5f9fef
MD5 f726b507f8a80215828687d802457a55
BLAKE2b-256 af877793340d4df9a56ab9f41a18d887199b8da28ea62c51d65061db10933d9b

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp313-cp313-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp313-cp313-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 7cc8b3aab66cffa5ea8b0b857ce265496e770ac3b71037bb0d900dffa4e050b6
MD5 8fcb1e6991c4cc01d4c3c34774b80cb4
BLAKE2b-256 db0525f0e5ed152fd8d2885540486953f759b0a11373ecfabfb096ee9f4c065b

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 6ce0e274d6fcb9668c6ce99e1e1c168f3976072a675140d6d6a5842c1b90b76e
MD5 db364a9f05dec3791840643b57b58b7c
BLAKE2b-256 b8a88553f3c780f2c293a442c7d2732e5075beaae80b0640b09dee4fe8d90620

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp312-cp312-win32.whl.

File metadata

  • Download URL: litebook-0.0.1-cp312-cp312-win32.whl
  • Upload date:
  • Size: 172.3 kB
  • Tags: CPython 3.12, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.8.1

File hashes

Hashes for litebook-0.0.1-cp312-cp312-win32.whl
Algorithm Hash digest
SHA256 d0d57296fc487183760a426b7ed362db89c595149c5f51412a21985ac7460445
MD5 a044c7d5189cf93ee0ce222a31fa211f
BLAKE2b-256 df79c1ac80bccdee93ab496bdb4fd0fa5ea86fa0cebef79031b8f6342a954bc0

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 0feb212f2dffda81c08302e0781fc91c2c3aeb78c6de1d42ebb14e7b9cef260c
MD5 b579620525a716106b8010296b70f0fa
BLAKE2b-256 a5582afc0bdbec837ede73d1e4ff0905a6ab57920019c4643b5804821b593cc7

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 7447b15a208b75caa42e5d43735e2f7bed058c92f23aa5d1709b8cf531dfca41
MD5 47105a215cecb17f38b1a12f12390b0c
BLAKE2b-256 f3eec809c1ae0a0d446146f7a79c49d6939440f9a3f1e86a51f1a287d22b2ad5

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp312-cp312-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp312-cp312-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 eb172bd0cfa18ed56bde5166a94ef1c0ad9e0b7fb171e15e4d3faac4894d09a2
MD5 231d957470c4bbfb72fa624f26b15648
BLAKE2b-256 bfa5adb86e2ff0fb9cc1e472ce92b4ee9863a73c22c71439e26a8a2961885784

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 0d5f8674212e08abc3eeb65dc85d262214a17d7bf4887be1cc1f190eeabf49fa
MD5 2bf8793eb19157380e66574c752db27f
BLAKE2b-256 488629d0f21b40f2eb5d9054451536cbe4bd2a4ea96fe098ef62ac0e9da44dc2

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp311-cp311-win32.whl.

File metadata

  • Download URL: litebook-0.0.1-cp311-cp311-win32.whl
  • Upload date:
  • Size: 172.0 kB
  • Tags: CPython 3.11, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.8.1

File hashes

Hashes for litebook-0.0.1-cp311-cp311-win32.whl
Algorithm Hash digest
SHA256 91b3ac5b2db68f4babc54c4457bc9ddb8390e2a35ed1c77bf60fa67a284c02e7
MD5 f0d5f5cf72b2f6ccf921434d16c0eb04
BLAKE2b-256 8e951cccaf4b18951c167d95dc873390995b3dbd03e0fbce3c41ae6063191a12

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 6e1a06b3e970f2e39f0b5c32c7cd0fa31c0760bfb25ace8c868616a3a3a46fd8
MD5 1ee006b5d04973b8066b951239bbd071
BLAKE2b-256 d57724a61a89d4d3f80557758c9411c191d84eadb462c316cf1e4544d9917321

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 189fcd8c464ab8c3b50b67c53778272023eb36423e9fcae6d9eeb3fccfe6c637
MD5 1485571b430b61cab602b12fd15db57d
BLAKE2b-256 4877b3707b5c0b124e1ef987c620005dafd8e379967cf6bfb216378052aef927

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp311-cp311-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp311-cp311-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 58619957f0fc490b3a6d34c41135c2bc6e5d5daaba89f523c3036af23a12e4c6
MD5 153839ead64bfc45885ff5a7069312f4
BLAKE2b-256 ab9442c7d659286d963211e178fcfc01bb54101887647774b6681dd82c1d178a

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 b2710b97b9b5fb9a33fd27a541614b865789851da3726659d26e4d8d54c781fa
MD5 1cc4e45573d88d223eaa88f9d76c581c
BLAKE2b-256 a59a15746ff63135a172b43e279e6f6de0d58dc38ea5ea0218de945b81f7a9df

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp310-cp310-win32.whl.

File metadata

  • Download URL: litebook-0.0.1-cp310-cp310-win32.whl
  • Upload date:
  • Size: 171.9 kB
  • Tags: CPython 3.10, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.8.1

File hashes

Hashes for litebook-0.0.1-cp310-cp310-win32.whl
Algorithm Hash digest
SHA256 53e27839ff50b8a6e59a06cda983fe177a1134f1832634e7301c96322cb174c4
MD5 40edf71f9403702528851f3e211edba7
BLAKE2b-256 1411cd2de5b7eed64871518d4aadc46a86c5dcf2b654260e680f1e318c9961aa

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 f720d1aeb1cdc750e412363987f5040c148472c1dd1803b3b029265a2b82c06e
MD5 db0b06f664bbb3dd0b2aad28e70b2ec2
BLAKE2b-256 7295c3d7871d33968632493ac8f02f09d8a82c9886794577c5f7c6783a2a2d1b

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 7de9dc7d1cc863248488b2ed538a57c9eeb3bc06067889a7a13b01339cea4f99
MD5 c3f30adfa735a45e4ab1d67c4a578463
BLAKE2b-256 b70538cc78c9c9ee6a2342e8fd2af3b00c68d8120c70de9938f070e5623194f5

See more details on using hashes here.

File details

Details for the file litebook-0.0.1-cp310-cp310-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for litebook-0.0.1-cp310-cp310-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 c309ee2360a30802573ad170c7736de512ae85af0cbeef5f6818eb7ac2286e7a
MD5 119c623ed1df8c0aa5efbbb6dc01a0a6
BLAKE2b-256 a720d894bd2bb34b20aa6c58a7eda45050f6d17837a1fe52b7f4a61204514910

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page