From b72df42d8b5819835ba4db88084704a30de8db15 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 4 Oct 2023 12:07:38 +0200 Subject: [PATCH 01/79] WIP: Add logging messages --- .../behaviours/decision_receive.py | 22 +++++++++++++++++++ .../skills/decision_maker_abci/models.py | 5 +++++ 2 files changed, 27 insertions(+) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index fd3506eef..e932f3a70 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -268,12 +268,34 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] price = prices[vote] available_shares = int(selected_type_tokens_in_pool * price) + self.context.logger.info( + f"Token amounts: {token_amounts}\n" + f"k: {k}\n" + f"Bet per token: {bet_per_token}\n" + f"Prices: {prices}\n" + f"Tokens traded: {tokens_traded}\n" + f"Selected shares: {selected_shares}\n" + f"Other shares: {other_shares}\n" + f"Selected type tokens in pool: {selected_type_tokens_in_pool}\n" + f"Other tokens in pool: {other_tokens_in_pool}\n" + f"Tokens remaining in pool: {tokens_remaining_in_pool}\n" + f"Swapped shares: {swapped_shares}\n" + f"Number of shares: {num_shares}\n" + f"Price: {price[vote]}\n" + f"Available shares: {available_shares}\n" + ) + return num_shares, available_shares def _is_profitable(self, confidence: float, vote: int) -> bool: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet bet_amount = self.params.get_bet_amount(confidence) + self.context.logger.info( + f"Bet amount: {self.wei_to_native(bet_amount)} xDAI\n" + f"Fee: {self.wei_to_native(bet.fee)} xDAI\n" + f"Net bet amount: {self.wei_to_native(remove_fraction_wei(bet_amount, bet.fee))} xDAI\n" + ) net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet.fee)) num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) bet_threshold = self.params.bet_threshold diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index b440f6678..412a0b62f 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -159,6 +159,11 @@ def get_bet_amount(self, confidence: float) -> int: """Get the bet amount given a prediction's confidence.""" threshold = round(confidence, 1) return self.bet_amount_per_threshold[threshold] + + # def get_bet_amount(self, confidence: float) -> int: + # """Get the bet amount given a specified trading strategy.""" + # threshold = round(confidence, 1) + # return self.bet_amount_per_threshold[threshold] class MechResponseSpecs(ApiSpecs): From e4dcd8d54e3af29a4748e377ccd705192d6853e2 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 4 Oct 2023 16:19:59 +0200 Subject: [PATCH 02/79] chore: Update packages --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/decision_receive.py | 5 ----- packages/valory/skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 19 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 67a8499e8..618af2953 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeienzc3c5xygb4z3l57zivtc3zexpoochjzmiil7pv646jhxrgetqm", - "skill/valory/trader_abci/0.1.0": "bafybeiho45hvspxswav2zial53i3aeeq6dpb6nrpwpzltor2qphbzld26y", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidkamza7zxyk43tm3otxaex3bwqzclim6mxydyfobrpat356nvmii", + "skill/valory/trader_abci/0.1.0": "bafybeicr4ssglw6dhp4xm2yqkmal6d6zwoiiwqczhni33omt7fivwhv674", "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", - "agent/valory/trader/0.1.0": "bafybeigh5kh6qdyrflwbv2s7hmoypp6qtlbwiavb7apms3z4cnpqksjxce", - "service/valory/trader/0.1.0": "bafybeifkb5pjds3yyda6fubolr36zjfypy7nbq7z3v5etiodr35vhuznza", + "agent/valory/trader/0.1.0": "bafybeiea2zh24sdunam47qae6rxp5ixcq23cayp2t4m7kzorqkyqclvrty", + "service/valory/trader/0.1.0": "bafybeib63klegywudy2udnnwb2ad5vu63at3hajapvmfbswadzcaqyaxwe", "contract/valory/erc20/0.1.0": "bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeidj6a3arhm6wpswofka3liwdaofv5dh5x5dv2sbvgqrrnb6djdr5q", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeifffirzbbfxo5b4efmk77b5m6kzvxrco46by2pmdjq7gwxpkocaem", "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", "contract/valory/realitio/0.1.0": "bafybeiewpazpi2wgixmiu64kauwn7qes3xzphqid4pxvznm2himv4tciee", "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index db52e1b58..5c7d29e5a 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidj6a3arhm6wpswofka3liwdaofv5dh5x5dv2sbvgqrrnb6djdr5q +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifffirzbbfxo5b4efmk77b5m6kzvxrco46by2pmdjq7gwxpkocaem - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeienzc3c5xygb4z3l57zivtc3zexpoochjzmiil7pv646jhxrgetqm -- valory/trader_abci:0.1.0:bafybeiho45hvspxswav2zial53i3aeeq6dpb6nrpwpzltor2qphbzld26y +- valory/decision_maker_abci:0.1.0:bafybeidkamza7zxyk43tm3otxaex3bwqzclim6mxydyfobrpat356nvmii +- valory/trader_abci:0.1.0:bafybeicr4ssglw6dhp4xm2yqkmal6d6zwoiiwqczhni33omt7fivwhv674 default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 7da6a2a21..05c6448b6 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeigh5kh6qdyrflwbv2s7hmoypp6qtlbwiavb7apms3z4cnpqksjxce +agent: valory/trader:0.1.0:bafybeiea2zh24sdunam47qae6rxp5ixcq23cayp2t4m7kzorqkyqclvrty number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index e932f3a70..3470f518f 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -291,11 +291,6 @@ def _is_profitable(self, confidence: float, vote: int) -> bool: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet bet_amount = self.params.get_bet_amount(confidence) - self.context.logger.info( - f"Bet amount: {self.wei_to_native(bet_amount)} xDAI\n" - f"Fee: {self.wei_to_native(bet.fee)} xDAI\n" - f"Net bet amount: {self.wei_to_native(remove_fraction_wei(bet_amount, bet.fee))} xDAI\n" - ) net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet.fee)) num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) bet_threshold = self.params.bet_threshold diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 9e3ea76a1..40b4aff71 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiato4qxnc2kjjdtttvqdna7dp4c5evlb6cus7h6eci7tj73tqnpey behaviours/bet_placement.py: bafybeifwwvvwh4qgf3jkyvza4wfvjv63il2xewsklsjtpyanp23y6hg2aa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeid54jwjs4lulcl2n2w7taxne3wqgsey6ppaidwr2up6bztyf35ghm + behaviours/decision_receive.py: bafybeih7a4s2c67q3bogmegk7okbebzhhanprw5u3qncvzlks2ilvzlcje behaviours/decision_request.py: bafybeidlyl2ojmpfs2zkewoacraya2cbampo4ynqbqaocsoq7v2nif3ahi behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeigzsx4wyov3ehfvdjmo2d7yimss4p7mbkopkqyr4gryxpa5rpv6ku @@ -25,7 +25,7 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeie6ynq37isn4itspkj2eka6r2wwsok3ofdve6iipw5nwjimmzblzu + models.py: bafybeie357butaav2hjvr2qyef2fwvgdsnfh6j2pt7ghmqoziayqjg6fna payloads.py: bafybeic4iz6uxinqpaxnefkadnzaox23y7k57zawnnkeovplih36v5cchy policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeihtbundd75a4wdk2d23smvdjlh7fsv42ff2cwwuwgkyyxjciobwca diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 0fee5ea84..e93ca5742 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeienzc3c5xygb4z3l57zivtc3zexpoochjzmiil7pv646jhxrgetqm -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidj6a3arhm6wpswofka3liwdaofv5dh5x5dv2sbvgqrrnb6djdr5q +- valory/decision_maker_abci:0.1.0:bafybeidkamza7zxyk43tm3otxaex3bwqzclim6mxydyfobrpat356nvmii +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifffirzbbfxo5b4efmk77b5m6kzvxrco46by2pmdjq7gwxpkocaem behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 37bd49539..fe4a37c06 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeienzc3c5xygb4z3l57zivtc3zexpoochjzmiil7pv646jhxrgetqm +- valory/decision_maker_abci:0.1.0:bafybeidkamza7zxyk43tm3otxaex3bwqzclim6mxydyfobrpat356nvmii behaviours: main: args: {} From dc6d71cdd6ba08eef7c24042890af525ab62b7ea Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 4 Oct 2023 16:59:11 +0200 Subject: [PATCH 03/79] chore: Update packages --- packages/packages.json | 10 +++--- packages/valory/agents/trader/aea-config.yaml | 6 ++-- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 35 ++++++++++--------- .../skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 +-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 31 insertions(+), 30 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 618af2953..1bc0068f8 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeidkamza7zxyk43tm3otxaex3bwqzclim6mxydyfobrpat356nvmii", - "skill/valory/trader_abci/0.1.0": "bafybeicr4ssglw6dhp4xm2yqkmal6d6zwoiiwqczhni33omt7fivwhv674", + "skill/valory/decision_maker_abci/0.1.0": "bafybeib4lim2wzczsxb6ycva6rwxzx3hh4njvnfgcn74gsaxlatsbaebhq", + "skill/valory/trader_abci/0.1.0": "bafybeifjvi4tae3zxn4qql3wb54itp6xpqt2oywyqsng47tktfovmeu3su", "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", - "agent/valory/trader/0.1.0": "bafybeiea2zh24sdunam47qae6rxp5ixcq23cayp2t4m7kzorqkyqclvrty", - "service/valory/trader/0.1.0": "bafybeib63klegywudy2udnnwb2ad5vu63at3hajapvmfbswadzcaqyaxwe", + "agent/valory/trader/0.1.0": "bafybeichr3c3cgnujsphppmcslyl3rfurmmwg5exbea6b2ybb2rio2slry", + "service/valory/trader/0.1.0": "bafybeidrp6xlogk26d7z37b2jmqkby4yugiceydcuwh4eh2pnkyq5cfdz4", "contract/valory/erc20/0.1.0": "bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeifffirzbbfxo5b4efmk77b5m6kzvxrco46by2pmdjq7gwxpkocaem", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiakesbetu43ehxojowietwaogihpaj5sr3uvgcstqdlvlrehtqxfy", "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", "contract/valory/realitio/0.1.0": "bafybeiewpazpi2wgixmiu64kauwn7qes3xzphqid4pxvznm2himv4tciee", "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 5c7d29e5a..818a7e2d4 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifffirzbbfxo5b4efmk77b5m6kzvxrco46by2pmdjq7gwxpkocaem +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiakesbetu43ehxojowietwaogihpaj5sr3uvgcstqdlvlrehtqxfy - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeidkamza7zxyk43tm3otxaex3bwqzclim6mxydyfobrpat356nvmii -- valory/trader_abci:0.1.0:bafybeicr4ssglw6dhp4xm2yqkmal6d6zwoiiwqczhni33omt7fivwhv674 +- valory/decision_maker_abci:0.1.0:bafybeib4lim2wzczsxb6ycva6rwxzx3hh4njvnfgcn74gsaxlatsbaebhq +- valory/trader_abci:0.1.0:bafybeifjvi4tae3zxn4qql3wb54itp6xpqt2oywyqsng47tktfovmeu3su default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 05c6448b6..d0e75ec9f 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiea2zh24sdunam47qae6rxp5ixcq23cayp2t4m7kzorqkyqclvrty +agent: valory/trader:0.1.0:bafybeichr3c3cgnujsphppmcslyl3rfurmmwg5exbea6b2ybb2rio2slry number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 3470f518f..b90f9da8f 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -230,60 +230,61 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] # calculate the pool's k (x*y=k) token_amounts = bet.outcomeTokenAmounts + self.context.logger.info(f"Token amounts: {token_amounts}\n") if token_amounts is None: return 0, 0 k = prod(token_amounts) + self.context.logger.info(f"k: {k}\n") # the OMEN market trades an equal amount of the investment to each of the tokens in the pool # here we calculate the bet amount per pool's token bet_per_token = net_bet_amount / BINARY_N_SLOTS + self.context.logger.info(f"Bet per token: {bet_per_token}\n") # calculate the number of the traded tokens prices = bet.outcomeTokenMarginalPrices + self.context.logger.info(f"Prices: {prices}\n") + if prices is None: return 0, 0 tokens_traded = [int(bet_per_token / prices[i]) for i in range(BINARY_N_SLOTS)] + self.context.logger.info(f"Tokens traded: {tokens_traded}\n") # get the shares for the answer that the service has selected selected_shares = tokens_traded.pop(vote) + self.context.logger.info(f"Selected shares: {selected_shares}\n") # get the shares for the opposite answer other_shares = tokens_traded.pop() + self.context.logger.info(f"Other shares: {other_shares}\n") # get the number of tokens in the pool for the answer that the service has selected selected_type_tokens_in_pool = token_amounts.pop(vote) + self.context.logger.info(f"Selected type tokens in pool: {selected_type_tokens_in_pool}\n") # get the number of tokens in the pool for the opposite answer other_tokens_in_pool = token_amounts.pop() + self.context.logger.info(f"Other tokens in pool: {other_tokens_in_pool}\n") # the OMEN market then trades the opposite tokens to the tokens of the answer that has been selected, # preserving the balance of the pool # here we calculate the number of shares that we get after trading the tokens for the opposite answer tokens_remaining_in_pool = int(k / (other_tokens_in_pool + other_shares)) + self.context.logger.info(f"Tokens remaining in pool: {tokens_remaining_in_pool}\n") + swapped_shares = selected_type_tokens_in_pool - tokens_remaining_in_pool + self.context.logger.info(f"Swapped shares: {swapped_shares}\n") # calculate the resulting number of shares if the service would take that position num_shares = selected_shares + swapped_shares + self.context.logger.info(f"Number of shares: {num_shares}\n") + # calculate the available number of shares price = prices[vote] - available_shares = int(selected_type_tokens_in_pool * price) + self.context.logger.info(f"Price: {prices[vote]}\n") - self.context.logger.info( - f"Token amounts: {token_amounts}\n" - f"k: {k}\n" - f"Bet per token: {bet_per_token}\n" - f"Prices: {prices}\n" - f"Tokens traded: {tokens_traded}\n" - f"Selected shares: {selected_shares}\n" - f"Other shares: {other_shares}\n" - f"Selected type tokens in pool: {selected_type_tokens_in_pool}\n" - f"Other tokens in pool: {other_tokens_in_pool}\n" - f"Tokens remaining in pool: {tokens_remaining_in_pool}\n" - f"Swapped shares: {swapped_shares}\n" - f"Number of shares: {num_shares}\n" - f"Price: {price[vote]}\n" - f"Available shares: {available_shares}\n" - ) + available_shares = int(selected_type_tokens_in_pool * price) + self.context.logger.info(f"Available shares: {available_shares}\n") return num_shares, available_shares diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 40b4aff71..296aff1bd 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiato4qxnc2kjjdtttvqdna7dp4c5evlb6cus7h6eci7tj73tqnpey behaviours/bet_placement.py: bafybeifwwvvwh4qgf3jkyvza4wfvjv63il2xewsklsjtpyanp23y6hg2aa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeih7a4s2c67q3bogmegk7okbebzhhanprw5u3qncvzlks2ilvzlcje + behaviours/decision_receive.py: bafybeigxqbgxn7ixrzlabdm5ae4lba46qkmexjqtwkxm5l76356orlbzna behaviours/decision_request.py: bafybeidlyl2ojmpfs2zkewoacraya2cbampo4ynqbqaocsoq7v2nif3ahi behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeigzsx4wyov3ehfvdjmo2d7yimss4p7mbkopkqyr4gryxpa5rpv6ku diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index e93ca5742..871d35025 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeidkamza7zxyk43tm3otxaex3bwqzclim6mxydyfobrpat356nvmii -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifffirzbbfxo5b4efmk77b5m6kzvxrco46by2pmdjq7gwxpkocaem +- valory/decision_maker_abci:0.1.0:bafybeib4lim2wzczsxb6ycva6rwxzx3hh4njvnfgcn74gsaxlatsbaebhq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiakesbetu43ehxojowietwaogihpaj5sr3uvgcstqdlvlrehtqxfy behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index fe4a37c06..5772e35c7 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeidkamza7zxyk43tm3otxaex3bwqzclim6mxydyfobrpat356nvmii +- valory/decision_maker_abci:0.1.0:bafybeib4lim2wzczsxb6ycva6rwxzx3hh4njvnfgcn74gsaxlatsbaebhq behaviours: main: args: {} From 1a9acf2fed0d0681eefb88ab5d853cf2bf48d9f5 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 4 Oct 2023 19:01:10 +0200 Subject: [PATCH 04/79] feat: Add mech_price to potential_net_profit calculation --- packages/packages.json | 10 +-- packages/valory/agents/trader/aea-config.yaml | 6 +- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 63 ++++++++++++++----- .../skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 +- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 60 insertions(+), 29 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 1bc0068f8..a2e34684a 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeib4lim2wzczsxb6ycva6rwxzx3hh4njvnfgcn74gsaxlatsbaebhq", - "skill/valory/trader_abci/0.1.0": "bafybeifjvi4tae3zxn4qql3wb54itp6xpqt2oywyqsng47tktfovmeu3su", + "skill/valory/decision_maker_abci/0.1.0": "bafybeibqdpkmfzjzhw6j2utfe47cikthcfyftkbg5f4kyd6x3t726wonvi", + "skill/valory/trader_abci/0.1.0": "bafybeiecic7l3mbvgxnh6yamkkfwyanc7ttkw4ii43s2dn2jc7uwto5aga", "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", - "agent/valory/trader/0.1.0": "bafybeichr3c3cgnujsphppmcslyl3rfurmmwg5exbea6b2ybb2rio2slry", - "service/valory/trader/0.1.0": "bafybeidrp6xlogk26d7z37b2jmqkby4yugiceydcuwh4eh2pnkyq5cfdz4", + "agent/valory/trader/0.1.0": "bafybeibyvydrywe2x7gsjjvgwejmidupyacclb46sseffleqbul5daslue", + "service/valory/trader/0.1.0": "bafybeiadk3dluozs6kwenzrnvxe6fr5anifysdrnebliize5cjn67ud7ny", "contract/valory/erc20/0.1.0": "bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiakesbetu43ehxojowietwaogihpaj5sr3uvgcstqdlvlrehtqxfy", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihfk6ckzpjjbugtklmfnrk43xvpa36g6wtc5lvlcru5iw3augky4q", "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", "contract/valory/realitio/0.1.0": "bafybeiewpazpi2wgixmiu64kauwn7qes3xzphqid4pxvznm2himv4tciee", "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 818a7e2d4..e0d43d7cd 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiakesbetu43ehxojowietwaogihpaj5sr3uvgcstqdlvlrehtqxfy +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihfk6ckzpjjbugtklmfnrk43xvpa36g6wtc5lvlcru5iw3augky4q - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeib4lim2wzczsxb6ycva6rwxzx3hh4njvnfgcn74gsaxlatsbaebhq -- valory/trader_abci:0.1.0:bafybeifjvi4tae3zxn4qql3wb54itp6xpqt2oywyqsng47tktfovmeu3su +- valory/decision_maker_abci:0.1.0:bafybeibqdpkmfzjzhw6j2utfe47cikthcfyftkbg5f4kyd6x3t726wonvi +- valory/trader_abci:0.1.0:bafybeiecic7l3mbvgxnh6yamkkfwyanc7ttkw4ii43s2dn2jc7uwto5aga default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index d0e75ec9f..30e74ab02 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeichr3c3cgnujsphppmcslyl3rfurmmwg5exbea6b2ybb2rio2slry +agent: valory/trader:0.1.0:bafybeibyvydrywe2x7gsjjvgwejmidupyacclb46sseffleqbul5daslue number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index b90f9da8f..4cc572f19 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -82,6 +82,16 @@ def request_id(self, request_id: Union[str, int]) -> None: msg = f"Request id {request_id} is not a valid integer!" self.context.logger.error(msg) + @property + def mech_price(self) -> int: + """Get the mech price.""" + return self._mech_price + + @mech_price.setter + def mech_price(self, price: int) -> None: + """Set the mech price.""" + self._mech_price = price + @property def response_hex(self) -> str: """Get the hash of the response data.""" @@ -230,71 +240,85 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] # calculate the pool's k (x*y=k) token_amounts = bet.outcomeTokenAmounts - self.context.logger.info(f"Token amounts: {token_amounts}\n") + self.context.logger.info(f"Token amounts: {[x/(10**18) for x in token_amounts]}") if token_amounts is None: return 0, 0 k = prod(token_amounts) - self.context.logger.info(f"k: {k}\n") + self.context.logger.info(f"k: {k}") # the OMEN market trades an equal amount of the investment to each of the tokens in the pool # here we calculate the bet amount per pool's token bet_per_token = net_bet_amount / BINARY_N_SLOTS - self.context.logger.info(f"Bet per token: {bet_per_token}\n") + self.context.logger.info(f"Bet per token: {bet_per_token/(10**18)}") # calculate the number of the traded tokens prices = bet.outcomeTokenMarginalPrices - self.context.logger.info(f"Prices: {prices}\n") + self.context.logger.info(f"Prices: {prices}") if prices is None: return 0, 0 tokens_traded = [int(bet_per_token / prices[i]) for i in range(BINARY_N_SLOTS)] - self.context.logger.info(f"Tokens traded: {tokens_traded}\n") + self.context.logger.info(f"Tokens traded: {[x/(10**18) for x in tokens_traded]}") # get the shares for the answer that the service has selected selected_shares = tokens_traded.pop(vote) - self.context.logger.info(f"Selected shares: {selected_shares}\n") + self.context.logger.info(f"Selected shares: {selected_shares/(10**18)}") # get the shares for the opposite answer other_shares = tokens_traded.pop() - self.context.logger.info(f"Other shares: {other_shares}\n") + self.context.logger.info(f"Other shares: {other_shares/(10**18)}") # get the number of tokens in the pool for the answer that the service has selected selected_type_tokens_in_pool = token_amounts.pop(vote) - self.context.logger.info(f"Selected type tokens in pool: {selected_type_tokens_in_pool}\n") + self.context.logger.info(f"Selected type tokens in pool: {selected_type_tokens_in_pool/(10**18)}") # get the number of tokens in the pool for the opposite answer other_tokens_in_pool = token_amounts.pop() - self.context.logger.info(f"Other tokens in pool: {other_tokens_in_pool}\n") + self.context.logger.info(f"Other tokens in pool: {other_tokens_in_pool/(10**18)}") # the OMEN market then trades the opposite tokens to the tokens of the answer that has been selected, # preserving the balance of the pool # here we calculate the number of shares that we get after trading the tokens for the opposite answer tokens_remaining_in_pool = int(k / (other_tokens_in_pool + other_shares)) - self.context.logger.info(f"Tokens remaining in pool: {tokens_remaining_in_pool}\n") + self.context.logger.info(f"Tokens remaining in pool: {tokens_remaining_in_pool/(10**18)}") swapped_shares = selected_type_tokens_in_pool - tokens_remaining_in_pool - self.context.logger.info(f"Swapped shares: {swapped_shares}\n") + self.context.logger.info(f"Swapped shares: {swapped_shares/(10**18)}") # calculate the resulting number of shares if the service would take that position num_shares = selected_shares + swapped_shares - self.context.logger.info(f"Number of shares: {num_shares}\n") + self.context.logger.info(f"Number of shares: {num_shares/(10**18)}") # calculate the available number of shares price = prices[vote] - self.context.logger.info(f"Price: {prices[vote]}\n") + self.context.logger.info(f"Price: {prices[vote]}") available_shares = int(selected_type_tokens_in_pool * price) - self.context.logger.info(f"Available shares: {available_shares}\n") + self.context.logger.info(f"Available shares: {available_shares/(10**18)}") return num_shares, available_shares + def _get_mech_price(self) -> WaitableConditionType: + """Get the price of the mech request.""" + result = yield from self._mech_contract_interact( + "get_price", "price", get_name(DecisionReceiveBehaviour.mech_price) + ) + return result + def _is_profitable(self, confidence: float, vote: int) -> bool: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet + self.context.logger.info(f"Sampled bet: {bet}") + bet_amount = self.params.get_bet_amount(confidence) + self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") + self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") + net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet.fee)) + self.context.logger.info(f"Net bet amount: {net_bet_amount/(10**18)}") num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) bet_threshold = self.params.bet_threshold + self.context.logger.info(f"Bet threshold: {bet_threshold/(10**18)}") if bet_threshold <= 0: self.context.logger.warning( @@ -303,11 +327,18 @@ def _is_profitable(self, confidence: float, vote: int) -> bool: ) bet_threshold = 0 - potential_net_profit = num_shares - net_bet_amount - bet_threshold + yield from self.wait_for_condition_with_sleep(self._get_mech_price) + self.context.logger.info(f"Mech price: {self.mech_price/(10**18)}") + potential_net_profit = num_shares - net_bet_amount - self.mech_price - bet_threshold + self.context.logger.info(f"Potential net profit: {potential_net_profit/(10**18)}") is_profitable = potential_net_profit >= 0 and num_shares <= available_shares + self.context.logger.info(f"Is profitable: {is_profitable}") shares_out = self.wei_to_native(num_shares) + self.context.logger.info(f"Shares out: {shares_out}") available_in = self.wei_to_native(available_shares) + self.context.logger.info(f"Available in: {available_in}") shares_out_of = f"{shares_out} / {available_in}" + self.context.logger.info(f"Shares out of: {shares_out_of}") self.context.logger.info( f"The current liquidity of the market is {bet.scaledLiquidityMeasure} xDAI. " f"The potential net profit is {self.wei_to_native(potential_net_profit)} xDAI " @@ -324,7 +355,7 @@ def async_act(self) -> Generator: vote, confidence = yield from self._get_decision() is_profitable = None if vote is not None and confidence is not None: - is_profitable = self._is_profitable(confidence, vote) + is_profitable = yield from self._is_profitable(confidence, vote) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 296aff1bd..7de5960f0 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiato4qxnc2kjjdtttvqdna7dp4c5evlb6cus7h6eci7tj73tqnpey behaviours/bet_placement.py: bafybeifwwvvwh4qgf3jkyvza4wfvjv63il2xewsklsjtpyanp23y6hg2aa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeigxqbgxn7ixrzlabdm5ae4lba46qkmexjqtwkxm5l76356orlbzna + behaviours/decision_receive.py: bafybeih25wxei6vreg6s46zetftxulr7dor5vua4q5eclpudaianyesbhq behaviours/decision_request.py: bafybeidlyl2ojmpfs2zkewoacraya2cbampo4ynqbqaocsoq7v2nif3ahi behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeigzsx4wyov3ehfvdjmo2d7yimss4p7mbkopkqyr4gryxpa5rpv6ku diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 871d35025..da1046379 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeib4lim2wzczsxb6ycva6rwxzx3hh4njvnfgcn74gsaxlatsbaebhq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiakesbetu43ehxojowietwaogihpaj5sr3uvgcstqdlvlrehtqxfy +- valory/decision_maker_abci:0.1.0:bafybeibqdpkmfzjzhw6j2utfe47cikthcfyftkbg5f4kyd6x3t726wonvi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihfk6ckzpjjbugtklmfnrk43xvpa36g6wtc5lvlcru5iw3augky4q behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 5772e35c7..607dcb033 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeib4lim2wzczsxb6ycva6rwxzx3hh4njvnfgcn74gsaxlatsbaebhq +- valory/decision_maker_abci:0.1.0:bafybeibqdpkmfzjzhw6j2utfe47cikthcfyftkbg5f4kyd6x3t726wonvi behaviours: main: args: {} From e82013704d4cbeea95e03c800c21677b236e7a31 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 5 Oct 2023 12:15:05 +0200 Subject: [PATCH 05/79] refactor: Make trading strategy an environment variable --- packages/packages.json | 10 +-- packages/valory/agents/trader/aea-config.yaml | 7 +- packages/valory/services/trader/service.yaml | 3 +- .../behaviours/bet_placement.py | 4 +- .../behaviours/decision_receive.py | 71 ++++++++++++++++--- .../skills/decision_maker_abci/models.py | 34 ++++++--- .../skills/decision_maker_abci/payloads.py | 1 + .../skills/decision_maker_abci/skill.yaml | 13 ++-- .../skills/decision_maker_abci/states/base.py | 5 ++ .../states/decision_receive.py | 1 + packages/valory/skills/trader_abci/skill.yaml | 5 +- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 12 files changed, 120 insertions(+), 36 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index a2e34684a..5c8c976ea 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeibqdpkmfzjzhw6j2utfe47cikthcfyftkbg5f4kyd6x3t726wonvi", - "skill/valory/trader_abci/0.1.0": "bafybeiecic7l3mbvgxnh6yamkkfwyanc7ttkw4ii43s2dn2jc7uwto5aga", + "skill/valory/decision_maker_abci/0.1.0": "bafybeigqpadxmtivc7qwyfy2d7gnaam54fy4tgpf2v36ccz4u5smctjsby", + "skill/valory/trader_abci/0.1.0": "bafybeig4gvatwjyqj45tvyppdun6eqnxnxkgo25pbsknlaas5ucap4sale", "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", - "agent/valory/trader/0.1.0": "bafybeibyvydrywe2x7gsjjvgwejmidupyacclb46sseffleqbul5daslue", - "service/valory/trader/0.1.0": "bafybeiadk3dluozs6kwenzrnvxe6fr5anifysdrnebliize5cjn67ud7ny", + "agent/valory/trader/0.1.0": "bafybeiantvy324mlx73shhbb2s5n7xf7k5wgptksxh53j2zsukfvdcztzq", + "service/valory/trader/0.1.0": "bafybeid5rozf2yngngqii5l7tpfe5h7pqd4ujmgs7uspctevnvhrba6vey", "contract/valory/erc20/0.1.0": "bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihfk6ckzpjjbugtklmfnrk43xvpa36g6wtc5lvlcru5iw3augky4q", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeidoi32fu5odle4i5hfbzcvfksjuzsadteswa4vq2a4cyp7oq2xqfi", "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", "contract/valory/realitio/0.1.0": "bafybeiewpazpi2wgixmiu64kauwn7qes3xzphqid4pxvznm2himv4tciee", "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index e0d43d7cd..b3ccd6fe9 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihfk6ckzpjjbugtklmfnrk43xvpa36g6wtc5lvlcru5iw3augky4q +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidoi32fu5odle4i5hfbzcvfksjuzsadteswa4vq2a4cyp7oq2xqfi - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeibqdpkmfzjzhw6j2utfe47cikthcfyftkbg5f4kyd6x3t726wonvi -- valory/trader_abci:0.1.0:bafybeiecic7l3mbvgxnh6yamkkfwyanc7ttkw4ii43s2dn2jc7uwto5aga +- valory/decision_maker_abci:0.1.0:bafybeigqpadxmtivc7qwyfy2d7gnaam54fy4tgpf2v36ccz4u5smctjsby +- valory/trader_abci:0.1.0:bafybeig4gvatwjyqj45tvyppdun6eqnxnxkgo25pbsknlaas5ucap4sale default_ledger: ethereum required_ledgers: - ethereum @@ -162,6 +162,7 @@ models: average_block_time: ${int:5} abt_error_mult: ${int:5} mech_agent_address: ${str:0xff82123dfb52ab75c417195c5fdb87630145ae81} + trading_strategy: ${str:bet_amount_per_conf_threshold} bet_amount_per_threshold: 0.0: ${int:0} 0.1: ${int:0} diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 30e74ab02..bb6ffe373 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeibyvydrywe2x7gsjjvgwejmidupyacclb46sseffleqbul5daslue +agent: valory/trader:0.1.0:bafybeiantvy324mlx73shhbb2s5n7xf7k5wgptksxh53j2zsukfvdcztzq number_of_agents: 4 deployment: {} --- @@ -78,6 +78,7 @@ type: skill average_block_time: ${ABT:int:5} abt_error_mult: ${ABT_ERROR_MULT:int:5} mech_agent_address: ${MECH_AGENT_ADDRESS:str:0xff82123dfb52ab75c417195c5fdb87630145ae81} + trading_strategy: ${TRADING_STRATEGY:str:bet_amount_per_conf_threshold} bet_amount_per_threshold: &id004 0.0: ${BET_AMOUNT_PER_THRESHOLD_000:int:0} 0.1: ${BET_AMOUNT_PER_THRESHOLD_010:int:0} diff --git a/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py b/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py index fa7b027f7..d4c06fa62 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py @@ -73,7 +73,9 @@ def market_maker_contract_address(self) -> str: @property def investment_amount(self) -> int: """Get the investment amount of the bet.""" - return self.params.get_bet_amount(self.synchronized_data.confidence) + return self.params.get_bet_amount( + self.params.trading_strategy, self.synchronized_data.win_probability, self.synchronized_data.confidence + ) @property def w_xdai_deficit(self) -> int: diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 4cc572f19..684a04216 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -21,6 +21,7 @@ from math import prod from typing import Any, Generator, Optional, Tuple, Union +from packages.valory.contracts.erc20.contract import ERC20 from packages.valory.contracts.mech.contract import Mech from packages.valory.protocols.contract_api import ContractApiMessage @@ -31,6 +32,7 @@ WaitableConditionType, remove_fraction_wei, ) +from packages.valory.skills.decision_maker_abci.behaviours.bet_placement import WXDAI from packages.valory.skills.decision_maker_abci.models import ( MechInteractionResponse, MechResponseSpecs, @@ -82,6 +84,16 @@ def request_id(self, request_id: Union[str, int]) -> None: msg = f"Request id {request_id} is not a valid integer!" self.context.logger.error(msg) + @property + def collateral_token(self) -> str: + """Get the contract address of the token that the market maker supports.""" + return self.synchronized_data.sampled_bet.collateralToken + + @property + def is_wxdai(self) -> bool: + """Get whether the collateral address is wxDAI.""" + return self.collateral_token.lower() == WXDAI.lower() + @property def mech_price(self) -> int: """Get the mech price.""" @@ -215,8 +227,8 @@ def _get_response(self) -> WaitableConditionType: def _get_decision( self, - ) -> Generator[None, None, Tuple[Optional[int], Optional[float]]]: - """Get the vote and it's confidence.""" + ) -> Generator[None, None, Tuple[Optional[int], Optional[float], Optional[float]]]: + """Get vote, win probability and confidence.""" for step in ( self._get_block_number, self._get_request_id, @@ -230,9 +242,9 @@ def _get_decision( self.context.logger.error( f"There was an error on the mech's response: {self.mech_response.error}" ) - return None, None + return None, None, None - return self.mech_response.result.vote, self.mech_response.result.confidence + return self.mech_response.result.vote, self.mech_response.result.win_probability, self.mech_response.result.confidence def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int]: """Calculate the claimed shares. This calculation only works for binary markets.""" @@ -304,13 +316,53 @@ def _get_mech_price(self) -> WaitableConditionType: "get_price", "price", get_name(DecisionReceiveBehaviour.mech_price) ) return result + + def _collateral_amount_info(self, amount: int) -> str: + """Get a description of the collateral token's amount.""" + return ( + f"{self.wei_to_native(amount)} wxDAI" + if self.is_wxdai + else f"{amount} WEI of the collateral token with address {self.collateral_token}" + ) + + def _check_balance(self) -> WaitableConditionType: + """Check the safe's balance.""" + response_msg = yield from self.get_contract_api_response( + performative=ContractApiMessage.Performative.GET_RAW_TRANSACTION, # type: ignore + contract_address=self.collateral_token, + contract_id=str(ERC20.contract_id), + contract_callable="check_balance", + account=self.synchronized_data.safe_contract_address, + ) + if response_msg.performative != ContractApiMessage.Performative.RAW_TRANSACTION: + self.context.logger.error( + f"Could not calculate the balance of the safe: {response_msg}" + ) + return False + + token = response_msg.raw_transaction.body.get("token", None) + wallet = response_msg.raw_transaction.body.get("wallet", None) + if token is None or wallet is None: + self.context.logger.error( + f"Something went wrong while trying to get the balance of the safe: {response_msg}" + ) + return False - def _is_profitable(self, confidence: float, vote: int) -> bool: + self.token_balance = int(token) + self.wallet_balance = int(wallet) + + native = self.wei_to_native(self.wallet_balance) + collateral = self._collateral_amount_info(self.token_balance) + self.context.logger.info(f"The safe has {native} xDAI and {collateral}.") + return True + + def _is_profitable(self, vote: int, win_probability: float, confidence: float) -> bool: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet self.context.logger.info(f"Sampled bet: {bet}") - - bet_amount = self.params.get_bet_amount(confidence) + strategy = self.params.trading_strategy + self.context.logger.info(f"Trading strategy: {strategy}") + bet_amount = self.params.get_bet_amount(strategy, win_probability, confidence) self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") @@ -352,14 +404,15 @@ def async_act(self) -> Generator: """Do the action.""" with self.context.benchmark_tool.measure(self.behaviour_id).local(): - vote, confidence = yield from self._get_decision() + vote, win_probability, confidence = yield from self._get_decision() is_profitable = None if vote is not None and confidence is not None: - is_profitable = yield from self._is_profitable(confidence, vote) + is_profitable = yield from self._is_profitable(vote, win_probability, confidence) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, vote, + win_probability, confidence, ) diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 412a0b62f..71791677f 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -92,6 +92,8 @@ class DecisionMakerParams(MarketManagerParams): def __init__(self, *args: Any, **kwargs: Any) -> None: """Initialize the parameters' object.""" self.mech_agent_address: str = self._ensure("mech_agent_address", kwargs, str) + # the trading strategy to use for placing bets + self.trading_strategy: str = self._ensure("trading_strategy", kwargs, str) # this is a mapping from the confidence of a bet's choice to the amount we are willing to bet self.bet_amount_per_threshold: Dict[float, int] = self._ensure( "bet_amount_per_threshold", kwargs, Dict[float, int] @@ -155,17 +157,26 @@ def slippage(self, slippage: float) -> None: ) self._slippage = slippage - def get_bet_amount(self, confidence: float) -> int: - """Get the bet amount given a prediction's confidence.""" - threshold = round(confidence, 1) - return self.bet_amount_per_threshold[threshold] - # def get_bet_amount(self, confidence: float) -> int: - # """Get the bet amount given a specified trading strategy.""" + # """Get the bet amount given a prediction's confidence.""" # threshold = round(confidence, 1) # return self.bet_amount_per_threshold[threshold] - - + + def get_bet_amount(self, strategy: str, win_probability: float, confidence: float) -> int: + """Get the bet amount given a specified trading strategy.""" + + if strategy == "bet_amount_per_conf_threshold": + self.context.logger.info(f"Used trading strategy: {strategy}") + threshold = round(confidence, 1) + return self.bet_amount_per_threshold[threshold] + elif strategy == "kelly_criterion": + self.context.logger.info(f"Used trading strategy: {strategy}") + threshold = round(confidence, 1) + return self.bet_amount_per_threshold[threshold] + # TODO: Implement Kelly Criterion + else: + raise ValueError(f"Invalid trading strategy: {strategy}") + class MechResponseSpecs(ApiSpecs): """A model that wraps ApiSpecs for the Mech's response specifications.""" @@ -209,6 +220,13 @@ def vote(self) -> Optional[int]: if self.p_no != self.p_yes: return int(self.p_no > self.p_yes) return None + + @property + def win_probability(self) -> Optional[float]: + """Return the probability estimation for winning with vote.""" + if self.p_no != self.p_yes: + return max(self.p_no, self.p_yes) + return None @dataclass diff --git a/packages/valory/skills/decision_maker_abci/payloads.py b/packages/valory/skills/decision_maker_abci/payloads.py index 7d03ac0d3..d7d455310 100644 --- a/packages/valory/skills/decision_maker_abci/payloads.py +++ b/packages/valory/skills/decision_maker_abci/payloads.py @@ -32,6 +32,7 @@ class DecisionReceivePayload(BaseTxPayload): is_profitable: Optional[bool] vote: Optional[int] + win_probability: Optional[float] confidence: Optional[float] diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 7de5960f0..acacea7da 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -13,9 +13,9 @@ fingerprint: __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky behaviours/base.py: bafybeiato4qxnc2kjjdtttvqdna7dp4c5evlb6cus7h6eci7tj73tqnpey - behaviours/bet_placement.py: bafybeifwwvvwh4qgf3jkyvza4wfvjv63il2xewsklsjtpyanp23y6hg2aa + behaviours/bet_placement.py: bafybeidulnzidcuxtmxyksgeetaczuzqwlcs6vqu6qn5fpxk4dbhhgenza behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeih25wxei6vreg6s46zetftxulr7dor5vua4q5eclpudaianyesbhq + behaviours/decision_receive.py: bafybeifdju7yjt7nzd74qwabdxp6a3z2a6qtvnrnltqsiqcbzbdw4fm6vy behaviours/decision_request.py: bafybeidlyl2ojmpfs2zkewoacraya2cbampo4ynqbqaocsoq7v2nif3ahi behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeigzsx4wyov3ehfvdjmo2d7yimss4p7mbkopkqyr4gryxpa5rpv6ku @@ -25,16 +25,16 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeie357butaav2hjvr2qyef2fwvgdsnfh6j2pt7ghmqoziayqjg6fna - payloads.py: bafybeic4iz6uxinqpaxnefkadnzaox23y7k57zawnnkeovplih36v5cchy + models.py: bafybeiblebmdiu7bhhy3tabw4yqptdh46yyuer3dymsksfwcedac5ix4ky + payloads.py: bafybeifyyngf3o4ch67gtdisjzqkhdghgjyw3zidr7wdjvguamk46jryf4 policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeihtbundd75a4wdk2d23smvdjlh7fsv42ff2cwwuwgkyyxjciobwca rounds.py: bafybeihopxmhzrpipc6r5x2vqf2tcixzuf5xdpqfsr7gr3n756n3ssft5q states/__init__.py: bafybeid23llnyp6j257dluxmrnztugo5llsrog7kua53hllyktz4dqhqoy - states/base.py: bafybeibx3kn2b3rovyiowjzpwhspjdbzyfroequg7zsjqsbdh5cyowu72a + states/base.py: bafybeidv7m33fzlqqpemokrjfvtgnehuhdietdznh4hnt7dcrrmmpd6rwu states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeiao747i4z7owk6dmwfuzdijag55m3ryj3nowfoggvczpgk3koza44 - states/decision_receive.py: bafybeifm3oyq2aji7f5yag6wpe4vr3ivi74pybdsk2jvmziiidx5nt7t4a + states/decision_receive.py: bafybeiamlxbuwce4c6cngrntu2uhsdlqgbvpk345htu2dnbgbb72bs4qgi states/decision_request.py: bafybeic7otc3hjb753svbmur3yyk6szahc25yii3x4w4vcnpfz6jwvacuu states/final_states.py: bafybeidiwhuyd5zm2cq7vhv2owcrxdpm7fnvn3db6p6tql4jz5hgpalflu states/handle_failed_tx.py: bafybeihewm2vernvhktuorljdupjqcg2p5vs6wvsira2d62wkoyo5xlzjm @@ -161,6 +161,7 @@ models: tx_timeout: 10.0 use_termination: false mech_agent_address: '0xff82123dfb52ab75c417195c5fdb87630145ae81' + trading_strategy: bet_amount_per_conf_threshold bet_amount_per_threshold: 0.0: 0 0.1: 0 diff --git a/packages/valory/skills/decision_maker_abci/states/base.py b/packages/valory/skills/decision_maker_abci/states/base.py index b84092b7d..ddcd0e41c 100644 --- a/packages/valory/skills/decision_maker_abci/states/base.py +++ b/packages/valory/skills/decision_maker_abci/states/base.py @@ -114,6 +114,11 @@ def vote(self) -> Optional[int]: """Get the bet's vote index.""" vote = self.db.get_strict("vote") return int(vote) if vote is not None else None + + @property + def win_probability(self) -> float: + """Get the vote's win probability.""" + return float(self.db.get_strict("win_probability")) @property def confidence(self) -> float: diff --git a/packages/valory/skills/decision_maker_abci/states/decision_receive.py b/packages/valory/skills/decision_maker_abci/states/decision_receive.py index 106d7d647..845cee1c1 100644 --- a/packages/valory/skills/decision_maker_abci/states/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/states/decision_receive.py @@ -44,6 +44,7 @@ class DecisionReceiveRound(CollectSameUntilThresholdRound): selection_key = ( get_name(SynchronizedData.is_profitable), get_name(SynchronizedData.vote), + get_name(SynchronizedData.win_probability), get_name(SynchronizedData.confidence), ) collection_key = get_name(SynchronizedData.participant_to_decision) diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index da1046379..4c18164e8 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeibqdpkmfzjzhw6j2utfe47cikthcfyftkbg5f4kyd6x3t726wonvi -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihfk6ckzpjjbugtklmfnrk43xvpa36g6wtc5lvlcru5iw3augky4q +- valory/decision_maker_abci:0.1.0:bafybeigqpadxmtivc7qwyfy2d7gnaam54fy4tgpf2v36ccz4u5smctjsby +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidoi32fu5odle4i5hfbzcvfksjuzsadteswa4vq2a4cyp7oq2xqfi behaviours: main: args: {} @@ -144,6 +144,7 @@ models: average_block_time: 5 abt_error_mult: 5 mech_agent_address: '0xff82123dfb52ab75c417195c5fdb87630145ae81' + trading_strategy: bet_amount_per_conf_threshold bet_amount_per_threshold: 0.0: 0 0.1: 0 diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 607dcb033..3a1786458 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeibqdpkmfzjzhw6j2utfe47cikthcfyftkbg5f4kyd6x3t726wonvi +- valory/decision_maker_abci:0.1.0:bafybeigqpadxmtivc7qwyfy2d7gnaam54fy4tgpf2v36ccz4u5smctjsby behaviours: main: args: {} From 54d93e27c286d46824673368218e10b2732a70b2 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 7 Oct 2023 19:40:11 +0200 Subject: [PATCH 06/79] WIP: Add odds and win probability as variables --- .../behaviours/bet_placement.py | 7 ++++++- .../behaviours/decision_receive.py | 17 +++++++++-------- .../valory/skills/decision_maker_abci/models.py | 9 ++++++++- .../skills/decision_maker_abci/payloads.py | 1 + .../skills/decision_maker_abci/states/base.py | 5 +++++ .../states/decision_receive.py | 1 + 6 files changed, 30 insertions(+), 10 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py b/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py index d4c06fa62..8fb0fd4f4 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py @@ -73,8 +73,13 @@ def market_maker_contract_address(self) -> str: @property def investment_amount(self) -> int: """Get the investment amount of the bet.""" + balance_sum = self.wallet_balance + self.token_balance return self.params.get_bet_amount( - self.params.trading_strategy, self.synchronized_data.win_probability, self.synchronized_data.confidence + balance_sum, + self.params.trading_strategy, + self.synchronized_data.odds, + self.synchronized_data.win_probability, + self.synchronized_data.confidence, ) @property diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 684a04216..a951831d0 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -244,7 +244,7 @@ def _get_decision( ) return None, None, None - return self.mech_response.result.vote, self.mech_response.result.win_probability, self.mech_response.result.confidence + return self.mech_response.result.vote, self.mech_response.result.odds, self.mech_response.result.win_probability, self.mech_response.result.confidence def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int]: """Calculate the claimed shares. This calculation only works for binary markets.""" @@ -356,13 +356,13 @@ def _check_balance(self) -> WaitableConditionType: self.context.logger.info(f"The safe has {native} xDAI and {collateral}.") return True - def _is_profitable(self, vote: int, win_probability: float, confidence: float) -> bool: + def _is_profitable(self, vote: int, odds: float, win_probability: float, confidence: float) -> bool: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet self.context.logger.info(f"Sampled bet: {bet}") - strategy = self.params.trading_strategy - self.context.logger.info(f"Trading strategy: {strategy}") - bet_amount = self.params.get_bet_amount(strategy, win_probability, confidence) + self.context.logger.info(f"Trading strategy: {self.params.trading_strategy}") + balance_sum = self.wallet_balance + self.token_balance + bet_amount = self.params.get_bet_amount(balance_sum, self.params.trading_strategy, odds, win_probability, confidence) self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") @@ -404,14 +404,15 @@ def async_act(self) -> Generator: """Do the action.""" with self.context.benchmark_tool.measure(self.behaviour_id).local(): - vote, win_probability, confidence = yield from self._get_decision() + vote, odds, win_probability, confidence = yield from self._get_decision() is_profitable = None - if vote is not None and confidence is not None: - is_profitable = yield from self._is_profitable(vote, win_probability, confidence) + if vote is not None and confidence is not None and odds is not None and win_probability is not None: + is_profitable = yield from self._is_profitable(vote, odds, win_probability, confidence) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, vote, + odds, win_probability, confidence, ) diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 71791677f..b268cbdb7 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -162,7 +162,7 @@ def slippage(self, slippage: float) -> None: # threshold = round(confidence, 1) # return self.bet_amount_per_threshold[threshold] - def get_bet_amount(self, strategy: str, win_probability: float, confidence: float) -> int: + def get_bet_amount(self, balance_sum: int, strategy: str, odds: float, win_probability: float, confidence: float) -> int: """Get the bet amount given a specified trading strategy.""" if strategy == "bet_amount_per_conf_threshold": @@ -221,6 +221,13 @@ def vote(self) -> Optional[int]: return int(self.p_no > self.p_yes) return None + @property + def odds(self) -> Optional[float]: + """Return the odds estimation for winning with vote.""" + if self.p_no != self.p_yes: + return self.p_no / self.p_yes + return None + @property def win_probability(self) -> Optional[float]: """Return the probability estimation for winning with vote.""" diff --git a/packages/valory/skills/decision_maker_abci/payloads.py b/packages/valory/skills/decision_maker_abci/payloads.py index d7d455310..89491fa1f 100644 --- a/packages/valory/skills/decision_maker_abci/payloads.py +++ b/packages/valory/skills/decision_maker_abci/payloads.py @@ -32,6 +32,7 @@ class DecisionReceivePayload(BaseTxPayload): is_profitable: Optional[bool] vote: Optional[int] + odds: Optional[float] win_probability: Optional[float] confidence: Optional[float] diff --git a/packages/valory/skills/decision_maker_abci/states/base.py b/packages/valory/skills/decision_maker_abci/states/base.py index ddcd0e41c..e879401d4 100644 --- a/packages/valory/skills/decision_maker_abci/states/base.py +++ b/packages/valory/skills/decision_maker_abci/states/base.py @@ -115,6 +115,11 @@ def vote(self) -> Optional[int]: vote = self.db.get_strict("vote") return int(vote) if vote is not None else None + @property + def odds(self) -> float: + """Get the vote's odds.""" + return float(self.db.get_strict("odds")) + @property def win_probability(self) -> float: """Get the vote's win probability.""" diff --git a/packages/valory/skills/decision_maker_abci/states/decision_receive.py b/packages/valory/skills/decision_maker_abci/states/decision_receive.py index 845cee1c1..baf618981 100644 --- a/packages/valory/skills/decision_maker_abci/states/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/states/decision_receive.py @@ -44,6 +44,7 @@ class DecisionReceiveRound(CollectSameUntilThresholdRound): selection_key = ( get_name(SynchronizedData.is_profitable), get_name(SynchronizedData.vote), + get_name(SynchronizedData.odds), get_name(SynchronizedData.win_probability), get_name(SynchronizedData.confidence), ) From 1ee89774e7baad53f96dc1d11f63965a8191f0c6 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Tue, 10 Oct 2023 19:24:24 +0200 Subject: [PATCH 07/79] feat: Add kelly bet amount calculation --- packages/packages.json | 10 +++---- packages/valory/agents/trader/aea-config.yaml | 6 ++--- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 26 +++++++++++++++++-- .../skills/decision_maker_abci/skill.yaml | 12 ++++----- packages/valory/skills/trader_abci/skill.yaml | 4 +-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 42 insertions(+), 20 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 5c8c976ea..dc6ef5561 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeigqpadxmtivc7qwyfy2d7gnaam54fy4tgpf2v36ccz4u5smctjsby", - "skill/valory/trader_abci/0.1.0": "bafybeig4gvatwjyqj45tvyppdun6eqnxnxkgo25pbsknlaas5ucap4sale", + "skill/valory/decision_maker_abci/0.1.0": "bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi", + "skill/valory/trader_abci/0.1.0": "bafybeidmfy4w6z2mf6ggunwzqwxsxrkc6vwup7wpwddeufv6jalame7u5a", "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", - "agent/valory/trader/0.1.0": "bafybeiantvy324mlx73shhbb2s5n7xf7k5wgptksxh53j2zsukfvdcztzq", - "service/valory/trader/0.1.0": "bafybeid5rozf2yngngqii5l7tpfe5h7pqd4ujmgs7uspctevnvhrba6vey", + "agent/valory/trader/0.1.0": "bafybeih7xlnlz3oejsa7vyj5sxsov42nd3jbf4rkmm6ziln6xbdda75kxi", + "service/valory/trader/0.1.0": "bafybeihr3t6mhuad3nqiyjq4ojo6qzjbffe7ukakduwg6oon3yotdfxbnm", "contract/valory/erc20/0.1.0": "bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeidoi32fu5odle4i5hfbzcvfksjuzsadteswa4vq2a4cyp7oq2xqfi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi", "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", "contract/valory/realitio/0.1.0": "bafybeiewpazpi2wgixmiu64kauwn7qes3xzphqid4pxvznm2himv4tciee", "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index b3ccd6fe9..22aeb4725 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidoi32fu5odle4i5hfbzcvfksjuzsadteswa4vq2a4cyp7oq2xqfi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeigqpadxmtivc7qwyfy2d7gnaam54fy4tgpf2v36ccz4u5smctjsby -- valory/trader_abci:0.1.0:bafybeig4gvatwjyqj45tvyppdun6eqnxnxkgo25pbsknlaas5ucap4sale +- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi +- valory/trader_abci:0.1.0:bafybeidmfy4w6z2mf6ggunwzqwxsxrkc6vwup7wpwddeufv6jalame7u5a default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index bb6ffe373..340b32079 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiantvy324mlx73shhbb2s5n7xf7k5wgptksxh53j2zsukfvdcztzq +agent: valory/trader:0.1.0:bafybeih7xlnlz3oejsa7vyj5sxsov42nd3jbf4rkmm6ziln6xbdda75kxi number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index a951831d0..9d788b75d 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -245,8 +245,22 @@ def _get_decision( return None, None, None return self.mech_response.result.vote, self.mech_response.result.odds, self.mech_response.result.win_probability, self.mech_response.result.confidence + + def _get_kelly_bet_amount(self, x, y, p, c, b) -> int: + """Calculate the Kelly bet amount.""" + if b == 0 or x**2 == y**2: + self.context.logger.error( + "Could not calculate Kelly bet amount. Either bankroll is 0 or pool token amount is distributed as x^2 - y^2 = 0:\n" + f"Bankroll: {b}\n" + f"Pool token amounts: {x}, {y}" + ) + return None + kelly_bet_amount = (-4*x**2*y + b*y**2*p + 2*b*x*y*p + b*x**2*p - 2*b*x**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p - 2*b*x*y*p - b*x**2*p + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p - 4*b*x**2*y*p + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) + self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount: {kelly_bet_amount}") + return int(kelly_bet_amount) - def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int]: + + def _calc_binary_shares(self, net_bet_amount: int, win_probability: float, confidence: float, vote: int) -> Tuple[int, int]: """Calculate the claimed shares. This calculation only works for binary markets.""" bet = self.synchronized_data.sampled_bet @@ -288,6 +302,14 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] other_tokens_in_pool = token_amounts.pop() self.context.logger.info(f"Other tokens in pool: {other_tokens_in_pool/(10**18)}") + bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade + kelly_bet_amount = self._get_kelly_bet_amount( + selected_shares, other_shares, win_probability, confidence, bankroll + ) + self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") + self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") + + # the OMEN market then trades the opposite tokens to the tokens of the answer that has been selected, # preserving the balance of the pool # here we calculate the number of shares that we get after trading the tokens for the opposite answer @@ -368,7 +390,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet.fee)) self.context.logger.info(f"Net bet amount: {net_bet_amount/(10**18)}") - num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) + num_shares, available_shares = self._calc_binary_shares(net_bet_amount, win_probability, confidence, vote) bet_threshold = self.params.bet_threshold self.context.logger.info(f"Bet threshold: {bet_threshold/(10**18)}") diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index acacea7da..d9e55b7ab 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -13,9 +13,9 @@ fingerprint: __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky behaviours/base.py: bafybeiato4qxnc2kjjdtttvqdna7dp4c5evlb6cus7h6eci7tj73tqnpey - behaviours/bet_placement.py: bafybeidulnzidcuxtmxyksgeetaczuzqwlcs6vqu6qn5fpxk4dbhhgenza + behaviours/bet_placement.py: bafybeiaf72izdvhqm27dqf6brxotxx6ckkah6zu4ndik2lu6i7o2sscsnq behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeifdju7yjt7nzd74qwabdxp6a3z2a6qtvnrnltqsiqcbzbdw4fm6vy + behaviours/decision_receive.py: bafybeid2zzfcwyxb4x26no76pz6a7u677eid3bqpmzk6cgym346mbids5q behaviours/decision_request.py: bafybeidlyl2ojmpfs2zkewoacraya2cbampo4ynqbqaocsoq7v2nif3ahi behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeigzsx4wyov3ehfvdjmo2d7yimss4p7mbkopkqyr4gryxpa5rpv6ku @@ -25,16 +25,16 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeiblebmdiu7bhhy3tabw4yqptdh46yyuer3dymsksfwcedac5ix4ky - payloads.py: bafybeifyyngf3o4ch67gtdisjzqkhdghgjyw3zidr7wdjvguamk46jryf4 + models.py: bafybeiht22vnshzf27nkdj6jxtbhac6uf43o7dhuiey67ua4fwfjgwlrgi + payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeihtbundd75a4wdk2d23smvdjlh7fsv42ff2cwwuwgkyyxjciobwca rounds.py: bafybeihopxmhzrpipc6r5x2vqf2tcixzuf5xdpqfsr7gr3n756n3ssft5q states/__init__.py: bafybeid23llnyp6j257dluxmrnztugo5llsrog7kua53hllyktz4dqhqoy - states/base.py: bafybeidv7m33fzlqqpemokrjfvtgnehuhdietdznh4hnt7dcrrmmpd6rwu + states/base.py: bafybeicbhqfspe7gnhrgabpy5ijbvkuxwjruyk3fiep64t3sjv7xvbxzry states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeiao747i4z7owk6dmwfuzdijag55m3ryj3nowfoggvczpgk3koza44 - states/decision_receive.py: bafybeiamlxbuwce4c6cngrntu2uhsdlqgbvpk345htu2dnbgbb72bs4qgi + states/decision_receive.py: bafybeifcrtxrcvafqc6cexh7tobzedlqufp4dionb7hvc27y37gniofax4 states/decision_request.py: bafybeic7otc3hjb753svbmur3yyk6szahc25yii3x4w4vcnpfz6jwvacuu states/final_states.py: bafybeidiwhuyd5zm2cq7vhv2owcrxdpm7fnvn3db6p6tql4jz5hgpalflu states/handle_failed_tx.py: bafybeihewm2vernvhktuorljdupjqcg2p5vs6wvsira2d62wkoyo5xlzjm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 4c18164e8..60614effa 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeigqpadxmtivc7qwyfy2d7gnaam54fy4tgpf2v36ccz4u5smctjsby -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidoi32fu5odle4i5hfbzcvfksjuzsadteswa4vq2a4cyp7oq2xqfi +- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 3a1786458..14ea45131 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeigqpadxmtivc7qwyfy2d7gnaam54fy4tgpf2v36ccz4u5smctjsby +- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi behaviours: main: args: {} From 6bb29a999897ef777c8905f78ae0b074674b7c34 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Tue, 10 Oct 2023 20:01:57 +0200 Subject: [PATCH 08/79] chore: update packages --- packages/packages.json | 16 ++++++++-------- packages/valory/agents/trader/aea-config.yaml | 12 ++++++------ packages/valory/services/trader/service.yaml | 2 +- .../valory/skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 8 ++++---- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 6 files changed, 22 insertions(+), 22 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index dc6ef5561..38073e8af 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi", - "skill/valory/trader_abci/0.1.0": "bafybeidmfy4w6z2mf6ggunwzqwxsxrkc6vwup7wpwddeufv6jalame7u5a", + "skill/valory/decision_maker_abci/0.1.0": "bafybeig2ied4556e4zxqhrt5735yw77jrddwfxkp5wh35vroqxazkklthi", + "skill/valory/trader_abci/0.1.0": "bafybeifmaslb57hs5wphix57a7vkjvdtejjx4qd34bl65db6drhj55sgrq", "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", - "agent/valory/trader/0.1.0": "bafybeih7xlnlz3oejsa7vyj5sxsov42nd3jbf4rkmm6ziln6xbdda75kxi", - "service/valory/trader/0.1.0": "bafybeihr3t6mhuad3nqiyjq4ojo6qzjbffe7ukakduwg6oon3yotdfxbnm", + "agent/valory/trader/0.1.0": "bafybeid7557f5djy2l7jv7grphxzksczj2l2wlie47wlwjhdocw2bmc354", + "service/valory/trader/0.1.0": "bafybeia2od66vpg5r4ygq2ehdxrq4oxk4edkuen63b7vgf2xtzyw7xzn2i", "contract/valory/erc20/0.1.0": "bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeib42rkufh6ezl5jzvclzabqw3laml7jxeyjpq2uyokgwaxmdonofu", "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", "contract/valory/realitio/0.1.0": "bafybeiewpazpi2wgixmiu64kauwn7qes3xzphqid4pxvznm2himv4tciee", "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", @@ -33,10 +33,10 @@ "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq", "connection/valory/ipfs/0.1.0": "bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e", "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274", - "contract/valory/gnosis_safe/0.1.0": "bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm", + "contract/valory/gnosis_safe/0.1.0": "bafybeifre4isiccoaayomlt7hj2b477djktdkopqa3fklnjpc7w2ohgze4", "contract/valory/service_registry/0.1.0": "bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu", - "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui", + "skill/valory/transaction_settlement_abci/0.1.0": "bafybeihggaeyqyh5dho6uyirlhoujhoff6jhe4lcdcnyiwpa6tlafawqsi", "contract/valory/multisend/0.1.0": "bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u", - "skill/valory/termination_abci/0.1.0": "bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm" + "skill/valory/termination_abci/0.1.0": "bafybeih7myqjqpkry3mc6fqnlkg7fo54x32u3ejengqwbdouzggipsnxpu" } } \ No newline at end of file diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 22aeb4725..f09bac6ba 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -15,7 +15,7 @@ connections: - valory/ledger:0.19.0:bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a - valory/p2p_libp2p_client:0.1.0:bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq contracts: -- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm +- valory/gnosis_safe:0.1.0:bafybeifre4isiccoaayomlt7hj2b477djktdkopqa3fklnjpc7w2ohgze4 - valory/gnosis_safe_proxy_factory:0.1.0:bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274 - valory/service_registry:0.1.0:bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu - valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu @@ -39,12 +39,12 @@ skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq - valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu -- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm -- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi +- valory/termination_abci:0.1.0:bafybeih7myqjqpkry3mc6fqnlkg7fo54x32u3ejengqwbdouzggipsnxpu +- valory/transaction_settlement_abci:0.1.0:bafybeihggaeyqyh5dho6uyirlhoujhoff6jhe4lcdcnyiwpa6tlafawqsi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib42rkufh6ezl5jzvclzabqw3laml7jxeyjpq2uyokgwaxmdonofu - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi -- valory/trader_abci:0.1.0:bafybeidmfy4w6z2mf6ggunwzqwxsxrkc6vwup7wpwddeufv6jalame7u5a +- valory/decision_maker_abci:0.1.0:bafybeig2ied4556e4zxqhrt5735yw77jrddwfxkp5wh35vroqxazkklthi +- valory/trader_abci:0.1.0:bafybeifmaslb57hs5wphix57a7vkjvdtejjx4qd34bl65db6drhj55sgrq default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 340b32079..54f363f61 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeih7xlnlz3oejsa7vyj5sxsov42nd3jbf4rkmm6ziln6xbdda75kxi +agent: valory/trader:0.1.0:bafybeid7557f5djy2l7jv7grphxzksczj2l2wlie47wlwjhdocw2bmc354 number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index d9e55b7ab..7c4026b32 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -44,7 +44,7 @@ fingerprint: fingerprint_ignore_patterns: [] connections: [] contracts: -- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm +- valory/gnosis_safe:0.1.0:bafybeifre4isiccoaayomlt7hj2b477djktdkopqa3fklnjpc7w2ohgze4 - valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu - valory/erc20:0.1.0:bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4 - valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u @@ -58,7 +58,7 @@ protocols: skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/transaction_settlement_abci:0.1.0:bafybeihggaeyqyh5dho6uyirlhoujhoff6jhe4lcdcnyiwpa6tlafawqsi behaviours: main: args: {} diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 60614effa..2dd503f68 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -22,11 +22,11 @@ skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq - valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu -- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm +- valory/transaction_settlement_abci:0.1.0:bafybeihggaeyqyh5dho6uyirlhoujhoff6jhe4lcdcnyiwpa6tlafawqsi +- valory/termination_abci:0.1.0:bafybeih7myqjqpkry3mc6fqnlkg7fo54x32u3ejengqwbdouzggipsnxpu - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi +- valory/decision_maker_abci:0.1.0:bafybeig2ied4556e4zxqhrt5735yw77jrddwfxkp5wh35vroqxazkklthi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib42rkufh6ezl5jzvclzabqw3laml7jxeyjpq2uyokgwaxmdonofu behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 14ea45131..31dfc610b 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi +- valory/decision_maker_abci:0.1.0:bafybeig2ied4556e4zxqhrt5735yw77jrddwfxkp5wh35vroqxazkklthi behaviours: main: args: {} From 8ef44c6ee202a6d98a0d9ce75a26d6a72926ea3c Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Tue, 10 Oct 2023 20:15:05 +0200 Subject: [PATCH 09/79] chore: Update hashes and packages --- packages/packages.json | 16 ++++++++-------- packages/valory/agents/trader/aea-config.yaml | 12 ++++++------ packages/valory/services/trader/service.yaml | 2 +- .../valory/skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 8 ++++---- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 6 files changed, 22 insertions(+), 22 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 38073e8af..dc6ef5561 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeig2ied4556e4zxqhrt5735yw77jrddwfxkp5wh35vroqxazkklthi", - "skill/valory/trader_abci/0.1.0": "bafybeifmaslb57hs5wphix57a7vkjvdtejjx4qd34bl65db6drhj55sgrq", + "skill/valory/decision_maker_abci/0.1.0": "bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi", + "skill/valory/trader_abci/0.1.0": "bafybeidmfy4w6z2mf6ggunwzqwxsxrkc6vwup7wpwddeufv6jalame7u5a", "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", - "agent/valory/trader/0.1.0": "bafybeid7557f5djy2l7jv7grphxzksczj2l2wlie47wlwjhdocw2bmc354", - "service/valory/trader/0.1.0": "bafybeia2od66vpg5r4ygq2ehdxrq4oxk4edkuen63b7vgf2xtzyw7xzn2i", + "agent/valory/trader/0.1.0": "bafybeih7xlnlz3oejsa7vyj5sxsov42nd3jbf4rkmm6ziln6xbdda75kxi", + "service/valory/trader/0.1.0": "bafybeihr3t6mhuad3nqiyjq4ojo6qzjbffe7ukakduwg6oon3yotdfxbnm", "contract/valory/erc20/0.1.0": "bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeib42rkufh6ezl5jzvclzabqw3laml7jxeyjpq2uyokgwaxmdonofu", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi", "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", "contract/valory/realitio/0.1.0": "bafybeiewpazpi2wgixmiu64kauwn7qes3xzphqid4pxvznm2himv4tciee", "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", @@ -33,10 +33,10 @@ "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq", "connection/valory/ipfs/0.1.0": "bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e", "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274", - "contract/valory/gnosis_safe/0.1.0": "bafybeifre4isiccoaayomlt7hj2b477djktdkopqa3fklnjpc7w2ohgze4", + "contract/valory/gnosis_safe/0.1.0": "bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm", "contract/valory/service_registry/0.1.0": "bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu", - "skill/valory/transaction_settlement_abci/0.1.0": "bafybeihggaeyqyh5dho6uyirlhoujhoff6jhe4lcdcnyiwpa6tlafawqsi", + "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui", "contract/valory/multisend/0.1.0": "bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u", - "skill/valory/termination_abci/0.1.0": "bafybeih7myqjqpkry3mc6fqnlkg7fo54x32u3ejengqwbdouzggipsnxpu" + "skill/valory/termination_abci/0.1.0": "bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm" } } \ No newline at end of file diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index f09bac6ba..22aeb4725 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -15,7 +15,7 @@ connections: - valory/ledger:0.19.0:bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a - valory/p2p_libp2p_client:0.1.0:bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq contracts: -- valory/gnosis_safe:0.1.0:bafybeifre4isiccoaayomlt7hj2b477djktdkopqa3fklnjpc7w2ohgze4 +- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm - valory/gnosis_safe_proxy_factory:0.1.0:bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274 - valory/service_registry:0.1.0:bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu - valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu @@ -39,12 +39,12 @@ skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq - valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu -- valory/termination_abci:0.1.0:bafybeih7myqjqpkry3mc6fqnlkg7fo54x32u3ejengqwbdouzggipsnxpu -- valory/transaction_settlement_abci:0.1.0:bafybeihggaeyqyh5dho6uyirlhoujhoff6jhe4lcdcnyiwpa6tlafawqsi -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib42rkufh6ezl5jzvclzabqw3laml7jxeyjpq2uyokgwaxmdonofu +- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeig2ied4556e4zxqhrt5735yw77jrddwfxkp5wh35vroqxazkklthi -- valory/trader_abci:0.1.0:bafybeifmaslb57hs5wphix57a7vkjvdtejjx4qd34bl65db6drhj55sgrq +- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi +- valory/trader_abci:0.1.0:bafybeidmfy4w6z2mf6ggunwzqwxsxrkc6vwup7wpwddeufv6jalame7u5a default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 54f363f61..340b32079 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeid7557f5djy2l7jv7grphxzksczj2l2wlie47wlwjhdocw2bmc354 +agent: valory/trader:0.1.0:bafybeih7xlnlz3oejsa7vyj5sxsov42nd3jbf4rkmm6ziln6xbdda75kxi number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 7c4026b32..d9e55b7ab 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -44,7 +44,7 @@ fingerprint: fingerprint_ignore_patterns: [] connections: [] contracts: -- valory/gnosis_safe:0.1.0:bafybeifre4isiccoaayomlt7hj2b477djktdkopqa3fklnjpc7w2ohgze4 +- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm - valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu - valory/erc20:0.1.0:bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4 - valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u @@ -58,7 +58,7 @@ protocols: skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/transaction_settlement_abci:0.1.0:bafybeihggaeyqyh5dho6uyirlhoujhoff6jhe4lcdcnyiwpa6tlafawqsi +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui behaviours: main: args: {} diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 2dd503f68..60614effa 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -22,11 +22,11 @@ skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq - valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu -- valory/transaction_settlement_abci:0.1.0:bafybeihggaeyqyh5dho6uyirlhoujhoff6jhe4lcdcnyiwpa6tlafawqsi -- valory/termination_abci:0.1.0:bafybeih7myqjqpkry3mc6fqnlkg7fo54x32u3ejengqwbdouzggipsnxpu +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeig2ied4556e4zxqhrt5735yw77jrddwfxkp5wh35vroqxazkklthi -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib42rkufh6ezl5jzvclzabqw3laml7jxeyjpq2uyokgwaxmdonofu +- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 31dfc610b..14ea45131 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeig2ied4556e4zxqhrt5735yw77jrddwfxkp5wh35vroqxazkklthi +- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi behaviours: main: args: {} From 4c77480ac9206a4b9998331a7339ac28608d4445 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 11 Oct 2023 17:32:04 +0200 Subject: [PATCH 10/79] feat: Add kelly bet amount calculation function --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 20 ++++++++++++------- .../skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 26 insertions(+), 20 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index dc6ef5561..05d2da535 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi", - "skill/valory/trader_abci/0.1.0": "bafybeidmfy4w6z2mf6ggunwzqwxsxrkc6vwup7wpwddeufv6jalame7u5a", + "skill/valory/decision_maker_abci/0.1.0": "bafybeibgel4gcug4qqsetvw57dk72g325yvnyzkdad3fwhsmov74vo7g5y", + "skill/valory/trader_abci/0.1.0": "bafybeieb6bofi7s3xveymk34bytuswz3l2eibwwxyv7m4k4e22d73czohe", "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", - "agent/valory/trader/0.1.0": "bafybeih7xlnlz3oejsa7vyj5sxsov42nd3jbf4rkmm6ziln6xbdda75kxi", - "service/valory/trader/0.1.0": "bafybeihr3t6mhuad3nqiyjq4ojo6qzjbffe7ukakduwg6oon3yotdfxbnm", + "agent/valory/trader/0.1.0": "bafybeigkspihyrn5gzmji6r3hd5wi3h6szackbasean3xmq646pp5erwea", + "service/valory/trader/0.1.0": "bafybeic36hayxersd5c7o7fwhjrnhzymww5d3uym5a6hcra3gxttyg4zgi", "contract/valory/erc20/0.1.0": "bafybeid6p64a6tnovatbwybc6ocdd4u7bqkxsb4ks52rvf7ozcxxl6iaf4", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihemgkzx32ukwgbvo5ivqa5xcvbrumzgeuvwaipsiv4rk74og53ri", "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", "contract/valory/realitio/0.1.0": "bafybeiewpazpi2wgixmiu64kauwn7qes3xzphqid4pxvznm2himv4tciee", "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 22aeb4725..128d48719 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihemgkzx32ukwgbvo5ivqa5xcvbrumzgeuvwaipsiv4rk74og53ri - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi -- valory/trader_abci:0.1.0:bafybeidmfy4w6z2mf6ggunwzqwxsxrkc6vwup7wpwddeufv6jalame7u5a +- valory/decision_maker_abci:0.1.0:bafybeibgel4gcug4qqsetvw57dk72g325yvnyzkdad3fwhsmov74vo7g5y +- valory/trader_abci:0.1.0:bafybeieb6bofi7s3xveymk34bytuswz3l2eibwwxyv7m4k4e22d73czohe default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 340b32079..833ad8497 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeih7xlnlz3oejsa7vyj5sxsov42nd3jbf4rkmm6ziln6xbdda75kxi +agent: valory/trader:0.1.0:bafybeigkspihyrn5gzmji6r3hd5wi3h6szackbasean3xmq646pp5erwea number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 9d788b75d..8d59bbad0 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -242,7 +242,7 @@ def _get_decision( self.context.logger.error( f"There was an error on the mech's response: {self.mech_response.error}" ) - return None, None, None + return None, None, None, None return self.mech_response.result.vote, self.mech_response.result.odds, self.mech_response.result.win_probability, self.mech_response.result.confidence @@ -255,8 +255,9 @@ def _get_kelly_bet_amount(self, x, y, p, c, b) -> int: f"Pool token amounts: {x}, {y}" ) return None - kelly_bet_amount = (-4*x**2*y + b*y**2*p + 2*b*x*y*p + b*x**2*p - 2*b*x**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p - 2*b*x*y*p - b*x**2*p + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p - 4*b*x**2*y*p + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) - self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount: {kelly_bet_amount}") + # TODO: Add Fee variable + kelly_bet_amount = (-4*x**2*y + b*y**2*p + 2*b*x*y*p + b*x**2*p - 2*b*y**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p - 2*b*x*y*p - b*x**2*p + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p - 4*b*x**2*y*p + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) + self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") return int(kelly_bet_amount) @@ -303,12 +304,16 @@ def _calc_binary_shares(self, net_bet_amount: int, win_probability: float, confi self.context.logger.info(f"Other tokens in pool: {other_tokens_in_pool/(10**18)}") bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade + self.context.logger.info(f"Wallet balance: {self.wallet_balance}") + self.context.logger.info(f"Token balance: {self.token_balance}") + self.context.logger.info(f"Bankroll: {bankroll}") kelly_bet_amount = self._get_kelly_bet_amount( - selected_shares, other_shares, win_probability, confidence, bankroll + selected_type_tokens_in_pool, other_tokens_in_pool, win_probability, confidence, bankroll ) - self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") - self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") - + if kelly_bet_amount != None: + self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") + self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") + self.context.logger.info(f"Added None check!") # the OMEN market then trades the opposite tokens to the tokens of the answer that has been selected, # preserving the balance of the pool @@ -383,6 +388,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide bet = self.synchronized_data.sampled_bet self.context.logger.info(f"Sampled bet: {bet}") self.context.logger.info(f"Trading strategy: {self.params.trading_strategy}") + yield from self._check_balance() balance_sum = self.wallet_balance + self.token_balance bet_amount = self.params.get_bet_amount(balance_sum, self.params.trading_strategy, odds, win_probability, confidence) self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index d9e55b7ab..9f0052f41 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiato4qxnc2kjjdtttvqdna7dp4c5evlb6cus7h6eci7tj73tqnpey behaviours/bet_placement.py: bafybeiaf72izdvhqm27dqf6brxotxx6ckkah6zu4ndik2lu6i7o2sscsnq behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeid2zzfcwyxb4x26no76pz6a7u677eid3bqpmzk6cgym346mbids5q + behaviours/decision_receive.py: bafybeib3wcmlb2ubbdjy3xnngbqprlfujtf536s76rrm3mb777fmyhinbi behaviours/decision_request.py: bafybeidlyl2ojmpfs2zkewoacraya2cbampo4ynqbqaocsoq7v2nif3ahi behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeigzsx4wyov3ehfvdjmo2d7yimss4p7mbkopkqyr4gryxpa5rpv6ku diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 60614effa..a447f679f 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiggpn4zqcnvdiih42pdxh6ewnhtk6wlz433ls2ihlrrvpok5b2esi +- valory/decision_maker_abci:0.1.0:bafybeibgel4gcug4qqsetvw57dk72g325yvnyzkdad3fwhsmov74vo7g5y +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihemgkzx32ukwgbvo5ivqa5xcvbrumzgeuvwaipsiv4rk74og53ri behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 14ea45131..0f0bdfcda 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeihlnphqhxlg6qatssx52bxp3qpmfpjjhh72rubc4si6duwedq7nhi +- valory/decision_maker_abci:0.1.0:bafybeibgel4gcug4qqsetvw57dk72g325yvnyzkdad3fwhsmov74vo7g5y behaviours: main: args: {} From 93b03cbf78e7a9ce100c944edc82ca6ddf07134f Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Tue, 17 Oct 2023 09:55:19 +0200 Subject: [PATCH 11/79] chore: update packages --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 8 ++++---- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 6 files changed, 16 insertions(+), 16 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 8b4f2c079..1274cb914 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeihtydxuzyd35cq23xoxbytpxebpbn3rsyqf4bt6z4sleflqck6riy", - "skill/valory/trader_abci/0.1.0": "bafybeignhbqiajnhec7xipsibm3vpjovxboaak3n3kd2ozc27sjaw7733m", + "skill/valory/decision_maker_abci/0.1.0": "bafybeibpww5tujkvo6qpbh73nupjkwa4jc4zeuo24mj5dwkrzm5a5p6b7a", + "skill/valory/trader_abci/0.1.0": "bafybeiaceyikkgnpfs6oqjxt6bj2mxt7ynqyov2kulbokxddr32qugqmaa", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeibpafgfqxva32x4y22zsw6pjur43xcbirjizlornqwvl5vykopdgy", - "service/valory/trader/0.1.0": "bafybeiadxvczqasdeukfmt2c2h66z4dxtgeyzinio7cm4alm2meboh65ye", + "agent/valory/trader/0.1.0": "bafybeif7gnc3pgmq7b72uudqxivfiry6umwtw5fzygba6pkewmagpwx6vy", + "service/valory/trader/0.1.0": "bafybeicdb74zhfxd5gabz23auwyzq57nh76cto7eixhml6ewxdvuxhh73u", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigfkdkpkrktw4wippon6al7vreg3qh7xax33xafomepy6xrv5paa4", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibndfdgzck75jpdwmeuomvy4lytylvpsh425rx5l5j6sl4xmkxp4q", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 2709d8edc..ba158657f 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigfkdkpkrktw4wippon6al7vreg3qh7xax33xafomepy6xrv5paa4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibndfdgzck75jpdwmeuomvy4lytylvpsh425rx5l5j6sl4xmkxp4q - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeihtydxuzyd35cq23xoxbytpxebpbn3rsyqf4bt6z4sleflqck6riy -- valory/trader_abci:0.1.0:bafybeignhbqiajnhec7xipsibm3vpjovxboaak3n3kd2ozc27sjaw7733m +- valory/decision_maker_abci:0.1.0:bafybeibpww5tujkvo6qpbh73nupjkwa4jc4zeuo24mj5dwkrzm5a5p6b7a +- valory/trader_abci:0.1.0:bafybeiaceyikkgnpfs6oqjxt6bj2mxt7ynqyov2kulbokxddr32qugqmaa default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 21306810d..6450f7ee8 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeibpafgfqxva32x4y22zsw6pjur43xcbirjizlornqwvl5vykopdgy +agent: valory/trader:0.1.0:bafybeif7gnc3pgmq7b72uudqxivfiry6umwtw5fzygba6pkewmagpwx6vy number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 349db84cb..27ea79f32 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -13,9 +13,9 @@ fingerprint: __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky behaviours/base.py: bafybeidny4y4w4jbjbp5d5qivur6jm37fnuik4mqzchzshiuvpozxe7vwy - behaviours/bet_placement.py: bafybeiauzdizqawjgzc3ugx33vuh726e25juhacqdr7c6uztpn6tra5dva + behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeibfnucc444uqcythgsn4cawluubbi4u4q7ab4aqc4ts3lu4qnvhdq + behaviours/decision_receive.py: bafybeibpet6vwbuvcqz6twtn2vvdpnuxd6jnjt7txhkg57ttpre7xeazwu behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga @@ -25,8 +25,8 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeidlis33rkpvtb2w6qrtmiqzb4tbqfolkbbs6hk3jcx73lfuwqif3e - payloads.py: bafybeic4iz6uxinqpaxnefkadnzaox23y7k57zawnnkeovplih36v5cchy + models.py: bafybeifgao43trxhykd22nkriav4gsi4rxdqllfe2n7y5q2tafrvbnpl3y + payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm rounds.py: bafybeihopxmhzrpipc6r5x2vqf2tcixzuf5xdpqfsr7gr3n756n3ssft5q diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 96b85c42b..583886990 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeihtydxuzyd35cq23xoxbytpxebpbn3rsyqf4bt6z4sleflqck6riy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigfkdkpkrktw4wippon6al7vreg3qh7xax33xafomepy6xrv5paa4 +- valory/decision_maker_abci:0.1.0:bafybeibpww5tujkvo6qpbh73nupjkwa4jc4zeuo24mj5dwkrzm5a5p6b7a +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibndfdgzck75jpdwmeuomvy4lytylvpsh425rx5l5j6sl4xmkxp4q behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 9b6e6c225..371b8577d 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeihtydxuzyd35cq23xoxbytpxebpbn3rsyqf4bt6z4sleflqck6riy +- valory/decision_maker_abci:0.1.0:bafybeibpww5tujkvo6qpbh73nupjkwa4jc4zeuo24mj5dwkrzm5a5p6b7a behaviours: main: args: {} From 88b3a65776ee495b77fcf3503dbf5ca06db1d355 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Tue, 17 Oct 2023 16:18:13 +0200 Subject: [PATCH 12/79] chore: Update packages --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/decision_receive.py | 2 ++ packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 15 insertions(+), 13 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 1274cb914..dd2930479 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeibpww5tujkvo6qpbh73nupjkwa4jc4zeuo24mj5dwkrzm5a5p6b7a", - "skill/valory/trader_abci/0.1.0": "bafybeiaceyikkgnpfs6oqjxt6bj2mxt7ynqyov2kulbokxddr32qugqmaa", + "skill/valory/decision_maker_abci/0.1.0": "bafybeig3fyxn2jtngwzd2xki7d6rcnudiwrg5e5cuvrbawisycalq2gsva", + "skill/valory/trader_abci/0.1.0": "bafybeie4krhb65r5d7wgrnh7bvnh22j3o4ucsvatxu3rv7eptg6vmz4ybm", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeif7gnc3pgmq7b72uudqxivfiry6umwtw5fzygba6pkewmagpwx6vy", - "service/valory/trader/0.1.0": "bafybeicdb74zhfxd5gabz23auwyzq57nh76cto7eixhml6ewxdvuxhh73u", + "agent/valory/trader/0.1.0": "bafybeidnagedsnhqgshua6hl5zwvgdepv6ak6pdj77xibm4khdj4zhurqa", + "service/valory/trader/0.1.0": "bafybeibv5n3w4lrbhlexzppqw7hndvs7w5flb6oltgmoit3n4b4koa6gty", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibndfdgzck75jpdwmeuomvy4lytylvpsh425rx5l5j6sl4xmkxp4q", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeif3vbhqtdwe4rnivf7mtbyf5rw6ji5pwdfnbg5ymlmi5flsmttvim", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index ba158657f..f48376846 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibndfdgzck75jpdwmeuomvy4lytylvpsh425rx5l5j6sl4xmkxp4q +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeif3vbhqtdwe4rnivf7mtbyf5rw6ji5pwdfnbg5ymlmi5flsmttvim - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibpww5tujkvo6qpbh73nupjkwa4jc4zeuo24mj5dwkrzm5a5p6b7a -- valory/trader_abci:0.1.0:bafybeiaceyikkgnpfs6oqjxt6bj2mxt7ynqyov2kulbokxddr32qugqmaa +- valory/decision_maker_abci:0.1.0:bafybeig3fyxn2jtngwzd2xki7d6rcnudiwrg5e5cuvrbawisycalq2gsva +- valory/trader_abci:0.1.0:bafybeie4krhb65r5d7wgrnh7bvnh22j3o4ucsvatxu3rv7eptg6vmz4ybm default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 6450f7ee8..4a699aa17 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeif7gnc3pgmq7b72uudqxivfiry6umwtw5fzygba6pkewmagpwx6vy +agent: valory/trader:0.1.0:bafybeidnagedsnhqgshua6hl5zwvgdepv6ak6pdj77xibm4khdj4zhurqa number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 37d4f7607..52a7046e0 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -315,6 +315,8 @@ def _calc_binary_shares(self, net_bet_amount: int, win_probability: float, confi self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") self.context.logger.info(f"Added None check!") + self.context.logger.info(f"Added None check2!") + self.context.logger.info(f"Added None check3!") # the OMEN market then trades the opposite tokens to the tokens of the answer that has been selected, # preserving the balance of the pool diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 27ea79f32..081cb7cf1 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeidny4y4w4jbjbp5d5qivur6jm37fnuik4mqzchzshiuvpozxe7vwy behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeibpet6vwbuvcqz6twtn2vvdpnuxd6jnjt7txhkg57ttpre7xeazwu + behaviours/decision_receive.py: bafybeibjmlyymzduzdwg4uutsfnjdeprg6aiklp6yw6riuu5oxg24eq3hi behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 583886990..5969edfe1 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibpww5tujkvo6qpbh73nupjkwa4jc4zeuo24mj5dwkrzm5a5p6b7a -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibndfdgzck75jpdwmeuomvy4lytylvpsh425rx5l5j6sl4xmkxp4q +- valory/decision_maker_abci:0.1.0:bafybeig3fyxn2jtngwzd2xki7d6rcnudiwrg5e5cuvrbawisycalq2gsva +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeif3vbhqtdwe4rnivf7mtbyf5rw6ji5pwdfnbg5ymlmi5flsmttvim behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 371b8577d..9441ce124 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeibpww5tujkvo6qpbh73nupjkwa4jc4zeuo24mj5dwkrzm5a5p6b7a +- valory/decision_maker_abci:0.1.0:bafybeig3fyxn2jtngwzd2xki7d6rcnudiwrg5e5cuvrbawisycalq2gsva behaviours: main: args: {} From 133a6d66281bbb5ab94986f81d669fb0f4267a81 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 18 Oct 2023 09:33:19 +0200 Subject: [PATCH 13/79] refactor: Reset mech tools --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/decision_receive.py | 1 + packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 13 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index dd2930479..8ab80bfa9 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeig3fyxn2jtngwzd2xki7d6rcnudiwrg5e5cuvrbawisycalq2gsva", - "skill/valory/trader_abci/0.1.0": "bafybeie4krhb65r5d7wgrnh7bvnh22j3o4ucsvatxu3rv7eptg6vmz4ybm", + "skill/valory/decision_maker_abci/0.1.0": "bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm", + "skill/valory/trader_abci/0.1.0": "bafybeigxrvqhwo5dgdnotxx5hdpemsp7tyljw5ruagrk3rs46ptbayjika", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeidnagedsnhqgshua6hl5zwvgdepv6ak6pdj77xibm4khdj4zhurqa", - "service/valory/trader/0.1.0": "bafybeibv5n3w4lrbhlexzppqw7hndvs7w5flb6oltgmoit3n4b4koa6gty", + "agent/valory/trader/0.1.0": "bafybeif7xd3mil4ifohqmhdfbvfbhakeu57duubym45igvezlmbfzqxngi", + "service/valory/trader/0.1.0": "bafybeiblxnwxrracktqlvuls4lc56u2mdfomrik4z6ri7gnbi23qjtiiay", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeif3vbhqtdwe4rnivf7mtbyf5rw6ji5pwdfnbg5ymlmi5flsmttvim", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index f48376846..2e060d721 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeif3vbhqtdwe4rnivf7mtbyf5rw6ji5pwdfnbg5ymlmi5flsmttvim +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeig3fyxn2jtngwzd2xki7d6rcnudiwrg5e5cuvrbawisycalq2gsva -- valory/trader_abci:0.1.0:bafybeie4krhb65r5d7wgrnh7bvnh22j3o4ucsvatxu3rv7eptg6vmz4ybm +- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm +- valory/trader_abci:0.1.0:bafybeigxrvqhwo5dgdnotxx5hdpemsp7tyljw5ruagrk3rs46ptbayjika default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 4a699aa17..cb1711ecb 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeidnagedsnhqgshua6hl5zwvgdepv6ak6pdj77xibm4khdj4zhurqa +agent: valory/trader:0.1.0:bafybeif7xd3mil4ifohqmhdfbvfbhakeu57duubym45igvezlmbfzqxngi number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 52a7046e0..29bd2146c 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -317,6 +317,7 @@ def _calc_binary_shares(self, net_bet_amount: int, win_probability: float, confi self.context.logger.info(f"Added None check!") self.context.logger.info(f"Added None check2!") self.context.logger.info(f"Added None check3!") + self.context.logger.info(f"Added None check4!") # the OMEN market then trades the opposite tokens to the tokens of the answer that has been selected, # preserving the balance of the pool diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 081cb7cf1..6dc5f7148 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeidny4y4w4jbjbp5d5qivur6jm37fnuik4mqzchzshiuvpozxe7vwy behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeibjmlyymzduzdwg4uutsfnjdeprg6aiklp6yw6riuu5oxg24eq3hi + behaviours/decision_receive.py: bafybeicoogphhr3acovqgrfxkivzjjuorua2vin3jyfo53sirmwveri7ru behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 5969edfe1..42f78e2cb 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeig3fyxn2jtngwzd2xki7d6rcnudiwrg5e5cuvrbawisycalq2gsva -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeif3vbhqtdwe4rnivf7mtbyf5rw6ji5pwdfnbg5ymlmi5flsmttvim +- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 9441ce124..2f66c404f 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeig3fyxn2jtngwzd2xki7d6rcnudiwrg5e5cuvrbawisycalq2gsva +- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm behaviours: main: args: {} From 5867590aa5cec0dbc29c978cd654b7142e6b7faf Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 18 Oct 2023 11:11:47 +0200 Subject: [PATCH 14/79] refactor: Outsourced Kelly calc --- .../behaviours/decision_receive.py | 57 ++++++++++--------- .../skills/decision_maker_abci/models.py | 36 ++++++++++-- 2 files changed, 60 insertions(+), 33 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 29bd2146c..31c3cf81c 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -30,7 +30,6 @@ CID_PREFIX, DecisionMakerBaseBehaviour, WaitableConditionType, - remove_fraction_wei, ) from packages.valory.skills.decision_maker_abci.behaviours.bet_placement import WXDAI from packages.valory.skills.decision_maker_abci.models import ( @@ -261,8 +260,19 @@ def _get_kelly_bet_amount(self, x, y, p, c, b) -> int: self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") return int(kelly_bet_amount) + def _get_bet_sample_info(bet, vote) -> Tuple[int, int]: + token_amounts = bet.outcomeTokenAmounts + if token_amounts is None: + return None, None, None + + selected_type_tokens_in_pool = token_amounts.pop(vote) + other_tokens_in_pool = token_amounts.pop() + bet_fee = bet.fee + + return selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee - def _calc_binary_shares(self, net_bet_amount: int, win_probability: float, confidence: float, vote: int) -> Tuple[int, int]: + + def _calc_binary_shares(self, bet_amount: int, win_probability: float, confidence: float, vote: int) -> Tuple[int, int]: """Calculate the claimed shares. This calculation only works for binary markets.""" bet = self.synchronized_data.sampled_bet @@ -276,7 +286,7 @@ def _calc_binary_shares(self, net_bet_amount: int, win_probability: float, confi # the OMEN market trades an equal amount of the investment to each of the tokens in the pool # here we calculate the bet amount per pool's token - bet_per_token = net_bet_amount / BINARY_N_SLOTS + bet_per_token = bet_amount / BINARY_N_SLOTS self.context.logger.info(f"Bet per token: {bet_per_token/(10**18)}") # calculate the number of the traded tokens @@ -304,21 +314,6 @@ def _calc_binary_shares(self, net_bet_amount: int, win_probability: float, confi other_tokens_in_pool = token_amounts.pop() self.context.logger.info(f"Other tokens in pool: {other_tokens_in_pool/(10**18)}") - bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade - self.context.logger.info(f"Wallet balance: {self.wallet_balance}") - self.context.logger.info(f"Token balance: {self.token_balance}") - self.context.logger.info(f"Bankroll: {bankroll}") - kelly_bet_amount = self._get_kelly_bet_amount( - selected_type_tokens_in_pool, other_tokens_in_pool, win_probability, confidence, bankroll - ) - if kelly_bet_amount != None: - self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") - self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") - self.context.logger.info(f"Added None check!") - self.context.logger.info(f"Added None check2!") - self.context.logger.info(f"Added None check3!") - self.context.logger.info(f"Added None check4!") - # the OMEN market then trades the opposite tokens to the tokens of the answer that has been selected, # preserving the balance of the pool # here we calculate the number of shares that we get after trading the tokens for the opposite answer @@ -390,17 +385,25 @@ def _check_balance(self) -> WaitableConditionType: def _is_profitable(self, vote: int, odds: float, win_probability: float, confidence: float) -> bool: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet - self.context.logger.info(f"Sampled bet: {bet}") - self.context.logger.info(f"Trading strategy: {self.params.trading_strategy}") yield from self._check_balance() - balance_sum = self.wallet_balance + self.token_balance - bet_amount = self.params.get_bet_amount(balance_sum, self.params.trading_strategy, odds, win_probability, confidence) + bankroll = self.wallet_balance + self.token_balance + self.context.logger.info(f"Wallet balance: {self.wallet_balance}") + self.context.logger.info(f"Token balance: {self.token_balance}") + self.context.logger.info(f"Bankroll: {bankroll}") + selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee = self._get_bet_sample_info(bet, vote) + bet_amount = self.params.get_bet_amount( + bankroll, + self.params.trading_strategy, + win_probability, + confidence, + selected_type_tokens_in_pool, + other_tokens_in_pool, + bet_fee, + ) self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") - net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet.fee)) - self.context.logger.info(f"Net bet amount: {net_bet_amount/(10**18)}") - num_shares, available_shares = self._calc_binary_shares(net_bet_amount, win_probability, confidence, vote) + num_shares, available_shares = self._calc_binary_shares(bet_amount, win_probability, confidence, vote) bet_threshold = self.params.bet_threshold self.context.logger.info(f"Bet threshold: {bet_threshold/(10**18)}") @@ -413,7 +416,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide yield from self.wait_for_condition_with_sleep(self._get_mech_price) self.context.logger.info(f"Mech price: {self.mech_price/(10**18)}") - potential_net_profit = num_shares - net_bet_amount - self.mech_price - bet_threshold + potential_net_profit = num_shares - bet_amount - self.mech_price - bet_threshold self.context.logger.info(f"Potential net profit: {potential_net_profit/(10**18)}") is_profitable = potential_net_profit >= 0 and num_shares <= available_shares self.context.logger.info(f"Is profitable: {is_profitable}") @@ -423,7 +426,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide self.context.logger.info(f"Available in: {available_in}") shares_out_of = f"{shares_out} / {available_in}" self.context.logger.info(f"Shares out of: {shares_out_of}") - potential_net_profit = num_shares - net_bet_amount - bet_threshold + potential_net_profit = num_shares - bet_amount - bet_threshold is_profitable = potential_net_profit >= 0 if num_shares > available_shares * SLIPPAGE: diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 133a11115..22830f1eb 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -35,13 +35,17 @@ from packages.valory.skills.abstract_round_abci.models import ( BenchmarkTool as BaseBenchmarkTool, ) + from packages.valory.skills.abstract_round_abci.models import Requests as BaseRequests from packages.valory.skills.abstract_round_abci.models import ( SharedState as BaseSharedState, ) from packages.valory.skills.decision_maker_abci.rounds import DecisionMakerAbciApp from packages.valory.skills.market_manager_abci.models import MarketManagerParams - +from packages.valory.skills.decision_maker_abci.behaviours.base import ( + DecisionMakerBaseBehaviour, + remove_fraction_wei, +) RE_CONTENT_IN_BRACKETS = r"\{([^}]*)\}" REQUIRED_BET_TEMPLATE_KEYS = {"yes", "no", "question"} @@ -165,18 +169,38 @@ def slippage(self, slippage: float) -> None: # threshold = round(confidence, 1) # return self.bet_amount_per_threshold[threshold] - def get_bet_amount(self, balance_sum: int, strategy: str, odds: float, win_probability: float, confidence: float) -> int: + def get_bet_amount( + self, + bankroll: int, + strategy: str, + win_probability: float, + confidence: float, + selected_type_tokens_in_pool: int, + other_tokens_in_pool: int, + bet_fee: int, + ) -> int: """Get the bet amount given a specified trading strategy.""" if strategy == "bet_amount_per_conf_threshold": self.context.logger.info(f"Used trading strategy: {strategy}") threshold = round(confidence, 1) - return self.bet_amount_per_threshold[threshold] + bet_amount = self.bet_amount_per_threshold[threshold] + self.context.logger.info(f"Bet amount: {bet_amount}") + net_bet_amount = remove_fraction_wei(bet_amount, DecisionMakerBaseBehaviour.wei_to_native(bet_fee)) + self.context.logger.info(f"Net bet amount: {net_bet_amount}") + return net_bet_amount + elif strategy == "kelly_criterion": self.context.logger.info(f"Used trading strategy: {strategy}") - threshold = round(confidence, 1) - return self.bet_amount_per_threshold[threshold] - # TODO: Implement Kelly Criterion + bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade + kelly_bet_amount = self._get_kelly_bet_amount( + selected_type_tokens_in_pool, other_tokens_in_pool, win_probability, confidence, bankroll + ) + if kelly_bet_amount != None: + self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") + self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") + return kelly_bet_amount + else: raise ValueError(f"Invalid trading strategy: {strategy}") From 935242d8d9feca433a24566f8bc6609c36fa59f4 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 18 Oct 2023 11:23:31 +0200 Subject: [PATCH 15/79] chore: Update packages --- packages/packages.json | 58 +++++++++---------- packages/valory/agents/trader/aea-config.yaml | 54 ++++++++--------- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/skill.yaml | 16 ++--- .../skills/market_manager_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 16 ++--- .../tx_settlement_multiplexer_abci/skill.yaml | 4 +- 7 files changed, 76 insertions(+), 76 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 8ab80bfa9..7735d5bc1 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { - "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm", - "skill/valory/trader_abci/0.1.0": "bafybeigxrvqhwo5dgdnotxx5hdpemsp7tyljw5ruagrk3rs46ptbayjika", + "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", + "skill/valory/decision_maker_abci/0.1.0": "bafybeiaeh5g4nilyiudnn5y3xw2q7rnqgsluiwt2ufyptr2v6f47i5eu5m", + "skill/valory/trader_abci/0.1.0": "bafybeiawahh3lswqcskavbnm46537rkaiej2lf3dnnqbnxn52fh7kxgz5q", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeif7xd3mil4ifohqmhdfbvfbhakeu57duubym45igvezlmbfzqxngi", - "service/valory/trader/0.1.0": "bafybeiblxnwxrracktqlvuls4lc56u2mdfomrik4z6ri7gnbi23qjtiiay", + "agent/valory/trader/0.1.0": "bafybeiekcyq54ipoqqnylkufyw4smouef7t5xu6gsu6y7t4go5ib42vupu", + "service/valory/trader/0.1.0": "bafybeigwrlmdxvxfabm53smdidlxhk3ke6j2gniyydvw4fwnmn2l3ygtri", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeic23djnpzskpjtko4e3yoq6g3oetvynr7rtvacshvcxubhkfavjey", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", @@ -15,28 +15,28 @@ "contract/valory/agent_registry/0.1.0": "bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty" }, "third_party": { - "protocol/open_aea/signing/1.0.0": "bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii", - "protocol/valory/abci/0.1.0": "bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu", - "protocol/valory/contract_api/1.0.0": "bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka", - "protocol/valory/http/1.0.0": "bafybeiejoqgv7finfxo3rcvvovrlj5ccrbgxodjq43uo26ylpowsa3llfe", - "protocol/valory/ledger_api/1.0.0": "bafybeige5agrztgzfevyglf7mb4o7pzfttmq4f6zi765y4g2zvftbyowru", - "protocol/valory/acn/1.1.0": "bafybeic2pxzfc3voxl2ejhcqyf2ehm4wm5gxvgx7bliloiqi2uppmq6weu", - "protocol/valory/tendermint/0.1.0": "bafybeig6g6twajlwssfbfp5rlnu5mwzuu5kgak5cs4fich7rlkx6whesnu", - "protocol/valory/ipfs/0.1.0": "bafybeiedxeismnx3k5ty4mvvhlqideixlhqmi5mtcki4lxqfa7uqh7p33u", - "skill/valory/abstract_abci/0.1.0": "bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a", - "skill/valory/reset_pause_abci/0.1.0": "bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe", - "skill/valory/registration_abci/0.1.0": "bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm", - "skill/valory/abstract_round_abci/0.1.0": "bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq", - "connection/valory/abci/0.1.0": "bafybeibtnfu6skrpducj2fzjzw7lrwj3et63xx6u5dryrabec26utzxsf4", - "connection/valory/http_client/0.23.0": "bafybeifgeqgryx6b3s6eseyzyezygmeitcpt3tkor2eiycozoi6clgdrny", - "connection/valory/ledger/0.19.0": "bafybeigo5vst3zlltkouenwxuzn6c47yr2fbbml6dl2o32rfnsezmalgnu", - "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihge56dn3xep2dzomu7rtvbgo4uc2qqh7ljl3fubqdi2lq44gs5lq", - "connection/valory/ipfs/0.1.0": "bafybeigkn27u7m5atju6a724clycyfshbgcbwheztil2bky7krfa46ub2a", - "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y", - "contract/valory/gnosis_safe/0.1.0": "bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci", - "contract/valory/service_registry/0.1.0": "bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu", - "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy", - "contract/valory/multisend/0.1.0": "bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y", - "skill/valory/termination_abci/0.1.0": "bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy" + "protocol/open_aea/signing/1.0.0": "bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m", + "protocol/valory/abci/0.1.0": "bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe", + "protocol/valory/contract_api/1.0.0": "bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa", + "protocol/valory/http/1.0.0": "bafybeia5bxdua2i6chw6pg47bvoljzcpuqxzy4rdrorbdmcbnwmnfdobtu", + "protocol/valory/ledger_api/1.0.0": "bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby", + "protocol/valory/acn/1.1.0": "bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa", + "protocol/valory/tendermint/0.1.0": "bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa", + "protocol/valory/ipfs/0.1.0": "bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa", + "skill/valory/abstract_abci/0.1.0": "bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy", + "skill/valory/reset_pause_abci/0.1.0": "bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu", + "skill/valory/registration_abci/0.1.0": "bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li", + "skill/valory/abstract_round_abci/0.1.0": "bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq", + "connection/valory/abci/0.1.0": "bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina", + "connection/valory/http_client/0.23.0": "bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y", + "connection/valory/ledger/0.19.0": "bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a", + "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq", + "connection/valory/ipfs/0.1.0": "bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e", + "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274", + "contract/valory/gnosis_safe/0.1.0": "bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm", + "contract/valory/service_registry/0.1.0": "bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu", + "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui", + "contract/valory/multisend/0.1.0": "bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u", + "skill/valory/termination_abci/0.1.0": "bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm" } } \ No newline at end of file diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 2e060d721..9fb0ea539 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -9,42 +9,42 @@ fingerprint: __init__.py: bafybeighcq4pmuzte6vhvvprrvo563vzghkoit2h6qdqxf2ma5bghevkee fingerprint_ignore_patterns: [] connections: -- valory/abci:0.1.0:bafybeibtnfu6skrpducj2fzjzw7lrwj3et63xx6u5dryrabec26utzxsf4 -- valory/http_client:0.23.0:bafybeifgeqgryx6b3s6eseyzyezygmeitcpt3tkor2eiycozoi6clgdrny -- valory/ipfs:0.1.0:bafybeigkn27u7m5atju6a724clycyfshbgcbwheztil2bky7krfa46ub2a -- valory/ledger:0.19.0:bafybeigo5vst3zlltkouenwxuzn6c47yr2fbbml6dl2o32rfnsezmalgnu -- valory/p2p_libp2p_client:0.1.0:bafybeihge56dn3xep2dzomu7rtvbgo4uc2qqh7ljl3fubqdi2lq44gs5lq +- valory/abci:0.1.0:bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina +- valory/http_client:0.23.0:bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y +- valory/ipfs:0.1.0:bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e +- valory/ledger:0.19.0:bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a +- valory/p2p_libp2p_client:0.1.0:bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq contracts: -- valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci -- valory/gnosis_safe_proxy_factory:0.1.0:bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y -- valory/service_registry:0.1.0:bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu +- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm +- valory/gnosis_safe_proxy_factory:0.1.0:bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274 +- valory/service_registry:0.1.0:bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu - valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m - valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi -- valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y +- valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u - valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga - valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa - valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e - valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 protocols: -- open_aea/signing:1.0.0:bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii -- valory/abci:0.1.0:bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu -- valory/acn:1.1.0:bafybeic2pxzfc3voxl2ejhcqyf2ehm4wm5gxvgx7bliloiqi2uppmq6weu -- valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka -- valory/http:1.0.0:bafybeiejoqgv7finfxo3rcvvovrlj5ccrbgxodjq43uo26ylpowsa3llfe -- valory/ipfs:0.1.0:bafybeiedxeismnx3k5ty4mvvhlqideixlhqmi5mtcki4lxqfa7uqh7p33u -- valory/ledger_api:1.0.0:bafybeige5agrztgzfevyglf7mb4o7pzfttmq4f6zi765y4g2zvftbyowru -- valory/tendermint:0.1.0:bafybeig6g6twajlwssfbfp5rlnu5mwzuu5kgak5cs4fich7rlkx6whesnu +- open_aea/signing:1.0.0:bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m +- valory/abci:0.1.0:bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe +- valory/acn:1.1.0:bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa +- valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa +- valory/http:1.0.0:bafybeia5bxdua2i6chw6pg47bvoljzcpuqxzy4rdrorbdmcbnwmnfdobtu +- valory/ipfs:0.1.0:bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa +- valory/ledger_api:1.0.0:bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby +- valory/tendermint:0.1.0:bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa skills: -- valory/abstract_abci:0.1.0:bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/registration_abci:0.1.0:bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm -- valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe -- valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy -- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi -- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm -- valory/trader_abci:0.1.0:bafybeigxrvqhwo5dgdnotxx5hdpemsp7tyljw5ruagrk3rs46ptbayjika +- valory/abstract_abci:0.1.0:bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li +- valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu +- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeic23djnpzskpjtko4e3yoq6g3oetvynr7rtvacshvcxubhkfavjey +- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq +- valory/decision_maker_abci:0.1.0:bafybeiaeh5g4nilyiudnn5y3xw2q7rnqgsluiwt2ufyptr2v6f47i5eu5m +- valory/trader_abci:0.1.0:bafybeiawahh3lswqcskavbnm46537rkaiej2lf3dnnqbnxn52fh7kxgz5q default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index cb1711ecb..bf7b710bc 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeif7xd3mil4ifohqmhdfbvfbhakeu57duubym45igvezlmbfzqxngi +agent: valory/trader:0.1.0:bafybeiekcyq54ipoqqnylkufyw4smouef7t5xu6gsu6y7t4go5ib42vupu number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 6dc5f7148..ddad9e15f 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeidny4y4w4jbjbp5d5qivur6jm37fnuik4mqzchzshiuvpozxe7vwy behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeicoogphhr3acovqgrfxkivzjjuorua2vin3jyfo53sirmwveri7ru + behaviours/decision_receive.py: bafybeig6uf5uonbrcutoboplxagqsssh2prlzrlplzkmnoiqrzukzpgumi behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga @@ -25,7 +25,7 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeifgao43trxhykd22nkriav4gsi4rxdqllfe2n7y5q2tafrvbnpl3y + models.py: bafybeiag5eajdmxavqsne3n74uthi3umzwtpuwc6bjbai633ich3kza6he payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm @@ -44,21 +44,21 @@ fingerprint: fingerprint_ignore_patterns: [] connections: [] contracts: -- valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci +- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm - valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m - valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi -- valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y +- valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u - valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga - valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa - valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e - valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 - valory/agent_registry:0.1.0:bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty protocols: -- valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka +- valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa skills: -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui behaviours: main: args: {} diff --git a/packages/valory/skills/market_manager_abci/skill.yaml b/packages/valory/skills/market_manager_abci/skill.yaml index e7edd85e7..790727458 100644 --- a/packages/valory/skills/market_manager_abci/skill.yaml +++ b/packages/valory/skills/market_manager_abci/skill.yaml @@ -26,7 +26,7 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq behaviours: main: args: {} diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 42f78e2cb..0d729dc71 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -19,14 +19,14 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/registration_abci:0.1.0:bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm -- valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe -- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy -- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li +- valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm +- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq +- valory/decision_maker_abci:0.1.0:bafybeiaeh5g4nilyiudnn5y3xw2q7rnqgsluiwt2ufyptr2v6f47i5eu5m +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeic23djnpzskpjtko4e3yoq6g3oetvynr7rtvacshvcxubhkfavjey behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 2f66c404f..1a0699841 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -19,8 +19,8 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/decision_maker_abci:0.1.0:bafybeiaeh5g4nilyiudnn5y3xw2q7rnqgsluiwt2ufyptr2v6f47i5eu5m behaviours: main: args: {} From 5e0d810e3f88bab700b70d55e6fc1fec0d07e4aa Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 13:57:21 +0200 Subject: [PATCH 16/79] fix: Manually resolve dependencies --- packages/packages.json | 24 +- packages/valory/agents/trader/aea-config.yaml | 18 +- .../contracts/agent_registry/contract.yaml | 8 +- .../conditional_tokens/contract.yaml | 4 +- packages/valory/contracts/erc20/contract.yaml | 8 +- .../contracts/market_maker/contract.yaml | 8 +- packages/valory/contracts/mech/contract.yaml | 6 +- .../valory/contracts/realitio/contract.yaml | 4 +- .../contracts/realitio_proxy/contract.yaml | 4 +- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/skill.yaml | 18 +- packages/valory/skills/trader_abci/skill.yaml | 4 +- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- poetry.lock | 362 ++++++------------ pyproject.toml | 14 +- 15 files changed, 188 insertions(+), 298 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 7735d5bc1..aa0c50002 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,18 +1,18 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeiaeh5g4nilyiudnn5y3xw2q7rnqgsluiwt2ufyptr2v6f47i5eu5m", - "skill/valory/trader_abci/0.1.0": "bafybeiawahh3lswqcskavbnm46537rkaiej2lf3dnnqbnxn52fh7kxgz5q", - "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeiekcyq54ipoqqnylkufyw4smouef7t5xu6gsu6y7t4go5ib42vupu", - "service/valory/trader/0.1.0": "bafybeigwrlmdxvxfabm53smdidlxhk3ke6j2gniyydvw4fwnmn2l3ygtri", - "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeic23djnpzskpjtko4e3yoq6g3oetvynr7rtvacshvcxubhkfavjey", - "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", - "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", - "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", - "contract/valory/conditional_tokens/0.1.0": "bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa", - "contract/valory/agent_registry/0.1.0": "bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty" + "skill/valory/decision_maker_abci/0.1.0": "bafybeidplpifszhmzhlgaukjfkztoydzfjy4piutpl26el2gns7iau52fe", + "skill/valory/trader_abci/0.1.0": "bafybeid4ywlzf4yop7ieptxbhjj6brysp7ysjuucjc27p6sgmq54pfilwm", + "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", + "agent/valory/trader/0.1.0": "bafybeicg6laukuhbs4rq3e54smlj34bsu7riu5a3ze6ttlbesubpuh3a2u", + "service/valory/trader/0.1.0": "bafybeidipprg2nu3xs4ml3lwxotcbikfwfaswhjyflsudaultxhkmvyfwa", + "contract/valory/erc20/0.1.0": "bafybeicsvxv6anl5zdlovfboftqknzqyzisyuxlkcqlespvbyv7ubga3te", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicjghsfbez3qgpwlwrrelepbhqsqmvc5q7vdhzp6ryqnjavugdxsm", + "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", + "contract/valory/realitio/0.1.0": "bafybeibzyfaeaxgyqnygtduhprs47fhtskh2vnmw2cvpemqhkgc72q4wpm", + "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", + "contract/valory/conditional_tokens/0.1.0": "bafybeigdarm2ssng3uuehlxto75um4hbp47rdi5si6bvv7asdopqsidbhq", + "contract/valory/agent_registry/0.1.0": "bafybeigpd6wvnbb7fbf6yd77rugepv5hrbb6l3qfodstwgemagtcgne3bm" }, "third_party": { "protocol/open_aea/signing/1.0.0": "bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 9fb0ea539..e56359221 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -18,13 +18,13 @@ contracts: - valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm - valory/gnosis_safe_proxy_factory:0.1.0:bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274 - valory/service_registry:0.1.0:bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu -- valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m -- valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi +- valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu +- valory/erc20:0.1.0:bafybeicsvxv6anl5zdlovfboftqknzqyzisyuxlkcqlespvbyv7ubga3te - valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u -- valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga -- valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa -- valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e -- valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 +- valory/mech:0.1.0:bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq +- valory/conditional_tokens:0.1.0:bafybeigdarm2ssng3uuehlxto75um4hbp47rdi5si6bvv7asdopqsidbhq +- valory/realitio:0.1.0:bafybeibzyfaeaxgyqnygtduhprs47fhtskh2vnmw2cvpemqhkgc72q4wpm +- valory/realitio_proxy:0.1.0:bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy protocols: - open_aea/signing:1.0.0:bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m - valory/abci:0.1.0:bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeic23djnpzskpjtko4e3yoq6g3oetvynr7rtvacshvcxubhkfavjey +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicjghsfbez3qgpwlwrrelepbhqsqmvc5q7vdhzp6ryqnjavugdxsm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeiaeh5g4nilyiudnn5y3xw2q7rnqgsluiwt2ufyptr2v6f47i5eu5m -- valory/trader_abci:0.1.0:bafybeiawahh3lswqcskavbnm46537rkaiej2lf3dnnqbnxn52fh7kxgz5q +- valory/decision_maker_abci:0.1.0:bafybeidplpifszhmzhlgaukjfkztoydzfjy4piutpl26el2gns7iau52fe +- valory/trader_abci:0.1.0:bafybeid4ywlzf4yop7ieptxbhjj6brysp7ysjuucjc27p6sgmq54pfilwm default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/contracts/agent_registry/contract.yaml b/packages/valory/contracts/agent_registry/contract.yaml index e7c0f8247..0bc8aa01e 100644 --- a/packages/valory/contracts/agent_registry/contract.yaml +++ b/packages/valory/contracts/agent_registry/contract.yaml @@ -16,8 +16,8 @@ contract_interface_paths: ethereum: build/AgentRegistry.json dependencies: open-aea-ledger-ethereum: - version: ==1.41.0 + version: ==1.39.0.post1 open-aea-test-autonomy: - version: ==0.13.1 - web3: - version: <7,>=6.0.0 + version: ==0.12.1.post4 + open-aea-web3: + version: ==6.0.1 diff --git a/packages/valory/contracts/conditional_tokens/contract.yaml b/packages/valory/contracts/conditional_tokens/contract.yaml index e27735501..c2b7a5395 100644 --- a/packages/valory/contracts/conditional_tokens/contract.yaml +++ b/packages/valory/contracts/conditional_tokens/contract.yaml @@ -15,8 +15,8 @@ contract_interface_paths: ethereum: build/ConditionalTokens.json dependencies: hexbytes: {} - web3: - version: <7,>=6.0.0 + open-aea-web3: + version: ==6.0.1 requests: version: ==2.28.2 urllib3: diff --git a/packages/valory/contracts/erc20/contract.yaml b/packages/valory/contracts/erc20/contract.yaml index 5144da9de..9dc68b5e8 100644 --- a/packages/valory/contracts/erc20/contract.yaml +++ b/packages/valory/contracts/erc20/contract.yaml @@ -21,11 +21,11 @@ dependencies: eth_typing: {} hexbytes: {} open-aea-ledger-ethereum: - version: ==1.41.0 + version: ==1.39.0.post1 open-aea-test-autonomy: - version: ==0.13.1 + version: ==0.12.1.post4 packaging: {} py-eth-sig-utils: {} requests: {} - web3: - version: <7,>=6.0.0 + open-aea-web3: + version: ==6.0.1 diff --git a/packages/valory/contracts/market_maker/contract.yaml b/packages/valory/contracts/market_maker/contract.yaml index 919086dc2..e9de76b50 100644 --- a/packages/valory/contracts/market_maker/contract.yaml +++ b/packages/valory/contracts/market_maker/contract.yaml @@ -21,11 +21,11 @@ dependencies: eth_typing: {} hexbytes: {} open-aea-ledger-ethereum: - version: ==1.41.0 + version: ==1.39.0.post1 open-aea-test-autonomy: - version: ==0.13.1 + version: ==0.12.1.post4 packaging: {} py-eth-sig-utils: {} requests: {} - web3: - version: <7,>=6.0.0 + open-aea-web3: + version: ==6.0.1 diff --git a/packages/valory/contracts/mech/contract.yaml b/packages/valory/contracts/mech/contract.yaml index 09b70c259..6afb8cdfc 100644 --- a/packages/valory/contracts/mech/contract.yaml +++ b/packages/valory/contracts/mech/contract.yaml @@ -17,7 +17,7 @@ contract_interface_paths: ethereum: build/mech.json dependencies: open-aea-ledger-ethereum: - version: ==1.41.0 - web3: - version: <7,>=6.0.0 + version: ==1.39.0.post1 + open-aea-web3: + version: ==6.0.1 eth_typing: {} diff --git a/packages/valory/contracts/realitio/contract.yaml b/packages/valory/contracts/realitio/contract.yaml index 3ec5122b9..be55574c2 100644 --- a/packages/valory/contracts/realitio/contract.yaml +++ b/packages/valory/contracts/realitio/contract.yaml @@ -16,8 +16,8 @@ contract_interface_paths: dependencies: eth_typing: {} hexbytes: {} - web3: - version: <7,>=6.0.0 + open-aea-web3: + version: ==6.0.1 requests: version: ==2.28.2 urllib3: diff --git a/packages/valory/contracts/realitio_proxy/contract.yaml b/packages/valory/contracts/realitio_proxy/contract.yaml index 3adbb2eea..944ffb161 100644 --- a/packages/valory/contracts/realitio_proxy/contract.yaml +++ b/packages/valory/contracts/realitio_proxy/contract.yaml @@ -14,6 +14,6 @@ class_name: RealitioProxyContract contract_interface_paths: ethereum: build/Realitio.json dependencies: - web3: - version: <7,>=6.0.0 + open-aea-web3: + version: ==6.0.1 contracts: [] diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index bf7b710bc..cc2cd3ffb 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiekcyq54ipoqqnylkufyw4smouef7t5xu6gsu6y7t4go5ib42vupu +agent: valory/trader:0.1.0:bafybeicg6laukuhbs4rq3e54smlj34bsu7riu5a3ze6ttlbesubpuh3a2u number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index ddad9e15f..a903900e4 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -45,14 +45,14 @@ fingerprint_ignore_patterns: [] connections: [] contracts: - valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm -- valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m -- valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi +- valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu +- valory/erc20:0.1.0:bafybeicsvxv6anl5zdlovfboftqknzqyzisyuxlkcqlespvbyv7ubga3te - valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u -- valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga -- valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa -- valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e -- valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 -- valory/agent_registry:0.1.0:bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty +- valory/mech:0.1.0:bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq +- valory/conditional_tokens:0.1.0:bafybeigdarm2ssng3uuehlxto75um4hbp47rdi5si6bvv7asdopqsidbhq +- valory/realitio:0.1.0:bafybeibzyfaeaxgyqnygtduhprs47fhtskh2vnmw2cvpemqhkgc72q4wpm +- valory/realitio_proxy:0.1.0:bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy +- valory/agent_registry:0.1.0:bafybeigpd6wvnbb7fbf6yd77rugepv5hrbb6l3qfodstwgemagtcgne3bm protocols: - valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa skills: @@ -241,6 +241,6 @@ dependencies: version: ==1.0.3 py-multicodec: version: ==0.2.1 - web3: - version: <7,>=6.0.0 + open-aea-web3: + version: ==6.0.1 is_abstract: true diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 0d729dc71..0b72d13a4 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui - valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm - valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeiaeh5g4nilyiudnn5y3xw2q7rnqgsluiwt2ufyptr2v6f47i5eu5m -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeic23djnpzskpjtko4e3yoq6g3oetvynr7rtvacshvcxubhkfavjey +- valory/decision_maker_abci:0.1.0:bafybeidplpifszhmzhlgaukjfkztoydzfjy4piutpl26el2gns7iau52fe +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicjghsfbez3qgpwlwrrelepbhqsqmvc5q7vdhzp6ryqnjavugdxsm behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 1a0699841..3e62b26f8 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeiaeh5g4nilyiudnn5y3xw2q7rnqgsluiwt2ufyptr2v6f47i5eu5m +- valory/decision_maker_abci:0.1.0:bafybeidplpifszhmzhlgaukjfkztoydzfjy4piutpl26el2gns7iau52fe behaviours: main: args: {} diff --git a/poetry.lock b/poetry.lock index 7703917ce..bfad880b4 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,10 +1,9 @@ -# This file is automatically @generated by Poetry 1.4.2 and should not be changed by hand. +# This file is automatically @generated by Poetry 1.6.1 and should not be changed by hand. [[package]] name = "aiohttp" version = "3.7.4.post0" description = "Async http client/server framework (asyncio)" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -62,7 +61,6 @@ speedups = ["aiodns", "brotlipy", "cchardet"] name = "asn1crypto" version = "1.4.0" description = "Fast ASN.1 parser and serializer with definitions for private keys, public keys, certificates, CRL, OCSP, CMS, PKCS#3, PKCS#7, PKCS#8, PKCS#12, PKCS#5, X.509 and TSP" -category = "main" optional = false python-versions = "*" files = [ @@ -74,7 +72,6 @@ files = [ name = "async-timeout" version = "3.0.1" description = "Timeout context manager for asyncio programs" -category = "main" optional = false python-versions = ">=3.5.3" files = [ @@ -86,7 +83,6 @@ files = [ name = "attrs" version = "23.1.0" description = "Classes Without Boilerplate" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -105,7 +101,6 @@ tests-no-zope = ["cloudpickle", "hypothesis", "mypy (>=1.1.1)", "pympler", "pyte name = "base58" version = "2.1.1" description = "Base58 and Base58Check implementation." -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -120,7 +115,6 @@ tests = ["PyHamcrest (>=2.0.2)", "mypy", "pytest (>=4.6)", "pytest-benchmark", " name = "bcrypt" version = "4.0.1" description = "Modern password hashing for your software and your servers" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -155,7 +149,6 @@ typecheck = ["mypy"] name = "bech32" version = "1.2.0" description = "Reference implementation for Bech32 and segwit addresses." -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -167,7 +160,6 @@ files = [ name = "bitarray" version = "2.8.2" description = "efficient arrays of booleans -- C extension" -category = "main" optional = false python-versions = "*" files = [ @@ -299,7 +291,6 @@ files = [ name = "blspy" version = "2.0.2" description = "BLS signatures in c++ (python bindings)" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -337,7 +328,6 @@ wheel = "*" name = "cached-property" version = "1.5.2" description = "A decorator for caching properties in classes." -category = "main" optional = false python-versions = "*" files = [ @@ -349,7 +339,6 @@ files = [ name = "cachetools" version = "5.3.1" description = "Extensible memoizing collections and decorators" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -361,7 +350,6 @@ files = [ name = "cbor2" version = "5.4.6" description = "CBOR (de)serializer with extensive tag support" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -411,7 +399,6 @@ test = ["pytest", "pytest-cov"] name = "certifi" version = "2023.7.22" description = "Python package for providing Mozilla's CA Bundle." -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -423,7 +410,6 @@ files = [ name = "cffi" version = "1.16.0" description = "Foreign Function Interface for Python calling C code." -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -488,7 +474,6 @@ pycparser = "*" name = "chardet" version = "4.0.0" description = "Universal encoding detector for Python 2 and 3" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -500,7 +485,6 @@ files = [ name = "charset-normalizer" version = "3.3.0" description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "main" optional = false python-versions = ">=3.7.0" files = [ @@ -600,7 +584,6 @@ files = [ name = "click" version = "8.0.2" description = "Composable command line interface toolkit" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -615,7 +598,6 @@ colorama = {version = "*", markers = "platform_system == \"Windows\""} name = "coincurve" version = "18.0.0" description = "Cross-platform Python CFFI bindings for libsecp256k1" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -671,7 +653,6 @@ cffi = ">=1.3.0" name = "colorama" version = "0.4.6" description = "Cross-platform colored terminal text." -category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=2.7" files = [ @@ -683,7 +664,6 @@ files = [ name = "coverage" version = "7.3.2" description = "Code coverage measurement for Python" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -751,7 +731,6 @@ toml = ["tomli"] name = "crcmod" version = "1.7" description = "CRC Generator" -category = "main" optional = false python-versions = "*" files = [ @@ -762,7 +741,6 @@ files = [ name = "cryptography" version = "41.0.4" description = "cryptography is a package which provides cryptographic recipes and primitives to Python developers." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -808,7 +786,6 @@ test-randomorder = ["pytest-randomly"] name = "cytoolz" version = "0.12.2" description = "Cython implementation of Toolz: High performance functional utilities" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -917,7 +894,6 @@ cython = ["cython"] name = "distlib" version = "0.3.7" description = "Distribution utilities" -category = "dev" optional = false python-versions = "*" files = [ @@ -929,7 +905,6 @@ files = [ name = "distro" version = "1.8.0" description = "Distro - an OS platform information API" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -941,7 +916,6 @@ files = [ name = "docker" version = "6.1.2" description = "A Python library for the Docker Engine API." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -964,7 +938,6 @@ ssh = ["paramiko (>=2.4.3)"] name = "dockerpty" version = "0.4.1" description = "Python library to use the pseudo-tty of a docker container" -category = "main" optional = false python-versions = "*" files = [ @@ -978,7 +951,6 @@ six = ">=1.3.0" name = "docopt" version = "0.6.2" description = "Pythonic argument parser, that will make you smile" -category = "main" optional = false python-versions = "*" files = [ @@ -989,7 +961,6 @@ files = [ name = "ecdsa" version = "0.16.1" description = "ECDSA cryptographic signature library (pure python)" -category = "main" optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -1008,7 +979,6 @@ gmpy2 = ["gmpy2"] name = "ed25519-blake2b" version = "1.4" description = "Ed25519 public-key signatures (BLAKE2b fork)" -category = "main" optional = false python-versions = "*" files = [ @@ -1019,7 +989,6 @@ files = [ name = "eth-abi" version = "4.0.0" description = "eth_abi: Python utilities for working with Ethereum ABI definitions, especially encoding and decoding" -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -1043,7 +1012,6 @@ tools = ["hypothesis (>=4.18.2,<5.0.0)"] name = "eth-account" version = "0.8.0" description = "eth-account: Sign Ethereum transactions and messages with local private keys" -category = "main" optional = false python-versions = ">=3.6, <4" files = [ @@ -1071,7 +1039,6 @@ test = ["coverage", "hypothesis (>=4.18.0,<5)", "pytest (>=6.2.5,<7)", "pytest-x name = "eth-hash" version = "0.5.2" description = "eth-hash: The Ethereum hashing function, keccak256, sometimes (erroneously) called sha3" -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -1094,7 +1061,6 @@ test = ["pytest (>=7.0.0)", "pytest-xdist (>=2.4.0)"] name = "eth-keyfile" version = "0.6.1" description = "A library for handling the encrypted keyfiles used to store ethereum private keys." -category = "main" optional = false python-versions = "*" files = [ @@ -1117,7 +1083,6 @@ test = ["pytest (>=6.2.5,<7)"] name = "eth-keys" version = "0.4.0" description = "Common API for Ethereum key operations." -category = "main" optional = false python-versions = "*" files = [ @@ -1140,7 +1105,6 @@ test = ["asn1tools (>=0.146.2,<0.147)", "eth-hash[pycryptodome]", "eth-hash[pysh name = "eth-rlp" version = "0.3.0" description = "eth-rlp: RLP definitions for common Ethereum objects in Python" -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -1163,7 +1127,6 @@ test = ["eth-hash[pycryptodome]", "pytest (>=6.2.5,<7)", "pytest-xdist", "tox (= name = "eth-typing" version = "3.5.0" description = "eth-typing: Common type annotations for ethereum python packages" -category = "main" optional = false python-versions = ">=3.7.2, <4" files = [ @@ -1184,7 +1147,6 @@ test = ["pytest (>=7.0.0)", "pytest-xdist (>=2.4.0)"] name = "eth-utils" version = "2.2.0" description = "eth-utils: Common utility functions for python code that interacts with Ethereum" -category = "main" optional = false python-versions = ">=3.7,<4" files = [ @@ -1208,7 +1170,6 @@ test = ["hypothesis (>=4.43.0)", "mypy (==0.971)", "pytest (>=7.0.0)", "pytest-x name = "exceptiongroup" version = "1.1.3" description = "Backport of PEP 654 (exception groups)" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1223,7 +1184,6 @@ test = ["pytest (>=6)"] name = "filelock" version = "3.12.4" description = "A platform independent file lock." -category = "dev" optional = false python-versions = ">=3.8" files = [ @@ -1240,7 +1200,6 @@ typing = ["typing-extensions (>=4.7.1)"] name = "flask" version = "2.1.3" description = "A simple framework for building complex web applications." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1262,7 +1221,6 @@ dotenv = ["python-dotenv"] name = "google-api-core" version = "2.12.0" description = "Google API client core library" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1283,18 +1241,17 @@ grpcio-gcp = ["grpcio-gcp (>=0.2.2,<1.0.dev0)"] [[package]] name = "google-api-python-client" -version = "2.103.0" +version = "2.104.0" description = "Google API Client Library for Python" -category = "main" optional = false python-versions = ">=3.7" files = [ - {file = "google-api-python-client-2.103.0.tar.gz", hash = "sha256:5b48dc23913b9a1b447991add03f27c335831559b5a870c522316eae671caf44"}, - {file = "google_api_python_client-2.103.0-py2.py3-none-any.whl", hash = "sha256:5d6cf80cc34598a85b73e7e689e6eb1ba34f342095aeab9ec408f94521382a7c"}, + {file = "google-api-python-client-2.104.0.tar.gz", hash = "sha256:bbc66520e7fe9417b93fd113f2a0a1afa789d686de9009b6e94e48fdea50a60f"}, + {file = "google_api_python_client-2.104.0-py2.py3-none-any.whl", hash = "sha256:867061526aa6dc6c1481d118e913a8a38a02a01eed589413968397ebd77df71d"}, ] [package.dependencies] -google-api-core = ">=1.31.5,<2.0.0 || >2.3.0,<3.0.0.dev0" +google-api-core = ">=1.31.5,<2.0.dev0 || >2.3.0,<3.0.0.dev0" google-auth = ">=1.19.0,<3.0.0.dev0" google-auth-httplib2 = ">=0.1.0" httplib2 = ">=0.15.0,<1.dev0" @@ -1304,7 +1261,6 @@ uritemplate = ">=3.0.1,<5" name = "google-auth" version = "2.23.3" description = "Google Authentication Library" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1328,7 +1284,6 @@ requests = ["requests (>=2.20.0,<3.0.0.dev0)"] name = "google-auth-httplib2" version = "0.1.1" description = "Google Authentication Library: httplib2 transport" -category = "main" optional = false python-versions = "*" files = [ @@ -1342,14 +1297,13 @@ httplib2 = ">=0.19.0" [[package]] name = "googleapis-common-protos" -version = "1.60.0" +version = "1.61.0" description = "Common protobufs used in Google APIs" -category = "main" optional = false python-versions = ">=3.7" files = [ - {file = "googleapis-common-protos-1.60.0.tar.gz", hash = "sha256:e73ebb404098db405ba95d1e1ae0aa91c3e15a71da031a2eeb6b2e23e7bc3708"}, - {file = "googleapis_common_protos-1.60.0-py2.py3-none-any.whl", hash = "sha256:69f9bbcc6acde92cab2db95ce30a70bd2b81d20b12eff3f1aabaffcbe8a93918"}, + {file = "googleapis-common-protos-1.61.0.tar.gz", hash = "sha256:8a64866a97f6304a7179873a465d6eee97b7a24ec6cfd78e0f575e96b821240b"}, + {file = "googleapis_common_protos-1.61.0-py2.py3-none-any.whl", hash = "sha256:22f1915393bb3245343f6efe87f6fe868532efc12aa26b391b15132e1279f1c0"}, ] [package.dependencies] @@ -1362,7 +1316,6 @@ grpc = ["grpcio (>=1.44.0,<2.0.0.dev0)"] name = "grpcio" version = "1.53.0" description = "HTTP/2-based RPC framework" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1420,7 +1373,6 @@ protobuf = ["grpcio-tools (>=1.53.0)"] name = "hexbytes" version = "0.3.1" description = "hexbytes: Python `bytes` subclass that decodes hex, with a readable console output" -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -1438,7 +1390,6 @@ test = ["eth-utils (>=1.0.1,<3)", "hypothesis (>=3.44.24,<=6.31.6)", "pytest (>= name = "httplib2" version = "0.22.0" description = "A comprehensive HTTP client library." -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -1453,7 +1404,6 @@ pyparsing = {version = ">=2.4.2,<3.0.0 || >3.0.0,<3.0.1 || >3.0.1,<3.0.2 || >3.0 name = "hypothesis" version = "6.21.6" description = "A library for property-based testing" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -1485,7 +1435,6 @@ zoneinfo = ["backports.zoneinfo (>=0.2.1)", "importlib-resources (>=3.3.0)", "tz name = "idna" version = "3.4" description = "Internationalized Domain Names in Applications (IDNA)" -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -1497,7 +1446,6 @@ files = [ name = "iniconfig" version = "2.0.0" description = "brain-dead simple config-ini parsing" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1509,7 +1457,6 @@ files = [ name = "ipfshttpclient" version = "0.8.0a2" description = "Python IPFS HTTP CLIENT library" -category = "main" optional = false python-versions = ">=3.6.2,!=3.7.0,!=3.7.1" files = [ @@ -1525,7 +1472,6 @@ requests = ">=2.11" name = "itsdangerous" version = "2.1.2" description = "Safely pass data to untrusted environments and back." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1537,7 +1483,6 @@ files = [ name = "jinja2" version = "3.1.2" description = "A very fast and expressive template engine." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1555,7 +1500,6 @@ i18n = ["Babel (>=2.7)"] name = "jsonschema" version = "4.19.0" description = "An implementation of JSON Schema validation for Python" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -1577,7 +1521,6 @@ format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339- name = "jsonschema-specifications" version = "2023.7.1" description = "The JSON Schema meta-schemas and vocabularies, exposed as a Registry" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -1592,7 +1535,6 @@ referencing = ">=0.28.0" name = "lru-dict" version = "1.2.0" description = "An Dict like LRU container." -category = "main" optional = false python-versions = "*" files = [ @@ -1687,7 +1629,6 @@ test = ["pytest"] name = "markupsafe" version = "2.1.3" description = "Safely add untrusted strings to HTML/XML markup." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1711,6 +1652,16 @@ files = [ {file = "MarkupSafe-2.1.3-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:5bbe06f8eeafd38e5d0a4894ffec89378b6c6a625ff57e3028921f8ff59318ac"}, {file = "MarkupSafe-2.1.3-cp311-cp311-win32.whl", hash = "sha256:dd15ff04ffd7e05ffcb7fe79f1b98041b8ea30ae9234aed2a9168b5797c3effb"}, {file = "MarkupSafe-2.1.3-cp311-cp311-win_amd64.whl", hash = "sha256:134da1eca9ec0ae528110ccc9e48041e0828d79f24121a1a146161103c76e686"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:f698de3fd0c4e6972b92290a45bd9b1536bffe8c6759c62471efaa8acb4c37bc"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:aa57bd9cf8ae831a362185ee444e15a93ecb2e344c8e52e4d721ea3ab6ef1823"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ffcc3f7c66b5f5b7931a5aa68fc9cecc51e685ef90282f4a82f0f5e9b704ad11"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:47d4f1c5f80fc62fdd7777d0d40a2e9dda0a05883ab11374334f6c4de38adffd"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1f67c7038d560d92149c060157d623c542173016c4babc0c1913cca0564b9939"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:9aad3c1755095ce347e26488214ef77e0485a3c34a50c5a5e2471dff60b9dd9c"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:14ff806850827afd6b07a5f32bd917fb7f45b046ba40c57abdb636674a8b559c"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:8f9293864fe09b8149f0cc42ce56e3f0e54de883a9de90cd427f191c346eb2e1"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-win32.whl", hash = "sha256:715d3562f79d540f251b99ebd6d8baa547118974341db04f5ad06d5ea3eb8007"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-win_amd64.whl", hash = "sha256:1b8dd8c3fd14349433c79fa8abeb573a55fc0fdd769133baac1f5e07abf54aeb"}, {file = "MarkupSafe-2.1.3-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8e254ae696c88d98da6555f5ace2279cf7cd5b3f52be2b5cf97feafe883b58d2"}, {file = "MarkupSafe-2.1.3-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:cb0932dc158471523c9637e807d9bfb93e06a95cbf010f1a38b98623b929ef2b"}, {file = "MarkupSafe-2.1.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9402b03f1a1b4dc4c19845e5c749e3ab82d5078d16a2a4c2cd2df62d57bb0707"}, @@ -1747,7 +1698,6 @@ files = [ name = "morphys" version = "1.0" description = "Smart conversions between unicode and bytes types for common cases" -category = "main" optional = false python-versions = "*" files = [ @@ -1758,7 +1708,6 @@ files = [ name = "multiaddr" version = "0.0.9" description = "Python implementation of jbenet's multiaddr" -category = "main" optional = false python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" files = [ @@ -1776,7 +1725,6 @@ varint = "*" name = "multidict" version = "6.0.4" description = "multidict implementation" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1860,7 +1808,6 @@ files = [ name = "mypy-extensions" version = "1.0.0" description = "Type system extensions for programs checked with the mypy type checker." -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -1872,7 +1819,6 @@ files = [ name = "netaddr" version = "0.9.0" description = "A network address manipulation library for Python" -category = "main" optional = false python-versions = "*" files = [ @@ -1882,19 +1828,17 @@ files = [ [[package]] name = "open-aea" -version = "1.41.0" +version = "1.39.0.post1" description = "Open Autonomous Economic Agent framework (without vendor lock-in)" -category = "main" optional = false python-versions = ">=3.8" files = [ - {file = "open-aea-1.41.0.tar.gz", hash = "sha256:d9b759e17781b33548f7af6888e2f12f6d039444d54b41958cee1e2f9d7b8f14"}, - {file = "open_aea-1.41.0-py3-none-any.whl", hash = "sha256:c28a4d4150fd41a3f5d2900c13e1814943148d0d9f8fb2e070e5ff65b3b069e5"}, - {file = "open_aea-1.41.0-py3-none-macosx_10_9_x86_64.whl", hash = "sha256:3878d56ae8fa9e313196efab189c4c6e078e45a6e315ae9374845d1d64641166"}, - {file = "open_aea-1.41.0-py3-none-manylinux1_x86_64.whl", hash = "sha256:f3199d38929d56138b6f50e35ee0efb1815e3fa1de9a15ad51aaef7a8757b96a"}, - {file = "open_aea-1.41.0-py3-none-manylinux2014_aarch64.whl", hash = "sha256:df8100a08637dd0d7b6651d88b7f95efcc4403a4849f298a8a5a31a9dd5a17e9"}, - {file = "open_aea-1.41.0-py3-none-win32.whl", hash = "sha256:74c3c1b79b10461fa03e024103ba39e4a04e067e2e45ca19af16fcdcd2eb5dcd"}, - {file = "open_aea-1.41.0-py3-none-win_amd64.whl", hash = "sha256:d14bc82fc53120aa2af20d5fa3b335fa93f98f7a9cfad33799def110c9e82a0d"}, + {file = "open-aea-1.39.0.post1.tar.gz", hash = "sha256:50d9d843ae9a16f4737603d107e4c8293168b92b4a8523cf3a5f51427bd8e94d"}, + {file = "open_aea-1.39.0.post1-py3-none-macosx_10_9_x86_64.whl", hash = "sha256:2cbe5bbdf0edb3e5ee434dd4728353f7f9c9cfe6d0f4c1aa26c1b1f63ecd7733"}, + {file = "open_aea-1.39.0.post1-py3-none-manylinux1_x86_64.whl", hash = "sha256:13b1555ecedd506aa70de9bf3b7d448cc0faf2370a30e8ef9bb099439a7f571d"}, + {file = "open_aea-1.39.0.post1-py3-none-manylinux2014_aarch64.whl", hash = "sha256:c4bf41f668e7a8c8e97d952d7072e823eb08e0893d9016261f0ad34e9bc7b71c"}, + {file = "open_aea-1.39.0.post1-py3-none-win32.whl", hash = "sha256:dfa7af61572c2c738aed6fbe48afe045a1f0ee64342fe4d588d990a9c1e0663d"}, + {file = "open_aea-1.39.0.post1-py3-none-win_amd64.whl", hash = "sha256:77f7e0f5c4c7bebbfe7051fb3610d4696dd43f7ef15d05c1ea1cdfde7fe453ae"}, ] [package.dependencies] @@ -1905,7 +1849,7 @@ ecdsa = ">=0.15,<0.17.0" jsonschema = ">=4.16.0,<=4.19.0" morphys = ">=1.0" packaging = ">=23.1,<24.0" -protobuf = ">=4.21.6,<5.0.0" +protobuf = ">=3.19.0,<4.0.0" py-multibase = ">=1.0.0" py-multicodec = ">=0.2.0" pymultihash = "0.8.2" @@ -1924,7 +1868,6 @@ test-tools = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "jsonschema (>=4.1 name = "open-aea-bip-utils" version = "2.7.2" description = "Generation of mnemonics, seeds, private/public keys and addresses for different types of cryptocurrencies" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1946,14 +1889,13 @@ develop = ["coverage (>=5.3)", "flake8 (>=3.8)", "isort (>=5.8)", "mypy (>=0.900 [[package]] name = "open-aea-cli-ipfs" -version = "1.41.0" +version = "1.39.0.post1" description = "CLI extension for open AEA framework wrapping IPFS functionality." -category = "main" optional = false python-versions = "*" files = [ - {file = "open-aea-cli-ipfs-1.41.0.tar.gz", hash = "sha256:e02cbc05b38205040fbc8659e9dcbf4d05044329a4e9b0496a400186fc3f18f6"}, - {file = "open_aea_cli_ipfs-1.41.0-py3-none-any.whl", hash = "sha256:bebf2ed31f72e99821db481e6a50cecf107001749bf13f29339f1861155fc305"}, + {file = "open-aea-cli-ipfs-1.39.0.post1.tar.gz", hash = "sha256:c70d98343eab15225f1b1339212bb8de7755e2d6b48a38e7961d1174e9904505"}, + {file = "open_aea_cli_ipfs-1.39.0.post1-py3-none-any.whl", hash = "sha256:4cef5729e91fa89016840da1684e552c1f8c75a0cf0b82ea48066d4b841b49e7"}, ] [package.dependencies] @@ -1963,14 +1905,13 @@ pytest = ">=7.0.0,<7.3.0" [[package]] name = "open-aea-cosmpy" -version = "0.6.6" +version = "0.6.5" description = "A library for interacting with the cosmos networks" -category = "main" optional = false python-versions = ">=3.8,<4.0" files = [ - {file = "open_aea_cosmpy-0.6.6-py3-none-any.whl", hash = "sha256:0e8beca421383dce13c19d6d305d96e0905ba3171b97c7d0528e1480fee670dc"}, - {file = "open_aea_cosmpy-0.6.6.tar.gz", hash = "sha256:ae5a40b61fdf4af511e60acb2cdfa3dffef57324e975dcadd87c1f02cf8e6c27"}, + {file = "open_aea_cosmpy-0.6.5-py3-none-any.whl", hash = "sha256:84dee91523e41402f1dc7f1f02e4869ae089ee2a25ad0d577dccfd11448f6b7f"}, + {file = "open_aea_cosmpy-0.6.5.tar.gz", hash = "sha256:922e14166fd48f2a2b726b54390bb74887c5450ac1ff4af32dada6ecea8077da"}, ] [package.dependencies] @@ -1982,74 +1923,104 @@ google-api-python-client = "*" grpcio = "1.53.0" jsonschema = ">=3.2.0,<5" open-aea-bip-utils = "2.7.2" -protobuf = ">=4.21.6,<5" +protobuf = "3.19.5" requests = "*" [[package]] name = "open-aea-ledger-cosmos" -version = "1.41.0" +version = "1.39.0.post1" description = "Python package wrapping the public and private key cryptography and ledger api of Cosmos." -category = "main" optional = false python-versions = "*" files = [ - {file = "open-aea-ledger-cosmos-1.41.0.tar.gz", hash = "sha256:505c11494ecd3b1ba0460b7b346be982cf5de8797d2a53668f06a9d74c92a0d9"}, - {file = "open_aea_ledger_cosmos-1.41.0-py3-none-any.whl", hash = "sha256:3c41ecb17b9378430baf8fafdaf38828e90ed94b6b9ae9ea9965c5ec3a2ee62e"}, + {file = "open-aea-ledger-cosmos-1.39.0.post1.tar.gz", hash = "sha256:ecb0f283fe0e66979ae5dbfbb9e6860d62d646abdb623acc7c69065ad81c31d8"}, + {file = "open_aea_ledger_cosmos-1.39.0.post1-py3-none-any.whl", hash = "sha256:aad946fa52837155ea7f6e0f129af342b58872f1a73532a7972164647ad6e725"}, ] [package.dependencies] bech32 = "1.2.0" ecdsa = ">=0.15,<0.17.0" open-aea = ">=1.0.0,<2.0.0" -open-aea-cosmpy = "0.6.6" +open-aea-cosmpy = "0.6.5" pycryptodome = ">=3.10.1,<4.0.0" [[package]] name = "open-aea-ledger-ethereum" -version = "1.41.0" +version = "1.39.0.post1" description = "Python package wrapping the public and private key cryptography and ledger api of Ethereum." -category = "main" optional = false python-versions = "*" files = [ - {file = "open-aea-ledger-ethereum-1.41.0.tar.gz", hash = "sha256:411f75ee0a313ed88752fe8b50550eaf48cfc02f683c11a5f8a36e1ea10b4a6a"}, - {file = "open_aea_ledger_ethereum-1.41.0-py3-none-any.whl", hash = "sha256:cfb5ee22b9123741af669821bc954ba233eafea8c2880c3d125038c141512dab"}, + {file = "open-aea-ledger-ethereum-1.39.0.post1.tar.gz", hash = "sha256:e1f221c576ca10b542c9dea60efdd170767aa409f38b580776e3cb9480afe0e2"}, + {file = "open_aea_ledger_ethereum-1.39.0.post1-py3-none-any.whl", hash = "sha256:4bbbc2b6756e89fae57bcdc932fa8043770b971da90857740ee692be1b38fadf"}, ] [package.dependencies] eth-account = ">=0.8.0,<0.9.0" ipfshttpclient = "0.8.0a2" open-aea = ">=1.0.0,<2.0.0" -web3 = ">=6.0.0,<7" +open-aea-web3 = "6.0.1" [[package]] name = "open-aea-test-autonomy" -version = "0.13.1" +version = "0.12.1.post4" description = "Plugin containing test tools for open-autonomy packages." -category = "main" optional = false python-versions = "*" files = [ - {file = "open-aea-test-autonomy-0.13.1.tar.gz", hash = "sha256:0e770ff9fc39369bcd4995608b789f466e3287fcb16052aa2d8cb45afdd923b7"}, - {file = "open_aea_test_autonomy-0.13.1-py3-none-any.whl", hash = "sha256:a464e317c57d18073fa2b6837d0637638662edc600bab91214bf113119aa1fc1"}, + {file = "open-aea-test-autonomy-0.12.1.post4.tar.gz", hash = "sha256:c481ac23a59e9ba954ae4d3b1e86fb72982dbdcf5b1e8a351d3eb1c87003b861"}, + {file = "open_aea_test_autonomy-0.12.1.post4-py3-none-any.whl", hash = "sha256:0bdeb2a1d84d3aecfc2c169ff762205fb2c091ffa601846a489678db7d0b01c3"}, ] [package.dependencies] docker = "6.1.2" -open-aea = {version = ">=1.41.0,<2.0.0", extras = ["all"]} -open-aea-ledger-ethereum = ">=1.41.0,<2.0.0" +open-aea = {version = ">=1.39.0.post1,<2.0.0", extras = ["all"]} +open-aea-ledger-ethereum = ">=1.39.0.post1,<2.0.0" pytest = "7.2.1" +[[package]] +name = "open-aea-web3" +version = "6.0.1" +description = "web3.py" +optional = false +python-versions = ">=3.7.2" +files = [ + {file = "open-aea-web3-6.0.1.tar.gz", hash = "sha256:202957204e743c65a10d4df46b39df44c4177a141f9dd29bf44ae0d868eab768"}, + {file = "open_aea_web3-6.0.1-py3-none-any.whl", hash = "sha256:73a90d9c61b76fb4f15909e6a70fc91319428dbf3ee83f3830355abc98f22331"}, +] + +[package.dependencies] +aiohttp = ">=3.7.4.post0" +eth-abi = ">=4.0.0-b.2" +eth-account = ">=0.8.0" +eth-hash = {version = ">=0.5.1", extras = ["pycryptodome"]} +eth-typing = ">=3.0.0" +eth-utils = ">=2.1.0" +hexbytes = ">=0.1.0" +jsonschema = ">=4.0.0" +lru-dict = ">=1.1.6" +parsimonious = "0.9.0" +protobuf = "3.19.5" +pywin32 = {version = ">=223", markers = "platform_system == \"Windows\""} +requests = ">=2.16.0" +websockets = ">=10.0.0" + +[package.extras] +dev = ["black (>=22.1.0)", "build (>=0.9.0)", "bumpversion", "click (>=5.1)", "configparser (==3.5.0)", "contextlib2 (>=0.5.4)", "eth-tester[py-evm] (==v0.8.0-b.3)", "flake8 (==3.8.3)", "flaky (>=3.7.0)", "hypothesis (>=3.31.2)", "importlib-metadata (<5.0)", "ipfshttpclient (==0.8.0a2)", "isort (>=5.11.0)", "mock", "mypy (==0.910)", "pluggy (==0.13.1)", "py-geth (>=3.11.0)", "py-solc-x (>=1.1.1)", "pytest (>=6.2.5)", "pytest-asyncio (>=0.18.1)", "pytest-mock (>=1.10)", "pytest-pythonpath (>=0.3)", "pytest-watch (>=4.2)", "pytest-xdist (>=1.29)", "setuptools (>=38.6.0)", "sphinx (>=4.2.0)", "sphinx-rtd-theme (>=0.5.2)", "toposort (>=1.4)", "towncrier (==18.5.0)", "tox (>=3.18.0)", "tqdm (>4.32)", "twine (>=1.13)", "types-protobuf (==3.19.13)", "types-requests (>=2.26.1)", "types-setuptools (>=57.4.4)", "urllib3", "wheel", "when-changed (>=0.3.0)"] +docs = ["click (>=5.1)", "configparser (==3.5.0)", "contextlib2 (>=0.5.4)", "mock", "py-geth (>=3.11.0)", "py-solc-x (>=1.1.1)", "pytest (>=6.2.5)", "sphinx (>=4.2.0)", "sphinx-rtd-theme (>=0.5.2)", "toposort (>=1.4)", "towncrier (==18.5.0)", "urllib3", "wheel"] +ipfs = ["ipfshttpclient (==0.8.0a2)"] +linter = ["black (>=22.1.0)", "flake8 (==3.8.3)", "isort (>=5.11.0)", "mypy (==0.910)", "types-protobuf (==3.19.13)", "types-requests (>=2.26.1)", "types-setuptools (>=57.4.4)"] +tester = ["eth-tester[py-evm] (==v0.8.0-b.3)", "py-geth (>=3.11.0)"] + [[package]] name = "open-autonomy" -version = "0.13.1" +version = "0.12.1.post4" description = "A framework for the creation of autonomous agent services." -category = "main" optional = false python-versions = ">=3.8" files = [ - {file = "open-autonomy-0.13.1.tar.gz", hash = "sha256:f517f13f78fbb82a71dcf8198346a6f32662c955592869e8e6f63d9743c05d88"}, - {file = "open_autonomy-0.13.1-py3-none-any.whl", hash = "sha256:ddbe81090c883a6a91a18c59fc0b51614a30a22f710ea8135f0e8c1b8f4c617e"}, + {file = "open-autonomy-0.12.1.post4.tar.gz", hash = "sha256:7bd5a2dc3b5720f80ca1290b35def793f958133e37333d93b8883f35281d3cb0"}, + {file = "open_autonomy-0.12.1.post4-py3-none-any.whl", hash = "sha256:e07b51904da87e2cb16ba75eff33b95b5c986c54c634801705c7a71a413876af"}, ] [package.dependencies] @@ -2059,8 +2030,8 @@ docker = "6.1.2" Flask = ">=2.0.2,<3.0.0" hexbytes = "*" jsonschema = ">=4.16.0,<=4.19.0" -open-aea = {version = "1.41.0", extras = ["all"]} -open-aea-cli-ipfs = "1.41.0" +open-aea = {version = "1.39.0.post1", extras = ["all"]} +open-aea-cli-ipfs = "1.39.0.post1" pytest = "7.2.1" python-dotenv = ">=0.14.0,<0.18.0" texttable = "1.6.7" @@ -2069,14 +2040,13 @@ watchdog = ">=2.1.6" werkzeug = "2.0.3" [package.extras] -all = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.41.0)", "pytest (>=7.0.0,<7.3.0)", "python-dotenv (>=0.14.0,<0.18.0)", "texttable (==1.6.7)"] -cli = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.41.0)", "pytest (>=7.0.0,<7.3.0)", "python-dotenv (>=0.14.0,<0.18.0)", "texttable (==1.6.7)"] +all = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.39.0.post1)", "pytest (>=7.0.0,<7.3.0)", "python-dotenv (>=0.14.0,<0.18.0)", "texttable (==1.6.7)"] +cli = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.39.0.post1)", "pytest (>=7.0.0,<7.3.0)", "python-dotenv (>=0.14.0,<0.18.0)", "texttable (==1.6.7)"] [[package]] name = "packaging" version = "23.2" description = "Core utilities for Python packages" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2088,7 +2058,6 @@ files = [ name = "paramiko" version = "3.3.1" description = "SSH2 protocol library" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -2110,7 +2079,6 @@ invoke = ["invoke (>=2.0)"] name = "parsimonious" version = "0.9.0" description = "(Soon to be) the fastest pure-Python PEG parser I could muster" -category = "main" optional = false python-versions = "*" files = [ @@ -2124,7 +2092,6 @@ regex = ">=2022.3.15" name = "platformdirs" version = "3.11.0" description = "A small Python package for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2140,7 +2107,6 @@ test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=7.4)", "pytest-co name = "pluggy" version = "1.3.0" description = "plugin and hook calling mechanisms for python" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -2154,32 +2120,42 @@ testing = ["pytest", "pytest-benchmark"] [[package]] name = "protobuf" -version = "4.24.4" -description = "" -category = "main" +version = "3.19.5" +description = "Protocol Buffers" optional = false -python-versions = ">=3.7" +python-versions = ">=3.5" files = [ - {file = "protobuf-4.24.4-cp310-abi3-win32.whl", hash = "sha256:ec9912d5cb6714a5710e28e592ee1093d68c5ebfeda61983b3f40331da0b1ebb"}, - {file = "protobuf-4.24.4-cp310-abi3-win_amd64.whl", hash = "sha256:1badab72aa8a3a2b812eacfede5020472e16c6b2212d737cefd685884c191085"}, - {file = "protobuf-4.24.4-cp37-abi3-macosx_10_9_universal2.whl", hash = "sha256:8e61a27f362369c2f33248a0ff6896c20dcd47b5d48239cb9720134bef6082e4"}, - {file = "protobuf-4.24.4-cp37-abi3-manylinux2014_aarch64.whl", hash = "sha256:bffa46ad9612e6779d0e51ae586fde768339b791a50610d85eb162daeb23661e"}, - {file = "protobuf-4.24.4-cp37-abi3-manylinux2014_x86_64.whl", hash = "sha256:b493cb590960ff863743b9ff1452c413c2ee12b782f48beca77c8da3e2ffe9d9"}, - {file = "protobuf-4.24.4-cp37-cp37m-win32.whl", hash = "sha256:dbbed8a56e56cee8d9d522ce844a1379a72a70f453bde6243e3c86c30c2a3d46"}, - {file = "protobuf-4.24.4-cp37-cp37m-win_amd64.whl", hash = "sha256:6b7d2e1c753715dcfe9d284a25a52d67818dd43c4932574307daf836f0071e37"}, - {file = "protobuf-4.24.4-cp38-cp38-win32.whl", hash = "sha256:02212557a76cd99574775a81fefeba8738d0f668d6abd0c6b1d3adcc75503dbe"}, - {file = "protobuf-4.24.4-cp38-cp38-win_amd64.whl", hash = "sha256:2fa3886dfaae6b4c5ed2730d3bf47c7a38a72b3a1f0acb4d4caf68e6874b947b"}, - {file = "protobuf-4.24.4-cp39-cp39-win32.whl", hash = "sha256:b77272f3e28bb416e2071186cb39efd4abbf696d682cbb5dc731308ad37fa6dd"}, - {file = "protobuf-4.24.4-cp39-cp39-win_amd64.whl", hash = "sha256:9fee5e8aa20ef1b84123bb9232b3f4a5114d9897ed89b4b8142d81924e05d79b"}, - {file = "protobuf-4.24.4-py3-none-any.whl", hash = "sha256:80797ce7424f8c8d2f2547e2d42bfbb6c08230ce5832d6c099a37335c9c90a92"}, - {file = "protobuf-4.24.4.tar.gz", hash = "sha256:5a70731910cd9104762161719c3d883c960151eea077134458503723b60e3667"}, + {file = "protobuf-3.19.5-cp310-cp310-manylinux2014_aarch64.whl", hash = "sha256:f2b599a21c9a32e171ec29a2ac54e03297736c578698e11b099d031f79da114b"}, + {file = "protobuf-3.19.5-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f976234e20ab2785f54224bcdafa027674e23663b132fa3ca0caa291a6cfbde7"}, + {file = "protobuf-3.19.5-cp310-cp310-win32.whl", hash = "sha256:4ee2af7051d3b10c8a4fe6fd1a2c69f201fea36aeee7086cf202a692e1b99ee1"}, + {file = "protobuf-3.19.5-cp310-cp310-win_amd64.whl", hash = "sha256:dca2284378a5f2a86ffed35c6ac147d14c48b525eefcd1083e5a9ce28dfa8657"}, + {file = "protobuf-3.19.5-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:c0f80876a8ff0ae7064084ed094eb86497bd5a3812e6fc96a05318b92301674e"}, + {file = "protobuf-3.19.5-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3c4160b601220627f7e91154e572baf5e161a9c3f445a8242d536ee3d0b7b17c"}, + {file = "protobuf-3.19.5-cp36-cp36m-win32.whl", hash = "sha256:f2bde37667b18c2b5280df83bc799204394a5d2d774e4deaf9de0eb741df6833"}, + {file = "protobuf-3.19.5-cp36-cp36m-win_amd64.whl", hash = "sha256:1867f93b06a183f87696871bb8d1e99ee71dbb69d468ce1f0cc8bf3d30f982f3"}, + {file = "protobuf-3.19.5-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a89aa0c042e61e11ade320b802d6db4ee5391d8d973e46d3a48172c1597789f8"}, + {file = "protobuf-3.19.5-cp37-cp37m-manylinux2014_aarch64.whl", hash = "sha256:f9cebda093c2f6bfed88f1c17cdade09d4d96096421b344026feee236532d4de"}, + {file = "protobuf-3.19.5-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67efb5d20618020aa9596e17bfc37ca068c28ec0c1507d9507f73c93d46c9855"}, + {file = "protobuf-3.19.5-cp37-cp37m-win32.whl", hash = "sha256:950abd6c00e7b51f87ae8b18a0ce4d69fea217f62f171426e77de5061f6d9850"}, + {file = "protobuf-3.19.5-cp37-cp37m-win_amd64.whl", hash = "sha256:d3973a2d58aefc7d1230725c2447ce7f86a71cbc094b86a77c6ee1505ac7cdb1"}, + {file = "protobuf-3.19.5-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:9e1d74032f56ff25f417cfe84c8147047732e5059137ca42efad20cbbd25f5e0"}, + {file = "protobuf-3.19.5-cp38-cp38-manylinux2014_aarch64.whl", hash = "sha256:d249519ba5ecf5dd6b18150c9b6bcde510b273714b696f3923ff8308fc11ae49"}, + {file = "protobuf-3.19.5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9f957ef53e872d58a0afd3bf6d80d48535d28c99b40e75e6634cbc33ea42fd54"}, + {file = "protobuf-3.19.5-cp38-cp38-win32.whl", hash = "sha256:5470f892961af464ae6eaf0f3099e2c1190ae8c7f36f174b89491281341f79ca"}, + {file = "protobuf-3.19.5-cp38-cp38-win_amd64.whl", hash = "sha256:c44e3282cff74ad18c7e8a0375f407f69ee50c2116364b44492a196293e08b21"}, + {file = "protobuf-3.19.5-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:66d14b5b90090353efe75c9fb1bf65ef7267383034688d255b500822e37d5c2f"}, + {file = "protobuf-3.19.5-cp39-cp39-manylinux2014_aarch64.whl", hash = "sha256:f4f909f4dde413dec435a44b0894956d55bb928ded7d6e3c726556ca4c796e84"}, + {file = "protobuf-3.19.5-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5266c36cc0af3bb3dbf44f199d225b33da66a9a5c3bdc2b14865ad10eddf0e37"}, + {file = "protobuf-3.19.5-cp39-cp39-win32.whl", hash = "sha256:6a02172b9650f819d01fb8e224fc69b0706458fc1ab4f1c669281243c71c1a5e"}, + {file = "protobuf-3.19.5-cp39-cp39-win_amd64.whl", hash = "sha256:696e6cfab94cc15a14946f2bf72719dced087d437adbd994fff34f38986628bc"}, + {file = "protobuf-3.19.5-py2.py3-none-any.whl", hash = "sha256:9e42b1cf2ecd8a1bd161239e693f22035ba99905ae6d7efeac8a0546c7ec1a27"}, + {file = "protobuf-3.19.5.tar.gz", hash = "sha256:e63b0b3c42e51c94add62b010366cd4979cb6d5f06158bcae8faac4c294f91e1"}, ] [[package]] name = "py" version = "1.11.0" description = "library with cross-python path, ini-parsing, io, code, log facilities" -category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -2191,7 +2167,6 @@ files = [ name = "py-ecc" version = "6.0.0" description = "Elliptic curve crypto in python including secp256k1 and alt_bn128" -category = "main" optional = false python-versions = ">=3.6, <4" files = [ @@ -2214,7 +2189,6 @@ test = ["pytest (==6.2.5)", "pytest-xdist (==1.26.0)"] name = "py-eth-sig-utils" version = "0.4.0" description = "Python Ethereum Signing Utils" -category = "main" optional = false python-versions = "*" files = [ @@ -2232,7 +2206,6 @@ rlp = ">=1.1.0" name = "py-multibase" version = "1.0.3" description = "Multibase implementation for Python" -category = "main" optional = false python-versions = "*" files = [ @@ -2249,7 +2222,6 @@ six = ">=1.10.0,<2.0" name = "py-multicodec" version = "0.2.1" description = "Multicodec implementation in Python" -category = "main" optional = false python-versions = "*" files = [ @@ -2266,7 +2238,6 @@ varint = ">=1.0.2,<2.0.0" name = "py-sr25519-bindings" version = "0.2.0" description = "Python bindings for sr25519 library" -category = "main" optional = false python-versions = "*" files = [ @@ -2339,7 +2310,6 @@ files = [ name = "pyasn1" version = "0.5.0" description = "Pure-Python implementation of ASN.1 types and DER/BER/CER codecs (X.208)" -category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,>=2.7" files = [ @@ -2351,7 +2321,6 @@ files = [ name = "pyasn1-modules" version = "0.3.0" description = "A collection of ASN.1-based protocols modules" -category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,>=2.7" files = [ @@ -2366,7 +2335,6 @@ pyasn1 = ">=0.4.6,<0.6.0" name = "pycparser" version = "2.21" description = "C parser in Python" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -2378,7 +2346,6 @@ files = [ name = "pycryptodome" version = "3.18.0" description = "Cryptographic library for Python" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -2420,7 +2387,6 @@ files = [ name = "pymultihash" version = "0.8.2" description = "Python implementation of the multihash specification" -category = "main" optional = false python-versions = "*" files = [ @@ -2436,7 +2402,6 @@ sha3 = ["pysha3"] name = "pynacl" version = "1.5.0" description = "Python binding to the Networking and Cryptography (NaCl) library" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -2463,7 +2428,6 @@ tests = ["hypothesis (>=3.27.0)", "pytest (>=3.2.1,!=3.3.0)"] name = "pyparsing" version = "3.1.1" description = "pyparsing module - Classes and methods to define and execute parsing grammars" -category = "main" optional = false python-versions = ">=3.6.8" files = [ @@ -2478,7 +2442,6 @@ diagrams = ["jinja2", "railroad-diagrams"] name = "pytest" version = "7.2.1" description = "pytest: simple powerful testing with Python" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2502,7 +2465,6 @@ testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2. name = "pytest-asyncio" version = "0.20.3" description = "Pytest support for asyncio" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2521,7 +2483,6 @@ testing = ["coverage (>=6.2)", "flaky (>=3.5.0)", "hypothesis (>=5.7.1)", "mypy name = "pytest-cov" version = "4.0.0" description = "Pytest plugin for measuring coverage." -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -2540,7 +2501,6 @@ testing = ["fields", "hunter", "process-tests", "pytest-xdist", "six", "virtuale name = "pytest-randomly" version = "3.12.0" description = "Pytest plugin to randomly order tests and control random.seed." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2555,7 +2515,6 @@ pytest = "*" name = "pytest-rerunfailures" version = "11.0" description = "pytest plugin to re-run tests to eliminate flaky failures" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2571,7 +2530,6 @@ pytest = ">=5.3" name = "python-baseconv" version = "1.2.2" description = "Convert numbers from base 10 integers to base X strings and back again." -category = "main" optional = false python-versions = "*" files = [ @@ -2582,7 +2540,6 @@ files = [ name = "python-dotenv" version = "0.17.1" description = "Read key-value pairs from a .env file and set them as environment variables" -category = "main" optional = false python-versions = "*" files = [ @@ -2597,7 +2554,6 @@ cli = ["click (>=5.0)"] name = "pytz" version = "2022.2.1" description = "World timezone definitions, modern and historical" -category = "main" optional = false python-versions = "*" files = [ @@ -2605,22 +2561,10 @@ files = [ {file = "pytz-2022.2.1.tar.gz", hash = "sha256:cea221417204f2d1a2aa03ddae3e867921971d0d76f14d87abb4414415bbdcf5"}, ] -[[package]] -name = "pyunormalize" -version = "15.0.0" -description = "Unicode normalization forms (NFC, NFKC, NFD, NFKD). A library independent from the Python core Unicode database." -category = "main" -optional = false -python-versions = ">=3.6" -files = [ - {file = "pyunormalize-15.0.0.tar.gz", hash = "sha256:e63fdba0d85ea04579dde2fc29a072dba773dcae600b04faf6cc90714c8b1302"}, -] - [[package]] name = "pywin32" version = "306" description = "Python for Window Extensions" -category = "main" optional = false python-versions = "*" files = [ @@ -2644,7 +2588,6 @@ files = [ name = "pyyaml" version = "6.0.1" description = "YAML parser and emitter for Python" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -2653,6 +2596,7 @@ files = [ {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:69b023b2b4daa7548bcfbd4aa3da05b3a74b772db9e23b982788168117739938"}, {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:81e0b275a9ecc9c0c0c07b4b90ba548307583c125f54d5b6946cfee6360c733d"}, {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ba336e390cd8e4d1739f42dfe9bb83a3cc2e80f567d8805e11b46f4a943f5515"}, + {file = "PyYAML-6.0.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:326c013efe8048858a6d312ddd31d56e468118ad4cdeda36c719bf5bb6192290"}, {file = "PyYAML-6.0.1-cp310-cp310-win32.whl", hash = "sha256:bd4af7373a854424dabd882decdc5579653d7868b8fb26dc7d0e99f823aa5924"}, {file = "PyYAML-6.0.1-cp310-cp310-win_amd64.whl", hash = "sha256:fd1592b3fdf65fff2ad0004b5e363300ef59ced41c2e6b3a99d4089fa8c5435d"}, {file = "PyYAML-6.0.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:6965a7bc3cf88e5a1c3bd2e0b5c22f8d677dc88a455344035f03399034eb3007"}, @@ -2660,8 +2604,15 @@ files = [ {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:42f8152b8dbc4fe7d96729ec2b99c7097d656dc1213a3229ca5383f973a5ed6d"}, {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:062582fca9fabdd2c8b54a3ef1c978d786e0f6b3a1510e0ac93ef59e0ddae2bc"}, {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d2b04aac4d386b172d5b9692e2d2da8de7bfb6c387fa4f801fbf6fb2e6ba4673"}, + {file = "PyYAML-6.0.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:e7d73685e87afe9f3b36c799222440d6cf362062f78be1013661b00c5c6f678b"}, {file = "PyYAML-6.0.1-cp311-cp311-win32.whl", hash = "sha256:1635fd110e8d85d55237ab316b5b011de701ea0f29d07611174a1b42f1444741"}, {file = "PyYAML-6.0.1-cp311-cp311-win_amd64.whl", hash = "sha256:bf07ee2fef7014951eeb99f56f39c9bb4af143d8aa3c21b1677805985307da34"}, + {file = "PyYAML-6.0.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:855fb52b0dc35af121542a76b9a84f8d1cd886ea97c84703eaa6d88e37a2ad28"}, + {file = "PyYAML-6.0.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:40df9b996c2b73138957fe23a16a4f0ba614f4c0efce1e9406a184b6d07fa3a9"}, + {file = "PyYAML-6.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6c22bec3fbe2524cde73d7ada88f6566758a8f7227bfbf93a408a9d86bcc12a0"}, + {file = "PyYAML-6.0.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:8d4e9c88387b0f5c7d5f281e55304de64cf7f9c0021a3525bd3b1c542da3b0e4"}, + {file = "PyYAML-6.0.1-cp312-cp312-win32.whl", hash = "sha256:d483d2cdf104e7c9fa60c544d92981f12ad66a457afae824d146093b8c294c54"}, + {file = "PyYAML-6.0.1-cp312-cp312-win_amd64.whl", hash = "sha256:0d3304d8c0adc42be59c5f8a4d9e3d7379e6955ad754aa9d6ab7a398b59dd1df"}, {file = "PyYAML-6.0.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:50550eb667afee136e9a77d6dc71ae76a44df8b3e51e41b77f6de2932bfe0f47"}, {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1fe35611261b29bd1de0070f0b2f47cb6ff71fa6595c077e42bd0c419fa27b98"}, {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:704219a11b772aea0d8ecd7058d0082713c3562b4e271b849ad7dc4a5c90c13c"}, @@ -2678,6 +2629,7 @@ files = [ {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a0cd17c15d3bb3fa06978b4e8958dcdc6e0174ccea823003a106c7d4d7899ac5"}, {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:28c119d996beec18c05208a8bd78cbe4007878c6dd15091efb73a30e90539696"}, {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7e07cbde391ba96ab58e532ff4803f79c4129397514e1413a7dc761ccd755735"}, + {file = "PyYAML-6.0.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:49a183be227561de579b4a36efbb21b3eab9651dd81b1858589f796549873dd6"}, {file = "PyYAML-6.0.1-cp38-cp38-win32.whl", hash = "sha256:184c5108a2aca3c5b3d3bf9395d50893a7ab82a38004c8f61c258d4428e80206"}, {file = "PyYAML-6.0.1-cp38-cp38-win_amd64.whl", hash = "sha256:1e2722cc9fbb45d9b87631ac70924c11d3a401b2d7f410cc0e3bbf249f2dca62"}, {file = "PyYAML-6.0.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:9eb6caa9a297fc2c2fb8862bc5370d0303ddba53ba97e71f08023b6cd73d16a8"}, @@ -2685,6 +2637,7 @@ files = [ {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5773183b6446b2c99bb77e77595dd486303b4faab2b086e7b17bc6bef28865f6"}, {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b786eecbdf8499b9ca1d697215862083bd6d2a99965554781d0d8d1ad31e13a0"}, {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bc1bf2925a1ecd43da378f4db9e4f799775d6367bdb94671027b73b393a7c42c"}, + {file = "PyYAML-6.0.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:04ac92ad1925b2cff1db0cfebffb6ffc43457495c9b3c39d3fcae417d7125dc5"}, {file = "PyYAML-6.0.1-cp39-cp39-win32.whl", hash = "sha256:faca3bdcf85b2fc05d06ff3fbc1f83e1391b3e724afa3feba7d13eeab355484c"}, {file = "PyYAML-6.0.1-cp39-cp39-win_amd64.whl", hash = "sha256:510c9deebc5c0225e8c96813043e62b680ba2f9c50a08d3724c7f28a747d1486"}, {file = "PyYAML-6.0.1.tar.gz", hash = "sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43"}, @@ -2694,7 +2647,6 @@ files = [ name = "referencing" version = "0.30.2" description = "JSON Referencing + Python" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -2710,7 +2662,6 @@ rpds-py = ">=0.7.0" name = "regex" version = "2023.10.3" description = "Alternative regular expression module, to replace re." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2808,7 +2759,6 @@ files = [ name = "requests" version = "2.28.2" description = "Python HTTP for Humans." -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -2830,7 +2780,6 @@ use-chardet-on-py3 = ["chardet (>=3.0.2,<6)"] name = "rlp" version = "3.0.0" description = "A package for Recursive Length Prefix encoding and decoding" -category = "main" optional = false python-versions = "*" files = [ @@ -2852,7 +2801,6 @@ test = ["hypothesis (==5.19.0)", "pytest (>=6.2.5,<7)", "tox (>=2.9.1,<3)"] name = "rpds-py" version = "0.10.6" description = "Python bindings to Rust's persistent data structures (rpds)" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -2961,7 +2909,6 @@ files = [ name = "rsa" version = "4.9" description = "Pure-Python RSA implementation" -category = "main" optional = false python-versions = ">=3.6,<4" files = [ @@ -2976,7 +2923,6 @@ pyasn1 = ">=0.1.3" name = "semver" version = "2.13.0" description = "Python helper for Semantic Versioning (http://semver.org/)" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -2988,7 +2934,6 @@ files = [ name = "six" version = "1.16.0" description = "Python 2 and 3 compatibility utilities" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -3000,7 +2945,6 @@ files = [ name = "sortedcontainers" version = "2.4.0" description = "Sorted Containers -- Sorted List, Sorted Dict, Sorted Set" -category = "main" optional = false python-versions = "*" files = [ @@ -3012,7 +2956,6 @@ files = [ name = "texttable" version = "1.6.7" description = "module to create simple ASCII tables" -category = "main" optional = false python-versions = "*" files = [ @@ -3024,7 +2967,6 @@ files = [ name = "toml" version = "0.10.2" description = "Python Library for Tom's Obvious, Minimal Language" -category = "main" optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -3036,7 +2978,6 @@ files = [ name = "tomli" version = "2.0.1" description = "A lil' TOML parser" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3048,7 +2989,6 @@ files = [ name = "tomte" version = "0.2.12" description = "A library that wraps many useful tools (linters, analysers, etc) to keep Python code clean, secure, well-documented and optimised." -category = "dev" optional = false python-versions = ">=3.7,<4.0" files = [ @@ -3086,7 +3026,6 @@ vulture = ["vulture (==2.7)"] name = "toolz" version = "0.12.0" description = "List processing tools and functional utilities" -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -3098,7 +3037,6 @@ files = [ name = "tox" version = "3.28.0" description = "tox is a generic virtualenv management and test command line tool" -category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" files = [ @@ -3124,7 +3062,6 @@ testing = ["flaky (>=3.4.0)", "freezegun (>=0.3.11)", "pathlib2 (>=2.3.3)", "psu name = "typing-extensions" version = "4.8.0" description = "Backported and Experimental Type Hints for Python 3.8+" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -3136,7 +3073,6 @@ files = [ name = "uritemplate" version = "4.1.1" description = "Implementation of RFC 6570 URI Templates" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -3148,7 +3084,6 @@ files = [ name = "urllib3" version = "1.26.16" description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" files = [ @@ -3165,7 +3100,6 @@ socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] name = "valory-docker-compose" version = "1.29.3" description = "Multi-container orchestration for Docker" -category = "main" optional = false python-versions = ">=3.4" files = [ @@ -3194,7 +3128,6 @@ tests = ["ddt (>=1.2.2,<2)", "pytest (<6)"] name = "varint" version = "1.0.2" description = "Simple python varint implementation" -category = "main" optional = false python-versions = "*" files = [ @@ -3205,7 +3138,6 @@ files = [ name = "virtualenv" version = "20.24.5" description = "Virtual Python Environment builder" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -3226,7 +3158,6 @@ test = ["covdefaults (>=2.3)", "coverage (>=7.2.7)", "coverage-enable-subprocess name = "watchdog" version = "3.0.0" description = "Filesystem events monitoring" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3262,47 +3193,10 @@ files = [ [package.extras] watchmedo = ["PyYAML (>=3.10)"] -[[package]] -name = "web3" -version = "6.11.0" -description = "web3.py" -category = "main" -optional = false -python-versions = ">=3.7.2" -files = [ - {file = "web3-6.11.0-py3-none-any.whl", hash = "sha256:44e79da6a4765eacf137f2f388e37aa0c1e24a93bdfb462cffe9441d1be3d509"}, - {file = "web3-6.11.0.tar.gz", hash = "sha256:050dea52ae73d787272e7ecba7249f096595938c90cce1a384c20375c6b0f720"}, -] - -[package.dependencies] -aiohttp = ">=3.7.4.post0" -eth-abi = ">=4.0.0" -eth-account = ">=0.8.0" -eth-hash = {version = ">=0.5.1", extras = ["pycryptodome"]} -eth-typing = ">=3.0.0" -eth-utils = ">=2.1.0" -hexbytes = ">=0.1.0" -jsonschema = ">=4.0.0" -lru-dict = ">=1.1.6" -protobuf = ">=4.21.6" -pyunormalize = ">=15.0.0" -pywin32 = {version = ">=223", markers = "platform_system == \"Windows\""} -requests = ">=2.16.0" -typing-extensions = ">=4.0.1" -websockets = ">=10.0.0" - -[package.extras] -dev = ["black (>=22.1.0)", "build (>=0.9.0)", "bumpversion", "eth-tester[py-evm] (==v0.9.1-b.1)", "flake8 (==3.8.3)", "flaky (>=3.7.0)", "hypothesis (>=3.31.2)", "importlib-metadata (<5.0)", "ipfshttpclient (==0.8.0a2)", "isort (>=5.11.0)", "mypy (==1.4.1)", "py-geth (>=3.11.0)", "pytest (>=7.0.0)", "pytest-asyncio (>=0.18.1)", "pytest-mock (>=1.10)", "pytest-watch (>=4.2)", "pytest-xdist (>=1.29)", "setuptools (>=38.6.0)", "sphinx (>=5.3.0)", "sphinx-rtd-theme (>=1.0.0)", "towncrier (>=21,<22)", "tox (>=3.18.0)", "tqdm (>4.32)", "twine (>=1.13)", "types-protobuf (==3.19.13)", "types-requests (>=2.26.1)", "types-setuptools (>=57.4.4)", "when-changed (>=0.3.0)"] -docs = ["sphinx (>=5.3.0)", "sphinx-rtd-theme (>=1.0.0)", "towncrier (>=21,<22)"] -ipfs = ["ipfshttpclient (==0.8.0a2)"] -linter = ["black (>=22.1.0)", "flake8 (==3.8.3)", "isort (>=5.11.0)", "mypy (==1.4.1)", "types-protobuf (==3.19.13)", "types-requests (>=2.26.1)", "types-setuptools (>=57.4.4)"] -tester = ["eth-tester[py-evm] (==v0.9.1-b.1)", "py-geth (>=3.11.0)"] - [[package]] name = "websocket-client" version = "0.59.0" description = "WebSocket client for Python with low level API options" -category = "main" optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -3317,7 +3211,6 @@ six = "*" name = "websockets" version = "11.0.3" description = "An implementation of the WebSocket Protocol (RFC 6455 & 7692)" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3397,7 +3290,6 @@ files = [ name = "werkzeug" version = "2.0.3" description = "The comprehensive WSGI web application library." -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -3412,7 +3304,6 @@ watchdog = ["watchdog"] name = "wheel" version = "0.41.2" description = "A built-package format for Python" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3427,7 +3318,6 @@ test = ["pytest (>=6.0.0)", "setuptools (>=65)"] name = "yarl" version = "1.9.2" description = "Yet another URL library" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3514,4 +3404,4 @@ multidict = ">=4.0" [metadata] lock-version = "2.0" python-versions = ">=3.10, <3.11" -content-hash = "4ce134636983c9885aea73c692a498ec01bd18266bed36cda27b4c79ba84cf2a" +content-hash = "d45a6625ccb2e5f14101046fd3e0db0820bd79cdf02f9c4ace29f67a27a36d22" diff --git a/pyproject.toml b/pyproject.toml index fe3a2b914..759b6790b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -16,21 +16,21 @@ include = "packages" [tool.poetry.dependencies] python = ">=3.10, <3.11" -open-autonomy = "==0.13.1" +open-autonomy = "==0.12.1.post4" requests = "==2.28.2" py-multibase = "==1.0.3" py-multicodec = "==0.2.1" py-eth-sig-utils = "*" grpcio = "==1.53.0" asn1crypto = "<1.5.0,>=1.4.0" -open-aea-ledger-ethereum = "==1.41.0" -open-aea-ledger-cosmos = "==1.41.0" -protobuf = "<5.0.0,>=4.21.6" +open-aea-ledger-ethereum = "==1.39.0.post1" +open-aea-ledger-cosmos = "==1.39.0.post1" +protobuf = "<=3.20.1,>=3.19" hypothesis = "==6.21.6" -open-aea-test-autonomy = "==0.13.1" -web3 = "<7,>=6.0.0" +open-aea-test-autonomy = "==0.12.1.post4" +open-aea-web3 = "==6.0.1" ipfshttpclient = "==0.8.0a2" -open-aea-cli-ipfs = "==1.41.0" +open-aea-cli-ipfs = "==1.39.0.post1" aiohttp = "<3.8,>=3.7.4" certifi = "*" multidict = "*" From 4ad2b14ddb38c884e0c725cd934540b9198eb043 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 14:51:12 +0200 Subject: [PATCH 17/79] fix: Add dev dependencies --- poetry.lock | 2 +- pyproject.toml | 11 ++++++++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/poetry.lock b/poetry.lock index bfad880b4..9a94f4e54 100644 --- a/poetry.lock +++ b/poetry.lock @@ -3404,4 +3404,4 @@ multidict = ">=4.0" [metadata] lock-version = "2.0" python-versions = ">=3.10, <3.11" -content-hash = "d45a6625ccb2e5f14101046fd3e0db0820bd79cdf02f9c4ace29f67a27a36d22" +content-hash = "7b6de2b7c3192e09ee5f687e659f7a2fd21fc2d0f7dca3430d3f1780c743597a" diff --git a/pyproject.toml b/pyproject.toml index 759b6790b..706b64223 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -27,7 +27,6 @@ open-aea-ledger-ethereum = "==1.39.0.post1" open-aea-ledger-cosmos = "==1.39.0.post1" protobuf = "<=3.20.1,>=3.19" hypothesis = "==6.21.6" -open-aea-test-autonomy = "==0.12.1.post4" open-aea-web3 = "==6.0.1" ipfshttpclient = "==0.8.0a2" open-aea-cli-ipfs = "==1.39.0.post1" @@ -50,6 +49,16 @@ pycryptodome = "==3.18.0" pytest = "==7.2.1" urllib3 = "==1.26.16" jsonschema = "<=4.19.0,>=4.16.0" +open-aea-test-autonomy = "0.12.1.post4" + +[tool.poetry.dev-dependencies] +asn1crypto = "1.4.0" +open-aea-cosmpy = "0.6.6" +open-aea = { path = "/open-aea", extras = ["all"], develop = true } +open-aea-cli-ipfs = { path = "/open-aea/plugins/aea-cli-ipfs", develop = true } +open-aea-ledger-cosmos = { path = "/open-aea/plugins/aea-ledger-cosmos", develop = true } +open-aea-ledger-ethereum = { path = "/open-aea/plugins/aea-ledger-ethereum", develop = true } +py_eth_sig_utils = "0.4.0" [tool.poetry.group.dev.dependencies.tomte] version = "==0.2.12" From 81c58fab4b108fef128d93dd87c6fa7ecb7be6dd Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 14:53:42 +0200 Subject: [PATCH 18/79] fix: Remove dev dependencies --- pyproject.toml | 9 --------- 1 file changed, 9 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 706b64223..a9716f431 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,15 +51,6 @@ urllib3 = "==1.26.16" jsonschema = "<=4.19.0,>=4.16.0" open-aea-test-autonomy = "0.12.1.post4" -[tool.poetry.dev-dependencies] -asn1crypto = "1.4.0" -open-aea-cosmpy = "0.6.6" -open-aea = { path = "/open-aea", extras = ["all"], develop = true } -open-aea-cli-ipfs = { path = "/open-aea/plugins/aea-cli-ipfs", develop = true } -open-aea-ledger-cosmos = { path = "/open-aea/plugins/aea-ledger-cosmos", develop = true } -open-aea-ledger-ethereum = { path = "/open-aea/plugins/aea-ledger-ethereum", develop = true } -py_eth_sig_utils = "0.4.0" - [tool.poetry.group.dev.dependencies.tomte] version = "==0.2.12" extras = [ "cli", "tests",] From c7ad754953fd1388480f88f88cbf9873951b9c86 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 16:10:09 +0200 Subject: [PATCH 19/79] WIP: Implement betting strategy 'kelly criterion' --- packages/packages.json | 58 +++++++++---------- packages/valory/agents/trader/aea-config.yaml | 54 ++++++++--------- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 29 +++++----- .../skills/decision_maker_abci/models.py | 16 ++++- .../skills/decision_maker_abci/skill.yaml | 16 ++--- .../skills/market_manager_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 16 ++--- .../tx_settlement_multiplexer_abci/skill.yaml | 4 +- 9 files changed, 107 insertions(+), 90 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 8ab80bfa9..87b8015aa 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { - "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm", - "skill/valory/trader_abci/0.1.0": "bafybeigxrvqhwo5dgdnotxx5hdpemsp7tyljw5ruagrk3rs46ptbayjika", + "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidju7ijwpfziwsj5rou42vdjsq7xnnjm3ibvgsjxpdxi3d5a7nvgq", + "skill/valory/trader_abci/0.1.0": "bafybeidlya7rs5xqxkuhuup4ribis3hucsm2d4kmj3tgzjw2stbl42u4s4", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeif7xd3mil4ifohqmhdfbvfbhakeu57duubym45igvezlmbfzqxngi", - "service/valory/trader/0.1.0": "bafybeiblxnwxrracktqlvuls4lc56u2mdfomrik4z6ri7gnbi23qjtiiay", + "agent/valory/trader/0.1.0": "bafybeifwuy6g6neqatcya7gu3djodqovucn6jrvel5vtcumac62ahrnuxa", + "service/valory/trader/0.1.0": "bafybeifks2lptzfdfcn3ykhvvqy73sma6aaykg2bbm3ycxiki4xjfhkwq4", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeih24r254u6sbxcjjcrx7duxgb46rm5udwozuqberzj3aennjwvplq", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", @@ -15,28 +15,28 @@ "contract/valory/agent_registry/0.1.0": "bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty" }, "third_party": { - "protocol/open_aea/signing/1.0.0": "bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii", - "protocol/valory/abci/0.1.0": "bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu", - "protocol/valory/contract_api/1.0.0": "bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka", - "protocol/valory/http/1.0.0": "bafybeiejoqgv7finfxo3rcvvovrlj5ccrbgxodjq43uo26ylpowsa3llfe", - "protocol/valory/ledger_api/1.0.0": "bafybeige5agrztgzfevyglf7mb4o7pzfttmq4f6zi765y4g2zvftbyowru", - "protocol/valory/acn/1.1.0": "bafybeic2pxzfc3voxl2ejhcqyf2ehm4wm5gxvgx7bliloiqi2uppmq6weu", - "protocol/valory/tendermint/0.1.0": "bafybeig6g6twajlwssfbfp5rlnu5mwzuu5kgak5cs4fich7rlkx6whesnu", - "protocol/valory/ipfs/0.1.0": "bafybeiedxeismnx3k5ty4mvvhlqideixlhqmi5mtcki4lxqfa7uqh7p33u", - "skill/valory/abstract_abci/0.1.0": "bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a", - "skill/valory/reset_pause_abci/0.1.0": "bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe", - "skill/valory/registration_abci/0.1.0": "bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm", - "skill/valory/abstract_round_abci/0.1.0": "bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq", - "connection/valory/abci/0.1.0": "bafybeibtnfu6skrpducj2fzjzw7lrwj3et63xx6u5dryrabec26utzxsf4", - "connection/valory/http_client/0.23.0": "bafybeifgeqgryx6b3s6eseyzyezygmeitcpt3tkor2eiycozoi6clgdrny", - "connection/valory/ledger/0.19.0": "bafybeigo5vst3zlltkouenwxuzn6c47yr2fbbml6dl2o32rfnsezmalgnu", - "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihge56dn3xep2dzomu7rtvbgo4uc2qqh7ljl3fubqdi2lq44gs5lq", - "connection/valory/ipfs/0.1.0": "bafybeigkn27u7m5atju6a724clycyfshbgcbwheztil2bky7krfa46ub2a", - "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y", - "contract/valory/gnosis_safe/0.1.0": "bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci", - "contract/valory/service_registry/0.1.0": "bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu", - "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy", - "contract/valory/multisend/0.1.0": "bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y", - "skill/valory/termination_abci/0.1.0": "bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy" + "protocol/open_aea/signing/1.0.0": "bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m", + "protocol/valory/abci/0.1.0": "bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe", + "protocol/valory/contract_api/1.0.0": "bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa", + "protocol/valory/http/1.0.0": "bafybeia5bxdua2i6chw6pg47bvoljzcpuqxzy4rdrorbdmcbnwmnfdobtu", + "protocol/valory/ledger_api/1.0.0": "bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby", + "protocol/valory/acn/1.1.0": "bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa", + "protocol/valory/tendermint/0.1.0": "bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa", + "protocol/valory/ipfs/0.1.0": "bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa", + "skill/valory/abstract_abci/0.1.0": "bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy", + "skill/valory/reset_pause_abci/0.1.0": "bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu", + "skill/valory/registration_abci/0.1.0": "bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li", + "skill/valory/abstract_round_abci/0.1.0": "bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq", + "connection/valory/abci/0.1.0": "bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina", + "connection/valory/http_client/0.23.0": "bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y", + "connection/valory/ledger/0.19.0": "bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a", + "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq", + "connection/valory/ipfs/0.1.0": "bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e", + "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274", + "contract/valory/gnosis_safe/0.1.0": "bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm", + "contract/valory/service_registry/0.1.0": "bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu", + "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui", + "contract/valory/multisend/0.1.0": "bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u", + "skill/valory/termination_abci/0.1.0": "bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm" } } \ No newline at end of file diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 2e060d721..ab68adb44 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -9,42 +9,42 @@ fingerprint: __init__.py: bafybeighcq4pmuzte6vhvvprrvo563vzghkoit2h6qdqxf2ma5bghevkee fingerprint_ignore_patterns: [] connections: -- valory/abci:0.1.0:bafybeibtnfu6skrpducj2fzjzw7lrwj3et63xx6u5dryrabec26utzxsf4 -- valory/http_client:0.23.0:bafybeifgeqgryx6b3s6eseyzyezygmeitcpt3tkor2eiycozoi6clgdrny -- valory/ipfs:0.1.0:bafybeigkn27u7m5atju6a724clycyfshbgcbwheztil2bky7krfa46ub2a -- valory/ledger:0.19.0:bafybeigo5vst3zlltkouenwxuzn6c47yr2fbbml6dl2o32rfnsezmalgnu -- valory/p2p_libp2p_client:0.1.0:bafybeihge56dn3xep2dzomu7rtvbgo4uc2qqh7ljl3fubqdi2lq44gs5lq +- valory/abci:0.1.0:bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina +- valory/http_client:0.23.0:bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y +- valory/ipfs:0.1.0:bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e +- valory/ledger:0.19.0:bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a +- valory/p2p_libp2p_client:0.1.0:bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq contracts: -- valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci -- valory/gnosis_safe_proxy_factory:0.1.0:bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y -- valory/service_registry:0.1.0:bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu +- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm +- valory/gnosis_safe_proxy_factory:0.1.0:bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274 +- valory/service_registry:0.1.0:bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu - valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m - valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi -- valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y +- valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u - valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga - valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa - valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e - valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 protocols: -- open_aea/signing:1.0.0:bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii -- valory/abci:0.1.0:bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu -- valory/acn:1.1.0:bafybeic2pxzfc3voxl2ejhcqyf2ehm4wm5gxvgx7bliloiqi2uppmq6weu -- valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka -- valory/http:1.0.0:bafybeiejoqgv7finfxo3rcvvovrlj5ccrbgxodjq43uo26ylpowsa3llfe -- valory/ipfs:0.1.0:bafybeiedxeismnx3k5ty4mvvhlqideixlhqmi5mtcki4lxqfa7uqh7p33u -- valory/ledger_api:1.0.0:bafybeige5agrztgzfevyglf7mb4o7pzfttmq4f6zi765y4g2zvftbyowru -- valory/tendermint:0.1.0:bafybeig6g6twajlwssfbfp5rlnu5mwzuu5kgak5cs4fich7rlkx6whesnu +- open_aea/signing:1.0.0:bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m +- valory/abci:0.1.0:bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe +- valory/acn:1.1.0:bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa +- valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa +- valory/http:1.0.0:bafybeia5bxdua2i6chw6pg47bvoljzcpuqxzy4rdrorbdmcbnwmnfdobtu +- valory/ipfs:0.1.0:bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa +- valory/ledger_api:1.0.0:bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby +- valory/tendermint:0.1.0:bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa skills: -- valory/abstract_abci:0.1.0:bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/registration_abci:0.1.0:bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm -- valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe -- valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy -- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi -- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm -- valory/trader_abci:0.1.0:bafybeigxrvqhwo5dgdnotxx5hdpemsp7tyljw5ruagrk3rs46ptbayjika +- valory/abstract_abci:0.1.0:bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li +- valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu +- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeih24r254u6sbxcjjcrx7duxgb46rm5udwozuqberzj3aennjwvplq +- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq +- valory/decision_maker_abci:0.1.0:bafybeidju7ijwpfziwsj5rou42vdjsq7xnnjm3ibvgsjxpdxi3d5a7nvgq +- valory/trader_abci:0.1.0:bafybeidlya7rs5xqxkuhuup4ribis3hucsm2d4kmj3tgzjw2stbl42u4s4 default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index cb1711ecb..1086e2980 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeif7xd3mil4ifohqmhdfbvfbhakeu57duubym45igvezlmbfzqxngi +agent: valory/trader:0.1.0:bafybeifwuy6g6neqatcya7gu3djodqovucn6jrvel5vtcumac62ahrnuxa number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 31c3cf81c..e1234cd0e 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -246,19 +246,6 @@ def _get_decision( return self.mech_response.result.vote, self.mech_response.result.odds, self.mech_response.result.win_probability, self.mech_response.result.confidence - def _get_kelly_bet_amount(self, x, y, p, c, b) -> int: - """Calculate the Kelly bet amount.""" - if b == 0 or x**2 == y**2: - self.context.logger.error( - "Could not calculate Kelly bet amount. Either bankroll is 0 or pool token amount is distributed as x^2 - y^2 = 0:\n" - f"Bankroll: {b}\n" - f"Pool token amounts: {x}, {y}" - ) - return None - # TODO: Add Fee variable - kelly_bet_amount = (-4*x**2*y + b*y**2*p + 2*b*x*y*p + b*x**2*p - 2*b*y**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p - 2*b*x*y*p - b*x**2*p + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p - 4*b*x**2*y*p + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) - self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") - return int(kelly_bet_amount) def _get_bet_sample_info(bet, vote) -> Tuple[int, int]: token_amounts = bet.outcomeTokenAmounts @@ -391,6 +378,21 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide self.context.logger.info(f"Token balance: {self.token_balance}") self.context.logger.info(f"Bankroll: {bankroll}") selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee = self._get_bet_sample_info(bet, vote) + + # Testing and printing kelly bet amount + self.context.logger.info("Start kelly bet amount calculation") + bet_amount = self.params.get_bet_amount( + bankroll, + "kelly_criterion", + win_probability, + confidence, + selected_type_tokens_in_pool, + other_tokens_in_pool, + bet_fee, + ) + + # Actual bet amount + self.context.logger.info("Start bet amount per conf threshold calculation") bet_amount = self.params.get_bet_amount( bankroll, self.params.trading_strategy, @@ -400,6 +402,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide other_tokens_in_pool, bet_fee, ) + self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 22830f1eb..ad1450cb8 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -90,7 +90,7 @@ def check_prompt_template(bet_prompt_template: PromptTemplate) -> None: f"For example, to parametrize {example_key!r} you may use " f"'{delimiter}{{{example_key}}}'" ) - + class DecisionMakerParams(MarketManagerParams): """Decision maker's parameters.""" @@ -164,6 +164,20 @@ def slippage(self, slippage: float) -> None: ) self._slippage = slippage + def _get_kelly_bet_amount(self, x, y, p, c, b) -> int: + """Calculate the Kelly bet amount.""" + if b == 0 or x**2 == y**2: + self.context.logger.error( + "Could not calculate Kelly bet amount. Either bankroll is 0 or pool token amount is distributed as x^2 - y^2 = 0:\n" + f"Bankroll: {b}\n" + f"Pool token amounts: {x}, {y}" + ) + return None + # TODO: Add Fee variable + kelly_bet_amount = (-4*x**2*y + b*y**2*p + 2*b*x*y*p + b*x**2*p - 2*b*y**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p - 2*b*x*y*p - b*x**2*p + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p - 4*b*x**2*y*p + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) + self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") + return int(kelly_bet_amount) + # def get_bet_amount(self, confidence: float) -> int: # """Get the bet amount given a prediction's confidence.""" # threshold = round(confidence, 1) diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 6dc5f7148..ba7b4d468 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeidny4y4w4jbjbp5d5qivur6jm37fnuik4mqzchzshiuvpozxe7vwy behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeicoogphhr3acovqgrfxkivzjjuorua2vin3jyfo53sirmwveri7ru + behaviours/decision_receive.py: bafybeiahl7ad6ojybm6zwn4gckonxi6cknux5q7tgm7sfdopqzjaycnoqu behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga @@ -25,7 +25,7 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeifgao43trxhykd22nkriav4gsi4rxdqllfe2n7y5q2tafrvbnpl3y + models.py: bafybeic6nuw5jpoktstbeapzfch43twkmvaha6bntsaoc4qgzmcxgbifzi payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm @@ -44,21 +44,21 @@ fingerprint: fingerprint_ignore_patterns: [] connections: [] contracts: -- valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci +- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm - valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m - valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi -- valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y +- valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u - valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga - valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa - valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e - valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 - valory/agent_registry:0.1.0:bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty protocols: -- valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka +- valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa skills: -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui behaviours: main: args: {} diff --git a/packages/valory/skills/market_manager_abci/skill.yaml b/packages/valory/skills/market_manager_abci/skill.yaml index e7edd85e7..790727458 100644 --- a/packages/valory/skills/market_manager_abci/skill.yaml +++ b/packages/valory/skills/market_manager_abci/skill.yaml @@ -26,7 +26,7 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq behaviours: main: args: {} diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 42f78e2cb..f4eb2509f 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -19,14 +19,14 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/registration_abci:0.1.0:bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm -- valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe -- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy -- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicwkfxhqdzeb54mqqpb27g4k2oq5owoxbp23c3boiibpgta3gsogi +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li +- valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu +- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm +- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq +- valory/decision_maker_abci:0.1.0:bafybeidju7ijwpfziwsj5rou42vdjsq7xnnjm3ibvgsjxpdxi3d5a7nvgq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeih24r254u6sbxcjjcrx7duxgb46rm5udwozuqberzj3aennjwvplq behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 2f66c404f..7dad84022 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -19,8 +19,8 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeigx5zys7qisck4i4tgrq5lkuopwoxx3kjxnlidxxwqgyamtw7yulm +- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/decision_maker_abci:0.1.0:bafybeidju7ijwpfziwsj5rou42vdjsq7xnnjm3ibvgsjxpdxi3d5a7nvgq behaviours: main: args: {} From f804ac9f775e21b73d4a6e4ae4369f8b2123f5ba Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 17:06:23 +0200 Subject: [PATCH 20/79] fix: Resolved dependency mismatches --- packages/packages.json | 32 ++-- packages/valory/agents/trader/aea-config.yaml | 28 +-- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/skill.yaml | 10 +- .../skills/market_manager_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 16 +- .../tx_settlement_multiplexer_abci/skill.yaml | 4 +- poetry.lock | 176 ++++-------------- 8 files changed, 80 insertions(+), 190 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 87b8015aa..950cb7edc 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { - "skill/valory/market_manager_abci/0.1.0": "bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq", - "skill/valory/decision_maker_abci/0.1.0": "bafybeidju7ijwpfziwsj5rou42vdjsq7xnnjm3ibvgsjxpdxi3d5a7nvgq", - "skill/valory/trader_abci/0.1.0": "bafybeidlya7rs5xqxkuhuup4ribis3hucsm2d4kmj3tgzjw2stbl42u4s4", + "skill/valory/market_manager_abci/0.1.0": "bafybeicreyjyimqbdcubay2weplpzzcblxa5mekmwucfhzjdbogbbriaty", + "skill/valory/decision_maker_abci/0.1.0": "bafybeiguok6wfm24p4iztxdmagtohnu25wglqlxzq5iflae3xyrs42w6hm", + "skill/valory/trader_abci/0.1.0": "bafybeiavqq3ide7pa236o6ao6u3bobko6tfsd62jd773xwr63zmbawubku", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeifwuy6g6neqatcya7gu3djodqovucn6jrvel5vtcumac62ahrnuxa", - "service/valory/trader/0.1.0": "bafybeifks2lptzfdfcn3ykhvvqy73sma6aaykg2bbm3ycxiki4xjfhkwq4", + "agent/valory/trader/0.1.0": "bafybeienzghvlqommoka44xrgy24kvkhp4ww27ksnai7qbthtvklokqd64", + "service/valory/trader/0.1.0": "bafybeihizjmvnt5kenzuex4sta4igqtnutu2w5nqrdwxupc4wtd3ifbmle", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeih24r254u6sbxcjjcrx7duxgb46rm5udwozuqberzj3aennjwvplq", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeifm6azxbjo6tgchl7p4bzd66eyvn6vcinyyg2fybidoydlkjybav4", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", @@ -24,19 +24,19 @@ "protocol/valory/tendermint/0.1.0": "bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa", "protocol/valory/ipfs/0.1.0": "bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa", "skill/valory/abstract_abci/0.1.0": "bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy", - "skill/valory/reset_pause_abci/0.1.0": "bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu", - "skill/valory/registration_abci/0.1.0": "bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li", - "skill/valory/abstract_round_abci/0.1.0": "bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq", + "skill/valory/reset_pause_abci/0.1.0": "bafybeih5p6r3bezwm3sccnwuxl2zyit7aqdqe6b3q56xgbsliscgscw4em", + "skill/valory/registration_abci/0.1.0": "bafybeiem3snx3q6f6go3h6qolnj7m5sgv7rrhbfsp7yri5biv6nzkrnpi4", + "skill/valory/abstract_round_abci/0.1.0": "bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu", "connection/valory/abci/0.1.0": "bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina", "connection/valory/http_client/0.23.0": "bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y", "connection/valory/ledger/0.19.0": "bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a", "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq", - "connection/valory/ipfs/0.1.0": "bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e", - "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274", - "contract/valory/gnosis_safe/0.1.0": "bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm", - "contract/valory/service_registry/0.1.0": "bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu", - "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui", - "contract/valory/multisend/0.1.0": "bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u", - "skill/valory/termination_abci/0.1.0": "bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm" + "connection/valory/ipfs/0.1.0": "bafybeih2ybmughrcm2arwlpnoksyzxonjomo6lruwxienslaeizngjm44y", + "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y", + "contract/valory/gnosis_safe/0.1.0": "bafybeias2zrinapw4luvr73i6fyzsnh4saxg7ktl6nkbskkamhs2tlyotq", + "contract/valory/service_registry/0.1.0": "bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu", + "skill/valory/transaction_settlement_abci/0.1.0": "bafybeici2zsmgzwd46tvkdee2mbg4gq7zmvwmyfscjtcve7xunbzfmvoza", + "contract/valory/multisend/0.1.0": "bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y", + "skill/valory/termination_abci/0.1.0": "bafybeiespnae46stpib425aed6cpvhvnvc4ywgsm77cs7sbn7us67j7ufu" } } \ No newline at end of file diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index ab68adb44..9e8779912 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -11,16 +11,16 @@ fingerprint_ignore_patterns: [] connections: - valory/abci:0.1.0:bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina - valory/http_client:0.23.0:bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y -- valory/ipfs:0.1.0:bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e +- valory/ipfs:0.1.0:bafybeih2ybmughrcm2arwlpnoksyzxonjomo6lruwxienslaeizngjm44y - valory/ledger:0.19.0:bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a - valory/p2p_libp2p_client:0.1.0:bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq contracts: -- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm -- valory/gnosis_safe_proxy_factory:0.1.0:bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274 -- valory/service_registry:0.1.0:bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu +- valory/gnosis_safe:0.1.0:bafybeias2zrinapw4luvr73i6fyzsnh4saxg7ktl6nkbskkamhs2tlyotq +- valory/gnosis_safe_proxy_factory:0.1.0:bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y +- valory/service_registry:0.1.0:bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu - valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m - valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi -- valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u +- valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y - valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga - valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa - valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e @@ -36,15 +36,15 @@ protocols: - valory/tendermint:0.1.0:bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa skills: - valory/abstract_abci:0.1.0:bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy -- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li -- valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu -- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm -- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeih24r254u6sbxcjjcrx7duxgb46rm5udwozuqberzj3aennjwvplq -- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeidju7ijwpfziwsj5rou42vdjsq7xnnjm3ibvgsjxpdxi3d5a7nvgq -- valory/trader_abci:0.1.0:bafybeidlya7rs5xqxkuhuup4ribis3hucsm2d4kmj3tgzjw2stbl42u4s4 +- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu +- valory/registration_abci:0.1.0:bafybeiem3snx3q6f6go3h6qolnj7m5sgv7rrhbfsp7yri5biv6nzkrnpi4 +- valory/reset_pause_abci:0.1.0:bafybeih5p6r3bezwm3sccnwuxl2zyit7aqdqe6b3q56xgbsliscgscw4em +- valory/termination_abci:0.1.0:bafybeiespnae46stpib425aed6cpvhvnvc4ywgsm77cs7sbn7us67j7ufu +- valory/transaction_settlement_abci:0.1.0:bafybeici2zsmgzwd46tvkdee2mbg4gq7zmvwmyfscjtcve7xunbzfmvoza +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifm6azxbjo6tgchl7p4bzd66eyvn6vcinyyg2fybidoydlkjybav4 +- valory/market_manager_abci:0.1.0:bafybeicreyjyimqbdcubay2weplpzzcblxa5mekmwucfhzjdbogbbriaty +- valory/decision_maker_abci:0.1.0:bafybeiguok6wfm24p4iztxdmagtohnu25wglqlxzq5iflae3xyrs42w6hm +- valory/trader_abci:0.1.0:bafybeiavqq3ide7pa236o6ao6u3bobko6tfsd62jd773xwr63zmbawubku default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 1086e2980..8e58e41c1 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeifwuy6g6neqatcya7gu3djodqovucn6jrvel5vtcumac62ahrnuxa +agent: valory/trader:0.1.0:bafybeienzghvlqommoka44xrgy24kvkhp4ww27ksnai7qbthtvklokqd64 number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index ba7b4d468..c732b4616 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -44,10 +44,10 @@ fingerprint: fingerprint_ignore_patterns: [] connections: [] contracts: -- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm +- valory/gnosis_safe:0.1.0:bafybeias2zrinapw4luvr73i6fyzsnh4saxg7ktl6nkbskkamhs2tlyotq - valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m - valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi -- valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u +- valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y - valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga - valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa - valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e @@ -56,9 +56,9 @@ contracts: protocols: - valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa skills: -- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu +- valory/market_manager_abci:0.1.0:bafybeicreyjyimqbdcubay2weplpzzcblxa5mekmwucfhzjdbogbbriaty +- valory/transaction_settlement_abci:0.1.0:bafybeici2zsmgzwd46tvkdee2mbg4gq7zmvwmyfscjtcve7xunbzfmvoza behaviours: main: args: {} diff --git a/packages/valory/skills/market_manager_abci/skill.yaml b/packages/valory/skills/market_manager_abci/skill.yaml index 790727458..04beb55ef 100644 --- a/packages/valory/skills/market_manager_abci/skill.yaml +++ b/packages/valory/skills/market_manager_abci/skill.yaml @@ -26,7 +26,7 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu behaviours: main: args: {} diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index f4eb2509f..93f1d0a13 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -19,14 +19,14 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/registration_abci:0.1.0:bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li -- valory/reset_pause_abci:0.1.0:bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu -- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui -- valory/termination_abci:0.1.0:bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm -- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/decision_maker_abci:0.1.0:bafybeidju7ijwpfziwsj5rou42vdjsq7xnnjm3ibvgsjxpdxi3d5a7nvgq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeih24r254u6sbxcjjcrx7duxgb46rm5udwozuqberzj3aennjwvplq +- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu +- valory/registration_abci:0.1.0:bafybeiem3snx3q6f6go3h6qolnj7m5sgv7rrhbfsp7yri5biv6nzkrnpi4 +- valory/reset_pause_abci:0.1.0:bafybeih5p6r3bezwm3sccnwuxl2zyit7aqdqe6b3q56xgbsliscgscw4em +- valory/transaction_settlement_abci:0.1.0:bafybeici2zsmgzwd46tvkdee2mbg4gq7zmvwmyfscjtcve7xunbzfmvoza +- valory/termination_abci:0.1.0:bafybeiespnae46stpib425aed6cpvhvnvc4ywgsm77cs7sbn7us67j7ufu +- valory/market_manager_abci:0.1.0:bafybeicreyjyimqbdcubay2weplpzzcblxa5mekmwucfhzjdbogbbriaty +- valory/decision_maker_abci:0.1.0:bafybeiguok6wfm24p4iztxdmagtohnu25wglqlxzq5iflae3xyrs42w6hm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifm6azxbjo6tgchl7p4bzd66eyvn6vcinyyg2fybidoydlkjybav4 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 7dad84022..0c325b4ef 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -19,8 +19,8 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/decision_maker_abci:0.1.0:bafybeidju7ijwpfziwsj5rou42vdjsq7xnnjm3ibvgsjxpdxi3d5a7nvgq +- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu +- valory/decision_maker_abci:0.1.0:bafybeiguok6wfm24p4iztxdmagtohnu25wglqlxzq5iflae3xyrs42w6hm behaviours: main: args: {} diff --git a/poetry.lock b/poetry.lock index 7703917ce..cccb4a776 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,10 +1,9 @@ -# This file is automatically @generated by Poetry 1.4.2 and should not be changed by hand. +# This file is automatically @generated by Poetry 1.6.1 and should not be changed by hand. [[package]] name = "aiohttp" version = "3.7.4.post0" description = "Async http client/server framework (asyncio)" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -62,7 +61,6 @@ speedups = ["aiodns", "brotlipy", "cchardet"] name = "asn1crypto" version = "1.4.0" description = "Fast ASN.1 parser and serializer with definitions for private keys, public keys, certificates, CRL, OCSP, CMS, PKCS#3, PKCS#7, PKCS#8, PKCS#12, PKCS#5, X.509 and TSP" -category = "main" optional = false python-versions = "*" files = [ @@ -74,7 +72,6 @@ files = [ name = "async-timeout" version = "3.0.1" description = "Timeout context manager for asyncio programs" -category = "main" optional = false python-versions = ">=3.5.3" files = [ @@ -86,7 +83,6 @@ files = [ name = "attrs" version = "23.1.0" description = "Classes Without Boilerplate" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -105,7 +101,6 @@ tests-no-zope = ["cloudpickle", "hypothesis", "mypy (>=1.1.1)", "pympler", "pyte name = "base58" version = "2.1.1" description = "Base58 and Base58Check implementation." -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -120,7 +115,6 @@ tests = ["PyHamcrest (>=2.0.2)", "mypy", "pytest (>=4.6)", "pytest-benchmark", " name = "bcrypt" version = "4.0.1" description = "Modern password hashing for your software and your servers" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -155,7 +149,6 @@ typecheck = ["mypy"] name = "bech32" version = "1.2.0" description = "Reference implementation for Bech32 and segwit addresses." -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -167,7 +160,6 @@ files = [ name = "bitarray" version = "2.8.2" description = "efficient arrays of booleans -- C extension" -category = "main" optional = false python-versions = "*" files = [ @@ -299,7 +291,6 @@ files = [ name = "blspy" version = "2.0.2" description = "BLS signatures in c++ (python bindings)" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -337,7 +328,6 @@ wheel = "*" name = "cached-property" version = "1.5.2" description = "A decorator for caching properties in classes." -category = "main" optional = false python-versions = "*" files = [ @@ -349,7 +339,6 @@ files = [ name = "cachetools" version = "5.3.1" description = "Extensible memoizing collections and decorators" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -361,7 +350,6 @@ files = [ name = "cbor2" version = "5.4.6" description = "CBOR (de)serializer with extensive tag support" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -411,7 +399,6 @@ test = ["pytest", "pytest-cov"] name = "certifi" version = "2023.7.22" description = "Python package for providing Mozilla's CA Bundle." -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -423,7 +410,6 @@ files = [ name = "cffi" version = "1.16.0" description = "Foreign Function Interface for Python calling C code." -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -488,7 +474,6 @@ pycparser = "*" name = "chardet" version = "4.0.0" description = "Universal encoding detector for Python 2 and 3" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -500,7 +485,6 @@ files = [ name = "charset-normalizer" version = "3.3.0" description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." -category = "main" optional = false python-versions = ">=3.7.0" files = [ @@ -600,7 +584,6 @@ files = [ name = "click" version = "8.0.2" description = "Composable command line interface toolkit" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -615,7 +598,6 @@ colorama = {version = "*", markers = "platform_system == \"Windows\""} name = "coincurve" version = "18.0.0" description = "Cross-platform Python CFFI bindings for libsecp256k1" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -671,7 +653,6 @@ cffi = ">=1.3.0" name = "colorama" version = "0.4.6" description = "Cross-platform colored terminal text." -category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=2.7" files = [ @@ -683,7 +664,6 @@ files = [ name = "coverage" version = "7.3.2" description = "Code coverage measurement for Python" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -751,7 +731,6 @@ toml = ["tomli"] name = "crcmod" version = "1.7" description = "CRC Generator" -category = "main" optional = false python-versions = "*" files = [ @@ -762,7 +741,6 @@ files = [ name = "cryptography" version = "41.0.4" description = "cryptography is a package which provides cryptographic recipes and primitives to Python developers." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -808,7 +786,6 @@ test-randomorder = ["pytest-randomly"] name = "cytoolz" version = "0.12.2" description = "Cython implementation of Toolz: High performance functional utilities" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -917,7 +894,6 @@ cython = ["cython"] name = "distlib" version = "0.3.7" description = "Distribution utilities" -category = "dev" optional = false python-versions = "*" files = [ @@ -929,7 +905,6 @@ files = [ name = "distro" version = "1.8.0" description = "Distro - an OS platform information API" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -941,7 +916,6 @@ files = [ name = "docker" version = "6.1.2" description = "A Python library for the Docker Engine API." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -964,7 +938,6 @@ ssh = ["paramiko (>=2.4.3)"] name = "dockerpty" version = "0.4.1" description = "Python library to use the pseudo-tty of a docker container" -category = "main" optional = false python-versions = "*" files = [ @@ -978,7 +951,6 @@ six = ">=1.3.0" name = "docopt" version = "0.6.2" description = "Pythonic argument parser, that will make you smile" -category = "main" optional = false python-versions = "*" files = [ @@ -989,7 +961,6 @@ files = [ name = "ecdsa" version = "0.16.1" description = "ECDSA cryptographic signature library (pure python)" -category = "main" optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -1008,7 +979,6 @@ gmpy2 = ["gmpy2"] name = "ed25519-blake2b" version = "1.4" description = "Ed25519 public-key signatures (BLAKE2b fork)" -category = "main" optional = false python-versions = "*" files = [ @@ -1019,7 +989,6 @@ files = [ name = "eth-abi" version = "4.0.0" description = "eth_abi: Python utilities for working with Ethereum ABI definitions, especially encoding and decoding" -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -1043,7 +1012,6 @@ tools = ["hypothesis (>=4.18.2,<5.0.0)"] name = "eth-account" version = "0.8.0" description = "eth-account: Sign Ethereum transactions and messages with local private keys" -category = "main" optional = false python-versions = ">=3.6, <4" files = [ @@ -1071,7 +1039,6 @@ test = ["coverage", "hypothesis (>=4.18.0,<5)", "pytest (>=6.2.5,<7)", "pytest-x name = "eth-hash" version = "0.5.2" description = "eth-hash: The Ethereum hashing function, keccak256, sometimes (erroneously) called sha3" -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -1094,7 +1061,6 @@ test = ["pytest (>=7.0.0)", "pytest-xdist (>=2.4.0)"] name = "eth-keyfile" version = "0.6.1" description = "A library for handling the encrypted keyfiles used to store ethereum private keys." -category = "main" optional = false python-versions = "*" files = [ @@ -1117,7 +1083,6 @@ test = ["pytest (>=6.2.5,<7)"] name = "eth-keys" version = "0.4.0" description = "Common API for Ethereum key operations." -category = "main" optional = false python-versions = "*" files = [ @@ -1140,7 +1105,6 @@ test = ["asn1tools (>=0.146.2,<0.147)", "eth-hash[pycryptodome]", "eth-hash[pysh name = "eth-rlp" version = "0.3.0" description = "eth-rlp: RLP definitions for common Ethereum objects in Python" -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -1163,7 +1127,6 @@ test = ["eth-hash[pycryptodome]", "pytest (>=6.2.5,<7)", "pytest-xdist", "tox (= name = "eth-typing" version = "3.5.0" description = "eth-typing: Common type annotations for ethereum python packages" -category = "main" optional = false python-versions = ">=3.7.2, <4" files = [ @@ -1184,7 +1147,6 @@ test = ["pytest (>=7.0.0)", "pytest-xdist (>=2.4.0)"] name = "eth-utils" version = "2.2.0" description = "eth-utils: Common utility functions for python code that interacts with Ethereum" -category = "main" optional = false python-versions = ">=3.7,<4" files = [ @@ -1208,7 +1170,6 @@ test = ["hypothesis (>=4.43.0)", "mypy (==0.971)", "pytest (>=7.0.0)", "pytest-x name = "exceptiongroup" version = "1.1.3" description = "Backport of PEP 654 (exception groups)" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1223,7 +1184,6 @@ test = ["pytest (>=6)"] name = "filelock" version = "3.12.4" description = "A platform independent file lock." -category = "dev" optional = false python-versions = ">=3.8" files = [ @@ -1240,7 +1200,6 @@ typing = ["typing-extensions (>=4.7.1)"] name = "flask" version = "2.1.3" description = "A simple framework for building complex web applications." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1262,7 +1221,6 @@ dotenv = ["python-dotenv"] name = "google-api-core" version = "2.12.0" description = "Google API client core library" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1283,18 +1241,17 @@ grpcio-gcp = ["grpcio-gcp (>=0.2.2,<1.0.dev0)"] [[package]] name = "google-api-python-client" -version = "2.103.0" +version = "2.104.0" description = "Google API Client Library for Python" -category = "main" optional = false python-versions = ">=3.7" files = [ - {file = "google-api-python-client-2.103.0.tar.gz", hash = "sha256:5b48dc23913b9a1b447991add03f27c335831559b5a870c522316eae671caf44"}, - {file = "google_api_python_client-2.103.0-py2.py3-none-any.whl", hash = "sha256:5d6cf80cc34598a85b73e7e689e6eb1ba34f342095aeab9ec408f94521382a7c"}, + {file = "google-api-python-client-2.104.0.tar.gz", hash = "sha256:bbc66520e7fe9417b93fd113f2a0a1afa789d686de9009b6e94e48fdea50a60f"}, + {file = "google_api_python_client-2.104.0-py2.py3-none-any.whl", hash = "sha256:867061526aa6dc6c1481d118e913a8a38a02a01eed589413968397ebd77df71d"}, ] [package.dependencies] -google-api-core = ">=1.31.5,<2.0.0 || >2.3.0,<3.0.0.dev0" +google-api-core = ">=1.31.5,<2.0.dev0 || >2.3.0,<3.0.0.dev0" google-auth = ">=1.19.0,<3.0.0.dev0" google-auth-httplib2 = ">=0.1.0" httplib2 = ">=0.15.0,<1.dev0" @@ -1304,7 +1261,6 @@ uritemplate = ">=3.0.1,<5" name = "google-auth" version = "2.23.3" description = "Google Authentication Library" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1328,7 +1284,6 @@ requests = ["requests (>=2.20.0,<3.0.0.dev0)"] name = "google-auth-httplib2" version = "0.1.1" description = "Google Authentication Library: httplib2 transport" -category = "main" optional = false python-versions = "*" files = [ @@ -1342,14 +1297,13 @@ httplib2 = ">=0.19.0" [[package]] name = "googleapis-common-protos" -version = "1.60.0" +version = "1.61.0" description = "Common protobufs used in Google APIs" -category = "main" optional = false python-versions = ">=3.7" files = [ - {file = "googleapis-common-protos-1.60.0.tar.gz", hash = "sha256:e73ebb404098db405ba95d1e1ae0aa91c3e15a71da031a2eeb6b2e23e7bc3708"}, - {file = "googleapis_common_protos-1.60.0-py2.py3-none-any.whl", hash = "sha256:69f9bbcc6acde92cab2db95ce30a70bd2b81d20b12eff3f1aabaffcbe8a93918"}, + {file = "googleapis-common-protos-1.61.0.tar.gz", hash = "sha256:8a64866a97f6304a7179873a465d6eee97b7a24ec6cfd78e0f575e96b821240b"}, + {file = "googleapis_common_protos-1.61.0-py2.py3-none-any.whl", hash = "sha256:22f1915393bb3245343f6efe87f6fe868532efc12aa26b391b15132e1279f1c0"}, ] [package.dependencies] @@ -1362,7 +1316,6 @@ grpc = ["grpcio (>=1.44.0,<2.0.0.dev0)"] name = "grpcio" version = "1.53.0" description = "HTTP/2-based RPC framework" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1420,7 +1373,6 @@ protobuf = ["grpcio-tools (>=1.53.0)"] name = "hexbytes" version = "0.3.1" description = "hexbytes: Python `bytes` subclass that decodes hex, with a readable console output" -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -1438,7 +1390,6 @@ test = ["eth-utils (>=1.0.1,<3)", "hypothesis (>=3.44.24,<=6.31.6)", "pytest (>= name = "httplib2" version = "0.22.0" description = "A comprehensive HTTP client library." -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -1453,7 +1404,6 @@ pyparsing = {version = ">=2.4.2,<3.0.0 || >3.0.0,<3.0.1 || >3.0.1,<3.0.2 || >3.0 name = "hypothesis" version = "6.21.6" description = "A library for property-based testing" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -1485,7 +1435,6 @@ zoneinfo = ["backports.zoneinfo (>=0.2.1)", "importlib-resources (>=3.3.0)", "tz name = "idna" version = "3.4" description = "Internationalized Domain Names in Applications (IDNA)" -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -1497,7 +1446,6 @@ files = [ name = "iniconfig" version = "2.0.0" description = "brain-dead simple config-ini parsing" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1509,7 +1457,6 @@ files = [ name = "ipfshttpclient" version = "0.8.0a2" description = "Python IPFS HTTP CLIENT library" -category = "main" optional = false python-versions = ">=3.6.2,!=3.7.0,!=3.7.1" files = [ @@ -1525,7 +1472,6 @@ requests = ">=2.11" name = "itsdangerous" version = "2.1.2" description = "Safely pass data to untrusted environments and back." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1537,7 +1483,6 @@ files = [ name = "jinja2" version = "3.1.2" description = "A very fast and expressive template engine." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1555,7 +1500,6 @@ i18n = ["Babel (>=2.7)"] name = "jsonschema" version = "4.19.0" description = "An implementation of JSON Schema validation for Python" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -1577,7 +1521,6 @@ format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339- name = "jsonschema-specifications" version = "2023.7.1" description = "The JSON Schema meta-schemas and vocabularies, exposed as a Registry" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -1592,7 +1535,6 @@ referencing = ">=0.28.0" name = "lru-dict" version = "1.2.0" description = "An Dict like LRU container." -category = "main" optional = false python-versions = "*" files = [ @@ -1687,7 +1629,6 @@ test = ["pytest"] name = "markupsafe" version = "2.1.3" description = "Safely add untrusted strings to HTML/XML markup." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1711,6 +1652,16 @@ files = [ {file = "MarkupSafe-2.1.3-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:5bbe06f8eeafd38e5d0a4894ffec89378b6c6a625ff57e3028921f8ff59318ac"}, {file = "MarkupSafe-2.1.3-cp311-cp311-win32.whl", hash = "sha256:dd15ff04ffd7e05ffcb7fe79f1b98041b8ea30ae9234aed2a9168b5797c3effb"}, {file = "MarkupSafe-2.1.3-cp311-cp311-win_amd64.whl", hash = "sha256:134da1eca9ec0ae528110ccc9e48041e0828d79f24121a1a146161103c76e686"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:f698de3fd0c4e6972b92290a45bd9b1536bffe8c6759c62471efaa8acb4c37bc"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:aa57bd9cf8ae831a362185ee444e15a93ecb2e344c8e52e4d721ea3ab6ef1823"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ffcc3f7c66b5f5b7931a5aa68fc9cecc51e685ef90282f4a82f0f5e9b704ad11"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:47d4f1c5f80fc62fdd7777d0d40a2e9dda0a05883ab11374334f6c4de38adffd"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1f67c7038d560d92149c060157d623c542173016c4babc0c1913cca0564b9939"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:9aad3c1755095ce347e26488214ef77e0485a3c34a50c5a5e2471dff60b9dd9c"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:14ff806850827afd6b07a5f32bd917fb7f45b046ba40c57abdb636674a8b559c"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:8f9293864fe09b8149f0cc42ce56e3f0e54de883a9de90cd427f191c346eb2e1"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-win32.whl", hash = "sha256:715d3562f79d540f251b99ebd6d8baa547118974341db04f5ad06d5ea3eb8007"}, + {file = "MarkupSafe-2.1.3-cp312-cp312-win_amd64.whl", hash = "sha256:1b8dd8c3fd14349433c79fa8abeb573a55fc0fdd769133baac1f5e07abf54aeb"}, {file = "MarkupSafe-2.1.3-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:8e254ae696c88d98da6555f5ace2279cf7cd5b3f52be2b5cf97feafe883b58d2"}, {file = "MarkupSafe-2.1.3-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:cb0932dc158471523c9637e807d9bfb93e06a95cbf010f1a38b98623b929ef2b"}, {file = "MarkupSafe-2.1.3-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9402b03f1a1b4dc4c19845e5c749e3ab82d5078d16a2a4c2cd2df62d57bb0707"}, @@ -1747,7 +1698,6 @@ files = [ name = "morphys" version = "1.0" description = "Smart conversions between unicode and bytes types for common cases" -category = "main" optional = false python-versions = "*" files = [ @@ -1758,7 +1708,6 @@ files = [ name = "multiaddr" version = "0.0.9" description = "Python implementation of jbenet's multiaddr" -category = "main" optional = false python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*" files = [ @@ -1776,7 +1725,6 @@ varint = "*" name = "multidict" version = "6.0.4" description = "multidict implementation" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1860,7 +1808,6 @@ files = [ name = "mypy-extensions" version = "1.0.0" description = "Type system extensions for programs checked with the mypy type checker." -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -1872,7 +1819,6 @@ files = [ name = "netaddr" version = "0.9.0" description = "A network address manipulation library for Python" -category = "main" optional = false python-versions = "*" files = [ @@ -1884,7 +1830,6 @@ files = [ name = "open-aea" version = "1.41.0" description = "Open Autonomous Economic Agent framework (without vendor lock-in)" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -1924,7 +1869,6 @@ test-tools = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "jsonschema (>=4.1 name = "open-aea-bip-utils" version = "2.7.2" description = "Generation of mnemonics, seeds, private/public keys and addresses for different types of cryptocurrencies" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -1948,7 +1892,6 @@ develop = ["coverage (>=5.3)", "flake8 (>=3.8)", "isort (>=5.8)", "mypy (>=0.900 name = "open-aea-cli-ipfs" version = "1.41.0" description = "CLI extension for open AEA framework wrapping IPFS functionality." -category = "main" optional = false python-versions = "*" files = [ @@ -1965,7 +1908,6 @@ pytest = ">=7.0.0,<7.3.0" name = "open-aea-cosmpy" version = "0.6.6" description = "A library for interacting with the cosmos networks" -category = "main" optional = false python-versions = ">=3.8,<4.0" files = [ @@ -1989,7 +1931,6 @@ requests = "*" name = "open-aea-ledger-cosmos" version = "1.41.0" description = "Python package wrapping the public and private key cryptography and ledger api of Cosmos." -category = "main" optional = false python-versions = "*" files = [ @@ -2008,7 +1949,6 @@ pycryptodome = ">=3.10.1,<4.0.0" name = "open-aea-ledger-ethereum" version = "1.41.0" description = "Python package wrapping the public and private key cryptography and ledger api of Ethereum." -category = "main" optional = false python-versions = "*" files = [ @@ -2026,7 +1966,6 @@ web3 = ">=6.0.0,<7" name = "open-aea-test-autonomy" version = "0.13.1" description = "Plugin containing test tools for open-autonomy packages." -category = "main" optional = false python-versions = "*" files = [ @@ -2044,7 +1983,6 @@ pytest = "7.2.1" name = "open-autonomy" version = "0.13.1" description = "A framework for the creation of autonomous agent services." -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -2076,7 +2014,6 @@ cli = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.4 name = "packaging" version = "23.2" description = "Core utilities for Python packages" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2088,7 +2025,6 @@ files = [ name = "paramiko" version = "3.3.1" description = "SSH2 protocol library" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -2110,7 +2046,6 @@ invoke = ["invoke (>=2.0)"] name = "parsimonious" version = "0.9.0" description = "(Soon to be) the fastest pure-Python PEG parser I could muster" -category = "main" optional = false python-versions = "*" files = [ @@ -2124,7 +2059,6 @@ regex = ">=2022.3.15" name = "platformdirs" version = "3.11.0" description = "A small Python package for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2140,7 +2074,6 @@ test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=7.4)", "pytest-co name = "pluggy" version = "1.3.0" description = "plugin and hook calling mechanisms for python" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -2156,7 +2089,6 @@ testing = ["pytest", "pytest-benchmark"] name = "protobuf" version = "4.24.4" description = "" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2179,7 +2111,6 @@ files = [ name = "py" version = "1.11.0" description = "library with cross-python path, ini-parsing, io, code, log facilities" -category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -2191,7 +2122,6 @@ files = [ name = "py-ecc" version = "6.0.0" description = "Elliptic curve crypto in python including secp256k1 and alt_bn128" -category = "main" optional = false python-versions = ">=3.6, <4" files = [ @@ -2214,7 +2144,6 @@ test = ["pytest (==6.2.5)", "pytest-xdist (==1.26.0)"] name = "py-eth-sig-utils" version = "0.4.0" description = "Python Ethereum Signing Utils" -category = "main" optional = false python-versions = "*" files = [ @@ -2232,7 +2161,6 @@ rlp = ">=1.1.0" name = "py-multibase" version = "1.0.3" description = "Multibase implementation for Python" -category = "main" optional = false python-versions = "*" files = [ @@ -2249,7 +2177,6 @@ six = ">=1.10.0,<2.0" name = "py-multicodec" version = "0.2.1" description = "Multicodec implementation in Python" -category = "main" optional = false python-versions = "*" files = [ @@ -2266,7 +2193,6 @@ varint = ">=1.0.2,<2.0.0" name = "py-sr25519-bindings" version = "0.2.0" description = "Python bindings for sr25519 library" -category = "main" optional = false python-versions = "*" files = [ @@ -2339,7 +2265,6 @@ files = [ name = "pyasn1" version = "0.5.0" description = "Pure-Python implementation of ASN.1 types and DER/BER/CER codecs (X.208)" -category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,>=2.7" files = [ @@ -2351,7 +2276,6 @@ files = [ name = "pyasn1-modules" version = "0.3.0" description = "A collection of ASN.1-based protocols modules" -category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,>=2.7" files = [ @@ -2366,7 +2290,6 @@ pyasn1 = ">=0.4.6,<0.6.0" name = "pycparser" version = "2.21" description = "C parser in Python" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -2378,7 +2301,6 @@ files = [ name = "pycryptodome" version = "3.18.0" description = "Cryptographic library for Python" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" files = [ @@ -2420,7 +2342,6 @@ files = [ name = "pymultihash" version = "0.8.2" description = "Python implementation of the multihash specification" -category = "main" optional = false python-versions = "*" files = [ @@ -2436,7 +2357,6 @@ sha3 = ["pysha3"] name = "pynacl" version = "1.5.0" description = "Python binding to the Networking and Cryptography (NaCl) library" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -2463,7 +2383,6 @@ tests = ["hypothesis (>=3.27.0)", "pytest (>=3.2.1,!=3.3.0)"] name = "pyparsing" version = "3.1.1" description = "pyparsing module - Classes and methods to define and execute parsing grammars" -category = "main" optional = false python-versions = ">=3.6.8" files = [ @@ -2478,7 +2397,6 @@ diagrams = ["jinja2", "railroad-diagrams"] name = "pytest" version = "7.2.1" description = "pytest: simple powerful testing with Python" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2502,7 +2420,6 @@ testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2. name = "pytest-asyncio" version = "0.20.3" description = "Pytest support for asyncio" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2521,7 +2438,6 @@ testing = ["coverage (>=6.2)", "flaky (>=3.5.0)", "hypothesis (>=5.7.1)", "mypy name = "pytest-cov" version = "4.0.0" description = "Pytest plugin for measuring coverage." -category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -2540,7 +2456,6 @@ testing = ["fields", "hunter", "process-tests", "pytest-xdist", "six", "virtuale name = "pytest-randomly" version = "3.12.0" description = "Pytest plugin to randomly order tests and control random.seed." -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2555,7 +2470,6 @@ pytest = "*" name = "pytest-rerunfailures" version = "11.0" description = "pytest plugin to re-run tests to eliminate flaky failures" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -2571,7 +2485,6 @@ pytest = ">=5.3" name = "python-baseconv" version = "1.2.2" description = "Convert numbers from base 10 integers to base X strings and back again." -category = "main" optional = false python-versions = "*" files = [ @@ -2582,7 +2495,6 @@ files = [ name = "python-dotenv" version = "0.17.1" description = "Read key-value pairs from a .env file and set them as environment variables" -category = "main" optional = false python-versions = "*" files = [ @@ -2597,7 +2509,6 @@ cli = ["click (>=5.0)"] name = "pytz" version = "2022.2.1" description = "World timezone definitions, modern and historical" -category = "main" optional = false python-versions = "*" files = [ @@ -2609,7 +2520,6 @@ files = [ name = "pyunormalize" version = "15.0.0" description = "Unicode normalization forms (NFC, NFKC, NFD, NFKD). A library independent from the Python core Unicode database." -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -2620,7 +2530,6 @@ files = [ name = "pywin32" version = "306" description = "Python for Window Extensions" -category = "main" optional = false python-versions = "*" files = [ @@ -2644,7 +2553,6 @@ files = [ name = "pyyaml" version = "6.0.1" description = "YAML parser and emitter for Python" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -2653,6 +2561,7 @@ files = [ {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:69b023b2b4daa7548bcfbd4aa3da05b3a74b772db9e23b982788168117739938"}, {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:81e0b275a9ecc9c0c0c07b4b90ba548307583c125f54d5b6946cfee6360c733d"}, {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ba336e390cd8e4d1739f42dfe9bb83a3cc2e80f567d8805e11b46f4a943f5515"}, + {file = "PyYAML-6.0.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:326c013efe8048858a6d312ddd31d56e468118ad4cdeda36c719bf5bb6192290"}, {file = "PyYAML-6.0.1-cp310-cp310-win32.whl", hash = "sha256:bd4af7373a854424dabd882decdc5579653d7868b8fb26dc7d0e99f823aa5924"}, {file = "PyYAML-6.0.1-cp310-cp310-win_amd64.whl", hash = "sha256:fd1592b3fdf65fff2ad0004b5e363300ef59ced41c2e6b3a99d4089fa8c5435d"}, {file = "PyYAML-6.0.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:6965a7bc3cf88e5a1c3bd2e0b5c22f8d677dc88a455344035f03399034eb3007"}, @@ -2660,8 +2569,15 @@ files = [ {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:42f8152b8dbc4fe7d96729ec2b99c7097d656dc1213a3229ca5383f973a5ed6d"}, {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:062582fca9fabdd2c8b54a3ef1c978d786e0f6b3a1510e0ac93ef59e0ddae2bc"}, {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d2b04aac4d386b172d5b9692e2d2da8de7bfb6c387fa4f801fbf6fb2e6ba4673"}, + {file = "PyYAML-6.0.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:e7d73685e87afe9f3b36c799222440d6cf362062f78be1013661b00c5c6f678b"}, {file = "PyYAML-6.0.1-cp311-cp311-win32.whl", hash = "sha256:1635fd110e8d85d55237ab316b5b011de701ea0f29d07611174a1b42f1444741"}, {file = "PyYAML-6.0.1-cp311-cp311-win_amd64.whl", hash = "sha256:bf07ee2fef7014951eeb99f56f39c9bb4af143d8aa3c21b1677805985307da34"}, + {file = "PyYAML-6.0.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:855fb52b0dc35af121542a76b9a84f8d1cd886ea97c84703eaa6d88e37a2ad28"}, + {file = "PyYAML-6.0.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:40df9b996c2b73138957fe23a16a4f0ba614f4c0efce1e9406a184b6d07fa3a9"}, + {file = "PyYAML-6.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6c22bec3fbe2524cde73d7ada88f6566758a8f7227bfbf93a408a9d86bcc12a0"}, + {file = "PyYAML-6.0.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:8d4e9c88387b0f5c7d5f281e55304de64cf7f9c0021a3525bd3b1c542da3b0e4"}, + {file = "PyYAML-6.0.1-cp312-cp312-win32.whl", hash = "sha256:d483d2cdf104e7c9fa60c544d92981f12ad66a457afae824d146093b8c294c54"}, + {file = "PyYAML-6.0.1-cp312-cp312-win_amd64.whl", hash = "sha256:0d3304d8c0adc42be59c5f8a4d9e3d7379e6955ad754aa9d6ab7a398b59dd1df"}, {file = "PyYAML-6.0.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:50550eb667afee136e9a77d6dc71ae76a44df8b3e51e41b77f6de2932bfe0f47"}, {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1fe35611261b29bd1de0070f0b2f47cb6ff71fa6595c077e42bd0c419fa27b98"}, {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:704219a11b772aea0d8ecd7058d0082713c3562b4e271b849ad7dc4a5c90c13c"}, @@ -2678,6 +2594,7 @@ files = [ {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a0cd17c15d3bb3fa06978b4e8958dcdc6e0174ccea823003a106c7d4d7899ac5"}, {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:28c119d996beec18c05208a8bd78cbe4007878c6dd15091efb73a30e90539696"}, {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7e07cbde391ba96ab58e532ff4803f79c4129397514e1413a7dc761ccd755735"}, + {file = "PyYAML-6.0.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:49a183be227561de579b4a36efbb21b3eab9651dd81b1858589f796549873dd6"}, {file = "PyYAML-6.0.1-cp38-cp38-win32.whl", hash = "sha256:184c5108a2aca3c5b3d3bf9395d50893a7ab82a38004c8f61c258d4428e80206"}, {file = "PyYAML-6.0.1-cp38-cp38-win_amd64.whl", hash = "sha256:1e2722cc9fbb45d9b87631ac70924c11d3a401b2d7f410cc0e3bbf249f2dca62"}, {file = "PyYAML-6.0.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:9eb6caa9a297fc2c2fb8862bc5370d0303ddba53ba97e71f08023b6cd73d16a8"}, @@ -2685,6 +2602,7 @@ files = [ {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5773183b6446b2c99bb77e77595dd486303b4faab2b086e7b17bc6bef28865f6"}, {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b786eecbdf8499b9ca1d697215862083bd6d2a99965554781d0d8d1ad31e13a0"}, {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bc1bf2925a1ecd43da378f4db9e4f799775d6367bdb94671027b73b393a7c42c"}, + {file = "PyYAML-6.0.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:04ac92ad1925b2cff1db0cfebffb6ffc43457495c9b3c39d3fcae417d7125dc5"}, {file = "PyYAML-6.0.1-cp39-cp39-win32.whl", hash = "sha256:faca3bdcf85b2fc05d06ff3fbc1f83e1391b3e724afa3feba7d13eeab355484c"}, {file = "PyYAML-6.0.1-cp39-cp39-win_amd64.whl", hash = "sha256:510c9deebc5c0225e8c96813043e62b680ba2f9c50a08d3724c7f28a747d1486"}, {file = "PyYAML-6.0.1.tar.gz", hash = "sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43"}, @@ -2694,7 +2612,6 @@ files = [ name = "referencing" version = "0.30.2" description = "JSON Referencing + Python" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -2710,7 +2627,6 @@ rpds-py = ">=0.7.0" name = "regex" version = "2023.10.3" description = "Alternative regular expression module, to replace re." -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -2808,7 +2724,6 @@ files = [ name = "requests" version = "2.28.2" description = "Python HTTP for Humans." -category = "main" optional = false python-versions = ">=3.7, <4" files = [ @@ -2830,7 +2745,6 @@ use-chardet-on-py3 = ["chardet (>=3.0.2,<6)"] name = "rlp" version = "3.0.0" description = "A package for Recursive Length Prefix encoding and decoding" -category = "main" optional = false python-versions = "*" files = [ @@ -2852,7 +2766,6 @@ test = ["hypothesis (==5.19.0)", "pytest (>=6.2.5,<7)", "tox (>=2.9.1,<3)"] name = "rpds-py" version = "0.10.6" description = "Python bindings to Rust's persistent data structures (rpds)" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -2961,7 +2874,6 @@ files = [ name = "rsa" version = "4.9" description = "Pure-Python RSA implementation" -category = "main" optional = false python-versions = ">=3.6,<4" files = [ @@ -2976,7 +2888,6 @@ pyasn1 = ">=0.1.3" name = "semver" version = "2.13.0" description = "Python helper for Semantic Versioning (http://semver.org/)" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -2988,7 +2899,6 @@ files = [ name = "six" version = "1.16.0" description = "Python 2 and 3 compatibility utilities" -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -3000,7 +2910,6 @@ files = [ name = "sortedcontainers" version = "2.4.0" description = "Sorted Containers -- Sorted List, Sorted Dict, Sorted Set" -category = "main" optional = false python-versions = "*" files = [ @@ -3012,7 +2921,6 @@ files = [ name = "texttable" version = "1.6.7" description = "module to create simple ASCII tables" -category = "main" optional = false python-versions = "*" files = [ @@ -3024,7 +2932,6 @@ files = [ name = "toml" version = "0.10.2" description = "Python Library for Tom's Obvious, Minimal Language" -category = "main" optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -3036,7 +2943,6 @@ files = [ name = "tomli" version = "2.0.1" description = "A lil' TOML parser" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3048,7 +2954,6 @@ files = [ name = "tomte" version = "0.2.12" description = "A library that wraps many useful tools (linters, analysers, etc) to keep Python code clean, secure, well-documented and optimised." -category = "dev" optional = false python-versions = ">=3.7,<4.0" files = [ @@ -3086,7 +2991,6 @@ vulture = ["vulture (==2.7)"] name = "toolz" version = "0.12.0" description = "List processing tools and functional utilities" -category = "main" optional = false python-versions = ">=3.5" files = [ @@ -3098,7 +3002,6 @@ files = [ name = "tox" version = "3.28.0" description = "tox is a generic virtualenv management and test command line tool" -category = "dev" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" files = [ @@ -3124,7 +3027,6 @@ testing = ["flaky (>=3.4.0)", "freezegun (>=0.3.11)", "pathlib2 (>=2.3.3)", "psu name = "typing-extensions" version = "4.8.0" description = "Backported and Experimental Type Hints for Python 3.8+" -category = "main" optional = false python-versions = ">=3.8" files = [ @@ -3136,7 +3038,6 @@ files = [ name = "uritemplate" version = "4.1.1" description = "Implementation of RFC 6570 URI Templates" -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -3148,7 +3049,6 @@ files = [ name = "urllib3" version = "1.26.16" description = "HTTP library with thread-safe connection pooling, file post, and more." -category = "main" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*" files = [ @@ -3165,7 +3065,6 @@ socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] name = "valory-docker-compose" version = "1.29.3" description = "Multi-container orchestration for Docker" -category = "main" optional = false python-versions = ">=3.4" files = [ @@ -3194,7 +3093,6 @@ tests = ["ddt (>=1.2.2,<2)", "pytest (<6)"] name = "varint" version = "1.0.2" description = "Simple python varint implementation" -category = "main" optional = false python-versions = "*" files = [ @@ -3205,7 +3103,6 @@ files = [ name = "virtualenv" version = "20.24.5" description = "Virtual Python Environment builder" -category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -3226,7 +3123,6 @@ test = ["covdefaults (>=2.3)", "coverage (>=7.2.7)", "coverage-enable-subprocess name = "watchdog" version = "3.0.0" description = "Filesystem events monitoring" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3264,14 +3160,13 @@ watchmedo = ["PyYAML (>=3.10)"] [[package]] name = "web3" -version = "6.11.0" +version = "6.11.1" description = "web3.py" -category = "main" optional = false python-versions = ">=3.7.2" files = [ - {file = "web3-6.11.0-py3-none-any.whl", hash = "sha256:44e79da6a4765eacf137f2f388e37aa0c1e24a93bdfb462cffe9441d1be3d509"}, - {file = "web3-6.11.0.tar.gz", hash = "sha256:050dea52ae73d787272e7ecba7249f096595938c90cce1a384c20375c6b0f720"}, + {file = "web3-6.11.1-py3-none-any.whl", hash = "sha256:0d39f58cbb0c652b45e711f01e01ec655117b47ba4eefd1f9550c52d205afa8c"}, + {file = "web3-6.11.1.tar.gz", hash = "sha256:d301d7120922d5b9e5c9535ef9780012ea25ea4011c2b177490ba7d3ef886b92"}, ] [package.dependencies] @@ -3281,7 +3176,7 @@ eth-account = ">=0.8.0" eth-hash = {version = ">=0.5.1", extras = ["pycryptodome"]} eth-typing = ">=3.0.0" eth-utils = ">=2.1.0" -hexbytes = ">=0.1.0" +hexbytes = ">=0.1.0,<0.4.0" jsonschema = ">=4.0.0" lru-dict = ">=1.1.6" protobuf = ">=4.21.6" @@ -3302,7 +3197,6 @@ tester = ["eth-tester[py-evm] (==v0.9.1-b.1)", "py-geth (>=3.11.0)"] name = "websocket-client" version = "0.59.0" description = "WebSocket client for Python with low level API options" -category = "main" optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" files = [ @@ -3317,7 +3211,6 @@ six = "*" name = "websockets" version = "11.0.3" description = "An implementation of the WebSocket Protocol (RFC 6455 & 7692)" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3397,7 +3290,6 @@ files = [ name = "werkzeug" version = "2.0.3" description = "The comprehensive WSGI web application library." -category = "main" optional = false python-versions = ">=3.6" files = [ @@ -3412,7 +3304,6 @@ watchdog = ["watchdog"] name = "wheel" version = "0.41.2" description = "A built-package format for Python" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3427,7 +3318,6 @@ test = ["pytest (>=6.0.0)", "setuptools (>=65)"] name = "yarl" version = "1.9.2" description = "Yet another URL library" -category = "main" optional = false python-versions = ">=3.7" files = [ @@ -3514,4 +3404,4 @@ multidict = ">=4.0" [metadata] lock-version = "2.0" python-versions = ">=3.10, <3.11" -content-hash = "4ce134636983c9885aea73c692a498ec01bd18266bed36cda27b4c79ba84cf2a" +content-hash = "f53486b8efbd8d73778e007a5ca81df29c30879ba06d4b45d0c431db06fb05f0" From a1510ee8424a42b6d147dfbea16fd56f51a6aa7c Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 17:18:55 +0200 Subject: [PATCH 21/79] fix: Resolved package incompatibilities manually --- packages/packages.json | 26 +++++++++---------- packages/valory/agents/trader/aea-config.yaml | 22 ++++++++-------- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/skill.yaml | 6 ++--- .../skills/market_manager_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 16 ++++++------ .../tx_settlement_multiplexer_abci/skill.yaml | 4 +-- 7 files changed, 39 insertions(+), 39 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 950cb7edc..17d73e846 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { - "skill/valory/market_manager_abci/0.1.0": "bafybeicreyjyimqbdcubay2weplpzzcblxa5mekmwucfhzjdbogbbriaty", - "skill/valory/decision_maker_abci/0.1.0": "bafybeiguok6wfm24p4iztxdmagtohnu25wglqlxzq5iflae3xyrs42w6hm", - "skill/valory/trader_abci/0.1.0": "bafybeiavqq3ide7pa236o6ao6u3bobko6tfsd62jd773xwr63zmbawubku", + "skill/valory/market_manager_abci/0.1.0": "bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci", + "skill/valory/decision_maker_abci/0.1.0": "bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4", + "skill/valory/trader_abci/0.1.0": "bafybeigj2skpawopovgqsfhaxmsod2z2hbnmzzieek4modu7coxeiqhh4m", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeienzghvlqommoka44xrgy24kvkhp4ww27ksnai7qbthtvklokqd64", - "service/valory/trader/0.1.0": "bafybeihizjmvnt5kenzuex4sta4igqtnutu2w5nqrdwxupc4wtd3ifbmle", + "agent/valory/trader/0.1.0": "bafybeic6v77dfjinljovk3t5kwj3rd5ka6tszx5klsve3ubg7fsak66evm", + "service/valory/trader/0.1.0": "bafybeiazwwgsq4bt7ahkciueaw47dtezveg5ihgfemcrw3gjbraupucyxy", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeifm6azxbjo6tgchl7p4bzd66eyvn6vcinyyg2fybidoydlkjybav4", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicskxgf753opvigwjejg4v4zpl27na4tzrpyssmgsprojsqcpcgdy", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", @@ -23,11 +23,11 @@ "protocol/valory/acn/1.1.0": "bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa", "protocol/valory/tendermint/0.1.0": "bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa", "protocol/valory/ipfs/0.1.0": "bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa", - "skill/valory/abstract_abci/0.1.0": "bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy", - "skill/valory/reset_pause_abci/0.1.0": "bafybeih5p6r3bezwm3sccnwuxl2zyit7aqdqe6b3q56xgbsliscgscw4em", - "skill/valory/registration_abci/0.1.0": "bafybeiem3snx3q6f6go3h6qolnj7m5sgv7rrhbfsp7yri5biv6nzkrnpi4", - "skill/valory/abstract_round_abci/0.1.0": "bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu", - "connection/valory/abci/0.1.0": "bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina", + "skill/valory/abstract_abci/0.1.0": "bafybeign23wzgany57twt7v6y2nrzcx4k7zyvnd5fwjicipawcm43xxolq", + "skill/valory/reset_pause_abci/0.1.0": "bafybeifeocwa2shc6bac7t7vjh7fz4kd4amjyzzh5nkswf2lqfodx7u6n4", + "skill/valory/registration_abci/0.1.0": "bafybeibgx6lnqdhch4nf5bddwmm7ehnxa7lmd6ek22jjvjarwynyys54di", + "skill/valory/abstract_round_abci/0.1.0": "bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a", + "connection/valory/abci/0.1.0": "bafybeigxzmb7xjmjdhia2s7fyzhhei4qybowx3s4aetrmi6zwopgrebepu", "connection/valory/http_client/0.23.0": "bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y", "connection/valory/ledger/0.19.0": "bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a", "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq", @@ -35,8 +35,8 @@ "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y", "contract/valory/gnosis_safe/0.1.0": "bafybeias2zrinapw4luvr73i6fyzsnh4saxg7ktl6nkbskkamhs2tlyotq", "contract/valory/service_registry/0.1.0": "bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu", - "skill/valory/transaction_settlement_abci/0.1.0": "bafybeici2zsmgzwd46tvkdee2mbg4gq7zmvwmyfscjtcve7xunbzfmvoza", + "skill/valory/transaction_settlement_abci/0.1.0": "bafybeihigszhn4u3mlzgp2oxkgbvgwazs22iwqrxnmkrh3xosfbei6o6qq", "contract/valory/multisend/0.1.0": "bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y", - "skill/valory/termination_abci/0.1.0": "bafybeiespnae46stpib425aed6cpvhvnvc4ywgsm77cs7sbn7us67j7ufu" + "skill/valory/termination_abci/0.1.0": "bafybeig5fafcst6q6o4t2scmws2lk3haf77fg6o7oxq47aspc2ffzs2bky" } } \ No newline at end of file diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 9e8779912..afd4755f1 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -9,7 +9,7 @@ fingerprint: __init__.py: bafybeighcq4pmuzte6vhvvprrvo563vzghkoit2h6qdqxf2ma5bghevkee fingerprint_ignore_patterns: [] connections: -- valory/abci:0.1.0:bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina +- valory/abci:0.1.0:bafybeigxzmb7xjmjdhia2s7fyzhhei4qybowx3s4aetrmi6zwopgrebepu - valory/http_client:0.23.0:bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y - valory/ipfs:0.1.0:bafybeih2ybmughrcm2arwlpnoksyzxonjomo6lruwxienslaeizngjm44y - valory/ledger:0.19.0:bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a @@ -35,16 +35,16 @@ protocols: - valory/ledger_api:1.0.0:bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby - valory/tendermint:0.1.0:bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa skills: -- valory/abstract_abci:0.1.0:bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy -- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu -- valory/registration_abci:0.1.0:bafybeiem3snx3q6f6go3h6qolnj7m5sgv7rrhbfsp7yri5biv6nzkrnpi4 -- valory/reset_pause_abci:0.1.0:bafybeih5p6r3bezwm3sccnwuxl2zyit7aqdqe6b3q56xgbsliscgscw4em -- valory/termination_abci:0.1.0:bafybeiespnae46stpib425aed6cpvhvnvc4ywgsm77cs7sbn7us67j7ufu -- valory/transaction_settlement_abci:0.1.0:bafybeici2zsmgzwd46tvkdee2mbg4gq7zmvwmyfscjtcve7xunbzfmvoza -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifm6azxbjo6tgchl7p4bzd66eyvn6vcinyyg2fybidoydlkjybav4 -- valory/market_manager_abci:0.1.0:bafybeicreyjyimqbdcubay2weplpzzcblxa5mekmwucfhzjdbogbbriaty -- valory/decision_maker_abci:0.1.0:bafybeiguok6wfm24p4iztxdmagtohnu25wglqlxzq5iflae3xyrs42w6hm -- valory/trader_abci:0.1.0:bafybeiavqq3ide7pa236o6ao6u3bobko6tfsd62jd773xwr63zmbawubku +- valory/abstract_abci:0.1.0:bafybeign23wzgany57twt7v6y2nrzcx4k7zyvnd5fwjicipawcm43xxolq +- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a +- valory/registration_abci:0.1.0:bafybeibgx6lnqdhch4nf5bddwmm7ehnxa7lmd6ek22jjvjarwynyys54di +- valory/reset_pause_abci:0.1.0:bafybeifeocwa2shc6bac7t7vjh7fz4kd4amjyzzh5nkswf2lqfodx7u6n4 +- valory/termination_abci:0.1.0:bafybeig5fafcst6q6o4t2scmws2lk3haf77fg6o7oxq47aspc2ffzs2bky +- valory/transaction_settlement_abci:0.1.0:bafybeihigszhn4u3mlzgp2oxkgbvgwazs22iwqrxnmkrh3xosfbei6o6qq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicskxgf753opvigwjejg4v4zpl27na4tzrpyssmgsprojsqcpcgdy +- valory/market_manager_abci:0.1.0:bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci +- valory/decision_maker_abci:0.1.0:bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4 +- valory/trader_abci:0.1.0:bafybeigj2skpawopovgqsfhaxmsod2z2hbnmzzieek4modu7coxeiqhh4m default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 8e58e41c1..b46a10829 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeienzghvlqommoka44xrgy24kvkhp4ww27ksnai7qbthtvklokqd64 +agent: valory/trader:0.1.0:bafybeic6v77dfjinljovk3t5kwj3rd5ka6tszx5klsve3ubg7fsak66evm number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index c732b4616..6139b53ab 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -56,9 +56,9 @@ contracts: protocols: - valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa skills: -- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu -- valory/market_manager_abci:0.1.0:bafybeicreyjyimqbdcubay2weplpzzcblxa5mekmwucfhzjdbogbbriaty -- valory/transaction_settlement_abci:0.1.0:bafybeici2zsmgzwd46tvkdee2mbg4gq7zmvwmyfscjtcve7xunbzfmvoza +- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a +- valory/market_manager_abci:0.1.0:bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci +- valory/transaction_settlement_abci:0.1.0:bafybeihigszhn4u3mlzgp2oxkgbvgwazs22iwqrxnmkrh3xosfbei6o6qq behaviours: main: args: {} diff --git a/packages/valory/skills/market_manager_abci/skill.yaml b/packages/valory/skills/market_manager_abci/skill.yaml index 04beb55ef..8188ba4b0 100644 --- a/packages/valory/skills/market_manager_abci/skill.yaml +++ b/packages/valory/skills/market_manager_abci/skill.yaml @@ -26,7 +26,7 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu +- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a behaviours: main: args: {} diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 93f1d0a13..51bbeb75a 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -19,14 +19,14 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu -- valory/registration_abci:0.1.0:bafybeiem3snx3q6f6go3h6qolnj7m5sgv7rrhbfsp7yri5biv6nzkrnpi4 -- valory/reset_pause_abci:0.1.0:bafybeih5p6r3bezwm3sccnwuxl2zyit7aqdqe6b3q56xgbsliscgscw4em -- valory/transaction_settlement_abci:0.1.0:bafybeici2zsmgzwd46tvkdee2mbg4gq7zmvwmyfscjtcve7xunbzfmvoza -- valory/termination_abci:0.1.0:bafybeiespnae46stpib425aed6cpvhvnvc4ywgsm77cs7sbn7us67j7ufu -- valory/market_manager_abci:0.1.0:bafybeicreyjyimqbdcubay2weplpzzcblxa5mekmwucfhzjdbogbbriaty -- valory/decision_maker_abci:0.1.0:bafybeiguok6wfm24p4iztxdmagtohnu25wglqlxzq5iflae3xyrs42w6hm -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifm6azxbjo6tgchl7p4bzd66eyvn6vcinyyg2fybidoydlkjybav4 +- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a +- valory/registration_abci:0.1.0:bafybeibgx6lnqdhch4nf5bddwmm7ehnxa7lmd6ek22jjvjarwynyys54di +- valory/reset_pause_abci:0.1.0:bafybeifeocwa2shc6bac7t7vjh7fz4kd4amjyzzh5nkswf2lqfodx7u6n4 +- valory/transaction_settlement_abci:0.1.0:bafybeihigszhn4u3mlzgp2oxkgbvgwazs22iwqrxnmkrh3xosfbei6o6qq +- valory/termination_abci:0.1.0:bafybeig5fafcst6q6o4t2scmws2lk3haf77fg6o7oxq47aspc2ffzs2bky +- valory/market_manager_abci:0.1.0:bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci +- valory/decision_maker_abci:0.1.0:bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicskxgf753opvigwjejg4v4zpl27na4tzrpyssmgsprojsqcpcgdy behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 0c325b4ef..46124ff9e 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -19,8 +19,8 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeiaxahvneaepovcctdoxreuw7tuh7zdcrnbqgeq62dxy3ncfwrceeu -- valory/decision_maker_abci:0.1.0:bafybeiguok6wfm24p4iztxdmagtohnu25wglqlxzq5iflae3xyrs42w6hm +- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a +- valory/decision_maker_abci:0.1.0:bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4 behaviours: main: args: {} From 603c50e6d257d0b90ab3ca314acc8fb85e6aab00 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 17:39:18 +0200 Subject: [PATCH 22/79] fix: Resolved package incompatibilities manually --- packages/packages.json | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 17d73e846..7cd29dd89 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -15,28 +15,28 @@ "contract/valory/agent_registry/0.1.0": "bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty" }, "third_party": { - "protocol/open_aea/signing/1.0.0": "bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m", - "protocol/valory/abci/0.1.0": "bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe", - "protocol/valory/contract_api/1.0.0": "bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa", - "protocol/valory/http/1.0.0": "bafybeia5bxdua2i6chw6pg47bvoljzcpuqxzy4rdrorbdmcbnwmnfdobtu", - "protocol/valory/ledger_api/1.0.0": "bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby", - "protocol/valory/acn/1.1.0": "bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa", - "protocol/valory/tendermint/0.1.0": "bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa", - "protocol/valory/ipfs/0.1.0": "bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa", - "skill/valory/abstract_abci/0.1.0": "bafybeign23wzgany57twt7v6y2nrzcx4k7zyvnd5fwjicipawcm43xxolq", - "skill/valory/reset_pause_abci/0.1.0": "bafybeifeocwa2shc6bac7t7vjh7fz4kd4amjyzzh5nkswf2lqfodx7u6n4", - "skill/valory/registration_abci/0.1.0": "bafybeibgx6lnqdhch4nf5bddwmm7ehnxa7lmd6ek22jjvjarwynyys54di", - "skill/valory/abstract_round_abci/0.1.0": "bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a", - "connection/valory/abci/0.1.0": "bafybeigxzmb7xjmjdhia2s7fyzhhei4qybowx3s4aetrmi6zwopgrebepu", - "connection/valory/http_client/0.23.0": "bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y", - "connection/valory/ledger/0.19.0": "bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a", - "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq", - "connection/valory/ipfs/0.1.0": "bafybeih2ybmughrcm2arwlpnoksyzxonjomo6lruwxienslaeizngjm44y", + "protocol/open_aea/signing/1.0.0": "bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii", + "protocol/valory/abci/0.1.0": "bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu", + "protocol/valory/contract_api/1.0.0": "bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka", + "protocol/valory/http/1.0.0": "bafybeiejoqgv7finfxo3rcvvovrlj5ccrbgxodjq43uo26ylpowsa3llfe", + "protocol/valory/ledger_api/1.0.0": "bafybeige5agrztgzfevyglf7mb4o7pzfttmq4f6zi765y4g2zvftbyowru", + "protocol/valory/acn/1.1.0": "bafybeic2pxzfc3voxl2ejhcqyf2ehm4wm5gxvgx7bliloiqi2uppmq6weu", + "protocol/valory/tendermint/0.1.0": "bafybeig6g6twajlwssfbfp5rlnu5mwzuu5kgak5cs4fich7rlkx6whesnu", + "protocol/valory/ipfs/0.1.0": "bafybeiedxeismnx3k5ty4mvvhlqideixlhqmi5mtcki4lxqfa7uqh7p33u", + "skill/valory/abstract_abci/0.1.0": "bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a", + "skill/valory/reset_pause_abci/0.1.0": "bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe", + "skill/valory/registration_abci/0.1.0": "bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm", + "skill/valory/abstract_round_abci/0.1.0": "bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq", + "connection/valory/abci/0.1.0": "bafybeibtnfu6skrpducj2fzjzw7lrwj3et63xx6u5dryrabec26utzxsf4", + "connection/valory/http_client/0.23.0": "bafybeifgeqgryx6b3s6eseyzyezygmeitcpt3tkor2eiycozoi6clgdrny", + "connection/valory/ledger/0.19.0": "bafybeigo5vst3zlltkouenwxuzn6c47yr2fbbml6dl2o32rfnsezmalgnu", + "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihge56dn3xep2dzomu7rtvbgo4uc2qqh7ljl3fubqdi2lq44gs5lq", + "connection/valory/ipfs/0.1.0": "bafybeigkn27u7m5atju6a724clycyfshbgcbwheztil2bky7krfa46ub2a", "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y", - "contract/valory/gnosis_safe/0.1.0": "bafybeias2zrinapw4luvr73i6fyzsnh4saxg7ktl6nkbskkamhs2tlyotq", + "contract/valory/gnosis_safe/0.1.0": "bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci", "contract/valory/service_registry/0.1.0": "bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu", - "skill/valory/transaction_settlement_abci/0.1.0": "bafybeihigszhn4u3mlzgp2oxkgbvgwazs22iwqrxnmkrh3xosfbei6o6qq", + "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy", "contract/valory/multisend/0.1.0": "bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y", - "skill/valory/termination_abci/0.1.0": "bafybeig5fafcst6q6o4t2scmws2lk3haf77fg6o7oxq47aspc2ffzs2bky" + "skill/valory/termination_abci/0.1.0": "bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy" } } \ No newline at end of file From 38a0f77ee36406618b879986ed67a84eacd9015a Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 17:50:52 +0200 Subject: [PATCH 23/79] fix: Resolved package incompatibilities manually --- packages/valory/agents/trader/aea-config.yaml | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index afd4755f1..5eb5ca824 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -9,13 +9,13 @@ fingerprint: __init__.py: bafybeighcq4pmuzte6vhvvprrvo563vzghkoit2h6qdqxf2ma5bghevkee fingerprint_ignore_patterns: [] connections: -- valory/abci:0.1.0:bafybeigxzmb7xjmjdhia2s7fyzhhei4qybowx3s4aetrmi6zwopgrebepu -- valory/http_client:0.23.0:bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y -- valory/ipfs:0.1.0:bafybeih2ybmughrcm2arwlpnoksyzxonjomo6lruwxienslaeizngjm44y -- valory/ledger:0.19.0:bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a -- valory/p2p_libp2p_client:0.1.0:bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq +- valory/abci:0.1.0:bafybeibtnfu6skrpducj2fzjzw7lrwj3et63xx6u5dryrabec26utzxsf4 +- valory/http_client:0.23.0:bafybeifgeqgryx6b3s6eseyzyezygmeitcpt3tkor2eiycozoi6clgdrny +- valory/ipfs:0.1.0:bafybeigkn27u7m5atju6a724clycyfshbgcbwheztil2bky7krfa46ub2a +- valory/ledger:0.19.0:bafybeigo5vst3zlltkouenwxuzn6c47yr2fbbml6dl2o32rfnsezmalgnu +- valory/p2p_libp2p_client:0.1.0:bafybeihge56dn3xep2dzomu7rtvbgo4uc2qqh7ljl3fubqdi2lq44gs5lq contracts: -- valory/gnosis_safe:0.1.0:bafybeias2zrinapw4luvr73i6fyzsnh4saxg7ktl6nkbskkamhs2tlyotq +- valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci - valory/gnosis_safe_proxy_factory:0.1.0:bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y - valory/service_registry:0.1.0:bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu - valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m @@ -35,12 +35,12 @@ protocols: - valory/ledger_api:1.0.0:bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby - valory/tendermint:0.1.0:bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa skills: -- valory/abstract_abci:0.1.0:bafybeign23wzgany57twt7v6y2nrzcx4k7zyvnd5fwjicipawcm43xxolq -- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a -- valory/registration_abci:0.1.0:bafybeibgx6lnqdhch4nf5bddwmm7ehnxa7lmd6ek22jjvjarwynyys54di -- valory/reset_pause_abci:0.1.0:bafybeifeocwa2shc6bac7t7vjh7fz4kd4amjyzzh5nkswf2lqfodx7u6n4 -- valory/termination_abci:0.1.0:bafybeig5fafcst6q6o4t2scmws2lk3haf77fg6o7oxq47aspc2ffzs2bky -- valory/transaction_settlement_abci:0.1.0:bafybeihigszhn4u3mlzgp2oxkgbvgwazs22iwqrxnmkrh3xosfbei6o6qq +- valory/abstract_abci:0.1.0:bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a +- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq +- valory/registration_abci:0.1.0:bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm +- valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe +- valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy +- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicskxgf753opvigwjejg4v4zpl27na4tzrpyssmgsprojsqcpcgdy - valory/market_manager_abci:0.1.0:bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci - valory/decision_maker_abci:0.1.0:bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4 From c7845ccc69abbe2758d42562d2e6fb0447d08ff3 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 17:54:56 +0200 Subject: [PATCH 24/79] chore: Update packages --- packages/packages.json | 12 +++++----- packages/valory/agents/trader/aea-config.yaml | 24 +++++++++---------- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/skill.yaml | 10 ++++---- .../skills/market_manager_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 16 ++++++------- .../tx_settlement_multiplexer_abci/skill.yaml | 4 ++-- 7 files changed, 35 insertions(+), 35 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 7cd29dd89..f0e87998a 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { - "skill/valory/market_manager_abci/0.1.0": "bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci", - "skill/valory/decision_maker_abci/0.1.0": "bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4", - "skill/valory/trader_abci/0.1.0": "bafybeigj2skpawopovgqsfhaxmsod2z2hbnmzzieek4modu7coxeiqhh4m", + "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidk7lohqazdqpskrvvu2dxxbh2zc2exn56ig3usl6fmgk23oy2roi", + "skill/valory/trader_abci/0.1.0": "bafybeiana5u5sesfypqd4vln3uu5q4aod6ezjnonsq2liymdiilx6wr5uu", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeic6v77dfjinljovk3t5kwj3rd5ka6tszx5klsve3ubg7fsak66evm", - "service/valory/trader/0.1.0": "bafybeiazwwgsq4bt7ahkciueaw47dtezveg5ihgfemcrw3gjbraupucyxy", + "agent/valory/trader/0.1.0": "bafybeihpkytjiusg7vrehf34ct56vxchd2u2ccuhf6xhpa6zwa3c3rpod4", + "service/valory/trader/0.1.0": "bafybeidwho7fb5yy2aa6zb744b52wz5t5bexiflkv2u35udeyrbvx5t634", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicskxgf753opvigwjejg4v4zpl27na4tzrpyssmgsprojsqcpcgdy", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeieokhhlopr2cj77cf3rbbxt2nhffegzifhcs4l7fictrkoq3dp77q", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 5eb5ca824..1f58f0c67 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -26,14 +26,14 @@ contracts: - valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e - valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 protocols: -- open_aea/signing:1.0.0:bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m -- valory/abci:0.1.0:bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe -- valory/acn:1.1.0:bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa -- valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa -- valory/http:1.0.0:bafybeia5bxdua2i6chw6pg47bvoljzcpuqxzy4rdrorbdmcbnwmnfdobtu -- valory/ipfs:0.1.0:bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa -- valory/ledger_api:1.0.0:bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby -- valory/tendermint:0.1.0:bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa +- open_aea/signing:1.0.0:bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii +- valory/abci:0.1.0:bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu +- valory/acn:1.1.0:bafybeic2pxzfc3voxl2ejhcqyf2ehm4wm5gxvgx7bliloiqi2uppmq6weu +- valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka +- valory/http:1.0.0:bafybeiejoqgv7finfxo3rcvvovrlj5ccrbgxodjq43uo26ylpowsa3llfe +- valory/ipfs:0.1.0:bafybeiedxeismnx3k5ty4mvvhlqideixlhqmi5mtcki4lxqfa7uqh7p33u +- valory/ledger_api:1.0.0:bafybeige5agrztgzfevyglf7mb4o7pzfttmq4f6zi765y4g2zvftbyowru +- valory/tendermint:0.1.0:bafybeig6g6twajlwssfbfp5rlnu5mwzuu5kgak5cs4fich7rlkx6whesnu skills: - valory/abstract_abci:0.1.0:bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicskxgf753opvigwjejg4v4zpl27na4tzrpyssmgsprojsqcpcgdy -- valory/market_manager_abci:0.1.0:bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci -- valory/decision_maker_abci:0.1.0:bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4 -- valory/trader_abci:0.1.0:bafybeigj2skpawopovgqsfhaxmsod2z2hbnmzzieek4modu7coxeiqhh4m +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieokhhlopr2cj77cf3rbbxt2nhffegzifhcs4l7fictrkoq3dp77q +- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m +- valory/decision_maker_abci:0.1.0:bafybeidk7lohqazdqpskrvvu2dxxbh2zc2exn56ig3usl6fmgk23oy2roi +- valory/trader_abci:0.1.0:bafybeiana5u5sesfypqd4vln3uu5q4aod6ezjnonsq2liymdiilx6wr5uu default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index b46a10829..430abd1bf 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeic6v77dfjinljovk3t5kwj3rd5ka6tszx5klsve3ubg7fsak66evm +agent: valory/trader:0.1.0:bafybeihpkytjiusg7vrehf34ct56vxchd2u2ccuhf6xhpa6zwa3c3rpod4 number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 6139b53ab..49e967ef8 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -44,7 +44,7 @@ fingerprint: fingerprint_ignore_patterns: [] connections: [] contracts: -- valory/gnosis_safe:0.1.0:bafybeias2zrinapw4luvr73i6fyzsnh4saxg7ktl6nkbskkamhs2tlyotq +- valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci - valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m - valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi - valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y @@ -54,11 +54,11 @@ contracts: - valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 - valory/agent_registry:0.1.0:bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty protocols: -- valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa +- valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka skills: -- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a -- valory/market_manager_abci:0.1.0:bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci -- valory/transaction_settlement_abci:0.1.0:bafybeihigszhn4u3mlzgp2oxkgbvgwazs22iwqrxnmkrh3xosfbei6o6qq +- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq +- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m +- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy behaviours: main: args: {} diff --git a/packages/valory/skills/market_manager_abci/skill.yaml b/packages/valory/skills/market_manager_abci/skill.yaml index 8188ba4b0..e7edd85e7 100644 --- a/packages/valory/skills/market_manager_abci/skill.yaml +++ b/packages/valory/skills/market_manager_abci/skill.yaml @@ -26,7 +26,7 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a +- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq behaviours: main: args: {} diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 51bbeb75a..27472e4bc 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -19,14 +19,14 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a -- valory/registration_abci:0.1.0:bafybeibgx6lnqdhch4nf5bddwmm7ehnxa7lmd6ek22jjvjarwynyys54di -- valory/reset_pause_abci:0.1.0:bafybeifeocwa2shc6bac7t7vjh7fz4kd4amjyzzh5nkswf2lqfodx7u6n4 -- valory/transaction_settlement_abci:0.1.0:bafybeihigszhn4u3mlzgp2oxkgbvgwazs22iwqrxnmkrh3xosfbei6o6qq -- valory/termination_abci:0.1.0:bafybeig5fafcst6q6o4t2scmws2lk3haf77fg6o7oxq47aspc2ffzs2bky -- valory/market_manager_abci:0.1.0:bafybeic5gypll65aywbmzhzv6w7fed4kmzjz2gbddaurdzfidkzakaqvci -- valory/decision_maker_abci:0.1.0:bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4 -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicskxgf753opvigwjejg4v4zpl27na4tzrpyssmgsprojsqcpcgdy +- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq +- valory/registration_abci:0.1.0:bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm +- valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe +- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy +- valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy +- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m +- valory/decision_maker_abci:0.1.0:bafybeidk7lohqazdqpskrvvu2dxxbh2zc2exn56ig3usl6fmgk23oy2roi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieokhhlopr2cj77cf3rbbxt2nhffegzifhcs4l7fictrkoq3dp77q behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 46124ff9e..d5c6966dd 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -19,8 +19,8 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeieahor42hdnkdjxhhfvsnrwt7krcjxcp5bcrlakjnxqbxmmxqrz3a -- valory/decision_maker_abci:0.1.0:bafybeig7wpxtugpldzozbebdkuo42ttzimcgq6rm7n6z7z3zsltpxkfwy4 +- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq +- valory/decision_maker_abci:0.1.0:bafybeidk7lohqazdqpskrvvu2dxxbh2zc2exn56ig3usl6fmgk23oy2roi behaviours: main: args: {} From a54e710d3d31ec0728cce34e0270e751ad8cb7b9 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 18:33:28 +0200 Subject: [PATCH 25/79] WIP: Implement betting strategy 'kelly criterion' --- packages/packages.json | 10 ++-- packages/valory/agents/trader/aea-config.yaml | 6 +-- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/base.py | 49 +++++++++++++++++ .../behaviours/decision_receive.py | 4 +- .../skills/decision_maker_abci/models.py | 53 ------------------- .../skills/decision_maker_abci/skill.yaml | 6 +-- packages/valory/skills/trader_abci/skill.yaml | 4 +- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 9 files changed, 66 insertions(+), 70 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index f0e87998a..2acb8af28 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeidk7lohqazdqpskrvvu2dxxbh2zc2exn56ig3usl6fmgk23oy2roi", - "skill/valory/trader_abci/0.1.0": "bafybeiana5u5sesfypqd4vln3uu5q4aod6ezjnonsq2liymdiilx6wr5uu", + "skill/valory/decision_maker_abci/0.1.0": "bafybeibdcuzoi56bngu7gpialvwfpyl65to7clxpbztsi2qihs4qtyrjcq", + "skill/valory/trader_abci/0.1.0": "bafybeidbsguskoo37hhfgvyyd2natr5c4m4hiefsmk5m2erxh3fn2t46ai", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeihpkytjiusg7vrehf34ct56vxchd2u2ccuhf6xhpa6zwa3c3rpod4", - "service/valory/trader/0.1.0": "bafybeidwho7fb5yy2aa6zb744b52wz5t5bexiflkv2u35udeyrbvx5t634", + "agent/valory/trader/0.1.0": "bafybeibv6cgnro4mdircbmmvhps2s3nbnrrry752gi3aukwgfzdga6otju", + "service/valory/trader/0.1.0": "bafybeievs5jkfdjhols43beluyyz5i32pftx6ixqsme4suyucaihztfk4e", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeieokhhlopr2cj77cf3rbbxt2nhffegzifhcs4l7fictrkoq3dp77q", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeia6v7ibv4na2iy5g4ab4d3pddry772rbe5k7xbafakcsdimfyolny", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 1f58f0c67..348eb6822 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieokhhlopr2cj77cf3rbbxt2nhffegzifhcs4l7fictrkoq3dp77q +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeia6v7ibv4na2iy5g4ab4d3pddry772rbe5k7xbafakcsdimfyolny - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidk7lohqazdqpskrvvu2dxxbh2zc2exn56ig3usl6fmgk23oy2roi -- valory/trader_abci:0.1.0:bafybeiana5u5sesfypqd4vln3uu5q4aod6ezjnonsq2liymdiilx6wr5uu +- valory/decision_maker_abci:0.1.0:bafybeibdcuzoi56bngu7gpialvwfpyl65to7clxpbztsi2qihs4qtyrjcq +- valory/trader_abci:0.1.0:bafybeidbsguskoo37hhfgvyyd2natr5c4m4hiefsmk5m2erxh3fn2t46ai default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 430abd1bf..55f853309 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeihpkytjiusg7vrehf34ct56vxchd2u2ccuhf6xhpa6zwa3c3rpod4 +agent: valory/trader:0.1.0:bafybeibv6cgnro4mdircbmmvhps2s3nbnrrry752gi3aukwgfzdga6otju number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index ed7cebcea..2b72d75a4 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -203,6 +203,55 @@ def check_balance(self) -> WaitableConditionType: collateral = self._collateral_amount_info(self.token_balance) self.context.logger.info(f"The safe has {native} xDAI and {collateral}.") return True + + def _calculate_kelly_bet_amount(self, x, y, p, c, b) -> int: + """Calculate the Kelly bet amount.""" + if b == 0 or x**2 == y**2: + self.context.logger.error( + "Could not calculate Kelly bet amount. Either bankroll is 0 or pool token amount is distributed as x^2 - y^2 = 0:\n" + f"Bankroll: {b}\n" + f"Pool token amounts: {x}, {y}" + ) + return None + # TODO: Add Fee variable + kelly_bet_amount = (-4*x**2*y + b*y**2*p + 2*b*x*y*p + b*x**2*p - 2*b*y**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p - 2*b*x*y*p - b*x**2*p + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p - 4*b*x**2*y*p + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) + self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") + return int(kelly_bet_amount) + + def get_bet_amount( + self, + bankroll: int, + strategy: str, + win_probability: float, + confidence: float, + selected_type_tokens_in_pool: int, + other_tokens_in_pool: int, + bet_fee: int, + ) -> int: + """Get the bet amount given a specified trading strategy.""" + + if strategy == "bet_amount_per_conf_threshold": + self.context.logger.info(f"Used trading strategy: {strategy}") + threshold = round(confidence, 1) + bet_amount = self.bet_amount_per_threshold[threshold] + self.context.logger.info(f"Bet amount: {bet_amount}") + net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) + self.context.logger.info(f"Net bet amount: {net_bet_amount}") + return net_bet_amount + + elif strategy == "kelly_criterion": + self.context.logger.info(f"Used trading strategy: {strategy}") + bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade + kelly_bet_amount = self._calculate_kelly_bet_amount( + selected_type_tokens_in_pool, other_tokens_in_pool, win_probability, confidence, bankroll + ) + if kelly_bet_amount != None: + self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") + self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") + return kelly_bet_amount + + else: + raise ValueError(f"Invalid trading strategy: {strategy}") def default_error( self, contract_id: str, contract_callable: str, response_msg: ContractApiMessage diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index e1234cd0e..2e926e3f6 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -381,7 +381,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide # Testing and printing kelly bet amount self.context.logger.info("Start kelly bet amount calculation") - bet_amount = self.params.get_bet_amount( + bet_amount = self.get_bet_amount( bankroll, "kelly_criterion", win_probability, @@ -393,7 +393,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide # Actual bet amount self.context.logger.info("Start bet amount per conf threshold calculation") - bet_amount = self.params.get_bet_amount( + bet_amount = self.get_bet_amount( bankroll, self.params.trading_strategy, win_probability, diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index ad1450cb8..62a3ff18a 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -42,10 +42,6 @@ ) from packages.valory.skills.decision_maker_abci.rounds import DecisionMakerAbciApp from packages.valory.skills.market_manager_abci.models import MarketManagerParams -from packages.valory.skills.decision_maker_abci.behaviours.base import ( - DecisionMakerBaseBehaviour, - remove_fraction_wei, -) RE_CONTENT_IN_BRACKETS = r"\{([^}]*)\}" REQUIRED_BET_TEMPLATE_KEYS = {"yes", "no", "question"} @@ -164,59 +160,10 @@ def slippage(self, slippage: float) -> None: ) self._slippage = slippage - def _get_kelly_bet_amount(self, x, y, p, c, b) -> int: - """Calculate the Kelly bet amount.""" - if b == 0 or x**2 == y**2: - self.context.logger.error( - "Could not calculate Kelly bet amount. Either bankroll is 0 or pool token amount is distributed as x^2 - y^2 = 0:\n" - f"Bankroll: {b}\n" - f"Pool token amounts: {x}, {y}" - ) - return None - # TODO: Add Fee variable - kelly_bet_amount = (-4*x**2*y + b*y**2*p + 2*b*x*y*p + b*x**2*p - 2*b*y**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p - 2*b*x*y*p - b*x**2*p + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p - 4*b*x**2*y*p + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) - self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") - return int(kelly_bet_amount) - # def get_bet_amount(self, confidence: float) -> int: # """Get the bet amount given a prediction's confidence.""" # threshold = round(confidence, 1) # return self.bet_amount_per_threshold[threshold] - - def get_bet_amount( - self, - bankroll: int, - strategy: str, - win_probability: float, - confidence: float, - selected_type_tokens_in_pool: int, - other_tokens_in_pool: int, - bet_fee: int, - ) -> int: - """Get the bet amount given a specified trading strategy.""" - - if strategy == "bet_amount_per_conf_threshold": - self.context.logger.info(f"Used trading strategy: {strategy}") - threshold = round(confidence, 1) - bet_amount = self.bet_amount_per_threshold[threshold] - self.context.logger.info(f"Bet amount: {bet_amount}") - net_bet_amount = remove_fraction_wei(bet_amount, DecisionMakerBaseBehaviour.wei_to_native(bet_fee)) - self.context.logger.info(f"Net bet amount: {net_bet_amount}") - return net_bet_amount - - elif strategy == "kelly_criterion": - self.context.logger.info(f"Used trading strategy: {strategy}") - bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade - kelly_bet_amount = self._get_kelly_bet_amount( - selected_type_tokens_in_pool, other_tokens_in_pool, win_probability, confidence, bankroll - ) - if kelly_bet_amount != None: - self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") - self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") - return kelly_bet_amount - - else: - raise ValueError(f"Invalid trading strategy: {strategy}") def get_policy_store_path(self, kwargs: Dict) -> Path: """Get the path of the policy store.""" diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 49e967ef8..11799b73a 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,10 +12,10 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeidny4y4w4jbjbp5d5qivur6jm37fnuik4mqzchzshiuvpozxe7vwy + behaviours/base.py: bafybeib6cwkdeeqspm6z3rzaanyozaq6iwa5z3mxqgmjn6fhfmjrrd2w2i behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeiahl7ad6ojybm6zwn4gckonxi6cknux5q7tgm7sfdopqzjaycnoqu + behaviours/decision_receive.py: bafybeihvvoqrkfy4p2svvajphlj2jzpn2k4nldyzoktn4oa6oxwic5y4jq behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga @@ -25,7 +25,7 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeic6nuw5jpoktstbeapzfch43twkmvaha6bntsaoc4qgzmcxgbifzi + models.py: bafybeihjtrjh2rtnar2ozeys5o4r2dodyiqg7mxhvxq6ozgv5rykg3i52e payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 27472e4bc..33ffe3d44 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidk7lohqazdqpskrvvu2dxxbh2zc2exn56ig3usl6fmgk23oy2roi -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieokhhlopr2cj77cf3rbbxt2nhffegzifhcs4l7fictrkoq3dp77q +- valory/decision_maker_abci:0.1.0:bafybeibdcuzoi56bngu7gpialvwfpyl65to7clxpbztsi2qihs4qtyrjcq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeia6v7ibv4na2iy5g4ab4d3pddry772rbe5k7xbafakcsdimfyolny behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index d5c6966dd..3e69153d8 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeidk7lohqazdqpskrvvu2dxxbh2zc2exn56ig3usl6fmgk23oy2roi +- valory/decision_maker_abci:0.1.0:bafybeibdcuzoi56bngu7gpialvwfpyl65to7clxpbztsi2qihs4qtyrjcq behaviours: main: args: {} From b390eac0203807fc2aac1d9b5cfe9f6d0dc6b829 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 19 Oct 2023 18:48:53 +0200 Subject: [PATCH 26/79] WIP: Implement betting strategy 'kelly criterion' --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/decision_receive.py | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 2acb8af28..4fe9b0977 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeibdcuzoi56bngu7gpialvwfpyl65to7clxpbztsi2qihs4qtyrjcq", - "skill/valory/trader_abci/0.1.0": "bafybeidbsguskoo37hhfgvyyd2natr5c4m4hiefsmk5m2erxh3fn2t46ai", + "skill/valory/decision_maker_abci/0.1.0": "bafybeigxd54zjgg2t6w6a653ot52xfdw4ogv5v4xuuhs4nghsk3hssxlyq", + "skill/valory/trader_abci/0.1.0": "bafybeiezckjtqia7spz424yecoih4f5pifsfqm26ebgha6wsaxkbe6knq4", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeibv6cgnro4mdircbmmvhps2s3nbnrrry752gi3aukwgfzdga6otju", - "service/valory/trader/0.1.0": "bafybeievs5jkfdjhols43beluyyz5i32pftx6ixqsme4suyucaihztfk4e", + "agent/valory/trader/0.1.0": "bafybeifcwke7zt7lmmof7frwr624pycxonzmgnsq3aorzktfksrveftic4", + "service/valory/trader/0.1.0": "bafybeie526gjh22nhsb3rmv3y3irqv75miuee2t476yvvw7bhelscmao3q", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeia6v7ibv4na2iy5g4ab4d3pddry772rbe5k7xbafakcsdimfyolny", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicgfbwyh4sx4njtic6axk7gi6ggejsjmdafl3qn3ofsg46mnlceiu", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 348eb6822..c7b90448b 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeia6v7ibv4na2iy5g4ab4d3pddry772rbe5k7xbafakcsdimfyolny +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicgfbwyh4sx4njtic6axk7gi6ggejsjmdafl3qn3ofsg46mnlceiu - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibdcuzoi56bngu7gpialvwfpyl65to7clxpbztsi2qihs4qtyrjcq -- valory/trader_abci:0.1.0:bafybeidbsguskoo37hhfgvyyd2natr5c4m4hiefsmk5m2erxh3fn2t46ai +- valory/decision_maker_abci:0.1.0:bafybeigxd54zjgg2t6w6a653ot52xfdw4ogv5v4xuuhs4nghsk3hssxlyq +- valory/trader_abci:0.1.0:bafybeiezckjtqia7spz424yecoih4f5pifsfqm26ebgha6wsaxkbe6knq4 default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 55f853309..883aea7fc 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeibv6cgnro4mdircbmmvhps2s3nbnrrry752gi3aukwgfzdga6otju +agent: valory/trader:0.1.0:bafybeifcwke7zt7lmmof7frwr624pycxonzmgnsq3aorzktfksrveftic4 number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 2e926e3f6..3d6c44ef5 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -247,7 +247,7 @@ def _get_decision( return self.mech_response.result.vote, self.mech_response.result.odds, self.mech_response.result.win_probability, self.mech_response.result.confidence - def _get_bet_sample_info(bet, vote) -> Tuple[int, int]: + def _get_bet_sample_info(bet, vote) -> Tuple[int, int, int]: token_amounts = bet.outcomeTokenAmounts if token_amounts is None: return None, None, None diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 11799b73a..e9542ee1d 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeib6cwkdeeqspm6z3rzaanyozaq6iwa5z3mxqgmjn6fhfmjrrd2w2i behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeihvvoqrkfy4p2svvajphlj2jzpn2k4nldyzoktn4oa6oxwic5y4jq + behaviours/decision_receive.py: bafybeigvwzwi226rfnkdt6s6oti7zv6njnyjnplx4fdbgxxhy3x5fse3fe behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 33ffe3d44..eef10c700 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibdcuzoi56bngu7gpialvwfpyl65to7clxpbztsi2qihs4qtyrjcq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeia6v7ibv4na2iy5g4ab4d3pddry772rbe5k7xbafakcsdimfyolny +- valory/decision_maker_abci:0.1.0:bafybeigxd54zjgg2t6w6a653ot52xfdw4ogv5v4xuuhs4nghsk3hssxlyq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicgfbwyh4sx4njtic6axk7gi6ggejsjmdafl3qn3ofsg46mnlceiu behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 3e69153d8..60b51d1a5 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeibdcuzoi56bngu7gpialvwfpyl65to7clxpbztsi2qihs4qtyrjcq +- valory/decision_maker_abci:0.1.0:bafybeigxd54zjgg2t6w6a653ot52xfdw4ogv5v4xuuhs4nghsk3hssxlyq behaviours: main: args: {} From e661e59504bec19987582df4d50bb0f2d7e83029 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 07:24:52 +0200 Subject: [PATCH 27/79] WIP: Implement betting strategy 'kelly criterion' --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/decision_receive.py | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 4fe9b0977..2cba2df57 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeigxd54zjgg2t6w6a653ot52xfdw4ogv5v4xuuhs4nghsk3hssxlyq", - "skill/valory/trader_abci/0.1.0": "bafybeiezckjtqia7spz424yecoih4f5pifsfqm26ebgha6wsaxkbe6knq4", + "skill/valory/decision_maker_abci/0.1.0": "bafybeiebdzxkpyzvv354vprxeq7mhu5rwokw6fqwicpafkjxqi47kxbove", + "skill/valory/trader_abci/0.1.0": "bafybeib3n74pv3p5fnyxdpfvr6kz7qhbmgjlvrlqpbkolreyrj7sandqte", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeifcwke7zt7lmmof7frwr624pycxonzmgnsq3aorzktfksrveftic4", - "service/valory/trader/0.1.0": "bafybeie526gjh22nhsb3rmv3y3irqv75miuee2t476yvvw7bhelscmao3q", + "agent/valory/trader/0.1.0": "bafybeifdrhzqqbmqkvifkqh3s5wvsycrwgduf2zsel5nnjem3olshe2w6m", + "service/valory/trader/0.1.0": "bafybeigursqz7jvfpcbr2k5ero55wjlgsad4rzr7mjx7w3op6ingbceuyq", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicgfbwyh4sx4njtic6axk7gi6ggejsjmdafl3qn3ofsg46mnlceiu", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiexfpuysxu7aeeglm4h44e66hfwu4cqmyspauaujut5dbopwjkgte", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index c7b90448b..ccf3a3362 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicgfbwyh4sx4njtic6axk7gi6ggejsjmdafl3qn3ofsg46mnlceiu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiexfpuysxu7aeeglm4h44e66hfwu4cqmyspauaujut5dbopwjkgte - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigxd54zjgg2t6w6a653ot52xfdw4ogv5v4xuuhs4nghsk3hssxlyq -- valory/trader_abci:0.1.0:bafybeiezckjtqia7spz424yecoih4f5pifsfqm26ebgha6wsaxkbe6knq4 +- valory/decision_maker_abci:0.1.0:bafybeiebdzxkpyzvv354vprxeq7mhu5rwokw6fqwicpafkjxqi47kxbove +- valory/trader_abci:0.1.0:bafybeib3n74pv3p5fnyxdpfvr6kz7qhbmgjlvrlqpbkolreyrj7sandqte default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 883aea7fc..c80141d73 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeifcwke7zt7lmmof7frwr624pycxonzmgnsq3aorzktfksrveftic4 +agent: valory/trader:0.1.0:bafybeifdrhzqqbmqkvifkqh3s5wvsycrwgduf2zsel5nnjem3olshe2w6m number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 3d6c44ef5..6cb1030b8 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -247,7 +247,7 @@ def _get_decision( return self.mech_response.result.vote, self.mech_response.result.odds, self.mech_response.result.win_probability, self.mech_response.result.confidence - def _get_bet_sample_info(bet, vote) -> Tuple[int, int, int]: + def _get_bet_sample_info(self, bet, vote) -> Tuple[int, int, int]: token_amounts = bet.outcomeTokenAmounts if token_amounts is None: return None, None, None diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index e9542ee1d..2dfe876aa 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeib6cwkdeeqspm6z3rzaanyozaq6iwa5z3mxqgmjn6fhfmjrrd2w2i behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeigvwzwi226rfnkdt6s6oti7zv6njnyjnplx4fdbgxxhy3x5fse3fe + behaviours/decision_receive.py: bafybeia5ykn4tfr6zjxzzy5ym2o4w45seisnkr7pamgl6ludcoobtbws6a behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index eef10c700..64870539d 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigxd54zjgg2t6w6a653ot52xfdw4ogv5v4xuuhs4nghsk3hssxlyq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicgfbwyh4sx4njtic6axk7gi6ggejsjmdafl3qn3ofsg46mnlceiu +- valory/decision_maker_abci:0.1.0:bafybeiebdzxkpyzvv354vprxeq7mhu5rwokw6fqwicpafkjxqi47kxbove +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiexfpuysxu7aeeglm4h44e66hfwu4cqmyspauaujut5dbopwjkgte behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 60b51d1a5..64c6ca8e4 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeigxd54zjgg2t6w6a653ot52xfdw4ogv5v4xuuhs4nghsk3hssxlyq +- valory/decision_maker_abci:0.1.0:bafybeiebdzxkpyzvv354vprxeq7mhu5rwokw6fqwicpafkjxqi47kxbove behaviours: main: args: {} From 3ef8dbb8e6a9cd58fa72a9e54164198901ca862f Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 07:39:25 +0200 Subject: [PATCH 28/79] WIP: Implement betting strategy 'kelly criterion' --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/base.py | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 2cba2df57..9fd5f5bc8 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeiebdzxkpyzvv354vprxeq7mhu5rwokw6fqwicpafkjxqi47kxbove", - "skill/valory/trader_abci/0.1.0": "bafybeib3n74pv3p5fnyxdpfvr6kz7qhbmgjlvrlqpbkolreyrj7sandqte", + "skill/valory/decision_maker_abci/0.1.0": "bafybeihrfc6s7uw6ralmixmaic3ed47zzkcyuehvxvmo2276kqfcvbsj7a", + "skill/valory/trader_abci/0.1.0": "bafybeifct7hiltgsfbfuyuvxos34ekkqbzgxgiwou54bq52y2z3gowoyre", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeifdrhzqqbmqkvifkqh3s5wvsycrwgduf2zsel5nnjem3olshe2w6m", - "service/valory/trader/0.1.0": "bafybeigursqz7jvfpcbr2k5ero55wjlgsad4rzr7mjx7w3op6ingbceuyq", + "agent/valory/trader/0.1.0": "bafybeiaycstshq45acrzavwca4vubcpafjqb6mip65insnrjqbh6qjteym", + "service/valory/trader/0.1.0": "bafybeietb7rfj6wblrmw3dv3qzs5kidd2tcw57bu25jjcgiqtxg4ipw53q", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiexfpuysxu7aeeglm4h44e66hfwu4cqmyspauaujut5dbopwjkgte", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeidzmyrhp75ej3tpty4bflizslis62tpykk7moewtpre3z6fndillm", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index ccf3a3362..43d3503a3 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiexfpuysxu7aeeglm4h44e66hfwu4cqmyspauaujut5dbopwjkgte +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidzmyrhp75ej3tpty4bflizslis62tpykk7moewtpre3z6fndillm - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiebdzxkpyzvv354vprxeq7mhu5rwokw6fqwicpafkjxqi47kxbove -- valory/trader_abci:0.1.0:bafybeib3n74pv3p5fnyxdpfvr6kz7qhbmgjlvrlqpbkolreyrj7sandqte +- valory/decision_maker_abci:0.1.0:bafybeihrfc6s7uw6ralmixmaic3ed47zzkcyuehvxvmo2276kqfcvbsj7a +- valory/trader_abci:0.1.0:bafybeifct7hiltgsfbfuyuvxos34ekkqbzgxgiwou54bq52y2z3gowoyre default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index c80141d73..f09081d0f 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeifdrhzqqbmqkvifkqh3s5wvsycrwgduf2zsel5nnjem3olshe2w6m +agent: valory/trader:0.1.0:bafybeiaycstshq45acrzavwca4vubcpafjqb6mip65insnrjqbh6qjteym number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 2b72d75a4..320d7b699 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -233,7 +233,7 @@ def get_bet_amount( if strategy == "bet_amount_per_conf_threshold": self.context.logger.info(f"Used trading strategy: {strategy}") threshold = round(confidence, 1) - bet_amount = self.bet_amount_per_threshold[threshold] + bet_amount = self.params.bet_amount_per_threshold[threshold] self.context.logger.info(f"Bet amount: {bet_amount}") net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) self.context.logger.info(f"Net bet amount: {net_bet_amount}") diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 2dfe876aa..a4164b8aa 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,7 +12,7 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeib6cwkdeeqspm6z3rzaanyozaq6iwa5z3mxqgmjn6fhfmjrrd2w2i + behaviours/base.py: bafybeicrox652guzlblsggh633xvj2gq2yc22phogz6aj6lkhrdsbccmqy behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm behaviours/decision_receive.py: bafybeia5ykn4tfr6zjxzzy5ym2o4w45seisnkr7pamgl6ludcoobtbws6a diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 64870539d..f0b87543e 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiebdzxkpyzvv354vprxeq7mhu5rwokw6fqwicpafkjxqi47kxbove -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiexfpuysxu7aeeglm4h44e66hfwu4cqmyspauaujut5dbopwjkgte +- valory/decision_maker_abci:0.1.0:bafybeihrfc6s7uw6ralmixmaic3ed47zzkcyuehvxvmo2276kqfcvbsj7a +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidzmyrhp75ej3tpty4bflizslis62tpykk7moewtpre3z6fndillm behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 64c6ca8e4..35450d3cb 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeiebdzxkpyzvv354vprxeq7mhu5rwokw6fqwicpafkjxqi47kxbove +- valory/decision_maker_abci:0.1.0:bafybeihrfc6s7uw6ralmixmaic3ed47zzkcyuehvxvmo2276kqfcvbsj7a behaviours: main: args: {} From 16f5aae672a8e18d0fd37ae79e4a9d0752348652 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 08:02:27 +0200 Subject: [PATCH 29/79] feat: Add confidence to kelly calculation --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/base.py | 2 +- .../decision_maker_abci/behaviours/decision_receive.py | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 16 insertions(+), 16 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 9fd5f5bc8..9ba7811b5 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeihrfc6s7uw6ralmixmaic3ed47zzkcyuehvxvmo2276kqfcvbsj7a", - "skill/valory/trader_abci/0.1.0": "bafybeifct7hiltgsfbfuyuvxos34ekkqbzgxgiwou54bq52y2z3gowoyre", + "skill/valory/decision_maker_abci/0.1.0": "bafybeie3ylckkbs6zav2dgqn5xrvljxnyvtasllvklhzzq2vuaegfc5u5u", + "skill/valory/trader_abci/0.1.0": "bafybeih72nyalhi4f3safyrx5grbvog7go6cqhnzwcmqzefgwbnfhzsehm", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeiaycstshq45acrzavwca4vubcpafjqb6mip65insnrjqbh6qjteym", - "service/valory/trader/0.1.0": "bafybeietb7rfj6wblrmw3dv3qzs5kidd2tcw57bu25jjcgiqtxg4ipw53q", + "agent/valory/trader/0.1.0": "bafybeia4nsqzjqlnwjlfehs7agksob5ovrm7vk7o2wzzb6wlhmodgkvgoi", + "service/valory/trader/0.1.0": "bafybeia23bg2cmglrzhkazdu3mrrrmlqhrg7ejcpnaj6uf3erviihb3vne", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeidzmyrhp75ej3tpty4bflizslis62tpykk7moewtpre3z6fndillm", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiasqsbffmyxdt5oxnxhtpt6ksj7yobxaq3upzvo52bcnfr5mygitu", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 43d3503a3..e175d4960 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidzmyrhp75ej3tpty4bflizslis62tpykk7moewtpre3z6fndillm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiasqsbffmyxdt5oxnxhtpt6ksj7yobxaq3upzvo52bcnfr5mygitu - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeihrfc6s7uw6ralmixmaic3ed47zzkcyuehvxvmo2276kqfcvbsj7a -- valory/trader_abci:0.1.0:bafybeifct7hiltgsfbfuyuvxos34ekkqbzgxgiwou54bq52y2z3gowoyre +- valory/decision_maker_abci:0.1.0:bafybeie3ylckkbs6zav2dgqn5xrvljxnyvtasllvklhzzq2vuaegfc5u5u +- valory/trader_abci:0.1.0:bafybeih72nyalhi4f3safyrx5grbvog7go6cqhnzwcmqzefgwbnfhzsehm default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index f09081d0f..736f680c9 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiaycstshq45acrzavwca4vubcpafjqb6mip65insnrjqbh6qjteym +agent: valory/trader:0.1.0:bafybeia4nsqzjqlnwjlfehs7agksob5ovrm7vk7o2wzzb6wlhmodgkvgoi number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 320d7b699..61605d29d 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -214,7 +214,7 @@ def _calculate_kelly_bet_amount(self, x, y, p, c, b) -> int: ) return None # TODO: Add Fee variable - kelly_bet_amount = (-4*x**2*y + b*y**2*p + 2*b*x*y*p + b*x**2*p - 2*b*y**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p - 2*b*x*y*p - b*x**2*p + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p - 4*b*x**2*y*p + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) + kelly_bet_amount = (-4*x**2*y + b*y**2*p*c + 2*b*x*y*p*c + b*x**2*p*c - 2*b*y**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p*c - 2*b*x*y*p*c - b*x**2*p*c + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p*c - 4*b*x**2*y*p*c + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") return int(kelly_bet_amount) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 6cb1030b8..be99ecaa4 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -429,7 +429,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide self.context.logger.info(f"Available in: {available_in}") shares_out_of = f"{shares_out} / {available_in}" self.context.logger.info(f"Shares out of: {shares_out_of}") - potential_net_profit = num_shares - bet_amount - bet_threshold + potential_net_profit = num_shares - bet_amount - self.mech_price - bet_threshold is_profitable = potential_net_profit >= 0 if num_shares > available_shares * SLIPPAGE: diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index a4164b8aa..91a6e6e42 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,10 +12,10 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeicrox652guzlblsggh633xvj2gq2yc22phogz6aj6lkhrdsbccmqy + behaviours/base.py: bafybeicmyj3tocd5xhcblrl7r3b3wh4berykicyzfbg4bbekzozihpzvta behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeia5ykn4tfr6zjxzzy5ym2o4w45seisnkr7pamgl6ludcoobtbws6a + behaviours/decision_receive.py: bafybeiep4wtrht3tnntdkpblrujnnprjutwglailgl2x3ndmpeefind5nu behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index f0b87543e..a89c92c75 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeihrfc6s7uw6ralmixmaic3ed47zzkcyuehvxvmo2276kqfcvbsj7a -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidzmyrhp75ej3tpty4bflizslis62tpykk7moewtpre3z6fndillm +- valory/decision_maker_abci:0.1.0:bafybeie3ylckkbs6zav2dgqn5xrvljxnyvtasllvklhzzq2vuaegfc5u5u +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiasqsbffmyxdt5oxnxhtpt6ksj7yobxaq3upzvo52bcnfr5mygitu behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 35450d3cb..436322eef 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeihrfc6s7uw6ralmixmaic3ed47zzkcyuehvxvmo2276kqfcvbsj7a +- valory/decision_maker_abci:0.1.0:bafybeie3ylckkbs6zav2dgqn5xrvljxnyvtasllvklhzzq2vuaegfc5u5u behaviours: main: args: {} From e00dfb6663205f2f87c94bc7ccb879e86d370f09 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 11:02:04 +0200 Subject: [PATCH 30/79] feat: Add kelly fraction parameter --- packages/packages.json | 10 ++++---- packages/valory/agents/trader/aea-config.yaml | 7 +++--- packages/valory/services/trader/service.yaml | 3 ++- .../decision_maker_abci/behaviours/base.py | 25 +++++++++++++------ .../behaviours/decision_receive.py | 5 ++-- .../skills/decision_maker_abci/models.py | 2 ++ .../skills/decision_maker_abci/skill.yaml | 7 +++--- packages/valory/skills/trader_abci/skill.yaml | 4 +-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 9 files changed, 41 insertions(+), 24 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 9ba7811b5..1cc8b82a9 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeie3ylckkbs6zav2dgqn5xrvljxnyvtasllvklhzzq2vuaegfc5u5u", - "skill/valory/trader_abci/0.1.0": "bafybeih72nyalhi4f3safyrx5grbvog7go6cqhnzwcmqzefgwbnfhzsehm", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454", + "skill/valory/trader_abci/0.1.0": "bafybeigitw2zk7icgnkl746h4fr6gqfxy4c3mqdz3h2wjd5fuzx27uzigq", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeia4nsqzjqlnwjlfehs7agksob5ovrm7vk7o2wzzb6wlhmodgkvgoi", - "service/valory/trader/0.1.0": "bafybeia23bg2cmglrzhkazdu3mrrrmlqhrg7ejcpnaj6uf3erviihb3vne", + "agent/valory/trader/0.1.0": "bafybeihkrrsuvkfuj2mzmftas5x7ishixgwgkw4vmeof3g2ugpw3npbecq", + "service/valory/trader/0.1.0": "bafybeiftm2wfmid7ug67c36vmbkgja2q2bws5bez3povllr7cba4wo4lua", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiasqsbffmyxdt5oxnxhtpt6ksj7yobxaq3upzvo52bcnfr5mygitu", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeign7jvjsis5toyivo2c2w7m4qpa5v5jngcheswqozlno6h72m7zda", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index e175d4960..0d5430deb 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiasqsbffmyxdt5oxnxhtpt6ksj7yobxaq3upzvo52bcnfr5mygitu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeign7jvjsis5toyivo2c2w7m4qpa5v5jngcheswqozlno6h72m7zda - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeie3ylckkbs6zav2dgqn5xrvljxnyvtasllvklhzzq2vuaegfc5u5u -- valory/trader_abci:0.1.0:bafybeih72nyalhi4f3safyrx5grbvog7go6cqhnzwcmqzefgwbnfhzsehm +- valory/decision_maker_abci:0.1.0:bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454 +- valory/trader_abci:0.1.0:bafybeigitw2zk7icgnkl746h4fr6gqfxy4c3mqdz3h2wjd5fuzx27uzigq default_ledger: ethereum required_ledgers: - ethereum @@ -163,6 +163,7 @@ models: abt_error_mult: ${int:5} mech_agent_address: ${str:0xff82123dfb52ab75c417195c5fdb87630145ae81} trading_strategy: ${str:bet_amount_per_conf_threshold} + bet_kelly_fraction: ${BET_KELLY_FRACTION:float:1.0} bet_amount_per_threshold: 0.0: ${int:0} 0.1: ${int:0} diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 736f680c9..05394bcb9 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeia4nsqzjqlnwjlfehs7agksob5ovrm7vk7o2wzzb6wlhmodgkvgoi +agent: valory/trader:0.1.0:bafybeihkrrsuvkfuj2mzmftas5x7ishixgwgkw4vmeof3g2ugpw3npbecq number_of_agents: 4 deployment: {} --- @@ -79,6 +79,7 @@ type: skill abt_error_mult: ${ABT_ERROR_MULT:int:5} mech_agent_address: ${MECH_AGENT_ADDRESS:str:0xff82123dfb52ab75c417195c5fdb87630145ae81} trading_strategy: ${TRADING_STRATEGY:str:bet_amount_per_conf_threshold} + bet_kelly_fraction: ${BET_KELLY_FRACTION:float:1.0} bet_amount_per_threshold: &id004 0.0: ${BET_AMOUNT_PER_THRESHOLD_000:int:0} 0.1: ${BET_AMOUNT_PER_THRESHOLD_010:int:0} diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 61605d29d..f629e9694 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -204,17 +204,17 @@ def check_balance(self) -> WaitableConditionType: self.context.logger.info(f"The safe has {native} xDAI and {collateral}.") return True - def _calculate_kelly_bet_amount(self, x, y, p, c, b) -> int: + def _calculate_kelly_bet_amount(self, x, y, p, c, b, f) -> int: """Calculate the Kelly bet amount.""" - if b == 0 or x**2 == y**2: + if b == 0 or x**2*f == y**2*f: self.context.logger.error( - "Could not calculate Kelly bet amount. Either bankroll is 0 or pool token amount is distributed as x^2 - y^2 = 0:\n" + "Could not calculate Kelly bet amount. Either bankroll is 0 or pool token amount is distributed as x^2*f - y^2*f = 0:\n" f"Bankroll: {b}\n" f"Pool token amounts: {x}, {y}" + f"Fee, fee fraction f: {1-f}, {f}" ) return None - # TODO: Add Fee variable - kelly_bet_amount = (-4*x**2*y + b*y**2*p*c + 2*b*x*y*p*c + b*x**2*p*c - 2*b*y**2 - 2*b*x*y + ((4*x**2*y - b*y**2*p*c - 2*b*x*y*p*c - b*x**2*p*c + 2*b*y**2 + 2*b*x*y)**2 - (4*(x**2 - y**2) * (-4*b*x*y**2*p*c - 4*b*x**2*y*p*c + 4*b*x*y**2)))**(1/2))/(2*(x**2 - y**2)) + kelly_bet_amount = (-4*x**2*y + b*y**2*p*c*f + 2*b*x*y*p*c*f + b*x**2*p*c*f - 2*b*y**2*f - 2*b*x*y*f + ((4*x**2*y - b*y**2*p*c*f - 2*b*x*y*p*c*f - b*x**2*p*c*f + 2*b*y**2*f + 2*b*x*y*f)**2 - (4*(x**2*f - y**2*f) * (-4*b*x*y**2*p*c - 4*b*x**2*y*p*c + 4*b*x*y**2)))**(1/2))/(2*(x**2*f - y**2*f)) self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") return int(kelly_bet_amount) @@ -240,15 +240,26 @@ def get_bet_amount( return net_bet_amount elif strategy == "kelly_criterion": + self.context.logger.info(f"Used trading strategy: {strategy}") bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade + fee_fraction = 1 - self.wei_to_native(bet_fee) + self.context.logger.info(f"Fee fraction: {fee_fraction}") kelly_bet_amount = self._calculate_kelly_bet_amount( - selected_type_tokens_in_pool, other_tokens_in_pool, win_probability, confidence, bankroll + selected_type_tokens_in_pool, + other_tokens_in_pool, + win_probability, + confidence, + bankroll, + fee_fraction, ) + if kelly_bet_amount != None: self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") - return kelly_bet_amount + adj_kelly_bet_amount = kelly_bet_amount * self.params.bet_kelly_fraction + self.context.logger.info(f"Adjusted Kelly bet amount with bet_kelly_fraction factor: {kelly_bet_amount/(10**18)} xDAI") + return adj_kelly_bet_amount else: raise ValueError(f"Invalid trading strategy: {strategy}") diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index be99ecaa4..b4fdaabf9 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -372,6 +372,7 @@ def _check_balance(self) -> WaitableConditionType: def _is_profitable(self, vote: int, odds: float, win_probability: float, confidence: float) -> bool: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet + self.context.logger.info(f"Bet: {bet}") yield from self._check_balance() bankroll = self.wallet_balance + self.token_balance self.context.logger.info(f"Wallet balance: {self.wallet_balance}") @@ -380,7 +381,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee = self._get_bet_sample_info(bet, vote) # Testing and printing kelly bet amount - self.context.logger.info("Start kelly bet amount calculation") + self.context.logger.info("\nStart kelly bet amount calculation") bet_amount = self.get_bet_amount( bankroll, "kelly_criterion", @@ -392,7 +393,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide ) # Actual bet amount - self.context.logger.info("Start bet amount per conf threshold calculation") + self.context.logger.info("\nStart bet amount per conf threshold calculation") bet_amount = self.get_bet_amount( bankroll, self.params.trading_strategy, diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 62a3ff18a..e033a053e 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -96,6 +96,8 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: self.mech_agent_address: str = self._ensure("mech_agent_address", kwargs, str) # the trading strategy to use for placing bets self.trading_strategy: str = self._ensure("trading_strategy", kwargs, str) + # the factor of calculated kelly bet to use for placing bets + self.bet_kelly_fraction: str = self._ensure("bet_kelly_fraction", kwargs, float) # this is a mapping from the confidence of a bet's choice to the amount we are willing to bet self.bet_amount_per_threshold: Dict[float, int] = self._ensure( "bet_amount_per_threshold", kwargs, Dict[float, int] diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 91a6e6e42..d5dca7d42 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,10 +12,10 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeicmyj3tocd5xhcblrl7r3b3wh4berykicyzfbg4bbekzozihpzvta + behaviours/base.py: bafybeihcctycussx3peq5o36spo7p7ahvgbkvmrqypm4xyucgsvml6552i behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeiep4wtrht3tnntdkpblrujnnprjutwglailgl2x3ndmpeefind5nu + behaviours/decision_receive.py: bafybeihfucag3bnhduwxaupmrrku3vuaztaw43spkfo2rp6csqnaunay7y behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga @@ -25,7 +25,7 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeihjtrjh2rtnar2ozeys5o4r2dodyiqg7mxhvxq6ozgv5rykg3i52e + models.py: bafybeibslcyggq67ooyh5jq57b6bx2qf2yawexy2xc2n73eei3bvvvg4um payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm @@ -162,6 +162,7 @@ models: use_termination: false mech_agent_address: '0xff82123dfb52ab75c417195c5fdb87630145ae81' trading_strategy: bet_amount_per_conf_threshold + bet_kelly_fraction: 1.0 bet_amount_per_threshold: 0.0: 0 0.1: 0 diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index a89c92c75..725da0945 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeie3ylckkbs6zav2dgqn5xrvljxnyvtasllvklhzzq2vuaegfc5u5u -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiasqsbffmyxdt5oxnxhtpt6ksj7yobxaq3upzvo52bcnfr5mygitu +- valory/decision_maker_abci:0.1.0:bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeign7jvjsis5toyivo2c2w7m4qpa5v5jngcheswqozlno6h72m7zda behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 436322eef..e804ce1c9 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeie3ylckkbs6zav2dgqn5xrvljxnyvtasllvklhzzq2vuaegfc5u5u +- valory/decision_maker_abci:0.1.0:bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454 behaviours: main: args: {} From 0d9f9e307b76534a6ba6ae3831874f850f6005ff Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 11:08:31 +0200 Subject: [PATCH 31/79] fix: Changed variable template --- packages/packages.json | 4 ++-- packages/valory/agents/trader/aea-config.yaml | 2 +- packages/valory/services/trader/service.yaml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 1cc8b82a9..7f10e5ec1 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -4,8 +4,8 @@ "skill/valory/decision_maker_abci/0.1.0": "bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454", "skill/valory/trader_abci/0.1.0": "bafybeigitw2zk7icgnkl746h4fr6gqfxy4c3mqdz3h2wjd5fuzx27uzigq", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeihkrrsuvkfuj2mzmftas5x7ishixgwgkw4vmeof3g2ugpw3npbecq", - "service/valory/trader/0.1.0": "bafybeiftm2wfmid7ug67c36vmbkgja2q2bws5bez3povllr7cba4wo4lua", + "agent/valory/trader/0.1.0": "bafybeigbkdwea3ltndswlpgge7msovuarb52mrp2jkl2h56wn2qfn2qe2y", + "service/valory/trader/0.1.0": "bafybeia7sk6dkjjhculhzlcmh72sauapov2mc5fniis5sz27gqvqybzn74", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeign7jvjsis5toyivo2c2w7m4qpa5v5jngcheswqozlno6h72m7zda", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 0d5430deb..73ff2685a 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -163,7 +163,7 @@ models: abt_error_mult: ${int:5} mech_agent_address: ${str:0xff82123dfb52ab75c417195c5fdb87630145ae81} trading_strategy: ${str:bet_amount_per_conf_threshold} - bet_kelly_fraction: ${BET_KELLY_FRACTION:float:1.0} + bet_kelly_fraction: ${float:1.0} bet_amount_per_threshold: 0.0: ${int:0} 0.1: ${int:0} diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 05394bcb9..9e8fcb627 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeihkrrsuvkfuj2mzmftas5x7ishixgwgkw4vmeof3g2ugpw3npbecq +agent: valory/trader:0.1.0:bafybeigbkdwea3ltndswlpgge7msovuarb52mrp2jkl2h56wn2qfn2qe2y number_of_agents: 4 deployment: {} --- From 42a630e044ececb04818d72865f2eef463afbed2 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 11:21:44 +0200 Subject: [PATCH 32/79] fix: Adjust bet kelly fraction datatype --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- packages/valory/skills/decision_maker_abci/models.py | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 7f10e5ec1..946c7d90e 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454", - "skill/valory/trader_abci/0.1.0": "bafybeigitw2zk7icgnkl746h4fr6gqfxy4c3mqdz3h2wjd5fuzx27uzigq", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu", + "skill/valory/trader_abci/0.1.0": "bafybeif2w2rdy2lu5og23iuan4tjvzs5yervmevgebr54f2r5ycauhxdr4", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeigbkdwea3ltndswlpgge7msovuarb52mrp2jkl2h56wn2qfn2qe2y", - "service/valory/trader/0.1.0": "bafybeia7sk6dkjjhculhzlcmh72sauapov2mc5fniis5sz27gqvqybzn74", + "agent/valory/trader/0.1.0": "bafybeigvo5fxlnko3t3obqmjrllgtiqte4sbvw4nesqr3lwab5ax4a2jru", + "service/valory/trader/0.1.0": "bafybeigksk2jv53hgwwggbi6kt2ve2gelzndwyen642sz5kbmgu3megu5a", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeign7jvjsis5toyivo2c2w7m4qpa5v5jngcheswqozlno6h72m7zda", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibizsj2axbbnp7ysdgo7eo2nhu5xlpzhanpckd4tnismfd5wcvyzm", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 73ff2685a..10074dd5b 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeign7jvjsis5toyivo2c2w7m4qpa5v5jngcheswqozlno6h72m7zda +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibizsj2axbbnp7ysdgo7eo2nhu5xlpzhanpckd4tnismfd5wcvyzm - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454 -- valory/trader_abci:0.1.0:bafybeigitw2zk7icgnkl746h4fr6gqfxy4c3mqdz3h2wjd5fuzx27uzigq +- valory/decision_maker_abci:0.1.0:bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu +- valory/trader_abci:0.1.0:bafybeif2w2rdy2lu5og23iuan4tjvzs5yervmevgebr54f2r5ycauhxdr4 default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 9e8fcb627..8aa360640 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeigbkdwea3ltndswlpgge7msovuarb52mrp2jkl2h56wn2qfn2qe2y +agent: valory/trader:0.1.0:bafybeigvo5fxlnko3t3obqmjrllgtiqte4sbvw4nesqr3lwab5ax4a2jru number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index e033a053e..169b31d6d 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -97,7 +97,7 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: # the trading strategy to use for placing bets self.trading_strategy: str = self._ensure("trading_strategy", kwargs, str) # the factor of calculated kelly bet to use for placing bets - self.bet_kelly_fraction: str = self._ensure("bet_kelly_fraction", kwargs, float) + self.bet_kelly_fraction: float = self._ensure("bet_kelly_fraction", kwargs, float) # this is a mapping from the confidence of a bet's choice to the amount we are willing to bet self.bet_amount_per_threshold: Dict[float, int] = self._ensure( "bet_amount_per_threshold", kwargs, Dict[float, int] diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index d5dca7d42..d81b57af1 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -25,7 +25,7 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeibslcyggq67ooyh5jq57b6bx2qf2yawexy2xc2n73eei3bvvvg4um + models.py: bafybeigbfqhm5ks3j7kpm6gedyymjn4azfijhymotmhf6bddazdu2jjlua payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 725da0945..7b71f4c07 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454 -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeign7jvjsis5toyivo2c2w7m4qpa5v5jngcheswqozlno6h72m7zda +- valory/decision_maker_abci:0.1.0:bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibizsj2axbbnp7ysdgo7eo2nhu5xlpzhanpckd4tnismfd5wcvyzm behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index e804ce1c9..7670be98a 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeidij2err3pehqus2xhcdftkp2i7jwxox5muank6v3sr7dofn3w454 +- valory/decision_maker_abci:0.1.0:bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu behaviours: main: args: {} From 7cf7bba853544b18f0362bae95f510808abc1e6d Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 11:33:20 +0200 Subject: [PATCH 33/79] fix: Add missing bet_kelly_fraction key in skill.yaml --- packages/packages.json | 6 +++--- packages/valory/agents/trader/aea-config.yaml | 2 +- packages/valory/services/trader/service.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 1 + 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 946c7d90e..a74188924 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -2,10 +2,10 @@ "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", "skill/valory/decision_maker_abci/0.1.0": "bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu", - "skill/valory/trader_abci/0.1.0": "bafybeif2w2rdy2lu5og23iuan4tjvzs5yervmevgebr54f2r5ycauhxdr4", + "skill/valory/trader_abci/0.1.0": "bafybeied6aazto4ffwaskeqizosemhwz6bvd7b3k6x3ywzyjlhwouwzphy", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeigvo5fxlnko3t3obqmjrllgtiqte4sbvw4nesqr3lwab5ax4a2jru", - "service/valory/trader/0.1.0": "bafybeigksk2jv53hgwwggbi6kt2ve2gelzndwyen642sz5kbmgu3megu5a", + "agent/valory/trader/0.1.0": "bafybeic3jiheur4bwpobwmdgaijgtyiwbz7demmekbo3tbroldg4wt32ku", + "service/valory/trader/0.1.0": "bafybeibetmiyypycggo5o2bqw6zjrjdwur3pv56soh3eesv6te5o5nfh4m", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibizsj2axbbnp7ysdgo7eo2nhu5xlpzhanpckd4tnismfd5wcvyzm", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 10074dd5b..bc8267409 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -44,7 +44,7 @@ skills: - valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibizsj2axbbnp7ysdgo7eo2nhu5xlpzhanpckd4tnismfd5wcvyzm - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m - valory/decision_maker_abci:0.1.0:bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu -- valory/trader_abci:0.1.0:bafybeif2w2rdy2lu5og23iuan4tjvzs5yervmevgebr54f2r5ycauhxdr4 +- valory/trader_abci:0.1.0:bafybeied6aazto4ffwaskeqizosemhwz6bvd7b3k6x3ywzyjlhwouwzphy default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 8aa360640..2660fbf94 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeigvo5fxlnko3t3obqmjrllgtiqte4sbvw4nesqr3lwab5ax4a2jru +agent: valory/trader:0.1.0:bafybeic3jiheur4bwpobwmdgaijgtyiwbz7demmekbo3tbroldg4wt32ku number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 7b71f4c07..2c5b99ef7 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -145,6 +145,7 @@ models: abt_error_mult: 5 mech_agent_address: '0xff82123dfb52ab75c417195c5fdb87630145ae81' trading_strategy: bet_amount_per_conf_threshold + bet_kelly_fraction: 1.0 bet_amount_per_threshold: 0.0: 0 0.1: 0 From 856c1074d3717ed7f65e4b13b991147cbd49e326 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 14:42:30 +0200 Subject: [PATCH 34/79] feat: Add max bet amount calculation as fallback for kelly bet amount --- packages/packages.json | 10 ++--- packages/valory/agents/trader/aea-config.yaml | 6 +-- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/base.py | 32 ++++++++++---- .../behaviours/decision_receive.py | 42 ++++++++++++++----- .../skills/decision_maker_abci/skill.yaml | 4 +- packages/valory/skills/trader_abci/skill.yaml | 4 +- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 71 insertions(+), 31 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index a74188924..d4a6c9750 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu", - "skill/valory/trader_abci/0.1.0": "bafybeied6aazto4ffwaskeqizosemhwz6bvd7b3k6x3ywzyjlhwouwzphy", + "skill/valory/decision_maker_abci/0.1.0": "bafybeiedzih42efbcrfatnabpohl6ir5ozgntqtao3unkreacv6vozzesm", + "skill/valory/trader_abci/0.1.0": "bafybeifobwnmclkd4wo5i4v2smf5mps67yrtd2npjg6rho4rcvfhs5smky", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeic3jiheur4bwpobwmdgaijgtyiwbz7demmekbo3tbroldg4wt32ku", - "service/valory/trader/0.1.0": "bafybeibetmiyypycggo5o2bqw6zjrjdwur3pv56soh3eesv6te5o5nfh4m", + "agent/valory/trader/0.1.0": "bafybeidhhojyrpmmkixaudtikfunjze4fmusxnt2spv6fu37wespz2rpzq", + "service/valory/trader/0.1.0": "bafybeialq7ekwtav6nv536e4lip72nkckjlnng4fwekkhmoutqgxdome5y", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibizsj2axbbnp7ysdgo7eo2nhu5xlpzhanpckd4tnismfd5wcvyzm", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeifcnlgmcmwcwcbkayily2uigx3bqvr4255zt3tkdtw6c4srucm2qu", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index bc8267409..a35f64ee3 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibizsj2axbbnp7ysdgo7eo2nhu5xlpzhanpckd4tnismfd5wcvyzm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifcnlgmcmwcwcbkayily2uigx3bqvr4255zt3tkdtw6c4srucm2qu - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu -- valory/trader_abci:0.1.0:bafybeied6aazto4ffwaskeqizosemhwz6bvd7b3k6x3ywzyjlhwouwzphy +- valory/decision_maker_abci:0.1.0:bafybeiedzih42efbcrfatnabpohl6ir5ozgntqtao3unkreacv6vozzesm +- valory/trader_abci:0.1.0:bafybeifobwnmclkd4wo5i4v2smf5mps67yrtd2npjg6rho4rcvfhs5smky default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 2660fbf94..0c4155d8f 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeic3jiheur4bwpobwmdgaijgtyiwbz7demmekbo3tbroldg4wt32ku +agent: valory/trader:0.1.0:bafybeidhhojyrpmmkixaudtikfunjze4fmusxnt2spv6fu37wespz2rpzq number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index f629e9694..c26e1cef7 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -217,6 +217,24 @@ def _calculate_kelly_bet_amount(self, x, y, p, c, b, f) -> int: kelly_bet_amount = (-4*x**2*y + b*y**2*p*c*f + 2*b*x*y*p*c*f + b*x**2*p*c*f - 2*b*y**2*f - 2*b*x*y*f + ((4*x**2*y - b*y**2*p*c*f - 2*b*x*y*p*c*f - b*x**2*p*c*f + 2*b*y**2*f + 2*b*x*y*f)**2 - (4*(x**2*f - y**2*f) * (-4*b*x*y**2*p*c - 4*b*x**2*y*p*c + 4*b*x*y**2)))**(1/2))/(2*(x**2*f - y**2*f)) self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") return int(kelly_bet_amount) + + def get_max_bet_amount(self, a, x, y, f) -> int: + """Get max bet amount based on available shares.""" + if x**2*f**2 + 2*x*y*f**2 + y**2*f**2 == 0: + self.context.logger.error( + "Could not recalculate. Either bankroll is 0 or pool token amount is distributed such as x**2*f**2 + 2*x*y*f**2 + y**2*f**2 == 0:\n" + f"Available tokens: {a}\n" + f"Pool token amounts: {x}, {y}\n" + f"Fee, fee fraction f: {1-f}, {f}" + ) + return None + else: + pre_root = -2*x**2 + a*x - 2*x*y + sqrt = 4*x**4 + 8*x**3*y + a**2*x**2 + 4*x**2*y**2 + 2*a**2*x*y + a**2*y**2 + numerator = y*(pre_root + (sqrt)**0.5 + a*y) + denominator = f*(x**2 + 2*x*y + y**2) + new_bet_amount = numerator/denominator + return int(new_bet_amount) def get_bet_amount( self, @@ -240,7 +258,6 @@ def get_bet_amount( return net_bet_amount elif strategy == "kelly_criterion": - self.context.logger.info(f"Used trading strategy: {strategy}") bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade fee_fraction = 1 - self.wei_to_native(bet_fee) @@ -253,14 +270,15 @@ def get_bet_amount( bankroll, fee_fraction, ) - - if kelly_bet_amount != None: + if kelly_bet_amount == None: + return 0 + else: self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") - adj_kelly_bet_amount = kelly_bet_amount * self.params.bet_kelly_fraction - self.context.logger.info(f"Adjusted Kelly bet amount with bet_kelly_fraction factor: {kelly_bet_amount/(10**18)} xDAI") - return adj_kelly_bet_amount - + self.context.logger.info(f"bet_kelly_fraction factor: {self.params.bet_kelly_fraction}") + adj_kelly_bet_amount = kelly_bet_amount * self.params.bet_kelly_fraction + self.context.logger.info(f"Adjusted Kelly bet amount with bet_kelly_fraction factor: {kelly_bet_amount/(10**18)} xDAI") + return adj_kelly_bet_amount else: raise ValueError(f"Invalid trading strategy: {strategy}") diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index b4fdaabf9..4cd244121 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -384,7 +384,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide self.context.logger.info("\nStart kelly bet amount calculation") bet_amount = self.get_bet_amount( bankroll, - "kelly_criterion", + self.params.trading_strategy, win_probability, confidence, selected_type_tokens_in_pool, @@ -392,11 +392,12 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide bet_fee, ) - # Actual bet amount + # Safety fallback to bet amount per conf threshold + # Only remove if you are sure that kelly bet amount is working as expected self.context.logger.info("\nStart bet amount per conf threshold calculation") bet_amount = self.get_bet_amount( bankroll, - self.params.trading_strategy, + "bet_amount_per_conf_threshold", win_probability, confidence, selected_type_tokens_in_pool, @@ -408,6 +409,34 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") num_shares, available_shares = self._calc_binary_shares(bet_amount, win_probability, confidence, vote) + if num_shares > available_shares * SLIPPAGE: + self.context.logger.warning( + "Kindly contemplate reducing your bet amount, as the pool's liquidity is low compared to your bet. " + "Consequently, this situation entails a higher level of risk as the obtained number of shares, " + "and therefore the potential net profit, will be lower than if the pool had higher liquidity!" + ) + if self.params.trading_strategy == "kelly_criterion": + self.context.logger.warning( + "Reducing kelly bet amount so the bought shares don't exceed available shares" + ) + prev_bet_amount = bet_amount + bet_amount = self.get_max_bet_amount( + available_shares, + selected_type_tokens_in_pool, + other_tokens_in_pool, + bet_fee, + ) + if bet_amount >= prev_bet_amount: + bet_amount = 0 + self.context.logger.warning( + "The new bet amount is >= the previous one. There might be a calculation error. \ + No bet will be placed." + ) + else: + self.context.logger.info( + f"New bet amount: {bet_amount/(10**18)}" + f"Betting {round(100*bet_amount/prev_bet_amount, 2)}% of the calculated kelly bet amount." + ) bet_threshold = self.params.bet_threshold self.context.logger.info(f"Bet threshold: {bet_threshold/(10**18)}") @@ -433,13 +462,6 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide potential_net_profit = num_shares - bet_amount - self.mech_price - bet_threshold is_profitable = potential_net_profit >= 0 - if num_shares > available_shares * SLIPPAGE: - self.context.logger.warning( - "Kindly contemplate reducing your bet amount, as the pool's liquidity is low compared to your bet. " - "Consequently, this situation entails a higher level of risk as the obtained number of shares, " - "and therefore the potential net profit, will be lower than if the pool had higher liquidity!" - ) - self.context.logger.info( f"The current liquidity of the market is {bet.scaledLiquidityMeasure} xDAI. " f"The potential net profit is {self.wei_to_native(potential_net_profit)} xDAI " diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index d81b57af1..af8da93f4 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,10 +12,10 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeihcctycussx3peq5o36spo7p7ahvgbkvmrqypm4xyucgsvml6552i + behaviours/base.py: bafybeidt7qyijlhuqs4a2eo75z6njndqkzo7csscsrycuvqembexfhbjbq behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeihfucag3bnhduwxaupmrrku3vuaztaw43spkfo2rp6csqnaunay7y + behaviours/decision_receive.py: bafybeiekb3q2avpffr6xdkfpr6foxsi4k3wmozqrjvx3rvf5mj2kywcshy behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 2c5b99ef7..4d0856ead 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibizsj2axbbnp7ysdgo7eo2nhu5xlpzhanpckd4tnismfd5wcvyzm +- valory/decision_maker_abci:0.1.0:bafybeiedzih42efbcrfatnabpohl6ir5ozgntqtao3unkreacv6vozzesm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifcnlgmcmwcwcbkayily2uigx3bqvr4255zt3tkdtw6c4srucm2qu behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 7670be98a..b2107606f 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeidtoo6jfbk6dwk4xtep7n6v2ujc74c6ljla5nb4ybfdpdp6kmrthu +- valory/decision_maker_abci:0.1.0:bafybeiedzih42efbcrfatnabpohl6ir5ozgntqtao3unkreacv6vozzesm behaviours: main: args: {} From 94ec9d92a64e46d0118821eb185040cddbb31f46 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 14:57:38 +0200 Subject: [PATCH 35/79] chore: Adjusted log variable --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/base.py | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index d4a6c9750..83ccbb518 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeiedzih42efbcrfatnabpohl6ir5ozgntqtao3unkreacv6vozzesm", - "skill/valory/trader_abci/0.1.0": "bafybeifobwnmclkd4wo5i4v2smf5mps67yrtd2npjg6rho4rcvfhs5smky", + "skill/valory/decision_maker_abci/0.1.0": "bafybeicwfzzptb75xr2qyjjw6wqrgomiamps4sf3w5x4r325pdte4m4mju", + "skill/valory/trader_abci/0.1.0": "bafybeidhzyzun3upgpeu3xprlklojf7gsq6xuq25d6qcabu3ueea2lpc7a", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeidhhojyrpmmkixaudtikfunjze4fmusxnt2spv6fu37wespz2rpzq", - "service/valory/trader/0.1.0": "bafybeialq7ekwtav6nv536e4lip72nkckjlnng4fwekkhmoutqgxdome5y", + "agent/valory/trader/0.1.0": "bafybeicabmm4ro4yjtnbvvlwjxtnsacrkylulooeqrslmjppcvgmwdwlb4", + "service/valory/trader/0.1.0": "bafybeigbgaho3nblxp3cgwzad2it4aitv7y522tadp4bpotgizhaonkzc4", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeifcnlgmcmwcwcbkayily2uigx3bqvr4255zt3tkdtw6c4srucm2qu", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibkbasosu7jviifqhkkzei2qacpz3f47yp6uky4vfuyunmwilkbrm", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index a35f64ee3..f61b9ba6c 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifcnlgmcmwcwcbkayily2uigx3bqvr4255zt3tkdtw6c4srucm2qu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibkbasosu7jviifqhkkzei2qacpz3f47yp6uky4vfuyunmwilkbrm - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiedzih42efbcrfatnabpohl6ir5ozgntqtao3unkreacv6vozzesm -- valory/trader_abci:0.1.0:bafybeifobwnmclkd4wo5i4v2smf5mps67yrtd2npjg6rho4rcvfhs5smky +- valory/decision_maker_abci:0.1.0:bafybeicwfzzptb75xr2qyjjw6wqrgomiamps4sf3w5x4r325pdte4m4mju +- valory/trader_abci:0.1.0:bafybeidhzyzun3upgpeu3xprlklojf7gsq6xuq25d6qcabu3ueea2lpc7a default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 0c4155d8f..7d7630855 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeidhhojyrpmmkixaudtikfunjze4fmusxnt2spv6fu37wespz2rpzq +agent: valory/trader:0.1.0:bafybeicabmm4ro4yjtnbvvlwjxtnsacrkylulooeqrslmjppcvgmwdwlb4 number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index c26e1cef7..5cdad078a 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -277,7 +277,7 @@ def get_bet_amount( self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") self.context.logger.info(f"bet_kelly_fraction factor: {self.params.bet_kelly_fraction}") adj_kelly_bet_amount = kelly_bet_amount * self.params.bet_kelly_fraction - self.context.logger.info(f"Adjusted Kelly bet amount with bet_kelly_fraction factor: {kelly_bet_amount/(10**18)} xDAI") + self.context.logger.info(f"Adjusted Kelly bet amount with bet_kelly_fraction factor: {adj_kelly_bet_amount/(10**18)} xDAI") return adj_kelly_bet_amount else: raise ValueError(f"Invalid trading strategy: {strategy}") diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index af8da93f4..09ac4fd43 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,7 +12,7 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeidt7qyijlhuqs4a2eo75z6njndqkzo7csscsrycuvqembexfhbjbq + behaviours/base.py: bafybeiduo2t3o7gmf7eatl5a22pk5l5lbfifhs7olbko3h2ec3pvnxnoza behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm behaviours/decision_receive.py: bafybeiekb3q2avpffr6xdkfpr6foxsi4k3wmozqrjvx3rvf5mj2kywcshy diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 4d0856ead..80fbbca25 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiedzih42efbcrfatnabpohl6ir5ozgntqtao3unkreacv6vozzesm -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifcnlgmcmwcwcbkayily2uigx3bqvr4255zt3tkdtw6c4srucm2qu +- valory/decision_maker_abci:0.1.0:bafybeicwfzzptb75xr2qyjjw6wqrgomiamps4sf3w5x4r325pdte4m4mju +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibkbasosu7jviifqhkkzei2qacpz3f47yp6uky4vfuyunmwilkbrm behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index b2107606f..cc4191d07 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeiedzih42efbcrfatnabpohl6ir5ozgntqtao3unkreacv6vozzesm +- valory/decision_maker_abci:0.1.0:bafybeicwfzzptb75xr2qyjjw6wqrgomiamps4sf3w5x4r325pdte4m4mju behaviours: main: args: {} From 1b35de2cb670fe70130f9923b33b2583f6dd3cc5 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 15:58:10 +0200 Subject: [PATCH 36/79] feat: Restrict bet sampling to the next 48h --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/sampling.py | 7 ++++++- packages/valory/skills/decision_maker_abci/models.py | 5 ----- packages/valory/skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 20 insertions(+), 20 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 83ccbb518..91f2d8e61 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeicwfzzptb75xr2qyjjw6wqrgomiamps4sf3w5x4r325pdte4m4mju", - "skill/valory/trader_abci/0.1.0": "bafybeidhzyzun3upgpeu3xprlklojf7gsq6xuq25d6qcabu3ueea2lpc7a", + "skill/valory/decision_maker_abci/0.1.0": "bafybeigto6mflba2r335vrkwaokgea6ins566qszfc55yg4zzsvdvfsznu", + "skill/valory/trader_abci/0.1.0": "bafybeih2kpsdapreskopobno7zhyenfaells5hq6t4a6vo5hzlawcvtuom", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeicabmm4ro4yjtnbvvlwjxtnsacrkylulooeqrslmjppcvgmwdwlb4", - "service/valory/trader/0.1.0": "bafybeigbgaho3nblxp3cgwzad2it4aitv7y522tadp4bpotgizhaonkzc4", + "agent/valory/trader/0.1.0": "bafybeic4afoeyrmckyagefoqvq4ogjooxx3ykcbq766pmxu7if4mf6y4gi", + "service/valory/trader/0.1.0": "bafybeiequhwzi6se3mydmrsojag3mrrles5jejxzacgyhuuvlay4wnncvu", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibkbasosu7jviifqhkkzei2qacpz3f47yp6uky4vfuyunmwilkbrm", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihvy5sm56tavxikdw44hzua3zzhuriur7ljiagocifvkotwpevqxu", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index f61b9ba6c..4ab90c609 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibkbasosu7jviifqhkkzei2qacpz3f47yp6uky4vfuyunmwilkbrm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihvy5sm56tavxikdw44hzua3zzhuriur7ljiagocifvkotwpevqxu - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeicwfzzptb75xr2qyjjw6wqrgomiamps4sf3w5x4r325pdte4m4mju -- valory/trader_abci:0.1.0:bafybeidhzyzun3upgpeu3xprlklojf7gsq6xuq25d6qcabu3ueea2lpc7a +- valory/decision_maker_abci:0.1.0:bafybeigto6mflba2r335vrkwaokgea6ins566qszfc55yg4zzsvdvfsznu +- valory/trader_abci:0.1.0:bafybeih2kpsdapreskopobno7zhyenfaells5hq6t4a6vo5hzlawcvtuom default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 7d7630855..664b95190 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeicabmm4ro4yjtnbvvlwjxtnsacrkylulooeqrslmjppcvgmwdwlb4 +agent: valory/trader:0.1.0:bafybeic4afoeyrmckyagefoqvq4ogjooxx3ykcbq766pmxu7if4mf6y4gi number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index 39f1384eb..58beeb92f 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -19,6 +19,8 @@ """This module contains the behaviour for sampling a bet.""" +import time + from typing import Generator, Iterator, List, Optional, Tuple from packages.valory.skills.decision_maker_abci.behaviours.base import ( @@ -54,7 +56,10 @@ def _sampled_bet_idx(self, bets: List[Bet]) -> int: :param bets: the bets' values to compare for the sampling. :return: the id of the sampled bet, out of all the available bets, not only the given ones. """ - return self.synchronized_data.bets.index(max(bets)) + # Get only bets that close in the next 48 hours + # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet + short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + 172800), bets) + return self.synchronized_data.bets.index(max(short_term_bets)) def _set_processed(self, idx: int) -> Optional[str]: """Update the bet's status for the given id to `PROCESSED`, and return the updated bets list, serialized.""" diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 169b31d6d..ed7668e47 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -161,11 +161,6 @@ def slippage(self, slippage: float) -> None: f"The configured slippage {slippage!r} is not in the range [0, 1]." ) self._slippage = slippage - - # def get_bet_amount(self, confidence: float) -> int: - # """Get the bet amount given a prediction's confidence.""" - # threshold = round(confidence, 1) - # return self.bet_amount_per_threshold[threshold] def get_policy_store_path(self, kwargs: Dict) -> Path: """Get the path of the policy store.""" diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 09ac4fd43..f10cda045 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -20,12 +20,12 @@ fingerprint: behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeiadikynvkaofbko72jc45xthhmmjfmlkpgramormhxwk5u47rnwdu + behaviours/sampling.py: bafybeif2o2t3tan7y53zqhcsidm6puy7u4gc74jxdstjrdultlddkrllky behaviours/tool_selection.py: bafybeigbxgm6rl6jnexxzjhb7thsdaqr56wfhxpve25yxlr7eyswf6lsey dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeigbfqhm5ks3j7kpm6gedyymjn4azfijhymotmhf6bddazdu2jjlua + models.py: bafybeihnpza4hibx3y6itnhpg2lgjmuh3dveby7tnarzsollofdtyajyuq payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 80fbbca25..05c623e57 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeicwfzzptb75xr2qyjjw6wqrgomiamps4sf3w5x4r325pdte4m4mju -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibkbasosu7jviifqhkkzei2qacpz3f47yp6uky4vfuyunmwilkbrm +- valory/decision_maker_abci:0.1.0:bafybeigto6mflba2r335vrkwaokgea6ins566qszfc55yg4zzsvdvfsznu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihvy5sm56tavxikdw44hzua3zzhuriur7ljiagocifvkotwpevqxu behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index cc4191d07..2298113ce 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeicwfzzptb75xr2qyjjw6wqrgomiamps4sf3w5x4r325pdte4m4mju +- valory/decision_maker_abci:0.1.0:bafybeigto6mflba2r335vrkwaokgea6ins566qszfc55yg4zzsvdvfsznu behaviours: main: args: {} From c55f0bf116827699d3cf644b03607f8b6429cf30 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 16:11:10 +0200 Subject: [PATCH 37/79] chore: Add log for short term bet filter --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/sampling.py | 3 ++- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 15 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 91f2d8e61..5b7328048 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeigto6mflba2r335vrkwaokgea6ins566qszfc55yg4zzsvdvfsznu", - "skill/valory/trader_abci/0.1.0": "bafybeih2kpsdapreskopobno7zhyenfaells5hq6t4a6vo5hzlawcvtuom", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidtzl2zrg7oeqqvkdmd4y73xa7rjaavo3onpi2zbjvfoytuqevlw4", + "skill/valory/trader_abci/0.1.0": "bafybeiaqo4rhmvdupvxvkbrayoozpp7wzxz5vrmwwnq3mlvyigzv3l74x4", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeic4afoeyrmckyagefoqvq4ogjooxx3ykcbq766pmxu7if4mf6y4gi", - "service/valory/trader/0.1.0": "bafybeiequhwzi6se3mydmrsojag3mrrles5jejxzacgyhuuvlay4wnncvu", + "agent/valory/trader/0.1.0": "bafybeifzvyer6rgvsyztjyzc5jybxktn3gdfligbdkznv7apamikvlwxzm", + "service/valory/trader/0.1.0": "bafybeifhjlttljq2sdd7msnm7iw3wgno36mro7erf7tgdhpxcx5vpqx3ga", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihvy5sm56tavxikdw44hzua3zzhuriur7ljiagocifvkotwpevqxu", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeie2h7ry3peazmnbqgk7x6hnapwvhlkbzuf2lz2wppeavx6koqogti", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 4ab90c609..ab1e6749f 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihvy5sm56tavxikdw44hzua3zzhuriur7ljiagocifvkotwpevqxu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeie2h7ry3peazmnbqgk7x6hnapwvhlkbzuf2lz2wppeavx6koqogti - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigto6mflba2r335vrkwaokgea6ins566qszfc55yg4zzsvdvfsznu -- valory/trader_abci:0.1.0:bafybeih2kpsdapreskopobno7zhyenfaells5hq6t4a6vo5hzlawcvtuom +- valory/decision_maker_abci:0.1.0:bafybeidtzl2zrg7oeqqvkdmd4y73xa7rjaavo3onpi2zbjvfoytuqevlw4 +- valory/trader_abci:0.1.0:bafybeiaqo4rhmvdupvxvkbrayoozpp7wzxz5vrmwwnq3mlvyigzv3l74x4 default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 664b95190..8381d6b98 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeic4afoeyrmckyagefoqvq4ogjooxx3ykcbq766pmxu7if4mf6y4gi +agent: valory/trader:0.1.0:bafybeifzvyer6rgvsyztjyzc5jybxktn3gdfligbdkznv7apamikvlwxzm number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index 58beeb92f..b3f18c8d0 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -58,7 +58,8 @@ def _sampled_bet_idx(self, bets: List[Bet]) -> int: """ # Get only bets that close in the next 48 hours # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet - short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + 172800), bets) + short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + 172800), bets) + self.context.logger.info(f"Short term bets: {short_term_bets}") return self.synchronized_data.bets.index(max(short_term_bets)) def _set_processed(self, idx: int) -> Optional[str]: diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index f10cda045..a4729dde3 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -20,7 +20,7 @@ fingerprint: behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeif2o2t3tan7y53zqhcsidm6puy7u4gc74jxdstjrdultlddkrllky + behaviours/sampling.py: bafybeiabi2vshb5a36gzhwh5gu2c7da7p3vlv4wwairatkk3tc2ehuw37y behaviours/tool_selection.py: bafybeigbxgm6rl6jnexxzjhb7thsdaqr56wfhxpve25yxlr7eyswf6lsey dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 05c623e57..f7fbcfb4e 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigto6mflba2r335vrkwaokgea6ins566qszfc55yg4zzsvdvfsznu -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihvy5sm56tavxikdw44hzua3zzhuriur7ljiagocifvkotwpevqxu +- valory/decision_maker_abci:0.1.0:bafybeidtzl2zrg7oeqqvkdmd4y73xa7rjaavo3onpi2zbjvfoytuqevlw4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeie2h7ry3peazmnbqgk7x6hnapwvhlkbzuf2lz2wppeavx6koqogti behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 2298113ce..0f0306e33 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeigto6mflba2r335vrkwaokgea6ins566qszfc55yg4zzsvdvfsznu +- valory/decision_maker_abci:0.1.0:bafybeidtzl2zrg7oeqqvkdmd4y73xa7rjaavo3onpi2zbjvfoytuqevlw4 behaviours: main: args: {} From 2309b1c29d358ab67afd4e4a14657444ed4db6e7 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 16:17:52 +0200 Subject: [PATCH 38/79] chore: Convert filter to list --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/sampling.py | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 5b7328048..1dc2ff84c 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeidtzl2zrg7oeqqvkdmd4y73xa7rjaavo3onpi2zbjvfoytuqevlw4", - "skill/valory/trader_abci/0.1.0": "bafybeiaqo4rhmvdupvxvkbrayoozpp7wzxz5vrmwwnq3mlvyigzv3l74x4", + "skill/valory/decision_maker_abci/0.1.0": "bafybeifop5opcgprzmvtcx477k6dok5wzl44gtcz4rcxihzq4bs4whoyva", + "skill/valory/trader_abci/0.1.0": "bafybeidwk6rpzmjatqeb3zqjd5ast7iyxnviqg5q4hqpwdoidcp5d6ro5a", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeifzvyer6rgvsyztjyzc5jybxktn3gdfligbdkznv7apamikvlwxzm", - "service/valory/trader/0.1.0": "bafybeifhjlttljq2sdd7msnm7iw3wgno36mro7erf7tgdhpxcx5vpqx3ga", + "agent/valory/trader/0.1.0": "bafybeiera2lfrgxfmt4ffcddvcvuwf6uke4rycstrqubmr7putaxunwwfa", + "service/valory/trader/0.1.0": "bafybeihhvrgo4wxdumb4xfbyaorxsl2o7imykxiouthlrzagvagu7sjpqy", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeie2h7ry3peazmnbqgk7x6hnapwvhlkbzuf2lz2wppeavx6koqogti", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeie7lf47zzob435t4ph5aaf6kmtu377hoa4hou2ilwenyglg3zshsi", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index ab1e6749f..30ad058b3 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeie2h7ry3peazmnbqgk7x6hnapwvhlkbzuf2lz2wppeavx6koqogti +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeie7lf47zzob435t4ph5aaf6kmtu377hoa4hou2ilwenyglg3zshsi - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidtzl2zrg7oeqqvkdmd4y73xa7rjaavo3onpi2zbjvfoytuqevlw4 -- valory/trader_abci:0.1.0:bafybeiaqo4rhmvdupvxvkbrayoozpp7wzxz5vrmwwnq3mlvyigzv3l74x4 +- valory/decision_maker_abci:0.1.0:bafybeifop5opcgprzmvtcx477k6dok5wzl44gtcz4rcxihzq4bs4whoyva +- valory/trader_abci:0.1.0:bafybeidwk6rpzmjatqeb3zqjd5ast7iyxnviqg5q4hqpwdoidcp5d6ro5a default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 8381d6b98..9bfe15fca 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeifzvyer6rgvsyztjyzc5jybxktn3gdfligbdkznv7apamikvlwxzm +agent: valory/trader:0.1.0:bafybeiera2lfrgxfmt4ffcddvcvuwf6uke4rycstrqubmr7putaxunwwfa number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index b3f18c8d0..bfa908367 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -59,7 +59,7 @@ def _sampled_bet_idx(self, bets: List[Bet]) -> int: # Get only bets that close in the next 48 hours # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + 172800), bets) - self.context.logger.info(f"Short term bets: {short_term_bets}") + self.context.logger.info(f"Short term bets: {list(short_term_bets)}") return self.synchronized_data.bets.index(max(short_term_bets)) def _set_processed(self, idx: int) -> Optional[str]: diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index a4729dde3..682c12de4 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -20,7 +20,7 @@ fingerprint: behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeiabi2vshb5a36gzhwh5gu2c7da7p3vlv4wwairatkk3tc2ehuw37y + behaviours/sampling.py: bafybeicb5vj3bfd2wfwrndwbkbvzvlkgd3dxogtauyyr67i6ltkdgmlseu behaviours/tool_selection.py: bafybeigbxgm6rl6jnexxzjhb7thsdaqr56wfhxpve25yxlr7eyswf6lsey dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index f7fbcfb4e..2ffaa4c1e 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidtzl2zrg7oeqqvkdmd4y73xa7rjaavo3onpi2zbjvfoytuqevlw4 -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeie2h7ry3peazmnbqgk7x6hnapwvhlkbzuf2lz2wppeavx6koqogti +- valory/decision_maker_abci:0.1.0:bafybeifop5opcgprzmvtcx477k6dok5wzl44gtcz4rcxihzq4bs4whoyva +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeie7lf47zzob435t4ph5aaf6kmtu377hoa4hou2ilwenyglg3zshsi behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 0f0306e33..099f48603 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeidtzl2zrg7oeqqvkdmd4y73xa7rjaavo3onpi2zbjvfoytuqevlw4 +- valory/decision_maker_abci:0.1.0:bafybeifop5opcgprzmvtcx477k6dok5wzl44gtcz4rcxihzq4bs4whoyva behaviours: main: args: {} From aba93a3bdd24e19305a4ae162b80e9bd7de9bd97 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 16:30:41 +0200 Subject: [PATCH 39/79] fix: changed datatype of short_term_bets --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/sampling.py | 5 +++-- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 16 insertions(+), 15 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 1dc2ff84c..81c0ef69e 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeifop5opcgprzmvtcx477k6dok5wzl44gtcz4rcxihzq4bs4whoyva", - "skill/valory/trader_abci/0.1.0": "bafybeidwk6rpzmjatqeb3zqjd5ast7iyxnviqg5q4hqpwdoidcp5d6ro5a", + "skill/valory/decision_maker_abci/0.1.0": "bafybeigcsq2ov6vtfoea7cs7gpji5fhvffxrjlqjghydieqn5rgacvyttq", + "skill/valory/trader_abci/0.1.0": "bafybeienn32vjro2xd32fumbzql6ffgvijrewuxtj3skyc4fewrxvevp5u", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeiera2lfrgxfmt4ffcddvcvuwf6uke4rycstrqubmr7putaxunwwfa", - "service/valory/trader/0.1.0": "bafybeihhvrgo4wxdumb4xfbyaorxsl2o7imykxiouthlrzagvagu7sjpqy", + "agent/valory/trader/0.1.0": "bafybeifxa77nssjfk3qi7jkrxjk42bpmgsrodirtehsfvwdq42r7rvmnfe", + "service/valory/trader/0.1.0": "bafybeicoc2u3hknfq5scfixobc6tcj3tqz2uqlszgvtbzze3lobdpbifgi", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeie7lf47zzob435t4ph5aaf6kmtu377hoa4hou2ilwenyglg3zshsi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihctenld5asts2ya3uydbf7ph2uyxcnmm3umpx3bx7utibbligtui", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 30ad058b3..cde7e6e3a 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeie7lf47zzob435t4ph5aaf6kmtu377hoa4hou2ilwenyglg3zshsi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihctenld5asts2ya3uydbf7ph2uyxcnmm3umpx3bx7utibbligtui - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeifop5opcgprzmvtcx477k6dok5wzl44gtcz4rcxihzq4bs4whoyva -- valory/trader_abci:0.1.0:bafybeidwk6rpzmjatqeb3zqjd5ast7iyxnviqg5q4hqpwdoidcp5d6ro5a +- valory/decision_maker_abci:0.1.0:bafybeigcsq2ov6vtfoea7cs7gpji5fhvffxrjlqjghydieqn5rgacvyttq +- valory/trader_abci:0.1.0:bafybeienn32vjro2xd32fumbzql6ffgvijrewuxtj3skyc4fewrxvevp5u default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 9bfe15fca..4bff9bae7 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiera2lfrgxfmt4ffcddvcvuwf6uke4rycstrqubmr7putaxunwwfa +agent: valory/trader:0.1.0:bafybeifxa77nssjfk3qi7jkrxjk42bpmgsrodirtehsfvwdq42r7rvmnfe number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index bfa908367..eb2a973ab 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -59,8 +59,9 @@ def _sampled_bet_idx(self, bets: List[Bet]) -> int: # Get only bets that close in the next 48 hours # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + 172800), bets) - self.context.logger.info(f"Short term bets: {list(short_term_bets)}") - return self.synchronized_data.bets.index(max(short_term_bets)) + short_term_bets_list = list(short_term_bets) + self.context.logger.info(f"Short term bets: {short_term_bets_list}") + return self.synchronized_data.bets.index(max(short_term_bets_list)) def _set_processed(self, idx: int) -> Optional[str]: """Update the bet's status for the given id to `PROCESSED`, and return the updated bets list, serialized.""" diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 682c12de4..c7d9d1d58 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -20,7 +20,7 @@ fingerprint: behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeicb5vj3bfd2wfwrndwbkbvzvlkgd3dxogtauyyr67i6ltkdgmlseu + behaviours/sampling.py: bafybeid3q7e7rao2od2eycidkvnbz2zzq4yse4mdjgvq2ja75sa4to3jte behaviours/tool_selection.py: bafybeigbxgm6rl6jnexxzjhb7thsdaqr56wfhxpve25yxlr7eyswf6lsey dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 2ffaa4c1e..4ca39c1d4 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeifop5opcgprzmvtcx477k6dok5wzl44gtcz4rcxihzq4bs4whoyva -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeie7lf47zzob435t4ph5aaf6kmtu377hoa4hou2ilwenyglg3zshsi +- valory/decision_maker_abci:0.1.0:bafybeigcsq2ov6vtfoea7cs7gpji5fhvffxrjlqjghydieqn5rgacvyttq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihctenld5asts2ya3uydbf7ph2uyxcnmm3umpx3bx7utibbligtui behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 099f48603..f09ae4d05 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeifop5opcgprzmvtcx477k6dok5wzl44gtcz4rcxihzq4bs4whoyva +- valory/decision_maker_abci:0.1.0:bafybeigcsq2ov6vtfoea7cs7gpji5fhvffxrjlqjghydieqn5rgacvyttq behaviours: main: args: {} From 9f42cd916192de0de66c091f2d48141982b69f3f Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Fri, 20 Oct 2023 16:43:02 +0200 Subject: [PATCH 40/79] fix: Handled negative value kelly bet --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/base.py | 7 +++++++ packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 20 insertions(+), 13 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 81c0ef69e..d1c2a7d2b 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeigcsq2ov6vtfoea7cs7gpji5fhvffxrjlqjghydieqn5rgacvyttq", - "skill/valory/trader_abci/0.1.0": "bafybeienn32vjro2xd32fumbzql6ffgvijrewuxtj3skyc4fewrxvevp5u", + "skill/valory/decision_maker_abci/0.1.0": "bafybeid4mm6tuszvtzu7pfeopiztz4oaduj6sxotv4kiuyrmgeojptnkmu", + "skill/valory/trader_abci/0.1.0": "bafybeicabuscexdi4qmtuib6cryk5x76ahjffh6r64ssxwp3mkj2tum4hq", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeifxa77nssjfk3qi7jkrxjk42bpmgsrodirtehsfvwdq42r7rvmnfe", - "service/valory/trader/0.1.0": "bafybeicoc2u3hknfq5scfixobc6tcj3tqz2uqlszgvtbzze3lobdpbifgi", + "agent/valory/trader/0.1.0": "bafybeidupzyt7hjs5qcxmjy6bfvl5zf4wqtgsnaeyxg44du6krk7iqikdy", + "service/valory/trader/0.1.0": "bafybeifys5cbasuvtqepmrotgoicv2bnv5xgfelfu2m6y4fn2t6esw7bni", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihctenld5asts2ya3uydbf7ph2uyxcnmm3umpx3bx7utibbligtui", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeieksefcyu72fuuofbstc3yf2ecx5kcyt6cro6w3im4gdyw53zgyl4", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index cde7e6e3a..066732681 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihctenld5asts2ya3uydbf7ph2uyxcnmm3umpx3bx7utibbligtui +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieksefcyu72fuuofbstc3yf2ecx5kcyt6cro6w3im4gdyw53zgyl4 - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigcsq2ov6vtfoea7cs7gpji5fhvffxrjlqjghydieqn5rgacvyttq -- valory/trader_abci:0.1.0:bafybeienn32vjro2xd32fumbzql6ffgvijrewuxtj3skyc4fewrxvevp5u +- valory/decision_maker_abci:0.1.0:bafybeid4mm6tuszvtzu7pfeopiztz4oaduj6sxotv4kiuyrmgeojptnkmu +- valory/trader_abci:0.1.0:bafybeicabuscexdi4qmtuib6cryk5x76ahjffh6r64ssxwp3mkj2tum4hq default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 4bff9bae7..b7041f50d 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeifxa77nssjfk3qi7jkrxjk42bpmgsrodirtehsfvwdq42r7rvmnfe +agent: valory/trader:0.1.0:bafybeidupzyt7hjs5qcxmjy6bfvl5zf4wqtgsnaeyxg44du6krk7iqikdy number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 5cdad078a..06d5c55eb 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -272,6 +272,13 @@ def get_bet_amount( ) if kelly_bet_amount == None: return 0 + if kelly_bet_amount < 0: + self.context.logger.error( + "Could not calculate Kelly bet amount. Negative value:\n" + f"Kelly bet amount: {kelly_bet_amount}" + "Set bet amount to 0." + ) + return 0 else: self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index c7d9d1d58..01661a8df 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,7 +12,7 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeiduo2t3o7gmf7eatl5a22pk5l5lbfifhs7olbko3h2ec3pvnxnoza + behaviours/base.py: bafybeid3hmx5utbm2rs2aq4gzdds3sd5yih3avtgvr4tganaqbi3afv2d4 behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm behaviours/decision_receive.py: bafybeiekb3q2avpffr6xdkfpr6foxsi4k3wmozqrjvx3rvf5mj2kywcshy diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 4ca39c1d4..bddde55b0 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeigcsq2ov6vtfoea7cs7gpji5fhvffxrjlqjghydieqn5rgacvyttq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihctenld5asts2ya3uydbf7ph2uyxcnmm3umpx3bx7utibbligtui +- valory/decision_maker_abci:0.1.0:bafybeid4mm6tuszvtzu7pfeopiztz4oaduj6sxotv4kiuyrmgeojptnkmu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieksefcyu72fuuofbstc3yf2ecx5kcyt6cro6w3im4gdyw53zgyl4 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index f09ae4d05..a1466f00a 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeigcsq2ov6vtfoea7cs7gpji5fhvffxrjlqjghydieqn5rgacvyttq +- valory/decision_maker_abci:0.1.0:bafybeid4mm6tuszvtzu7pfeopiztz4oaduj6sxotv4kiuyrmgeojptnkmu behaviours: main: args: {} From 0104cbd7ff5e34f8976730a13d0914b25c13ca18 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 21 Oct 2023 08:13:59 +0200 Subject: [PATCH 41/79] refactor: Cap max buy amount to a fraction of available shares --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/base.py | 2 +- .../decision_maker_abci/behaviours/decision_receive.py | 3 +++ packages/valory/skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 18 insertions(+), 15 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index d1c2a7d2b..3a90cb9da 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeid4mm6tuszvtzu7pfeopiztz4oaduj6sxotv4kiuyrmgeojptnkmu", - "skill/valory/trader_abci/0.1.0": "bafybeicabuscexdi4qmtuib6cryk5x76ahjffh6r64ssxwp3mkj2tum4hq", + "skill/valory/decision_maker_abci/0.1.0": "bafybeieewl4yttwangroyavt4y7oirmp56g2qgvpjd4k4euipbbpjgtc5q", + "skill/valory/trader_abci/0.1.0": "bafybeiepbuovugocdzccr3xjidz4pv2xzg5vgyki4zlsw2leuhe5tb7xhe", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeidupzyt7hjs5qcxmjy6bfvl5zf4wqtgsnaeyxg44du6krk7iqikdy", - "service/valory/trader/0.1.0": "bafybeifys5cbasuvtqepmrotgoicv2bnv5xgfelfu2m6y4fn2t6esw7bni", + "agent/valory/trader/0.1.0": "bafybeia4npclqw7tgejjx7icyjv5majq6t3pg2pr3lcsc4xie7wjy4cq2y", + "service/valory/trader/0.1.0": "bafybeifeecmnpaixjicnndphelgrimp3rjoqp5do6sl7dux3wowypbs42q", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeieksefcyu72fuuofbstc3yf2ecx5kcyt6cro6w3im4gdyw53zgyl4", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeieofft7qquen3sgf5os7ovdsw27yytdtcm2icfxmhy3gwcz55rj74", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 066732681..93096cb5c 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieksefcyu72fuuofbstc3yf2ecx5kcyt6cro6w3im4gdyw53zgyl4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieofft7qquen3sgf5os7ovdsw27yytdtcm2icfxmhy3gwcz55rj74 - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeid4mm6tuszvtzu7pfeopiztz4oaduj6sxotv4kiuyrmgeojptnkmu -- valory/trader_abci:0.1.0:bafybeicabuscexdi4qmtuib6cryk5x76ahjffh6r64ssxwp3mkj2tum4hq +- valory/decision_maker_abci:0.1.0:bafybeieewl4yttwangroyavt4y7oirmp56g2qgvpjd4k4euipbbpjgtc5q +- valory/trader_abci:0.1.0:bafybeiepbuovugocdzccr3xjidz4pv2xzg5vgyki4zlsw2leuhe5tb7xhe default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index b7041f50d..4566e148f 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeidupzyt7hjs5qcxmjy6bfvl5zf4wqtgsnaeyxg44du6krk7iqikdy +agent: valory/trader:0.1.0:bafybeia4npclqw7tgejjx7icyjv5majq6t3pg2pr3lcsc4xie7wjy4cq2y number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 06d5c55eb..178b1be1d 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -283,7 +283,7 @@ def get_bet_amount( self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") self.context.logger.info(f"bet_kelly_fraction factor: {self.params.bet_kelly_fraction}") - adj_kelly_bet_amount = kelly_bet_amount * self.params.bet_kelly_fraction + adj_kelly_bet_amount = int(kelly_bet_amount * self.params.bet_kelly_fraction) self.context.logger.info(f"Adjusted Kelly bet amount with bet_kelly_fraction factor: {adj_kelly_bet_amount/(10**18)} xDAI") return adj_kelly_bet_amount else: diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 4cd244121..8c6469ddf 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -409,6 +409,9 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") num_shares, available_shares = self._calc_binary_shares(bet_amount, win_probability, confidence, vote) + + # Set available shares to 1/3 of the total available shares to prevent the bot from buying all shares in this test scenario + available_shares = int(available_shares / 3) if num_shares > available_shares * SLIPPAGE: self.context.logger.warning( "Kindly contemplate reducing your bet amount, as the pool's liquidity is low compared to your bet. " diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 01661a8df..2e749e81b 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,10 +12,10 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeid3hmx5utbm2rs2aq4gzdds3sd5yih3avtgvr4tganaqbi3afv2d4 + behaviours/base.py: bafybeifa3nzbtnpb6ixk6ftlw4x6beq3lslm6akpvfqifh4vpynlddre3i behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeiekb3q2avpffr6xdkfpr6foxsi4k3wmozqrjvx3rvf5mj2kywcshy + behaviours/decision_receive.py: bafybeigdrin6errqqomqjihj2lvryvhknl5hd5mzu6praixnfpcyw3inr4 behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index bddde55b0..8c3eed8d7 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeid4mm6tuszvtzu7pfeopiztz4oaduj6sxotv4kiuyrmgeojptnkmu -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieksefcyu72fuuofbstc3yf2ecx5kcyt6cro6w3im4gdyw53zgyl4 +- valory/decision_maker_abci:0.1.0:bafybeieewl4yttwangroyavt4y7oirmp56g2qgvpjd4k4euipbbpjgtc5q +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieofft7qquen3sgf5os7ovdsw27yytdtcm2icfxmhy3gwcz55rj74 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index a1466f00a..71651566e 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeid4mm6tuszvtzu7pfeopiztz4oaduj6sxotv4kiuyrmgeojptnkmu +- valory/decision_maker_abci:0.1.0:bafybeieewl4yttwangroyavt4y7oirmp56g2qgvpjd4k4euipbbpjgtc5q behaviours: main: args: {} From 57d27e7604bfb40f2cd8dbe14379ab44b323f7e7 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 21 Oct 2023 09:37:03 +0200 Subject: [PATCH 42/79] refactor: Add bet_amount to synchonized data --- packages/packages.json | 10 +++---- packages/valory/agents/trader/aea-config.yaml | 6 ++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/base.py | 19 +++++-------- .../behaviours/bet_placement.py | 9 +------ .../behaviours/decision_receive.py | 27 +++++++++---------- .../skills/decision_maker_abci/payloads.py | 1 + .../skills/decision_maker_abci/skill.yaml | 12 ++++----- .../skills/decision_maker_abci/states/base.py | 5 ++++ .../states/decision_receive.py | 1 + packages/valory/skills/trader_abci/skill.yaml | 4 +-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 12 files changed, 46 insertions(+), 52 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 3a90cb9da..7c6afd7cb 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeieewl4yttwangroyavt4y7oirmp56g2qgvpjd4k4euipbbpjgtc5q", - "skill/valory/trader_abci/0.1.0": "bafybeiepbuovugocdzccr3xjidz4pv2xzg5vgyki4zlsw2leuhe5tb7xhe", + "skill/valory/decision_maker_abci/0.1.0": "bafybeievapnqxbtrxmbaabdlmqzujuw5wybemtt4s6jv44tkotq3i2o2ui", + "skill/valory/trader_abci/0.1.0": "bafybeichmlcig6qucvflhi7l5oaxllih47rs4yz325pfvzfldg7abazmha", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeia4npclqw7tgejjx7icyjv5majq6t3pg2pr3lcsc4xie7wjy4cq2y", - "service/valory/trader/0.1.0": "bafybeifeecmnpaixjicnndphelgrimp3rjoqp5do6sl7dux3wowypbs42q", + "agent/valory/trader/0.1.0": "bafybeicbgf3zftgiezg33cvcp2ll6kixbi5c6ofzj6fojhbzufk4dregya", + "service/valory/trader/0.1.0": "bafybeiekdangesbgwq66npsirjhkeae7eydcvnz5brlg3estuxcixtvv4e", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeieofft7qquen3sgf5os7ovdsw27yytdtcm2icfxmhy3gwcz55rj74", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiesb2rnxpcbyqwwcwfozltoix4mzytohj7hcivc2hc7pwtbgqx2yy", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 93096cb5c..37dc48e86 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieofft7qquen3sgf5os7ovdsw27yytdtcm2icfxmhy3gwcz55rj74 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiesb2rnxpcbyqwwcwfozltoix4mzytohj7hcivc2hc7pwtbgqx2yy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeieewl4yttwangroyavt4y7oirmp56g2qgvpjd4k4euipbbpjgtc5q -- valory/trader_abci:0.1.0:bafybeiepbuovugocdzccr3xjidz4pv2xzg5vgyki4zlsw2leuhe5tb7xhe +- valory/decision_maker_abci:0.1.0:bafybeievapnqxbtrxmbaabdlmqzujuw5wybemtt4s6jv44tkotq3i2o2ui +- valory/trader_abci:0.1.0:bafybeichmlcig6qucvflhi7l5oaxllih47rs4yz325pfvzfldg7abazmha default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 4566e148f..2e5f1b4b1 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeia4npclqw7tgejjx7icyjv5majq6t3pg2pr3lcsc4xie7wjy4cq2y +agent: valory/trader:0.1.0:bafybeicbgf3zftgiezg33cvcp2ll6kixbi5c6ofzj6fojhbzufk4dregya number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 178b1be1d..f1e16aef0 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -215,7 +215,6 @@ def _calculate_kelly_bet_amount(self, x, y, p, c, b, f) -> int: ) return None kelly_bet_amount = (-4*x**2*y + b*y**2*p*c*f + 2*b*x*y*p*c*f + b*x**2*p*c*f - 2*b*y**2*f - 2*b*x*y*f + ((4*x**2*y - b*y**2*p*c*f - 2*b*x*y*p*c*f - b*x**2*p*c*f + 2*b*y**2*f + 2*b*x*y*f)**2 - (4*(x**2*f - y**2*f) * (-4*b*x*y**2*p*c - 4*b*x**2*y*p*c + 4*b*x*y**2)))**(1/2))/(2*(x**2*f - y**2*f)) - self.context.logger.info(f"Kelly bet amount _get_kelly_bet_amount X1: {kelly_bet_amount}") return int(kelly_bet_amount) def get_max_bet_amount(self, a, x, y, f) -> int: @@ -249,16 +248,14 @@ def get_bet_amount( """Get the bet amount given a specified trading strategy.""" if strategy == "bet_amount_per_conf_threshold": - self.context.logger.info(f"Used trading strategy: {strategy}") + self.context.logger.info(f"Used trading strategy: Bet amount per confidence threshold") threshold = round(confidence, 1) bet_amount = self.params.bet_amount_per_threshold[threshold] self.context.logger.info(f"Bet amount: {bet_amount}") - net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) - self.context.logger.info(f"Net bet amount: {net_bet_amount}") - return net_bet_amount + return bet_amount elif strategy == "kelly_criterion": - self.context.logger.info(f"Used trading strategy: {strategy}") + self.context.logger.info(f"Used trading strategy: Kelly Criterion") bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade fee_fraction = 1 - self.wei_to_native(bet_fee) self.context.logger.info(f"Fee fraction: {fee_fraction}") @@ -273,18 +270,16 @@ def get_bet_amount( if kelly_bet_amount == None: return 0 if kelly_bet_amount < 0: - self.context.logger.error( - "Could not calculate Kelly bet amount. Negative value:\n" - f"Kelly bet amount: {kelly_bet_amount}" + self.context.logger.info( + f"Negative value for kelly bet amount: {kelly_bet_amount}\n" "Set bet amount to 0." ) return 0 else: - self.context.logger.info(f"Kelly bet amount wei: {kelly_bet_amount}") self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") - self.context.logger.info(f"bet_kelly_fraction factor: {self.params.bet_kelly_fraction}") + self.context.logger.info(f"Bet kelly fraction: {self.params.bet_kelly_fraction}") adj_kelly_bet_amount = int(kelly_bet_amount * self.params.bet_kelly_fraction) - self.context.logger.info(f"Adjusted Kelly bet amount with bet_kelly_fraction factor: {adj_kelly_bet_amount/(10**18)} xDAI") + self.context.logger.info(f"Adjusted Kelly bet: {adj_kelly_bet_amount/(10**18)} xDAI") return adj_kelly_bet_amount else: raise ValueError(f"Invalid trading strategy: {strategy}") diff --git a/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py b/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py index 306096d42..677374a59 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/bet_placement.py @@ -59,14 +59,7 @@ def market_maker_contract_address(self) -> str: @property def investment_amount(self) -> int: """Get the investment amount of the bet.""" - balance_sum = self.wallet_balance + self.token_balance - return self.params.get_bet_amount( - balance_sum, - self.params.trading_strategy, - self.synchronized_data.odds, - self.synchronized_data.win_probability, - self.synchronized_data.confidence, - ) + return self.synchronized_data.bet_amount @property def w_xdai_deficit(self) -> int: diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 8c6469ddf..028e62610 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -30,6 +30,7 @@ CID_PREFIX, DecisionMakerBaseBehaviour, WaitableConditionType, + remove_fraction_wei ) from packages.valory.skills.decision_maker_abci.behaviours.bet_placement import WXDAI from packages.valory.skills.decision_maker_abci.models import ( @@ -259,7 +260,7 @@ def _get_bet_sample_info(self, bet, vote) -> Tuple[int, int, int]: return selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee - def _calc_binary_shares(self, bet_amount: int, win_probability: float, confidence: float, vote: int) -> Tuple[int, int]: + def _calc_binary_shares(self, bet_amount: int, vote: int) -> Tuple[int, int]: """Calculate the claimed shares. This calculation only works for binary markets.""" bet = self.synchronized_data.sampled_bet @@ -308,11 +309,11 @@ def _calc_binary_shares(self, bet_amount: int, win_probability: float, confidenc self.context.logger.info(f"Tokens remaining in pool: {tokens_remaining_in_pool/(10**18)}") swapped_shares = selected_type_tokens_in_pool - tokens_remaining_in_pool - self.context.logger.info(f"Swapped shares: {swapped_shares/(10**18)}") + self.context.logger.info(f"Swapped shares: {int(swapped_shares/(10**18))}") # calculate the resulting number of shares if the service would take that position num_shares = selected_shares + swapped_shares - self.context.logger.info(f"Number of shares: {num_shares/(10**18)}") + self.context.logger.info(f"Number of shares: {int(num_shares/(10**18))}") # calculate the available number of shares price = prices[vote] @@ -375,13 +376,10 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide self.context.logger.info(f"Bet: {bet}") yield from self._check_balance() bankroll = self.wallet_balance + self.token_balance - self.context.logger.info(f"Wallet balance: {self.wallet_balance}") - self.context.logger.info(f"Token balance: {self.token_balance}") - self.context.logger.info(f"Bankroll: {bankroll}") + self.context.logger.info(f"Bankroll wei: {bankroll}") selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee = self._get_bet_sample_info(bet, vote) # Testing and printing kelly bet amount - self.context.logger.info("\nStart kelly bet amount calculation") bet_amount = self.get_bet_amount( bankroll, self.params.trading_strategy, @@ -394,7 +392,6 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide # Safety fallback to bet amount per conf threshold # Only remove if you are sure that kelly bet amount is working as expected - self.context.logger.info("\nStart bet amount per conf threshold calculation") bet_amount = self.get_bet_amount( bankroll, "bet_amount_per_conf_threshold", @@ -404,14 +401,17 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide other_tokens_in_pool, bet_fee, ) + net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) + self.context.logger.info(f"Net bet amount: {net_bet_amount}") self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") - num_shares, available_shares = self._calc_binary_shares(bet_amount, win_probability, confidence, vote) + num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) # Set available shares to 1/3 of the total available shares to prevent the bot from buying all shares in this test scenario available_shares = int(available_shares / 3) + self.context.logger.info(f"Adjusted available shares: {available_shares}") if num_shares > available_shares * SLIPPAGE: self.context.logger.warning( "Kindly contemplate reducing your bet amount, as the pool's liquidity is low compared to your bet. " @@ -457,9 +457,7 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide is_profitable = potential_net_profit >= 0 and num_shares <= available_shares self.context.logger.info(f"Is profitable: {is_profitable}") shares_out = self.wei_to_native(num_shares) - self.context.logger.info(f"Shares out: {shares_out}") available_in = self.wei_to_native(available_shares) - self.context.logger.info(f"Available in: {available_in}") shares_out_of = f"{shares_out} / {available_in}" self.context.logger.info(f"Shares out of: {shares_out_of}") potential_net_profit = num_shares - bet_amount - self.mech_price - bet_threshold @@ -468,11 +466,11 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide self.context.logger.info( f"The current liquidity of the market is {bet.scaledLiquidityMeasure} xDAI. " f"The potential net profit is {self.wei_to_native(potential_net_profit)} xDAI " - f"from buying {self.wei_to_native(num_shares)} shares for the option {bet.get_outcome(vote)}.\n" + f"from buying {int(self.wei_to_native(num_shares))} shares for the option {bet.get_outcome(vote)}.\n" f"Decision for profitability of this market: {is_profitable}." ) - return is_profitable + return is_profitable, bet_amount def async_act(self) -> Generator: """Do the action.""" @@ -481,7 +479,7 @@ def async_act(self) -> Generator: vote, odds, win_probability, confidence = yield from self._get_decision() is_profitable = None if vote is not None and confidence is not None and odds is not None and win_probability is not None: - is_profitable = yield from self._is_profitable(vote, odds, win_probability, confidence) + is_profitable, bet_amount = yield from self._is_profitable(vote, odds, win_probability, confidence) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, @@ -489,6 +487,7 @@ def async_act(self) -> Generator: odds, win_probability, confidence, + bet_amount, ) yield from self.finish_behaviour(payload) diff --git a/packages/valory/skills/decision_maker_abci/payloads.py b/packages/valory/skills/decision_maker_abci/payloads.py index 89491fa1f..8b7714751 100644 --- a/packages/valory/skills/decision_maker_abci/payloads.py +++ b/packages/valory/skills/decision_maker_abci/payloads.py @@ -35,6 +35,7 @@ class DecisionReceivePayload(BaseTxPayload): odds: Optional[float] win_probability: Optional[float] confidence: Optional[float] + bet_amount: Optional[int] @dataclass(frozen=True) diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 2e749e81b..64d3d1b59 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,10 +12,10 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeifa3nzbtnpb6ixk6ftlw4x6beq3lslm6akpvfqifh4vpynlddre3i - behaviours/bet_placement.py: bafybeihbsgejf57mdcwhkt7vv7lcf6wf2hxlzctdyznr4qvymzwdohmmmi + behaviours/base.py: bafybeihikmpn6uf3sbtzsc5psgw22q3p7yt4eflb6gecwaqzdmft5em4ky + behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeigdrin6errqqomqjihj2lvryvhknl5hd5mzu6praixnfpcyw3inr4 + behaviours/decision_receive.py: bafybeififxbuus2kwsdwepbwwkqpiye3gw7vhyzpxiwhliqrn3aesdqjd4 behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga @@ -26,15 +26,15 @@ fingerprint: fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy models.py: bafybeihnpza4hibx3y6itnhpg2lgjmuh3dveby7tnarzsollofdtyajyuq - payloads.py: bafybeifjwiv2wtjur73diflcui7neclwtcu76or74udofxyvursu3rgy4i + payloads.py: bafybeid7nfq2zui2zqpw54hxx7nixuuuv5v5f5f47pxdxiwe2ow4wqwple policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm rounds.py: bafybeihopxmhzrpipc6r5x2vqf2tcixzuf5xdpqfsr7gr3n756n3ssft5q states/__init__.py: bafybeid23llnyp6j257dluxmrnztugo5llsrog7kua53hllyktz4dqhqoy - states/base.py: bafybeicbhqfspe7gnhrgabpy5ijbvkuxwjruyk3fiep64t3sjv7xvbxzry + states/base.py: bafybeifzmubtucyciyqfubzvyflst5gdmt6bdpn7ggpcu5hbmw4an77som states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeiao747i4z7owk6dmwfuzdijag55m3ryj3nowfoggvczpgk3koza44 - states/decision_receive.py: bafybeifcrtxrcvafqc6cexh7tobzedlqufp4dionb7hvc27y37gniofax4 + states/decision_receive.py: bafybeigsfhisfkdw45emrvkhpnyeymrnbqpyqumzt26xs7iqoe2u6oclby states/decision_request.py: bafybeic7otc3hjb753svbmur3yyk6szahc25yii3x4w4vcnpfz6jwvacuu states/final_states.py: bafybeidiwhuyd5zm2cq7vhv2owcrxdpm7fnvn3db6p6tql4jz5hgpalflu states/handle_failed_tx.py: bafybeihewm2vernvhktuorljdupjqcg2p5vs6wvsira2d62wkoyo5xlzjm diff --git a/packages/valory/skills/decision_maker_abci/states/base.py b/packages/valory/skills/decision_maker_abci/states/base.py index e879401d4..8b612c934 100644 --- a/packages/valory/skills/decision_maker_abci/states/base.py +++ b/packages/valory/skills/decision_maker_abci/states/base.py @@ -129,6 +129,11 @@ def win_probability(self) -> float: def confidence(self) -> float: """Get the vote's confidence.""" return float(self.db.get_strict("confidence")) + + @property + def bet_amount(self) -> int: + """Get the calculated bet amount.""" + return int(self.db.get_strict("bet_amount")) @property def is_profitable(self) -> bool: diff --git a/packages/valory/skills/decision_maker_abci/states/decision_receive.py b/packages/valory/skills/decision_maker_abci/states/decision_receive.py index baf618981..7c767beea 100644 --- a/packages/valory/skills/decision_maker_abci/states/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/states/decision_receive.py @@ -47,6 +47,7 @@ class DecisionReceiveRound(CollectSameUntilThresholdRound): get_name(SynchronizedData.odds), get_name(SynchronizedData.win_probability), get_name(SynchronizedData.confidence), + get_name(SynchronizedData.bet_amount), ) collection_key = get_name(SynchronizedData.participant_to_decision) diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 8c3eed8d7..5d9f33a38 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeieewl4yttwangroyavt4y7oirmp56g2qgvpjd4k4euipbbpjgtc5q -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieofft7qquen3sgf5os7ovdsw27yytdtcm2icfxmhy3gwcz55rj74 +- valory/decision_maker_abci:0.1.0:bafybeievapnqxbtrxmbaabdlmqzujuw5wybemtt4s6jv44tkotq3i2o2ui +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiesb2rnxpcbyqwwcwfozltoix4mzytohj7hcivc2hc7pwtbgqx2yy behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 71651566e..243ed789b 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeieewl4yttwangroyavt4y7oirmp56g2qgvpjd4k4euipbbpjgtc5q +- valory/decision_maker_abci:0.1.0:bafybeievapnqxbtrxmbaabdlmqzujuw5wybemtt4s6jv44tkotq3i2o2ui behaviours: main: args: {} From 69fda09e8720bba63a13b26c9d744d84ad88dc48 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 21 Oct 2023 09:47:36 +0200 Subject: [PATCH 43/79] fix: Use net bet amount for calculating shares --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/base.py | 1 - .../behaviours/decision_receive.py | 15 +++++++-------- .../valory/skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 21 insertions(+), 23 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 7c6afd7cb..76afb0f4e 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeievapnqxbtrxmbaabdlmqzujuw5wybemtt4s6jv44tkotq3i2o2ui", - "skill/valory/trader_abci/0.1.0": "bafybeichmlcig6qucvflhi7l5oaxllih47rs4yz325pfvzfldg7abazmha", + "skill/valory/decision_maker_abci/0.1.0": "bafybeiggfsrtagrbymnmxybca7lglw646ihr5sf4u2o3otvqretqjdgsym", + "skill/valory/trader_abci/0.1.0": "bafybeihotqqvbstpwulskeg5ldinmiaym37zybdsqhbylxhcbayzxkkuau", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeicbgf3zftgiezg33cvcp2ll6kixbi5c6ofzj6fojhbzufk4dregya", - "service/valory/trader/0.1.0": "bafybeiekdangesbgwq66npsirjhkeae7eydcvnz5brlg3estuxcixtvv4e", + "agent/valory/trader/0.1.0": "bafybeiculubuqk2jcdizvgjlhu6qxnbl4jtffcismv5mxc4wuyu6i3fafa", + "service/valory/trader/0.1.0": "bafybeianxdk2cwugiy64bmn53usvvtjtkyumx2gfcvwlfmnr6j2oonpejy", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiesb2rnxpcbyqwwcwfozltoix4mzytohj7hcivc2hc7pwtbgqx2yy", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigixjanrmuuhe5pwnys2ggyqdhd43dyiah2x2wbcvqm36wc6lycl4", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 37dc48e86..7fc14d132 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiesb2rnxpcbyqwwcwfozltoix4mzytohj7hcivc2hc7pwtbgqx2yy +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigixjanrmuuhe5pwnys2ggyqdhd43dyiah2x2wbcvqm36wc6lycl4 - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeievapnqxbtrxmbaabdlmqzujuw5wybemtt4s6jv44tkotq3i2o2ui -- valory/trader_abci:0.1.0:bafybeichmlcig6qucvflhi7l5oaxllih47rs4yz325pfvzfldg7abazmha +- valory/decision_maker_abci:0.1.0:bafybeiggfsrtagrbymnmxybca7lglw646ihr5sf4u2o3otvqretqjdgsym +- valory/trader_abci:0.1.0:bafybeihotqqvbstpwulskeg5ldinmiaym37zybdsqhbylxhcbayzxkkuau default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 2e5f1b4b1..8b536fe6f 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeicbgf3zftgiezg33cvcp2ll6kixbi5c6ofzj6fojhbzufk4dregya +agent: valory/trader:0.1.0:bafybeiculubuqk2jcdizvgjlhu6qxnbl4jtffcismv5mxc4wuyu6i3fafa number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index f1e16aef0..2dc6a9b79 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -251,7 +251,6 @@ def get_bet_amount( self.context.logger.info(f"Used trading strategy: Bet amount per confidence threshold") threshold = round(confidence, 1) bet_amount = self.params.bet_amount_per_threshold[threshold] - self.context.logger.info(f"Bet amount: {bet_amount}") return bet_amount elif strategy == "kelly_criterion": diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 028e62610..1ecfba93e 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -260,7 +260,7 @@ def _get_bet_sample_info(self, bet, vote) -> Tuple[int, int, int]: return selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee - def _calc_binary_shares(self, bet_amount: int, vote: int) -> Tuple[int, int]: + def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int]: """Calculate the claimed shares. This calculation only works for binary markets.""" bet = self.synchronized_data.sampled_bet @@ -274,7 +274,7 @@ def _calc_binary_shares(self, bet_amount: int, vote: int) -> Tuple[int, int]: # the OMEN market trades an equal amount of the investment to each of the tokens in the pool # here we calculate the bet amount per pool's token - bet_per_token = bet_amount / BINARY_N_SLOTS + bet_per_token = net_bet_amount / BINARY_N_SLOTS self.context.logger.info(f"Bet per token: {bet_per_token/(10**18)}") # calculate the number of the traded tokens @@ -370,7 +370,7 @@ def _check_balance(self) -> WaitableConditionType: self.context.logger.info(f"The safe has {native} xDAI and {collateral}.") return True - def _is_profitable(self, vote: int, odds: float, win_probability: float, confidence: float) -> bool: + def _is_profitable(self, vote: int, win_probability: float, confidence: float) -> Tuple[bool, int]: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet self.context.logger.info(f"Bet: {bet}") @@ -401,11 +401,11 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide other_tokens_in_pool, bet_fee, ) - net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) - self.context.logger.info(f"Net bet amount: {net_bet_amount}") - self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") + net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) + self.context.logger.info(f"Net bet amount: {net_bet_amount}") + num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) @@ -469,7 +469,6 @@ def _is_profitable(self, vote: int, odds: float, win_probability: float, confide f"from buying {int(self.wei_to_native(num_shares))} shares for the option {bet.get_outcome(vote)}.\n" f"Decision for profitability of this market: {is_profitable}." ) - return is_profitable, bet_amount def async_act(self) -> Generator: @@ -479,7 +478,7 @@ def async_act(self) -> Generator: vote, odds, win_probability, confidence = yield from self._get_decision() is_profitable = None if vote is not None and confidence is not None and odds is not None and win_probability is not None: - is_profitable, bet_amount = yield from self._is_profitable(vote, odds, win_probability, confidence) + is_profitable, bet_amount = yield from self._is_profitable(vote, win_probability, confidence) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 64d3d1b59..8214361fb 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,10 +12,10 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeihikmpn6uf3sbtzsc5psgw22q3p7yt4eflb6gecwaqzdmft5em4ky + behaviours/base.py: bafybeihtxmtlko56j63bvueu42rzrw27cgdyfcy72lh4pw67onouj6cisy behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeififxbuus2kwsdwepbwwkqpiye3gw7vhyzpxiwhliqrn3aesdqjd4 + behaviours/decision_receive.py: bafybeicvfil5dj2j3grqrdqsm3wxmo6caxuvix2oqt3l6hsbuegqwe4zt4 behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 5d9f33a38..03e92bcc4 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeievapnqxbtrxmbaabdlmqzujuw5wybemtt4s6jv44tkotq3i2o2ui -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiesb2rnxpcbyqwwcwfozltoix4mzytohj7hcivc2hc7pwtbgqx2yy +- valory/decision_maker_abci:0.1.0:bafybeiggfsrtagrbymnmxybca7lglw646ihr5sf4u2o3otvqretqjdgsym +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigixjanrmuuhe5pwnys2ggyqdhd43dyiah2x2wbcvqm36wc6lycl4 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 243ed789b..c8142f20b 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeievapnqxbtrxmbaabdlmqzujuw5wybemtt4s6jv44tkotq3i2o2ui +- valory/decision_maker_abci:0.1.0:bafybeiggfsrtagrbymnmxybca7lglw646ihr5sf4u2o3otvqretqjdgsym behaviours: main: args: {} From 173f4f5c1248b53f048ef566374e09a4f591d5ba Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 21 Oct 2023 10:01:11 +0200 Subject: [PATCH 44/79] fix: Initialize bet amount with default value 0 --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/decision_receive.py | 3 ++- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 15 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 76afb0f4e..065126588 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeiggfsrtagrbymnmxybca7lglw646ihr5sf4u2o3otvqretqjdgsym", - "skill/valory/trader_abci/0.1.0": "bafybeihotqqvbstpwulskeg5ldinmiaym37zybdsqhbylxhcbayzxkkuau", + "skill/valory/decision_maker_abci/0.1.0": "bafybeietvbnfhn7ezmyfmsqzkhyqqvfdm5z7eyzujlmpuzpe5psrhlx3fm", + "skill/valory/trader_abci/0.1.0": "bafybeibhwgvkvrionm46ycgtdvprdpdtt4vhjhjzvuyl6tvdm37vpasytm", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeiculubuqk2jcdizvgjlhu6qxnbl4jtffcismv5mxc4wuyu6i3fafa", - "service/valory/trader/0.1.0": "bafybeianxdk2cwugiy64bmn53usvvtjtkyumx2gfcvwlfmnr6j2oonpejy", + "agent/valory/trader/0.1.0": "bafybeicwcphx6wzgtpyl44m43pxs4vjbh6md67ha3fbwwcuaynl4t7c7hq", + "service/valory/trader/0.1.0": "bafybeiexom3xywrc7cdnecekopdtz5xemfkeil4bhiuhzeui4di4crhipy", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigixjanrmuuhe5pwnys2ggyqdhd43dyiah2x2wbcvqm36wc6lycl4", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicbatbrtf3pdir2ns77mfvctdj7c27qmmz5q7m74g6gopam4dk764", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 7fc14d132..978ce4668 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigixjanrmuuhe5pwnys2ggyqdhd43dyiah2x2wbcvqm36wc6lycl4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicbatbrtf3pdir2ns77mfvctdj7c27qmmz5q7m74g6gopam4dk764 - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiggfsrtagrbymnmxybca7lglw646ihr5sf4u2o3otvqretqjdgsym -- valory/trader_abci:0.1.0:bafybeihotqqvbstpwulskeg5ldinmiaym37zybdsqhbylxhcbayzxkkuau +- valory/decision_maker_abci:0.1.0:bafybeietvbnfhn7ezmyfmsqzkhyqqvfdm5z7eyzujlmpuzpe5psrhlx3fm +- valory/trader_abci:0.1.0:bafybeibhwgvkvrionm46ycgtdvprdpdtt4vhjhjzvuyl6tvdm37vpasytm default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 8b536fe6f..12a43fa00 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiculubuqk2jcdizvgjlhu6qxnbl4jtffcismv5mxc4wuyu6i3fafa +agent: valory/trader:0.1.0:bafybeicwcphx6wzgtpyl44m43pxs4vjbh6md67ha3fbwwcuaynl4t7c7hq number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 1ecfba93e..5b5a2dc99 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -477,7 +477,8 @@ def async_act(self) -> Generator: with self.context.benchmark_tool.measure(self.behaviour_id).local(): vote, odds, win_probability, confidence = yield from self._get_decision() is_profitable = None - if vote is not None and confidence is not None and odds is not None and win_probability is not None: + bet_amount = 0 + if vote is not None and confidence is not None and win_probability is not None: is_profitable, bet_amount = yield from self._is_profitable(vote, win_probability, confidence) payload = DecisionReceivePayload( self.context.agent_address, diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 8214361fb..a9d819852 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeihtxmtlko56j63bvueu42rzrw27cgdyfcy72lh4pw67onouj6cisy behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeicvfil5dj2j3grqrdqsm3wxmo6caxuvix2oqt3l6hsbuegqwe4zt4 + behaviours/decision_receive.py: bafybeidjirag3sy66kcjohlszaone7hilwdexlcl36wmg4sjgstma35ac4 behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 03e92bcc4..ce6b4c38f 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiggfsrtagrbymnmxybca7lglw646ihr5sf4u2o3otvqretqjdgsym -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigixjanrmuuhe5pwnys2ggyqdhd43dyiah2x2wbcvqm36wc6lycl4 +- valory/decision_maker_abci:0.1.0:bafybeietvbnfhn7ezmyfmsqzkhyqqvfdm5z7eyzujlmpuzpe5psrhlx3fm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicbatbrtf3pdir2ns77mfvctdj7c27qmmz5q7m74g6gopam4dk764 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index c8142f20b..2d15d58a7 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeiggfsrtagrbymnmxybca7lglw646ihr5sf4u2o3otvqretqjdgsym +- valory/decision_maker_abci:0.1.0:bafybeietvbnfhn7ezmyfmsqzkhyqqvfdm5z7eyzujlmpuzpe5psrhlx3fm behaviours: main: args: {} From d95d4f1588b7c7fe9543d4be80cb86cf1b3fd64a Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 21 Oct 2023 13:33:39 +0200 Subject: [PATCH 45/79] feat: Activated Kelly calc --- .../behaviours/decision_receive.py | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 5b5a2dc99..9675ca27b 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -386,21 +386,21 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - win_probability, confidence, selected_type_tokens_in_pool, - other_tokens_in_pool, + other_tokens_in_pool, bet_fee, ) - # Safety fallback to bet amount per conf threshold - # Only remove if you are sure that kelly bet amount is working as expected - bet_amount = self.get_bet_amount( - bankroll, - "bet_amount_per_conf_threshold", - win_probability, - confidence, - selected_type_tokens_in_pool, - other_tokens_in_pool, - bet_fee, - ) + # # Safety fallback to bet amount per conf threshold + # # Only remove if you are sure that kelly bet amount is working as expected + # bet_amount = self.get_bet_amount( + # bankroll, + # "bet_amount_per_conf_threshold", + # win_probability, + # confidence, + # selected_type_tokens_in_pool, + # other_tokens_in_pool, + # bet_fee, + # ) self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) From fdb3306bd665313c2a460e087897048c6ce8893c Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 21 Oct 2023 14:09:45 +0200 Subject: [PATCH 46/79] chore: Update packages --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 6 files changed, 13 insertions(+), 13 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 065126588..08064613d 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeietvbnfhn7ezmyfmsqzkhyqqvfdm5z7eyzujlmpuzpe5psrhlx3fm", - "skill/valory/trader_abci/0.1.0": "bafybeibhwgvkvrionm46ycgtdvprdpdtt4vhjhjzvuyl6tvdm37vpasytm", + "skill/valory/decision_maker_abci/0.1.0": "bafybeihd467vzpzl4pogxxlr3bsifjp6qo5uu7xkkkkevfuc2b6yi5okaa", + "skill/valory/trader_abci/0.1.0": "bafybeie5dwrob4ob3lfditiubvjtp5hh4yjtjlw3ggriyg23kk3jyqjaey", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeicwcphx6wzgtpyl44m43pxs4vjbh6md67ha3fbwwcuaynl4t7c7hq", - "service/valory/trader/0.1.0": "bafybeiexom3xywrc7cdnecekopdtz5xemfkeil4bhiuhzeui4di4crhipy", + "agent/valory/trader/0.1.0": "bafybeieuztblaw7dvwatlelul5tvmdk45eotuchnbcve45vhtp5bpbiqzm", + "service/valory/trader/0.1.0": "bafybeibj6iafddluegyldqilz6pt5svux3q2rycezdxlrnt73wvfqrwm3a", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicbatbrtf3pdir2ns77mfvctdj7c27qmmz5q7m74g6gopam4dk764", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeignqppsmqns3ncoi7cb3en5r6mo74363it4uojnxemdwxjrvbxwpi", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 978ce4668..dff2a6f4e 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicbatbrtf3pdir2ns77mfvctdj7c27qmmz5q7m74g6gopam4dk764 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeignqppsmqns3ncoi7cb3en5r6mo74363it4uojnxemdwxjrvbxwpi - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeietvbnfhn7ezmyfmsqzkhyqqvfdm5z7eyzujlmpuzpe5psrhlx3fm -- valory/trader_abci:0.1.0:bafybeibhwgvkvrionm46ycgtdvprdpdtt4vhjhjzvuyl6tvdm37vpasytm +- valory/decision_maker_abci:0.1.0:bafybeihd467vzpzl4pogxxlr3bsifjp6qo5uu7xkkkkevfuc2b6yi5okaa +- valory/trader_abci:0.1.0:bafybeie5dwrob4ob3lfditiubvjtp5hh4yjtjlw3ggriyg23kk3jyqjaey default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 12a43fa00..d55c46057 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeicwcphx6wzgtpyl44m43pxs4vjbh6md67ha3fbwwcuaynl4t7c7hq +agent: valory/trader:0.1.0:bafybeieuztblaw7dvwatlelul5tvmdk45eotuchnbcve45vhtp5bpbiqzm number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index a9d819852..e93fa21cc 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeihtxmtlko56j63bvueu42rzrw27cgdyfcy72lh4pw67onouj6cisy behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeidjirag3sy66kcjohlszaone7hilwdexlcl36wmg4sjgstma35ac4 + behaviours/decision_receive.py: bafybeiapvf3yczclpo6bjlkvpliq5vtndn4ajmlx5qq6j4e5xuymjn7vay behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index ce6b4c38f..a18bb805f 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeietvbnfhn7ezmyfmsqzkhyqqvfdm5z7eyzujlmpuzpe5psrhlx3fm -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicbatbrtf3pdir2ns77mfvctdj7c27qmmz5q7m74g6gopam4dk764 +- valory/decision_maker_abci:0.1.0:bafybeihd467vzpzl4pogxxlr3bsifjp6qo5uu7xkkkkevfuc2b6yi5okaa +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeignqppsmqns3ncoi7cb3en5r6mo74363it4uojnxemdwxjrvbxwpi behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 2d15d58a7..31be3ac6a 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeietvbnfhn7ezmyfmsqzkhyqqvfdm5z7eyzujlmpuzpe5psrhlx3fm +- valory/decision_maker_abci:0.1.0:bafybeihd467vzpzl4pogxxlr3bsifjp6qo5uu7xkkkkevfuc2b6yi5okaa behaviours: main: args: {} From 4112aa034c409081fa4dad34aa6c461153842cdc Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 21 Oct 2023 18:47:32 +0200 Subject: [PATCH 47/79] refactor: Add log for payload values --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 18 +++++++++--------- .../behaviours/decision_request.py | 6 ++++++ .../skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 29 insertions(+), 23 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 08064613d..ab186d18e 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeihd467vzpzl4pogxxlr3bsifjp6qo5uu7xkkkkevfuc2b6yi5okaa", - "skill/valory/trader_abci/0.1.0": "bafybeie5dwrob4ob3lfditiubvjtp5hh4yjtjlw3ggriyg23kk3jyqjaey", + "skill/valory/decision_maker_abci/0.1.0": "bafybeic2crikcpbebygr2j4bh5dhzmpz5m6e7vx6uygfqkmbrhtja3tspq", + "skill/valory/trader_abci/0.1.0": "bafybeid6xo6qbv36524hwoq4gmf2jmnu2yvvwymhn4nho4vde2tksre6za", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeieuztblaw7dvwatlelul5tvmdk45eotuchnbcve45vhtp5bpbiqzm", - "service/valory/trader/0.1.0": "bafybeibj6iafddluegyldqilz6pt5svux3q2rycezdxlrnt73wvfqrwm3a", + "agent/valory/trader/0.1.0": "bafybeiaczvjktyqcr4y5nh2e7skp5gfitf3bkc4our5qnrrsu5x6rercvu", + "service/valory/trader/0.1.0": "bafybeiautoecmov22hpxdsd6irumforatcwd2zhvhcorl6uxebfahd53c4", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeignqppsmqns3ncoi7cb3en5r6mo74363it4uojnxemdwxjrvbxwpi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiaozbpbgybhvjepehqigsxxzpxurkpmg54zmn42nqfycjdt2p6ziu", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index dff2a6f4e..6c41ef876 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeignqppsmqns3ncoi7cb3en5r6mo74363it4uojnxemdwxjrvbxwpi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiaozbpbgybhvjepehqigsxxzpxurkpmg54zmn42nqfycjdt2p6ziu - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeihd467vzpzl4pogxxlr3bsifjp6qo5uu7xkkkkevfuc2b6yi5okaa -- valory/trader_abci:0.1.0:bafybeie5dwrob4ob3lfditiubvjtp5hh4yjtjlw3ggriyg23kk3jyqjaey +- valory/decision_maker_abci:0.1.0:bafybeic2crikcpbebygr2j4bh5dhzmpz5m6e7vx6uygfqkmbrhtja3tspq +- valory/trader_abci:0.1.0:bafybeid6xo6qbv36524hwoq4gmf2jmnu2yvvwymhn4nho4vde2tksre6za default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index d55c46057..f5703293a 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeieuztblaw7dvwatlelul5tvmdk45eotuchnbcve45vhtp5bpbiqzm +agent: valory/trader:0.1.0:bafybeiaczvjktyqcr4y5nh2e7skp5gfitf3bkc4our5qnrrsu5x6rercvu number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 9675ca27b..3751f66d0 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -284,43 +284,43 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] if prices is None: return 0, 0 tokens_traded = [int(bet_per_token / prices[i]) for i in range(BINARY_N_SLOTS)] - self.context.logger.info(f"Tokens traded: {[x/(10**18) for x in tokens_traded]}") + self.context.logger.info(f"Tokens traded: {[x for x in tokens_traded]}") # get the shares for the answer that the service has selected selected_shares = tokens_traded.pop(vote) - self.context.logger.info(f"Selected shares: {selected_shares/(10**18)}") + self.context.logger.info(f"Selected shares: {selected_shares}") # get the shares for the opposite answer other_shares = tokens_traded.pop() - self.context.logger.info(f"Other shares: {other_shares/(10**18)}") + self.context.logger.info(f"Other shares: {other_shares}") # get the number of tokens in the pool for the answer that the service has selected selected_type_tokens_in_pool = token_amounts.pop(vote) - self.context.logger.info(f"Selected type tokens in pool: {selected_type_tokens_in_pool/(10**18)}") + self.context.logger.info(f"Selected type tokens in pool: {selected_type_tokens_in_pool}") # get the number of tokens in the pool for the opposite answer other_tokens_in_pool = token_amounts.pop() - self.context.logger.info(f"Other tokens in pool: {other_tokens_in_pool/(10**18)}") + self.context.logger.info(f"Other tokens in pool: {other_tokens_in_pool}") # the OMEN market then trades the opposite tokens to the tokens of the answer that has been selected, # preserving the balance of the pool # here we calculate the number of shares that we get after trading the tokens for the opposite answer tokens_remaining_in_pool = int(k / (other_tokens_in_pool + other_shares)) - self.context.logger.info(f"Tokens remaining in pool: {tokens_remaining_in_pool/(10**18)}") + self.context.logger.info(f"Tokens remaining in pool: {tokens_remaining_in_pool}") swapped_shares = selected_type_tokens_in_pool - tokens_remaining_in_pool - self.context.logger.info(f"Swapped shares: {int(swapped_shares/(10**18))}") + self.context.logger.info(f"Swapped shares: {swapped_shares}") # calculate the resulting number of shares if the service would take that position num_shares = selected_shares + swapped_shares - self.context.logger.info(f"Number of shares: {int(num_shares/(10**18))}") + self.context.logger.info(f"Number of shares: {num_shares}") # calculate the available number of shares price = prices[vote] self.context.logger.info(f"Price: {prices[vote]}") available_shares = int(selected_type_tokens_in_pool * price) - self.context.logger.info(f"Available shares: {available_shares/(10**18)}") + self.context.logger.info(f"Available shares: {available_shares}") return num_shares, available_shares diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py index 4039b174f..4c42f9c64 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py @@ -302,5 +302,11 @@ def async_act(self) -> Generator: mech_tx_hex = yield from self._prepare_safe_tx() price = self.price agent = self.context.agent_address + # log the payload + self.context.logger.info( + f"Sending request to mech with payload: { + agent, tx_submitter, mech_tx_hex, price + }" + ) payload = RequestPayload(agent, tx_submitter, mech_tx_hex, price) yield from self.finish_behaviour(payload) diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index e93fa21cc..4de2a9492 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,8 +15,8 @@ fingerprint: behaviours/base.py: bafybeihtxmtlko56j63bvueu42rzrw27cgdyfcy72lh4pw67onouj6cisy behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeiapvf3yczclpo6bjlkvpliq5vtndn4ajmlx5qq6j4e5xuymjn7vay - behaviours/decision_request.py: bafybeiajbv3t6w4vz3u3bbqzaufjfi2znwsly4cvf55farwvp7y7c2jefm + behaviours/decision_receive.py: bafybeiew7l4fn7u2u22alc7f4abqo6up7izls4k3nwzo2pg57e6brfgzk4 + behaviours/decision_request.py: bafybeicwz3ob2glidp4syylscwrqmecwnvf3esnhotpsh4goxwohriijxy behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index a18bb805f..218350670 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeihd467vzpzl4pogxxlr3bsifjp6qo5uu7xkkkkevfuc2b6yi5okaa -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeignqppsmqns3ncoi7cb3en5r6mo74363it4uojnxemdwxjrvbxwpi +- valory/decision_maker_abci:0.1.0:bafybeic2crikcpbebygr2j4bh5dhzmpz5m6e7vx6uygfqkmbrhtja3tspq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiaozbpbgybhvjepehqigsxxzpxurkpmg54zmn42nqfycjdt2p6ziu behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 31be3ac6a..7550b4117 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeihd467vzpzl4pogxxlr3bsifjp6qo5uu7xkkkkevfuc2b6yi5okaa +- valory/decision_maker_abci:0.1.0:bafybeic2crikcpbebygr2j4bh5dhzmpz5m6e7vx6uygfqkmbrhtja3tspq behaviours: main: args: {} From eff5d12913a362578abf65a301656b2e19c0bdbf Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 21 Oct 2023 19:14:18 +0200 Subject: [PATCH 48/79] fix: Adjusted log string --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/decision_request.py | 4 +--- packages/valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 14 insertions(+), 16 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index ab186d18e..423928b66 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeic2crikcpbebygr2j4bh5dhzmpz5m6e7vx6uygfqkmbrhtja3tspq", - "skill/valory/trader_abci/0.1.0": "bafybeid6xo6qbv36524hwoq4gmf2jmnu2yvvwymhn4nho4vde2tksre6za", + "skill/valory/decision_maker_abci/0.1.0": "bafybeihcmpkvsqheb7ghwmfvkqfkay7k5nnzco7ic3cjmwm6apwv3g6fkq", + "skill/valory/trader_abci/0.1.0": "bafybeihed3vu52x4fbo2klwiwgkgpxvviunpywhguquf4gwe3i2nappv6a", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeiaczvjktyqcr4y5nh2e7skp5gfitf3bkc4our5qnrrsu5x6rercvu", - "service/valory/trader/0.1.0": "bafybeiautoecmov22hpxdsd6irumforatcwd2zhvhcorl6uxebfahd53c4", + "agent/valory/trader/0.1.0": "bafybeia4fbw37wbleo4jd2vklmw3bljfypnnuwfzhtgogtrsonzolq2y54", + "service/valory/trader/0.1.0": "bafybeifknjmgvnz62pl266qnxrsk2vttz4hsarkugkfwjmwy7y6cann7se", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiaozbpbgybhvjepehqigsxxzpxurkpmg54zmn42nqfycjdt2p6ziu", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeienj6rwalsbvzvms6i2wyiludpn5doeoqhvqyjvmq5sqoxjmcjvvi", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 6c41ef876..50395a7a9 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiaozbpbgybhvjepehqigsxxzpxurkpmg54zmn42nqfycjdt2p6ziu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeienj6rwalsbvzvms6i2wyiludpn5doeoqhvqyjvmq5sqoxjmcjvvi - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeic2crikcpbebygr2j4bh5dhzmpz5m6e7vx6uygfqkmbrhtja3tspq -- valory/trader_abci:0.1.0:bafybeid6xo6qbv36524hwoq4gmf2jmnu2yvvwymhn4nho4vde2tksre6za +- valory/decision_maker_abci:0.1.0:bafybeihcmpkvsqheb7ghwmfvkqfkay7k5nnzco7ic3cjmwm6apwv3g6fkq +- valory/trader_abci:0.1.0:bafybeihed3vu52x4fbo2klwiwgkgpxvviunpywhguquf4gwe3i2nappv6a default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index f5703293a..4c1a70ad8 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiaczvjktyqcr4y5nh2e7skp5gfitf3bkc4our5qnrrsu5x6rercvu +agent: valory/trader:0.1.0:bafybeia4fbw37wbleo4jd2vklmw3bljfypnnuwfzhtgogtrsonzolq2y54 number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py index 4c42f9c64..fe90dfdc3 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py @@ -304,9 +304,7 @@ def async_act(self) -> Generator: agent = self.context.agent_address # log the payload self.context.logger.info( - f"Sending request to mech with payload: { - agent, tx_submitter, mech_tx_hex, price - }" + f"Sending request to mech with payload: {agent, tx_submitter, mech_tx_hex, price}" ) payload = RequestPayload(agent, tx_submitter, mech_tx_hex, price) yield from self.finish_behaviour(payload) diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 4de2a9492..b8364892a 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -16,7 +16,7 @@ fingerprint: behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm behaviours/decision_receive.py: bafybeiew7l4fn7u2u22alc7f4abqo6up7izls4k3nwzo2pg57e6brfgzk4 - behaviours/decision_request.py: bafybeicwz3ob2glidp4syylscwrqmecwnvf3esnhotpsh4goxwohriijxy + behaviours/decision_request.py: bafybeift3ec4uwsccvx7ehtmpypsq7w2625qspbpvu7t2iyv6hdv2scxly behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 218350670..0d0ccfccb 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeic2crikcpbebygr2j4bh5dhzmpz5m6e7vx6uygfqkmbrhtja3tspq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiaozbpbgybhvjepehqigsxxzpxurkpmg54zmn42nqfycjdt2p6ziu +- valory/decision_maker_abci:0.1.0:bafybeihcmpkvsqheb7ghwmfvkqfkay7k5nnzco7ic3cjmwm6apwv3g6fkq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeienj6rwalsbvzvms6i2wyiludpn5doeoqhvqyjvmq5sqoxjmcjvvi behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 7550b4117..d922163be 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeic2crikcpbebygr2j4bh5dhzmpz5m6e7vx6uygfqkmbrhtja3tspq +- valory/decision_maker_abci:0.1.0:bafybeihcmpkvsqheb7ghwmfvkqfkay7k5nnzco7ic3cjmwm6apwv3g6fkq behaviours: main: args: {} From 8373687771704d354fb5515ec2857233fb39d1a8 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 22 Oct 2023 07:51:46 +0200 Subject: [PATCH 49/79] refactor: Add threshold for minimum bankroll after kelly bet --- packages/packages.json | 10 ++++----- packages/valory/agents/trader/aea-config.yaml | 6 ++--- packages/valory/services/trader/service.yaml | 2 +- .../decision_maker_abci/behaviours/base.py | 4 +++- .../behaviours/decision_receive.py | 22 +++++++++---------- .../skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 28 insertions(+), 26 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 423928b66..53b16776d 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeihcmpkvsqheb7ghwmfvkqfkay7k5nnzco7ic3cjmwm6apwv3g6fkq", - "skill/valory/trader_abci/0.1.0": "bafybeihed3vu52x4fbo2klwiwgkgpxvviunpywhguquf4gwe3i2nappv6a", + "skill/valory/decision_maker_abci/0.1.0": "bafybeifjazvbwo44z4mjtit4w7n2svujxyxdpq2cyulijiswclvm5psele", + "skill/valory/trader_abci/0.1.0": "bafybeiciv5s7uhthsthwy44fsnv2jp4gy522hbbva2hhddgjzi2vcka52m", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeia4fbw37wbleo4jd2vklmw3bljfypnnuwfzhtgogtrsonzolq2y54", - "service/valory/trader/0.1.0": "bafybeifknjmgvnz62pl266qnxrsk2vttz4hsarkugkfwjmwy7y6cann7se", + "agent/valory/trader/0.1.0": "bafybeih6pou273n5wnvrl6xjjtq7faox2rfqqlxfhs5ylnv67qebvqjrmm", + "service/valory/trader/0.1.0": "bafybeicdfb5rhft2dzb2sfuydwleekpo77gw3a2qna5d5ruayga7jcvg5i", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeienj6rwalsbvzvms6i2wyiludpn5doeoqhvqyjvmq5sqoxjmcjvvi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicyoze6fasbkthbs2lbyfkpkv3ug36yx2w4cg52qrq445b5ojxdji", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 50395a7a9..9c36111ac 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeienj6rwalsbvzvms6i2wyiludpn5doeoqhvqyjvmq5sqoxjmcjvvi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicyoze6fasbkthbs2lbyfkpkv3ug36yx2w4cg52qrq445b5ojxdji - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeihcmpkvsqheb7ghwmfvkqfkay7k5nnzco7ic3cjmwm6apwv3g6fkq -- valory/trader_abci:0.1.0:bafybeihed3vu52x4fbo2klwiwgkgpxvviunpywhguquf4gwe3i2nappv6a +- valory/decision_maker_abci:0.1.0:bafybeifjazvbwo44z4mjtit4w7n2svujxyxdpq2cyulijiswclvm5psele +- valory/trader_abci:0.1.0:bafybeiciv5s7uhthsthwy44fsnv2jp4gy522hbbva2hhddgjzi2vcka52m default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 4c1a70ad8..025fb770b 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeia4fbw37wbleo4jd2vklmw3bljfypnnuwfzhtgogtrsonzolq2y54 +agent: valory/trader:0.1.0:bafybeih6pou273n5wnvrl6xjjtq7faox2rfqqlxfhs5ylnv67qebvqjrmm number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 2dc6a9b79..01069c1eb 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -256,6 +256,7 @@ def get_bet_amount( elif strategy == "kelly_criterion": self.context.logger.info(f"Used trading strategy: Kelly Criterion") bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade + bankroll_adj = bankroll - 500000000000000000 # keep 0.5 xDAI in the bankroll fee_fraction = 1 - self.wei_to_native(bet_fee) self.context.logger.info(f"Fee fraction: {fee_fraction}") kelly_bet_amount = self._calculate_kelly_bet_amount( @@ -263,9 +264,10 @@ def get_bet_amount( other_tokens_in_pool, win_probability, confidence, - bankroll, + bankroll_adj, fee_fraction, ) + if kelly_bet_amount == None: return 0 if kelly_bet_amount < 0: diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 3751f66d0..2dc17bf15 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -390,17 +390,17 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - bet_fee, ) - # # Safety fallback to bet amount per conf threshold - # # Only remove if you are sure that kelly bet amount is working as expected - # bet_amount = self.get_bet_amount( - # bankroll, - # "bet_amount_per_conf_threshold", - # win_probability, - # confidence, - # selected_type_tokens_in_pool, - # other_tokens_in_pool, - # bet_fee, - # ) + # Safety fallback to bet amount per conf threshold + # Only remove if you are sure that kelly bet amount is working as expected + bet_amount = self.get_bet_amount( + bankroll, + "bet_amount_per_conf_threshold", + win_probability, + confidence, + selected_type_tokens_in_pool, + other_tokens_in_pool, + bet_fee, + ) self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index b8364892a..1a4498158 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,10 +12,10 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeihtxmtlko56j63bvueu42rzrw27cgdyfcy72lh4pw67onouj6cisy + behaviours/base.py: bafybeih5euy77qdwt3w22s2mkh4as53jcbx67sac6quludtxdxlj4cjoly behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeiew7l4fn7u2u22alc7f4abqo6up7izls4k3nwzo2pg57e6brfgzk4 + behaviours/decision_receive.py: bafybeiendfww3pyjc6becickyu6utssw4bq2mjeyh2w546ty3m4zum4e4e behaviours/decision_request.py: bafybeift3ec4uwsccvx7ehtmpypsq7w2625qspbpvu7t2iyv6hdv2scxly behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 0d0ccfccb..bd70c61a0 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeihcmpkvsqheb7ghwmfvkqfkay7k5nnzco7ic3cjmwm6apwv3g6fkq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeienj6rwalsbvzvms6i2wyiludpn5doeoqhvqyjvmq5sqoxjmcjvvi +- valory/decision_maker_abci:0.1.0:bafybeifjazvbwo44z4mjtit4w7n2svujxyxdpq2cyulijiswclvm5psele +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicyoze6fasbkthbs2lbyfkpkv3ug36yx2w4cg52qrq445b5ojxdji behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index d922163be..284561fa5 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeihcmpkvsqheb7ghwmfvkqfkay7k5nnzco7ic3cjmwm6apwv3g6fkq +- valory/decision_maker_abci:0.1.0:bafybeifjazvbwo44z4mjtit4w7n2svujxyxdpq2cyulijiswclvm5psele behaviours: main: args: {} From 031472ec740d9bd30bade61e2fa8aba24eccf178 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 22 Oct 2023 08:14:00 +0200 Subject: [PATCH 50/79] refactor: Add log for adjusted bankroll and make floor bankroll a variable --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/base.py | 12 ++++++++++-- .../valory/skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 23 insertions(+), 15 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 53b16776d..06a55f7dd 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeifjazvbwo44z4mjtit4w7n2svujxyxdpq2cyulijiswclvm5psele", - "skill/valory/trader_abci/0.1.0": "bafybeiciv5s7uhthsthwy44fsnv2jp4gy522hbbva2hhddgjzi2vcka52m", + "skill/valory/decision_maker_abci/0.1.0": "bafybeifyojpilkhpmcr6kfjudqjm3wy6ptmfqdfdr2qwfezkzazabuj4cq", + "skill/valory/trader_abci/0.1.0": "bafybeiaby25cfwwhfxwaiihxeorexp3fzkvbghhrouc2px3o3xkzomwpoa", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeih6pou273n5wnvrl6xjjtq7faox2rfqqlxfhs5ylnv67qebvqjrmm", - "service/valory/trader/0.1.0": "bafybeicdfb5rhft2dzb2sfuydwleekpo77gw3a2qna5d5ruayga7jcvg5i", + "agent/valory/trader/0.1.0": "bafybeif4f56ihsevlot6fijextsfmgh5cccmtxjyulrsxvjxzxsslj3cpu", + "service/valory/trader/0.1.0": "bafybeiesayf3a4p26uji7rb5ztgv3oy4e672i3bj5af7pypaipggada74m", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeicyoze6fasbkthbs2lbyfkpkv3ug36yx2w4cg52qrq445b5ojxdji", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeih27pqrh2d3n7ds2ibibdvc22hdzl5h64ejrnkdni52aconroa7x4", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 9c36111ac..0d26339a8 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicyoze6fasbkthbs2lbyfkpkv3ug36yx2w4cg52qrq445b5ojxdji +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeih27pqrh2d3n7ds2ibibdvc22hdzl5h64ejrnkdni52aconroa7x4 - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeifjazvbwo44z4mjtit4w7n2svujxyxdpq2cyulijiswclvm5psele -- valory/trader_abci:0.1.0:bafybeiciv5s7uhthsthwy44fsnv2jp4gy522hbbva2hhddgjzi2vcka52m +- valory/decision_maker_abci:0.1.0:bafybeifyojpilkhpmcr6kfjudqjm3wy6ptmfqdfdr2qwfezkzazabuj4cq +- valory/trader_abci:0.1.0:bafybeiaby25cfwwhfxwaiihxeorexp3fzkvbghhrouc2px3o3xkzomwpoa default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 025fb770b..e2cfea69c 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeih6pou273n5wnvrl6xjjtq7faox2rfqqlxfhs5ylnv67qebvqjrmm +agent: valory/trader:0.1.0:bafybeif4f56ihsevlot6fijextsfmgh5cccmtxjyulrsxvjxzxsslj3cpu number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 01069c1eb..1f8af74ba 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -255,8 +255,16 @@ def get_bet_amount( elif strategy == "kelly_criterion": self.context.logger.info(f"Used trading strategy: Kelly Criterion") - bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of xDAI available to trade - bankroll_adj = bankroll - 500000000000000000 # keep 0.5 xDAI in the bankroll + bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of DAI available to trade + floor_balance = 500000000000000000 + bankroll_adj = bankroll - floor_balance # keep 0.5 xDAI in the bankroll + self.context.logger.info(f"Adjusted bankroll: {bankroll_adj} DAI") + if bankroll_adj <= 0: + self.context.logger.info( + f"Bankroll is less than {floor_balance}: {bankroll_adj}. Set bet amount to 0." + f"Top up safe with DAI or wait for redeeming." + ) + return 0 fee_fraction = 1 - self.wei_to_native(bet_fee) self.context.logger.info(f"Fee fraction: {fee_fraction}") kelly_bet_amount = self._calculate_kelly_bet_amount( diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 1a4498158..37aafb16e 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,7 +12,7 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeih5euy77qdwt3w22s2mkh4as53jcbx67sac6quludtxdxlj4cjoly + behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm behaviours/decision_receive.py: bafybeiendfww3pyjc6becickyu6utssw4bq2mjeyh2w546ty3m4zum4e4e diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index bd70c61a0..bb40eabc6 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeifjazvbwo44z4mjtit4w7n2svujxyxdpq2cyulijiswclvm5psele -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeicyoze6fasbkthbs2lbyfkpkv3ug36yx2w4cg52qrq445b5ojxdji +- valory/decision_maker_abci:0.1.0:bafybeifyojpilkhpmcr6kfjudqjm3wy6ptmfqdfdr2qwfezkzazabuj4cq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeih27pqrh2d3n7ds2ibibdvc22hdzl5h64ejrnkdni52aconroa7x4 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 284561fa5..d85c9a7fe 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeifjazvbwo44z4mjtit4w7n2svujxyxdpq2cyulijiswclvm5psele +- valory/decision_maker_abci:0.1.0:bafybeifyojpilkhpmcr6kfjudqjm3wy6ptmfqdfdr2qwfezkzazabuj4cq behaviours: main: args: {} From efff0c78bb10bde4ffc8ad4001affd89bbaaeef9 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 22 Oct 2023 08:24:04 +0200 Subject: [PATCH 51/79] feat: Activate kelly bet strategy --- packages/packages.json | 10 ++++----- packages/valory/agents/trader/aea-config.yaml | 6 ++--- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 22 +++++++++---------- .../skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 24 insertions(+), 24 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 06a55f7dd..462926d2f 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeifyojpilkhpmcr6kfjudqjm3wy6ptmfqdfdr2qwfezkzazabuj4cq", - "skill/valory/trader_abci/0.1.0": "bafybeiaby25cfwwhfxwaiihxeorexp3fzkvbghhrouc2px3o3xkzomwpoa", + "skill/valory/decision_maker_abci/0.1.0": "bafybeibuwkc76sko3oojspxv2s3fjtahaxfb6slz3flb3lcdv75m4k4zce", + "skill/valory/trader_abci/0.1.0": "bafybeielgbp4xaortxlcpjl5p6lknvogijusckwph3sz6l3fiwhtyubnlu", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeif4f56ihsevlot6fijextsfmgh5cccmtxjyulrsxvjxzxsslj3cpu", - "service/valory/trader/0.1.0": "bafybeiesayf3a4p26uji7rb5ztgv3oy4e672i3bj5af7pypaipggada74m", + "agent/valory/trader/0.1.0": "bafybeicu62uobww5rrkqkpfgfadi3pucsyksro62y2cdeg6ef36hgjo4hy", + "service/valory/trader/0.1.0": "bafybeih45bzt7tfinaqb3fxdwhg6thmfevhvpi3yoboy4nxoo44sud3rpq", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeih27pqrh2d3n7ds2ibibdvc22hdzl5h64ejrnkdni52aconroa7x4", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigdmzlilolxfn7fuoui7xtn3gxzc4a3r6ehz7twi7cnigpefwtndu", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 0d26339a8..c7ab9642c 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeih27pqrh2d3n7ds2ibibdvc22hdzl5h64ejrnkdni52aconroa7x4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigdmzlilolxfn7fuoui7xtn3gxzc4a3r6ehz7twi7cnigpefwtndu - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeifyojpilkhpmcr6kfjudqjm3wy6ptmfqdfdr2qwfezkzazabuj4cq -- valory/trader_abci:0.1.0:bafybeiaby25cfwwhfxwaiihxeorexp3fzkvbghhrouc2px3o3xkzomwpoa +- valory/decision_maker_abci:0.1.0:bafybeibuwkc76sko3oojspxv2s3fjtahaxfb6slz3flb3lcdv75m4k4zce +- valory/trader_abci:0.1.0:bafybeielgbp4xaortxlcpjl5p6lknvogijusckwph3sz6l3fiwhtyubnlu default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index e2cfea69c..fbb436b8e 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeif4f56ihsevlot6fijextsfmgh5cccmtxjyulrsxvjxzxsslj3cpu +agent: valory/trader:0.1.0:bafybeicu62uobww5rrkqkpfgfadi3pucsyksro62y2cdeg6ef36hgjo4hy number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 2dc17bf15..3751f66d0 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -390,17 +390,17 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - bet_fee, ) - # Safety fallback to bet amount per conf threshold - # Only remove if you are sure that kelly bet amount is working as expected - bet_amount = self.get_bet_amount( - bankroll, - "bet_amount_per_conf_threshold", - win_probability, - confidence, - selected_type_tokens_in_pool, - other_tokens_in_pool, - bet_fee, - ) + # # Safety fallback to bet amount per conf threshold + # # Only remove if you are sure that kelly bet amount is working as expected + # bet_amount = self.get_bet_amount( + # bankroll, + # "bet_amount_per_conf_threshold", + # win_probability, + # confidence, + # selected_type_tokens_in_pool, + # other_tokens_in_pool, + # bet_fee, + # ) self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 37aafb16e..71a375f19 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeiendfww3pyjc6becickyu6utssw4bq2mjeyh2w546ty3m4zum4e4e + behaviours/decision_receive.py: bafybeiew7l4fn7u2u22alc7f4abqo6up7izls4k3nwzo2pg57e6brfgzk4 behaviours/decision_request.py: bafybeift3ec4uwsccvx7ehtmpypsq7w2625qspbpvu7t2iyv6hdv2scxly behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index bb40eabc6..9de192895 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeifyojpilkhpmcr6kfjudqjm3wy6ptmfqdfdr2qwfezkzazabuj4cq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeih27pqrh2d3n7ds2ibibdvc22hdzl5h64ejrnkdni52aconroa7x4 +- valory/decision_maker_abci:0.1.0:bafybeibuwkc76sko3oojspxv2s3fjtahaxfb6slz3flb3lcdv75m4k4zce +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigdmzlilolxfn7fuoui7xtn3gxzc4a3r6ehz7twi7cnigpefwtndu behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index d85c9a7fe..edba63f07 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeifyojpilkhpmcr6kfjudqjm3wy6ptmfqdfdr2qwfezkzazabuj4cq +- valory/decision_maker_abci:0.1.0:bafybeibuwkc76sko3oojspxv2s3fjtahaxfb6slz3flb3lcdv75m4k4zce behaviours: main: args: {} From 4f69d83fefed22730d90bbf68934136b2352a879 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 22 Oct 2023 09:34:35 +0200 Subject: [PATCH 52/79] refactor: Add loging for decision receive payload and sync data --- packages/packages.json | 10 ++++----- packages/valory/agents/trader/aea-config.yaml | 6 ++--- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 22 +++++++++++++++++++ .../skills/decision_maker_abci/skill.yaml | 4 ++-- .../states/decision_receive.py | 5 +++++ packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 41 insertions(+), 14 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 462926d2f..1555b49c2 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeibuwkc76sko3oojspxv2s3fjtahaxfb6slz3flb3lcdv75m4k4zce", - "skill/valory/trader_abci/0.1.0": "bafybeielgbp4xaortxlcpjl5p6lknvogijusckwph3sz6l3fiwhtyubnlu", + "skill/valory/decision_maker_abci/0.1.0": "bafybeiapv52i3mkxwfhgqlgqvzw3uuifzbwt7oiuwrb6xh62fnnrbkjcne", + "skill/valory/trader_abci/0.1.0": "bafybeibxgl5fc2ychrhkukmpharb6rpnwjahhmmtdqtdxb75ktfullpbgi", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeicu62uobww5rrkqkpfgfadi3pucsyksro62y2cdeg6ef36hgjo4hy", - "service/valory/trader/0.1.0": "bafybeih45bzt7tfinaqb3fxdwhg6thmfevhvpi3yoboy4nxoo44sud3rpq", + "agent/valory/trader/0.1.0": "bafybeie6sa36tta3kxq3f36nqxtch5tudhlajga3coqehb6teasub424na", + "service/valory/trader/0.1.0": "bafybeie6ujrnmevajc6hqi6hcdkwa5fso2jt4hxewgwzzft2uiv4gdyq3a", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigdmzlilolxfn7fuoui7xtn3gxzc4a3r6ehz7twi7cnigpefwtndu", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeif2halgb2eg2v47ddk3nc5axcir5vhkefhgjaj22d7v7gdtj7xnuy", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index c7ab9642c..b0cdd56c1 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigdmzlilolxfn7fuoui7xtn3gxzc4a3r6ehz7twi7cnigpefwtndu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeif2halgb2eg2v47ddk3nc5axcir5vhkefhgjaj22d7v7gdtj7xnuy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibuwkc76sko3oojspxv2s3fjtahaxfb6slz3flb3lcdv75m4k4zce -- valory/trader_abci:0.1.0:bafybeielgbp4xaortxlcpjl5p6lknvogijusckwph3sz6l3fiwhtyubnlu +- valory/decision_maker_abci:0.1.0:bafybeiapv52i3mkxwfhgqlgqvzw3uuifzbwt7oiuwrb6xh62fnnrbkjcne +- valory/trader_abci:0.1.0:bafybeibxgl5fc2ychrhkukmpharb6rpnwjahhmmtdqtdxb75ktfullpbgi default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index fbb436b8e..791eacbec 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeicu62uobww5rrkqkpfgfadi3pucsyksro62y2cdeg6ef36hgjo4hy +agent: valory/trader:0.1.0:bafybeie6sa36tta3kxq3f36nqxtch5tudhlajga3coqehb6teasub424na number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 3751f66d0..75ddd2059 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -479,7 +479,29 @@ def async_act(self) -> Generator: is_profitable = None bet_amount = 0 if vote is not None and confidence is not None and win_probability is not None: + self.context.logger.info( + "All should be not none:" + f"Vote: {vote}" + f"Odds: {odds}" + f"Win probability: {win_probability}" + f"Confidence: {confidence}" + ) is_profitable, bet_amount = yield from self._is_profitable(vote, win_probability, confidence) + self.context.logger.info( + "Resulting profitability and bet amount:" + f"Is profitable: {is_profitable}" + f"Bet amount: {bet_amount}" + ) + self.context.logger.info( + "Give to DecisionReceivePayload:" + f"Agent address: {self.context.agent_address}" + f"Is profitable: {is_profitable}" + f"Vote: {vote}" + f"Odds: {odds}" + f"Win probability: {win_probability}" + f"Confidence: {confidence}" + f"Bet amount: {bet_amount}" + ) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 71a375f19..04d44641a 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeiew7l4fn7u2u22alc7f4abqo6up7izls4k3nwzo2pg57e6brfgzk4 + behaviours/decision_receive.py: bafybeidxxqxw7alt64kvgyrbxkxzuljvvcc6pbbxrq2xfnitnpgifrryve behaviours/decision_request.py: bafybeift3ec4uwsccvx7ehtmpypsq7w2625qspbpvu7t2iyv6hdv2scxly behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga @@ -34,7 +34,7 @@ fingerprint: states/base.py: bafybeifzmubtucyciyqfubzvyflst5gdmt6bdpn7ggpcu5hbmw4an77som states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeiao747i4z7owk6dmwfuzdijag55m3ryj3nowfoggvczpgk3koza44 - states/decision_receive.py: bafybeigsfhisfkdw45emrvkhpnyeymrnbqpyqumzt26xs7iqoe2u6oclby + states/decision_receive.py: bafybeiethamxxrj2pdb6gbv5g4znbh37k6zfsdzp6biabmls47rmtelx2u states/decision_request.py: bafybeic7otc3hjb753svbmur3yyk6szahc25yii3x4w4vcnpfz6jwvacuu states/final_states.py: bafybeidiwhuyd5zm2cq7vhv2owcrxdpm7fnvn3db6p6tql4jz5hgpalflu states/handle_failed_tx.py: bafybeihewm2vernvhktuorljdupjqcg2p5vs6wvsira2d62wkoyo5xlzjm diff --git a/packages/valory/skills/decision_maker_abci/states/decision_receive.py b/packages/valory/skills/decision_maker_abci/states/decision_receive.py index 7c767beea..51a146c4e 100644 --- a/packages/valory/skills/decision_maker_abci/states/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/states/decision_receive.py @@ -58,6 +58,11 @@ def end_block(self) -> Optional[Tuple[SynchronizedData, Enum]]: return None synced_data, event = cast(Tuple[SynchronizedData, Enum], res) + self.context.logger.info( + f"Synced data: {synced_data}" + f"Event: {event}" + ) + if event == Event.DONE and synced_data.vote is None: return synced_data, Event.TIE diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 9de192895..36f489495 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibuwkc76sko3oojspxv2s3fjtahaxfb6slz3flb3lcdv75m4k4zce -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigdmzlilolxfn7fuoui7xtn3gxzc4a3r6ehz7twi7cnigpefwtndu +- valory/decision_maker_abci:0.1.0:bafybeiapv52i3mkxwfhgqlgqvzw3uuifzbwt7oiuwrb6xh62fnnrbkjcne +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeif2halgb2eg2v47ddk3nc5axcir5vhkefhgjaj22d7v7gdtj7xnuy behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index edba63f07..88cacc069 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeibuwkc76sko3oojspxv2s3fjtahaxfb6slz3flb3lcdv75m4k4zce +- valory/decision_maker_abci:0.1.0:bafybeiapv52i3mkxwfhgqlgqvzw3uuifzbwt7oiuwrb6xh62fnnrbkjcne behaviours: main: args: {} From 119520967d6f635b9b9ba2a7b960d06965a7d940 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 22 Oct 2023 11:10:30 +0200 Subject: [PATCH 53/79] fix: Set bet amount initially to None; Remove odds --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 11 ++++------- packages/valory/skills/decision_maker_abci/models.py | 7 ------- .../valory/skills/decision_maker_abci/payloads.py | 1 - packages/valory/skills/decision_maker_abci/skill.yaml | 10 +++++----- .../valory/skills/decision_maker_abci/states/base.py | 5 ----- .../decision_maker_abci/states/decision_receive.py | 1 - packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 11 files changed, 21 insertions(+), 38 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 1555b49c2..ea543966b 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeiapv52i3mkxwfhgqlgqvzw3uuifzbwt7oiuwrb6xh62fnnrbkjcne", - "skill/valory/trader_abci/0.1.0": "bafybeibxgl5fc2ychrhkukmpharb6rpnwjahhmmtdqtdxb75ktfullpbgi", + "skill/valory/decision_maker_abci/0.1.0": "bafybeiah5ywqa2jlhmmz3jytnn6u4whw5oqycossjcyvfp442iujymivti", + "skill/valory/trader_abci/0.1.0": "bafybeib6tbq6ez5zt3jslqrdkbqm2wr5swcwo4jglcqo3gvdfcil4abvty", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeie6sa36tta3kxq3f36nqxtch5tudhlajga3coqehb6teasub424na", - "service/valory/trader/0.1.0": "bafybeie6ujrnmevajc6hqi6hcdkwa5fso2jt4hxewgwzzft2uiv4gdyq3a", + "agent/valory/trader/0.1.0": "bafybeiekvyhrmnbprmwn7mmth6w6zosejogjp32pn5eqkbvb3otqguyd3u", + "service/valory/trader/0.1.0": "bafybeidj2nllxyttti62cudp6fwtcs5jxytxptai4fcc2lbqdegydrzlf4", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeif2halgb2eg2v47ddk3nc5axcir5vhkefhgjaj22d7v7gdtj7xnuy", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeifjge7ztqv3qwknuyqzps3wqtpvanlmwgmeu4xiayag6rlksfvgl4", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index b0cdd56c1..90d59c2e2 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeif2halgb2eg2v47ddk3nc5axcir5vhkefhgjaj22d7v7gdtj7xnuy +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifjge7ztqv3qwknuyqzps3wqtpvanlmwgmeu4xiayag6rlksfvgl4 - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiapv52i3mkxwfhgqlgqvzw3uuifzbwt7oiuwrb6xh62fnnrbkjcne -- valory/trader_abci:0.1.0:bafybeibxgl5fc2ychrhkukmpharb6rpnwjahhmmtdqtdxb75ktfullpbgi +- valory/decision_maker_abci:0.1.0:bafybeiah5ywqa2jlhmmz3jytnn6u4whw5oqycossjcyvfp442iujymivti +- valory/trader_abci:0.1.0:bafybeib6tbq6ez5zt3jslqrdkbqm2wr5swcwo4jglcqo3gvdfcil4abvty default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 791eacbec..24e659cb2 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeie6sa36tta3kxq3f36nqxtch5tudhlajga3coqehb6teasub424na +agent: valory/trader:0.1.0:bafybeiekvyhrmnbprmwn7mmth6w6zosejogjp32pn5eqkbvb3otqguyd3u number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 75ddd2059..7d9071c05 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -243,9 +243,9 @@ def _get_decision( self.context.logger.error( f"There was an error on the mech's response: {self.mech_response.error}" ) - return None, None, None, None + return None, None, None - return self.mech_response.result.vote, self.mech_response.result.odds, self.mech_response.result.win_probability, self.mech_response.result.confidence + return self.mech_response.result.vote, self.mech_response.result.win_probability, self.mech_response.result.confidence def _get_bet_sample_info(self, bet, vote) -> Tuple[int, int, int]: @@ -475,14 +475,13 @@ def async_act(self) -> Generator: """Do the action.""" with self.context.benchmark_tool.measure(self.behaviour_id).local(): - vote, odds, win_probability, confidence = yield from self._get_decision() + vote, win_probability, confidence = yield from self._get_decision() is_profitable = None - bet_amount = 0 + bet_amount = None if vote is not None and confidence is not None and win_probability is not None: self.context.logger.info( "All should be not none:" f"Vote: {vote}" - f"Odds: {odds}" f"Win probability: {win_probability}" f"Confidence: {confidence}" ) @@ -497,7 +496,6 @@ def async_act(self) -> Generator: f"Agent address: {self.context.agent_address}" f"Is profitable: {is_profitable}" f"Vote: {vote}" - f"Odds: {odds}" f"Win probability: {win_probability}" f"Confidence: {confidence}" f"Bet amount: {bet_amount}" @@ -506,7 +504,6 @@ def async_act(self) -> Generator: self.context.agent_address, is_profitable, vote, - odds, win_probability, confidence, bet_amount, diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index ed7668e47..5fc60b529 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -221,13 +221,6 @@ def vote(self) -> Optional[int]: return int(self.p_no > self.p_yes) return None - @property - def odds(self) -> Optional[float]: - """Return the odds estimation for winning with vote.""" - if self.p_no != self.p_yes: - return self.p_no / self.p_yes - return None - @property def win_probability(self) -> Optional[float]: """Return the probability estimation for winning with vote.""" diff --git a/packages/valory/skills/decision_maker_abci/payloads.py b/packages/valory/skills/decision_maker_abci/payloads.py index 8b7714751..bfe82045f 100644 --- a/packages/valory/skills/decision_maker_abci/payloads.py +++ b/packages/valory/skills/decision_maker_abci/payloads.py @@ -32,7 +32,6 @@ class DecisionReceivePayload(BaseTxPayload): is_profitable: Optional[bool] vote: Optional[int] - odds: Optional[float] win_probability: Optional[float] confidence: Optional[float] bet_amount: Optional[int] diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 04d44641a..3a0afa09e 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeidxxqxw7alt64kvgyrbxkxzuljvvcc6pbbxrq2xfnitnpgifrryve + behaviours/decision_receive.py: bafybeihzeibn2cwr6y5ocii7f4xocfgo7rdsemptgvvlxzrf66djdsez5i behaviours/decision_request.py: bafybeift3ec4uwsccvx7ehtmpypsq7w2625qspbpvu7t2iyv6hdv2scxly behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga @@ -25,16 +25,16 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeihnpza4hibx3y6itnhpg2lgjmuh3dveby7tnarzsollofdtyajyuq - payloads.py: bafybeid7nfq2zui2zqpw54hxx7nixuuuv5v5f5f47pxdxiwe2ow4wqwple + models.py: bafybeihdmbhpjfluyb5pueiqumik2q7l7pe3sibhj7p24jpwbduc2ku6tq + payloads.py: bafybeien7rnk27f6j3dfytn45k4gzky5kqlkz5u7npja3zrsdgmgtigjnm policy.py: bafybeiftviqwq6lapfxj6ykxyh64z72vauqrgmsoho7zo2lvsdvu32kw3m redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm rounds.py: bafybeihopxmhzrpipc6r5x2vqf2tcixzuf5xdpqfsr7gr3n756n3ssft5q states/__init__.py: bafybeid23llnyp6j257dluxmrnztugo5llsrog7kua53hllyktz4dqhqoy - states/base.py: bafybeifzmubtucyciyqfubzvyflst5gdmt6bdpn7ggpcu5hbmw4an77som + states/base.py: bafybeicolcsto2ue5iif36gh4ggjo5kaq4234xrsp2llgvynhbvt53gliy states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeiao747i4z7owk6dmwfuzdijag55m3ryj3nowfoggvczpgk3koza44 - states/decision_receive.py: bafybeiethamxxrj2pdb6gbv5g4znbh37k6zfsdzp6biabmls47rmtelx2u + states/decision_receive.py: bafybeiggp75xhcqhnw7f5k3zsrs4z55574ca6dh2azw5qsvx2d232dteji states/decision_request.py: bafybeic7otc3hjb753svbmur3yyk6szahc25yii3x4w4vcnpfz6jwvacuu states/final_states.py: bafybeidiwhuyd5zm2cq7vhv2owcrxdpm7fnvn3db6p6tql4jz5hgpalflu states/handle_failed_tx.py: bafybeihewm2vernvhktuorljdupjqcg2p5vs6wvsira2d62wkoyo5xlzjm diff --git a/packages/valory/skills/decision_maker_abci/states/base.py b/packages/valory/skills/decision_maker_abci/states/base.py index 8b612c934..f053b50a2 100644 --- a/packages/valory/skills/decision_maker_abci/states/base.py +++ b/packages/valory/skills/decision_maker_abci/states/base.py @@ -115,11 +115,6 @@ def vote(self) -> Optional[int]: vote = self.db.get_strict("vote") return int(vote) if vote is not None else None - @property - def odds(self) -> float: - """Get the vote's odds.""" - return float(self.db.get_strict("odds")) - @property def win_probability(self) -> float: """Get the vote's win probability.""" diff --git a/packages/valory/skills/decision_maker_abci/states/decision_receive.py b/packages/valory/skills/decision_maker_abci/states/decision_receive.py index 51a146c4e..1523ec6f2 100644 --- a/packages/valory/skills/decision_maker_abci/states/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/states/decision_receive.py @@ -44,7 +44,6 @@ class DecisionReceiveRound(CollectSameUntilThresholdRound): selection_key = ( get_name(SynchronizedData.is_profitable), get_name(SynchronizedData.vote), - get_name(SynchronizedData.odds), get_name(SynchronizedData.win_probability), get_name(SynchronizedData.confidence), get_name(SynchronizedData.bet_amount), diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 36f489495..fdb8d40b5 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiapv52i3mkxwfhgqlgqvzw3uuifzbwt7oiuwrb6xh62fnnrbkjcne -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeif2halgb2eg2v47ddk3nc5axcir5vhkefhgjaj22d7v7gdtj7xnuy +- valory/decision_maker_abci:0.1.0:bafybeiah5ywqa2jlhmmz3jytnn6u4whw5oqycossjcyvfp442iujymivti +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifjge7ztqv3qwknuyqzps3wqtpvanlmwgmeu4xiayag6rlksfvgl4 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 88cacc069..8c89564a6 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeiapv52i3mkxwfhgqlgqvzw3uuifzbwt7oiuwrb6xh62fnnrbkjcne +- valory/decision_maker_abci:0.1.0:bafybeiah5ywqa2jlhmmz3jytnn6u4whw5oqycossjcyvfp442iujymivti behaviours: main: args: {} From d063fbd218eebf98089ad6087482dd9f1bba4d33 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 22 Oct 2023 11:56:54 +0200 Subject: [PATCH 54/79] chore: Update logging --- packages/packages.json | 10 ++--- packages/valory/agents/trader/aea-config.yaml | 6 +-- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 38 +++++-------------- .../skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 +- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 22 insertions(+), 42 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index ea543966b..d34efead2 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeiah5ywqa2jlhmmz3jytnn6u4whw5oqycossjcyvfp442iujymivti", - "skill/valory/trader_abci/0.1.0": "bafybeib6tbq6ez5zt3jslqrdkbqm2wr5swcwo4jglcqo3gvdfcil4abvty", + "skill/valory/decision_maker_abci/0.1.0": "bafybeibyo4miaobop6bazkjddgt5ziz2bqujalfxj6sqafjvpmn6iylgta", + "skill/valory/trader_abci/0.1.0": "bafybeifvupbzef6dylan3wrbqhhasshupcosbbdut34i6dnvqkurv4mt2q", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeiekvyhrmnbprmwn7mmth6w6zosejogjp32pn5eqkbvb3otqguyd3u", - "service/valory/trader/0.1.0": "bafybeidj2nllxyttti62cudp6fwtcs5jxytxptai4fcc2lbqdegydrzlf4", + "agent/valory/trader/0.1.0": "bafybeic76b3url7y56cgqohwx5xxnovhbx3rmqubv6nyewpi66t5akekoa", + "service/valory/trader/0.1.0": "bafybeihdgu4gemvd4favxt3gh5or4ze2723jder7kh3fv2x4ycey74u4ni", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeifjge7ztqv3qwknuyqzps3wqtpvanlmwgmeu4xiayag6rlksfvgl4", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihswmftpp5ecwiaavvf4rb7rjtabzpfzfiwnsh7kzp7m7zrssvip4", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 90d59c2e2..535345d64 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifjge7ztqv3qwknuyqzps3wqtpvanlmwgmeu4xiayag6rlksfvgl4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihswmftpp5ecwiaavvf4rb7rjtabzpfzfiwnsh7kzp7m7zrssvip4 - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiah5ywqa2jlhmmz3jytnn6u4whw5oqycossjcyvfp442iujymivti -- valory/trader_abci:0.1.0:bafybeib6tbq6ez5zt3jslqrdkbqm2wr5swcwo4jglcqo3gvdfcil4abvty +- valory/decision_maker_abci:0.1.0:bafybeibyo4miaobop6bazkjddgt5ziz2bqujalfxj6sqafjvpmn6iylgta +- valory/trader_abci:0.1.0:bafybeifvupbzef6dylan3wrbqhhasshupcosbbdut34i6dnvqkurv4mt2q default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 24e659cb2..5e0558138 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiekvyhrmnbprmwn7mmth6w6zosejogjp32pn5eqkbvb3otqguyd3u +agent: valory/trader:0.1.0:bafybeic76b3url7y56cgqohwx5xxnovhbx3rmqubv6nyewpi66t5akekoa number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 7d9071c05..7bf6ac173 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -266,7 +266,7 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] # calculate the pool's k (x*y=k) token_amounts = bet.outcomeTokenAmounts - self.context.logger.info(f"Token amounts: {[x/(10**18) for x in token_amounts]}") + self.context.logger.info(f"Token amounts: {[x for x in token_amounts]}") if token_amounts is None: return 0, 0 k = prod(token_amounts) @@ -275,7 +275,7 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] # the OMEN market trades an equal amount of the investment to each of the tokens in the pool # here we calculate the bet amount per pool's token bet_per_token = net_bet_amount / BINARY_N_SLOTS - self.context.logger.info(f"Bet per token: {bet_per_token/(10**18)}") + self.context.logger.info(f"Bet per token: {bet_per_token}") # calculate the number of the traded tokens prices = bet.outcomeTokenMarginalPrices @@ -401,8 +401,8 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - # other_tokens_in_pool, # bet_fee, # ) - self.context.logger.info(f"Bet amount: {bet_amount/(10**18)}") - self.context.logger.info(f"Bet fee: {bet.fee/(10**18)}") + self.context.logger.info(f"Bet amount: {bet_amount}") + self.context.logger.info(f"Bet fee: {bet.fee}") net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) self.context.logger.info(f"Net bet amount: {net_bet_amount}") @@ -437,11 +437,11 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - ) else: self.context.logger.info( - f"New bet amount: {bet_amount/(10**18)}" + f"New bet amount: {bet_amount}" f"Betting {round(100*bet_amount/prev_bet_amount, 2)}% of the calculated kelly bet amount." ) bet_threshold = self.params.bet_threshold - self.context.logger.info(f"Bet threshold: {bet_threshold/(10**18)}") + self.context.logger.info(f"Bet threshold: {bet_threshold}") if bet_threshold <= 0: self.context.logger.warning( @@ -451,9 +451,9 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - bet_threshold = 0 yield from self.wait_for_condition_with_sleep(self._get_mech_price) - self.context.logger.info(f"Mech price: {self.mech_price/(10**18)}") + self.context.logger.info(f"Mech price: {self.mech_price}") potential_net_profit = num_shares - bet_amount - self.mech_price - bet_threshold - self.context.logger.info(f"Potential net profit: {potential_net_profit/(10**18)}") + self.context.logger.info(f"Potential net profit: {potential_net_profit}") is_profitable = potential_net_profit >= 0 and num_shares <= available_shares self.context.logger.info(f"Is profitable: {is_profitable}") shares_out = self.wei_to_native(num_shares) @@ -466,7 +466,7 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - self.context.logger.info( f"The current liquidity of the market is {bet.scaledLiquidityMeasure} xDAI. " f"The potential net profit is {self.wei_to_native(potential_net_profit)} xDAI " - f"from buying {int(self.wei_to_native(num_shares))} shares for the option {bet.get_outcome(vote)}.\n" + f"from buying {self.wei_to_native(num_shares)} shares for the option {bet.get_outcome(vote)}.\n" f"Decision for profitability of this market: {is_profitable}." ) return is_profitable, bet_amount @@ -479,27 +479,7 @@ def async_act(self) -> Generator: is_profitable = None bet_amount = None if vote is not None and confidence is not None and win_probability is not None: - self.context.logger.info( - "All should be not none:" - f"Vote: {vote}" - f"Win probability: {win_probability}" - f"Confidence: {confidence}" - ) is_profitable, bet_amount = yield from self._is_profitable(vote, win_probability, confidence) - self.context.logger.info( - "Resulting profitability and bet amount:" - f"Is profitable: {is_profitable}" - f"Bet amount: {bet_amount}" - ) - self.context.logger.info( - "Give to DecisionReceivePayload:" - f"Agent address: {self.context.agent_address}" - f"Is profitable: {is_profitable}" - f"Vote: {vote}" - f"Win probability: {win_probability}" - f"Confidence: {confidence}" - f"Bet amount: {bet_amount}" - ) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 3a0afa09e..e056943ab 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicvespraci44y2dtddy4wi7cdhjuyk6crjs7ztnssm2rcrovha3hm - behaviours/decision_receive.py: bafybeihzeibn2cwr6y5ocii7f4xocfgo7rdsemptgvvlxzrf66djdsez5i + behaviours/decision_receive.py: bafybeie6wl3bpnbexgqtw5ahvhonvo6ph5yr4av5qrnffyssgqtybmgjr4 behaviours/decision_request.py: bafybeift3ec4uwsccvx7ehtmpypsq7w2625qspbpvu7t2iyv6hdv2scxly behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index fdb8d40b5..351a3e83a 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiah5ywqa2jlhmmz3jytnn6u4whw5oqycossjcyvfp442iujymivti -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeifjge7ztqv3qwknuyqzps3wqtpvanlmwgmeu4xiayag6rlksfvgl4 +- valory/decision_maker_abci:0.1.0:bafybeibyo4miaobop6bazkjddgt5ziz2bqujalfxj6sqafjvpmn6iylgta +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihswmftpp5ecwiaavvf4rb7rjtabzpfzfiwnsh7kzp7m7zrssvip4 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 8c89564a6..d2d8a2d5a 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeiah5ywqa2jlhmmz3jytnn6u4whw5oqycossjcyvfp442iujymivti +- valory/decision_maker_abci:0.1.0:bafybeibyo4miaobop6bazkjddgt5ziz2bqujalfxj6sqafjvpmn6iylgta behaviours: main: args: {} From c863d7a103fefb49c6995bcbed07ce31d0bf4550 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 22 Oct 2023 13:35:57 +0200 Subject: [PATCH 55/79] fix: Add non zero check for sampled bets; Adjusted logging --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/sampling.py | 10 ++++++++-- packages/valory/skills/decision_maker_abci/skill.yaml | 4 ++-- .../decision_maker_abci/states/decision_receive.py | 5 ----- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 22 insertions(+), 21 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index d34efead2..54a1020e6 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeibyo4miaobop6bazkjddgt5ziz2bqujalfxj6sqafjvpmn6iylgta", - "skill/valory/trader_abci/0.1.0": "bafybeifvupbzef6dylan3wrbqhhasshupcosbbdut34i6dnvqkurv4mt2q", + "skill/valory/decision_maker_abci/0.1.0": "bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii", + "skill/valory/trader_abci/0.1.0": "bafybeidwasoawrqbgenhhln7ngdhnedirdv7kljrxa2w2fau6uejjttaiu", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeic76b3url7y56cgqohwx5xxnovhbx3rmqubv6nyewpi66t5akekoa", - "service/valory/trader/0.1.0": "bafybeihdgu4gemvd4favxt3gh5or4ze2723jder7kh3fv2x4ycey74u4ni", + "agent/valory/trader/0.1.0": "bafybeibq4c3l7mqco3ye4mqu4zr4fjofmilohp6pxmvch34z4opgnqh7q4", + "service/valory/trader/0.1.0": "bafybeiecxxfu2oamtm6j3x2am2xp2pyfkbzcjagdfvznnoyefunacvw2du", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihswmftpp5ecwiaavvf4rb7rjtabzpfzfiwnsh7kzp7m7zrssvip4", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeib6dvgbls4z3rmqc26t4vu645irf6kjhm7ifjmv7e3ikzjcvul64u", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 535345d64..cc815bb03 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihswmftpp5ecwiaavvf4rb7rjtabzpfzfiwnsh7kzp7m7zrssvip4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib6dvgbls4z3rmqc26t4vu645irf6kjhm7ifjmv7e3ikzjcvul64u - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibyo4miaobop6bazkjddgt5ziz2bqujalfxj6sqafjvpmn6iylgta -- valory/trader_abci:0.1.0:bafybeifvupbzef6dylan3wrbqhhasshupcosbbdut34i6dnvqkurv4mt2q +- valory/decision_maker_abci:0.1.0:bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii +- valory/trader_abci:0.1.0:bafybeidwasoawrqbgenhhln7ngdhnedirdv7kljrxa2w2fau6uejjttaiu default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 5e0558138..6fb125b75 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeic76b3url7y56cgqohwx5xxnovhbx3rmqubv6nyewpi66t5akekoa +agent: valory/trader:0.1.0:bafybeibq4c3l7mqco3ye4mqu4zr4fjofmilohp6pxmvch34z4opgnqh7q4 number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index eb2a973ab..e0336b44d 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -60,6 +60,8 @@ def _sampled_bet_idx(self, bets: List[Bet]) -> int: # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + 172800), bets) short_term_bets_list = list(short_term_bets) + if len(short_term_bets_list) == 0: + return None self.context.logger.info(f"Short term bets: {short_term_bets_list}") return self.synchronized_data.bets.index(max(short_term_bets_list)) @@ -79,8 +81,12 @@ def _sample(self) -> Tuple[Optional[str], Optional[int]]: return None, None idx = self._sampled_bet_idx(available_bets) - - if self.synchronized_data.bets[idx].scaledLiquidityMeasure == 0: + + if idx is None: + msg = "There were no unprocessed bets that close within the next 48 hours available to sample from!" + self.context.logger.warning(msg) + return None, None + elif self.synchronized_data.bets[idx].scaledLiquidityMeasure == 0: msg = "There were no unprocessed bets with non-zero liquidity!" self.context.logger.warning(msg) return None, None diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index e056943ab..1cfd96fbf 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -20,7 +20,7 @@ fingerprint: behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeid3q7e7rao2od2eycidkvnbz2zzq4yse4mdjgvq2ja75sa4to3jte + behaviours/sampling.py: bafybeiarw643pcvh7xk4pp7ytxqbif4ocp5smydrkqv2nnwnlocxpwwyt4 behaviours/tool_selection.py: bafybeigbxgm6rl6jnexxzjhb7thsdaqr56wfhxpve25yxlr7eyswf6lsey dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya @@ -34,7 +34,7 @@ fingerprint: states/base.py: bafybeicolcsto2ue5iif36gh4ggjo5kaq4234xrsp2llgvynhbvt53gliy states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeiao747i4z7owk6dmwfuzdijag55m3ryj3nowfoggvczpgk3koza44 - states/decision_receive.py: bafybeiggp75xhcqhnw7f5k3zsrs4z55574ca6dh2azw5qsvx2d232dteji + states/decision_receive.py: bafybeiasj5uaixpqau6hcxpw5vyevqrufd3ubkwvgbgy37gcwfom3bl3iq states/decision_request.py: bafybeic7otc3hjb753svbmur3yyk6szahc25yii3x4w4vcnpfz6jwvacuu states/final_states.py: bafybeidiwhuyd5zm2cq7vhv2owcrxdpm7fnvn3db6p6tql4jz5hgpalflu states/handle_failed_tx.py: bafybeihewm2vernvhktuorljdupjqcg2p5vs6wvsira2d62wkoyo5xlzjm diff --git a/packages/valory/skills/decision_maker_abci/states/decision_receive.py b/packages/valory/skills/decision_maker_abci/states/decision_receive.py index 1523ec6f2..3d9f64361 100644 --- a/packages/valory/skills/decision_maker_abci/states/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/states/decision_receive.py @@ -57,11 +57,6 @@ def end_block(self) -> Optional[Tuple[SynchronizedData, Enum]]: return None synced_data, event = cast(Tuple[SynchronizedData, Enum], res) - self.context.logger.info( - f"Synced data: {synced_data}" - f"Event: {event}" - ) - if event == Event.DONE and synced_data.vote is None: return synced_data, Event.TIE diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 351a3e83a..d5e62a34f 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibyo4miaobop6bazkjddgt5ziz2bqujalfxj6sqafjvpmn6iylgta -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihswmftpp5ecwiaavvf4rb7rjtabzpfzfiwnsh7kzp7m7zrssvip4 +- valory/decision_maker_abci:0.1.0:bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib6dvgbls4z3rmqc26t4vu645irf6kjhm7ifjmv7e3ikzjcvul64u behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index d2d8a2d5a..b0951b771 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeibyo4miaobop6bazkjddgt5ziz2bqujalfxj6sqafjvpmn6iylgta +- valory/decision_maker_abci:0.1.0:bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii behaviours: main: args: {} From 14d4f3909215009136ef6566fd92d0b73350f70d Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 25 Oct 2023 09:08:31 +0200 Subject: [PATCH 56/79] chore: Update packages --- packages/packages.json | 70 +++++++++---------- packages/valory/agents/trader/aea-config.yaml | 40 +++++------ packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/skill.yaml | 12 ++-- .../skills/market_manager_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 +- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 66 insertions(+), 66 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 532eb4a4a..2a232e803 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,42 +1,42 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii", - "skill/valory/trader_abci/0.1.0": "bafybeidwasoawrqbgenhhln7ngdhnedirdv7kljrxa2w2fau6uejjttaiu", - "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeibq4c3l7mqco3ye4mqu4zr4fjofmilohp6pxmvch34z4opgnqh7q4", - "service/valory/trader/0.1.0": "bafybeiecxxfu2oamtm6j3x2am2xp2pyfkbzcjagdfvznnoyefunacvw2du", - "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeib6dvgbls4z3rmqc26t4vu645irf6kjhm7ifjmv7e3ikzjcvul64u", - "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", - "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", - "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", - "contract/valory/conditional_tokens/0.1.0": "bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa", - "contract/valory/agent_registry/0.1.0": "bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty" + "skill/valory/decision_maker_abci/0.1.0": "bafybeicqwyuk35ivm4ehb4jywvxzc3eoohvmk3256k62rojidxa5fxryby", + "skill/valory/trader_abci/0.1.0": "bafybeifzts5xfwhbbbivjdxnw3zlcfimadvs5evm3zjevfxviaueqqvdlu", + "contract/valory/market_maker/0.1.0": "bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu", + "agent/valory/trader/0.1.0": "bafybeihzfptjfl6rpzv2ighekwxhzx4lqt6qwljlizvpgapo6be7xnuspe", + "service/valory/trader/0.1.0": "bafybeie7llmqpakhau272wgb3gfidy7kq7h4x5lbthkr3zqolqy4dkjpfy", + "contract/valory/erc20/0.1.0": "bafybeicsvxv6anl5zdlovfboftqknzqyzisyuxlkcqlespvbyv7ubga3te", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibratoz5jx542nceiak2523nhg6yjl5gwqamgnr3f5fcocnm7a5ba", + "contract/valory/mech/0.1.0": "bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq", + "contract/valory/realitio/0.1.0": "bafybeibzyfaeaxgyqnygtduhprs47fhtskh2vnmw2cvpemqhkgc72q4wpm", + "contract/valory/realitio_proxy/0.1.0": "bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy", + "contract/valory/conditional_tokens/0.1.0": "bafybeigdarm2ssng3uuehlxto75um4hbp47rdi5si6bvv7asdopqsidbhq", + "contract/valory/agent_registry/0.1.0": "bafybeigpd6wvnbb7fbf6yd77rugepv5hrbb6l3qfodstwgemagtcgne3bm" }, "third_party": { - "protocol/open_aea/signing/1.0.0": "bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m", - "protocol/valory/abci/0.1.0": "bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe", - "protocol/valory/contract_api/1.0.0": "bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa", - "protocol/valory/http/1.0.0": "bafybeia5bxdua2i6chw6pg47bvoljzcpuqxzy4rdrorbdmcbnwmnfdobtu", - "protocol/valory/ledger_api/1.0.0": "bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby", - "protocol/valory/acn/1.1.0": "bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa", - "protocol/valory/tendermint/0.1.0": "bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa", - "protocol/valory/ipfs/0.1.0": "bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa", - "skill/valory/abstract_abci/0.1.0": "bafybeigafjci7m7ezwzasav5xqo7v2mbxxn7qb4y7vnuc2wr2irzvn7wsy", - "skill/valory/reset_pause_abci/0.1.0": "bafybeigeoc363gv3wp2rrmk6p2fdxney33nxd3owtpfugzapgruwe4klyu", - "skill/valory/registration_abci/0.1.0": "bafybeibndt6vxiwc2edgtaxpjbhwto3eyu33ujz3zmvtygvo2qz7xme5li", - "skill/valory/abstract_round_abci/0.1.0": "bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq", - "connection/valory/abci/0.1.0": "bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina", - "connection/valory/http_client/0.23.0": "bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y", - "connection/valory/ledger/0.19.0": "bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a", - "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq", - "connection/valory/ipfs/0.1.0": "bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e", - "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274", - "contract/valory/gnosis_safe/0.1.0": "bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm", - "contract/valory/service_registry/0.1.0": "bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu", - "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui", - "contract/valory/multisend/0.1.0": "bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u", - "skill/valory/termination_abci/0.1.0": "bafybeigqpij2sgrpnilqjljfciixop4fldq5qceixc7534q6af4potdmdm" + "protocol/open_aea/signing/1.0.0": "bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii", + "protocol/valory/abci/0.1.0": "bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu", + "protocol/valory/contract_api/1.0.0": "bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka", + "protocol/valory/http/1.0.0": "bafybeiejoqgv7finfxo3rcvvovrlj5ccrbgxodjq43uo26ylpowsa3llfe", + "protocol/valory/ledger_api/1.0.0": "bafybeige5agrztgzfevyglf7mb4o7pzfttmq4f6zi765y4g2zvftbyowru", + "protocol/valory/acn/1.1.0": "bafybeic2pxzfc3voxl2ejhcqyf2ehm4wm5gxvgx7bliloiqi2uppmq6weu", + "protocol/valory/tendermint/0.1.0": "bafybeig6g6twajlwssfbfp5rlnu5mwzuu5kgak5cs4fich7rlkx6whesnu", + "protocol/valory/ipfs/0.1.0": "bafybeiedxeismnx3k5ty4mvvhlqideixlhqmi5mtcki4lxqfa7uqh7p33u", + "skill/valory/abstract_abci/0.1.0": "bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a", + "skill/valory/reset_pause_abci/0.1.0": "bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe", + "skill/valory/registration_abci/0.1.0": "bafybeidbirkdjus6wbpynmyv6ffb6uevsi3zeuhokiqokuw42o7ar5j7hm", + "skill/valory/abstract_round_abci/0.1.0": "bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq", + "connection/valory/abci/0.1.0": "bafybeibtnfu6skrpducj2fzjzw7lrwj3et63xx6u5dryrabec26utzxsf4", + "connection/valory/http_client/0.23.0": "bafybeifgeqgryx6b3s6eseyzyezygmeitcpt3tkor2eiycozoi6clgdrny", + "connection/valory/ledger/0.19.0": "bafybeigo5vst3zlltkouenwxuzn6c47yr2fbbml6dl2o32rfnsezmalgnu", + "connection/valory/p2p_libp2p_client/0.1.0": "bafybeihge56dn3xep2dzomu7rtvbgo4uc2qqh7ljl3fubqdi2lq44gs5lq", + "connection/valory/ipfs/0.1.0": "bafybeigkn27u7m5atju6a724clycyfshbgcbwheztil2bky7krfa46ub2a", + "contract/valory/gnosis_safe_proxy_factory/0.1.0": "bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y", + "contract/valory/gnosis_safe/0.1.0": "bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci", + "contract/valory/service_registry/0.1.0": "bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu", + "skill/valory/transaction_settlement_abci/0.1.0": "bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy", + "contract/valory/multisend/0.1.0": "bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y", + "skill/valory/termination_abci/0.1.0": "bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy" } } \ No newline at end of file diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index d88011eab..0beb72457 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -9,31 +9,31 @@ fingerprint: __init__.py: bafybeighcq4pmuzte6vhvvprrvo563vzghkoit2h6qdqxf2ma5bghevkee fingerprint_ignore_patterns: [] connections: -- valory/abci:0.1.0:bafybeib3exj2vkz4u76rc2amtwz6veeozipr6zdgzlaqsovu3dorppcina -- valory/http_client:0.23.0:bafybeieoeuy4brzimtnubmokwirhrx27ezls6cdnl5qik4rkykfle3nn2y -- valory/ipfs:0.1.0:bafybeidu3xd6rd5zysv2due2cnrc3sxx5vss2usxwaxxtxxuyha2kuhd3e -- valory/ledger:0.19.0:bafybeigfoz7d7si7s4jehvloq2zmiiocpbxcaathl3bxkyarxoerxq7g3a -- valory/p2p_libp2p_client:0.1.0:bafybeihdnfdth3qgltefgrem7xyi4b3ejzaz67xglm2hbma2rfvpl2annq +- valory/abci:0.1.0:bafybeibtnfu6skrpducj2fzjzw7lrwj3et63xx6u5dryrabec26utzxsf4 +- valory/http_client:0.23.0:bafybeifgeqgryx6b3s6eseyzyezygmeitcpt3tkor2eiycozoi6clgdrny +- valory/ipfs:0.1.0:bafybeigkn27u7m5atju6a724clycyfshbgcbwheztil2bky7krfa46ub2a +- valory/ledger:0.19.0:bafybeigo5vst3zlltkouenwxuzn6c47yr2fbbml6dl2o32rfnsezmalgnu +- valory/p2p_libp2p_client:0.1.0:bafybeihge56dn3xep2dzomu7rtvbgo4uc2qqh7ljl3fubqdi2lq44gs5lq contracts: -- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm -- valory/gnosis_safe_proxy_factory:0.1.0:bafybeid6glyjikjxmefwmhn62cxiofophegjmg2z5vqqsvk6tmyunwc274 -- valory/service_registry:0.1.0:bafybeige6pubafkiqmaiyuql6pcojm6fvh5thvhrsapi53au2rhuumqymu +- valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci +- valory/gnosis_safe_proxy_factory:0.1.0:bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y +- valory/service_registry:0.1.0:bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu - valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu - valory/erc20:0.1.0:bafybeicsvxv6anl5zdlovfboftqknzqyzisyuxlkcqlespvbyv7ubga3te -- valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u +- valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y - valory/mech:0.1.0:bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq - valory/conditional_tokens:0.1.0:bafybeigdarm2ssng3uuehlxto75um4hbp47rdi5si6bvv7asdopqsidbhq - valory/realitio:0.1.0:bafybeibzyfaeaxgyqnygtduhprs47fhtskh2vnmw2cvpemqhkgc72q4wpm - valory/realitio_proxy:0.1.0:bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy protocols: -- open_aea/signing:1.0.0:bafybeifuxs7gdg2okbn7uofymenjlmnih2wxwkym44lsgwmklgwuckxm2m -- valory/abci:0.1.0:bafybeigootsvqpk6th5xpdtzanxum3earifrrezfyhylfrit7yvqdrtgpe -- valory/acn:1.1.0:bafybeiapa5ilsobggnspoqhspftwolrx52udrwmaxdxgrk26heuvl4oooa -- valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa -- valory/http:1.0.0:bafybeia5bxdua2i6chw6pg47bvoljzcpuqxzy4rdrorbdmcbnwmnfdobtu -- valory/ipfs:0.1.0:bafybeibjzhsengtxfofqpxy6syamplevp35obemwfp4c5lhag3v2bvgysa -- valory/ledger_api:1.0.0:bafybeigsvceac33asd6ecbqev34meyyjwu3rangenv6xp5rkxyz4krvcby -- valory/tendermint:0.1.0:bafybeidjqmwvgi4rqgp65tbkhmi45fwn2odr5ecezw6q47hwitsgyw4jpa +- open_aea/signing:1.0.0:bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii +- valory/abci:0.1.0:bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu +- valory/acn:1.1.0:bafybeic2pxzfc3voxl2ejhcqyf2ehm4wm5gxvgx7bliloiqi2uppmq6weu +- valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka +- valory/http:1.0.0:bafybeiejoqgv7finfxo3rcvvovrlj5ccrbgxodjq43uo26ylpowsa3llfe +- valory/ipfs:0.1.0:bafybeiedxeismnx3k5ty4mvvhlqideixlhqmi5mtcki4lxqfa7uqh7p33u +- valory/ledger_api:1.0.0:bafybeige5agrztgzfevyglf7mb4o7pzfttmq4f6zi765y4g2zvftbyowru +- valory/tendermint:0.1.0:bafybeig6g6twajlwssfbfp5rlnu5mwzuu5kgak5cs4fich7rlkx6whesnu skills: - valory/abstract_abci:0.1.0:bafybeihgemn2gwjc2wyxuh7rttg5pk5gec7dxhet3ih2tmg75vsdbgad7a - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib6dvgbls4z3rmqc26t4vu645irf6kjhm7ifjmv7e3ikzjcvul64u +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibratoz5jx542nceiak2523nhg6yjl5gwqamgnr3f5fcocnm7a5ba - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii -- valory/trader_abci:0.1.0:bafybeidwasoawrqbgenhhln7ngdhnedirdv7kljrxa2w2fau6uejjttaiu +- valory/decision_maker_abci:0.1.0:bafybeicqwyuk35ivm4ehb4jywvxzc3eoohvmk3256k62rojidxa5fxryby +- valory/trader_abci:0.1.0:bafybeifzts5xfwhbbbivjdxnw3zlcfimadvs5evm3zjevfxviaueqqvdlu default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 6fb125b75..6e1a670bd 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeibq4c3l7mqco3ye4mqu4zr4fjofmilohp6pxmvch34z4opgnqh7q4 +agent: valory/trader:0.1.0:bafybeihzfptjfl6rpzv2ighekwxhzx4lqt6qwljlizvpgapo6be7xnuspe number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 39c80cd6c..848ab8ff8 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -44,21 +44,21 @@ fingerprint: fingerprint_ignore_patterns: [] connections: [] contracts: -- valory/gnosis_safe:0.1.0:bafybeih6d3vxz3jlgodxm5b2qcwsmansqj4xobuyd6hjnhzremuvd65yrm +- valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci - valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu - valory/erc20:0.1.0:bafybeicsvxv6anl5zdlovfboftqknzqyzisyuxlkcqlespvbyv7ubga3te -- valory/multisend:0.1.0:bafybeieg4tywd5lww2vygvpkilg3hcepa4rmhehjuamyvdf6vazt554v6u +- valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y - valory/mech:0.1.0:bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq - valory/conditional_tokens:0.1.0:bafybeigdarm2ssng3uuehlxto75um4hbp47rdi5si6bvv7asdopqsidbhq - valory/realitio:0.1.0:bafybeibzyfaeaxgyqnygtduhprs47fhtskh2vnmw2cvpemqhkgc72q4wpm - valory/realitio_proxy:0.1.0:bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy - valory/agent_registry:0.1.0:bafybeigpd6wvnbb7fbf6yd77rugepv5hrbb6l3qfodstwgemagtcgne3bm protocols: -- valory/contract_api:1.0.0:bafybeiasywsvax45qmugus5kxogejj66c5taen27h4voriodz7rgushtqa +- valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka skills: -- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq -- valory/market_manager_abci:0.1.0:bafybeidnqerwkljbjgog73qaa5duu5ymsfjs6jsszeupseshx7go3n6afq -- valory/transaction_settlement_abci:0.1.0:bafybeia7rzsbea3ch4gcafyp3z6uvqh4npws2xpdwbkkdbrqqpjops7nui +- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq +- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m +- valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy behaviours: main: args: {} diff --git a/packages/valory/skills/market_manager_abci/skill.yaml b/packages/valory/skills/market_manager_abci/skill.yaml index 790727458..e7edd85e7 100644 --- a/packages/valory/skills/market_manager_abci/skill.yaml +++ b/packages/valory/skills/market_manager_abci/skill.yaml @@ -26,7 +26,7 @@ connections: [] contracts: [] protocols: [] skills: -- valory/abstract_round_abci:0.1.0:bafybeih2fyfb6kkf7r45pvdk7pyyebr5xloia4xiqxtb3qsrasnstqmepq +- valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq behaviours: main: args: {} diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index d5e62a34f..8c4168806 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib6dvgbls4z3rmqc26t4vu645irf6kjhm7ifjmv7e3ikzjcvul64u +- valory/decision_maker_abci:0.1.0:bafybeicqwyuk35ivm4ehb4jywvxzc3eoohvmk3256k62rojidxa5fxryby +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibratoz5jx542nceiak2523nhg6yjl5gwqamgnr3f5fcocnm7a5ba behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index b0951b771..80bb1268e 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii +- valory/decision_maker_abci:0.1.0:bafybeicqwyuk35ivm4ehb4jywvxzc3eoohvmk3256k62rojidxa5fxryby behaviours: main: args: {} From b7ace28269092042688593dcf2d60762f4832d00 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 25 Oct 2023 09:54:02 +0200 Subject: [PATCH 57/79] chore: Update package hashes manually --- packages/valory/agents/trader/aea-config.yaml | 18 +- poetry.lock | 631 ++++++++---------- pyproject.toml | 16 +- 3 files changed, 312 insertions(+), 353 deletions(-) diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 0beb72457..cc815bb03 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -18,13 +18,13 @@ contracts: - valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci - valory/gnosis_safe_proxy_factory:0.1.0:bafybeigxqwbd6wds57ecsfkl2hf4z4vbz5gokex6nutu5zcdpw6irh573y - valory/service_registry:0.1.0:bafybeiebuuhs7fmigfh4c5dvzt6rbm5ekwrcnz7zouyjey7yyyqmpa6dyu -- valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu -- valory/erc20:0.1.0:bafybeicsvxv6anl5zdlovfboftqknzqyzisyuxlkcqlespvbyv7ubga3te +- valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m +- valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi - valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y -- valory/mech:0.1.0:bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq -- valory/conditional_tokens:0.1.0:bafybeigdarm2ssng3uuehlxto75um4hbp47rdi5si6bvv7asdopqsidbhq -- valory/realitio:0.1.0:bafybeibzyfaeaxgyqnygtduhprs47fhtskh2vnmw2cvpemqhkgc72q4wpm -- valory/realitio_proxy:0.1.0:bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy +- valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga +- valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa +- valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e +- valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 protocols: - open_aea/signing:1.0.0:bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii - valory/abci:0.1.0:bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibratoz5jx542nceiak2523nhg6yjl5gwqamgnr3f5fcocnm7a5ba +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib6dvgbls4z3rmqc26t4vu645irf6kjhm7ifjmv7e3ikzjcvul64u - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeicqwyuk35ivm4ehb4jywvxzc3eoohvmk3256k62rojidxa5fxryby -- valory/trader_abci:0.1.0:bafybeifzts5xfwhbbbivjdxnw3zlcfimadvs5evm3zjevfxviaueqqvdlu +- valory/decision_maker_abci:0.1.0:bafybeig7zb4w4ohmzxccwp2x4xxyqz3tmierzb42xlfil2n4cvpk66iaii +- valory/trader_abci:0.1.0:bafybeidwasoawrqbgenhhln7ngdhnedirdv7kljrxa2w2fau6uejjttaiu default_ledger: ethereum required_ledgers: - ethereum diff --git a/poetry.lock b/poetry.lock index bc65e38f6..5fad54694 100644 --- a/poetry.lock +++ b/poetry.lock @@ -337,63 +337,65 @@ files = [ [[package]] name = "cachetools" -version = "5.3.1" +version = "5.3.2" description = "Extensible memoizing collections and decorators" optional = false python-versions = ">=3.7" files = [ - {file = "cachetools-5.3.1-py3-none-any.whl", hash = "sha256:95ef631eeaea14ba2e36f06437f36463aac3a096799e876ee55e5cdccb102590"}, - {file = "cachetools-5.3.1.tar.gz", hash = "sha256:dce83f2d9b4e1f732a8cd44af8e8fab2dbe46201467fc98b3ef8f269092bf62b"}, + {file = "cachetools-5.3.2-py3-none-any.whl", hash = "sha256:861f35a13a451f94e301ce2bec7cac63e881232ccce7ed67fab9b5df4d3beaa1"}, + {file = "cachetools-5.3.2.tar.gz", hash = "sha256:086ee420196f7b2ab9ca2db2520aca326318b68fe5ba8bc4d49cca91add450f2"}, ] [[package]] name = "cbor2" -version = "5.4.6" +version = "5.5.0" description = "CBOR (de)serializer with extensive tag support" optional = false -python-versions = ">=3.7" +python-versions = ">=3.8" files = [ - {file = "cbor2-5.4.6-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:309fffbb7f561d67f02095d4b9657b73c9220558701c997e9bfcfbca2696e927"}, - {file = "cbor2-5.4.6-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:ff95b33e5482313a74648ca3620c9328e9f30ecfa034df040b828e476597d352"}, - {file = "cbor2-5.4.6-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:db9eb582fce972f0fa429d8159b7891ff8deccb7affc4995090afc61ce0d328a"}, - {file = "cbor2-5.4.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3950be57a1698086cf26d8710b4e5a637b65133c5b1f9eec23967d4089d8cfed"}, - {file = "cbor2-5.4.6-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:78304df140b9e13b93bcbb2aecee64c9aaa9f1cadbd45f043b5e7b93cc2f21a2"}, - {file = "cbor2-5.4.6-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:e73ca40dd3c7210ff776acff9869ddc9ff67bae7c425b58e5715dcf55275163f"}, - {file = "cbor2-5.4.6-cp310-cp310-win_amd64.whl", hash = "sha256:0b956f19e93ba3180c336282cd1b6665631f2d3a196a9c19b29a833bf979e7a4"}, - {file = "cbor2-5.4.6-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:1c12c0ab78f5bc290b08a79152a8621822415836a86f8f4b50dadba371736fda"}, - {file = "cbor2-5.4.6-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:3545b16f9f0d5f34d4c99052829c3726020a07be34c99c250d0df87418f02954"}, - {file = "cbor2-5.4.6-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:24144822f8d2b0156f4cda9427f071f969c18683ffed39663dc86bc0a75ae4dd"}, - {file = "cbor2-5.4.6-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1835536e76ea16e88c934aac5e369ba9f93d495b01e5fa2d93f0b4986b89146d"}, - {file = "cbor2-5.4.6-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:39452c799453f5bf33281ffc0752c620b8bfa0b7c13070b87d370257a1311976"}, - {file = "cbor2-5.4.6-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:3316f09a77af85e7772ecfdd693b0f450678a60b1aee641bac319289757e3fa0"}, - {file = "cbor2-5.4.6-cp311-cp311-win_amd64.whl", hash = "sha256:456cdff668a50a52fdb8aa6d0742511e43ed46d6a5b463dba80a5a720fa0d320"}, - {file = "cbor2-5.4.6-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:9394ca49ecdf0957924e45d09a4026482d184a465a047f60c4044eb464c43de9"}, - {file = "cbor2-5.4.6-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:56dfa030cd3d67e5b6701d3067923f2f61536a8ffb1b45be14775d1e866b59ae"}, - {file = "cbor2-5.4.6-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e5094562dfe3e5583202b93ef7ca5082c2ba5571accb2c4412d27b7d0ba8a563"}, - {file = "cbor2-5.4.6-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:94f844d0e232aca061a86dd6ff191e47ba0389ddd34acb784ad9a41594dc99a4"}, - {file = "cbor2-5.4.6-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:7bbd3470eb685325398023e335be896b74f61b014896604ed45049a7b7b6d8ac"}, - {file = "cbor2-5.4.6-cp37-cp37m-win_amd64.whl", hash = "sha256:0bd12c54a48949d11f5ffc2fa27f5df1b4754111f5207453e5fae3512ebb3cab"}, - {file = "cbor2-5.4.6-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:d2984a488f350aee1d54fa9cb8c6a3c1f1f5b268abbc91161e47185de4d829f3"}, - {file = "cbor2-5.4.6-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:c285a2cb2c04004bfead93df89d92a0cef1874ad337d0cb5ea53c2c31e97bfdb"}, - {file = "cbor2-5.4.6-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6709d97695205cd08255363b54afa035306d5302b7b5e38308c8ff5a47e60f2a"}, - {file = "cbor2-5.4.6-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:96087fa5336ebfc94465c0768cd5de0fcf9af3840d2cf0ce32f5767855f1a293"}, - {file = "cbor2-5.4.6-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:0d2b926b024d3a1549b819bc82fdc387062bbd977b0299dd5fa5e0ea3267b98b"}, - {file = "cbor2-5.4.6-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6e1b5aee920b6a2f737aa12e2b54de3826b09f885a7ce402db84216343368140"}, - {file = "cbor2-5.4.6-cp38-cp38-win_amd64.whl", hash = "sha256:79e048e623846d60d735bb350263e8fdd36cb6195d7f1a2b57eacd573d9c0b33"}, - {file = "cbor2-5.4.6-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:80ac8ba450c7a41c5afe5f7e503d3092442ed75393e1de162b0bf0d97edf7c7f"}, - {file = "cbor2-5.4.6-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4ce1a2c272ba8523a55ea2f1d66e3464e89fa0e37c9a3d786a919fe64e68dbd7"}, - {file = "cbor2-5.4.6-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1618d16e310f7ffed141762b0ff5d8bb6b53ad449406115cc465bf04213cefcf"}, - {file = "cbor2-5.4.6-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4bbbdb2e3ef274865dc3f279aae109b5d94f4654aea3c72c479fb37e4a1e7ed7"}, - {file = "cbor2-5.4.6-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:6f9c702bee2954fffdfa3de95a5af1a6b1c5f155e39490353d5654d83bb05bb9"}, - {file = "cbor2-5.4.6-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:4b9f3924da0e460a93b3674c7e71020dd6c9e9f17400a34e52a88c0af2dcd2aa"}, - {file = "cbor2-5.4.6-cp39-cp39-win_amd64.whl", hash = "sha256:d54bd840b4fe34f097b8665fc0692c7dd175349e53976be6c5de4433b970daa4"}, - {file = "cbor2-5.4.6-py3-none-any.whl", hash = "sha256:181ac494091d1f9c5bb373cd85514ce1eb967a8cf3ec298e8dfa8878aa823956"}, - {file = "cbor2-5.4.6.tar.gz", hash = "sha256:b893500db0fe033e570c3adc956af6eefc57e280026bd2d86fd53da9f1e594d7"}, + {file = "cbor2-5.5.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:1ea9f9ede6b99d9283ddca8aa0114b163fc5f3e7e0bfb20b2c1231ccffe6dfa2"}, + {file = "cbor2-5.5.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:7ed4c8e78cb37ac471499e368cf6e61606b9be6b314e8fd26a2140b1485e7713"}, + {file = "cbor2-5.5.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9bbc1caf81dda3e0596ab60a9705b72c243c61d42e2f6054c32f68ce24ee7069"}, + {file = "cbor2-5.5.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0b0372dcc81c1a2659713b81f6eaa2664889d298e35f46739b45d579aa1f0324"}, + {file = "cbor2-5.5.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:319d73c7fb22fc27f5f76cca6d22dd5dc924da5e907667421276e4857eb03e97"}, + {file = "cbor2-5.5.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:c7547022c4ab2ba21240a93382f6ee758d9afbb7660625ea82b6fe004de7c344"}, + {file = "cbor2-5.5.0-cp310-cp310-win_amd64.whl", hash = "sha256:3e5b411e483aa4132f59a49549db4862ec6cec8faea5aede796de79e450ca058"}, + {file = "cbor2-5.5.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:e4ef724e6f2b18f1d75a4dc6c136a900ba31928cf96a0a57e8d422fe1d36dc73"}, + {file = "cbor2-5.5.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:6b3e99ad82b4f106e5fcdb270503b040f68c07fce2425a650ec17dafd2e818d0"}, + {file = "cbor2-5.5.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a48f9e69b8749178340c03933a549eecd0c427df2931f91f3c6d50268980f3c3"}, + {file = "cbor2-5.5.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0eeb081fdcfd82320ac1d15821ffa8740e91269ac16350ecb81e7c2af532657a"}, + {file = "cbor2-5.5.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:165506e8ad17da248dc519bd3b416aa436ac6d4b0b3b6df413e0cd0e99ebdca6"}, + {file = "cbor2-5.5.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:56975266e45bc02fe4ed33d4aaa54a755df9d9c52af5b07f3561c257cc71666f"}, + {file = "cbor2-5.5.0-cp311-cp311-win_amd64.whl", hash = "sha256:b1123fd77c6cd34ebc9c96e9739fc65bf9dea4a935733ac106ceff78cd101500"}, + {file = "cbor2-5.5.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:817b951d4454854836deefd968c3b48168ea61bd45aa43985097a641ad64e019"}, + {file = "cbor2-5.5.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:7a0a6abb60c2ee9d2cddbfc8a5964144b7d39ca9fc00fdaf1fde6a36b148fb1c"}, + {file = "cbor2-5.5.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:98283f372a443e8bd74eb12f609200427a65bc2079bdb53b5b8d290d0e414205"}, + {file = "cbor2-5.5.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2ee5c56a3348747803e88242c170d71a8b37da04d02690298cfc6deb3c835610"}, + {file = "cbor2-5.5.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:9911a502a507ee275addbd2b9585767c4b3769b906d76fbdac7f4a6fd0e70cd3"}, + {file = "cbor2-5.5.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:5bef8ade50940d7cee2083020685068426c3553f416ff1321ee8b7bc6d3dbb0c"}, + {file = "cbor2-5.5.0-cp312-cp312-win_amd64.whl", hash = "sha256:4da17036611bf8809bc5b20fce6e37ab1e792bca6ada713f9ce84cdef66c6c82"}, + {file = "cbor2-5.5.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:9ccbdcc14056a246b71b2274e6e8d842a54b667c16ad6bf74f889f722b82499b"}, + {file = "cbor2-5.5.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:dfa2dd19efe994a67b9ffa33cc20ccdaa6b8e8fd5848a4c13701bdbaec86eff1"}, + {file = "cbor2-5.5.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ae3c8b8fba719fc2c10591ab881ea1642130ecac321d17e195ace5766918c646"}, + {file = "cbor2-5.5.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:779e2de091ab022fcfc3d2a32489344268e067b852b884ecabfa84a678a7fba0"}, + {file = "cbor2-5.5.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:a73b2902f2deac8033d2571025a8430345e0de4326312dd5040a5187f6825fe7"}, + {file = "cbor2-5.5.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:2cf21356d1dd9d13ab9997b4134c21d132b85dd6e778f5d602cdc3310cc946e9"}, + {file = "cbor2-5.5.0-cp38-cp38-win_amd64.whl", hash = "sha256:162a4511fda3b71d9257a3356645d162e8e3b707b9fffe052237ee0b933651bc"}, + {file = "cbor2-5.5.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:16e217cbfc8bf47dfdcd7e4d570efee785cda187150d9b7ab7cfc8202d87fa5f"}, + {file = "cbor2-5.5.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:44453c1d3289ccd508f43f1cce876a2800659c32ffe4732d6e75f1dc7b6a1efa"}, + {file = "cbor2-5.5.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4832ab39e037a084ea180d2f8bc746fff84a35bb419ec40edfe6b0e69cad3fed"}, + {file = "cbor2-5.5.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bf50d4961180f0780c185e10a813f9115fd4e8275d65ab767450adbcdf94517a"}, + {file = "cbor2-5.5.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:30798f1c9e65db40e4b323bb34bae2106f10663792864558a470b455776b4439"}, + {file = "cbor2-5.5.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:de98295ef3db971548e44c1c7e745f450778bcbbbf9fff3d1fb4265094a57ce5"}, + {file = "cbor2-5.5.0-cp39-cp39-win_amd64.whl", hash = "sha256:ba1b0f546f47ccd0f55605b8102ca66d4c19dcae42ab6d6a4d2d75526aac5282"}, + {file = "cbor2-5.5.0-py3-none-any.whl", hash = "sha256:d478ef30fa559cdc819c2c9c78e5b20bd69e570c29e1070c537abe28a03c87b8"}, + {file = "cbor2-5.5.0.tar.gz", hash = "sha256:380a427faed0202236dccca6b1dc0491f35c0598bdb6cac983616f6106127bd7"}, ] [package.extras] -doc = ["sphinx-autodoc-typehints (>=1.2.0)", "sphinx-rtd-theme"] -test = ["pytest", "pytest-cov"] +benchmarks = ["pytest-benchmark (==4.0.0)"] +doc = ["Sphinx (>=7)", "packaging", "sphinx-autodoc-typehints (>=1.2.0)", "sphinx-rtd-theme (>=1.3.0)", "typing-extensions"] +test = ["coverage (>=7)", "hypothesis", "pytest"] [[package]] name = "certifi" @@ -483,101 +485,101 @@ files = [ [[package]] name = "charset-normalizer" -version = "3.3.0" +version = "3.3.1" description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." optional = false python-versions = ">=3.7.0" files = [ - {file = "charset-normalizer-3.3.0.tar.gz", hash = "sha256:63563193aec44bce707e0c5ca64ff69fa72ed7cf34ce6e11d5127555756fd2f6"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:effe5406c9bd748a871dbcaf3ac69167c38d72db8c9baf3ff954c344f31c4cbe"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:4162918ef3098851fcd8a628bf9b6a98d10c380725df9e04caf5ca6dd48c847a"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:0570d21da019941634a531444364f2482e8db0b3425fcd5ac0c36565a64142c8"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5707a746c6083a3a74b46b3a631d78d129edab06195a92a8ece755aac25a3f3d"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:278c296c6f96fa686d74eb449ea1697f3c03dc28b75f873b65b5201806346a69"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a4b71f4d1765639372a3b32d2638197f5cd5221b19531f9245fcc9ee62d38f56"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f5969baeaea61c97efa706b9b107dcba02784b1601c74ac84f2a532ea079403e"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a3f93dab657839dfa61025056606600a11d0b696d79386f974e459a3fbc568ec"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:db756e48f9c5c607b5e33dd36b1d5872d0422e960145b08ab0ec7fd420e9d649"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:232ac332403e37e4a03d209a3f92ed9071f7d3dbda70e2a5e9cff1c4ba9f0678"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:e5c1502d4ace69a179305abb3f0bb6141cbe4714bc9b31d427329a95acfc8bdd"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:2502dd2a736c879c0f0d3e2161e74d9907231e25d35794584b1ca5284e43f596"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:23e8565ab7ff33218530bc817922fae827420f143479b753104ab801145b1d5b"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-win32.whl", hash = "sha256:1872d01ac8c618a8da634e232f24793883d6e456a66593135aeafe3784b0848d"}, - {file = "charset_normalizer-3.3.0-cp310-cp310-win_amd64.whl", hash = "sha256:557b21a44ceac6c6b9773bc65aa1b4cc3e248a5ad2f5b914b91579a32e22204d"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:d7eff0f27edc5afa9e405f7165f85a6d782d308f3b6b9d96016c010597958e63"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:6a685067d05e46641d5d1623d7c7fdf15a357546cbb2f71b0ebde91b175ffc3e"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:0d3d5b7db9ed8a2b11a774db2bbea7ba1884430a205dbd54a32d61d7c2a190fa"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2935ffc78db9645cb2086c2f8f4cfd23d9b73cc0dc80334bc30aac6f03f68f8c"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:9fe359b2e3a7729010060fbca442ca225280c16e923b37db0e955ac2a2b72a05"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:380c4bde80bce25c6e4f77b19386f5ec9db230df9f2f2ac1e5ad7af2caa70459"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f0d1e3732768fecb052d90d62b220af62ead5748ac51ef61e7b32c266cac9293"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1b2919306936ac6efb3aed1fbf81039f7087ddadb3160882a57ee2ff74fd2382"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:f8888e31e3a85943743f8fc15e71536bda1c81d5aa36d014a3c0c44481d7db6e"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:82eb849f085624f6a607538ee7b83a6d8126df6d2f7d3b319cb837b289123078"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-musllinux_1_1_ppc64le.whl", hash = "sha256:7b8b8bf1189b3ba9b8de5c8db4d541b406611a71a955bbbd7385bbc45fcb786c"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-musllinux_1_1_s390x.whl", hash = "sha256:5adf257bd58c1b8632046bbe43ee38c04e1038e9d37de9c57a94d6bd6ce5da34"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:c350354efb159b8767a6244c166f66e67506e06c8924ed74669b2c70bc8735b1"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-win32.whl", hash = "sha256:02af06682e3590ab952599fbadac535ede5d60d78848e555aa58d0c0abbde786"}, - {file = "charset_normalizer-3.3.0-cp311-cp311-win_amd64.whl", hash = "sha256:86d1f65ac145e2c9ed71d8ffb1905e9bba3a91ae29ba55b4c46ae6fc31d7c0d4"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:3b447982ad46348c02cb90d230b75ac34e9886273df3a93eec0539308a6296d7"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:abf0d9f45ea5fb95051c8bfe43cb40cda383772f7e5023a83cc481ca2604d74e"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:b09719a17a2301178fac4470d54b1680b18a5048b481cb8890e1ef820cb80455"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b3d9b48ee6e3967b7901c052b670c7dda6deb812c309439adaffdec55c6d7b78"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:edfe077ab09442d4ef3c52cb1f9dab89bff02f4524afc0acf2d46be17dc479f5"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3debd1150027933210c2fc321527c2299118aa929c2f5a0a80ab6953e3bd1908"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:86f63face3a527284f7bb8a9d4f78988e3c06823f7bea2bd6f0e0e9298ca0403"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:24817cb02cbef7cd499f7c9a2735286b4782bd47a5b3516a0e84c50eab44b98e"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:c71f16da1ed8949774ef79f4a0260d28b83b3a50c6576f8f4f0288d109777989"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:9cf3126b85822c4e53aa28c7ec9869b924d6fcfb76e77a45c44b83d91afd74f9"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-musllinux_1_1_ppc64le.whl", hash = "sha256:b3b2316b25644b23b54a6f6401074cebcecd1244c0b8e80111c9a3f1c8e83d65"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-musllinux_1_1_s390x.whl", hash = "sha256:03680bb39035fbcffe828eae9c3f8afc0428c91d38e7d61aa992ef7a59fb120e"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:4cc152c5dd831641e995764f9f0b6589519f6f5123258ccaca8c6d34572fefa8"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-win32.whl", hash = "sha256:b8f3307af845803fb0b060ab76cf6dd3a13adc15b6b451f54281d25911eb92df"}, - {file = "charset_normalizer-3.3.0-cp312-cp312-win_amd64.whl", hash = "sha256:8eaf82f0eccd1505cf39a45a6bd0a8cf1c70dcfc30dba338207a969d91b965c0"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:dc45229747b67ffc441b3de2f3ae5e62877a282ea828a5bdb67883c4ee4a8810"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2f4a0033ce9a76e391542c182f0d48d084855b5fcba5010f707c8e8c34663d77"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ada214c6fa40f8d800e575de6b91a40d0548139e5dc457d2ebb61470abf50186"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b1121de0e9d6e6ca08289583d7491e7fcb18a439305b34a30b20d8215922d43c"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1063da2c85b95f2d1a430f1c33b55c9c17ffaf5e612e10aeaad641c55a9e2b9d"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:70f1d09c0d7748b73290b29219e854b3207aea922f839437870d8cc2168e31cc"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:250c9eb0f4600361dd80d46112213dff2286231d92d3e52af1e5a6083d10cad9"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:750b446b2ffce1739e8578576092179160f6d26bd5e23eb1789c4d64d5af7dc7"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:fc52b79d83a3fe3a360902d3f5d79073a993597d48114c29485e9431092905d8"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:588245972aca710b5b68802c8cad9edaa98589b1b42ad2b53accd6910dad3545"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e39c7eb31e3f5b1f88caff88bcff1b7f8334975b46f6ac6e9fc725d829bc35d4"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-win32.whl", hash = "sha256:abecce40dfebbfa6abf8e324e1860092eeca6f7375c8c4e655a8afb61af58f2c"}, - {file = "charset_normalizer-3.3.0-cp37-cp37m-win_amd64.whl", hash = "sha256:24a91a981f185721542a0b7c92e9054b7ab4fea0508a795846bc5b0abf8118d4"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:67b8cc9574bb518ec76dc8e705d4c39ae78bb96237cb533edac149352c1f39fe"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:ac71b2977fb90c35d41c9453116e283fac47bb9096ad917b8819ca8b943abecd"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:3ae38d325b512f63f8da31f826e6cb6c367336f95e418137286ba362925c877e"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:542da1178c1c6af8873e143910e2269add130a299c9106eef2594e15dae5e482"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:30a85aed0b864ac88309b7d94be09f6046c834ef60762a8833b660139cfbad13"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:aae32c93e0f64469f74ccc730a7cb21c7610af3a775157e50bbd38f816536b38"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:15b26ddf78d57f1d143bdf32e820fd8935d36abe8a25eb9ec0b5a71c82eb3895"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7f5d10bae5d78e4551b7be7a9b29643a95aded9d0f602aa2ba584f0388e7a557"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:249c6470a2b60935bafd1d1d13cd613f8cd8388d53461c67397ee6a0f5dce741"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:c5a74c359b2d47d26cdbbc7845e9662d6b08a1e915eb015d044729e92e7050b7"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:b5bcf60a228acae568e9911f410f9d9e0d43197d030ae5799e20dca8df588287"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:187d18082694a29005ba2944c882344b6748d5be69e3a89bf3cc9d878e548d5a"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:81bf654678e575403736b85ba3a7867e31c2c30a69bc57fe88e3ace52fb17b89"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-win32.whl", hash = "sha256:85a32721ddde63c9df9ebb0d2045b9691d9750cb139c161c80e500d210f5e26e"}, - {file = "charset_normalizer-3.3.0-cp38-cp38-win_amd64.whl", hash = "sha256:468d2a840567b13a590e67dd276c570f8de00ed767ecc611994c301d0f8c014f"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e0fc42822278451bc13a2e8626cf2218ba570f27856b536e00cfa53099724828"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:09c77f964f351a7369cc343911e0df63e762e42bac24cd7d18525961c81754f4"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:12ebea541c44fdc88ccb794a13fe861cc5e35d64ed689513a5c03d05b53b7c82"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:805dfea4ca10411a5296bcc75638017215a93ffb584c9e344731eef0dcfb026a"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:96c2b49eb6a72c0e4991d62406e365d87067ca14c1a729a870d22354e6f68115"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:aaf7b34c5bc56b38c931a54f7952f1ff0ae77a2e82496583b247f7c969eb1479"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:619d1c96099be5823db34fe89e2582b336b5b074a7f47f819d6b3a57ff7bdb86"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a0ac5e7015a5920cfce654c06618ec40c33e12801711da6b4258af59a8eff00a"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:93aa7eef6ee71c629b51ef873991d6911b906d7312c6e8e99790c0f33c576f89"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:7966951325782121e67c81299a031f4c115615e68046f79b85856b86ebffc4cd"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:02673e456dc5ab13659f85196c534dc596d4ef260e4d86e856c3b2773ce09843"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:c2af80fb58f0f24b3f3adcb9148e6203fa67dd3f61c4af146ecad033024dde43"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:153e7b6e724761741e0974fc4dcd406d35ba70b92bfe3fedcb497226c93b9da7"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-win32.whl", hash = "sha256:d47ecf253780c90ee181d4d871cd655a789da937454045b17b5798da9393901a"}, - {file = "charset_normalizer-3.3.0-cp39-cp39-win_amd64.whl", hash = "sha256:d97d85fa63f315a8bdaba2af9a6a686e0eceab77b3089af45133252618e70884"}, - {file = "charset_normalizer-3.3.0-py3-none-any.whl", hash = "sha256:e46cd37076971c1040fc8c41273a8b3e2c624ce4f2be3f5dfcb7a430c1d3acc2"}, + {file = "charset-normalizer-3.3.1.tar.gz", hash = "sha256:d9137a876020661972ca6eec0766d81aef8a5627df628b664b234b73396e727e"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:8aee051c89e13565c6bd366813c386939f8e928af93c29fda4af86d25b73d8f8"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:352a88c3df0d1fa886562384b86f9a9e27563d4704ee0e9d56ec6fcd270ea690"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:223b4d54561c01048f657fa6ce41461d5ad8ff128b9678cfe8b2ecd951e3f8a2"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:4f861d94c2a450b974b86093c6c027888627b8082f1299dfd5a4bae8e2292821"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:1171ef1fc5ab4693c5d151ae0fdad7f7349920eabbaca6271f95969fa0756c2d"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:28f512b9a33235545fbbdac6a330a510b63be278a50071a336afc1b78781b147"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:c0e842112fe3f1a4ffcf64b06dc4c61a88441c2f02f373367f7b4c1aa9be2ad5"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3f9bc2ce123637a60ebe819f9fccc614da1bcc05798bbbaf2dd4ec91f3e08846"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:f194cce575e59ffe442c10a360182a986535fd90b57f7debfaa5c845c409ecc3"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:9a74041ba0bfa9bc9b9bb2cd3238a6ab3b7618e759b41bd15b5f6ad958d17605"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:b578cbe580e3b41ad17b1c428f382c814b32a6ce90f2d8e39e2e635d49e498d1"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:6db3cfb9b4fcecb4390db154e75b49578c87a3b9979b40cdf90d7e4b945656e1"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:debb633f3f7856f95ad957d9b9c781f8e2c6303ef21724ec94bea2ce2fcbd056"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-win32.whl", hash = "sha256:87071618d3d8ec8b186d53cb6e66955ef2a0e4fa63ccd3709c0c90ac5a43520f"}, + {file = "charset_normalizer-3.3.1-cp310-cp310-win_amd64.whl", hash = "sha256:e372d7dfd154009142631de2d316adad3cc1c36c32a38b16a4751ba78da2a397"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:ae4070f741f8d809075ef697877fd350ecf0b7c5837ed68738607ee0a2c572cf"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:58e875eb7016fd014c0eea46c6fa92b87b62c0cb31b9feae25cbbe62c919f54d"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:dbd95e300367aa0827496fe75a1766d198d34385a58f97683fe6e07f89ca3e3c"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:de0b4caa1c8a21394e8ce971997614a17648f94e1cd0640fbd6b4d14cab13a72"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:985c7965f62f6f32bf432e2681173db41336a9c2611693247069288bcb0c7f8b"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a15c1fe6d26e83fd2e5972425a772cca158eae58b05d4a25a4e474c221053e2d"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ae55d592b02c4349525b6ed8f74c692509e5adffa842e582c0f861751701a673"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:be4d9c2770044a59715eb57c1144dedea7c5d5ae80c68fb9959515037cde2008"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:851cf693fb3aaef71031237cd68699dded198657ec1e76a76eb8be58c03a5d1f"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:31bbaba7218904d2eabecf4feec0d07469284e952a27400f23b6628439439fa7"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-musllinux_1_1_ppc64le.whl", hash = "sha256:871d045d6ccc181fd863a3cd66ee8e395523ebfbc57f85f91f035f50cee8e3d4"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-musllinux_1_1_s390x.whl", hash = "sha256:501adc5eb6cd5f40a6f77fbd90e5ab915c8fd6e8c614af2db5561e16c600d6f3"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:f5fb672c396d826ca16a022ac04c9dce74e00a1c344f6ad1a0fdc1ba1f332213"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-win32.whl", hash = "sha256:bb06098d019766ca16fc915ecaa455c1f1cd594204e7f840cd6258237b5079a8"}, + {file = "charset_normalizer-3.3.1-cp311-cp311-win_amd64.whl", hash = "sha256:8af5a8917b8af42295e86b64903156b4f110a30dca5f3b5aedea123fbd638bff"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:7ae8e5142dcc7a49168f4055255dbcced01dc1714a90a21f87448dc8d90617d1"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:5b70bab78accbc672f50e878a5b73ca692f45f5b5e25c8066d748c09405e6a55"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:5ceca5876032362ae73b83347be8b5dbd2d1faf3358deb38c9c88776779b2e2f"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:34d95638ff3613849f473afc33f65c401a89f3b9528d0d213c7037c398a51296"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:9edbe6a5bf8b56a4a84533ba2b2f489d0046e755c29616ef8830f9e7d9cf5728"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f6a02a3c7950cafaadcd46a226ad9e12fc9744652cc69f9e5534f98b47f3bbcf"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10b8dd31e10f32410751b3430996f9807fc4d1587ca69772e2aa940a82ab571a"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:edc0202099ea1d82844316604e17d2b175044f9bcb6b398aab781eba957224bd"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:b891a2f68e09c5ef989007fac11476ed33c5c9994449a4e2c3386529d703dc8b"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:71ef3b9be10070360f289aea4838c784f8b851be3ba58cf796262b57775c2f14"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-musllinux_1_1_ppc64le.whl", hash = "sha256:55602981b2dbf8184c098bc10287e8c245e351cd4fdcad050bd7199d5a8bf514"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-musllinux_1_1_s390x.whl", hash = "sha256:46fb9970aa5eeca547d7aa0de5d4b124a288b42eaefac677bde805013c95725c"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:520b7a142d2524f999447b3a0cf95115df81c4f33003c51a6ab637cbda9d0bf4"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-win32.whl", hash = "sha256:8ec8ef42c6cd5856a7613dcd1eaf21e5573b2185263d87d27c8edcae33b62a61"}, + {file = "charset_normalizer-3.3.1-cp312-cp312-win_amd64.whl", hash = "sha256:baec8148d6b8bd5cee1ae138ba658c71f5b03e0d69d5907703e3e1df96db5e41"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:63a6f59e2d01310f754c270e4a257426fe5a591dc487f1983b3bbe793cf6bac6"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1d6bfc32a68bc0933819cfdfe45f9abc3cae3877e1d90aac7259d57e6e0f85b1"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:4f3100d86dcd03c03f7e9c3fdb23d92e32abbca07e7c13ebd7ddfbcb06f5991f"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:39b70a6f88eebe239fa775190796d55a33cfb6d36b9ffdd37843f7c4c1b5dc67"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4e12f8ee80aa35e746230a2af83e81bd6b52daa92a8afaef4fea4a2ce9b9f4fa"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7b6cefa579e1237ce198619b76eaa148b71894fb0d6bcf9024460f9bf30fd228"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:61f1e3fb621f5420523abb71f5771a204b33c21d31e7d9d86881b2cffe92c47c"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:4f6e2a839f83a6a76854d12dbebde50e4b1afa63e27761549d006fa53e9aa80e"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:1ec937546cad86d0dce5396748bf392bb7b62a9eeb8c66efac60e947697f0e58"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:82ca51ff0fc5b641a2d4e1cc8c5ff108699b7a56d7f3ad6f6da9dbb6f0145b48"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:633968254f8d421e70f91c6ebe71ed0ab140220469cf87a9857e21c16687c034"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-win32.whl", hash = "sha256:c0c72d34e7de5604df0fde3644cc079feee5e55464967d10b24b1de268deceb9"}, + {file = "charset_normalizer-3.3.1-cp37-cp37m-win_amd64.whl", hash = "sha256:63accd11149c0f9a99e3bc095bbdb5a464862d77a7e309ad5938fbc8721235ae"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:5a3580a4fdc4ac05f9e53c57f965e3594b2f99796231380adb2baaab96e22761"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:2465aa50c9299d615d757c1c888bc6fef384b7c4aec81c05a0172b4400f98557"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:cb7cd68814308aade9d0c93c5bd2ade9f9441666f8ba5aa9c2d4b389cb5e2a45"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:91e43805ccafa0a91831f9cd5443aa34528c0c3f2cc48c4cb3d9a7721053874b"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:854cc74367180beb327ab9d00f964f6d91da06450b0855cbbb09187bcdb02de5"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c15070ebf11b8b7fd1bfff7217e9324963c82dbdf6182ff7050519e350e7ad9f"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2c4c99f98fc3a1835af8179dcc9013f93594d0670e2fa80c83aa36346ee763d2"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3fb765362688821404ad6cf86772fc54993ec11577cd5a92ac44b4c2ba52155b"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:dced27917823df984fe0c80a5c4ad75cf58df0fbfae890bc08004cd3888922a2"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:a66bcdf19c1a523e41b8e9d53d0cedbfbac2e93c649a2e9502cb26c014d0980c"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:ecd26be9f112c4f96718290c10f4caea6cc798459a3a76636b817a0ed7874e42"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:3f70fd716855cd3b855316b226a1ac8bdb3caf4f7ea96edcccc6f484217c9597"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:17a866d61259c7de1bdadef418a37755050ddb4b922df8b356503234fff7932c"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-win32.whl", hash = "sha256:548eefad783ed787b38cb6f9a574bd8664468cc76d1538215d510a3cd41406cb"}, + {file = "charset_normalizer-3.3.1-cp38-cp38-win_amd64.whl", hash = "sha256:45f053a0ece92c734d874861ffe6e3cc92150e32136dd59ab1fb070575189c97"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:bc791ec3fd0c4309a753f95bb6c749ef0d8ea3aea91f07ee1cf06b7b02118f2f"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:0c8c61fb505c7dad1d251c284e712d4e0372cef3b067f7ddf82a7fa82e1e9a93"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:2c092be3885a1b7899cd85ce24acedc1034199d6fca1483fa2c3a35c86e43041"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c2000c54c395d9e5e44c99dc7c20a64dc371f777faf8bae4919ad3e99ce5253e"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:4cb50a0335382aac15c31b61d8531bc9bb657cfd848b1d7158009472189f3d62"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:c30187840d36d0ba2893bc3271a36a517a717f9fd383a98e2697ee890a37c273"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fe81b35c33772e56f4b6cf62cf4aedc1762ef7162a31e6ac7fe5e40d0149eb67"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:d0bf89afcbcf4d1bb2652f6580e5e55a840fdf87384f6063c4a4f0c95e378656"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:06cf46bdff72f58645434d467bf5228080801298fbba19fe268a01b4534467f5"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:3c66df3f41abee950d6638adc7eac4730a306b022570f71dd0bd6ba53503ab57"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:cd805513198304026bd379d1d516afbf6c3c13f4382134a2c526b8b854da1c2e"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:9505dc359edb6a330efcd2be825fdb73ee3e628d9010597aa1aee5aa63442e97"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:31445f38053476a0c4e6d12b047b08ced81e2c7c712e5a1ad97bc913256f91b2"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-win32.whl", hash = "sha256:bd28b31730f0e982ace8663d108e01199098432a30a4c410d06fe08fdb9e93f4"}, + {file = "charset_normalizer-3.3.1-cp39-cp39-win_amd64.whl", hash = "sha256:555fe186da0068d3354cdf4bbcbc609b0ecae4d04c921cc13e209eece7720727"}, + {file = "charset_normalizer-3.3.1-py3-none-any.whl", hash = "sha256:800561453acdecedaac137bf09cd719c7a440b6800ec182f077bb8e7025fb708"}, ] [[package]] @@ -739,34 +741,34 @@ files = [ [[package]] name = "cryptography" -version = "41.0.4" +version = "41.0.5" description = "cryptography is a package which provides cryptographic recipes and primitives to Python developers." optional = false python-versions = ">=3.7" files = [ - {file = "cryptography-41.0.4-cp37-abi3-macosx_10_12_universal2.whl", hash = "sha256:80907d3faa55dc5434a16579952ac6da800935cd98d14dbd62f6f042c7f5e839"}, - {file = "cryptography-41.0.4-cp37-abi3-macosx_10_12_x86_64.whl", hash = "sha256:35c00f637cd0b9d5b6c6bd11b6c3359194a8eba9c46d4e875a3660e3b400005f"}, - {file = "cryptography-41.0.4-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:cecfefa17042941f94ab54f769c8ce0fe14beff2694e9ac684176a2535bf9714"}, - {file = "cryptography-41.0.4-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e40211b4923ba5a6dc9769eab704bdb3fbb58d56c5b336d30996c24fcf12aadb"}, - {file = "cryptography-41.0.4-cp37-abi3-manylinux_2_28_aarch64.whl", hash = "sha256:23a25c09dfd0d9f28da2352503b23e086f8e78096b9fd585d1d14eca01613e13"}, - {file = "cryptography-41.0.4-cp37-abi3-manylinux_2_28_x86_64.whl", hash = "sha256:2ed09183922d66c4ec5fdaa59b4d14e105c084dd0febd27452de8f6f74704143"}, - {file = "cryptography-41.0.4-cp37-abi3-musllinux_1_1_aarch64.whl", hash = "sha256:5a0f09cefded00e648a127048119f77bc2b2ec61e736660b5789e638f43cc397"}, - {file = "cryptography-41.0.4-cp37-abi3-musllinux_1_1_x86_64.whl", hash = "sha256:9eeb77214afae972a00dee47382d2591abe77bdae166bda672fb1e24702a3860"}, - {file = "cryptography-41.0.4-cp37-abi3-win32.whl", hash = "sha256:3b224890962a2d7b57cf5eeb16ccaafba6083f7b811829f00476309bce2fe0fd"}, - {file = "cryptography-41.0.4-cp37-abi3-win_amd64.whl", hash = "sha256:c880eba5175f4307129784eca96f4e70b88e57aa3f680aeba3bab0e980b0f37d"}, - {file = "cryptography-41.0.4-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:004b6ccc95943f6a9ad3142cfabcc769d7ee38a3f60fb0dddbfb431f818c3a67"}, - {file = "cryptography-41.0.4-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:86defa8d248c3fa029da68ce61fe735432b047e32179883bdb1e79ed9bb8195e"}, - {file = "cryptography-41.0.4-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:37480760ae08065437e6573d14be973112c9e6dcaf5f11d00147ee74f37a3829"}, - {file = "cryptography-41.0.4-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:b5f4dfe950ff0479f1f00eda09c18798d4f49b98f4e2006d644b3301682ebdca"}, - {file = "cryptography-41.0.4-pp38-pypy38_pp73-macosx_10_12_x86_64.whl", hash = "sha256:7e53db173370dea832190870e975a1e09c86a879b613948f09eb49324218c14d"}, - {file = "cryptography-41.0.4-pp38-pypy38_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:5b72205a360f3b6176485a333256b9bcd48700fc755fef51c8e7e67c4b63e3ac"}, - {file = "cryptography-41.0.4-pp38-pypy38_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:93530900d14c37a46ce3d6c9e6fd35dbe5f5601bf6b3a5c325c7bffc030344d9"}, - {file = "cryptography-41.0.4-pp38-pypy38_pp73-win_amd64.whl", hash = "sha256:efc8ad4e6fc4f1752ebfb58aefece8b4e3c4cae940b0994d43649bdfce8d0d4f"}, - {file = "cryptography-41.0.4-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:c3391bd8e6de35f6f1140e50aaeb3e2b3d6a9012536ca23ab0d9c35ec18c8a91"}, - {file = "cryptography-41.0.4-pp39-pypy39_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:0d9409894f495d465fe6fda92cb70e8323e9648af912d5b9141d616df40a87b8"}, - {file = "cryptography-41.0.4-pp39-pypy39_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:8ac4f9ead4bbd0bc8ab2d318f97d85147167a488be0e08814a37eb2f439d5cf6"}, - {file = "cryptography-41.0.4-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:047c4603aeb4bbd8db2756e38f5b8bd7e94318c047cfe4efeb5d715e08b49311"}, - {file = "cryptography-41.0.4.tar.gz", hash = "sha256:7febc3094125fc126a7f6fb1f420d0da639f3f32cb15c8ff0dc3997c4549f51a"}, + {file = "cryptography-41.0.5-cp37-abi3-macosx_10_12_universal2.whl", hash = "sha256:da6a0ff8f1016ccc7477e6339e1d50ce5f59b88905585f77193ebd5068f1e797"}, + {file = "cryptography-41.0.5-cp37-abi3-macosx_10_12_x86_64.whl", hash = "sha256:b948e09fe5fb18517d99994184854ebd50b57248736fd4c720ad540560174ec5"}, + {file = "cryptography-41.0.5-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d38e6031e113b7421db1de0c1b1f7739564a88f1684c6b89234fbf6c11b75147"}, + {file = "cryptography-41.0.5-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e270c04f4d9b5671ebcc792b3ba5d4488bf7c42c3c241a3748e2599776f29696"}, + {file = "cryptography-41.0.5-cp37-abi3-manylinux_2_28_aarch64.whl", hash = "sha256:ec3b055ff8f1dce8e6ef28f626e0972981475173d7973d63f271b29c8a2897da"}, + {file = "cryptography-41.0.5-cp37-abi3-manylinux_2_28_x86_64.whl", hash = "sha256:7d208c21e47940369accfc9e85f0de7693d9a5d843c2509b3846b2db170dfd20"}, + {file = "cryptography-41.0.5-cp37-abi3-musllinux_1_1_aarch64.whl", hash = "sha256:8254962e6ba1f4d2090c44daf50a547cd5f0bf446dc658a8e5f8156cae0d8548"}, + {file = "cryptography-41.0.5-cp37-abi3-musllinux_1_1_x86_64.whl", hash = "sha256:a48e74dad1fb349f3dc1d449ed88e0017d792997a7ad2ec9587ed17405667e6d"}, + {file = "cryptography-41.0.5-cp37-abi3-win32.whl", hash = "sha256:d3977f0e276f6f5bf245c403156673db103283266601405376f075c849a0b936"}, + {file = "cryptography-41.0.5-cp37-abi3-win_amd64.whl", hash = "sha256:73801ac9736741f220e20435f84ecec75ed70eda90f781a148f1bad546963d81"}, + {file = "cryptography-41.0.5-pp310-pypy310_pp73-macosx_10_12_x86_64.whl", hash = "sha256:3be3ca726e1572517d2bef99a818378bbcf7d7799d5372a46c79c29eb8d166c1"}, + {file = "cryptography-41.0.5-pp310-pypy310_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:e886098619d3815e0ad5790c973afeee2c0e6e04b4da90b88e6bd06e2a0b1b72"}, + {file = "cryptography-41.0.5-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:573eb7128cbca75f9157dcde974781209463ce56b5804983e11a1c462f0f4e88"}, + {file = "cryptography-41.0.5-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:0c327cac00f082013c7c9fb6c46b7cc9fa3c288ca702c74773968173bda421bf"}, + {file = "cryptography-41.0.5-pp38-pypy38_pp73-macosx_10_12_x86_64.whl", hash = "sha256:227ec057cd32a41c6651701abc0328135e472ed450f47c2766f23267b792a88e"}, + {file = "cryptography-41.0.5-pp38-pypy38_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:22892cc830d8b2c89ea60148227631bb96a7da0c1b722f2aac8824b1b7c0b6b8"}, + {file = "cryptography-41.0.5-pp38-pypy38_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:5a70187954ba7292c7876734183e810b728b4f3965fbe571421cb2434d279179"}, + {file = "cryptography-41.0.5-pp38-pypy38_pp73-win_amd64.whl", hash = "sha256:88417bff20162f635f24f849ab182b092697922088b477a7abd6664ddd82291d"}, + {file = "cryptography-41.0.5-pp39-pypy39_pp73-macosx_10_12_x86_64.whl", hash = "sha256:c707f7afd813478e2019ae32a7c49cd932dd60ab2d2a93e796f68236b7e1fbf1"}, + {file = "cryptography-41.0.5-pp39-pypy39_pp73-manylinux_2_28_aarch64.whl", hash = "sha256:580afc7b7216deeb87a098ef0674d6ee34ab55993140838b14c9b83312b37b86"}, + {file = "cryptography-41.0.5-pp39-pypy39_pp73-manylinux_2_28_x86_64.whl", hash = "sha256:fba1e91467c65fe64a82c689dc6cf58151158993b13eb7a7f3f4b7f395636723"}, + {file = "cryptography-41.0.5-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:0d2a6a598847c46e3e321a7aef8af1436f11c27f1254933746304ff014664d84"}, + {file = "cryptography-41.0.5.tar.gz", hash = "sha256:392cb88b597247177172e02da6b7a63deeff1937fa6fec3bbf902ebd75d97ec7"}, ] [package.dependencies] @@ -1125,22 +1127,22 @@ test = ["eth-hash[pycryptodome]", "pytest (>=6.2.5,<7)", "pytest-xdist", "tox (= [[package]] name = "eth-typing" -version = "3.5.0" +version = "3.5.1" description = "eth-typing: Common type annotations for ethereum python packages" optional = false python-versions = ">=3.7.2, <4" files = [ - {file = "eth-typing-3.5.0.tar.gz", hash = "sha256:a92f6896896752143a4704c57441eedf7b1f65d5df4b1c20cb802bb4aa602d7e"}, - {file = "eth_typing-3.5.0-py3-none-any.whl", hash = "sha256:a773dbb7d78fcd1539c30264193ca26ec965f3abca2711748e307f117b0a10f5"}, + {file = "eth-typing-3.5.1.tar.gz", hash = "sha256:e21a8b0688581a6765f72fa184d86d06c3949e354d4af5293798abc0b4255989"}, + {file = "eth_typing-3.5.1-py3-none-any.whl", hash = "sha256:9d80c7d112a8774bddeb7278b1bc2f17ca4c062825476ce6bc9cba4d47956010"}, ] [package.dependencies] typing-extensions = ">=4.0.1" [package.extras] -dev = ["black (>=23)", "build (>=0.9.0)", "bumpversion (>=0.5.3)", "flake8 (==6.0.0)", "flake8-bugbear (==23.3.23)", "ipython", "isort (>=5.10.1)", "mypy (==0.971)", "pydocstyle (>=6.0.0)", "pytest (>=7.0.0)", "pytest-watch (>=4.1.0)", "pytest-xdist (>=2.4.0)", "sphinx (>=5.0.0)", "sphinx-rtd-theme (>=1.0.0)", "towncrier (>=21,<22)", "tox (>=4.0.0)", "twine", "wheel"] +dev = ["black (>=23)", "build (>=0.9.0)", "bumpversion (>=0.5.3)", "flake8 (==6.0.0)", "flake8-bugbear (==23.3.23)", "ipython", "isort (>=5.10.1)", "mypy (==0.971)", "pydocstyle (>=6.0.0)", "pytest (>=7.0.0)", "pytest-watch (>=4.1.0)", "pytest-xdist (>=2.4.0)", "sphinx (>=5.0.0)", "sphinx-rtd-theme (>=1.0.0)", "towncrier (>=21,<22)", "tox (>=4.0.0)", "twine", "types-setuptools", "wheel"] docs = ["sphinx (>=5.0.0)", "sphinx-rtd-theme (>=1.0.0)", "towncrier (>=21,<22)"] -lint = ["black (>=23)", "flake8 (==6.0.0)", "flake8-bugbear (==23.3.23)", "isort (>=5.10.1)", "mypy (==0.971)", "pydocstyle (>=6.0.0)"] +lint = ["black (>=23)", "flake8 (==6.0.0)", "flake8-bugbear (==23.3.23)", "isort (>=5.10.1)", "mypy (==0.971)", "pydocstyle (>=6.0.0)", "types-setuptools"] test = ["pytest (>=7.0.0)", "pytest-xdist (>=2.4.0)"] [[package]] @@ -1241,13 +1243,13 @@ grpcio-gcp = ["grpcio-gcp (>=0.2.2,<1.0.dev0)"] [[package]] name = "google-api-python-client" -version = "2.104.0" +version = "2.105.0" description = "Google API Client Library for Python" optional = false python-versions = ">=3.7" files = [ - {file = "google-api-python-client-2.104.0.tar.gz", hash = "sha256:bbc66520e7fe9417b93fd113f2a0a1afa789d686de9009b6e94e48fdea50a60f"}, - {file = "google_api_python_client-2.104.0-py2.py3-none-any.whl", hash = "sha256:867061526aa6dc6c1481d118e913a8a38a02a01eed589413968397ebd77df71d"}, + {file = "google-api-python-client-2.105.0.tar.gz", hash = "sha256:0a8b32cfc2d9b3c1868ae6faef7ee1ab9c89a6cec30be709ea9c97f9a3e5902d"}, + {file = "google_api_python_client-2.105.0-py2.py3-none-any.whl", hash = "sha256:571ce7c41e53415e385aab5a955725f71780550683ffcb71596f5809677d40b7"}, ] [package.dependencies] @@ -1828,17 +1830,18 @@ files = [ [[package]] name = "open-aea" -version = "1.39.0.post1" +version = "1.41.0" description = "Open Autonomous Economic Agent framework (without vendor lock-in)" optional = false python-versions = ">=3.8" files = [ - {file = "open-aea-1.39.0.post1.tar.gz", hash = "sha256:50d9d843ae9a16f4737603d107e4c8293168b92b4a8523cf3a5f51427bd8e94d"}, - {file = "open_aea-1.39.0.post1-py3-none-macosx_10_9_x86_64.whl", hash = "sha256:2cbe5bbdf0edb3e5ee434dd4728353f7f9c9cfe6d0f4c1aa26c1b1f63ecd7733"}, - {file = "open_aea-1.39.0.post1-py3-none-manylinux1_x86_64.whl", hash = "sha256:13b1555ecedd506aa70de9bf3b7d448cc0faf2370a30e8ef9bb099439a7f571d"}, - {file = "open_aea-1.39.0.post1-py3-none-manylinux2014_aarch64.whl", hash = "sha256:c4bf41f668e7a8c8e97d952d7072e823eb08e0893d9016261f0ad34e9bc7b71c"}, - {file = "open_aea-1.39.0.post1-py3-none-win32.whl", hash = "sha256:dfa7af61572c2c738aed6fbe48afe045a1f0ee64342fe4d588d990a9c1e0663d"}, - {file = "open_aea-1.39.0.post1-py3-none-win_amd64.whl", hash = "sha256:77f7e0f5c4c7bebbfe7051fb3610d4696dd43f7ef15d05c1ea1cdfde7fe453ae"}, + {file = "open-aea-1.41.0.tar.gz", hash = "sha256:d9b759e17781b33548f7af6888e2f12f6d039444d54b41958cee1e2f9d7b8f14"}, + {file = "open_aea-1.41.0-py3-none-any.whl", hash = "sha256:c28a4d4150fd41a3f5d2900c13e1814943148d0d9f8fb2e070e5ff65b3b069e5"}, + {file = "open_aea-1.41.0-py3-none-macosx_10_9_x86_64.whl", hash = "sha256:3878d56ae8fa9e313196efab189c4c6e078e45a6e315ae9374845d1d64641166"}, + {file = "open_aea-1.41.0-py3-none-manylinux1_x86_64.whl", hash = "sha256:f3199d38929d56138b6f50e35ee0efb1815e3fa1de9a15ad51aaef7a8757b96a"}, + {file = "open_aea-1.41.0-py3-none-manylinux2014_aarch64.whl", hash = "sha256:df8100a08637dd0d7b6651d88b7f95efcc4403a4849f298a8a5a31a9dd5a17e9"}, + {file = "open_aea-1.41.0-py3-none-win32.whl", hash = "sha256:74c3c1b79b10461fa03e024103ba39e4a04e067e2e45ca19af16fcdcd2eb5dcd"}, + {file = "open_aea-1.41.0-py3-none-win_amd64.whl", hash = "sha256:d14bc82fc53120aa2af20d5fa3b335fa93f98f7a9cfad33799def110c9e82a0d"}, ] [package.dependencies] @@ -1849,7 +1852,7 @@ ecdsa = ">=0.15,<0.17.0" jsonschema = ">=4.16.0,<=4.19.0" morphys = ">=1.0" packaging = ">=23.1,<24.0" -protobuf = ">=3.19.0,<4.0.0" +protobuf = ">=4.21.6,<5.0.0" py-multibase = ">=1.0.0" py-multicodec = ">=0.2.0" pymultihash = "0.8.2" @@ -1889,13 +1892,13 @@ develop = ["coverage (>=5.3)", "flake8 (>=3.8)", "isort (>=5.8)", "mypy (>=0.900 [[package]] name = "open-aea-cli-ipfs" -version = "1.39.0.post1" +version = "1.41.0" description = "CLI extension for open AEA framework wrapping IPFS functionality." optional = false python-versions = "*" files = [ - {file = "open-aea-cli-ipfs-1.39.0.post1.tar.gz", hash = "sha256:c70d98343eab15225f1b1339212bb8de7755e2d6b48a38e7961d1174e9904505"}, - {file = "open_aea_cli_ipfs-1.39.0.post1-py3-none-any.whl", hash = "sha256:4cef5729e91fa89016840da1684e552c1f8c75a0cf0b82ea48066d4b841b49e7"}, + {file = "open-aea-cli-ipfs-1.41.0.tar.gz", hash = "sha256:e02cbc05b38205040fbc8659e9dcbf4d05044329a4e9b0496a400186fc3f18f6"}, + {file = "open_aea_cli_ipfs-1.41.0-py3-none-any.whl", hash = "sha256:bebf2ed31f72e99821db481e6a50cecf107001749bf13f29339f1861155fc305"}, ] [package.dependencies] @@ -1905,13 +1908,13 @@ pytest = ">=7.0.0,<7.3.0" [[package]] name = "open-aea-cosmpy" -version = "0.6.5" +version = "0.6.6" description = "A library for interacting with the cosmos networks" optional = false python-versions = ">=3.8,<4.0" files = [ - {file = "open_aea_cosmpy-0.6.5-py3-none-any.whl", hash = "sha256:84dee91523e41402f1dc7f1f02e4869ae089ee2a25ad0d577dccfd11448f6b7f"}, - {file = "open_aea_cosmpy-0.6.5.tar.gz", hash = "sha256:922e14166fd48f2a2b726b54390bb74887c5450ac1ff4af32dada6ecea8077da"}, + {file = "open_aea_cosmpy-0.6.6-py3-none-any.whl", hash = "sha256:0e8beca421383dce13c19d6d305d96e0905ba3171b97c7d0528e1480fee670dc"}, + {file = "open_aea_cosmpy-0.6.6.tar.gz", hash = "sha256:ae5a40b61fdf4af511e60acb2cdfa3dffef57324e975dcadd87c1f02cf8e6c27"}, ] [package.dependencies] @@ -1923,104 +1926,70 @@ google-api-python-client = "*" grpcio = "1.53.0" jsonschema = ">=3.2.0,<5" open-aea-bip-utils = "2.7.2" -protobuf = "3.19.5" +protobuf = ">=4.21.6,<5" requests = "*" [[package]] name = "open-aea-ledger-cosmos" -version = "1.39.0.post1" +version = "1.41.0" description = "Python package wrapping the public and private key cryptography and ledger api of Cosmos." optional = false python-versions = "*" files = [ - {file = "open-aea-ledger-cosmos-1.39.0.post1.tar.gz", hash = "sha256:ecb0f283fe0e66979ae5dbfbb9e6860d62d646abdb623acc7c69065ad81c31d8"}, - {file = "open_aea_ledger_cosmos-1.39.0.post1-py3-none-any.whl", hash = "sha256:aad946fa52837155ea7f6e0f129af342b58872f1a73532a7972164647ad6e725"}, + {file = "open-aea-ledger-cosmos-1.41.0.tar.gz", hash = "sha256:505c11494ecd3b1ba0460b7b346be982cf5de8797d2a53668f06a9d74c92a0d9"}, + {file = "open_aea_ledger_cosmos-1.41.0-py3-none-any.whl", hash = "sha256:3c41ecb17b9378430baf8fafdaf38828e90ed94b6b9ae9ea9965c5ec3a2ee62e"}, ] [package.dependencies] bech32 = "1.2.0" ecdsa = ">=0.15,<0.17.0" open-aea = ">=1.0.0,<2.0.0" -open-aea-cosmpy = "0.6.5" +open-aea-cosmpy = "0.6.6" pycryptodome = ">=3.10.1,<4.0.0" [[package]] name = "open-aea-ledger-ethereum" -version = "1.39.0.post1" +version = "1.41.0" description = "Python package wrapping the public and private key cryptography and ledger api of Ethereum." optional = false python-versions = "*" files = [ - {file = "open-aea-ledger-ethereum-1.39.0.post1.tar.gz", hash = "sha256:e1f221c576ca10b542c9dea60efdd170767aa409f38b580776e3cb9480afe0e2"}, - {file = "open_aea_ledger_ethereum-1.39.0.post1-py3-none-any.whl", hash = "sha256:4bbbc2b6756e89fae57bcdc932fa8043770b971da90857740ee692be1b38fadf"}, + {file = "open-aea-ledger-ethereum-1.41.0.tar.gz", hash = "sha256:411f75ee0a313ed88752fe8b50550eaf48cfc02f683c11a5f8a36e1ea10b4a6a"}, + {file = "open_aea_ledger_ethereum-1.41.0-py3-none-any.whl", hash = "sha256:cfb5ee22b9123741af669821bc954ba233eafea8c2880c3d125038c141512dab"}, ] [package.dependencies] eth-account = ">=0.8.0,<0.9.0" ipfshttpclient = "0.8.0a2" open-aea = ">=1.0.0,<2.0.0" -open-aea-web3 = "6.0.1" +web3 = ">=6.0.0,<7" [[package]] name = "open-aea-test-autonomy" -version = "0.12.1.post4" +version = "0.13.1" description = "Plugin containing test tools for open-autonomy packages." optional = false python-versions = "*" files = [ - {file = "open-aea-test-autonomy-0.12.1.post4.tar.gz", hash = "sha256:c481ac23a59e9ba954ae4d3b1e86fb72982dbdcf5b1e8a351d3eb1c87003b861"}, - {file = "open_aea_test_autonomy-0.12.1.post4-py3-none-any.whl", hash = "sha256:0bdeb2a1d84d3aecfc2c169ff762205fb2c091ffa601846a489678db7d0b01c3"}, + {file = "open-aea-test-autonomy-0.13.1.tar.gz", hash = "sha256:0e770ff9fc39369bcd4995608b789f466e3287fcb16052aa2d8cb45afdd923b7"}, + {file = "open_aea_test_autonomy-0.13.1-py3-none-any.whl", hash = "sha256:a464e317c57d18073fa2b6837d0637638662edc600bab91214bf113119aa1fc1"}, ] [package.dependencies] docker = "6.1.2" -open-aea = {version = ">=1.39.0.post1,<2.0.0", extras = ["all"]} -open-aea-ledger-ethereum = ">=1.39.0.post1,<2.0.0" +open-aea = {version = ">=1.41.0,<2.0.0", extras = ["all"]} +open-aea-ledger-ethereum = ">=1.41.0,<2.0.0" pytest = "7.2.1" -[[package]] -name = "open-aea-web3" -version = "6.0.1" -description = "web3.py" -optional = false -python-versions = ">=3.7.2" -files = [ - {file = "open-aea-web3-6.0.1.tar.gz", hash = "sha256:202957204e743c65a10d4df46b39df44c4177a141f9dd29bf44ae0d868eab768"}, - {file = "open_aea_web3-6.0.1-py3-none-any.whl", hash = "sha256:73a90d9c61b76fb4f15909e6a70fc91319428dbf3ee83f3830355abc98f22331"}, -] - -[package.dependencies] -aiohttp = ">=3.7.4.post0" -eth-abi = ">=4.0.0-b.2" -eth-account = ">=0.8.0" -eth-hash = {version = ">=0.5.1", extras = ["pycryptodome"]} -eth-typing = ">=3.0.0" -eth-utils = ">=2.1.0" -hexbytes = ">=0.1.0" -jsonschema = ">=4.0.0" -lru-dict = ">=1.1.6" -parsimonious = "0.9.0" -protobuf = "3.19.5" -pywin32 = {version = ">=223", markers = "platform_system == \"Windows\""} -requests = ">=2.16.0" -websockets = ">=10.0.0" - -[package.extras] -dev = ["black (>=22.1.0)", "build (>=0.9.0)", "bumpversion", "click (>=5.1)", "configparser (==3.5.0)", "contextlib2 (>=0.5.4)", "eth-tester[py-evm] (==v0.8.0-b.3)", "flake8 (==3.8.3)", "flaky (>=3.7.0)", "hypothesis (>=3.31.2)", "importlib-metadata (<5.0)", "ipfshttpclient (==0.8.0a2)", "isort (>=5.11.0)", "mock", "mypy (==0.910)", "pluggy (==0.13.1)", "py-geth (>=3.11.0)", "py-solc-x (>=1.1.1)", "pytest (>=6.2.5)", "pytest-asyncio (>=0.18.1)", "pytest-mock (>=1.10)", "pytest-pythonpath (>=0.3)", "pytest-watch (>=4.2)", "pytest-xdist (>=1.29)", "setuptools (>=38.6.0)", "sphinx (>=4.2.0)", "sphinx-rtd-theme (>=0.5.2)", "toposort (>=1.4)", "towncrier (==18.5.0)", "tox (>=3.18.0)", "tqdm (>4.32)", "twine (>=1.13)", "types-protobuf (==3.19.13)", "types-requests (>=2.26.1)", "types-setuptools (>=57.4.4)", "urllib3", "wheel", "when-changed (>=0.3.0)"] -docs = ["click (>=5.1)", "configparser (==3.5.0)", "contextlib2 (>=0.5.4)", "mock", "py-geth (>=3.11.0)", "py-solc-x (>=1.1.1)", "pytest (>=6.2.5)", "sphinx (>=4.2.0)", "sphinx-rtd-theme (>=0.5.2)", "toposort (>=1.4)", "towncrier (==18.5.0)", "urllib3", "wheel"] -ipfs = ["ipfshttpclient (==0.8.0a2)"] -linter = ["black (>=22.1.0)", "flake8 (==3.8.3)", "isort (>=5.11.0)", "mypy (==0.910)", "types-protobuf (==3.19.13)", "types-requests (>=2.26.1)", "types-setuptools (>=57.4.4)"] -tester = ["eth-tester[py-evm] (==v0.8.0-b.3)", "py-geth (>=3.11.0)"] - [[package]] name = "open-autonomy" -version = "0.12.1.post4" +version = "0.13.1" description = "A framework for the creation of autonomous agent services." optional = false python-versions = ">=3.8" files = [ - {file = "open-autonomy-0.12.1.post4.tar.gz", hash = "sha256:7bd5a2dc3b5720f80ca1290b35def793f958133e37333d93b8883f35281d3cb0"}, - {file = "open_autonomy-0.12.1.post4-py3-none-any.whl", hash = "sha256:e07b51904da87e2cb16ba75eff33b95b5c986c54c634801705c7a71a413876af"}, + {file = "open-autonomy-0.13.1.tar.gz", hash = "sha256:f517f13f78fbb82a71dcf8198346a6f32662c955592869e8e6f63d9743c05d88"}, + {file = "open_autonomy-0.13.1-py3-none-any.whl", hash = "sha256:ddbe81090c883a6a91a18c59fc0b51614a30a22f710ea8135f0e8c1b8f4c617e"}, ] [package.dependencies] @@ -2030,8 +1999,8 @@ docker = "6.1.2" Flask = ">=2.0.2,<3.0.0" hexbytes = "*" jsonschema = ">=4.16.0,<=4.19.0" -open-aea = {version = "1.39.0.post1", extras = ["all"]} -open-aea-cli-ipfs = "1.39.0.post1" +open-aea = {version = "1.41.0", extras = ["all"]} +open-aea-cli-ipfs = "1.41.0" pytest = "7.2.1" python-dotenv = ">=0.14.0,<0.18.0" texttable = "1.6.7" @@ -2040,8 +2009,8 @@ watchdog = ">=2.1.6" werkzeug = "2.0.3" [package.extras] -all = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.39.0.post1)", "pytest (>=7.0.0,<7.3.0)", "python-dotenv (>=0.14.0,<0.18.0)", "texttable (==1.6.7)"] -cli = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.39.0.post1)", "pytest (>=7.0.0,<7.3.0)", "python-dotenv (>=0.14.0,<0.18.0)", "texttable (==1.6.7)"] +all = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.41.0)", "pytest (>=7.0.0,<7.3.0)", "python-dotenv (>=0.14.0,<0.18.0)", "texttable (==1.6.7)"] +cli = ["click (==8.0.2)", "coverage (>=6.4.4,<8.0.0)", "open-aea-cli-ipfs (==1.41.0)", "pytest (>=7.0.0,<7.3.0)", "python-dotenv (>=0.14.0,<0.18.0)", "texttable (==1.6.7)"] [[package]] name = "packaging" @@ -2123,33 +2092,21 @@ name = "protobuf" version = "4.24.4" description = "" optional = false -python-versions = ">=3.5" +python-versions = ">=3.7" files = [ - {file = "protobuf-3.19.5-cp310-cp310-manylinux2014_aarch64.whl", hash = "sha256:f2b599a21c9a32e171ec29a2ac54e03297736c578698e11b099d031f79da114b"}, - {file = "protobuf-3.19.5-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f976234e20ab2785f54224bcdafa027674e23663b132fa3ca0caa291a6cfbde7"}, - {file = "protobuf-3.19.5-cp310-cp310-win32.whl", hash = "sha256:4ee2af7051d3b10c8a4fe6fd1a2c69f201fea36aeee7086cf202a692e1b99ee1"}, - {file = "protobuf-3.19.5-cp310-cp310-win_amd64.whl", hash = "sha256:dca2284378a5f2a86ffed35c6ac147d14c48b525eefcd1083e5a9ce28dfa8657"}, - {file = "protobuf-3.19.5-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:c0f80876a8ff0ae7064084ed094eb86497bd5a3812e6fc96a05318b92301674e"}, - {file = "protobuf-3.19.5-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3c4160b601220627f7e91154e572baf5e161a9c3f445a8242d536ee3d0b7b17c"}, - {file = "protobuf-3.19.5-cp36-cp36m-win32.whl", hash = "sha256:f2bde37667b18c2b5280df83bc799204394a5d2d774e4deaf9de0eb741df6833"}, - {file = "protobuf-3.19.5-cp36-cp36m-win_amd64.whl", hash = "sha256:1867f93b06a183f87696871bb8d1e99ee71dbb69d468ce1f0cc8bf3d30f982f3"}, - {file = "protobuf-3.19.5-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a89aa0c042e61e11ade320b802d6db4ee5391d8d973e46d3a48172c1597789f8"}, - {file = "protobuf-3.19.5-cp37-cp37m-manylinux2014_aarch64.whl", hash = "sha256:f9cebda093c2f6bfed88f1c17cdade09d4d96096421b344026feee236532d4de"}, - {file = "protobuf-3.19.5-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:67efb5d20618020aa9596e17bfc37ca068c28ec0c1507d9507f73c93d46c9855"}, - {file = "protobuf-3.19.5-cp37-cp37m-win32.whl", hash = "sha256:950abd6c00e7b51f87ae8b18a0ce4d69fea217f62f171426e77de5061f6d9850"}, - {file = "protobuf-3.19.5-cp37-cp37m-win_amd64.whl", hash = "sha256:d3973a2d58aefc7d1230725c2447ce7f86a71cbc094b86a77c6ee1505ac7cdb1"}, - {file = "protobuf-3.19.5-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:9e1d74032f56ff25f417cfe84c8147047732e5059137ca42efad20cbbd25f5e0"}, - {file = "protobuf-3.19.5-cp38-cp38-manylinux2014_aarch64.whl", hash = "sha256:d249519ba5ecf5dd6b18150c9b6bcde510b273714b696f3923ff8308fc11ae49"}, - {file = "protobuf-3.19.5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9f957ef53e872d58a0afd3bf6d80d48535d28c99b40e75e6634cbc33ea42fd54"}, - {file = "protobuf-3.19.5-cp38-cp38-win32.whl", hash = "sha256:5470f892961af464ae6eaf0f3099e2c1190ae8c7f36f174b89491281341f79ca"}, - {file = "protobuf-3.19.5-cp38-cp38-win_amd64.whl", hash = "sha256:c44e3282cff74ad18c7e8a0375f407f69ee50c2116364b44492a196293e08b21"}, - {file = "protobuf-3.19.5-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:66d14b5b90090353efe75c9fb1bf65ef7267383034688d255b500822e37d5c2f"}, - {file = "protobuf-3.19.5-cp39-cp39-manylinux2014_aarch64.whl", hash = "sha256:f4f909f4dde413dec435a44b0894956d55bb928ded7d6e3c726556ca4c796e84"}, - {file = "protobuf-3.19.5-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5266c36cc0af3bb3dbf44f199d225b33da66a9a5c3bdc2b14865ad10eddf0e37"}, - {file = "protobuf-3.19.5-cp39-cp39-win32.whl", hash = "sha256:6a02172b9650f819d01fb8e224fc69b0706458fc1ab4f1c669281243c71c1a5e"}, - {file = "protobuf-3.19.5-cp39-cp39-win_amd64.whl", hash = "sha256:696e6cfab94cc15a14946f2bf72719dced087d437adbd994fff34f38986628bc"}, - {file = "protobuf-3.19.5-py2.py3-none-any.whl", hash = "sha256:9e42b1cf2ecd8a1bd161239e693f22035ba99905ae6d7efeac8a0546c7ec1a27"}, - {file = "protobuf-3.19.5.tar.gz", hash = "sha256:e63b0b3c42e51c94add62b010366cd4979cb6d5f06158bcae8faac4c294f91e1"}, + {file = "protobuf-4.24.4-cp310-abi3-win32.whl", hash = "sha256:ec9912d5cb6714a5710e28e592ee1093d68c5ebfeda61983b3f40331da0b1ebb"}, + {file = "protobuf-4.24.4-cp310-abi3-win_amd64.whl", hash = "sha256:1badab72aa8a3a2b812eacfede5020472e16c6b2212d737cefd685884c191085"}, + {file = "protobuf-4.24.4-cp37-abi3-macosx_10_9_universal2.whl", hash = "sha256:8e61a27f362369c2f33248a0ff6896c20dcd47b5d48239cb9720134bef6082e4"}, + {file = "protobuf-4.24.4-cp37-abi3-manylinux2014_aarch64.whl", hash = "sha256:bffa46ad9612e6779d0e51ae586fde768339b791a50610d85eb162daeb23661e"}, + {file = "protobuf-4.24.4-cp37-abi3-manylinux2014_x86_64.whl", hash = "sha256:b493cb590960ff863743b9ff1452c413c2ee12b782f48beca77c8da3e2ffe9d9"}, + {file = "protobuf-4.24.4-cp37-cp37m-win32.whl", hash = "sha256:dbbed8a56e56cee8d9d522ce844a1379a72a70f453bde6243e3c86c30c2a3d46"}, + {file = "protobuf-4.24.4-cp37-cp37m-win_amd64.whl", hash = "sha256:6b7d2e1c753715dcfe9d284a25a52d67818dd43c4932574307daf836f0071e37"}, + {file = "protobuf-4.24.4-cp38-cp38-win32.whl", hash = "sha256:02212557a76cd99574775a81fefeba8738d0f668d6abd0c6b1d3adcc75503dbe"}, + {file = "protobuf-4.24.4-cp38-cp38-win_amd64.whl", hash = "sha256:2fa3886dfaae6b4c5ed2730d3bf47c7a38a72b3a1f0acb4d4caf68e6874b947b"}, + {file = "protobuf-4.24.4-cp39-cp39-win32.whl", hash = "sha256:b77272f3e28bb416e2071186cb39efd4abbf696d682cbb5dc731308ad37fa6dd"}, + {file = "protobuf-4.24.4-cp39-cp39-win_amd64.whl", hash = "sha256:9fee5e8aa20ef1b84123bb9232b3f4a5114d9897ed89b4b8142d81924e05d79b"}, + {file = "protobuf-4.24.4-py3-none-any.whl", hash = "sha256:80797ce7424f8c8d2f2547e2d42bfbb6c08230ce5832d6c099a37335c9c90a92"}, + {file = "protobuf-4.24.4.tar.gz", hash = "sha256:5a70731910cd9104762161719c3d883c960151eea077134458503723b60e3667"}, ] [[package]] @@ -3146,13 +3103,13 @@ files = [ [[package]] name = "virtualenv" -version = "20.24.5" +version = "20.24.6" description = "Virtual Python Environment builder" optional = false python-versions = ">=3.7" files = [ - {file = "virtualenv-20.24.5-py3-none-any.whl", hash = "sha256:b80039f280f4919c77b30f1c23294ae357c4c8701042086e3fc005963e4e537b"}, - {file = "virtualenv-20.24.5.tar.gz", hash = "sha256:e8361967f6da6fbdf1426483bfe9fca8287c242ac0bc30429905721cefbff752"}, + {file = "virtualenv-20.24.6-py3-none-any.whl", hash = "sha256:520d056652454c5098a00c0f073611ccbea4c79089331f60bf9d7ba247bb7381"}, + {file = "virtualenv-20.24.6.tar.gz", hash = "sha256:02ece4f56fbf939dbbc33c0715159951d6bf14aaf5457b092e4548e1382455af"}, ] [package.dependencies] @@ -3254,81 +3211,83 @@ six = "*" [[package]] name = "websockets" -version = "11.0.3" +version = "12.0" description = "An implementation of the WebSocket Protocol (RFC 6455 & 7692)" optional = false -python-versions = ">=3.7" +python-versions = ">=3.8" files = [ - {file = "websockets-11.0.3-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:3ccc8a0c387629aec40f2fc9fdcb4b9d5431954f934da3eaf16cdc94f67dbfac"}, - {file = "websockets-11.0.3-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d67ac60a307f760c6e65dad586f556dde58e683fab03323221a4e530ead6f74d"}, - {file = "websockets-11.0.3-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:84d27a4832cc1a0ee07cdcf2b0629a8a72db73f4cf6de6f0904f6661227f256f"}, - {file = "websockets-11.0.3-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ffd7dcaf744f25f82190856bc26ed81721508fc5cbf2a330751e135ff1283564"}, - {file = "websockets-11.0.3-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7622a89d696fc87af8e8d280d9b421db5133ef5b29d3f7a1ce9f1a7bf7fcfa11"}, - {file = "websockets-11.0.3-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bceab846bac555aff6427d060f2fcfff71042dba6f5fca7dc4f75cac815e57ca"}, - {file = "websockets-11.0.3-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:54c6e5b3d3a8936a4ab6870d46bdd6ec500ad62bde9e44462c32d18f1e9a8e54"}, - {file = "websockets-11.0.3-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:41f696ba95cd92dc047e46b41b26dd24518384749ed0d99bea0a941ca87404c4"}, - {file = "websockets-11.0.3-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:86d2a77fd490ae3ff6fae1c6ceaecad063d3cc2320b44377efdde79880e11526"}, - {file = "websockets-11.0.3-cp310-cp310-win32.whl", hash = "sha256:2d903ad4419f5b472de90cd2d40384573b25da71e33519a67797de17ef849b69"}, - {file = "websockets-11.0.3-cp310-cp310-win_amd64.whl", hash = "sha256:1d2256283fa4b7f4c7d7d3e84dc2ece74d341bce57d5b9bf385df109c2a1a82f"}, - {file = "websockets-11.0.3-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:e848f46a58b9fcf3d06061d17be388caf70ea5b8cc3466251963c8345e13f7eb"}, - {file = "websockets-11.0.3-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:aa5003845cdd21ac0dc6c9bf661c5beddd01116f6eb9eb3c8e272353d45b3288"}, - {file = "websockets-11.0.3-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:b58cbf0697721120866820b89f93659abc31c1e876bf20d0b3d03cef14faf84d"}, - {file = "websockets-11.0.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:660e2d9068d2bedc0912af508f30bbeb505bbbf9774d98def45f68278cea20d3"}, - {file = "websockets-11.0.3-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:c1f0524f203e3bd35149f12157438f406eff2e4fb30f71221c8a5eceb3617b6b"}, - {file = "websockets-11.0.3-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:def07915168ac8f7853812cc593c71185a16216e9e4fa886358a17ed0fd9fcf6"}, - {file = "websockets-11.0.3-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:b30c6590146e53149f04e85a6e4fcae068df4289e31e4aee1fdf56a0dead8f97"}, - {file = "websockets-11.0.3-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:619d9f06372b3a42bc29d0cd0354c9bb9fb39c2cbc1a9c5025b4538738dbffaf"}, - {file = "websockets-11.0.3-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:01f5567d9cf6f502d655151645d4e8b72b453413d3819d2b6f1185abc23e82dd"}, - {file = "websockets-11.0.3-cp311-cp311-win32.whl", hash = "sha256:e1459677e5d12be8bbc7584c35b992eea142911a6236a3278b9b5ce3326f282c"}, - {file = "websockets-11.0.3-cp311-cp311-win_amd64.whl", hash = "sha256:e7837cb169eca3b3ae94cc5787c4fed99eef74c0ab9506756eea335e0d6f3ed8"}, - {file = "websockets-11.0.3-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:9f59a3c656fef341a99e3d63189852be7084c0e54b75734cde571182c087b152"}, - {file = "websockets-11.0.3-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2529338a6ff0eb0b50c7be33dc3d0e456381157a31eefc561771ee431134a97f"}, - {file = "websockets-11.0.3-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:34fd59a4ac42dff6d4681d8843217137f6bc85ed29722f2f7222bd619d15e95b"}, - {file = "websockets-11.0.3-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:332d126167ddddec94597c2365537baf9ff62dfcc9db4266f263d455f2f031cb"}, - {file = "websockets-11.0.3-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:6505c1b31274723ccaf5f515c1824a4ad2f0d191cec942666b3d0f3aa4cb4007"}, - {file = "websockets-11.0.3-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:f467ba0050b7de85016b43f5a22b46383ef004c4f672148a8abf32bc999a87f0"}, - {file = "websockets-11.0.3-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:9d9acd80072abcc98bd2c86c3c9cd4ac2347b5a5a0cae7ed5c0ee5675f86d9af"}, - {file = "websockets-11.0.3-cp37-cp37m-win32.whl", hash = "sha256:e590228200fcfc7e9109509e4d9125eace2042fd52b595dd22bbc34bb282307f"}, - {file = "websockets-11.0.3-cp37-cp37m-win_amd64.whl", hash = "sha256:b16fff62b45eccb9c7abb18e60e7e446998093cdcb50fed33134b9b6878836de"}, - {file = "websockets-11.0.3-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:fb06eea71a00a7af0ae6aefbb932fb8a7df3cb390cc217d51a9ad7343de1b8d0"}, - {file = "websockets-11.0.3-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:8a34e13a62a59c871064dfd8ffb150867e54291e46d4a7cf11d02c94a5275bae"}, - {file = "websockets-11.0.3-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:4841ed00f1026dfbced6fca7d963c4e7043aa832648671b5138008dc5a8f6d99"}, - {file = "websockets-11.0.3-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1a073fc9ab1c8aff37c99f11f1641e16da517770e31a37265d2755282a5d28aa"}, - {file = "websockets-11.0.3-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:68b977f21ce443d6d378dbd5ca38621755f2063d6fdb3335bda981d552cfff86"}, - {file = "websockets-11.0.3-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e1a99a7a71631f0efe727c10edfba09ea6bee4166a6f9c19aafb6c0b5917d09c"}, - {file = "websockets-11.0.3-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:bee9fcb41db2a23bed96c6b6ead6489702c12334ea20a297aa095ce6d31370d0"}, - {file = "websockets-11.0.3-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:4b253869ea05a5a073ebfdcb5cb3b0266a57c3764cf6fe114e4cd90f4bfa5f5e"}, - {file = "websockets-11.0.3-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:1553cb82942b2a74dd9b15a018dce645d4e68674de2ca31ff13ebc2d9f283788"}, - {file = "websockets-11.0.3-cp38-cp38-win32.whl", hash = "sha256:f61bdb1df43dc9c131791fbc2355535f9024b9a04398d3bd0684fc16ab07df74"}, - {file = "websockets-11.0.3-cp38-cp38-win_amd64.whl", hash = "sha256:03aae4edc0b1c68498f41a6772d80ac7c1e33c06c6ffa2ac1c27a07653e79d6f"}, - {file = "websockets-11.0.3-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:777354ee16f02f643a4c7f2b3eff8027a33c9861edc691a2003531f5da4f6bc8"}, - {file = "websockets-11.0.3-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:8c82f11964f010053e13daafdc7154ce7385ecc538989a354ccc7067fd7028fd"}, - {file = "websockets-11.0.3-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:3580dd9c1ad0701169e4d6fc41e878ffe05e6bdcaf3c412f9d559389d0c9e016"}, - {file = "websockets-11.0.3-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6f1a3f10f836fab6ca6efa97bb952300b20ae56b409414ca85bff2ad241d2a61"}, - {file = "websockets-11.0.3-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:df41b9bc27c2c25b486bae7cf42fccdc52ff181c8c387bfd026624a491c2671b"}, - {file = "websockets-11.0.3-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:279e5de4671e79a9ac877427f4ac4ce93751b8823f276b681d04b2156713b9dd"}, - {file = "websockets-11.0.3-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:1fdf26fa8a6a592f8f9235285b8affa72748dc12e964a5518c6c5e8f916716f7"}, - {file = "websockets-11.0.3-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:69269f3a0b472e91125b503d3c0b3566bda26da0a3261c49f0027eb6075086d1"}, - {file = "websockets-11.0.3-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:97b52894d948d2f6ea480171a27122d77af14ced35f62e5c892ca2fae9344311"}, - {file = "websockets-11.0.3-cp39-cp39-win32.whl", hash = "sha256:c7f3cb904cce8e1be667c7e6fef4516b98d1a6a0635a58a57528d577ac18a128"}, - {file = "websockets-11.0.3-cp39-cp39-win_amd64.whl", hash = "sha256:c792ea4eabc0159535608fc5658a74d1a81020eb35195dd63214dcf07556f67e"}, - {file = "websockets-11.0.3-pp37-pypy37_pp73-macosx_10_9_x86_64.whl", hash = "sha256:f2e58f2c36cc52d41f2659e4c0cbf7353e28c8c9e63e30d8c6d3494dc9fdedcf"}, - {file = "websockets-11.0.3-pp37-pypy37_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:de36fe9c02995c7e6ae6efe2e205816f5f00c22fd1fbf343d4d18c3d5ceac2f5"}, - {file = "websockets-11.0.3-pp37-pypy37_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0ac56b661e60edd453585f4bd68eb6a29ae25b5184fd5ba51e97652580458998"}, - {file = "websockets-11.0.3-pp37-pypy37_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e052b8467dd07d4943936009f46ae5ce7b908ddcac3fda581656b1b19c083d9b"}, - {file = "websockets-11.0.3-pp37-pypy37_pp73-win_amd64.whl", hash = "sha256:42cc5452a54a8e46a032521d7365da775823e21bfba2895fb7b77633cce031bb"}, - {file = "websockets-11.0.3-pp38-pypy38_pp73-macosx_10_9_x86_64.whl", hash = "sha256:e6316827e3e79b7b8e7d8e3b08f4e331af91a48e794d5d8b099928b6f0b85f20"}, - {file = "websockets-11.0.3-pp38-pypy38_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8531fdcad636d82c517b26a448dcfe62f720e1922b33c81ce695d0edb91eb931"}, - {file = "websockets-11.0.3-pp38-pypy38_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:c114e8da9b475739dde229fd3bc6b05a6537a88a578358bc8eb29b4030fac9c9"}, - {file = "websockets-11.0.3-pp38-pypy38_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e063b1865974611313a3849d43f2c3f5368093691349cf3c7c8f8f75ad7cb280"}, - {file = "websockets-11.0.3-pp38-pypy38_pp73-win_amd64.whl", hash = "sha256:92b2065d642bf8c0a82d59e59053dd2fdde64d4ed44efe4870fa816c1232647b"}, - {file = "websockets-11.0.3-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:0ee68fe502f9031f19d495dae2c268830df2760c0524cbac5d759921ba8c8e82"}, - {file = "websockets-11.0.3-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dcacf2c7a6c3a84e720d1bb2b543c675bf6c40e460300b628bab1b1efc7c034c"}, - {file = "websockets-11.0.3-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b67c6f5e5a401fc56394f191f00f9b3811fe843ee93f4a70df3c389d1adf857d"}, - {file = "websockets-11.0.3-pp39-pypy39_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1d5023a4b6a5b183dc838808087033ec5df77580485fc533e7dab2567851b0a4"}, - {file = "websockets-11.0.3-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:ed058398f55163a79bb9f06a90ef9ccc063b204bb346c4de78efc5d15abfe602"}, - {file = "websockets-11.0.3-py3-none-any.whl", hash = "sha256:6681ba9e7f8f3b19440921e99efbb40fc89f26cd71bf539e45d8c8a25c976dc6"}, - {file = "websockets-11.0.3.tar.gz", hash = "sha256:88fc51d9a26b10fc331be344f1781224a375b78488fc343620184e95a4b27016"}, + {file = "websockets-12.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:d554236b2a2006e0ce16315c16eaa0d628dab009c33b63ea03f41c6107958374"}, + {file = "websockets-12.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:2d225bb6886591b1746b17c0573e29804619c8f755b5598d875bb4235ea639be"}, + {file = "websockets-12.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:eb809e816916a3b210bed3c82fb88eaf16e8afcf9c115ebb2bacede1797d2547"}, + {file = "websockets-12.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c588f6abc13f78a67044c6b1273a99e1cf31038ad51815b3b016ce699f0d75c2"}, + {file = "websockets-12.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:5aa9348186d79a5f232115ed3fa9020eab66d6c3437d72f9d2c8ac0c6858c558"}, + {file = "websockets-12.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6350b14a40c95ddd53e775dbdbbbc59b124a5c8ecd6fbb09c2e52029f7a9f480"}, + {file = "websockets-12.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:70ec754cc2a769bcd218ed8d7209055667b30860ffecb8633a834dde27d6307c"}, + {file = "websockets-12.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6e96f5ed1b83a8ddb07909b45bd94833b0710f738115751cdaa9da1fb0cb66e8"}, + {file = "websockets-12.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:4d87be612cbef86f994178d5186add3d94e9f31cc3cb499a0482b866ec477603"}, + {file = "websockets-12.0-cp310-cp310-win32.whl", hash = "sha256:befe90632d66caaf72e8b2ed4d7f02b348913813c8b0a32fae1cc5fe3730902f"}, + {file = "websockets-12.0-cp310-cp310-win_amd64.whl", hash = "sha256:363f57ca8bc8576195d0540c648aa58ac18cf85b76ad5202b9f976918f4219cf"}, + {file = "websockets-12.0-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:5d873c7de42dea355d73f170be0f23788cf3fa9f7bed718fd2830eefedce01b4"}, + {file = "websockets-12.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:3f61726cae9f65b872502ff3c1496abc93ffbe31b278455c418492016e2afc8f"}, + {file = "websockets-12.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:ed2fcf7a07334c77fc8a230755c2209223a7cc44fc27597729b8ef5425aa61a3"}, + {file = "websockets-12.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e332c210b14b57904869ca9f9bf4ca32f5427a03eeb625da9b616c85a3a506c"}, + {file = "websockets-12.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:5693ef74233122f8ebab026817b1b37fe25c411ecfca084b29bc7d6efc548f45"}, + {file = "websockets-12.0-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6e9e7db18b4539a29cc5ad8c8b252738a30e2b13f033c2d6e9d0549b45841c04"}, + {file = "websockets-12.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:6e2df67b8014767d0f785baa98393725739287684b9f8d8a1001eb2839031447"}, + {file = "websockets-12.0-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:bea88d71630c5900690fcb03161ab18f8f244805c59e2e0dc4ffadae0a7ee0ca"}, + {file = "websockets-12.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:dff6cdf35e31d1315790149fee351f9e52978130cef6c87c4b6c9b3baf78bc53"}, + {file = "websockets-12.0-cp311-cp311-win32.whl", hash = "sha256:3e3aa8c468af01d70332a382350ee95f6986db479ce7af14d5e81ec52aa2b402"}, + {file = "websockets-12.0-cp311-cp311-win_amd64.whl", hash = "sha256:25eb766c8ad27da0f79420b2af4b85d29914ba0edf69f547cc4f06ca6f1d403b"}, + {file = "websockets-12.0-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:0e6e2711d5a8e6e482cacb927a49a3d432345dfe7dea8ace7b5790df5932e4df"}, + {file = "websockets-12.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:dbcf72a37f0b3316e993e13ecf32f10c0e1259c28ffd0a85cee26e8549595fbc"}, + {file = "websockets-12.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:12743ab88ab2af1d17dd4acb4645677cb7063ef4db93abffbf164218a5d54c6b"}, + {file = "websockets-12.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7b645f491f3c48d3f8a00d1fce07445fab7347fec54a3e65f0725d730d5b99cb"}, + {file = "websockets-12.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:9893d1aa45a7f8b3bc4510f6ccf8db8c3b62120917af15e3de247f0780294b92"}, + {file = "websockets-12.0-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1f38a7b376117ef7aff996e737583172bdf535932c9ca021746573bce40165ed"}, + {file = "websockets-12.0-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:f764ba54e33daf20e167915edc443b6f88956f37fb606449b4a5b10ba42235a5"}, + {file = "websockets-12.0-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:1e4b3f8ea6a9cfa8be8484c9221ec0257508e3a1ec43c36acdefb2a9c3b00aa2"}, + {file = "websockets-12.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:9fdf06fd06c32205a07e47328ab49c40fc1407cdec801d698a7c41167ea45113"}, + {file = "websockets-12.0-cp312-cp312-win32.whl", hash = "sha256:baa386875b70cbd81798fa9f71be689c1bf484f65fd6fb08d051a0ee4e79924d"}, + {file = "websockets-12.0-cp312-cp312-win_amd64.whl", hash = "sha256:ae0a5da8f35a5be197f328d4727dbcfafa53d1824fac3d96cdd3a642fe09394f"}, + {file = "websockets-12.0-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:5f6ffe2c6598f7f7207eef9a1228b6f5c818f9f4d53ee920aacd35cec8110438"}, + {file = "websockets-12.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:9edf3fc590cc2ec20dc9d7a45108b5bbaf21c0d89f9fd3fd1685e223771dc0b2"}, + {file = "websockets-12.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:8572132c7be52632201a35f5e08348137f658e5ffd21f51f94572ca6c05ea81d"}, + {file = "websockets-12.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:604428d1b87edbf02b233e2c207d7d528460fa978f9e391bd8aaf9c8311de137"}, + {file = "websockets-12.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1a9d160fd080c6285e202327aba140fc9a0d910b09e423afff4ae5cbbf1c7205"}, + {file = "websockets-12.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:87b4aafed34653e465eb77b7c93ef058516cb5acf3eb21e42f33928616172def"}, + {file = "websockets-12.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:b2ee7288b85959797970114deae81ab41b731f19ebcd3bd499ae9ca0e3f1d2c8"}, + {file = "websockets-12.0-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:7fa3d25e81bfe6a89718e9791128398a50dec6d57faf23770787ff441d851967"}, + {file = "websockets-12.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:a571f035a47212288e3b3519944f6bf4ac7bc7553243e41eac50dd48552b6df7"}, + {file = "websockets-12.0-cp38-cp38-win32.whl", hash = "sha256:3c6cc1360c10c17463aadd29dd3af332d4a1adaa8796f6b0e9f9df1fdb0bad62"}, + {file = "websockets-12.0-cp38-cp38-win_amd64.whl", hash = "sha256:1bf386089178ea69d720f8db6199a0504a406209a0fc23e603b27b300fdd6892"}, + {file = "websockets-12.0-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:ab3d732ad50a4fbd04a4490ef08acd0517b6ae6b77eb967251f4c263011a990d"}, + {file = "websockets-12.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:a1d9697f3337a89691e3bd8dc56dea45a6f6d975f92e7d5f773bc715c15dde28"}, + {file = "websockets-12.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:1df2fbd2c8a98d38a66f5238484405b8d1d16f929bb7a33ed73e4801222a6f53"}, + {file = "websockets-12.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:23509452b3bc38e3a057382c2e941d5ac2e01e251acce7adc74011d7d8de434c"}, + {file = "websockets-12.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:2e5fc14ec6ea568200ea4ef46545073da81900a2b67b3e666f04adf53ad452ec"}, + {file = "websockets-12.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:46e71dbbd12850224243f5d2aeec90f0aaa0f2dde5aeeb8fc8df21e04d99eff9"}, + {file = "websockets-12.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:b81f90dcc6c85a9b7f29873beb56c94c85d6f0dac2ea8b60d995bd18bf3e2aae"}, + {file = "websockets-12.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:a02413bc474feda2849c59ed2dfb2cddb4cd3d2f03a2fedec51d6e959d9b608b"}, + {file = "websockets-12.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:bbe6013f9f791944ed31ca08b077e26249309639313fff132bfbf3ba105673b9"}, + {file = "websockets-12.0-cp39-cp39-win32.whl", hash = "sha256:cbe83a6bbdf207ff0541de01e11904827540aa069293696dd528a6640bd6a5f6"}, + {file = "websockets-12.0-cp39-cp39-win_amd64.whl", hash = "sha256:fc4e7fa5414512b481a2483775a8e8be7803a35b30ca805afa4998a84f9fd9e8"}, + {file = "websockets-12.0-pp310-pypy310_pp73-macosx_10_9_x86_64.whl", hash = "sha256:248d8e2446e13c1d4326e0a6a4e9629cb13a11195051a73acf414812700badbd"}, + {file = "websockets-12.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f44069528d45a933997a6fef143030d8ca8042f0dfaad753e2906398290e2870"}, + {file = "websockets-12.0-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:c4e37d36f0d19f0a4413d3e18c0d03d0c268ada2061868c1e6f5ab1a6d575077"}, + {file = "websockets-12.0-pp310-pypy310_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3d829f975fc2e527a3ef2f9c8f25e553eb7bc779c6665e8e1d52aa22800bb38b"}, + {file = "websockets-12.0-pp310-pypy310_pp73-win_amd64.whl", hash = "sha256:2c71bd45a777433dd9113847af751aae36e448bc6b8c361a566cb043eda6ec30"}, + {file = "websockets-12.0-pp38-pypy38_pp73-macosx_10_9_x86_64.whl", hash = "sha256:0bee75f400895aef54157b36ed6d3b308fcab62e5260703add87f44cee9c82a6"}, + {file = "websockets-12.0-pp38-pypy38_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:423fc1ed29f7512fceb727e2d2aecb952c46aa34895e9ed96071821309951123"}, + {file = "websockets-12.0-pp38-pypy38_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:27a5e9964ef509016759f2ef3f2c1e13f403725a5e6a1775555994966a66e931"}, + {file = "websockets-12.0-pp38-pypy38_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:c3181df4583c4d3994d31fb235dc681d2aaad744fbdbf94c4802485ececdecf2"}, + {file = "websockets-12.0-pp38-pypy38_pp73-win_amd64.whl", hash = "sha256:b067cb952ce8bf40115f6c19f478dc71c5e719b7fbaa511359795dfd9d1a6468"}, + {file = "websockets-12.0-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:00700340c6c7ab788f176d118775202aadea7602c5cc6be6ae127761c16d6b0b"}, + {file = "websockets-12.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e469d01137942849cff40517c97a30a93ae79917752b34029f0ec72df6b46399"}, + {file = "websockets-12.0-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:ffefa1374cd508d633646d51a8e9277763a9b78ae71324183693959cf94635a7"}, + {file = "websockets-12.0-pp39-pypy39_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ba0cab91b3956dfa9f512147860783a1829a8d905ee218a9837c18f683239611"}, + {file = "websockets-12.0-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:2cb388a5bfb56df4d9a406783b7f9dbefb888c09b71629351cc6b036e9259370"}, + {file = "websockets-12.0-py3-none-any.whl", hash = "sha256:dc284bbc8d7c78a6c69e0c7325ab46ee5e40bb4d50e494d8131a07ef47500e9e"}, + {file = "websockets-12.0.tar.gz", hash = "sha256:81df9cbcbb6c260de1e007e58c011bfebe2dafc8435107b0537f393dd38c8b1b"}, ] [[package]] diff --git a/pyproject.toml b/pyproject.toml index a9716f431..8a8801099 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -16,20 +16,21 @@ include = "packages" [tool.poetry.dependencies] python = ">=3.10, <3.11" -open-autonomy = "==0.12.1.post4" +open-autonomy = "==0.13.1" requests = "==2.28.2" py-multibase = "==1.0.3" py-multicodec = "==0.2.1" py-eth-sig-utils = "*" grpcio = "==1.53.0" asn1crypto = "<1.5.0,>=1.4.0" -open-aea-ledger-ethereum = "==1.39.0.post1" -open-aea-ledger-cosmos = "==1.39.0.post1" -protobuf = "<=3.20.1,>=3.19" +open-aea-ledger-ethereum = "==1.41.0" +open-aea-ledger-cosmos = "==1.41.0" +protobuf = "<5.0.0,>=4.21.6" hypothesis = "==6.21.6" -open-aea-web3 = "==6.0.1" +open-aea-test-autonomy = "==0.13.1" +web3 = "<7,>=6.0.0" ipfshttpclient = "==0.8.0a2" -open-aea-cli-ipfs = "==1.39.0.post1" +open-aea-cli-ipfs = "==1.41.0" aiohttp = "<3.8,>=3.7.4" certifi = "*" multidict = "*" @@ -49,8 +50,7 @@ pycryptodome = "==3.18.0" pytest = "==7.2.1" urllib3 = "==1.26.16" jsonschema = "<=4.19.0,>=4.16.0" -open-aea-test-autonomy = "0.12.1.post4" [tool.poetry.group.dev.dependencies.tomte] version = "==0.2.12" -extras = [ "cli", "tests",] +extras = [ "cli", "tests",] \ No newline at end of file From 614c39fa3092ce4e0872580a5d9923d82dbb3884 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Wed, 25 Oct 2023 10:23:15 +0200 Subject: [PATCH 58/79] chore: Update dependency versions manually --- packages/packages.json | 10 +++--- packages/valory/agents/trader/aea-config.yaml | 6 ++-- .../contracts/agent_registry/contract.yaml | 8 ++--- .../conditional_tokens/contract.yaml | 4 +-- packages/valory/contracts/erc20/contract.yaml | 8 ++--- .../contracts/market_maker/contract.yaml | 8 ++--- packages/valory/contracts/mech/contract.yaml | 6 ++-- .../valory/contracts/realitio/contract.yaml | 4 +-- .../contracts/realitio_proxy/contract.yaml | 4 +-- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/skill.yaml | 34 +++++++++---------- packages/valory/skills/trader_abci/skill.yaml | 4 +-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 13 files changed, 50 insertions(+), 50 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 17c7f9c3f..13f2e1005 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeiac5tj4x22dgzaq62ja5tudeyt6f27nhs5e3fulej5ayojye5oyzq", - "skill/valory/trader_abci/0.1.0": "bafybeibspd55q2gm5un6wpfoq4zanho3nqwgzp42w63accgpyjo63cq6ie", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidunyquz4vrrflpj253xhwrzfkepyrh6whhwp6kb752hhanonocpm", + "skill/valory/trader_abci/0.1.0": "bafybeiaimoeaztc3cbi4lt72rs27n4qcpawhypp7wdzixl7ubivfoo4vc4", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeicfyo2qkrqep6o2dhp56eqt4zb6cqz33o753zh3wewgwx5rwn6p6m", - "service/valory/trader/0.1.0": "bafybeib46qrohyfex5g34wqtqt6ka2kzbkqllofw2knktve5hn3acf6isy", + "agent/valory/trader/0.1.0": "bafybeicqje6nqp7xnetzbswm6kfbczpiqz7du6kpf6m7l6mvnnfle36q5m", + "service/valory/trader/0.1.0": "bafybeidu6uvpxhb4534276tcfp62gfmhu5bd6q2acauspqm7pcousdzyqe", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiemvcwdd746zwhq3rtocpdcx3bj2crxmm2u5kebfsit3fkeq4oogm", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeic7hzp64xhla7fjhqiqmtbcq6oen5drlfgukaj4r7x5zzqfpv4pxm", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 6348ea214..2ce39fab8 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiemvcwdd746zwhq3rtocpdcx3bj2crxmm2u5kebfsit3fkeq4oogm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeic7hzp64xhla7fjhqiqmtbcq6oen5drlfgukaj4r7x5zzqfpv4pxm - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiac5tj4x22dgzaq62ja5tudeyt6f27nhs5e3fulej5ayojye5oyzq -- valory/trader_abci:0.1.0:bafybeibspd55q2gm5un6wpfoq4zanho3nqwgzp42w63accgpyjo63cq6ie +- valory/decision_maker_abci:0.1.0:bafybeidunyquz4vrrflpj253xhwrzfkepyrh6whhwp6kb752hhanonocpm +- valory/trader_abci:0.1.0:bafybeiaimoeaztc3cbi4lt72rs27n4qcpawhypp7wdzixl7ubivfoo4vc4 default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/contracts/agent_registry/contract.yaml b/packages/valory/contracts/agent_registry/contract.yaml index 0bc8aa01e..e7c0f8247 100644 --- a/packages/valory/contracts/agent_registry/contract.yaml +++ b/packages/valory/contracts/agent_registry/contract.yaml @@ -16,8 +16,8 @@ contract_interface_paths: ethereum: build/AgentRegistry.json dependencies: open-aea-ledger-ethereum: - version: ==1.39.0.post1 + version: ==1.41.0 open-aea-test-autonomy: - version: ==0.12.1.post4 - open-aea-web3: - version: ==6.0.1 + version: ==0.13.1 + web3: + version: <7,>=6.0.0 diff --git a/packages/valory/contracts/conditional_tokens/contract.yaml b/packages/valory/contracts/conditional_tokens/contract.yaml index c2b7a5395..e27735501 100644 --- a/packages/valory/contracts/conditional_tokens/contract.yaml +++ b/packages/valory/contracts/conditional_tokens/contract.yaml @@ -15,8 +15,8 @@ contract_interface_paths: ethereum: build/ConditionalTokens.json dependencies: hexbytes: {} - open-aea-web3: - version: ==6.0.1 + web3: + version: <7,>=6.0.0 requests: version: ==2.28.2 urllib3: diff --git a/packages/valory/contracts/erc20/contract.yaml b/packages/valory/contracts/erc20/contract.yaml index 9dc68b5e8..5144da9de 100644 --- a/packages/valory/contracts/erc20/contract.yaml +++ b/packages/valory/contracts/erc20/contract.yaml @@ -21,11 +21,11 @@ dependencies: eth_typing: {} hexbytes: {} open-aea-ledger-ethereum: - version: ==1.39.0.post1 + version: ==1.41.0 open-aea-test-autonomy: - version: ==0.12.1.post4 + version: ==0.13.1 packaging: {} py-eth-sig-utils: {} requests: {} - open-aea-web3: - version: ==6.0.1 + web3: + version: <7,>=6.0.0 diff --git a/packages/valory/contracts/market_maker/contract.yaml b/packages/valory/contracts/market_maker/contract.yaml index e9de76b50..919086dc2 100644 --- a/packages/valory/contracts/market_maker/contract.yaml +++ b/packages/valory/contracts/market_maker/contract.yaml @@ -21,11 +21,11 @@ dependencies: eth_typing: {} hexbytes: {} open-aea-ledger-ethereum: - version: ==1.39.0.post1 + version: ==1.41.0 open-aea-test-autonomy: - version: ==0.12.1.post4 + version: ==0.13.1 packaging: {} py-eth-sig-utils: {} requests: {} - open-aea-web3: - version: ==6.0.1 + web3: + version: <7,>=6.0.0 diff --git a/packages/valory/contracts/mech/contract.yaml b/packages/valory/contracts/mech/contract.yaml index 6afb8cdfc..09b70c259 100644 --- a/packages/valory/contracts/mech/contract.yaml +++ b/packages/valory/contracts/mech/contract.yaml @@ -17,7 +17,7 @@ contract_interface_paths: ethereum: build/mech.json dependencies: open-aea-ledger-ethereum: - version: ==1.39.0.post1 - open-aea-web3: - version: ==6.0.1 + version: ==1.41.0 + web3: + version: <7,>=6.0.0 eth_typing: {} diff --git a/packages/valory/contracts/realitio/contract.yaml b/packages/valory/contracts/realitio/contract.yaml index be55574c2..3ec5122b9 100644 --- a/packages/valory/contracts/realitio/contract.yaml +++ b/packages/valory/contracts/realitio/contract.yaml @@ -16,8 +16,8 @@ contract_interface_paths: dependencies: eth_typing: {} hexbytes: {} - open-aea-web3: - version: ==6.0.1 + web3: + version: <7,>=6.0.0 requests: version: ==2.28.2 urllib3: diff --git a/packages/valory/contracts/realitio_proxy/contract.yaml b/packages/valory/contracts/realitio_proxy/contract.yaml index 944ffb161..3adbb2eea 100644 --- a/packages/valory/contracts/realitio_proxy/contract.yaml +++ b/packages/valory/contracts/realitio_proxy/contract.yaml @@ -14,6 +14,6 @@ class_name: RealitioProxyContract contract_interface_paths: ethereum: build/Realitio.json dependencies: - open-aea-web3: - version: ==6.0.1 + web3: + version: <7,>=6.0.0 contracts: [] diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 09efd8454..3794568d1 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeicfyo2qkrqep6o2dhp56eqt4zb6cqz33o753zh3wewgwx5rwn6p6m +agent: valory/trader:0.1.0:bafybeicqje6nqp7xnetzbswm6kfbczpiqz7du6kpf6m7l6mvnnfle36q5m number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 62b26af98..b9578e73b 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,21 +12,21 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeidny4y4w4jbjbp5d5qivur6jm37fnuik4mqzchzshiuvpozxe7vwy - behaviours/bet_placement.py: bafybeiauzdizqawjgzc3ugx33vuh726e25juhacqdr7c6uztpn6tra5dva + behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m + behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeie4aawdikv7pj5rorqy55jy2fkqzhitz3qmf3wyycarsj4dmwz7wa - behaviours/decision_receive.py: bafybeibfnucc444uqcythgsn4cawluubbi4u4q7ab4aqc4ts3lu4qnvhdq - behaviours/decision_request.py: bafybeibrk6jxalkgspinmjboqr3o6d6hl6mxtlkif74a5p32vp2zzhhzua + behaviours/decision_receive.py: bafybeie6wl3bpnbexgqtw5ahvhonvo6ph5yr4av5qrnffyssgqtybmgjr4 + behaviours/decision_request.py: bafybeia7ko3nryzcnsihh4ab7vnrgtyjm3w7tvmkxhqzr2a65hcfo5fzye behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeiccrnttqwf5vuf3lr55k5c6tsqsrekoypoag5gntyimjhbmuokkga behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeiadikynvkaofbko72jc45xthhmmjfmlkpgramormhxwk5u47rnwdu + behaviours/sampling.py: bafybeiarw643pcvh7xk4pp7ytxqbif4ocp5smydrkqv2nnwnlocxpwwyt4 behaviours/tool_selection.py: bafybeigfr2frkljrxyfxs5p3j42equzehgaqtkyuxk6eiujyudr6ajqakm dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeidlis33rkpvtb2w6qrtmiqzb4tbqfolkbbs6hk3jcx73lfuwqif3e - payloads.py: bafybeiawx6ix2ljvf545fe3wocdoh7frds6gjvzgv62b3w6huaolgvywqi + models.py: bafybeihdmbhpjfluyb5pueiqumik2q7l7pe3sibhj7p24jpwbduc2ku6tq + payloads.py: bafybeifq7mz5jbb6lqhdlrlr5kpqb2ghvr3xlt7usegaimree7yryeh2na policy.py: bafybeidkqqrkgxah5q73mlpr64swxczadhuyax3ab2ijg6obemnvy2sxnu redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm rounds.py: bafybeihopxmhzrpipc6r5x2vqf2tcixzuf5xdpqfsr7gr3n756n3ssft5q @@ -34,7 +34,7 @@ fingerprint: states/base.py: bafybeicolcsto2ue5iif36gh4ggjo5kaq4234xrsp2llgvynhbvt53gliy states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeifruvxwwltndwazkzzbpc5nnnad3z5t5ofy6d3i7nssljbxl6gvxu - states/decision_receive.py: bafybeifm3oyq2aji7f5yag6wpe4vr3ivi74pybdsk2jvmziiidx5nt7t4a + states/decision_receive.py: bafybeiasj5uaixpqau6hcxpw5vyevqrufd3ubkwvgbgy37gcwfom3bl3iq states/decision_request.py: bafybeic7otc3hjb753svbmur3yyk6szahc25yii3x4w4vcnpfz6jwvacuu states/final_states.py: bafybeidiwhuyd5zm2cq7vhv2owcrxdpm7fnvn3db6p6tql4jz5hgpalflu states/handle_failed_tx.py: bafybeihewm2vernvhktuorljdupjqcg2p5vs6wvsira2d62wkoyo5xlzjm @@ -45,14 +45,14 @@ fingerprint_ignore_patterns: [] connections: [] contracts: - valory/gnosis_safe:0.1.0:bafybeibt7arvjzz4ah24omst74f4sfjpzrdef76yti6ml7dopsauhdzeci -- valory/market_maker:0.1.0:bafybeidaz4dol7qsrwitw5jwasjtvd2vtlxhxizwkzen5kurblwacz4biu -- valory/erc20:0.1.0:bafybeicsvxv6anl5zdlovfboftqknzqyzisyuxlkcqlespvbyv7ubga3te +- valory/market_maker:0.1.0:bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m +- valory/erc20:0.1.0:bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi - valory/multisend:0.1.0:bafybeig5byt5urg2d2bsecufxe5ql7f4mezg3mekfleeh32nmuusx66p4y -- valory/mech:0.1.0:bafybeiddc6pgurpyja2k64wzsb3jgcvl254s7rplgt5iooftsyfalqlbfq -- valory/conditional_tokens:0.1.0:bafybeigdarm2ssng3uuehlxto75um4hbp47rdi5si6bvv7asdopqsidbhq -- valory/realitio:0.1.0:bafybeibzyfaeaxgyqnygtduhprs47fhtskh2vnmw2cvpemqhkgc72q4wpm -- valory/realitio_proxy:0.1.0:bafybeibvndq6756qck7forgeavhdbn6ykgqs2ufyg7n5g6qdfpveatxuwy -- valory/agent_registry:0.1.0:bafybeigpd6wvnbb7fbf6yd77rugepv5hrbb6l3qfodstwgemagtcgne3bm +- valory/mech:0.1.0:bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga +- valory/conditional_tokens:0.1.0:bafybeif5jwc6owfe6brmqq5sfnhrwo2ajdtt4glrmyhlqxcvtkyofahwsa +- valory/realitio:0.1.0:bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e +- valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 +- valory/agent_registry:0.1.0:bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty protocols: - valory/contract_api:1.0.0:bafybeialhbjvwiwcnqq3ysxcyemobcbie7xza66gaofcvla5njezkvhcka skills: @@ -242,6 +242,6 @@ dependencies: version: ==1.0.3 py-multicodec: version: ==0.2.1 - open-aea-web3: - version: ==6.0.1 + web3: + version: <7,>=6.0.0 is_abstract: true diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index c4e0cf9ff..c9764e1a4 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeiac5tj4x22dgzaq62ja5tudeyt6f27nhs5e3fulej5ayojye5oyzq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiemvcwdd746zwhq3rtocpdcx3bj2crxmm2u5kebfsit3fkeq4oogm +- valory/decision_maker_abci:0.1.0:bafybeidunyquz4vrrflpj253xhwrzfkepyrh6whhwp6kb752hhanonocpm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeic7hzp64xhla7fjhqiqmtbcq6oen5drlfgukaj4r7x5zzqfpv4pxm behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 531820298..d3a3a4f74 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeiac5tj4x22dgzaq62ja5tudeyt6f27nhs5e3fulej5ayojye5oyzq +- valory/decision_maker_abci:0.1.0:bafybeidunyquz4vrrflpj253xhwrzfkepyrh6whhwp6kb752hhanonocpm behaviours: main: args: {} From 6e1f960be67a595757c9d7502153390c68200e82 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 26 Oct 2023 17:30:22 +0200 Subject: [PATCH 59/79] Doc: Add kelly strategy explanation --- kelly_strategy_proof.md | 80 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 kelly_strategy_proof.md diff --git a/kelly_strategy_proof.md b/kelly_strategy_proof.md new file mode 100644 index 000000000..1484fe42e --- /dev/null +++ b/kelly_strategy_proof.md @@ -0,0 +1,80 @@ +# Introduction +The Kelly Criterion is the calculation rule for the Kelly fraction $K$, which is the portion of the gambling capital to be wagered in order to maximize the profit considering the payoff odds and the probability of winning. The calculation rule is given by + +$$ +f^* = \frac{bp - (1 - p)}{b} +$$ + +where $f^*$ is the Kelly fraction of the bankroll, which is the maximum available gambling capital, $b$ is the net odds received on the wager (bet amount excluded), $p$ is the probability of winning, and $(1-p)$ is the probability of losing ([Beygelzimer et. al., 2012](#references)). + +In traditional betting frameworks, the odds for a bet are usually fixed when placing a bet and stay the same regardless of the betting amount. The Kelly Criterion was originally designed for static odds and faces some challenges when being used in scenarios with dynamic odds. In prediction markets run by Constant Product Market Makers (CPMMs) the odds depend on the bet amount. As the Kelly Criterion calculates the optimal bet amount based on the odds, there exist an interdependence of bet amount and odds. The following sections provide a way to calculate the optimal absolute Kelly bet amount depending on the Bankroll and number of outcome tokens fore each outcome in the liquidity pool before placing the bet. The function only applies for prediction markets run by CPMMs with a binary outcome. + +# Kelly equation with dynamic odds +## General Equation +The Kelly formula can be converted into + +$$ +f^* = \frac{Q \cdot p - 1}{Q - 1} +$$ + +where $Q$ is the gross payoff odds, i.e., in the event of a win, $Q$ times the amount wagered $( Q > 1 )$ will be received, including the initial investment. + +As the Kelly formula calculates the fraction $f^*$ of the bankroll $B$ (Maximum available gambling capital) to bet it can be written as + +$$f^*=\frac{X}{B}$$ + +where $X$ is the absolute Kelly bet amount. Setting bot equations equal to each other results in + +$$ +\frac{X}{B} = \frac{Q \cdot p - 1}{Q - 1} +$$ + +## Odds Function +The odds $Q$ for a bet in a prediction market run by a CPMM are calculated as +$$ +Q=\frac{n_r}{X} +$$ + +where $n_r$ is the number of the selected outcome token received from placing a bet X, if the market closes with the chosen answer. + +To calculate the number of received tokens $n_r$, the bet placement algorithm of a CPMM prediction market needs to be understood: When a user submits a bet placement transaction to the prediction market, this transaction includes among other parameters the investment amount and the vote. CPMMs are designed to always retain the product $k$ of their asset amounts $a$ and $b$ constant: + +$$k=a \cdot b \quad a,b > 0$$ + +To ensure this the CPMM divides the investment amount by the number of asset classes and + + +$Q$: gross payoff odds (e.g. If $Q=2$, the returned amount in case of winning a bet, where 1$ was invested is 2$.) + +$a$: Number of tokens of the selected outcome in the pool prior to bet placement + +$b$: Number of tokens of the other outcome in the pool prior to bet placement + +$a_{new}$: Number of tokens of the selected outcome in the pool after bet placement + +$b_{new}$: Number of tokens of the other outcome in the pool prior to bet placement + +$P_a$: Marginal price of $1$ selected token + +$P_b$: Marginal price of $1$ other token + + + + + + + + +$f^* = \frac{x}{B}$ + + + + + + +# References +**Angeris, G., Agrawal, A., Evans, A., Chitra, T., & Boyd, S.** (2021). *Constant Function Market Makers: Multi-Asset Trades via Convex Optimization*. arXiv preprint [arXiv:2107.12484 [math.OC]](https://arxiv.org/abs/2107.12484). + +**Beygelzimer, A., Langford, J., & Pennock, D.** (2012). *Learning Performance of Prediction Markets with Kelly Bettors*. arXiv preprint [arXiv:1201.6655 [cs.AI]](https://arxiv.org/abs/1201.6655). + + From e5208f4f994bec724390dcc3741d44897aabe9ac Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Thu, 26 Oct 2023 17:43:33 +0200 Subject: [PATCH 60/79] chore: Update packages --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../valory/skills/decision_maker_abci/skill.yaml | 14 +++++++------- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 6 files changed, 19 insertions(+), 19 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 388e20e91..1715a9042 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeichzmhpgyhk5gc6gepocdaghdwyoutq4x3ul4w7av4lasp7bxfb3y", - "skill/valory/trader_abci/0.1.0": "bafybeifrvvhiaioqqjzyouhi3ga37jk7ataxz5sox275mccqqszcsiehju", + "skill/valory/decision_maker_abci/0.1.0": "bafybeih4aa6rxd625clmccuz2dyhmnrsj4gxzo3pobu3l4gyopzsn7keeq", + "skill/valory/trader_abci/0.1.0": "bafybeifeaukjvguqqjh6fxfutujcc4khe6dvfx4u55duf76dvchxjootp4", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeidfoajq7jno5ojcgvdkcacialgqr4rsayivkspjdyhcd2povbkiri", - "service/valory/trader/0.1.0": "bafybeihwzztpxd5g3pq5awpdtvbirdkwzt66bj26lpulzay2afsrzubfnq", + "agent/valory/trader/0.1.0": "bafybeien57adhb5nss3ghcqxlzldn2p3sk7rarb6pwsaboytnjvc3kjesa", + "service/valory/trader/0.1.0": "bafybeidqfl6jwklwx252qhdupluxfhvvy4uzzg3pnm4izob4b76m7bvzbi", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeib5s5ubudn67phubygrx7lmlzfrhwhy4lo6biusef7ffk2jyipn6a", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihjoetoipbyivp52xwpbfpvgqazzyrhh3djgi552xbpr7enlezpmi", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index d48ac2407..1b12692fc 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib5s5ubudn67phubygrx7lmlzfrhwhy4lo6biusef7ffk2jyipn6a +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihjoetoipbyivp52xwpbfpvgqazzyrhh3djgi552xbpr7enlezpmi - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeichzmhpgyhk5gc6gepocdaghdwyoutq4x3ul4w7av4lasp7bxfb3y -- valory/trader_abci:0.1.0:bafybeifrvvhiaioqqjzyouhi3ga37jk7ataxz5sox275mccqqszcsiehju +- valory/decision_maker_abci:0.1.0:bafybeih4aa6rxd625clmccuz2dyhmnrsj4gxzo3pobu3l4gyopzsn7keeq +- valory/trader_abci:0.1.0:bafybeifeaukjvguqqjh6fxfutujcc4khe6dvfx4u55duf76dvchxjootp4 default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 4118af6ef..2ce70007d 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeidfoajq7jno5ojcgvdkcacialgqr4rsayivkspjdyhcd2povbkiri +agent: valory/trader:0.1.0:bafybeien57adhb5nss3ghcqxlzldn2p3sk7rarb6pwsaboytnjvc3kjesa number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 5b287f3b5..a169cdbc3 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,11 +12,11 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeidny4y4w4jbjbp5d5qivur6jm37fnuik4mqzchzshiuvpozxe7vwy - behaviours/bet_placement.py: bafybeiauzdizqawjgzc3ugx33vuh726e25juhacqdr7c6uztpn6tra5dva + behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m + behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicl6b4hcmqmekta2mcuhkkydnzk7jmic6k44e6ns3u2ibad3awzvu - behaviours/decision_receive.py: bafybeiesgn3gaj34n554apuxhq7jldtjgnir77fvnkr3tw5t4fprbvqhum - behaviours/decision_request.py: bafybeibrk6jxalkgspinmjboqr3o6d6hl6mxtlkif74a5p32vp2zzhhzua + behaviours/decision_receive.py: bafybeid5yzjer3vacvrjz6rwksbuu5eqivwvpa2ag6wzwcceqagg2m3niy + behaviours/decision_request.py: bafybeia7ko3nryzcnsihh4ab7vnrgtyjm3w7tvmkxhqzr2a65hcfo5fzye behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeihywv5332ngbz4hhcwjbaglctblwjbfhdenppznnlxbsgnxdhrrim behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm @@ -25,13 +25,13 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeihy4igjg72xsgcntawxnzhimsrq2rlucmlbceeglqdgnihazoclxu - payloads.py: bafybeiawx6ix2ljvf545fe3wocdoh7frds6gjvzgv62b3w6huaolgvywqi + models.py: bafybeictiktfdhk2lur3yftnzwqnqm57dxgp42bqsp4xedtqwbcx3krcta + payloads.py: bafybeifq7mz5jbb6lqhdlrlr5kpqb2ghvr3xlt7usegaimree7yryeh2na policy.py: bafybeidpmx4ek3qze63zpuwixyf6t7bdv62ewgkzt3ljrzadiwdw64cueq redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm rounds.py: bafybeihopxmhzrpipc6r5x2vqf2tcixzuf5xdpqfsr7gr3n756n3ssft5q states/__init__.py: bafybeid23llnyp6j257dluxmrnztugo5llsrog7kua53hllyktz4dqhqoy - states/base.py: bafybeihe72qgalihmtzaezy3bvodxiqiawv2gzlnrfnmegddf22brieyiu + states/base.py: bafybeifgt4x5os25iq6ccaia5ka2okehfxv33oizgy3zjrnudgi46vis7q states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeifruvxwwltndwazkzzbpc5nnnad3z5t5ofy6d3i7nssljbxl6gvxu states/decision_receive.py: bafybeiasj5uaixpqau6hcxpw5vyevqrufd3ubkwvgbgy37gcwfom3bl3iq diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 2ebe1e1be..ff07739dd 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeichzmhpgyhk5gc6gepocdaghdwyoutq4x3ul4w7av4lasp7bxfb3y -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeib5s5ubudn67phubygrx7lmlzfrhwhy4lo6biusef7ffk2jyipn6a +- valory/decision_maker_abci:0.1.0:bafybeih4aa6rxd625clmccuz2dyhmnrsj4gxzo3pobu3l4gyopzsn7keeq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihjoetoipbyivp52xwpbfpvgqazzyrhh3djgi552xbpr7enlezpmi behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 0fb9b460a..526da2ec7 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeichzmhpgyhk5gc6gepocdaghdwyoutq4x3ul4w7av4lasp7bxfb3y +- valory/decision_maker_abci:0.1.0:bafybeih4aa6rxd625clmccuz2dyhmnrsj4gxzo3pobu3l4gyopzsn7keeq behaviours: main: args: {} From 84bfe308edeecc27913bb515eaa630ededaee47d Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 28 Oct 2023 08:35:58 +0200 Subject: [PATCH 61/79] doc: Add explanation for kelly calculation --- .gitignore | 2 ++ kelly_strategy_proof.md | 80 ----------------------------------------- 2 files changed, 2 insertions(+), 80 deletions(-) delete mode 100644 kelly_strategy_proof.md diff --git a/.gitignore b/.gitignore index f2695e299..769259560 100644 --- a/.gitignore +++ b/.gitignore @@ -45,3 +45,5 @@ trader/ !/packages/valory/agents/trader/ !/packages/valory/services/trader/ /trader_service/ + +kelly_strategy_explanation.md diff --git a/kelly_strategy_proof.md b/kelly_strategy_proof.md deleted file mode 100644 index 1484fe42e..000000000 --- a/kelly_strategy_proof.md +++ /dev/null @@ -1,80 +0,0 @@ -# Introduction -The Kelly Criterion is the calculation rule for the Kelly fraction $K$, which is the portion of the gambling capital to be wagered in order to maximize the profit considering the payoff odds and the probability of winning. The calculation rule is given by - -$$ -f^* = \frac{bp - (1 - p)}{b} -$$ - -where $f^*$ is the Kelly fraction of the bankroll, which is the maximum available gambling capital, $b$ is the net odds received on the wager (bet amount excluded), $p$ is the probability of winning, and $(1-p)$ is the probability of losing ([Beygelzimer et. al., 2012](#references)). - -In traditional betting frameworks, the odds for a bet are usually fixed when placing a bet and stay the same regardless of the betting amount. The Kelly Criterion was originally designed for static odds and faces some challenges when being used in scenarios with dynamic odds. In prediction markets run by Constant Product Market Makers (CPMMs) the odds depend on the bet amount. As the Kelly Criterion calculates the optimal bet amount based on the odds, there exist an interdependence of bet amount and odds. The following sections provide a way to calculate the optimal absolute Kelly bet amount depending on the Bankroll and number of outcome tokens fore each outcome in the liquidity pool before placing the bet. The function only applies for prediction markets run by CPMMs with a binary outcome. - -# Kelly equation with dynamic odds -## General Equation -The Kelly formula can be converted into - -$$ -f^* = \frac{Q \cdot p - 1}{Q - 1} -$$ - -where $Q$ is the gross payoff odds, i.e., in the event of a win, $Q$ times the amount wagered $( Q > 1 )$ will be received, including the initial investment. - -As the Kelly formula calculates the fraction $f^*$ of the bankroll $B$ (Maximum available gambling capital) to bet it can be written as - -$$f^*=\frac{X}{B}$$ - -where $X$ is the absolute Kelly bet amount. Setting bot equations equal to each other results in - -$$ -\frac{X}{B} = \frac{Q \cdot p - 1}{Q - 1} -$$ - -## Odds Function -The odds $Q$ for a bet in a prediction market run by a CPMM are calculated as -$$ -Q=\frac{n_r}{X} -$$ - -where $n_r$ is the number of the selected outcome token received from placing a bet X, if the market closes with the chosen answer. - -To calculate the number of received tokens $n_r$, the bet placement algorithm of a CPMM prediction market needs to be understood: When a user submits a bet placement transaction to the prediction market, this transaction includes among other parameters the investment amount and the vote. CPMMs are designed to always retain the product $k$ of their asset amounts $a$ and $b$ constant: - -$$k=a \cdot b \quad a,b > 0$$ - -To ensure this the CPMM divides the investment amount by the number of asset classes and - - -$Q$: gross payoff odds (e.g. If $Q=2$, the returned amount in case of winning a bet, where 1$ was invested is 2$.) - -$a$: Number of tokens of the selected outcome in the pool prior to bet placement - -$b$: Number of tokens of the other outcome in the pool prior to bet placement - -$a_{new}$: Number of tokens of the selected outcome in the pool after bet placement - -$b_{new}$: Number of tokens of the other outcome in the pool prior to bet placement - -$P_a$: Marginal price of $1$ selected token - -$P_b$: Marginal price of $1$ other token - - - - - - - - -$f^* = \frac{x}{B}$ - - - - - - -# References -**Angeris, G., Agrawal, A., Evans, A., Chitra, T., & Boyd, S.** (2021). *Constant Function Market Makers: Multi-Asset Trades via Convex Optimization*. arXiv preprint [arXiv:2107.12484 [math.OC]](https://arxiv.org/abs/2107.12484). - -**Beygelzimer, A., Langford, J., & Pennock, D.** (2012). *Learning Performance of Prediction Markets with Kelly Bettors*. arXiv preprint [arXiv:1201.6655 [cs.AI]](https://arxiv.org/abs/1201.6655). - - From 3e87ed7f157682e0dbea4e7ebb20019bd1d60dc2 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sat, 28 Oct 2023 17:04:34 +0200 Subject: [PATCH 62/79] feat: Add closing timespan for selecting bets as parameter variable --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 7 ++++--- packages/valory/services/trader/service.yaml | 3 ++- .../skills/decision_maker_abci/behaviours/sampling.py | 6 +++++- packages/valory/skills/decision_maker_abci/models.py | 2 ++ packages/valory/skills/decision_maker_abci/skill.yaml | 5 +++-- packages/valory/skills/trader_abci/skill.yaml | 5 +++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 25 insertions(+), 15 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 1715a9042..8b07e294e 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeih4aa6rxd625clmccuz2dyhmnrsj4gxzo3pobu3l4gyopzsn7keeq", - "skill/valory/trader_abci/0.1.0": "bafybeifeaukjvguqqjh6fxfutujcc4khe6dvfx4u55duf76dvchxjootp4", + "skill/valory/decision_maker_abci/0.1.0": "bafybeibwkfuzcqcgzhkca5dts3jqyx5lcxdaglxezxitys2stcrnfpegkq", + "skill/valory/trader_abci/0.1.0": "bafybeidhtfdxqfommouxrx35ur6hr7xfqms6xdmeslldadybjru7jj3dri", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeien57adhb5nss3ghcqxlzldn2p3sk7rarb6pwsaboytnjvc3kjesa", - "service/valory/trader/0.1.0": "bafybeidqfl6jwklwx252qhdupluxfhvvy4uzzg3pnm4izob4b76m7bvzbi", + "agent/valory/trader/0.1.0": "bafybeibfd2b5m4rpm3jwly2slh5g7t74egjncm6ympqjyzdcrtxlsdsxzy", + "service/valory/trader/0.1.0": "bafybeihsrrzf7rvlkioechtlpd465j3vq6bdcbgsz7gmmq5o46e3v4htcy", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeihjoetoipbyivp52xwpbfpvgqazzyrhh3djgi552xbpr7enlezpmi", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigk645ypegx6niauycxgvzvomyrfb4h5qvnht6hlmpqwwl5mb7eei", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 1b12692fc..ad2026703 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihjoetoipbyivp52xwpbfpvgqazzyrhh3djgi552xbpr7enlezpmi +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigk645ypegx6niauycxgvzvomyrfb4h5qvnht6hlmpqwwl5mb7eei - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeih4aa6rxd625clmccuz2dyhmnrsj4gxzo3pobu3l4gyopzsn7keeq -- valory/trader_abci:0.1.0:bafybeifeaukjvguqqjh6fxfutujcc4khe6dvfx4u55duf76dvchxjootp4 +- valory/decision_maker_abci:0.1.0:bafybeibwkfuzcqcgzhkca5dts3jqyx5lcxdaglxezxitys2stcrnfpegkq +- valory/trader_abci:0.1.0:bafybeidhtfdxqfommouxrx35ur6hr7xfqms6xdmeslldadybjru7jj3dri default_ledger: ethereum required_ledgers: - ethereum @@ -162,6 +162,7 @@ models: average_block_time: ${int:5} abt_error_mult: ${int:5} mech_agent_address: ${str:0xff82123dfb52ab75c417195c5fdb87630145ae81} + sample_bets_closing_days: ${int:10} trading_strategy: ${str:bet_amount_per_conf_threshold} bet_kelly_fraction: ${float:1.0} bet_amount_per_threshold: diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 2ce70007d..15168a0e9 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeien57adhb5nss3ghcqxlzldn2p3sk7rarb6pwsaboytnjvc3kjesa +agent: valory/trader:0.1.0:bafybeibfd2b5m4rpm3jwly2slh5g7t74egjncm6ympqjyzdcrtxlsdsxzy number_of_agents: 4 deployment: {} --- @@ -78,6 +78,7 @@ type: skill average_block_time: ${ABT:int:5} abt_error_mult: ${ABT_ERROR_MULT:int:5} mech_agent_address: ${MECH_AGENT_ADDRESS:str:0xff82123dfb52ab75c417195c5fdb87630145ae81} + sample_bets_closing_days: ${SAMPLE_BETS_CLOSING_DAYS:int:10} trading_strategy: ${TRADING_STRATEGY:str:bet_amount_per_conf_threshold} bet_kelly_fraction: ${BET_KELLY_FRACTION:float:1.0} bet_amount_per_threshold: &id004 diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index e0336b44d..dab342415 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -58,7 +58,11 @@ def _sampled_bet_idx(self, bets: List[Bet]) -> int: """ # Get only bets that close in the next 48 hours # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet - short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + 172800), bets) + if self.params.sample_bets_closing_days <= 0: + msg = "The number of days to sample bets from must be positive!" + self.context.logger.warning(msg) + return None + short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + self.params.sample_bets_closing_days*60*60*24), bets) short_term_bets_list = list(short_term_bets) if len(short_term_bets_list) == 0: return None diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 893a62bf2..a28c01a83 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -94,6 +94,8 @@ class DecisionMakerParams(MarketManagerParams): def __init__(self, *args: Any, **kwargs: Any) -> None: """Initialize the parameters' object.""" self.mech_agent_address: str = self._ensure("mech_agent_address", kwargs, str) + self.sample_bets_closing_days: int = self._ensure("sample_bets_closing_days", kwargs, int) + self.bet_kelly_fraction: float = self._ensure("bet_kelly_fraction", kwargs, float) # the trading strategy to use for placing bets self.trading_strategy: str = self._ensure("trading_strategy", kwargs, str) # the factor of calculated kelly bet to use for placing bets diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index a169cdbc3..7cf18c6e2 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -20,12 +20,12 @@ fingerprint: behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeihywv5332ngbz4hhcwjbaglctblwjbfhdenppznnlxbsgnxdhrrim behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeiarw643pcvh7xk4pp7ytxqbif4ocp5smydrkqv2nnwnlocxpwwyt4 + behaviours/sampling.py: bafybeiflvr2anw3ndwr7h7nvz7r54jcexiehjtyklsgsbyso3dnzrjvojm behaviours/tool_selection.py: bafybeigfr2frkljrxyfxs5p3j42equzehgaqtkyuxk6eiujyudr6ajqakm dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeictiktfdhk2lur3yftnzwqnqm57dxgp42bqsp4xedtqwbcx3krcta + models.py: bafybeifimsvv37emaffsc7zqhg5rkps5q6e7ah7xwjzap7znb2k65ailva payloads.py: bafybeifq7mz5jbb6lqhdlrlr5kpqb2ghvr3xlt7usegaimree7yryeh2na policy.py: bafybeidpmx4ek3qze63zpuwixyf6t7bdv62ewgkzt3ljrzadiwdw64cueq redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm @@ -161,6 +161,7 @@ models: tx_timeout: 10.0 use_termination: false mech_agent_address: '0xff82123dfb52ab75c417195c5fdb87630145ae81' + sample_bets_closing_days: 10 trading_strategy: bet_amount_per_conf_threshold bet_kelly_fraction: 1.0 bet_amount_per_threshold: diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index ff07739dd..74535ad20 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeih4aa6rxd625clmccuz2dyhmnrsj4gxzo3pobu3l4gyopzsn7keeq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeihjoetoipbyivp52xwpbfpvgqazzyrhh3djgi552xbpr7enlezpmi +- valory/decision_maker_abci:0.1.0:bafybeibwkfuzcqcgzhkca5dts3jqyx5lcxdaglxezxitys2stcrnfpegkq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigk645ypegx6niauycxgvzvomyrfb4h5qvnht6hlmpqwwl5mb7eei behaviours: main: args: {} @@ -144,6 +144,7 @@ models: average_block_time: 5 abt_error_mult: 5 mech_agent_address: '0xff82123dfb52ab75c417195c5fdb87630145ae81' + sample_bets_closing_days: 10 trading_strategy: bet_amount_per_conf_threshold bet_kelly_fraction: 1.0 bet_amount_per_threshold: diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 526da2ec7..0739dafc5 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeih4aa6rxd625clmccuz2dyhmnrsj4gxzo3pobu3l4gyopzsn7keeq +- valory/decision_maker_abci:0.1.0:bafybeibwkfuzcqcgzhkca5dts3jqyx5lcxdaglxezxitys2stcrnfpegkq behaviours: main: args: {} From 0cf81d369a21dd125f3c4e8b667ca039ebcd558e Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 29 Oct 2023 11:20:13 +0100 Subject: [PATCH 63/79] fix: Remove kelly bet fraction check; remove bet adjustment when high bet while low liquidity --- packages/packages.json | 10 ++++---- packages/valory/agents/trader/aea-config.yaml | 6 ++--- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 24 ------------------- .../skills/decision_maker_abci/models.py | 8 +++---- .../skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 18 insertions(+), 42 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 8b07e294e..8b96056fc 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeibwkfuzcqcgzhkca5dts3jqyx5lcxdaglxezxitys2stcrnfpegkq", - "skill/valory/trader_abci/0.1.0": "bafybeidhtfdxqfommouxrx35ur6hr7xfqms6xdmeslldadybjru7jj3dri", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidfnvzgccil5wstwcljvcyfm4jrkjvro2uozjd3dxg2efvfhnqxt4", + "skill/valory/trader_abci/0.1.0": "bafybeifwqnaj2cdzvgba74ajcx3aspboyhuzp6tdmhpl3alq5iyna3shza", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeibfd2b5m4rpm3jwly2slh5g7t74egjncm6ympqjyzdcrtxlsdsxzy", - "service/valory/trader/0.1.0": "bafybeihsrrzf7rvlkioechtlpd465j3vq6bdcbgsz7gmmq5o46e3v4htcy", + "agent/valory/trader/0.1.0": "bafybeif7fbm2se4dtk3rfdbiiko3eruclsa7qmommezxcxwjxupdrzpjsy", + "service/valory/trader/0.1.0": "bafybeigmm5qajmmmsmeug2agc7t2p33nbxoycezgiuh44tnenfpqjvqg2e", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigk645ypegx6niauycxgvzvomyrfb4h5qvnht6hlmpqwwl5mb7eei", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeieyqfhflrkbnmqefpqbseuo7cmnopem6k3a5uhd6xilekjtukcriu", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index ad2026703..206f2e002 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigk645ypegx6niauycxgvzvomyrfb4h5qvnht6hlmpqwwl5mb7eei +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieyqfhflrkbnmqefpqbseuo7cmnopem6k3a5uhd6xilekjtukcriu - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibwkfuzcqcgzhkca5dts3jqyx5lcxdaglxezxitys2stcrnfpegkq -- valory/trader_abci:0.1.0:bafybeidhtfdxqfommouxrx35ur6hr7xfqms6xdmeslldadybjru7jj3dri +- valory/decision_maker_abci:0.1.0:bafybeidfnvzgccil5wstwcljvcyfm4jrkjvro2uozjd3dxg2efvfhnqxt4 +- valory/trader_abci:0.1.0:bafybeifwqnaj2cdzvgba74ajcx3aspboyhuzp6tdmhpl3alq5iyna3shza default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 15168a0e9..427bc9d72 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeibfd2b5m4rpm3jwly2slh5g7t74egjncm6ympqjyzdcrtxlsdsxzy +agent: valory/trader:0.1.0:bafybeif7fbm2se4dtk3rfdbiiko3eruclsa7qmommezxcxwjxupdrzpjsy number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index fd01743ac..0687ece5c 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -410,7 +410,6 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) # Set available shares to 1/3 of the total available shares to prevent the bot from buying all shares in this test scenario - available_shares = int(available_shares / 3) self.context.logger.info(f"Adjusted available shares: {available_shares}") if num_shares > available_shares * SLIPPAGE: self.context.logger.warning( @@ -418,31 +417,8 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - "Consequently, this situation entails a higher level of risk as the obtained number of shares, " "and therefore the potential net profit, will be lower than if the pool had higher liquidity!" ) - if self.params.trading_strategy == "kelly_criterion": - self.context.logger.warning( - "Reducing kelly bet amount so the bought shares don't exceed available shares" - ) - prev_bet_amount = bet_amount - bet_amount = self.get_max_bet_amount( - available_shares, - selected_type_tokens_in_pool, - other_tokens_in_pool, - bet_fee, - ) - if bet_amount >= prev_bet_amount: - bet_amount = 0 - self.context.logger.warning( - "The new bet amount is >= the previous one. There might be a calculation error. \ - No bet will be placed." - ) - else: - self.context.logger.info( - f"New bet amount: {bet_amount}" - f"Betting {round(100*bet_amount/prev_bet_amount, 2)}% of the calculated kelly bet amount." - ) bet_threshold = self.params.bet_threshold self.context.logger.info(f"Bet threshold: {bet_threshold}") - if bet_threshold <= 0: self.context.logger.warning( f"A non-positive bet threshold was given ({bet_threshold}). The threshold will be disabled, " diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index a28c01a83..370ac007f 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -94,12 +94,12 @@ class DecisionMakerParams(MarketManagerParams): def __init__(self, *args: Any, **kwargs: Any) -> None: """Initialize the parameters' object.""" self.mech_agent_address: str = self._ensure("mech_agent_address", kwargs, str) - self.sample_bets_closing_days: int = self._ensure("sample_bets_closing_days", kwargs, int) - self.bet_kelly_fraction: float = self._ensure("bet_kelly_fraction", kwargs, float) + # # the number of days to sample bets from + # self.sample_bets_closing_days: int = self._ensure("sample_bets_closing_days", kwargs, int) # the trading strategy to use for placing bets self.trading_strategy: str = self._ensure("trading_strategy", kwargs, str) - # the factor of calculated kelly bet to use for placing bets - self.bet_kelly_fraction: float = self._ensure("bet_kelly_fraction", kwargs, float) + # # the factor of calculated kelly bet to use for placing bets + # self.bet_kelly_fraction: float = self._ensure("bet_kelly_fraction", kwargs, float) # this is a mapping from the confidence of a bet's choice to the amount we are willing to bet self.bet_amount_per_threshold: Dict[float, int] = self._ensure( "bet_amount_per_threshold", kwargs, Dict[float, int] diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 7cf18c6e2..0e3cfa1d2 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicl6b4hcmqmekta2mcuhkkydnzk7jmic6k44e6ns3u2ibad3awzvu - behaviours/decision_receive.py: bafybeid5yzjer3vacvrjz6rwksbuu5eqivwvpa2ag6wzwcceqagg2m3niy + behaviours/decision_receive.py: bafybeifscx27fxwdqqrh7ne7ncczzsnqhm3qhu4xvsyfpzosppb3df3xme behaviours/decision_request.py: bafybeia7ko3nryzcnsihh4ab7vnrgtyjm3w7tvmkxhqzr2a65hcfo5fzye behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeihywv5332ngbz4hhcwjbaglctblwjbfhdenppznnlxbsgnxdhrrim @@ -25,7 +25,7 @@ fingerprint: dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeifimsvv37emaffsc7zqhg5rkps5q6e7ah7xwjzap7znb2k65ailva + models.py: bafybeih4t43cod4mi4hper4w4jwttenhdzh653cmhzmybaqocuwcpuh5ri payloads.py: bafybeifq7mz5jbb6lqhdlrlr5kpqb2ghvr3xlt7usegaimree7yryeh2na policy.py: bafybeidpmx4ek3qze63zpuwixyf6t7bdv62ewgkzt3ljrzadiwdw64cueq redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 74535ad20..9c07e35e8 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeibwkfuzcqcgzhkca5dts3jqyx5lcxdaglxezxitys2stcrnfpegkq -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigk645ypegx6niauycxgvzvomyrfb4h5qvnht6hlmpqwwl5mb7eei +- valory/decision_maker_abci:0.1.0:bafybeidfnvzgccil5wstwcljvcyfm4jrkjvro2uozjd3dxg2efvfhnqxt4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieyqfhflrkbnmqefpqbseuo7cmnopem6k3a5uhd6xilekjtukcriu behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 0739dafc5..088668df3 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeibwkfuzcqcgzhkca5dts3jqyx5lcxdaglxezxitys2stcrnfpegkq +- valory/decision_maker_abci:0.1.0:bafybeidfnvzgccil5wstwcljvcyfm4jrkjvro2uozjd3dxg2efvfhnqxt4 behaviours: main: args: {} From 9d830b2ad1b4be363cd8fee3e1e68312143d9c08 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 29 Oct 2023 11:50:53 +0100 Subject: [PATCH 64/79] fix: Add params check --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/behaviours/sampling.py | 1 + packages/valory/skills/decision_maker_abci/models.py | 8 ++++---- packages/valory/skills/decision_maker_abci/skill.yaml | 4 ++-- packages/valory/skills/trader_abci/skill.yaml | 4 ++-- .../skills/tx_settlement_multiplexer_abci/skill.yaml | 2 +- 8 files changed, 19 insertions(+), 18 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 8b96056fc..163e02fff 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeidfnvzgccil5wstwcljvcyfm4jrkjvro2uozjd3dxg2efvfhnqxt4", - "skill/valory/trader_abci/0.1.0": "bafybeifwqnaj2cdzvgba74ajcx3aspboyhuzp6tdmhpl3alq5iyna3shza", + "skill/valory/decision_maker_abci/0.1.0": "bafybeid5a66v22jqqmomszxnmjs36jwjqd54dmjngm6g4jhb7l4b2hlovu", + "skill/valory/trader_abci/0.1.0": "bafybeie52d2sopsoh7sq4dxmwqadnjwjiyqzleakxhraidswksxovfw33i", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeif7fbm2se4dtk3rfdbiiko3eruclsa7qmommezxcxwjxupdrzpjsy", - "service/valory/trader/0.1.0": "bafybeigmm5qajmmmsmeug2agc7t2p33nbxoycezgiuh44tnenfpqjvqg2e", + "agent/valory/trader/0.1.0": "bafybeiezt6rrvgzocndfx2o6mc7dvuvkp7kt7y5tgwkgw4xqgsz4sdpig4", + "service/valory/trader/0.1.0": "bafybeifiauyzhgndr6czi3t3wfamwrpxs6ueflqtclgvais74s76odsw3i", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeieyqfhflrkbnmqefpqbseuo7cmnopem6k3a5uhd6xilekjtukcriu", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiglc3mdmlesffzpxl7to4skarqzn2aftpfgngjqnijd4zkmxmmqdq", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 206f2e002..9369a4e03 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieyqfhflrkbnmqefpqbseuo7cmnopem6k3a5uhd6xilekjtukcriu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiglc3mdmlesffzpxl7to4skarqzn2aftpfgngjqnijd4zkmxmmqdq - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidfnvzgccil5wstwcljvcyfm4jrkjvro2uozjd3dxg2efvfhnqxt4 -- valory/trader_abci:0.1.0:bafybeifwqnaj2cdzvgba74ajcx3aspboyhuzp6tdmhpl3alq5iyna3shza +- valory/decision_maker_abci:0.1.0:bafybeid5a66v22jqqmomszxnmjs36jwjqd54dmjngm6g4jhb7l4b2hlovu +- valory/trader_abci:0.1.0:bafybeie52d2sopsoh7sq4dxmwqadnjwjiyqzleakxhraidswksxovfw33i default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 427bc9d72..e217f0b51 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeif7fbm2se4dtk3rfdbiiko3eruclsa7qmommezxcxwjxupdrzpjsy +agent: valory/trader:0.1.0:bafybeiezt6rrvgzocndfx2o6mc7dvuvkp7kt7y5tgwkgw4xqgsz4sdpig4 number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index dab342415..e6d5f4028 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -58,6 +58,7 @@ def _sampled_bet_idx(self, bets: List[Bet]) -> int: """ # Get only bets that close in the next 48 hours # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet + if self.params.sample_bets_closing_days <= 0: msg = "The number of days to sample bets from must be positive!" self.context.logger.warning(msg) diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 370ac007f..9f877df7f 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -94,12 +94,12 @@ class DecisionMakerParams(MarketManagerParams): def __init__(self, *args: Any, **kwargs: Any) -> None: """Initialize the parameters' object.""" self.mech_agent_address: str = self._ensure("mech_agent_address", kwargs, str) - # # the number of days to sample bets from - # self.sample_bets_closing_days: int = self._ensure("sample_bets_closing_days", kwargs, int) + # the number of days to sample bets from + self.sample_bets_closing_days: int = self._ensure("sample_bets_closing_days", kwargs, int) # the trading strategy to use for placing bets self.trading_strategy: str = self._ensure("trading_strategy", kwargs, str) - # # the factor of calculated kelly bet to use for placing bets - # self.bet_kelly_fraction: float = self._ensure("bet_kelly_fraction", kwargs, float) + # the factor of calculated kelly bet to use for placing bets + self.bet_kelly_fraction: float = self._ensure("bet_kelly_fraction", kwargs, float) # this is a mapping from the confidence of a bet's choice to the amount we are willing to bet self.bet_amount_per_threshold: Dict[float, int] = self._ensure( "bet_amount_per_threshold", kwargs, Dict[float, int] diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 0e3cfa1d2..ce975baa7 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -20,12 +20,12 @@ fingerprint: behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeihywv5332ngbz4hhcwjbaglctblwjbfhdenppznnlxbsgnxdhrrim behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeiflvr2anw3ndwr7h7nvz7r54jcexiehjtyklsgsbyso3dnzrjvojm + behaviours/sampling.py: bafybeibzx5euk6u2lazji6cktbebieoov3oyziksnhuy6e72xywlrrsj4u behaviours/tool_selection.py: bafybeigfr2frkljrxyfxs5p3j42equzehgaqtkyuxk6eiujyudr6ajqakm dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeih4t43cod4mi4hper4w4jwttenhdzh653cmhzmybaqocuwcpuh5ri + models.py: bafybeib3plosgwkkzjape77vodcc72diztvn7nbceiaxekuc7t33j5x3dy payloads.py: bafybeifq7mz5jbb6lqhdlrlr5kpqb2ghvr3xlt7usegaimree7yryeh2na policy.py: bafybeidpmx4ek3qze63zpuwixyf6t7bdv62ewgkzt3ljrzadiwdw64cueq redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 9c07e35e8..a14314726 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidfnvzgccil5wstwcljvcyfm4jrkjvro2uozjd3dxg2efvfhnqxt4 -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeieyqfhflrkbnmqefpqbseuo7cmnopem6k3a5uhd6xilekjtukcriu +- valory/decision_maker_abci:0.1.0:bafybeid5a66v22jqqmomszxnmjs36jwjqd54dmjngm6g4jhb7l4b2hlovu +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiglc3mdmlesffzpxl7to4skarqzn2aftpfgngjqnijd4zkmxmmqdq behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 088668df3..eb1f0c534 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeidfnvzgccil5wstwcljvcyfm4jrkjvro2uozjd3dxg2efvfhnqxt4 +- valory/decision_maker_abci:0.1.0:bafybeid5a66v22jqqmomszxnmjs36jwjqd54dmjngm6g4jhb7l4b2hlovu behaviours: main: args: {} From c4c6b8469276cd6a058834e397249c4aa54a6247 Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 29 Oct 2023 12:23:41 +0100 Subject: [PATCH 65/79] refactor: Reactivate bet threshold based on market liquidity for testing scenario --- packages/packages.json | 10 ++--- packages/valory/agents/trader/aea-config.yaml | 6 +-- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 38 +++++++++++++------ .../skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 +- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 39 insertions(+), 25 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 163e02fff..513602a87 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeid5a66v22jqqmomszxnmjs36jwjqd54dmjngm6g4jhb7l4b2hlovu", - "skill/valory/trader_abci/0.1.0": "bafybeie52d2sopsoh7sq4dxmwqadnjwjiyqzleakxhraidswksxovfw33i", + "skill/valory/decision_maker_abci/0.1.0": "bafybeidgjt4wbkbxplze4girajvphlrsgoi4lp3sqraic7zxzrr6saa3j4", + "skill/valory/trader_abci/0.1.0": "bafybeiatac6irwe3aifwxobdtogu5puqrqzca7hpszxcc3dninkcqsbm7a", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeiezt6rrvgzocndfx2o6mc7dvuvkp7kt7y5tgwkgw4xqgsz4sdpig4", - "service/valory/trader/0.1.0": "bafybeifiauyzhgndr6czi3t3wfamwrpxs6ueflqtclgvais74s76odsw3i", + "agent/valory/trader/0.1.0": "bafybeibmqtverd7ijecjjssyyce3c3sat5pf2ecdtudts5lxs3vlvvua7u", + "service/valory/trader/0.1.0": "bafybeigvw2v3si54kkssfoiiyvyzunykevpqcqpvrwobdqerhxwopwgssq", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiglc3mdmlesffzpxl7to4skarqzn2aftpfgngjqnijd4zkmxmmqdq", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibyz5jjbvfbxlslsdwneq4o7c4skbr6ge4o4r7q6i5xvzc7wwtcp4", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 9369a4e03..00f0de89e 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiglc3mdmlesffzpxl7to4skarqzn2aftpfgngjqnijd4zkmxmmqdq +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibyz5jjbvfbxlslsdwneq4o7c4skbr6ge4o4r7q6i5xvzc7wwtcp4 - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeid5a66v22jqqmomszxnmjs36jwjqd54dmjngm6g4jhb7l4b2hlovu -- valory/trader_abci:0.1.0:bafybeie52d2sopsoh7sq4dxmwqadnjwjiyqzleakxhraidswksxovfw33i +- valory/decision_maker_abci:0.1.0:bafybeidgjt4wbkbxplze4girajvphlrsgoi4lp3sqraic7zxzrr6saa3j4 +- valory/trader_abci:0.1.0:bafybeiatac6irwe3aifwxobdtogu5puqrqzca7hpszxcc3dninkcqsbm7a default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index e217f0b51..60f2c457e 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeiezt6rrvgzocndfx2o6mc7dvuvkp7kt7y5tgwkgw4xqgsz4sdpig4 +agent: valory/trader:0.1.0:bafybeibmqtverd7ijecjjssyyce3c3sat5pf2ecdtudts5lxs3vlvvua7u number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 0687ece5c..678b51619 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -390,17 +390,6 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - bet_fee, ) - # # Safety fallback to bet amount per conf threshold - # # Only remove if you are sure that kelly bet amount is working as expected - # bet_amount = self.get_bet_amount( - # bankroll, - # "bet_amount_per_conf_threshold", - # win_probability, - # confidence, - # selected_type_tokens_in_pool, - # other_tokens_in_pool, - # bet_fee, - # ) self.context.logger.info(f"Bet amount: {bet_amount}") self.context.logger.info(f"Bet fee: {bet.fee}") net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) @@ -409,7 +398,9 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) - # Set available shares to 1/3 of the total available shares to prevent the bot from buying all shares in this test scenario + # Set available shares to 1/3 of the total available shares to prevent the bot from consuming too much liquidity + # Deactivate if bet strategy is kelly and it is no test scenario as kelly counts liquidity in already. + available_shares = int(available_shares / 3) self.context.logger.info(f"Adjusted available shares: {available_shares}") if num_shares > available_shares * SLIPPAGE: self.context.logger.warning( @@ -417,6 +408,29 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - "Consequently, this situation entails a higher level of risk as the obtained number of shares, " "and therefore the potential net profit, will be lower than if the pool had higher liquidity!" ) + if self.params.trading_strategy == "kelly_criterion": + self.context.logger.warning( + "Reducing kelly bet amount so the bought shares don't exceed available shares" + ) + prev_bet_amount = bet_amount + bet_amount = self.get_max_bet_amount( + available_shares, + selected_type_tokens_in_pool, + other_tokens_in_pool, + bet_fee, + ) + if bet_amount >= prev_bet_amount: + bet_amount = 0 + self.context.logger.warning( + "The new bet amount is >= the previous one. There might be a calculation error. \ + No bet will be placed." + ) + else: + self.context.logger.info( + f"New bet amount: {bet_amount}" + f"Betting {round(100*bet_amount/prev_bet_amount, 2)}% of the calculated kelly bet amount." + ) + bet_threshold = self.params.bet_threshold self.context.logger.info(f"Bet threshold: {bet_threshold}") if bet_threshold <= 0: diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index ce975baa7..e1b4186b3 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicl6b4hcmqmekta2mcuhkkydnzk7jmic6k44e6ns3u2ibad3awzvu - behaviours/decision_receive.py: bafybeifscx27fxwdqqrh7ne7ncczzsnqhm3qhu4xvsyfpzosppb3df3xme + behaviours/decision_receive.py: bafybeihrybg4clfvojzgcmexl3kfbgshuz2etdwzhcqe5aaujf4qoa5xv4 behaviours/decision_request.py: bafybeia7ko3nryzcnsihh4ab7vnrgtyjm3w7tvmkxhqzr2a65hcfo5fzye behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeihywv5332ngbz4hhcwjbaglctblwjbfhdenppznnlxbsgnxdhrrim diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index a14314726..0f0bd638d 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeid5a66v22jqqmomszxnmjs36jwjqd54dmjngm6g4jhb7l4b2hlovu -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiglc3mdmlesffzpxl7to4skarqzn2aftpfgngjqnijd4zkmxmmqdq +- valory/decision_maker_abci:0.1.0:bafybeidgjt4wbkbxplze4girajvphlrsgoi4lp3sqraic7zxzrr6saa3j4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibyz5jjbvfbxlslsdwneq4o7c4skbr6ge4o4r7q6i5xvzc7wwtcp4 behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index eb1f0c534..84d32bfc4 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeid5a66v22jqqmomszxnmjs36jwjqd54dmjngm6g4jhb7l4b2hlovu +- valory/decision_maker_abci:0.1.0:bafybeidgjt4wbkbxplze4girajvphlrsgoi4lp3sqraic7zxzrr6saa3j4 behaviours: main: args: {} From 58e413f3fecbc9baf4ebfe23181aec48d179e89d Mon Sep 17 00:00:00 2001 From: Jannik Hehemann Date: Sun, 29 Oct 2023 14:01:52 +0100 Subject: [PATCH 66/79] refactor: Remove bet threshold based on liquidity measure --- packages/packages.json | 10 +++---- packages/valory/agents/trader/aea-config.yaml | 6 ++--- packages/valory/services/trader/service.yaml | 2 +- .../behaviours/decision_receive.py | 26 ------------------- .../skills/decision_maker_abci/skill.yaml | 2 +- packages/valory/skills/trader_abci/skill.yaml | 4 +-- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 7 files changed, 13 insertions(+), 39 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 513602a87..8cd4a573d 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m", - "skill/valory/decision_maker_abci/0.1.0": "bafybeidgjt4wbkbxplze4girajvphlrsgoi4lp3sqraic7zxzrr6saa3j4", - "skill/valory/trader_abci/0.1.0": "bafybeiatac6irwe3aifwxobdtogu5puqrqzca7hpszxcc3dninkcqsbm7a", + "skill/valory/decision_maker_abci/0.1.0": "bafybeid6s6rixpn7w37u6tntxvcjokxsdwomlfbyqx4oje7eurohp5ddti", + "skill/valory/trader_abci/0.1.0": "bafybeicpvkcfq2imdn2dpckr7ehwxc56ucweqjjql4pc4xvphyu253y3w4", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeibmqtverd7ijecjjssyyce3c3sat5pf2ecdtudts5lxs3vlvvua7u", - "service/valory/trader/0.1.0": "bafybeigvw2v3si54kkssfoiiyvyzunykevpqcqpvrwobdqerhxwopwgssq", + "agent/valory/trader/0.1.0": "bafybeicpsqvqkk4gw3fzy6jrkylgrzegghsrzklwxopffsl5f3gluywrme", + "service/valory/trader/0.1.0": "bafybeifm25ns3xjbw72ty7ovnt6dop7obyxqhftidsoqx4rel6lmsz2b7i", "contract/valory/erc20/0.1.0": "bafybeibysifjwhlcn7nntsjkowdmja53ed6urfzypi6sxfc7chtheecvpi", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeibyz5jjbvfbxlslsdwneq4o7c4skbr6ge4o4r7q6i5xvzc7wwtcp4", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigyaiv732wt62rqxflsyj4u7hasakt6kyvk6dwvjnaihptrrfq6hi", "contract/valory/mech/0.1.0": "bafybeifaavuqr2bz7nypapjwkufc5c6vwxm5ifucmtd3w7sh42tne35nga", "contract/valory/realitio/0.1.0": "bafybeic3wihpzz4deguslpzlnsgrlrabclq3njwuagyaiiv6rzqujfrs6e", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 00f0de89e..c7d1a46b7 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -41,10 +41,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibyz5jjbvfbxlslsdwneq4o7c4skbr6ge4o4r7q6i5xvzc7wwtcp4 +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigyaiv732wt62rqxflsyj4u7hasakt6kyvk6dwvjnaihptrrfq6hi - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidgjt4wbkbxplze4girajvphlrsgoi4lp3sqraic7zxzrr6saa3j4 -- valory/trader_abci:0.1.0:bafybeiatac6irwe3aifwxobdtogu5puqrqzca7hpszxcc3dninkcqsbm7a +- valory/decision_maker_abci:0.1.0:bafybeid6s6rixpn7w37u6tntxvcjokxsdwomlfbyqx4oje7eurohp5ddti +- valory/trader_abci:0.1.0:bafybeicpvkcfq2imdn2dpckr7ehwxc56ucweqjjql4pc4xvphyu253y3w4 default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 60f2c457e..cd89948af 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeibmqtverd7ijecjjssyyce3c3sat5pf2ecdtudts5lxs3vlvvua7u +agent: valory/trader:0.1.0:bafybeicpsqvqkk4gw3fzy6jrkylgrzegghsrzklwxopffsl5f3gluywrme number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 678b51619..24327385b 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -398,9 +398,6 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) - # Set available shares to 1/3 of the total available shares to prevent the bot from consuming too much liquidity - # Deactivate if bet strategy is kelly and it is no test scenario as kelly counts liquidity in already. - available_shares = int(available_shares / 3) self.context.logger.info(f"Adjusted available shares: {available_shares}") if num_shares > available_shares * SLIPPAGE: self.context.logger.warning( @@ -408,29 +405,6 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - "Consequently, this situation entails a higher level of risk as the obtained number of shares, " "and therefore the potential net profit, will be lower than if the pool had higher liquidity!" ) - if self.params.trading_strategy == "kelly_criterion": - self.context.logger.warning( - "Reducing kelly bet amount so the bought shares don't exceed available shares" - ) - prev_bet_amount = bet_amount - bet_amount = self.get_max_bet_amount( - available_shares, - selected_type_tokens_in_pool, - other_tokens_in_pool, - bet_fee, - ) - if bet_amount >= prev_bet_amount: - bet_amount = 0 - self.context.logger.warning( - "The new bet amount is >= the previous one. There might be a calculation error. \ - No bet will be placed." - ) - else: - self.context.logger.info( - f"New bet amount: {bet_amount}" - f"Betting {round(100*bet_amount/prev_bet_amount, 2)}% of the calculated kelly bet amount." - ) - bet_threshold = self.params.bet_threshold self.context.logger.info(f"Bet threshold: {bet_threshold}") if bet_threshold <= 0: diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index e1b4186b3..d15ab99f9 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -15,7 +15,7 @@ fingerprint: behaviours/base.py: bafybeiakjp65ts3do3wi5bvpizt4vel7sgy5znbtr4obsu4i7h437gob6m behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicl6b4hcmqmekta2mcuhkkydnzk7jmic6k44e6ns3u2ibad3awzvu - behaviours/decision_receive.py: bafybeihrybg4clfvojzgcmexl3kfbgshuz2etdwzhcqe5aaujf4qoa5xv4 + behaviours/decision_receive.py: bafybeigketncslwg5y3uidso4kmviy4cb5xasjf4fyfj6lfcenln6pnqdm behaviours/decision_request.py: bafybeia7ko3nryzcnsihh4ab7vnrgtyjm3w7tvmkxhqzr2a65hcfo5fzye behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm behaviours/reedem.py: bafybeihywv5332ngbz4hhcwjbaglctblwjbfhdenppznnlxbsgnxdhrrim diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index 0f0bd638d..d0edacd1c 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -25,8 +25,8 @@ skills: - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeidgjt4wbkbxplze4girajvphlrsgoi4lp3sqraic7zxzrr6saa3j4 -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeibyz5jjbvfbxlslsdwneq4o7c4skbr6ge4o4r7q6i5xvzc7wwtcp4 +- valory/decision_maker_abci:0.1.0:bafybeid6s6rixpn7w37u6tntxvcjokxsdwomlfbyqx4oje7eurohp5ddti +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigyaiv732wt62rqxflsyj4u7hasakt6kyvk6dwvjnaihptrrfq6hi behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 84d32bfc4..9b13f68dc 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeidgjt4wbkbxplze4girajvphlrsgoi4lp3sqraic7zxzrr6saa3j4 +- valory/decision_maker_abci:0.1.0:bafybeid6s6rixpn7w37u6tntxvcjokxsdwomlfbyqx4oje7eurohp5ddti behaviours: main: args: {} From a9f58c80d13d9e2bdaf6a67b2706df0e224008b3 Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:01:10 +0200 Subject: [PATCH 67/79] fix: bets filtering for `kelly_criterion` --- .../decision_maker_abci/behaviours/base.py | 5 +++ .../decision_maker_abci/behaviours/reedem.py | 5 --- .../behaviours/sampling.py | 33 ++++++++----------- .../skills/decision_maker_abci/models.py | 4 +++ 4 files changed, 22 insertions(+), 25 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 1f8af74ba..f8b1fdaf6 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -93,6 +93,11 @@ def synchronized_data(self) -> SynchronizedData: """Return the synchronized data.""" return SynchronizedData(super().synchronized_data.db) + @property + def synced_timestamp(self) -> int: + """Return the synchronized timestamp across the agents.""" + return int(self.round_sequence.last_round_transition_timestamp.timestamp()) + @property def safe_tx_hash(self) -> str: """Get the safe_tx_hash.""" diff --git a/packages/valory/skills/decision_maker_abci/behaviours/reedem.py b/packages/valory/skills/decision_maker_abci/behaviours/reedem.py index aee5073bd..e75531069 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/reedem.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/reedem.py @@ -83,11 +83,6 @@ def __init__(self, **kwargs: Any) -> None: # from all trades associated with it. self.claimable_amounts: Dict[HexBytes, int] = {} - @property - def synced_timestamp(self) -> int: - """Return the synchronized timestamp across the agents.""" - return int(self.round_sequence.last_round_transition_timestamp.timestamp()) - def setup(self) -> None: """Setup the behaviour""" self._policy = self.synchronized_data.policy diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index e6d5f4028..cadd461e9 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -35,6 +35,9 @@ ) +UNIX_DAY = 60 * 60 * 24 + + class SamplingBehaviour(DecisionMakerBaseBehaviour): """A behaviour in which the agents blacklist the sampled bet.""" @@ -44,31 +47,25 @@ class SamplingBehaviour(DecisionMakerBaseBehaviour): def available_bets(self) -> Iterator[Bet]: """Get an iterator of the unprocessed bets.""" bets = self.synchronized_data.bets + + # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet + if self.params.trading_strategy == "kelly_criterion": + # get only bets that close in the next 48 hours + bets = [bet for bet in bets if bet.openingTimestamp <= (self.synced_timestamp + self.params.sample_bets_closing_days * UNIX_DAY)] + return filter(lambda bet: bet.status == BetStatus.UNPROCESSED, bets) def _sampled_bet_idx(self, bets: List[Bet]) -> int: """ Sample a bet and return its id. - The sampling logic is relatively simple at the moment + The sampling logic is relatively simple at the moment. It simply selects the unprocessed bet with the largest liquidity. :param bets: the bets' values to compare for the sampling. :return: the id of the sampled bet, out of all the available bets, not only the given ones. """ - # Get only bets that close in the next 48 hours - # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet - - if self.params.sample_bets_closing_days <= 0: - msg = "The number of days to sample bets from must be positive!" - self.context.logger.warning(msg) - return None - short_term_bets = filter(lambda bet: bet.openingTimestamp <= (time.time() + self.params.sample_bets_closing_days*60*60*24), bets) - short_term_bets_list = list(short_term_bets) - if len(short_term_bets_list) == 0: - return None - self.context.logger.info(f"Short term bets: {short_term_bets_list}") - return self.synchronized_data.bets.index(max(short_term_bets_list)) + return self.synchronized_data.bets.index(max(bets)) def _set_processed(self, idx: int) -> Optional[str]: """Update the bet's status for the given id to `PROCESSED`, and return the updated bets list, serialized.""" @@ -86,12 +83,8 @@ def _sample(self) -> Tuple[Optional[str], Optional[int]]: return None, None idx = self._sampled_bet_idx(available_bets) - - if idx is None: - msg = "There were no unprocessed bets that close within the next 48 hours available to sample from!" - self.context.logger.warning(msg) - return None, None - elif self.synchronized_data.bets[idx].scaledLiquidityMeasure == 0: + + if self.synchronized_data.bets[idx].scaledLiquidityMeasure == 0: msg = "There were no unprocessed bets with non-zero liquidity!" self.context.logger.warning(msg) return None, None diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 9f877df7f..8f92c87e0 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -96,6 +96,10 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: self.mech_agent_address: str = self._ensure("mech_agent_address", kwargs, str) # the number of days to sample bets from self.sample_bets_closing_days: int = self._ensure("sample_bets_closing_days", kwargs, int) + if self.sample_bets_closing_days <= 0: + msg = "The number of days to sample bets from must be positive!" + raise ValueError(msg) + # the trading strategy to use for placing bets self.trading_strategy: str = self._ensure("trading_strategy", kwargs, str) # the factor of calculated kelly bet to use for placing bets From 8323302222c289967681983c884dc082cc77afe5 Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:01:29 +0200 Subject: [PATCH 68/79] fix: add missing overrides --- packages/valory/services/trader/service.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index cd89948af..aadb6f6fd 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -162,6 +162,9 @@ type: skill average_block_time: ${ABT:int:5} abt_error_mult: ${ABT_ERROR_MULT:int:5} mech_agent_address: ${MECH_AGENT_ADDRESS:str:0xff82123dfb52ab75c417195c5fdb87630145ae81} + sample_bets_closing_days: ${SAMPLE_BETS_CLOSING_DAYS:int:10} + trading_strategy: ${TRADING_STRATEGY:str:bet_amount_per_conf_threshold} + bet_kelly_fraction: ${BET_KELLY_FRACTION:float:1.0} bet_amount_per_threshold: *id004 bet_threshold: ${BET_THRESHOLD:int:100000000000000000} blacklisting_duration: ${BLACKLISTING_DURATION:int:3600} @@ -230,6 +233,9 @@ type: skill average_block_time: ${ABT:int:5} abt_error_mult: ${ABT_ERROR_MULT:int:5} mech_agent_address: ${MECH_AGENT_ADDRESS:str:0xff82123dfb52ab75c417195c5fdb87630145ae81} + sample_bets_closing_days: ${SAMPLE_BETS_CLOSING_DAYS:int:10} + trading_strategy: ${TRADING_STRATEGY:str:bet_amount_per_conf_threshold} + bet_kelly_fraction: ${BET_KELLY_FRACTION:float:1.0} bet_amount_per_threshold: *id004 bet_threshold: ${BET_THRESHOLD:int:100000000000000000} blacklisting_duration: ${BLACKLISTING_DURATION:int:3600} @@ -298,6 +304,9 @@ type: skill average_block_time: ${ABT:int:5} abt_error_mult: ${ABT_ERROR_MULT:int:5} mech_agent_address: ${MECH_AGENT_ADDRESS:str:0xff82123dfb52ab75c417195c5fdb87630145ae81} + sample_bets_closing_days: ${SAMPLE_BETS_CLOSING_DAYS:int:10} + trading_strategy: ${TRADING_STRATEGY:str:bet_amount_per_conf_threshold} + bet_kelly_fraction: ${BET_KELLY_FRACTION:float:1.0} bet_amount_per_threshold: *id004 bet_threshold: ${BET_THRESHOLD:int:100000000000000000} blacklisting_duration: ${BLACKLISTING_DURATION:int:3600} From 71a9ee91a89c2cc617f57446ae30a117235ba440 Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:03:55 +0200 Subject: [PATCH 69/79] refactor: remove unused `win_probability` --- .../decision_maker_abci/behaviours/decision_receive.py | 1 - packages/valory/skills/decision_maker_abci/payloads.py | 1 - packages/valory/skills/decision_maker_abci/states/base.py | 5 ----- .../skills/decision_maker_abci/states/decision_receive.py | 1 - 4 files changed, 8 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 24327385b..04fb20d52 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -448,7 +448,6 @@ def async_act(self) -> Generator: self.context.agent_address, is_profitable, vote, - win_probability, confidence, bet_amount, ) diff --git a/packages/valory/skills/decision_maker_abci/payloads.py b/packages/valory/skills/decision_maker_abci/payloads.py index 46762668c..7b26bc9ba 100644 --- a/packages/valory/skills/decision_maker_abci/payloads.py +++ b/packages/valory/skills/decision_maker_abci/payloads.py @@ -32,7 +32,6 @@ class DecisionReceivePayload(BaseTxPayload): is_profitable: Optional[bool] vote: Optional[int] - win_probability: Optional[float] confidence: Optional[float] bet_amount: Optional[int] diff --git a/packages/valory/skills/decision_maker_abci/states/base.py b/packages/valory/skills/decision_maker_abci/states/base.py index 4b468ec11..2b1f44b44 100644 --- a/packages/valory/skills/decision_maker_abci/states/base.py +++ b/packages/valory/skills/decision_maker_abci/states/base.py @@ -119,11 +119,6 @@ def vote(self) -> Optional[int]: """Get the bet's vote index.""" vote = self.db.get_strict("vote") return int(vote) if vote is not None else None - - @property - def win_probability(self) -> float: - """Get the vote's win probability.""" - return float(self.db.get_strict("win_probability")) @property def confidence(self) -> float: diff --git a/packages/valory/skills/decision_maker_abci/states/decision_receive.py b/packages/valory/skills/decision_maker_abci/states/decision_receive.py index 3d9f64361..a45b9ecd2 100644 --- a/packages/valory/skills/decision_maker_abci/states/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/states/decision_receive.py @@ -44,7 +44,6 @@ class DecisionReceiveRound(CollectSameUntilThresholdRound): selection_key = ( get_name(SynchronizedData.is_profitable), get_name(SynchronizedData.vote), - get_name(SynchronizedData.win_probability), get_name(SynchronizedData.confidence), get_name(SynchronizedData.bet_amount), ) From adc3c7ceb3278ba386a9e9970b82fba4b35ccdc3 Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:06:39 +0200 Subject: [PATCH 70/79] refactor: guard clauses --- .../decision_maker_abci/behaviours/base.py | 81 ++++++++++--------- 1 file changed, 41 insertions(+), 40 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index f8b1fdaf6..0c9101f76 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -251,53 +251,54 @@ def get_bet_amount( bet_fee: int, ) -> int: """Get the bet amount given a specified trading strategy.""" - + if strategy == "bet_amount_per_conf_threshold": self.context.logger.info(f"Used trading strategy: Bet amount per confidence threshold") threshold = round(confidence, 1) bet_amount = self.params.bet_amount_per_threshold[threshold] return bet_amount - - elif strategy == "kelly_criterion": - self.context.logger.info(f"Used trading strategy: Kelly Criterion") - bankroll = self.token_balance + self.wallet_balance # bankroll: the max amount of DAI available to trade - floor_balance = 500000000000000000 - bankroll_adj = bankroll - floor_balance # keep 0.5 xDAI in the bankroll - self.context.logger.info(f"Adjusted bankroll: {bankroll_adj} DAI") - if bankroll_adj <= 0: - self.context.logger.info( - f"Bankroll is less than {floor_balance}: {bankroll_adj}. Set bet amount to 0." - f"Top up safe with DAI or wait for redeeming." - ) - return 0 - fee_fraction = 1 - self.wei_to_native(bet_fee) - self.context.logger.info(f"Fee fraction: {fee_fraction}") - kelly_bet_amount = self._calculate_kelly_bet_amount( - selected_type_tokens_in_pool, - other_tokens_in_pool, - win_probability, - confidence, - bankroll_adj, - fee_fraction, - ) - - if kelly_bet_amount == None: - return 0 - if kelly_bet_amount < 0: - self.context.logger.info( - f"Negative value for kelly bet amount: {kelly_bet_amount}\n" - "Set bet amount to 0." - ) - return 0 - else: - self.context.logger.info(f"Kelly bet amount xDAI: {kelly_bet_amount/(10**18)}") - self.context.logger.info(f"Bet kelly fraction: {self.params.bet_kelly_fraction}") - adj_kelly_bet_amount = int(kelly_bet_amount * self.params.bet_kelly_fraction) - self.context.logger.info(f"Adjusted Kelly bet: {adj_kelly_bet_amount/(10**18)} xDAI") - return adj_kelly_bet_amount - else: + + if strategy != "kelly_criterion": raise ValueError(f"Invalid trading strategy: {strategy}") + self.context.logger.info(f"Used trading strategy: Kelly Criterion") + # bankroll: the max amount of DAI available to trade + bankroll = self.token_balance + self.wallet_balance + # keep `floor_balance` xDAI in the bankroll + floor_balance = 500000000000000000 + bankroll_adj = bankroll - floor_balance + self.context.logger.info(f"Adjusted bankroll: {bankroll_adj} DAI") + if bankroll_adj <= 0: + self.context.logger.info( + f"Bankroll ({bankroll_adj}) is less than the floor balance ({floor_balance}). " + "Set bet amount to 0." + "Top up safe with DAI or wait for redeeming." + ) + return 0 + + fee_fraction = 1 - self.wei_to_native(bet_fee) + self.context.logger.info(f"Fee fraction: {fee_fraction}") + kelly_bet_amount = self._calculate_kelly_bet_amount( + selected_type_tokens_in_pool, + other_tokens_in_pool, + win_probability, + confidence, + bankroll_adj, + fee_fraction, + ) + if kelly_bet_amount < 0: + self.context.logger.info( + f"Invalid value for kelly bet amount: {kelly_bet_amount}\n" + "Set bet amount to 0." + ) + return 0 + + self.context.logger.info(f"Kelly bet amount: {self.wei_to_native(kelly_bet_amount)} xDAI") + self.context.logger.info(f"Bet kelly fraction: {self.params.bet_kelly_fraction}") + adj_kelly_bet_amount = int(kelly_bet_amount * self.params.bet_kelly_fraction) + self.context.logger.info(f"Adjusted Kelly bet amount: {self.wei_to_native(adj_kelly_bet_amount)} xDAI") + return adj_kelly_bet_amount + def default_error( self, contract_id: str, contract_callable: str, response_msg: ContractApiMessage ) -> None: From 148a2321d3d35d19899e0cec70ca5de9d728473b Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:07:01 +0200 Subject: [PATCH 71/79] fix: kelly return values --- packages/valory/skills/decision_maker_abci/behaviours/base.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index 0c9101f76..dea42e282 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -218,7 +218,7 @@ def _calculate_kelly_bet_amount(self, x, y, p, c, b, f) -> int: f"Pool token amounts: {x}, {y}" f"Fee, fee fraction f: {1-f}, {f}" ) - return None + return 0 kelly_bet_amount = (-4*x**2*y + b*y**2*p*c*f + 2*b*x*y*p*c*f + b*x**2*p*c*f - 2*b*y**2*f - 2*b*x*y*f + ((4*x**2*y - b*y**2*p*c*f - 2*b*x*y*p*c*f - b*x**2*p*c*f + 2*b*y**2*f + 2*b*x*y*f)**2 - (4*(x**2*f - y**2*f) * (-4*b*x*y**2*p*c - 4*b*x**2*y*p*c + 4*b*x*y**2)))**(1/2))/(2*(x**2*f - y**2*f)) return int(kelly_bet_amount) @@ -231,7 +231,7 @@ def get_max_bet_amount(self, a, x, y, f) -> int: f"Pool token amounts: {x}, {y}\n" f"Fee, fee fraction f: {1-f}, {f}" ) - return None + return 0 else: pre_root = -2*x**2 + a*x - 2*x*y sqrt = 4*x**4 + 8*x**3*y + a**2*x**2 + 4*x**2*y**2 + 2*a**2*x*y + a**2*y**2 From 94bcf94f351f5e5faa636b9b1afd90feaed5c2c0 Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:07:55 +0200 Subject: [PATCH 72/79] refactor: remove unused `bankroll` --- packages/valory/skills/decision_maker_abci/behaviours/base.py | 1 - .../skills/decision_maker_abci/behaviours/decision_receive.py | 1 - 2 files changed, 2 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index dea42e282..c5c8c2681 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -242,7 +242,6 @@ def get_max_bet_amount(self, a, x, y, f) -> int: def get_bet_amount( self, - bankroll: int, strategy: str, win_probability: float, confidence: float, diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 04fb20d52..82e8766b1 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -381,7 +381,6 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - # Testing and printing kelly bet amount bet_amount = self.get_bet_amount( - bankroll, self.params.trading_strategy, win_probability, confidence, From 3d832b3a32a7c7101a60328fa4938bf5c0f36c6c Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:09:09 +0200 Subject: [PATCH 73/79] refactor: do not return `None` --- packages/valory/skills/decision_maker_abci/models.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 8f92c87e0..3dc82d4d9 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -235,9 +235,7 @@ def vote(self) -> Optional[int]: @property def win_probability(self) -> Optional[float]: """Return the probability estimation for winning with vote.""" - if self.p_no != self.p_yes: - return max(self.p_no, self.p_yes) - return None + return max(self.p_no, self.p_yes) @dataclass(init=False) From 8d92f988bfcca881203cbf90ea4983b102ea9f1a Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:10:26 +0200 Subject: [PATCH 74/79] style: remove unnecessary code --- .../behaviours/decision_receive.py | 85 ++----------------- 1 file changed, 5 insertions(+), 80 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 82e8766b1..4a1c54241 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -21,7 +21,6 @@ from math import prod from typing import Any, Generator, Optional, Tuple, Union -from packages.valory.contracts.erc20.contract import ERC20 from packages.valory.contracts.mech.contract import Mech from packages.valory.protocols.contract_api import ContractApiMessage @@ -32,7 +31,6 @@ WaitableConditionType, remove_fraction_wei ) -from packages.valory.skills.decision_maker_abci.behaviours.bet_placement import WXDAI from packages.valory.skills.decision_maker_abci.models import ( MechInteractionResponse, MechResponseSpecs, @@ -85,26 +83,6 @@ def request_id(self, request_id: Union[str, int]) -> None: msg = f"Request id {request_id} is not a valid integer!" self.context.logger.error(msg) - @property - def collateral_token(self) -> str: - """Get the contract address of the token that the market maker supports.""" - return self.synchronized_data.sampled_bet.collateralToken - - @property - def is_wxdai(self) -> bool: - """Get whether the collateral address is wxDAI.""" - return self.collateral_token.lower() == WXDAI.lower() - - @property - def mech_price(self) -> int: - """Get the mech price.""" - return self._mech_price - - @mech_price.setter - def mech_price(self, price: int) -> None: - """Set the mech price.""" - self._mech_price = price - @property def response_hex(self) -> str: """Get the hash of the response data.""" @@ -267,8 +245,6 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] # calculate the pool's k (x*y=k) token_amounts = bet.outcomeTokenAmounts self.context.logger.info(f"Token amounts: {[x for x in token_amounts]}") - if token_amounts is None: - return 0, 0 k = prod(token_amounts) self.context.logger.info(f"k: {k}") @@ -324,74 +300,23 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] return num_shares, available_shares - def _get_mech_price(self) -> WaitableConditionType: - """Get the price of the mech request.""" - result = yield from self._mech_contract_interact( - "get_price", "price", get_name(DecisionReceiveBehaviour.mech_price) - ) - return result - - def _collateral_amount_info(self, amount: int) -> str: - """Get a description of the collateral token's amount.""" - return ( - f"{self.wei_to_native(amount)} wxDAI" - if self.is_wxdai - else f"{amount} WEI of the collateral token with address {self.collateral_token}" - ) - - def _check_balance(self) -> WaitableConditionType: - """Check the safe's balance.""" - response_msg = yield from self.get_contract_api_response( - performative=ContractApiMessage.Performative.GET_RAW_TRANSACTION, # type: ignore - contract_address=self.collateral_token, - contract_id=str(ERC20.contract_id), - contract_callable="check_balance", - account=self.synchronized_data.safe_contract_address, - ) - if response_msg.performative != ContractApiMessage.Performative.RAW_TRANSACTION: - self.context.logger.error( - f"Could not calculate the balance of the safe: {response_msg}" - ) - return False - - token = response_msg.raw_transaction.body.get("token", None) - wallet = response_msg.raw_transaction.body.get("wallet", None) - if token is None or wallet is None: - self.context.logger.error( - f"Something went wrong while trying to get the balance of the safe: {response_msg}" - ) - return False - - self.token_balance = int(token) - self.wallet_balance = int(wallet) - - native = self.wei_to_native(self.wallet_balance) - collateral = self._collateral_amount_info(self.token_balance) - self.context.logger.info(f"The safe has {native} xDAI and {collateral}.") - return True - def _is_profitable(self, vote: int, win_probability: float, confidence: float) -> Tuple[bool, int]: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet - self.context.logger.info(f"Bet: {bet}") - yield from self._check_balance() - bankroll = self.wallet_balance + self.token_balance - self.context.logger.info(f"Bankroll wei: {bankroll}") - selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee = self._get_bet_sample_info(bet, vote) - - # Testing and printing kelly bet amount + selected_type_tokens_in_pool, other_tokens_in_pool = self._get_bet_sample_info(bet, vote) + bet_amount = self.get_bet_amount( self.params.trading_strategy, win_probability, confidence, selected_type_tokens_in_pool, other_tokens_in_pool, - bet_fee, + bet.fee, ) self.context.logger.info(f"Bet amount: {bet_amount}") self.context.logger.info(f"Bet fee: {bet.fee}") - net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet_fee)) + net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet.fee)) self.context.logger.info(f"Net bet amount: {net_bet_amount}") @@ -442,7 +367,7 @@ def async_act(self) -> Generator: is_profitable = None bet_amount = None if vote is not None and confidence is not None and win_probability is not None: - is_profitable, bet_amount = yield from self._is_profitable(vote, win_probability, confidence) + is_profitable, bet_amount = self._is_profitable(vote, win_probability, confidence) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, From 4b1936aeaa257193698467c00a1b360b0b39d1bd Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:12:38 +0200 Subject: [PATCH 75/79] fix: potential net profit calculation and unnecessary code --- .../behaviours/decision_receive.py | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index 4a1c54241..f60fd3cf9 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -338,17 +338,7 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - ) bet_threshold = 0 - yield from self.wait_for_condition_with_sleep(self._get_mech_price) - self.context.logger.info(f"Mech price: {self.mech_price}") - potential_net_profit = num_shares - bet_amount - self.mech_price - bet_threshold - self.context.logger.info(f"Potential net profit: {potential_net_profit}") - is_profitable = potential_net_profit >= 0 and num_shares <= available_shares - self.context.logger.info(f"Is profitable: {is_profitable}") - shares_out = self.wei_to_native(num_shares) - available_in = self.wei_to_native(available_shares) - shares_out_of = f"{shares_out} / {available_in}" - self.context.logger.info(f"Shares out of: {shares_out_of}") - potential_net_profit = num_shares - bet_amount - self.mech_price - bet_threshold + potential_net_profit = num_shares - net_bet_amount - bet_threshold is_profitable = potential_net_profit >= 0 self.context.logger.info( From 53ceb426a766f2bc1d581773dfa746d5786639c4 Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:13:14 +0200 Subject: [PATCH 76/79] fix: `_get_bet_sample_info` --- .../behaviours/decision_receive.py | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index f60fd3cf9..ac61ab145 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -224,19 +224,16 @@ def _get_decision( return None, None, None return self.mech_response.result.vote, self.mech_response.result.win_probability, self.mech_response.result.confidence - - def _get_bet_sample_info(self, bet, vote) -> Tuple[int, int, int]: + @staticmethod + def _get_bet_sample_info(bet: Bet, vote: int) -> Tuple[int, int]: + """Get the bet sample information.""" token_amounts = bet.outcomeTokenAmounts - if token_amounts is None: - return None, None, None - - selected_type_tokens_in_pool = token_amounts.pop(vote) - other_tokens_in_pool = token_amounts.pop() - bet_fee = bet.fee - - return selected_type_tokens_in_pool, other_tokens_in_pool, bet_fee + selected_type_tokens_in_pool = token_amounts[vote] + opposite_vote = vote ^ 1 + other_tokens_in_pool = token_amounts[opposite_vote] + return selected_type_tokens_in_pool, other_tokens_in_pool def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int]: """Calculate the claimed shares. This calculation only works for binary markets.""" From 2116ee25b721610f379eb0ed6bcdc7b85db0aa29 Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:15:34 +0200 Subject: [PATCH 77/79] chore: format code --- .../decision_maker_abci/behaviours/base.py | 86 +++++++++++++++---- .../behaviours/decision_receive.py | 44 +++++++--- .../behaviours/decision_request.py | 4 - .../behaviours/sampling.py | 12 ++- .../skills/decision_maker_abci/models.py | 16 ++-- .../skills/decision_maker_abci/states/base.py | 2 +- pyproject.toml | 2 +- 7 files changed, 118 insertions(+), 48 deletions(-) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/base.py b/packages/valory/skills/decision_maker_abci/behaviours/base.py index c5c8c2681..a6ae73201 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/base.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/base.py @@ -208,36 +208,76 @@ def check_balance(self) -> WaitableConditionType: collateral = self._collateral_amount_info(self.token_balance) self.context.logger.info(f"The safe has {native} xDAI and {collateral}.") return True - - def _calculate_kelly_bet_amount(self, x, y, p, c, b, f) -> int: + + def _calculate_kelly_bet_amount( + self, x: int, y: int, p: float, c: float, b: int, f: float + ) -> int: """Calculate the Kelly bet amount.""" - if b == 0 or x**2*f == y**2*f: + if b == 0 or x**2 * f == y**2 * f: self.context.logger.error( - "Could not calculate Kelly bet amount. Either bankroll is 0 or pool token amount is distributed as x^2*f - y^2*f = 0:\n" + "Could not calculate Kelly bet amount. " + "Either bankroll is 0 or pool token amount is distributed as x^2*f - y^2*f = 0:\n" f"Bankroll: {b}\n" f"Pool token amounts: {x}, {y}" f"Fee, fee fraction f: {1-f}, {f}" ) return 0 - kelly_bet_amount = (-4*x**2*y + b*y**2*p*c*f + 2*b*x*y*p*c*f + b*x**2*p*c*f - 2*b*y**2*f - 2*b*x*y*f + ((4*x**2*y - b*y**2*p*c*f - 2*b*x*y*p*c*f - b*x**2*p*c*f + 2*b*y**2*f + 2*b*x*y*f)**2 - (4*(x**2*f - y**2*f) * (-4*b*x*y**2*p*c - 4*b*x**2*y*p*c + 4*b*x*y**2)))**(1/2))/(2*(x**2*f - y**2*f)) + kelly_bet_amount = ( + -4 * x**2 * y + + b * y**2 * p * c * f + + 2 * b * x * y * p * c * f + + b * x**2 * p * c * f + - 2 * b * y**2 * f + - 2 * b * x * y * f + + ( + ( + 4 * x**2 * y + - b * y**2 * p * c * f + - 2 * b * x * y * p * c * f + - b * x**2 * p * c * f + + 2 * b * y**2 * f + + 2 * b * x * y * f + ) + ** 2 + - ( + 4 + * (x**2 * f - y**2 * f) + * ( + -4 * b * x * y**2 * p * c + - 4 * b * x**2 * y * p * c + + 4 * b * x * y**2 + ) + ) + ) + ** (1 / 2) + ) / (2 * (x**2 * f - y**2 * f)) return int(kelly_bet_amount) - - def get_max_bet_amount(self, a, x, y, f) -> int: + + def get_max_bet_amount(self, a: int, x: int, y: int, f: float) -> int: """Get max bet amount based on available shares.""" - if x**2*f**2 + 2*x*y*f**2 + y**2*f**2 == 0: + if x**2 * f**2 + 2 * x * y * f**2 + y**2 * f**2 == 0: self.context.logger.error( - "Could not recalculate. Either bankroll is 0 or pool token amount is distributed such as x**2*f**2 + 2*x*y*f**2 + y**2*f**2 == 0:\n" + "Could not recalculate. " + "Either bankroll is 0 or pool token amount is distributed such as " + "x**2*f**2 + 2*x*y*f**2 + y**2*f**2 == 0:\n" f"Available tokens: {a}\n" f"Pool token amounts: {x}, {y}\n" f"Fee, fee fraction f: {1-f}, {f}" ) return 0 else: - pre_root = -2*x**2 + a*x - 2*x*y - sqrt = 4*x**4 + 8*x**3*y + a**2*x**2 + 4*x**2*y**2 + 2*a**2*x*y + a**2*y**2 - numerator = y*(pre_root + (sqrt)**0.5 + a*y) - denominator = f*(x**2 + 2*x*y + y**2) - new_bet_amount = numerator/denominator + pre_root = -2 * x**2 + a * x - 2 * x * y + sqrt = ( + 4 * x**4 + + 8 * x**3 * y + + a**2 * x**2 + + 4 * x**2 * y**2 + + 2 * a**2 * x * y + + a**2 * y**2 + ) + numerator = y * (pre_root + sqrt**0.5 + a * y) + denominator = f * (x**2 + 2 * x * y + y**2) + new_bet_amount = numerator / denominator return int(new_bet_amount) def get_bet_amount( @@ -252,7 +292,9 @@ def get_bet_amount( """Get the bet amount given a specified trading strategy.""" if strategy == "bet_amount_per_conf_threshold": - self.context.logger.info(f"Used trading strategy: Bet amount per confidence threshold") + self.context.logger.info( + "Used trading strategy: Bet amount per confidence threshold" + ) threshold = round(confidence, 1) bet_amount = self.params.bet_amount_per_threshold[threshold] return bet_amount @@ -260,7 +302,7 @@ def get_bet_amount( if strategy != "kelly_criterion": raise ValueError(f"Invalid trading strategy: {strategy}") - self.context.logger.info(f"Used trading strategy: Kelly Criterion") + self.context.logger.info("Used trading strategy: Kelly Criterion") # bankroll: the max amount of DAI available to trade bankroll = self.token_balance + self.wallet_balance # keep `floor_balance` xDAI in the bankroll @@ -292,10 +334,16 @@ def get_bet_amount( ) return 0 - self.context.logger.info(f"Kelly bet amount: {self.wei_to_native(kelly_bet_amount)} xDAI") - self.context.logger.info(f"Bet kelly fraction: {self.params.bet_kelly_fraction}") + self.context.logger.info( + f"Kelly bet amount: {self.wei_to_native(kelly_bet_amount)} xDAI" + ) + self.context.logger.info( + f"Bet kelly fraction: {self.params.bet_kelly_fraction}" + ) adj_kelly_bet_amount = int(kelly_bet_amount * self.params.bet_kelly_fraction) - self.context.logger.info(f"Adjusted Kelly bet amount: {self.wei_to_native(adj_kelly_bet_amount)} xDAI") + self.context.logger.info( + f"Adjusted Kelly bet amount: {self.wei_to_native(adj_kelly_bet_amount)} xDAI" + ) return adj_kelly_bet_amount def default_error( diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py index ac61ab145..19dc0b9ad 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_receive.py @@ -29,7 +29,7 @@ CID_PREFIX, DecisionMakerBaseBehaviour, WaitableConditionType, - remove_fraction_wei + remove_fraction_wei, ) from packages.valory.skills.decision_maker_abci.models import ( MechInteractionResponse, @@ -39,7 +39,7 @@ from packages.valory.skills.decision_maker_abci.states.decision_receive import ( DecisionReceiveRound, ) -from packages.valory.skills.market_manager_abci.bets import BINARY_N_SLOTS +from packages.valory.skills.market_manager_abci.bets import BINARY_N_SLOTS, Bet ZERO_ADDRESS = "0x0000000000000000000000000000000000000000" @@ -223,7 +223,11 @@ def _get_decision( ) return None, None, None - return self.mech_response.result.vote, self.mech_response.result.win_probability, self.mech_response.result.confidence + return ( + self.mech_response.result.vote, + self.mech_response.result.win_probability, + self.mech_response.result.confidence, + ) @staticmethod def _get_bet_sample_info(bet: Bet, vote: int) -> Tuple[int, int]: @@ -269,7 +273,9 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] # get the number of tokens in the pool for the answer that the service has selected selected_type_tokens_in_pool = token_amounts.pop(vote) - self.context.logger.info(f"Selected type tokens in pool: {selected_type_tokens_in_pool}") + self.context.logger.info( + f"Selected type tokens in pool: {selected_type_tokens_in_pool}" + ) # get the number of tokens in the pool for the opposite answer other_tokens_in_pool = token_amounts.pop() @@ -279,8 +285,10 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] # preserving the balance of the pool # here we calculate the number of shares that we get after trading the tokens for the opposite answer tokens_remaining_in_pool = int(k / (other_tokens_in_pool + other_shares)) - self.context.logger.info(f"Tokens remaining in pool: {tokens_remaining_in_pool}") - + self.context.logger.info( + f"Tokens remaining in pool: {tokens_remaining_in_pool}" + ) + swapped_shares = selected_type_tokens_in_pool - tokens_remaining_in_pool self.context.logger.info(f"Swapped shares: {swapped_shares}") @@ -297,10 +305,14 @@ def _calc_binary_shares(self, net_bet_amount: int, vote: int) -> Tuple[int, int] return num_shares, available_shares - def _is_profitable(self, vote: int, win_probability: float, confidence: float) -> Tuple[bool, int]: + def _is_profitable( + self, vote: int, win_probability: float, confidence: float + ) -> Tuple[bool, int]: """Whether the decision is profitable or not.""" bet = self.synchronized_data.sampled_bet - selected_type_tokens_in_pool, other_tokens_in_pool = self._get_bet_sample_info(bet, vote) + selected_type_tokens_in_pool, other_tokens_in_pool = self._get_bet_sample_info( + bet, vote + ) bet_amount = self.get_bet_amount( self.params.trading_strategy, @@ -310,15 +322,14 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - other_tokens_in_pool, bet.fee, ) - + self.context.logger.info(f"Bet amount: {bet_amount}") self.context.logger.info(f"Bet fee: {bet.fee}") net_bet_amount = remove_fraction_wei(bet_amount, self.wei_to_native(bet.fee)) self.context.logger.info(f"Net bet amount: {net_bet_amount}") - num_shares, available_shares = self._calc_binary_shares(net_bet_amount, vote) - + self.context.logger.info(f"Adjusted available shares: {available_shares}") if num_shares > available_shares * SLIPPAGE: self.context.logger.warning( @@ -327,7 +338,6 @@ def _is_profitable(self, vote: int, win_probability: float, confidence: float) - "and therefore the potential net profit, will be lower than if the pool had higher liquidity!" ) bet_threshold = self.params.bet_threshold - self.context.logger.info(f"Bet threshold: {bet_threshold}") if bet_threshold <= 0: self.context.logger.warning( f"A non-positive bet threshold was given ({bet_threshold}). The threshold will be disabled, " @@ -353,8 +363,14 @@ def async_act(self) -> Generator: vote, win_probability, confidence = yield from self._get_decision() is_profitable = None bet_amount = None - if vote is not None and confidence is not None and win_probability is not None: - is_profitable, bet_amount = self._is_profitable(vote, win_probability, confidence) + if ( + vote is not None + and confidence is not None + and win_probability is not None + ): + is_profitable, bet_amount = self._is_profitable( + vote, win_probability, confidence + ) payload = DecisionReceivePayload( self.context.agent_address, is_profitable, diff --git a/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py b/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py index 7a77704bf..4c3b367da 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/decision_request.py @@ -302,9 +302,5 @@ def async_act(self) -> Generator: mech_tx_hex = yield from self._prepare_safe_tx() price = self.price agent = self.context.agent_address - # log the payload - self.context.logger.info( - f"Sending request to mech with payload: {agent, tx_submitter, mech_tx_hex, price}" - ) payload = RequestPayload(agent, tx_submitter, mech_tx_hex, price) yield from self.finish_behaviour(payload) diff --git a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py index cadd461e9..a56cdf3a8 100644 --- a/packages/valory/skills/decision_maker_abci/behaviours/sampling.py +++ b/packages/valory/skills/decision_maker_abci/behaviours/sampling.py @@ -19,8 +19,6 @@ """This module contains the behaviour for sampling a bet.""" -import time - from typing import Generator, Iterator, List, Optional, Tuple from packages.valory.skills.decision_maker_abci.behaviours.base import ( @@ -51,7 +49,15 @@ def available_bets(self) -> Iterator[Bet]: # Note: the openingTimestamp is misleading as it is the closing timestamp of the bet if self.params.trading_strategy == "kelly_criterion": # get only bets that close in the next 48 hours - bets = [bet for bet in bets if bet.openingTimestamp <= (self.synced_timestamp + self.params.sample_bets_closing_days * UNIX_DAY)] + bets = [ + bet + for bet in bets + if bet.openingTimestamp + <= ( + self.synced_timestamp + + self.params.sample_bets_closing_days * UNIX_DAY + ) + ] return filter(lambda bet: bet.status == BetStatus.UNPROCESSED, bets) diff --git a/packages/valory/skills/decision_maker_abci/models.py b/packages/valory/skills/decision_maker_abci/models.py index 3dc82d4d9..92a509a08 100644 --- a/packages/valory/skills/decision_maker_abci/models.py +++ b/packages/valory/skills/decision_maker_abci/models.py @@ -35,7 +35,6 @@ from packages.valory.skills.abstract_round_abci.models import ( BenchmarkTool as BaseBenchmarkTool, ) - from packages.valory.skills.abstract_round_abci.models import Requests as BaseRequests from packages.valory.skills.abstract_round_abci.models import ( SharedState as BaseSharedState, @@ -43,6 +42,7 @@ from packages.valory.skills.decision_maker_abci.rounds import DecisionMakerAbciApp from packages.valory.skills.market_manager_abci.models import MarketManagerParams + RE_CONTENT_IN_BRACKETS = r"\{([^}]*)\}" REQUIRED_BET_TEMPLATE_KEYS = {"yes", "no", "question"} @@ -86,7 +86,7 @@ def check_prompt_template(bet_prompt_template: PromptTemplate) -> None: f"For example, to parametrize {example_key!r} you may use " f"'{delimiter}{{{example_key}}}'" ) - + class DecisionMakerParams(MarketManagerParams): """Decision maker's parameters.""" @@ -95,7 +95,9 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: """Initialize the parameters' object.""" self.mech_agent_address: str = self._ensure("mech_agent_address", kwargs, str) # the number of days to sample bets from - self.sample_bets_closing_days: int = self._ensure("sample_bets_closing_days", kwargs, int) + self.sample_bets_closing_days: int = self._ensure( + "sample_bets_closing_days", kwargs, int + ) if self.sample_bets_closing_days <= 0: msg = "The number of days to sample bets from must be positive!" raise ValueError(msg) @@ -103,7 +105,9 @@ def __init__(self, *args: Any, **kwargs: Any) -> None: # the trading strategy to use for placing bets self.trading_strategy: str = self._ensure("trading_strategy", kwargs, str) # the factor of calculated kelly bet to use for placing bets - self.bet_kelly_fraction: float = self._ensure("bet_kelly_fraction", kwargs, float) + self.bet_kelly_fraction: float = self._ensure( + "bet_kelly_fraction", kwargs, float + ) # this is a mapping from the confidence of a bet's choice to the amount we are willing to bet self.bet_amount_per_threshold: Dict[float, int] = self._ensure( "bet_amount_per_threshold", kwargs, Dict[float, int] @@ -167,7 +171,7 @@ def slippage(self, slippage: float) -> None: f"The configured slippage {slippage!r} is not in the range [0, 1]." ) self._slippage = slippage - + def get_policy_store_path(self, kwargs: Dict) -> Path: """Get the path of the policy store.""" path = self._ensure("policy_store_path", kwargs, str) @@ -231,7 +235,7 @@ def vote(self) -> Optional[int]: if self.p_no != self.p_yes: return int(self.p_no > self.p_yes) return None - + @property def win_probability(self) -> Optional[float]: """Return the probability estimation for winning with vote.""" diff --git a/packages/valory/skills/decision_maker_abci/states/base.py b/packages/valory/skills/decision_maker_abci/states/base.py index 2b1f44b44..b57ddfe31 100644 --- a/packages/valory/skills/decision_maker_abci/states/base.py +++ b/packages/valory/skills/decision_maker_abci/states/base.py @@ -124,7 +124,7 @@ def vote(self) -> Optional[int]: def confidence(self) -> float: """Get the vote's confidence.""" return float(self.db.get_strict("confidence")) - + @property def bet_amount(self) -> int: """Get the calculated bet amount.""" diff --git a/pyproject.toml b/pyproject.toml index 8a8801099..fe3a2b914 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,4 +53,4 @@ jsonschema = "<=4.19.0,>=4.16.0" [tool.poetry.group.dev.dependencies.tomte] version = "==0.2.12" -extras = [ "cli", "tests",] \ No newline at end of file +extras = [ "cli", "tests",] From f67772286325f7b93a24af54c51cf59d9e6420e6 Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 17:49:37 +0200 Subject: [PATCH 78/79] fix: add missing contract This error was present on `main` and fixed here after merging. --- packages/valory/agents/trader/aea-config.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 99d247c06..1ed39a043 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -26,6 +26,7 @@ contracts: - valory/realitio:0.1.0:bafybeid6kh4tiqswpeufkr7eowmq7seoyhkssnedgzw6pe4h7wswui6dlm - valory/realitio_proxy:0.1.0:bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4 - valory/agent_registry:0.1.0:bafybeifwdtwxdc2jdlhzdyxctqdmoz6zroxf5o4nhuok5l4luvnofqavty +- valory/service_staking_token:0.1.0:bafybeibifxmoeaiptovouispl5jdgm4lduzcfgsx723zlw45cfpllecuwy protocols: - open_aea/signing:1.0.0:bafybeie7xyems76v5b4wc2lmaidcujizpxfzjnnwdeokmhje53g7ym25ii - valory/abci:0.1.0:bafybeihmzlmmb4pdo3zkhg6ehuyaa4lhw7bfpclln2o2z7v3o6fcep26iu From f60751f6b110c66207bba54697cbf9ba7d0302dc Mon Sep 17 00:00:00 2001 From: Adamantios Date: Wed, 1 Nov 2023 18:53:14 +0200 Subject: [PATCH 79/79] chore: run generators --- packages/packages.json | 10 +++++----- packages/valory/agents/trader/aea-config.yaml | 6 +++--- packages/valory/services/trader/service.yaml | 2 +- .../skills/decision_maker_abci/skill.yaml | 20 +++++++++---------- packages/valory/skills/trader_abci/skill.yaml | 6 +++--- .../tx_settlement_multiplexer_abci/skill.yaml | 2 +- 6 files changed, 23 insertions(+), 23 deletions(-) diff --git a/packages/packages.json b/packages/packages.json index 8d1bbebc3..406b9aa36 100644 --- a/packages/packages.json +++ b/packages/packages.json @@ -1,13 +1,13 @@ { "dev": { "skill/valory/market_manager_abci/0.1.0": "bafybeidropskas24c4lcekzdbwoflhnzaglmeqxvpyuoa7cf7q2rf2yex4", - "skill/valory/decision_maker_abci/0.1.0": "bafybeid6ysjyi67q62yvf5g2v5jqlqbf25uylqiklwoeax7fnulfrrj65u", - "skill/valory/trader_abci/0.1.0": "bafybeiextdo2zomsnmpmo3dxtm7s4tjku6g46c2znpbtaqjauipksaxg6y", + "skill/valory/decision_maker_abci/0.1.0": "bafybeie4k3s546hx4p5g3dtn75hlrysyh3ieslszexctwal4odmarx34fm", + "skill/valory/trader_abci/0.1.0": "bafybeigpzcq345ed5acmehnp7uj4nwv22xtl35mbp4x2howw7sps3iwi2e", "contract/valory/market_maker/0.1.0": "bafybeif4mm2s3gxtvp227yypkcnna5ftec7vajcftvtbdmqddh7nprah5m", - "agent/valory/trader/0.1.0": "bafybeib5qyuv6m6hud6ibym3rzuastkdvnfe2ijy2ruscocdigu24u7iv4", - "service/valory/trader/0.1.0": "bafybeic4g5lxp2ia2xbj45dmsfrinfgziwixj2l2kumzpk2ujuus66qlpy", + "agent/valory/trader/0.1.0": "bafybeicda6weararan4qyidf7dd4vxwesektyrjmu6mhvraew6q2mrezhu", + "service/valory/trader/0.1.0": "bafybeigwj6jajdge5qcjz6mimoylkv6zhbso45w4t6zo2m7olwkbb5puyq", "contract/valory/erc20/0.1.0": "bafybeieqj7dea4tcv6z2yqkgtmhd23vbiycsr5trhwxdvlbwulpl6vhmam", - "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeidqyfnc4nvqraem4fpnkejqd77iwfcixg6fh3hc5ulhvstwcbdhbm", + "skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeiet3hqejz7rtutuzmvyl7wqwqqi2buqagryawav4yeuem45ohpr2e", "contract/valory/mech/0.1.0": "bafybeihvc6btuk3nvernzcx4qpezvuhiw2wwnagqj5nkeljvszghv7mq64", "contract/valory/realitio/0.1.0": "bafybeid6kh4tiqswpeufkr7eowmq7seoyhkssnedgzw6pe4h7wswui6dlm", "contract/valory/realitio_proxy/0.1.0": "bafybeidx37xzjjmapwacedgzhum6grfzhp5vhouz4zu3pvpgdy5pgb2fr4", diff --git a/packages/valory/agents/trader/aea-config.yaml b/packages/valory/agents/trader/aea-config.yaml index 1ed39a043..1c6496ec0 100644 --- a/packages/valory/agents/trader/aea-config.yaml +++ b/packages/valory/agents/trader/aea-config.yaml @@ -43,10 +43,10 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeidqyfnc4nvqraem4fpnkejqd77iwfcixg6fh3hc5ulhvstwcbdhbm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiet3hqejz7rtutuzmvyl7wqwqqi2buqagryawav4yeuem45ohpr2e - valory/market_manager_abci:0.1.0:bafybeidropskas24c4lcekzdbwoflhnzaglmeqxvpyuoa7cf7q2rf2yex4 -- valory/decision_maker_abci:0.1.0:bafybeid6ysjyi67q62yvf5g2v5jqlqbf25uylqiklwoeax7fnulfrrj65u -- valory/trader_abci:0.1.0:bafybeiextdo2zomsnmpmo3dxtm7s4tjku6g46c2znpbtaqjauipksaxg6y +- valory/decision_maker_abci:0.1.0:bafybeie4k3s546hx4p5g3dtn75hlrysyh3ieslszexctwal4odmarx34fm +- valory/trader_abci:0.1.0:bafybeigpzcq345ed5acmehnp7uj4nwv22xtl35mbp4x2howw7sps3iwi2e default_ledger: ethereum required_ledgers: - ethereum diff --git a/packages/valory/services/trader/service.yaml b/packages/valory/services/trader/service.yaml index 7583c040b..086777c13 100644 --- a/packages/valory/services/trader/service.yaml +++ b/packages/valory/services/trader/service.yaml @@ -7,7 +7,7 @@ license: Apache-2.0 fingerprint: README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq fingerprint_ignore_patterns: [] -agent: valory/trader:0.1.0:bafybeib5qyuv6m6hud6ibym3rzuastkdvnfe2ijy2ruscocdigu24u7iv4 +agent: valory/trader:0.1.0:bafybeicda6weararan4qyidf7dd4vxwesektyrjmu6mhvraew6q2mrezhu number_of_agents: 4 deployment: {} --- diff --git a/packages/valory/skills/decision_maker_abci/skill.yaml b/packages/valory/skills/decision_maker_abci/skill.yaml index 1fca2f063..4a77eef31 100644 --- a/packages/valory/skills/decision_maker_abci/skill.yaml +++ b/packages/valory/skills/decision_maker_abci/skill.yaml @@ -12,29 +12,29 @@ fingerprint: README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i __init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky - behaviours/base.py: bafybeibt4fn3l52xwfat2vqn5nae2vm3ahjrddahjukkqxg33dcaumwcei - behaviours/bet_placement.py: bafybeiauzdizqawjgzc3ugx33vuh726e25juhacqdr7c6uztpn6tra5dva + behaviours/base.py: bafybeige65wi6lqzq26sbl5n6y7haqkgjltlwb65k6sohzv77pp3rmhsjm + behaviours/bet_placement.py: bafybeigtz4uimsqjjwq4r5p3a5v6niqdtqezbuf2ghy6o7syhsh4k5gjfa behaviours/blacklisting.py: bafybeicl6b4hcmqmekta2mcuhkkydnzk7jmic6k44e6ns3u2ibad3awzvu - behaviours/decision_receive.py: bafybeigketncslwg5y3uidso4kmviy4cb5xasjf4fyfj6lfcenln6pnqdm - behaviours/decision_request.py: bafybeia7ko3nryzcnsihh4ab7vnrgtyjm3w7tvmkxhqzr2a65hcfo5fzye + behaviours/decision_receive.py: bafybeidw2etz4k5zbmqp6qfg2ba5eimgpjl3w5bv7fz2xd6ah6vrns3g4i + behaviours/decision_request.py: bafybeibrk6jxalkgspinmjboqr3o6d6hl6mxtlkif74a5p32vp2zzhhzua behaviours/handle_failed_tx.py: bafybeidxpc6u575ymct5tdwutvzov6zqfdoio5irgldn3fw7q3lg36mmxm - behaviours/reedem.py: bafybeic7i5tfgsl2rwbfxxpukqe6nmnpk3o6koyw2rn3xv5t5lbnubmnrq + behaviours/reedem.py: bafybeiewhlzhvrjtllym3jyk5fzci4r67fgutgzgrsmv4t3uvrejm7aaki behaviours/round_behaviour.py: bafybeig4tdktyu6hapoqymnxh2bgpds547st6a44heue657wkctwe4gjvm - behaviours/sampling.py: bafybeibzx5euk6u2lazji6cktbebieoov3oyziksnhuy6e72xywlrrsj4u + behaviours/sampling.py: bafybeieu4obvwhsquvgmdi7moo4eajdh376oqlzb4zu3wsznovg2o5x2de behaviours/tool_selection.py: bafybeigfr2frkljrxyfxs5p3j42equzehgaqtkyuxk6eiujyudr6ajqakm dialogues.py: bafybeigpwuzku3we7axmxeamg7vn656maww6emuztau5pg3ebsoquyfdqm fsm_specification.yaml: bafybeifnob3ceim2mj7lqagtnpwqjqqxs5eg3oiwc73gwm6x5i2dvvlcya handlers.py: bafybeihj33szgrcxnpd73s4nvluyxwwsvhjum2cuq3ilhhe6vfola3k7vy - models.py: bafybeidd73nai777thcqsdofgt57hhinhxbkr6zeiypxaxa4oqjpgfyulu - payloads.py: bafybeiawx6ix2ljvf545fe3wocdoh7frds6gjvzgv62b3w6huaolgvywqi + models.py: bafybeibcdzwl33kge725ivlz4emclzj2tu7cvbzrnwa3v7tuux37lwt5vm + payloads.py: bafybeifhq6stu4vp2ef4qvihxgpos3yc2zcuaja2safwt7efdidoejgvqa policy.py: bafybeidpmx4ek3qze63zpuwixyf6t7bdv62ewgkzt3ljrzadiwdw64cueq redeem_info.py: bafybeibddfxwp3577c3dl2utaowwltquu5fg6crezpumoebw563wxpbfrm rounds.py: bafybeihopxmhzrpipc6r5x2vqf2tcixzuf5xdpqfsr7gr3n756n3ssft5q states/__init__.py: bafybeid23llnyp6j257dluxmrnztugo5llsrog7kua53hllyktz4dqhqoy - states/base.py: bafybeifgt4x5os25iq6ccaia5ka2okehfxv33oizgy3zjrnudgi46vis7q + states/base.py: bafybeibyymqlq3srv5uqmitscdjjv6ijalwlzym5f7ab74teqweeywgv7y states/bet_placement.py: bafybeibalhxhp2c4oljmiwqi6ds3g36fgtabmf42mb5sgq6z22znrcbhda states/blacklisting.py: bafybeifruvxwwltndwazkzzbpc5nnnad3z5t5ofy6d3i7nssljbxl6gvxu - states/decision_receive.py: bafybeiasj5uaixpqau6hcxpw5vyevqrufd3ubkwvgbgy37gcwfom3bl3iq + states/decision_receive.py: bafybeib3roo27nccj4eylaqwwzztzzzwsi6px5atjrch5wbqmpln2kyy6y states/decision_request.py: bafybeic7otc3hjb753svbmur3yyk6szahc25yii3x4w4vcnpfz6jwvacuu states/final_states.py: bafybeidiwhuyd5zm2cq7vhv2owcrxdpm7fnvn3db6p6tql4jz5hgpalflu states/handle_failed_tx.py: bafybeihewm2vernvhktuorljdupjqcg2p5vs6wvsira2d62wkoyo5xlzjm diff --git a/packages/valory/skills/trader_abci/skill.yaml b/packages/valory/skills/trader_abci/skill.yaml index bea06a28c..8930c2403 100644 --- a/packages/valory/skills/trader_abci/skill.yaml +++ b/packages/valory/skills/trader_abci/skill.yaml @@ -24,9 +24,9 @@ skills: - valory/reset_pause_abci:0.1.0:bafybeicpxn2khtaesuf4cq6ypwdmdmonlqroj2q2i6cxvpizc2y4cw66pe - valory/transaction_settlement_abci:0.1.0:bafybeia6cdxdlqrcwk2maw25fo7dafzd2p3rs7syropvufophk2pitzbwy - valory/termination_abci:0.1.0:bafybeieqm46zuccaagnko3qlw6p3nvoohdrfgvpmw467r5lyil2dqrzjsy -- valory/market_manager_abci:0.1.0:bafybeigmy3g2klkzdhttti2ouxf575ua5y7ajmh4a3yfpukeukqxjky47m -- valory/decision_maker_abci:0.1.0:bafybeid6s6rixpn7w37u6tntxvcjokxsdwomlfbyqx4oje7eurohp5ddti -- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigyaiv732wt62rqxflsyj4u7hasakt6kyvk6dwvjnaihptrrfq6hi +- valory/market_manager_abci:0.1.0:bafybeidropskas24c4lcekzdbwoflhnzaglmeqxvpyuoa7cf7q2rf2yex4 +- valory/decision_maker_abci:0.1.0:bafybeie4k3s546hx4p5g3dtn75hlrysyh3ieslszexctwal4odmarx34fm +- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeiet3hqejz7rtutuzmvyl7wqwqqi2buqagryawav4yeuem45ohpr2e behaviours: main: args: {} diff --git a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml index 10cded608..c3047d696 100644 --- a/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml +++ b/packages/valory/skills/tx_settlement_multiplexer_abci/skill.yaml @@ -20,7 +20,7 @@ contracts: [] protocols: [] skills: - valory/abstract_round_abci:0.1.0:bafybeid7neqpxxe4ualp23gxgrtpf6r5u3myr2mmc4uvwameyqshfdoydq -- valory/decision_maker_abci:0.1.0:bafybeid6ysjyi67q62yvf5g2v5jqlqbf25uylqiklwoeax7fnulfrrj65u +- valory/decision_maker_abci:0.1.0:bafybeie4k3s546hx4p5g3dtn75hlrysyh3ieslszexctwal4odmarx34fm behaviours: main: args: {}