Compare commits

...

10 Commits

Author SHA1 Message Date
Cryptoval Trading Technologies
8f77238d82 progress 2024-11-01 18:59:46 +00:00
Cryptoval Trading Technologies
64536e2955 hosts added 2024-10-30 19:22:32 +00:00
Cryptoval Trading Technologies
d468bdfd79 moving redis to comm 2024-10-26 00:18:37 +00:00
Cryptoval Trading Technologies
641b083a49 progress 2024-10-25 21:07:31 +00:00
Cryptoval Trading Technologies
f512abe271 progress with mkt simulator 2024-10-15 23:37:40 +00:00
Cryptoval Trading Technologies
b693b57778 progress 2024-10-11 22:18:06 +00:00
Cryptoval Trading Technologies
4bc2ee411a progress 2024-10-06 16:08:06 +00:00
Cryptoval Trading Technologies
16228e7f0d fix 2024-10-03 15:11:34 +00:00
Cryptoval Trading Technologies
e5448f2ab4 progress 2024-09-11 01:28:31 +00:00
Cryptoval Trading Technologies
0e726530ee run_trading_calendar 2024-09-11 02:10:06 +01:00
40 changed files with 656 additions and 162 deletions

View File

@ -76,6 +76,7 @@
"supervisor": false,
},
"dtvmhost": {
"to_check": "yes",
"type": "metal",
"users": ["oleg"],
"docker": false,
@ -89,25 +90,44 @@
},
// ----------- V i r t u a l M a c h i n e s
"cvttdata": {
"type": "vm",
"users": ["oleg", "cvtt"],
"docker": true,
"supervisor": false,
},
"cvtt-dev": {
"cvtt-admin": {
"type": "vm",
"users": ["oleg"],
"docker": true,
"supervisor": false,
"__eod__": null
},
"cvtt-build": {
"type": "vm",
"users": ["oleg"],
"docker": true,
"supervisor": false,
"__eod__": null
},
"cvtt-dev": {
"type": "vm",
"users": ["oleg"],
"docker": true,
"supervisor": false,
},
"cvtt-edu": {
"type": "vm",
"users": ["oleg"],
"docker": false,
"supervisor": false,
},
"cvtt-md": {
"type": "vm",
"users": ["oleg", "cvtt"],
"docker": true,
"supervisor": false,
},
"cvtt-prod-03": {
"type": "vm",
"users": ["oleg"],
"docker": false,
"supervisor": true,
},
"cvtt-prod-eqty-01": {
"type": "vm",
"users": ["oleg", "cvtt"],
@ -120,6 +140,24 @@
"docker": true,
"supervisor": false,
},
"cvtt-testserver": {
"type": "vm",
"users": ["oleg", "cvtt"],
"docker": true,
"supervisor": false,
},
"cvttdata": {
"type": "vm",
"users": ["oleg", "cvtt"],
"docker": true,
"supervisor": false,
},
"cvttdata-testdb": {
"type": "vm",
"users": ["oleg", "cvtt"],
"docker": true,
"supervisor": false,
},
"desktop": {
"type": "vm",
"users": ["oleg"],
@ -132,30 +170,6 @@
"docker": true,
"supervisor": false,
},
"cvtt-md": {
"type": "vm",
"users": ["oleg", "cvtt"],
"docker": true,
"supervisor": false,
},
"cvttdata-testdb": {
"type": "vm",
"users": ["oleg", "cvtt"],
"docker": true,
"supervisor": false,
},
"cvtt-testserver": {
"type": "vm",
"users": ["oleg", "cvtt"],
"docker": true,
"supervisor": false,
},
"cvtt-prod-03": {
"type": "vm",
"users": ["oleg"],
"docker": false,
"supervisor": true,
},
},
"cryptovaltrading.com": {
@ -163,6 +177,7 @@
"users": ["oleg"],
"type": "cloud",
"ssh_port": 7822,
# "to_check": "No"
},
},
}

View File

@ -0,0 +1,80 @@
{
"WIKI": {
"to_check": "Yes",
"protocol": "http",
"host": "cloud11.cvtt.vpn",
"port": 8080
},
"Mattermost": {
"to_check": "Yes",
"protocol": "https",
"host": "mattermost.cryptovaltrading.com",
"port": 443
},
"Gitea": {
"to_check": "Yes",
"protocol": "http",
"host": "homestore.cvtt.vpn",
"port": 3000
},
"Docker Registry": {
"to_check": "Yes",
"protocol": "http",
"host": "cloud21.cvtt.vpn",
"port": 5500
},
"CVTT Config Service": {
"to_check": "Yes",
"protocol": "http",
"host": "cloud23.cvtt.vpn",
"port": 6789
},
"Trading Calendar": {
"to_check": "Yes",
"protocol": "http",
"host": "cloud23.cvtt.vpn",
"port": 8000
},
"US EQTY Rel.Liquidity": {
"to_check": "Yes",
"protocol": "http",
"host": "cloud23.cvtt.vpn",
"port": 5678
},
"PyTorch (Jupyter)": {
"to_check": "Yes",
"protocol": "http",
"host": "gpushnik.cvtt.vpn",
"port": 8888
},
"TensorFlow (Jupyter)": {
"to_check": "Yes",
"protocol": "http",
"host": "gpushnik.cvtt.vpn",
"port": 9999
},
"FastAI (Jupyter)": {
"to_check": "Yes",
"protocol": "http",
"host": "gpushnik.cvtt.vpn",
"port": 7777
},
"Jenkins": {
"to_check": "Yes",
"protocol": "http",
"host": "cvtt-build.cvtt.vpn",
"port": 8080
},
"NetBird": {
"to_check": "Yes",
"protocol": "http",
"host": "cloud18.cryptovaltrading.com",
"port": 80
},
"Proxmox Testing": {
"to_check": "No",
"protocol": "http",
"host": "proxmox.sheynin.home",
"port": 80
},
}

View File

@ -0,0 +1,7 @@
{
"Alpaca HBAR Loader": {
"image_name": "alpaca_hbar",
"docker_dev": "market_data/alpaca_hbar",
"based_on_dist": "cvtt-rust"
}
}

View File

@ -1,11 +1,11 @@
{
"type": "redis",
"redis_settings": "localhost"
"comm_settings": "/comm/pubsub/redis/localhost"
, "app_channels": {
"executor": "EXEC"
, "risk_manager": "RMGR"
, "risk_manager": "RMGR"
, "trader": "TRDR"
, "quant": "QUANT"
, "quant": "QUANT"
}
}

View File

@ -1,7 +1,7 @@
@var CONFIG_SERVICE=cloud23.cvtt.vpn:6789
{
"refdata": @inc=http://cloud11.cvtt.vpn:6789/refdata/refdata
, "redis": @inc=http://cloud11.cvtt.vpn:6789/apps/common/redis
, "cvttcomm": @inc=http://cloud11.cvtt.vpn:6789/apps/cvttcomm
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "exchanges_settings": {
"COINBASE_AT": {
"order_entry": {

View File

@ -2,8 +2,7 @@
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "cvttcomm": @inc=http://${CONFIG_SERVICE}/apps/cvttcomm
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "quant": {
"books": {
"CVTT_BK01": {}

View File

@ -1,9 +1,7 @@
@var CONFIG_SERVICE=cloud23.cvtt.vpn:6789
{
"refdata": @inc=http://cloud11.cvtt.vpn:6789/refdata/refdata
, "cvttcomm": @inc=http://cloud11.cvtt.vpn:6789/apps/cvttcomm
, "redis": @inc=http://cloud11.cvtt.vpn:6789/apps/common/redis
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "risk_manager": {
"book": "CVTT_BK01"
, "database": {

View File

@ -1,7 +1,7 @@
@var CONFIG_SERVICE=cloud23.cvtt.vpn:6789
{
"refdata": @inc=http://cloud11.cvtt.vpn:6789/refdata/refdata
, "cvttcomm": @inc=http://cloud11.cvtt.vpn:6789/apps/cvttcomm
, "redis": @inc=http://cloud11.cvtt.vpn:6789/apps/common/redis
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "exchanges_settings": {
"COINBASE_AT": {
"mkt_data": {

View File

@ -3,7 +3,7 @@
"dynamic_stock_list": {
"exchange_id": "ALPACA"
, "list_source": "redis"
, "redis_settings": "cvtt-prod-eqty-01"
, "comm_settings": "/comm/pubsub/redis/cvtt-prod-eqty-01"
, "redis_key": "DAY_STOCK_LIST"
}
}

View File

@ -3,7 +3,7 @@
@var SourcePath=/home/oleg/develop/cvtt2/tmp
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "algos": @inc=http://${CONFIG_SERVICE}/apps/common/algos
, "session_type": "CALENDAR"

View File

@ -3,10 +3,13 @@
"class": "cvttpy.trading.algos.simple.SimpleTradingAlgo"
, "params": {}
}
, "TRDALGO_SIMPLE_BO": {
"class": "cvttpy.trading.algos.bid_and_offer.SimpleBidAndOfferTradingAlgo"
, "params": {}
}
, "TRDALGO_MOOMOC_01": {
"class": "cvttpy.trading.algos.moo_moc.MooMocTradingAlgo"
, "params": {
},
, "params": {}
}
, "TRDALGO_TWAP01": {
"class": "cvttpy.trading.algos.twap.TwapAlgo"

43
data/apps/common/comm.cfg Normal file
View File

@ -0,0 +1,43 @@
# /comm
{
"pubsub" : {
"redis": {
"localhost": {
"url": "redis://localhost"
, "type": "redis"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvttdata": {
"url": "redis://cvttdata.cvtt.vpn"
, "type": "redis"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvtt-testserver": {
"url": "redis://cvtt-testserver.cvtt.vpn"
, "type": "redis"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvtt-prod-eqty-01": {
"url": "redis://cvtt-prod-eqty-01.cvtt.vpn"
, "type": "redis"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvtt-prod-03": {
"url": "redis://cvtt-prod-03.cvtt.vpn"
, "type": "redis"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvtt-prod-eqty-01": {
"url": "redis://cvtt-prod-eqty-01.cvtt.vpn"
, "type": "redis"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
}
}
}

View File

@ -1,32 +0,0 @@
{
"localhost": {
"url": "redis://localhost"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvttdata": {
"url": "redis://cvttdata.cvtt.vpn"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvtt-testserver": {
"url": "redis://cvtt-testserver.cvtt.vpn"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvtt-prod-eqty-01": {
"url": "redis://cvtt-prod-eqty-01.cvtt.vpn"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvtt-prod-03": {
"url": "redis://cvtt-prod-03.cvtt.vpn"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
, "cvtt-prod-eqty-01": {
"url": "redis://cvtt-prod-eqty-01.cvtt.vpn"
, "read_timeout" : 0.01
, "ping_timeout_secs": 2.0
}
}

View File

@ -3,12 +3,13 @@
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "cvttcomm": {
"type": "redis"
# , "redis_settings": "localhost"
, "redis_settings": "cloud17"
}
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "comm_settings": "/comm/pubsub/redis/cloud17"
# , "cvttcomm": {
# "type": "redis"
# # , "comm_settings": "/comm/pubsub/redis/localhost"
# , "comm_settings": "/comm/pubsub/redis/cloud17"
# }
, "session_type": "PERMANENT"
, "books": {
"CVTT_BK01": {}

View File

@ -3,12 +3,11 @@
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "cvttcomm": {
"type": "redis"
# , "redis_settings": "localhost"
, "redis_settings": "cloud17"
}
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "comm_settings": "/comm/pubsub/redis/cloud17"
# , "cvttcomm": {
# "type": "redis"
# }
, "session_type": "PERMANENT"
, "books": {
"CVTT_BK01": {}

View File

@ -3,12 +3,9 @@
{ "___dummy___": null
, "refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "active_instruments": @inc=http://${CONFIG_SERVICE}/apps/active_instruments
, "cvttcomm": {
"type": "redis"
, "redis_settings": "cvtt-prod-eqty-01"
}
, "comm_settings": "/comm/pubsub/redis/cvtt-prod-eqty-01"
, "session_type": "CALENDAR"
, "calendar_session": {
"trading_hours_url": [
@ -34,7 +31,7 @@
}
# --------------------------------------------------------------------
, "trader": {
"app_channel": "TRDR" active_exchanges_: str
"app_channel": "TRDR"
, "is_short_allowed": false
, "exchanges_settings": {

View File

@ -3,5 +3,5 @@
{
# ----------------------------------
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
}

View File

@ -18,19 +18,19 @@
, "status_channel": "Status-CVTT"
}
, "data_checks": {
"BNBFUT-1": {
"tables": ["bnbfut.md_booktops"]
, "exchange_id": "BNBFUT"
, "instruments": ["PERP-BTC-USDT"]
, "threshold_sec": 3600.0
}
, "BNBFUT-2": {
"tables": ["bnbfut.md_trades"]
, "exchange_id": "BNBFUT"
, "instruments": ["PERP-BTC-USDT"]
, "threshold_sec": 3600.0
}
, "BNBSPOT-1": {
# "BNBFUT-1": {
# "tables": ["bnbfut.md_booktops"]
# , "exchange_id": "BNBFUT"
# , "instruments": ["PERP-BTC-USDT"]
# , "threshold_sec": 3600.0
# }
# , "BNBFUT-2": {
# "tables": ["bnbfut.md_trades"]
# , "exchange_id": "BNBFUT"
# , "instruments": ["PERP-BTC-USDT"]
# , "threshold_sec": 3600.0
# }
"BNBSPOT-1": {
"tables": ["bnbspot.md_booktops"]
, "exchange_id": "BNBSPOT"
, "instruments": ["PAIR-BTC-USDT"]

View File

@ -2,19 +2,72 @@
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
// -------------------------------------------------------------------------
// This is used only for dynamically loaded instrument lists (as for Alpaca)
, "active_instruments": @inc=http://${CONFIG_SERVICE}/apps/active_instruments
, "cvttcomm": {
"type": "redis"
, "redis_settings": "cvtt-prod-eqty-01"
}
, "comm_settings": "/comm/pubsub/redis/cvtt-prod-eqty-01"
# , "cvttcomm": {
# "type": "redis"
# , "comm_settings": "/comm/pubsub/redis/cvtt-prod-eqty-01"
# }
//------------------------------------------------------------------------------
, "md_recorder": {
"db": {
"instrument_groups": {
"BNBFUT_CLD21": [
"BNBFUT:PERP-BTC-USDT"
, "BNBFUT:PERP-ETH-USDT"
]
"BNBFUT_CVTTDATA": [
"BNBFUT:PERP-BTC-USDT"
, "BNBFUT:PERP-ETH-USDT"
]
, "BNBSPOT_CLD21": [
"BNBSPOT:PAIR-ADA-USDT"
, "BNBSPOT:PAIR-BCH-USDT"
, "BNBSPOT:PAIR-BTC-USDT"
, "BNBSPOT:PAIR-DOT-USDT"
, "BNBSPOT:PAIR-ETH-USDT"
, "BNBSPOT:PAIR-LTC-USDT"
, "BNBSPOT:PAIR-SOL-USDT"
, "BNBSPOT:PAIR-USDC-USDT"
, "BNBSPOT:PAIR-XRP-USDT"
]
, "BNBSPOT_CVTTDATA": [
"BNBSPOT:PAIR-ADA-USDT"
, "BNBSPOT:PAIR-BCH-USDT"
, "BNBSPOT:PAIR-BTC-USDT"
, "BNBSPOT:PAIR-DOT-USDT"
, "BNBSPOT:PAIR-ETH-USDT"
, "BNBSPOT:PAIR-LTC-USDT"
, "BNBSPOT:PAIR-SOL-USDT"
, "BNBSPOT:PAIR-USDC-USDT"
, "BNBSPOT:PAIR-XRP-USDT"
]
, "COINBASE_CLD21": [
"COINBASE:PAIR-ADA-USD"
, "COINBASE:PAIR-BCH-USD"
, "COINBASE:PAIR-BTC-USD"
, "COINBASE:PAIR-DOT-USD"
, "COINBASE:PAIR-ETH-USD"
, "COINBASE:PAIR-LTC-USD"
, "COINBASE:PAIR-SOL-USD"
, "COINBASE:PAIR-XRP-USD"
]
, "COINBASE_CVTTDATA": [
"COINBASE:PAIR-ADA-USD"
, "COINBASE:PAIR-BCH-USD"
, "COINBASE:PAIR-BTC-USD"
, "COINBASE:PAIR-DOT-USD"
, "COINBASE:PAIR-ETH-USD"
, "COINBASE:PAIR-LTC-USD"
, "COINBASE:PAIR-SOL-USD"
, "COINBASE:PAIR-XRP-USD"
]
}
, "db": {
"class": "cvttpy.tools.db.timescale.tsdb_client.TimescaleDbClient"
}
, "flush_interval_sec": 0.5
@ -31,11 +84,15 @@
}
, "BNBSPOT": {
"instruments": {
"PAIR-BTC-USDT": ["TRADES", "BOOK_TOP"]
"PAIR-ADA-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-BCH-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-BTC-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-DOT-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-ETH-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-LTC-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-XRP-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-SOL-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-USDC-USDT": ["TRADES", "BOOK_TOP"]
, "PAIR-XRP-USDT": ["TRADES", "BOOK_TOP"]
}
, "tables": {
"trades": "bnbspot.md_trades"
@ -56,9 +113,13 @@
}
, "COINBASE": {
"instruments": {
"PAIR-BTC-USD": ["TRADES", "BOOK_TOP"]
"PAIR-ADA-USD": ["TRADES", "BOOK_TOP"]
, "PAIR-BCH-USD": ["TRADES", "BOOK_TOP"]
, "PAIR-BTC-USD": ["TRADES", "BOOK_TOP"]
, "PAIR-DOT-USD": ["TRADES", "BOOK_TOP"]
, "PAIR-ETH-USD": ["TRADES", "BOOK_TOP"]
, "PAIR-LTC-USD": ["TRADES", "BOOK_TOP"]
, "PAIR-SOL-USD": ["TRADES", "BOOK_TOP"]
, "PAIR-XRP-USD": ["TRADES", "BOOK_TOP"]
}
, "tables": {

View File

@ -9,9 +9,10 @@
},
}
}
, "cvttcomm": {
"type": "redis"
, "redis_settings": "localhost"
}
, "comm_settings": "/comm/pubsub/redis/localhost"
# , "cvttcomm": {
# "type": "redis"
# , "comm_settings": "/comm/pubsub/redis/localhost"
# }
}

View File

@ -15,9 +15,10 @@
},
}
}
, "cvttcomm": {
"type": "redis"
, "redis_settings": "localhost"
}
, "comm_settings": "/comm/pubsub/redis/localhost"
# , "cvttcomm": {
# "type": "redis"
# , "comm_settings": "/comm/pubsub/redis/localhost"
# }
}

View File

@ -0,0 +1,35 @@
@var CONFIG_SERVICE=cloud23.cvtt.vpn:6789
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "algos": @inc=http://${CONFIG_SERVICE}/apps/common/algos
"exchanges_settings": {
"*": {
"mkt_data": {
"enabled": true
, "streaming": true
},
},
"ALPACA-MD-REST-ONLY": {
"mkt_data": {
"enabled": true
, "streaming": false
},
},
"COINBASE_SIM": {
"mkt_data": {
"enabled": true
, "streaming": true
},
"order_entry": {
"enabled": true
, "streaming": true
},
"accounting": {
"enabled": true
, "streaming": false
},
}
}
}

View File

@ -0,0 +1,141 @@
@var CONFIG_SERVICE=cloud23.cvtt.vpn:6789
@var SQLITE_DIR=/home/oleg/tmp/sqlite
@var FROM_TIME="2024-10-03 13:30:00"
@var INTERVAL="18 minutes"
# @var INTERVAL="5 minutes"
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "comm_settings": "/comm/pubsub/redis/localhost"
, "simulation": {
# "speed_factor": 1.0,
"speed_factor": 0.0,
"time_events_interval_ms": 0
}
, "market_simulator" : {
"initial_positions": {
"exchange": "COINBASE",
"assets": {
"BTC": 0.5
, "ETH": 0.0
, "USD": 10_000.0
}
}
, "market_data": {
"sources": [
# {
# "loader_class": "cvttpy.trading.mkt_data.time_series.loaders.sqlite_loader.SqliteMdLoader"
# , "file_name": "${SQLITE_DIR}/20240906.COIN.1min.db"
# , "table_name": "md_1min_bars"
# , "columns": [
# "tstamp"
# , "tstamp_ns as tm" # must have tm for DataFrame
# , "tstamp_ns as local_time_ns" # must have for simrunner
# , "exchange_id"
# , "instrument_id"
# , "open"
# , "high"
# , "low"
# , "close"
# , "volume"
# , "vwap"
# , "num_trades"
# ]
# , "time_column": "tstamp"
# , "exchange_id": "ALPACA"
# , "instruments": ["STOCK-COIN"]
# , "md_type": "HIST_BAR"
# }
{
"loader_class": "cvttpy.trading.mkt_data.time_series.loaders.tsdb_loader.TimescaleTSLoader"
, "credentials_key": "TSDB_MD_CVTTDATA_RO"
, "interval": ${INTERVAL}
, "from_time": ${FROM_TIME} #"2024-10-03 09:00:00"
, "exchange_id": "COINBASE"
, "instruments": ["PAIR-BTC-USD"]
, "md_type": "TRADES"
, "table_name": "coinbase.md_trades"
, "columns": [
"time",
"local_time_ns",
"exchange_ts_ns",
"exchange_id",
"instrument_id",
"price",
"quantity",
"taker_side",
"'TRD' as type",
]
, "time_column": "time"
}
, {
"loader_class": "cvttpy.trading.mkt_data.time_series.loaders.tsdb_loader.TimescaleTSLoader"
, "credentials_key": "TSDB_MD_CVTTDATA_RO"
, "interval": ${INTERVAL}
, "from_time": ${FROM_TIME} #"2024-10-03 09:00:00"
, "exchange_id": "COINBASE"
, "instruments": ["PAIR-BTC-USD"]
, "md_type": "BOOK_TOP"
, "table_name": "coinbase.md_booktops"
, "columns": [
"time",
"local_time_ns",
"exchange_id",
"instrument_id",
"bid_price",
"bid_quantity",
"ask_price",
"ask_quantity",
"'BT' as type",
]
, "time_column": "time"
}
]
, "api": {
"web_socket": {
"url": "ws://localhost:8080/ws"
}
}
}
, "order_entry": {
"execution": {
"execute_on": ["BOOK_TOP", "TRADES"]
"top_only": true
,"min_order_age_sec": 0.1
, "pricing_method": "BY_MKT_TRD_PRICE_BY_TRADE"
, "short_sale_allowed": false
, "fee_schedule": {
"taker_fee_rate": 0.006
"maker_fee_rate": 0.004
}
# , "presubscribe_md_types": ["BOOK_TOP", "TRADES"]
}
, "api": {
"web_socket": {
"url": "ws://localhost:8180/ws"
}
, "REST": {
"port": 8181
"new_order_url": ["POST", "http://localhost:8181/order"]
, "cancel_order_url": ["POST", "http://localhost:8181/cancel"]
, "cancel_all_url": ["POST", "http://localhost:8181/cancel_all"]
, "open_orders_url": ["GET", "http://localhost:8181/open_orders"]
, "order_status_url": ["GET", "http://localhost:8181/order_status"]
}
}
}
, "accounting": {
"api": {
"REST": {
"port": 8182
, "positions_url": ["GET", "http://localhost:8182/positions"]
, "trades_url": ["GET", "http://localhost:8182/trades"]
}
}
}
}
}

View File

@ -32,6 +32,6 @@
}
}
, "refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
}

View File

@ -23,6 +23,6 @@
}
}
, "refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
}

View File

@ -1,7 +1,7 @@
@var CONFIG_SERVICE=cloud23.cvtt.vpn:6789
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "active_instruments": @inc=http://${CONFIG_SERVICE}/apps/active_instruments
"exchanges_settings": {
"*": {
@ -19,7 +19,7 @@
}
# , "cvttcomm": {
# "type": "redis"
# , "redis_settings": "localhost"
# , "comm_settings": "/comm/pubsub/redis/localhost"
# }
}

View File

@ -1,7 +1,7 @@
@var CONFIG_SERVICE=cloud23.cvtt.vpn:6789
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "active_instruments": @inc=http://${CONFIG_SERVICE}/apps/active_instruments
, "exchanges_settings": {
"*": {
@ -11,10 +11,11 @@
},
}
}
, "cvttcomm": {
"type": "redis"
, "redis_settings": "cvtt-prod-eqty-01"
}
, "comm_settings": "/comm/pubsub/redis/cvtt-prod-eqty-01"
# , "cvttcomm": {
# "type": "redis"
# , "comm_settings": "/comm/pubsub/redis/cvtt-prod-eqty-01"
# }
, "md_portal": {
"app_channel": "MD_PORTAL"
}

View File

@ -1,13 +1,14 @@
@var CONFIG_SERVICE=cloud23.cvtt.vpn:6789
{
"refdata": @inc=http://${CONFIG_SERVICE}/refdata/refdata
, "redis": @inc=http://${CONFIG_SERVICE}/apps/common/redis
, "comm": @inc=http://${CONFIG_SERVICE}/apps/common/comm
, "cvttcomm": {
"type": "redis"
# , "redis_settings": "localhost"
, "redis_settings": "cvtt-prod"
}
, "comm_settings": "/comm/pubsub/redis/cvtt-prod"
# , "cvttcomm": {
# "type": "redis"
# # , "comm_settings": "/comm/pubsub/redis/localhost"
# , "comm_settings": "/comm/pubsub/redis/cvtt-prod"
# }
, "executor": {
"app_channel": "EXEC"
}

View File

@ -39,9 +39,9 @@
"md_symbol": "AAVEBUSD",
"trade_symbol": "AAVEBUSD"
},
"PAIR-XRP-BUSD": {
"md_symbol": "XRPBUSD",
"trade_symbol": "XRPBUSD"
"PAIR-ADA-USDT": {
"md_symbol": "ADAUSDT",
"trade_symbol": "ADAUSDT"
},
"PAIR-AVAX-BUSD": {
"md_symbol": "AVAXBUSD",
@ -51,6 +51,10 @@
"md_symbol": "BCHBUSD",
"trade_symbol": "BCHBUSD"
},
"PAIR-BCH-USDT": {
"md_symbol": "BCHUSDT",
"trade_symbol": "BCHUSDT"
},
"PAIR-BTC-BUSD": {
"md_symbol": "BTCBUSD",
"trade_symbol": "BTCBUSD"
@ -71,6 +75,10 @@
"md_symbol": "DOGEUSDT",
"trade_symbol": "DOGEUSDT"
},
"PAIR-DOT-USDT": {
"md_symbol": "DOTUSDT",
"trade_symbol": "DOTUSDT"
},
"PAIR-ETH-BUSD": {
"md_symbol": "ETHBUSD",
"trade_symbol": "ETHBUSD"
@ -111,9 +119,9 @@
"md_symbol": "MATICUSDT",
"trade_symbol": "MATICUSDT"
},
"PAIR-SOL-BUSD": {
"md_symbol": "SOLBUSD",
"trade_symbol": "SOLBUSD"
"PAIR-SOL-USDT": {
"md_symbol": "SOLUSDT",
"trade_symbol": "SOLUSDT"
},
"PAIR-UNI-BUSD": {
"md_symbol": "UNIBUSD",
@ -235,6 +243,10 @@
"md_symbol": "AVAX-USD",
"trade_symbol": "AVAX-USD"
},
"PAIR-ADA-USD": {
"md_symbol": "ADA-USD",
"trade_symbol": "ADA-USD"
},
"PAIR-BCH-USD": {
"md_symbol": "BCH-USD",
"trade_symbol": "BCH-USD"
@ -247,6 +259,10 @@
"md_symbol": "DOGE-USD",
"trade_symbol": "DOGE-USD"
},
"PAIR-DOT-USD": {
"md_symbol": "DOT-USD",
"trade_symbol": "DOT-USD"
},
"PAIR-ETH-USD": {
"md_symbol": "ETH-USD",
"trade_symbol": "ETH-USD"

View File

@ -12,7 +12,7 @@
, "cred_key": "ALPACA_SANDBOX"
, "order_entry": {
"class": "cvttpy.exchanges.alpaca.connector.AlpacaOrderEntryClient"
"class": "cvttpy.exchanges.alpaca.oe_client.AlpacaOrderEntryClient"
, "REST": {
"submit_order_url": ["POST", "https://paper-api.alpaca.markets/v2/orders"]
@ -57,7 +57,7 @@
, "cred_key": "ALPACA_SANDBOX"
, "order_entry": {
"class": "cvttpy.exchanges.alpaca.connector.AlpacaOrderEntryClient"
"class": "cvttpy.exchanges.alpaca.oe_client.AlpacaOrderEntryClient"
, "REST": {
"submit_order_url": ["POST", "https://paper-api.alpaca.markets/v2/orders"]
@ -122,7 +122,7 @@
, "cred_key": "ALPACA_SANDBOX"
, "order_entry": {
"class": "cvttpy.exchanges.alpaca.connector.AlpacaOrderEntryClient"
"class": "cvttpy.exchanges.alpaca.oe_client.AlpacaOrderEntryClient"
, "REST": {
"submit_order_url": ["POST", "https://paper-api.alpaca.markets/v2/orders"]
@ -254,7 +254,7 @@
, "type": "SPOT"
, "order_entry": {
"class": "cvttpy.exchanges.coinbase.spot.connector.CoinbaseSpotRestExchConnector"
"class": "cvttpy.exchanges.coinbase.spot.oe_client.CoinbaseSpotOEClient"
, "REST": {
"open_orders_url": ["GET", "https://api.coinbase.com/api/v3/brokerage/orders/historical/batch"]
@ -290,7 +290,7 @@
, "type": "SPOT"
, "order_entry": {
"class": "cvttpy.exchanges.coinbase.spot.connector.CoinbaseSpotRestExchConnector"
"class": "cvttpy.exchanges.coinbase.spot.oe_client.CoinbaseSpotOEClient"
, "REST": {
"open_orders_url": ["GET", "https://api.coinbase.com/api/v3/brokerage/orders/historical/batch"]
@ -316,6 +316,37 @@
}
}
, "COINBASE_SIM": {
"exchange_id": "COINBASE"
, "name": "Coinbase Advanced Trade (Simulation)"
, "type": "SPOT"
, "mktdata" : {
"class": "cvttpy.exchanges.mkt_simulator.md_client.MktSimMdClientFeed"
"ws_url": ["WS", "ws://localhost:8080/ws"]
}
, "order_entry": {
"class": "cvttpy.exchanges.mkt_simulator.oe_client.MarketSimulatorOEClient"
, "REST": {
"new_order_url": ["POST", "http://localhost:8181/order"]
, "cancel_order_url": ["POST", "http://localhost:8181/cancel"]
, "cancel_all_url": ["POST", "http://localhost:8181/cancel_all"]
, "open_orders_url": ["GET", "http://localhost:8181/open_orders"]
, "order_status_url": ["GET", "http://localhost:8181/order_status"]
},
"ws_url": ["WSS", "ws://localhost:8180/ws"]
}
, "accounting": {
"class": "cvttpy.exchanges.mkt_simulator.acct_client.MktSimAccounting"
, "REST": {
"positions_url": ["GET", "http://localhost:8182/positions"]
, "trades_url": ["GET", "http://localhost:8182/trades"]
}
}
}
# ---------------------------- G
, "GEMINI": {
# https://docs.gemini.com/rest-api
@ -404,7 +435,7 @@
, "mktdata" : {
"class": "cvttpy.exchanges.proxies.md_portal_clnt.mkt_data.MktDataPortalFeed"
, "redis_settings": "cvtt-prod-eqty-01"
, "comm_settings": "/comm/pubsub/redis/cvtt-prod-eqty-01"
, "channel_prefix": "MD_ALPACA_SNDBX"
}
}
@ -415,10 +446,20 @@
, "mktdata" : {
"class": "cvttpy.exchanges.proxies.md_portal_clnt.mkt_data.MktDataPortalFeed"
, "redis_settings": "cvtt-prod-03"
, "comm_settings": "/comm/pubsub/redis/cvtt-prod-03"
, "channel_prefix": "MD_ALPACA_03"
}
}
# , "MARKET_SIMULATOR": {
# "exchange_id": "MARKET_SIMULATOR"
# , "name": "Market Simulator"
# , "type": "SIM"
# , "mktdata" : {
# "class": "cvttpy.exchanges.mkt_simulator.md_client.MktSimMdClientFeed"
# "ws_url": ["WS", "ws://localhost:8080/ws"]
# }
# }
# ---------------------------- O
, "OKX": {
"exchange_id": "OKX"

View File

@ -13,6 +13,18 @@
"quantity_precision": "0.001",
"price_tick": 0.01
},
"PAIR-ADA-USD": {
"base_asset": "ADA",
"quote_asset": "USD",
"quantity_precision": "0.1",
"price_tick": 0.0001
},
"PAIR-ADA-USDT": {
"base_asset": "ADA",
"quote_asset": "USDT",
"quantity_precision": "0.1",
"price_tick": 0.0001
},
"PAIR-ASD-USDT": {
"base_asset": "ASD",
"quote_asset": "USDT",
@ -51,6 +63,12 @@
"quantity_precision": "0.001",
"price_tick": 0.1
},
"PAIR-BCH-USDT": {
"base_asset": "BCH",
"quote_asset": "USDT",
"quantity_precision": "0.001",
"price_tick": 0.1
},
"PAIR-BTC-BUSD": {
"base_asset": "BTC",
"quote_asset": "BUSD",
@ -100,6 +118,18 @@
"quantity_precision": "0.01",
"price_tick": 0.00001
},
"PAIR-DOT-USD": {
"base_asset": "DOT",
"quote_asset": "USD",
"quantity_precision": "0.01",
"price_tick": 0.001
},
"PAIR-DOT-USDT": {
"base_asset": "DOT",
"quote_asset": "USDT",
"quantity_precision": "0.01",
"price_tick": 0.001
},
# --- PAIR-E
"PAIR-ETH-BUSD": {
"base_asset": "ETH",
@ -216,7 +246,13 @@
"PAIR-SOL-USD": {
"base_asset": "SOL",
"quote_asset": "USD",
"quantity_precision": "0.01",
"quantity_precision": "0.001",
"price_tick": 0.01
},
"PAIR-SOL-USDT": {
"base_asset": "SOL",
"quote_asset": "USDT",
"quantity_precision": "0.001",
"price_tick": 0.01
},
# --- PAIR-U

View File

@ -1,4 +1,5 @@
#!/bin/bash
cd $(dirname ${0})
docker compose down && docker compose up -d --pull=always
docker compose down
docker compose up -d --pull=always

View File

@ -0,0 +1,13 @@
version: "3.8"
#==================================================
services:
relative_liquidity:
image: cloud21.cvtt.vpn:5500/relative_liquidity:latest
container_name: relative_liquidity_svc
restart: unless-stopped
volumes:
- /home/cvtt/prod/data:/app/data
- /home/cvtt/prod/logs:/logs
ports:
- 5678:5678

View File

@ -0,0 +1,5 @@
#!/bin/bash
cd $(dirname ${0})
docker compose down
docker compose up -d --pull=always

View File

@ -0,0 +1,4 @@
#!/bin/bash
cd $(dirname ${0})
docker compose up -d --pull=always

4
run_relative_liquidity/stop.sh Executable file
View File

@ -0,0 +1,4 @@
#!/bin/bash
cd $(dirname ${0})
docker compose down

View File

@ -0,0 +1,10 @@
version: "3.8"
#==================================================
services:
trading_calendar:
image: apptasticsoftware/trading-calendar
container_name: trading-calendar
restart: unless-stopped
ports:
- 8000:80

View File

@ -0,0 +1,5 @@
#!/bin/bash
cd $(dirname ${0})
docker compose down
docker compose up -d --pull=always

4
run_trading_calendar/start.sh Executable file
View File

@ -0,0 +1,4 @@
#!/bin/bash
cd $(dirname ${0})
docker compose up -d --pull=always

4
run_trading_calendar/stop.sh Executable file
View File

@ -0,0 +1,4 @@
#!/bin/bash
cd $(dirname ${0})
docker compose down