diff --git a/README.md b/README.md index 9265b45..6a2512c 100644 --- a/README.md +++ b/README.md @@ -1,66 +1,178 @@ -## Foundry - -**Foundry is a blazing fast, portable and modular toolkit for Ethereum application development written in Rust.** - -Foundry consists of: - -- **Forge**: Ethereum testing framework (like Truffle, Hardhat and DappTools). -- **Cast**: Swiss army knife for interacting with EVM smart contracts, sending transactions and getting chain data. -- **Anvil**: Local Ethereum node, akin to Ganache, Hardhat Network. -- **Chisel**: Fast, utilitarian, and verbose solidity REPL. - -## Documentation - -https://book.getfoundry.sh/ - -## Usage - -### Build - +# Dataset Bonding Curve Smart Contracts + +This repository contains smart contracts implementing a bonding curve mechanism for dataset tokens. The system allows for the creation and pricing of dataset tokens using a bonding curve pricing model. + +## Overview + +The project consists of two main contracts: + +1. **DatasetToken**: An ERC1155-based token contract for representing datasets +2. **DatasetBondingCurve**: A contract implementing the bonding curve pricing mechanism with the following features: + - Initial price: 0.01 ETH + - Price multiplier: 1.5x increase per token + - Automated price calculation based on token supply + +## Contract Functions + +### DatasetToken Contract (`DeployDataset.sol`) + +#### Core Functions +- `mintDatasetToken(OwnershipShare[], string, string, string, string, uint256, string[])`: Mints a new dataset token with multiple owners, metadata, and initial price +- `purchaseDataset(uint256)`: Allows users to purchase a dataset token at the current bonding curve price +- `setBondingCurve(address)`: Sets the bonding curve contract address (admin only) +- `updatePrice(uint256, uint256)`: Updates the price of a dataset (primary owner only) + +#### View Functions +- `getTokensByTag(string)`: Returns all token IDs associated with a specific tag +- `getTokenTags(uint256)`: Returns all tags for a specific token +- `getTokenOwners(uint256)`: Returns ownership information for a token +- `getTotalTokens()`: Returns the total number of tokens minted +- `getTokensByOwner(address)`: Returns all token IDs owned by an address +- `getDatasetIPFSHash(uint256)`: Returns the IPFS hash for a purchased dataset + +### DatasetBondingCurve Contract + +#### Core Functions +- `setInitialPrice(uint256, uint256)`: Sets the initial price for a token's bonding curve +- `calculatePrice(uint256)`: Calculates the current price for a specific token +- `getCurrentPrice(uint256)`: View function to get the current price +- `recordPurchase(uint256)`: Records a purchase to update the bonding curve +- `updateDatasetTokenAddress(address)`: Updates the dataset token contract address + +## User Workflow + +### For Dataset Owners + +1. **Creating a Dataset Token** + ```solidity + // Example ownership structure + OwnershipShare[] shares = [ + OwnershipShare(owner1, 7000), // 70% + OwnershipShare(owner2, 3000) // 30% + ]; + + // Mint token with metadata + datasetToken.mintDatasetToken( + shares, + "Dataset Name", + "Description", + "contentHash", + "ipfsHash", + initialPrice, + ["tag1", "tag2"] + ); + ``` + +2. **Managing Dataset** + - Update price if needed using `updatePrice()` + - Monitor ownership and sales through events + - Add or remove tags as needed + +### For Dataset Buyers + +1. **Discovering Datasets** + - Browse datasets by tags using `getTokensByTag()` + - View dataset metadata and ownership information + - Check current prices using `getCurrentPrice()` + +2. **Purchasing a Dataset** + ```solidity + // Get current price + uint256 price = bondingCurve.getCurrentPrice(tokenId); + + // Purchase dataset + datasetToken.purchaseDataset{value: price}(tokenId); + ``` + +3. **Accessing Dataset** + - After purchase, retrieve IPFS hash using `getDatasetIPFSHash()` + - Access dataset content through IPFS + +### Price Mechanism + +The bonding curve implements an automated market maker with the following characteristics: + +1. **Initial Pricing** + - Each dataset starts at its set initial price + - Price increases by 1.5x after each purchase + +2. **Price Calculation** + ``` + Current Price = Initial Price * (1.5 ^ Number of Purchases) + ``` + +3. **Revenue Distribution** + - Sales revenue is automatically distributed to owners based on their ownership percentages + - Payments are instant and trustless + +## Prerequisites + +- [Foundry](https://book.getfoundry.sh/getting-started/installation) +- Ethereum wallet with some ETH for deployment +- Environment variables set up (see Configuration section) + +## Installation + +1. Clone the repository: ```shell -$ forge build +git clone +cd ``` -### Test - +2. Install dependencies: ```shell -$ forge test +forge install ``` -### Format +## Configuration -```shell -$ forge fmt +Create a `.env` file in the root directory with the following variables: +``` +PRIVATE_KEY=your_private_key +RPC_URL=your_rpc_url ``` -### Gas Snapshots +## Building +To build the contracts: ```shell -$ forge snapshot +forge build ``` -### Anvil +## Testing +Run the test suite: ```shell -$ anvil +forge test ``` -### Deploy - +For more detailed test output: ```shell -$ forge script script/Counter.s.sol:CounterScript --rpc-url --private-key +forge test -vv ``` -### Cast - +For gas reports: ```shell -$ cast +forge test --gas-report ``` -### Help +## Deployment +The deployment process involves two steps: + +1. Deploy the DatasetToken contract +2. Deploy the DatasetBondingCurve contract + +To deploy the contracts: ```shell -$ forge --help -$ anvil --help -$ cast --help +source .env +forge script script/DeployBondingCurve.s.sol:DeployBondingCurve --rpc-url $RPC_URL --private-key $PRIVATE_KEY --broadcast ``` + +## Security + +- The contracts use OpenZeppelin's standard implementations for security +- Ownership controls are in place for administrative functions +- Price calculations are done with proper decimal handling to prevent rounding errors +- Reentrancy protection is implemented for all state-changing functions +- Multi-owner support with percentage-based revenue distribution diff --git a/broadcast/DeployBondingCurve.s.sol/84532/run-1739351951.json b/broadcast/DeployBondingCurve.s.sol/84532/run-1739351951.json new file mode 100644 index 0000000..af3ac34 --- /dev/null +++ b/broadcast/DeployBondingCurve.s.sol/84532/run-1739351951.json @@ -0,0 +1,197 @@ +{ + "transactions": [ + { + "hash": "0xfef1db52401a9149016f08d4b8c2a5a61879bd2e5093fb8a6e24ff3617288576", + "transactionType": "CREATE", + "contractName": "DatasetToken", + "contractAddress": "0x30fcd694cd892b97d6ce6eaf40086346749e40b5", + "function": null, + "arguments": [ + "ipfs://", + "0x89fEdB2167197199Fd069122e5351A1C779F91B8" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "gas": "0x30ba3c", + "value": "0x0", + "input": "0x60806040523461028457612cc9803803806100198161029e565b9283398101906040818303126102845780516001600160401b03811161028457810182601f82011215610284578051906001600160401b03821161026e5761006a601f8301601f191660200161029e565b93828552602083830101116102845760005b82811061028957846020856000828785010152015160018060a01b0381168091036102845781516001600160401b03811161026e57600254600181811c91168015610264575b602082101461024e57601f81116101e9575b50602092601f82116001146101845792819293600092610179575b50508160011b916000199060031b1c1916176002555b801561016357600380546001600160a01b03198116831790915560405191906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a36001600455612a0590816102c48239f35b631e4fbdf760e01b600052600060045260246000fd5b0151905083806100ef565b601f198216936002600052806000209160005b8681106101d157508360019596106101b8575b505050811b01600255610105565b015160001960f88460031b161c191690558380806101aa565b91926020600181928685015181550194019201610197565b60026000527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace601f830160051c81019160208410610244575b601f0160051c01905b81811061023857506100d4565b6000815560010161022b565b9091508190610222565b634e487b7160e01b600052602260045260246000fd5b90607f16906100c2565b634e487b7160e01b600052604160045260246000fd5b600080fd5b8060208092840101518282880101520161007c565b6040519190601f01601f191682016001600160401b0381118382101761026e5760405256fe6080604052600436101561001257600080fd5b60003560e01c8062fdd58e1461019657806301ffc9a7146101915780630e89341c1461018c57806318c398fe146101875780631b45f9c5146101825780632cee94181461017d5780632eb2c2d61461017857806340398d671461017357806343ff1fb81461016e57806349ee56f9146101695780634e1273f414610164578063681ece9d1461015f5780636914db601461015a578063715018a61461015557806382367b2d1461015057806387078c561461014b5780638da5cb5b14610146578063a22cb46514610141578063e985e9c51461013c578063eff1d50e14610137578063f08b82e614610132578063f242432a1461012d578063f2fde38b146101285763fcce48831461012357600080fd5b61155c565b6114d2565b611429565b61140b565b6113e2565b611385565b6112cc565b6112a3565b611213565b61110d565b6110b0565b610ffb565b610e83565b610d81565b610aae565b610a00565b61093b565b6108b1565b6107c8565b610700565b6105b9565b610309565b61023f565b6101e0565b600435906001600160a01b03821682036101b157565b600080fd5b602435906001600160a01b03821682036101b157565b35906001600160a01b03821682036101b157565b346101b15760403660031901126101b15760206102246101fe61019b565b6024356000526000835260406000209060018060a01b0316600052602052604060002090565b54604051908152f35b6001600160e01b03198116036101b157565b346101b15760203660031901126101b157602060043561025e8161022d565b63ffffffff60e01b16636cdb3d1360e11b811490811561029c575b811561028b575b506040519015158152f35b6301ffc9a760e01b14905038610280565b6303a24d0760e21b81149150610279565b60005b8381106102c05750506000910152565b81810151838201526020016102b0565b906020916102e9815180928185528580860191016102ad565b601f01601f1916010190565b9060206103069281815201906102d0565b90565b346101b15760203660031901126101b157604051600060025461032b81610f1d565b80845290600181169081156103c25750600114610363575b61035f836103538185038261041c565b604051918291826102f5565b0390f35b600260009081527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace939250905b8082106103a857509091508101602001610353610343565b919260018160209254838588010152019101909291610390565b60ff191660208086019190915291151560051b840190910191506103539050610343565b634e487b7160e01b600052604160045260246000fd5b604081019081106001600160401b0382111761041757604052565b6103e6565b90601f801991011681019081106001600160401b0382111761041757604052565b6001600160401b0381116104175760051b60200190565b81601f820112156101b15780359061046b8261043d565b92610479604051948561041c565b82845260208085019360061b830101918183116101b157602001925b8284106104a3575050505090565b6040848303126101b157602060409182516104bd816103fc565b6104c6876101cc565b81528287013583820152815201930192610495565b6001600160401b03811161041757601f01601f191660200190565b81601f820112156101b157602081359101610510826104db565b9261051e604051948561041c565b828452828201116101b15781600092602092838601378301015290565b9080601f830112156101b15781356105528161043d565b92610560604051948561041c565b81845260208085019260051b820101918383116101b15760208201905b83821061058c57505050505090565b81356001600160401b0381116101b1576020916105ae878480948801016104f6565b81520191019061057d565b346101b15760e03660031901126101b1576004356001600160401b0381116101b1576105e9903690600401610454565b6024356001600160401b0381116101b1576106089036906004016104f6565b906044356001600160401b0381116101b1576106289036906004016104f6565b6064356001600160401b0381116101b1576106479036906004016104f6565b6084356001600160401b0381116101b1576106669036906004016104f6565b9060a4359260c435956001600160401b0387116101b15761068e61069497369060040161053b565b9561158d565b005b9080602083519182815201916020808360051b8301019401926000915b8383106106c257505050505090565b90919293946020806106e0600193601f1986820301875289516102d0565b970193019301919392906106b3565b906020610306928181520190610696565b346101b15760203660031901126101b15760043560005260066020526005604060002001805461072f8161043d565b9161073d604051938461041c565b818352602083019060005260206000206000915b838310610766576040518061035f87826106ef565b60016020819261077585610f57565b815201920192019190610751565b906020808351928381520192019060005b8181106107a15750505090565b8251845260209384019390920191600101610794565b906020610306928181520190610783565b346101b15760203660031901126101b1576004356001600160401b0381116101b1576107fb6108009136906004016104f6565b611d86565b60405190816020825491828152019160005260206000209060005b81811061083e5761035f856108328187038261041c565b604051918291826107b7565b825484526020909301926001928301920161081b565b9080601f830112156101b157813561086b8161043d565b92610879604051948561041c565b81845260208085019260051b8201019283116101b157602001905b8282106108a15750505090565b8135815260209182019101610894565b346101b15760a03660031901126101b1576108ca61019b565b6108d26101b6565b906044356001600160401b0381116101b1576108f2903690600401610854565b6064356001600160401b0381116101b157610911903690600401610854565b90608435936001600160401b0385116101b1576109356106949536906004016104f6565b93611eb5565b346101b15760203660031901126101b15761095461019b565b6005549061096182611dd5565b91600091825b8281106109b25750505061097a81611dd5565b9160005b828110610993576040518061035f86826107b7565b806109a060019284611cc3565b516109ab8287611cc3565b520161097e565b6000818152602081815260408083206001600160a01b03861684529091529020546109e0575b600101610967565b926109f881856109f260019489611cc3565b52611a6d565b9390506109d8565b346101b15760203660031901126101b157610a1961019b565b610a2161220d565b6001600160a01b03168015610a6957600980546001600160a01b031916821790557fc4fda5d836a9aaafabd3088c5f5dcabfe179c3b392b09dbac0e8727667f3c776600080a2005b60405162461bcd60e51b815260206004820152601d60248201527f496e76616c696420626f6e64696e6720637572766520616464726573730000006044820152606490fd5b60203660031901126101b157600435600260045414610d70576002600455610af2610aed610ae6836000526007602052604060002090565b5460ff1690565b611f55565b600954610b0f906001600160a01b03165b6001600160a01b031690565b6040516362ae87ab60e11b81526004810183905290602090829060249082905afa8015610d3c57610b4a91600091610d41575b503414611fb0565b610b5e816000526006602052604060002090565b600601908160005b828254821015610c21576000808080610bc0610bf5610bed6001610be48a8c610bdf610bd7859f9d610bad610c199f86610b9f91611cf1565b50546001600160a01b031690565b998a916000526000602052604060002090565b9060018060a01b0316600052602052604060002090565b541515611ffc565b611cf1565b50015434611bae565b612710900490565b90610c09610c01611d71565b8b33846124f5565b5af1610c1361203e565b5061206e565b018290610b66565b600954909150610c39906001600160a01b0316610b03565b803b156101b1576040516392d76ff960e01b815260048101839052906000908290602490829084905af18015610d3c57610d21575b50815491610c7b83611dd5565b92610c8581611dd5565b9160005b828110610cd357505050610cc67f358eaa98bb414b5fd23651427cb44fff0f7de91707aed81fcac3ad09aeebec16916040519182913396836120ba565b0390a36106946001600455565b80610cff610ce6610b9f60019486611cf1565b610cf0838a611cc3565b6001600160a01b039091169052565b610d10610bed83610be48487611cf1565b610d1a8287611cc3565b5201610c89565b80610d306000610d369361041c565b806110a5565b82610c6e565b611ca1565b610d63915060203d602011610d69575b610d5b818361041c565b810190611fa1565b38610b42565b503d610d51565b633ee5aeb560e01b60005260046000fd5b346101b15760403660031901126101b1576004356001600160401b0381116101b157366023820112156101b157806004013590610dbd8261043d565b91610dcb604051938461041c565b8083526024602084019160051b830101913683116101b157602401905b828210610e1c57836024356001600160401b0381116101b15761035f91610e16610832923690600401610854565b906120df565b60208091610e29846101cc565b815201910190610de8565b602060408183019282815284518094520192019060005b818110610e585750505090565b825180516001600160a01b031685526020908101518186015260409094019390920191600101610e4b565b346101b15760203660031901126101b157600435600052600660205260066040600020018054610eb28161043d565b91610ec0604051938461041c565b818352602083019060005260206000206000915b838310610ee9576040518061035f8782610e34565b60026020600192604051610efc816103fc565b848060a01b0386541681528486015483820152815201920192019190610ed4565b90600182811c92168015610f4d575b6020831014610f3757565b634e487b7160e01b600052602260045260246000fd5b91607f1691610f2c565b9060405191826000825492610f6b84610f1d565b8084529360018116908115610fd95750600114610f92575b50610f909250038361041c565b565b90506000929192526020600020906000915b818310610fbd575050906020610f909282010138610f83565b6020919350806001915483858901015201910190918492610fa4565b905060209250610f9094915060ff191682840152151560051b82010138610f83565b346101b15760203660031901126101b1576004356000526006602052611071604060002061102881610f57565b9061109b61103860018301610f57565b9161108d61104860028301610f57565b61107f600461105960038601610f57565b9401549560405198899860a08a5260a08a01906102d0565b9088820360208a01526102d0565b9086820360408801526102d0565b9084820360608601526102d0565b9060808301520390f35b60009103126101b157565b346101b15760003660031901126101b1576110c961220d565b600380546001600160a01b031981169091556000906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346101b15760403660031901126101b15760043560243580156111ce576111c97f945c1c4e99aa89f648fbfe3df471b916f719e16d960fcec0737d4d56bd696838916111716006611168866000526006602052604060002090565b01541515612171565b6111a0611199610b03610b9f6006611193896000526006602052604060002090565b01611cdc565b33146121b5565b8060046111b7866000526006602052604060002090565b01556040519081529081906020820190565b0390a2005b60405162461bcd60e51b815260206004820152601c60248201527f5072696365206d7573742062652067726561746572207468616e2030000000006044820152606490fd5b346101b15760203660031901126101b1576004356000818152602081815260408083203384529091529020541561125f57600052600660205261035f6103536003604060002001610f57565b606460405162461bcd60e51b815260206004820152602060248201527f43616c6c657220646f6573206e6f74206f776e207468697320646174617365746044820152fd5b346101b15760003660031901126101b1576003546040516001600160a01b039091168152602090f35b346101b15760403660031901126101b1576112e561019b565b60243590811515908183036101b1576001600160a01b038116928315611370576113316113429233600052600160205260406000209060018060a01b0316600052602052604060002090565b9060ff801983541691151516179055565b6040519081527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3160203392a3005b62ced3e160e81b600052600060045260246000fd5b346101b15760403660031901126101b157602060ff6113d66113a561019b565b6113ad6101b6565b6001600160a01b0391821660009081526001865260408082209290931681526020919091522090565b54166040519015158152f35b346101b15760003660031901126101b1576009546040516001600160a01b039091168152602090f35b346101b15760003660031901126101b1576020600554604051908152f35b346101b15760a03660031901126101b15761144261019b565b61144a6101b6565b6064356044356084356001600160401b0381116101b15761146f9036906004016104f6565b6001600160a01b0385169490939033861415806114ae575b61149557610694955061254c565b8563711bec9160e11b6000523360045260245260446000fd5b50600086815260016020908152604080832033845290915290205460ff1615611487565b346101b15760203660031901126101b1576114eb61019b565b6114f361220d565b6001600160a01b0316801561154657600380546001600160a01b0319811683179091556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b631e4fbdf760e01b600052600060045260246000fd5b346101b15760203660031901126101b1576004356000526007602052602060ff604060002054166040519015158152f35b96919493959261159b61220d565b6115a781511515611893565b6115b3875115156118df565b6115be851515611923565b6115ca8851151561197b565b6115d6845115156119c7565b6009546115f9906001600160a01b03906115f1908216610b03565b161515611a13565b611602886122d2565b6116536005549661161a61161589611a6d565b600555565b611637846116328a6000526006602052604060002090565b611add565b600161164d896000526006602052604060002090565b01611add565b61166d81600261164d896000526006602052604060002090565b61168787600361164d896000526006602052604060002090565b84600461169e886000526006602052604060002090565b01556116c08460056116ba896000526006602052604060002090565b01611bc1565b6009546116d5906001600160a01b0316610b03565b803b156101b15760405163afe742c360e01b81526004810188905260248101879052906000908290604490829084905af18015610d3c5761187e575b5060005b885181101561177f5760019061174c600661173a8a6000526006602052604060002090565b01611745838d611cc3565b5190611d0d565b61177961176a61175c838d611cc3565b51516001600160a01b031690565b89611773611d71565b91612392565b01611715565b509193969092949560005b86518110156117b857806117b2896117ad6117a76001958c611cc3565b51611d86565b611dac565b0161178a565b50929591949093966117e46117d7846000526007602052604060002090565b805460ff19166001179055565b6117ee8551611dd5565b936117f98651611dd5565b9660005b8751811015611843578061182361181961175c6001948c611cc3565b610cf0838b611cc3565b602061182f828b611cc3565b51015161183c828c611cc3565b52016117fd565b507f803c525550fdef50c98a15210bff07d15105fa724bd751d551511f27b0a0647b979650611879949860405197889788611e44565b0390a2565b80610d30600061188d9361041c565b38611711565b1561189a57565b60405162461bcd60e51b815260206004820152601860248201527f436f6e74656e74206861736820697320726571756972656400000000000000006044820152606490fd5b156118e657565b60405162461bcd60e51b815260206004820152601560248201527412541194c81a185cda081a5cc81c995c5d5a5c9959605a1b6044820152606490fd5b1561192a57565b60405162461bcd60e51b8152602060048201526024808201527f496e697469616c207072696365206d75737420626520677265617465722074686044820152630616e20360e41b6064820152608490fd5b1561198257565b60405162461bcd60e51b815260206004820152601b60248201527f4174206c65617374206f6e65206f776e657220726571756972656400000000006044820152606490fd5b156119ce57565b60405162461bcd60e51b815260206004820152601960248201527f4174206c65617374206f6e6520746167207265717569726564000000000000006044820152606490fd5b15611a1a57565b60405162461bcd60e51b8152602060048201526015602482015274109bdb991a5b99c818dd5c9d99481b9bdd081cd95d605a1b6044820152606490fd5b634e487b7160e01b600052601160045260246000fd5b6000198114611a7c5760010190565b611a57565b818110611a8c575050565b60008155600101611a81565b9190601f8111611aa757505050565b610f90926000526020600020906020601f840160051c83019310611ad3575b601f0160051c0190611a81565b9091508190611ac6565b91909182516001600160401b03811161041757611b0481611afe8454610f1d565b84611a98565b6020601f8211600114611b45578190611b36939495600092611b3a575b50508160011b916000199060031b1c19161790565b9055565b015190503880611b21565b601f19821690611b5a84600052602060002090565b9160005b818110611b9657509583600195969710611b7d575b505050811b019055565b015160001960f88460031b161c19169055388080611b73565b9192602060018192868b015181550194019201611b5e565b81810292918115918404141715611a7c57565b815191600160401b8311610417578154838355808410611c1e575b506020611bf0910191600052602060002090565b6000915b838310611c015750505050565b6001602082611c1283945186611add565b01920192019190611bf4565b8260005283602060002091820191015b818110611c3b5750611bdc565b80611c4860019254610f1d565b80611c55575b5001611c2e565b601f81118314611c6b5750600081555b38611c4e565b611c8f9083601f611c8185600052602060002090565b920160051c82019101611a81565b60008181526020812081835555611c65565b6040513d6000823e3d90fd5b634e487b7160e01b600052603260045260246000fd5b8051821015611cd75760209160051b010190565b611cad565b805415611cd757600052602060002090600090565b8054821015611cd75760005260206000209060011b0190600090565b8054600160401b81101561041757611d2a91600182018155611cf1565b919091611d5b57805182546001600160a01b0319166001600160a01b03919091161782556020015160019190910155565b634e487b7160e01b600052600060045260246000fd5b60405190611d8060208361041c565b60008252565b6020611d9f9181604051938285809451938492016102ad565b8101600881520301902090565b805490600160401b8210156104175760018201808255821015611cd75760005260206000200155565b90611ddf8261043d565b611dec604051918261041c565b8281528092611dfd601f199161043d565b0190602036910137565b906020808351928381520192019060005b818110611e255750505090565b82516001600160a01b0316845260209384019390920191600101611e18565b93611e86611ea294611e786103069a9895611e6a611e949660e08b5260e08b0190611e07565b9089820360208b0152610783565b9087820360408901526102d0565b9085820360608701526102d0565b9083820360808501526102d0565b9260a082015260c0818403910152610696565b939291906001600160a01b0385163381141580611f31575b611f19576001600160a01b03821615611f035715611eee57610f909461259a565b626a0d4560e21b600052600060045260246000fd5b632bfa23e760e11b600052600060045260246000fd5b63711bec9160e11b6000523360045260245260446000fd5b50600081815260016020908152604080832033845290915290205460ff1615611ecd565b15611f5c57565b60405162461bcd60e51b815260206004820152601e60248201527f44617461736574206973206e6f74206c697374656420666f722073616c6500006044820152606490fd5b908160209103126101b1575190565b15611fb757565b60405162461bcd60e51b815260206004820152601860248201527f496e636f7272656374207061796d656e7420616d6f756e7400000000000000006044820152606490fd5b1561200357565b60405162461bcd60e51b81526020600482015260136024820152724f776e657220686173206e6f20746f6b656e7360681b6044820152606490fd5b3d15612069573d9061204f826104db565b9161205d604051938461041c565b82523d6000602084013e565b606090565b1561207557565b60405162461bcd60e51b815260206004820152601760248201527f5061796d656e74207472616e73666572206661696c65640000000000000000006044820152606490fd5b90916120d161030693604084526040840190611e07565b916020818403910152610783565b9190918051835180820361215a5750506120f98151611dd5565b9060005b8151811015612153578061214160019260051b60208082870101519189010151600052600060205260406000209060018060a01b0316600052602052604060002090565b5461214c8286611cc3565b52016120fd565b5090925050565b635b05999160e01b60005260045260245260446000fd5b1561217857565b60405162461bcd60e51b81526020600482015260156024820152744461746173657420686173206e6f206f776e65727360581b6044820152606490fd5b156121bc57565b60405162461bcd60e51b815260206004820152602360248201527f4f6e6c79207072696d617279206f776e65722063616e2075706461746520707260448201526269636560e81b6064820152608490fd5b6003546001600160a01b0316330361222157565b63118cdaa760e01b6000523360045260246000fd5b1561223d57565b60405162461bcd60e51b8152602060048201526015602482015274496e76616c6964206f776e6572206164647265737360581b6044820152606490fd5b91908201809211611a7c57565b1561228e57565b606460405162461bcd60e51b815260206004820152602060248201527f546f74616c2070657263656e74616765206d75737420657175616c20313030256044820152fd5b60009190825b81518410156123815760206122ed8584611cc3565b510151156123325761232a60019161231561230e610b0361175c8988611cc3565b1515612236565b60206123218786611cc3565b5101519061227a565b9301926122d8565b60405162461bcd60e51b815260206004820152602160248201527f50657263656e74616765206d7573742062652067726561746572207468616e206044820152600360fc1b6064820152608490fd5b610f90929350612710915014612287565b6001600160a01b03811692918315611f035760016123cd60405192600184526020840152604083019160018352606084015260808301604052565b9281518451908181036124de57505060005b8251811015612427578060019160051b61241f61241787610bc0602080868b010151958c010151946000526000602052604060002090565b91825461227a565b9055016123df565b5092919360018251146000146124a25760208281015184820151604080519283529282015260009133917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f629190a45b80516001036124965790602080610f90959301519101519160003361292f565b610f90936000336127fa565b60006040517f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb3391806124d688888361277b565b0390a4612476565b635b05999160e01b60005260045260245260446000fd5b9192916001600160a01b03821615611f03576001600160a01b03811615611eee576125446001610f90959160405192600184526020840152604083019160018352606084015260808301604052565b92909161259a565b92939290916001600160a01b03831615611f03576001600160a01b03821615611eee57610f909461254460405192600184526020840152604083019160018352606084015260808301604052565b94939290919384518251908181036124de5750506001600160a01b0386811695861515959185168015159391929060005b84518110156126ad578060051b90898988602080868b010151958c01015192612626575b93600194612601575b505050016125cb565b61261c91610bc0612417926000526000602052604060002090565b90553889816125f8565b505090916126428d610bc0836000526000602052604060002090565b54828110612676578291898f61266d600197968f950391610bc0856000526000602052604060002090565b559094506125ef565b6040516303dee4c560e01b81526001600160a01b038f16600482015260248101919091526044810183905260648101829052608490fd5b5091989593929790965060018851146000146127415760208881015186820151604080519283529282015233917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6291a45b61270a575b5050505050565b845160010361273057602080612726960151920151923361292f565b3880808080612703565b61273c949192336127fa565b612726565b6040517f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb339180612773898d8361277b565b0390a46126fe565b90916120d161030693604084526040840190610783565b908160209103126101b157516103068161022d565b6001600160a01b0391821681529116602082015260a06040820181905261030694919391926127ec92916127de9190860190610783565b908482036060860152610783565b9160808184039101526102d0565b9091949293853b61280e575b505050505050565b60209361283091604051968795869563bc197c8160e01b8752600487016127a7565b038160006001600160a01b0387165af1600091816128c5575b50612885575061285761203e565b805191908261287e57632bfa23e760e11b6000526001600160a01b03821660045260246000fd5b9050602001fd5b6001600160e01b0319166343e6837f60e01b016128a85750388080808080612806565b632bfa23e760e11b6000526001600160a01b031660045260246000fd5b6128e891925060203d6020116128ef575b6128e0818361041c565b810190612792565b9038612849565b503d6128d6565b6001600160a01b039182168152911660208201526040810191909152606081019190915260a060808201819052610306929101906102d0565b9091949293853b61294257505050505050565b60209361296491604051968795869563f23a6e6160e01b8752600487016128f6565b038160006001600160a01b0387165af1600091816129ae575b5061298b575061285761203e565b6001600160e01b031916630dc5919f60e01b016128a85750388080808080612806565b6129c891925060203d6020116128ef576128e0818361041c565b903861297d56fea2646970667358221220d41df3aa8aa1825e5b2593e6a90f5a8c95125657158ac8b53ace82d89cd4f1cd64736f6c634300081c0033000000000000000000000000000000000000000000000000000000000000004000000000000000000000000089fedb2167197199fd069122e5351a1c779f91b80000000000000000000000000000000000000000000000000000000000000007697066733a2f2f00000000000000000000000000000000000000000000000000", + "nonce": "0x1", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0x7e6c2ada5c3c50973e21680bc5435087dd8c104058115581a8f3e689466e8f26", + "transactionType": "CREATE", + "contractName": "DatasetBondingCurve", + "contractAddress": "0xa2b93ff387e56ba1ef3cb883315ba8df09fea06a", + "function": null, + "arguments": [ + "0x30fCD694CD892b97d6cE6EAf40086346749e40B5", + "0x89fEdB2167197199Fd069122e5351A1C779F91B8" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "gas": "0xa2e2e", + "value": "0x0", + "input": "0x60803461013857601f6108ca38819003918201601f19168301916001600160401b0383118484101761013d5780849260409485528339810103126101385761004681610153565b906001600160a01b039061005c90602001610153565b1690811561012257600080546001600160a01b031981168417825560405193916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a36001600160a01b03169081156100e05750600180546001600160a01b03191691909117905560405161076290816101688239f35b62461bcd60e51b815260206004820152601d60248201527f496e76616c6964206461746173657420746f6b656e20616464726573730000006044820152606490fd5b631e4fbdf760e01b600052600060045260246000fd5b600080fd5b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b03821682036101385756fe6080604052600436101561001257600080fd5b60003560e01c806310cee91914610621578063113990b8146105fe5780631798820f146105d25780632928a557146105a6578063715018a61461054d5780638da5cb5b14610524578063918f86741461050157806392d76ff914610444578063ae10426514610383578063afe742c31461020e578063b5713ff7146101e5578063c55d0f561461013d5763f2fde38b146100ab57600080fd5b34610138576020366003190112610138576004356001600160a01b03811690819003610138576100d9610703565b801561012257600080546001600160a01b03198116831782556001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a3005b631e4fbdf760e01b600052600060045260246000fd5b600080fd5b346101385760203660031901126101385760043580600052600260205261016a60406000205415156106b7565b60009081526002602090815260408083205460039092528220545b80831061019757602082604051908152f35b906714d1120d7b1600008102908082046714d1120d7b16000014901517156101cf57670de0b6b3a76400006001910492019190610185565b634e487b7160e01b600052601160045260246000fd5b34610138576000366003190112610138576001546040516001600160a01b039091168152602090f35b346101385760403660031901126101385760015460043590602435906001600160a01b031633036103245780156102d35781600052600260205260406000205461028e5760207f12c0ad9d517477ec2ebaa67b0e56cfad40b02e2c0769f65cfb36d38cb16a910591836000526002825280604060002055604051908152a2005b60405162461bcd60e51b815260206004820152601960248201527f496e697469616c20707269636520616c726561647920736574000000000000006044820152606490fd5b60405162461bcd60e51b8152602060048201526024808201527f496e697469616c207072696365206d75737420626520677265617465722074686044820152630616e20360e41b6064820152608490fd5b60405162461bcd60e51b815260206004820152603160248201527f4f6e6c79206461746173657420746f6b656e20636f6e74726163742063616e2060448201527073657420696e697469616c20707269636560781b6064820152608490fd5b34610138576020366003190112610138576004358060005260026020526103b060406000205415156106b7565b8060005260026020526040600020548160005260036020526040600020549160005b83811061040e57602083837fccfa5799e90149f8ab0bc1d481fdbe650f64035a2d299e17b342c119adc790ad83604051848152a2604051908152f35b916714d1120d7b1600008102908082046714d1120d7b16000014901517156101cf57670de0b6b3a76400006001910492016103d2565b3461013857602036600319011261013857600154600435906001600160a01b031633036104a35780600052600260205261048460406000205415156106b7565b60005260036020526040600020805460001981146101cf576001019055005b60405162461bcd60e51b815260206004820152603060248201527f4f6e6c79206461746173657420746f6b656e20636f6e74726163742063616e2060448201526f7265636f72642070757263686173657360801b6064820152608490fd5b34610138576000366003190112610138576020604051670de0b6b3a76400008152f35b34610138576000366003190112610138576000546040516001600160a01b039091168152602090f35b3461013857600036600319011261013857610566610703565b600080546001600160a01b0319811682556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346101385760203660031901126101385760043560005260026020526020604060002054604051908152f35b346101385760203660031901126101385760043560005260036020526020604060002054604051908152f35b346101385760003660031901126101385760206040516714d1120d7b1600008152f35b34610138576020366003190112610138576004356001600160a01b038116908190036101385761064f610703565b8015610672576bffffffffffffffffffffffff60a01b6001541617600155600080f35b60405162461bcd60e51b815260206004820152601d60248201527f496e76616c6964206461746173657420746f6b656e20616464726573730000006044820152606490fd5b156106be57565b60405162461bcd60e51b815260206004820152601b60248201527f546f6b656e20696e697469616c207072696365206e6f742073657400000000006044820152606490fd5b6000546001600160a01b0316330361071757565b63118cdaa760e01b6000523360045260246000fdfea2646970667358221220f8cac7623f68bbb045656de3dac0808d9edaf0fafaa568127cc630f5078c21bb64736f6c634300081c003300000000000000000000000030fcd694cd892b97d6ce6eaf40086346749e40b500000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8", + "nonce": "0x2", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0x99f387b5252a95cef21ce4903498c0a3c0985f846542fc3745db97816f8d28c8", + "transactionType": "CALL", + "contractName": "DatasetToken", + "contractAddress": "0x30fcd694cd892b97d6ce6eaf40086346749e40b5", + "function": "setBondingCurve(address)", + "arguments": [ + "0xA2b93fF387E56BA1EF3CB883315bA8df09fEa06a" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": "0x30fcd694cd892b97d6ce6eaf40086346749e40b5", + "gas": "0xff21", + "value": "0x0", + "input": "0x43ff1fb8000000000000000000000000a2b93ff387e56ba1ef3cb883315ba8df09fea06a", + "nonce": "0x3", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "status": "0x1", + "cumulativeGasUsed": "0x8a2261", + "logs": [ + { + "address": "0x30fcd694cd892b97d6ce6eaf40086346749e40b5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8" + ], + "data": "0x", + "blockHash": "0xf77f2ffd75f618940fdf3b8ff9adbf21250ceea7dc8e9943fa96fc864e961240", + "blockNumber": "0x14c8453", + "transactionHash": "0xfef1db52401a9149016f08d4b8c2a5a61879bd2e5093fb8a6e24ff3617288576", + "transactionIndex": "0x2e", + "logIndex": "0x8e", + "removed": false + } + ], + "logsBloom": "0x00000000000000004000000100000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000000000000000000000000400000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0xfef1db52401a9149016f08d4b8c2a5a61879bd2e5093fb8a6e24ff3617288576", + "transactionIndex": "0x2e", + "blockHash": "0xf77f2ffd75f618940fdf3b8ff9adbf21250ceea7dc8e9943fa96fc864e961240", + "blockNumber": "0x14c8453", + "gasUsed": "0x257e67", + "effectiveGasPrice": "0x188ab", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": null, + "contractAddress": "0x30fcd694cd892b97d6ce6eaf40086346749e40b5", + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0xb01625fd76", + "l1GasPrice": "0x180668689", + "l1GasUsed": "0x1a00f" + }, + { + "status": "0x1", + "cumulativeGasUsed": "0x91f7b4", + "logs": [ + { + "address": "0xa2b93ff387e56ba1ef3cb883315ba8df09fea06a", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8" + ], + "data": "0x", + "blockHash": "0xf77f2ffd75f618940fdf3b8ff9adbf21250ceea7dc8e9943fa96fc864e961240", + "blockNumber": "0x14c8453", + "transactionHash": "0x7e6c2ada5c3c50973e21680bc5435087dd8c104058115581a8f3e689466e8f26", + "transactionIndex": "0x2f", + "logIndex": "0x8f", + "removed": false + } + ], + "logsBloom": "0x00000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000001000000000000000000400000000000000000020000000000000000008800000000000000000000000000000000400008000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0x7e6c2ada5c3c50973e21680bc5435087dd8c104058115581a8f3e689466e8f26", + "transactionIndex": "0x2f", + "blockHash": "0xf77f2ffd75f618940fdf3b8ff9adbf21250ceea7dc8e9943fa96fc864e961240", + "blockNumber": "0x14c8453", + "gasUsed": "0x7d553", + "effectiveGasPrice": "0x188ab", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": null, + "contractAddress": "0xa2b93ff387e56ba1ef3cb883315ba8df09fea06a", + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0x2004f662f0", + "l1GasPrice": "0x180668689", + "l1GasUsed": "0x4ba7" + }, + { + "status": "0x1", + "cumulativeGasUsed": "0x102cb9e", + "logs": [ + { + "address": "0x30fcd694cd892b97d6ce6eaf40086346749e40b5", + "topics": [ + "0xc4fda5d836a9aaafabd3088c5f5dcabfe179c3b392b09dbac0e8727667f3c776", + "0x000000000000000000000000a2b93ff387e56ba1ef3cb883315ba8df09fea06a" + ], + "data": "0x", + "blockHash": "0x2b10fd29623bc051a1f1b14f4cbaac741ef6f5945c1b4c37524ffe154e83a1a1", + "blockNumber": "0x14c8454", + "transactionHash": "0x99f387b5252a95cef21ce4903498c0a3c0985f846542fc3745db97816f8d28c8", + "transactionIndex": "0x32", + "logIndex": "0x96", + "removed": false + } + ], + "logsBloom": "0x00000000000000004000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000004000000000000000080000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000008000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0x99f387b5252a95cef21ce4903498c0a3c0985f846542fc3745db97816f8d28c8", + "transactionIndex": "0x32", + "blockHash": "0x2b10fd29623bc051a1f1b14f4cbaac741ef6f5945c1b4c37524ffe154e83a1a1", + "blockNumber": "0x14c8454", + "gasUsed": "0xb8b6", + "effectiveGasPrice": "0x188ac", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": "0x30fcd694cd892b97d6ce6eaf40086346749e40b5", + "contractAddress": null, + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0x2a7c5e726", + "l1GasPrice": "0x181e24662", + "l1GasUsed": "0x640" + } + ], + "libraries": [], + "pending": [], + "returns": { + "0": { + "internal_type": "contract DatasetBondingCurve", + "value": "0xA2b93fF387E56BA1EF3CB883315bA8df09fEa06a" + }, + "1": { + "internal_type": "contract DatasetToken", + "value": "0x30fCD694CD892b97d6cE6EAf40086346749e40B5" + } + }, + "timestamp": 1739351951, + "chain": 84532, + "commit": "0c8dc77" +} \ No newline at end of file diff --git a/broadcast/DeployBondingCurve.s.sol/84532/run-1739352629.json b/broadcast/DeployBondingCurve.s.sol/84532/run-1739352629.json new file mode 100644 index 0000000..ec4c764 --- /dev/null +++ b/broadcast/DeployBondingCurve.s.sol/84532/run-1739352629.json @@ -0,0 +1,197 @@ +{ + "transactions": [ + { + "hash": "0x9646f22492f77b13cacabbf5bfe2222122515b75469c174acfd95e22ed45ddd4", + "transactionType": "CREATE", + "contractName": "DatasetToken", + "contractAddress": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "function": null, + "arguments": [ + "ipfs://", + "0x89fEdB2167197199Fd069122e5351A1C779F91B8" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "gas": "0x30ba3c", + "value": "0x0", + "input": "0x60806040523461028457612cc9803803806100198161029e565b9283398101906040818303126102845780516001600160401b03811161028457810182601f82011215610284578051906001600160401b03821161026e5761006a601f8301601f191660200161029e565b93828552602083830101116102845760005b82811061028957846020856000828785010152015160018060a01b0381168091036102845781516001600160401b03811161026e57600254600181811c91168015610264575b602082101461024e57601f81116101e9575b50602092601f82116001146101845792819293600092610179575b50508160011b916000199060031b1c1916176002555b801561016357600380546001600160a01b03198116831790915560405191906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a36001600455612a0590816102c48239f35b631e4fbdf760e01b600052600060045260246000fd5b0151905083806100ef565b601f198216936002600052806000209160005b8681106101d157508360019596106101b8575b505050811b01600255610105565b015160001960f88460031b161c191690558380806101aa565b91926020600181928685015181550194019201610197565b60026000527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace601f830160051c81019160208410610244575b601f0160051c01905b81811061023857506100d4565b6000815560010161022b565b9091508190610222565b634e487b7160e01b600052602260045260246000fd5b90607f16906100c2565b634e487b7160e01b600052604160045260246000fd5b600080fd5b8060208092840101518282880101520161007c565b6040519190601f01601f191682016001600160401b0381118382101761026e5760405256fe6080604052600436101561001257600080fd5b60003560e01c8062fdd58e1461019657806301ffc9a7146101915780630e89341c1461018c57806318c398fe146101875780631b45f9c5146101825780632cee94181461017d5780632eb2c2d61461017857806340398d671461017357806343ff1fb81461016e57806349ee56f9146101695780634e1273f414610164578063681ece9d1461015f5780636914db601461015a578063715018a61461015557806382367b2d1461015057806387078c561461014b5780638da5cb5b14610146578063a22cb46514610141578063e985e9c51461013c578063eff1d50e14610137578063f08b82e614610132578063f242432a1461012d578063f2fde38b146101285763fcce48831461012357600080fd5b61155c565b6114d2565b611429565b61140b565b6113e2565b611385565b6112cc565b6112a3565b611213565b61110d565b6110b0565b610ffb565b610e83565b610d81565b610aae565b610a00565b61093b565b6108b1565b6107c8565b610700565b6105b9565b610309565b61023f565b6101e0565b600435906001600160a01b03821682036101b157565b600080fd5b602435906001600160a01b03821682036101b157565b35906001600160a01b03821682036101b157565b346101b15760403660031901126101b15760206102246101fe61019b565b6024356000526000835260406000209060018060a01b0316600052602052604060002090565b54604051908152f35b6001600160e01b03198116036101b157565b346101b15760203660031901126101b157602060043561025e8161022d565b63ffffffff60e01b16636cdb3d1360e11b811490811561029c575b811561028b575b506040519015158152f35b6301ffc9a760e01b14905038610280565b6303a24d0760e21b81149150610279565b60005b8381106102c05750506000910152565b81810151838201526020016102b0565b906020916102e9815180928185528580860191016102ad565b601f01601f1916010190565b9060206103069281815201906102d0565b90565b346101b15760203660031901126101b157604051600060025461032b81610f1d565b80845290600181169081156103c25750600114610363575b61035f836103538185038261041c565b604051918291826102f5565b0390f35b600260009081527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace939250905b8082106103a857509091508101602001610353610343565b919260018160209254838588010152019101909291610390565b60ff191660208086019190915291151560051b840190910191506103539050610343565b634e487b7160e01b600052604160045260246000fd5b604081019081106001600160401b0382111761041757604052565b6103e6565b90601f801991011681019081106001600160401b0382111761041757604052565b6001600160401b0381116104175760051b60200190565b81601f820112156101b15780359061046b8261043d565b92610479604051948561041c565b82845260208085019360061b830101918183116101b157602001925b8284106104a3575050505090565b6040848303126101b157602060409182516104bd816103fc565b6104c6876101cc565b81528287013583820152815201930192610495565b6001600160401b03811161041757601f01601f191660200190565b81601f820112156101b157602081359101610510826104db565b9261051e604051948561041c565b828452828201116101b15781600092602092838601378301015290565b9080601f830112156101b15781356105528161043d565b92610560604051948561041c565b81845260208085019260051b820101918383116101b15760208201905b83821061058c57505050505090565b81356001600160401b0381116101b1576020916105ae878480948801016104f6565b81520191019061057d565b346101b15760e03660031901126101b1576004356001600160401b0381116101b1576105e9903690600401610454565b6024356001600160401b0381116101b1576106089036906004016104f6565b906044356001600160401b0381116101b1576106289036906004016104f6565b6064356001600160401b0381116101b1576106479036906004016104f6565b6084356001600160401b0381116101b1576106669036906004016104f6565b9060a4359260c435956001600160401b0387116101b15761068e61069497369060040161053b565b9561158d565b005b9080602083519182815201916020808360051b8301019401926000915b8383106106c257505050505090565b90919293946020806106e0600193601f1986820301875289516102d0565b970193019301919392906106b3565b906020610306928181520190610696565b346101b15760203660031901126101b15760043560005260066020526005604060002001805461072f8161043d565b9161073d604051938461041c565b818352602083019060005260206000206000915b838310610766576040518061035f87826106ef565b60016020819261077585610f57565b815201920192019190610751565b906020808351928381520192019060005b8181106107a15750505090565b8251845260209384019390920191600101610794565b906020610306928181520190610783565b346101b15760203660031901126101b1576004356001600160401b0381116101b1576107fb6108009136906004016104f6565b611d86565b60405190816020825491828152019160005260206000209060005b81811061083e5761035f856108328187038261041c565b604051918291826107b7565b825484526020909301926001928301920161081b565b9080601f830112156101b157813561086b8161043d565b92610879604051948561041c565b81845260208085019260051b8201019283116101b157602001905b8282106108a15750505090565b8135815260209182019101610894565b346101b15760a03660031901126101b1576108ca61019b565b6108d26101b6565b906044356001600160401b0381116101b1576108f2903690600401610854565b6064356001600160401b0381116101b157610911903690600401610854565b90608435936001600160401b0385116101b1576109356106949536906004016104f6565b93611eb5565b346101b15760203660031901126101b15761095461019b565b6005549061096182611dd5565b91600091825b8281106109b25750505061097a81611dd5565b9160005b828110610993576040518061035f86826107b7565b806109a060019284611cc3565b516109ab8287611cc3565b520161097e565b6000818152602081815260408083206001600160a01b03861684529091529020546109e0575b600101610967565b926109f881856109f260019489611cc3565b52611a6d565b9390506109d8565b346101b15760203660031901126101b157610a1961019b565b610a2161220d565b6001600160a01b03168015610a6957600980546001600160a01b031916821790557fc4fda5d836a9aaafabd3088c5f5dcabfe179c3b392b09dbac0e8727667f3c776600080a2005b60405162461bcd60e51b815260206004820152601d60248201527f496e76616c696420626f6e64696e6720637572766520616464726573730000006044820152606490fd5b60203660031901126101b157600435600260045414610d70576002600455610af2610aed610ae6836000526007602052604060002090565b5460ff1690565b611f55565b600954610b0f906001600160a01b03165b6001600160a01b031690565b6040516362ae87ab60e11b81526004810183905290602090829060249082905afa8015610d3c57610b4a91600091610d41575b503414611fb0565b610b5e816000526006602052604060002090565b600601908160005b828254821015610c21576000808080610bc0610bf5610bed6001610be48a8c610bdf610bd7859f9d610bad610c199f86610b9f91611cf1565b50546001600160a01b031690565b998a916000526000602052604060002090565b9060018060a01b0316600052602052604060002090565b541515611ffc565b611cf1565b50015434611bae565b612710900490565b90610c09610c01611d71565b8b33846124f5565b5af1610c1361203e565b5061206e565b018290610b66565b600954909150610c39906001600160a01b0316610b03565b803b156101b1576040516392d76ff960e01b815260048101839052906000908290602490829084905af18015610d3c57610d21575b50815491610c7b83611dd5565b92610c8581611dd5565b9160005b828110610cd357505050610cc67f358eaa98bb414b5fd23651427cb44fff0f7de91707aed81fcac3ad09aeebec16916040519182913396836120ba565b0390a36106946001600455565b80610cff610ce6610b9f60019486611cf1565b610cf0838a611cc3565b6001600160a01b039091169052565b610d10610bed83610be48487611cf1565b610d1a8287611cc3565b5201610c89565b80610d306000610d369361041c565b806110a5565b82610c6e565b611ca1565b610d63915060203d602011610d69575b610d5b818361041c565b810190611fa1565b38610b42565b503d610d51565b633ee5aeb560e01b60005260046000fd5b346101b15760403660031901126101b1576004356001600160401b0381116101b157366023820112156101b157806004013590610dbd8261043d565b91610dcb604051938461041c565b8083526024602084019160051b830101913683116101b157602401905b828210610e1c57836024356001600160401b0381116101b15761035f91610e16610832923690600401610854565b906120df565b60208091610e29846101cc565b815201910190610de8565b602060408183019282815284518094520192019060005b818110610e585750505090565b825180516001600160a01b031685526020908101518186015260409094019390920191600101610e4b565b346101b15760203660031901126101b157600435600052600660205260066040600020018054610eb28161043d565b91610ec0604051938461041c565b818352602083019060005260206000206000915b838310610ee9576040518061035f8782610e34565b60026020600192604051610efc816103fc565b848060a01b0386541681528486015483820152815201920192019190610ed4565b90600182811c92168015610f4d575b6020831014610f3757565b634e487b7160e01b600052602260045260246000fd5b91607f1691610f2c565b9060405191826000825492610f6b84610f1d565b8084529360018116908115610fd95750600114610f92575b50610f909250038361041c565b565b90506000929192526020600020906000915b818310610fbd575050906020610f909282010138610f83565b6020919350806001915483858901015201910190918492610fa4565b905060209250610f9094915060ff191682840152151560051b82010138610f83565b346101b15760203660031901126101b1576004356000526006602052611071604060002061102881610f57565b9061109b61103860018301610f57565b9161108d61104860028301610f57565b61107f600461105960038601610f57565b9401549560405198899860a08a5260a08a01906102d0565b9088820360208a01526102d0565b9086820360408801526102d0565b9084820360608601526102d0565b9060808301520390f35b60009103126101b157565b346101b15760003660031901126101b1576110c961220d565b600380546001600160a01b031981169091556000906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346101b15760403660031901126101b15760043560243580156111ce576111c97f945c1c4e99aa89f648fbfe3df471b916f719e16d960fcec0737d4d56bd696838916111716006611168866000526006602052604060002090565b01541515612171565b6111a0611199610b03610b9f6006611193896000526006602052604060002090565b01611cdc565b33146121b5565b8060046111b7866000526006602052604060002090565b01556040519081529081906020820190565b0390a2005b60405162461bcd60e51b815260206004820152601c60248201527f5072696365206d7573742062652067726561746572207468616e2030000000006044820152606490fd5b346101b15760203660031901126101b1576004356000818152602081815260408083203384529091529020541561125f57600052600660205261035f6103536003604060002001610f57565b606460405162461bcd60e51b815260206004820152602060248201527f43616c6c657220646f6573206e6f74206f776e207468697320646174617365746044820152fd5b346101b15760003660031901126101b1576003546040516001600160a01b039091168152602090f35b346101b15760403660031901126101b1576112e561019b565b60243590811515908183036101b1576001600160a01b038116928315611370576113316113429233600052600160205260406000209060018060a01b0316600052602052604060002090565b9060ff801983541691151516179055565b6040519081527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3160203392a3005b62ced3e160e81b600052600060045260246000fd5b346101b15760403660031901126101b157602060ff6113d66113a561019b565b6113ad6101b6565b6001600160a01b0391821660009081526001865260408082209290931681526020919091522090565b54166040519015158152f35b346101b15760003660031901126101b1576009546040516001600160a01b039091168152602090f35b346101b15760003660031901126101b1576020600554604051908152f35b346101b15760a03660031901126101b15761144261019b565b61144a6101b6565b6064356044356084356001600160401b0381116101b15761146f9036906004016104f6565b6001600160a01b0385169490939033861415806114ae575b61149557610694955061254c565b8563711bec9160e11b6000523360045260245260446000fd5b50600086815260016020908152604080832033845290915290205460ff1615611487565b346101b15760203660031901126101b1576114eb61019b565b6114f361220d565b6001600160a01b0316801561154657600380546001600160a01b0319811683179091556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b631e4fbdf760e01b600052600060045260246000fd5b346101b15760203660031901126101b1576004356000526007602052602060ff604060002054166040519015158152f35b96919493959261159b61220d565b6115a781511515611893565b6115b3875115156118df565b6115be851515611923565b6115ca8851151561197b565b6115d6845115156119c7565b6009546115f9906001600160a01b03906115f1908216610b03565b161515611a13565b611602886122d2565b6116536005549661161a61161589611a6d565b600555565b611637846116328a6000526006602052604060002090565b611add565b600161164d896000526006602052604060002090565b01611add565b61166d81600261164d896000526006602052604060002090565b61168787600361164d896000526006602052604060002090565b84600461169e886000526006602052604060002090565b01556116c08460056116ba896000526006602052604060002090565b01611bc1565b6009546116d5906001600160a01b0316610b03565b803b156101b15760405163afe742c360e01b81526004810188905260248101879052906000908290604490829084905af18015610d3c5761187e575b5060005b885181101561177f5760019061174c600661173a8a6000526006602052604060002090565b01611745838d611cc3565b5190611d0d565b61177961176a61175c838d611cc3565b51516001600160a01b031690565b89611773611d71565b91612392565b01611715565b509193969092949560005b86518110156117b857806117b2896117ad6117a76001958c611cc3565b51611d86565b611dac565b0161178a565b50929591949093966117e46117d7846000526007602052604060002090565b805460ff19166001179055565b6117ee8551611dd5565b936117f98651611dd5565b9660005b8751811015611843578061182361181961175c6001948c611cc3565b610cf0838b611cc3565b602061182f828b611cc3565b51015161183c828c611cc3565b52016117fd565b507f803c525550fdef50c98a15210bff07d15105fa724bd751d551511f27b0a0647b979650611879949860405197889788611e44565b0390a2565b80610d30600061188d9361041c565b38611711565b1561189a57565b60405162461bcd60e51b815260206004820152601860248201527f436f6e74656e74206861736820697320726571756972656400000000000000006044820152606490fd5b156118e657565b60405162461bcd60e51b815260206004820152601560248201527412541194c81a185cda081a5cc81c995c5d5a5c9959605a1b6044820152606490fd5b1561192a57565b60405162461bcd60e51b8152602060048201526024808201527f496e697469616c207072696365206d75737420626520677265617465722074686044820152630616e20360e41b6064820152608490fd5b1561198257565b60405162461bcd60e51b815260206004820152601b60248201527f4174206c65617374206f6e65206f776e657220726571756972656400000000006044820152606490fd5b156119ce57565b60405162461bcd60e51b815260206004820152601960248201527f4174206c65617374206f6e6520746167207265717569726564000000000000006044820152606490fd5b15611a1a57565b60405162461bcd60e51b8152602060048201526015602482015274109bdb991a5b99c818dd5c9d99481b9bdd081cd95d605a1b6044820152606490fd5b634e487b7160e01b600052601160045260246000fd5b6000198114611a7c5760010190565b611a57565b818110611a8c575050565b60008155600101611a81565b9190601f8111611aa757505050565b610f90926000526020600020906020601f840160051c83019310611ad3575b601f0160051c0190611a81565b9091508190611ac6565b91909182516001600160401b03811161041757611b0481611afe8454610f1d565b84611a98565b6020601f8211600114611b45578190611b36939495600092611b3a575b50508160011b916000199060031b1c19161790565b9055565b015190503880611b21565b601f19821690611b5a84600052602060002090565b9160005b818110611b9657509583600195969710611b7d575b505050811b019055565b015160001960f88460031b161c19169055388080611b73565b9192602060018192868b015181550194019201611b5e565b81810292918115918404141715611a7c57565b815191600160401b8311610417578154838355808410611c1e575b506020611bf0910191600052602060002090565b6000915b838310611c015750505050565b6001602082611c1283945186611add565b01920192019190611bf4565b8260005283602060002091820191015b818110611c3b5750611bdc565b80611c4860019254610f1d565b80611c55575b5001611c2e565b601f81118314611c6b5750600081555b38611c4e565b611c8f9083601f611c8185600052602060002090565b920160051c82019101611a81565b60008181526020812081835555611c65565b6040513d6000823e3d90fd5b634e487b7160e01b600052603260045260246000fd5b8051821015611cd75760209160051b010190565b611cad565b805415611cd757600052602060002090600090565b8054821015611cd75760005260206000209060011b0190600090565b8054600160401b81101561041757611d2a91600182018155611cf1565b919091611d5b57805182546001600160a01b0319166001600160a01b03919091161782556020015160019190910155565b634e487b7160e01b600052600060045260246000fd5b60405190611d8060208361041c565b60008252565b6020611d9f9181604051938285809451938492016102ad565b8101600881520301902090565b805490600160401b8210156104175760018201808255821015611cd75760005260206000200155565b90611ddf8261043d565b611dec604051918261041c565b8281528092611dfd601f199161043d565b0190602036910137565b906020808351928381520192019060005b818110611e255750505090565b82516001600160a01b0316845260209384019390920191600101611e18565b93611e86611ea294611e786103069a9895611e6a611e949660e08b5260e08b0190611e07565b9089820360208b0152610783565b9087820360408901526102d0565b9085820360608701526102d0565b9083820360808501526102d0565b9260a082015260c0818403910152610696565b939291906001600160a01b0385163381141580611f31575b611f19576001600160a01b03821615611f035715611eee57610f909461259a565b626a0d4560e21b600052600060045260246000fd5b632bfa23e760e11b600052600060045260246000fd5b63711bec9160e11b6000523360045260245260446000fd5b50600081815260016020908152604080832033845290915290205460ff1615611ecd565b15611f5c57565b60405162461bcd60e51b815260206004820152601e60248201527f44617461736574206973206e6f74206c697374656420666f722073616c6500006044820152606490fd5b908160209103126101b1575190565b15611fb757565b60405162461bcd60e51b815260206004820152601860248201527f496e636f7272656374207061796d656e7420616d6f756e7400000000000000006044820152606490fd5b1561200357565b60405162461bcd60e51b81526020600482015260136024820152724f776e657220686173206e6f20746f6b656e7360681b6044820152606490fd5b3d15612069573d9061204f826104db565b9161205d604051938461041c565b82523d6000602084013e565b606090565b1561207557565b60405162461bcd60e51b815260206004820152601760248201527f5061796d656e74207472616e73666572206661696c65640000000000000000006044820152606490fd5b90916120d161030693604084526040840190611e07565b916020818403910152610783565b9190918051835180820361215a5750506120f98151611dd5565b9060005b8151811015612153578061214160019260051b60208082870101519189010151600052600060205260406000209060018060a01b0316600052602052604060002090565b5461214c8286611cc3565b52016120fd565b5090925050565b635b05999160e01b60005260045260245260446000fd5b1561217857565b60405162461bcd60e51b81526020600482015260156024820152744461746173657420686173206e6f206f776e65727360581b6044820152606490fd5b156121bc57565b60405162461bcd60e51b815260206004820152602360248201527f4f6e6c79207072696d617279206f776e65722063616e2075706461746520707260448201526269636560e81b6064820152608490fd5b6003546001600160a01b0316330361222157565b63118cdaa760e01b6000523360045260246000fd5b1561223d57565b60405162461bcd60e51b8152602060048201526015602482015274496e76616c6964206f776e6572206164647265737360581b6044820152606490fd5b91908201809211611a7c57565b1561228e57565b606460405162461bcd60e51b815260206004820152602060248201527f546f74616c2070657263656e74616765206d75737420657175616c20313030256044820152fd5b60009190825b81518410156123815760206122ed8584611cc3565b510151156123325761232a60019161231561230e610b0361175c8988611cc3565b1515612236565b60206123218786611cc3565b5101519061227a565b9301926122d8565b60405162461bcd60e51b815260206004820152602160248201527f50657263656e74616765206d7573742062652067726561746572207468616e206044820152600360fc1b6064820152608490fd5b610f90929350612710915014612287565b6001600160a01b03811692918315611f035760016123cd60405192600184526020840152604083019160018352606084015260808301604052565b9281518451908181036124de57505060005b8251811015612427578060019160051b61241f61241787610bc0602080868b010151958c010151946000526000602052604060002090565b91825461227a565b9055016123df565b5092919360018251146000146124a25760208281015184820151604080519283529282015260009133917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f629190a45b80516001036124965790602080610f90959301519101519160003361292f565b610f90936000336127fa565b60006040517f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb3391806124d688888361277b565b0390a4612476565b635b05999160e01b60005260045260245260446000fd5b9192916001600160a01b03821615611f03576001600160a01b03811615611eee576125446001610f90959160405192600184526020840152604083019160018352606084015260808301604052565b92909161259a565b92939290916001600160a01b03831615611f03576001600160a01b03821615611eee57610f909461254460405192600184526020840152604083019160018352606084015260808301604052565b94939290919384518251908181036124de5750506001600160a01b0386811695861515959185168015159391929060005b84518110156126ad578060051b90898988602080868b010151958c01015192612626575b93600194612601575b505050016125cb565b61261c91610bc0612417926000526000602052604060002090565b90553889816125f8565b505090916126428d610bc0836000526000602052604060002090565b54828110612676578291898f61266d600197968f950391610bc0856000526000602052604060002090565b559094506125ef565b6040516303dee4c560e01b81526001600160a01b038f16600482015260248101919091526044810183905260648101829052608490fd5b5091989593929790965060018851146000146127415760208881015186820151604080519283529282015233917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6291a45b61270a575b5050505050565b845160010361273057602080612726960151920151923361292f565b3880808080612703565b61273c949192336127fa565b612726565b6040517f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb339180612773898d8361277b565b0390a46126fe565b90916120d161030693604084526040840190610783565b908160209103126101b157516103068161022d565b6001600160a01b0391821681529116602082015260a06040820181905261030694919391926127ec92916127de9190860190610783565b908482036060860152610783565b9160808184039101526102d0565b9091949293853b61280e575b505050505050565b60209361283091604051968795869563bc197c8160e01b8752600487016127a7565b038160006001600160a01b0387165af1600091816128c5575b50612885575061285761203e565b805191908261287e57632bfa23e760e11b6000526001600160a01b03821660045260246000fd5b9050602001fd5b6001600160e01b0319166343e6837f60e01b016128a85750388080808080612806565b632bfa23e760e11b6000526001600160a01b031660045260246000fd5b6128e891925060203d6020116128ef575b6128e0818361041c565b810190612792565b9038612849565b503d6128d6565b6001600160a01b039182168152911660208201526040810191909152606081019190915260a060808201819052610306929101906102d0565b9091949293853b61294257505050505050565b60209361296491604051968795869563f23a6e6160e01b8752600487016128f6565b038160006001600160a01b0387165af1600091816129ae575b5061298b575061285761203e565b6001600160e01b031916630dc5919f60e01b016128a85750388080808080612806565b6129c891925060203d6020116128ef576128e0818361041c565b903861297d56fea2646970667358221220d41df3aa8aa1825e5b2593e6a90f5a8c95125657158ac8b53ace82d89cd4f1cd64736f6c634300081c0033000000000000000000000000000000000000000000000000000000000000004000000000000000000000000089fedb2167197199fd069122e5351a1c779f91b80000000000000000000000000000000000000000000000000000000000000007697066733a2f2f00000000000000000000000000000000000000000000000000", + "nonce": "0x4", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xd4965fe6110e96228abbc5f4906c13924ff0e834b9eb8c3765e94c75831396db", + "transactionType": "CREATE", + "contractName": "DatasetBondingCurve", + "contractAddress": "0x641ecbb155b8589120005de67e7abf524034ea5b", + "function": null, + "arguments": [ + "0x8C26b4c8c3D276f4a3d2AB3dD967d9d633aB08d5", + "0x89fEdB2167197199Fd069122e5351A1C779F91B8" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "gas": "0xa2e2e", + "value": "0x0", + "input": "0x60803461013857601f6108ca38819003918201601f19168301916001600160401b0383118484101761013d5780849260409485528339810103126101385761004681610153565b906001600160a01b039061005c90602001610153565b1690811561012257600080546001600160a01b031981168417825560405193916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a36001600160a01b03169081156100e05750600180546001600160a01b03191691909117905560405161076290816101688239f35b62461bcd60e51b815260206004820152601d60248201527f496e76616c6964206461746173657420746f6b656e20616464726573730000006044820152606490fd5b631e4fbdf760e01b600052600060045260246000fd5b600080fd5b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b03821682036101385756fe6080604052600436101561001257600080fd5b60003560e01c806310cee91914610621578063113990b8146105fe5780631798820f146105d25780632928a557146105a6578063715018a61461054d5780638da5cb5b14610524578063918f86741461050157806392d76ff914610444578063ae10426514610383578063afe742c31461020e578063b5713ff7146101e5578063c55d0f561461013d5763f2fde38b146100ab57600080fd5b34610138576020366003190112610138576004356001600160a01b03811690819003610138576100d9610703565b801561012257600080546001600160a01b03198116831782556001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a3005b631e4fbdf760e01b600052600060045260246000fd5b600080fd5b346101385760203660031901126101385760043580600052600260205261016a60406000205415156106b7565b60009081526002602090815260408083205460039092528220545b80831061019757602082604051908152f35b906714d1120d7b1600008102908082046714d1120d7b16000014901517156101cf57670de0b6b3a76400006001910492019190610185565b634e487b7160e01b600052601160045260246000fd5b34610138576000366003190112610138576001546040516001600160a01b039091168152602090f35b346101385760403660031901126101385760015460043590602435906001600160a01b031633036103245780156102d35781600052600260205260406000205461028e5760207f12c0ad9d517477ec2ebaa67b0e56cfad40b02e2c0769f65cfb36d38cb16a910591836000526002825280604060002055604051908152a2005b60405162461bcd60e51b815260206004820152601960248201527f496e697469616c20707269636520616c726561647920736574000000000000006044820152606490fd5b60405162461bcd60e51b8152602060048201526024808201527f496e697469616c207072696365206d75737420626520677265617465722074686044820152630616e20360e41b6064820152608490fd5b60405162461bcd60e51b815260206004820152603160248201527f4f6e6c79206461746173657420746f6b656e20636f6e74726163742063616e2060448201527073657420696e697469616c20707269636560781b6064820152608490fd5b34610138576020366003190112610138576004358060005260026020526103b060406000205415156106b7565b8060005260026020526040600020548160005260036020526040600020549160005b83811061040e57602083837fccfa5799e90149f8ab0bc1d481fdbe650f64035a2d299e17b342c119adc790ad83604051848152a2604051908152f35b916714d1120d7b1600008102908082046714d1120d7b16000014901517156101cf57670de0b6b3a76400006001910492016103d2565b3461013857602036600319011261013857600154600435906001600160a01b031633036104a35780600052600260205261048460406000205415156106b7565b60005260036020526040600020805460001981146101cf576001019055005b60405162461bcd60e51b815260206004820152603060248201527f4f6e6c79206461746173657420746f6b656e20636f6e74726163742063616e2060448201526f7265636f72642070757263686173657360801b6064820152608490fd5b34610138576000366003190112610138576020604051670de0b6b3a76400008152f35b34610138576000366003190112610138576000546040516001600160a01b039091168152602090f35b3461013857600036600319011261013857610566610703565b600080546001600160a01b0319811682556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346101385760203660031901126101385760043560005260026020526020604060002054604051908152f35b346101385760203660031901126101385760043560005260036020526020604060002054604051908152f35b346101385760003660031901126101385760206040516714d1120d7b1600008152f35b34610138576020366003190112610138576004356001600160a01b038116908190036101385761064f610703565b8015610672576bffffffffffffffffffffffff60a01b6001541617600155600080f35b60405162461bcd60e51b815260206004820152601d60248201527f496e76616c6964206461746173657420746f6b656e20616464726573730000006044820152606490fd5b156106be57565b60405162461bcd60e51b815260206004820152601b60248201527f546f6b656e20696e697469616c207072696365206e6f742073657400000000006044820152606490fd5b6000546001600160a01b0316330361071757565b63118cdaa760e01b6000523360045260246000fdfea2646970667358221220f8cac7623f68bbb045656de3dac0808d9edaf0fafaa568127cc630f5078c21bb64736f6c634300081c00330000000000000000000000008c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d500000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8", + "nonce": "0x5", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xaf2664690620643cdf51a91aa9223fe93fcf7028a7259ff7bbeaae914e464635", + "transactionType": "CALL", + "contractName": "DatasetToken", + "contractAddress": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "function": "setBondingCurve(address)", + "arguments": [ + "0x641eCbB155b8589120005dE67e7aBF524034EA5B" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "gas": "0x10e11", + "value": "0x0", + "input": "0x43ff1fb8000000000000000000000000641ecbb155b8589120005de67e7abf524034ea5b", + "nonce": "0x6", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "status": "0x1", + "cumulativeGasUsed": "0x8da5a3", + "logs": [ + { + "address": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8" + ], + "data": "0x", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "transactionHash": "0x9646f22492f77b13cacabbf5bfe2222122515b75469c174acfd95e22ed45ddd4", + "transactionIndex": "0x33", + "logIndex": "0x8b", + "removed": false + } + ], + "logsBloom": "0x00000000000001000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000400000000000000000000400000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000001000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0x9646f22492f77b13cacabbf5bfe2222122515b75469c174acfd95e22ed45ddd4", + "transactionIndex": "0x33", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "gasUsed": "0x257e67", + "effectiveGasPrice": "0xe965f", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": null, + "contractAddress": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0xb496679977", + "l1GasPrice": "0x18a2d3ea1", + "l1GasUsed": "0x1a01c" + }, + { + "status": "0x1", + "cumulativeGasUsed": "0x957af6", + "logs": [ + { + "address": "0x641ecbb155b8589120005de67e7abf524034ea5b", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8" + ], + "data": "0x", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "transactionHash": "0xd4965fe6110e96228abbc5f4906c13924ff0e834b9eb8c3765e94c75831396db", + "transactionIndex": "0x34", + "logIndex": "0x8c", + "removed": false + } + ], + "logsBloom": "0x00000000000000000000000000000000000000000000000000c00042000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000000000000000000000000400000000000000000000000000000000000000000000000000004000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0xd4965fe6110e96228abbc5f4906c13924ff0e834b9eb8c3765e94c75831396db", + "transactionIndex": "0x34", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "gasUsed": "0x7d553", + "effectiveGasPrice": "0xe965f", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": null, + "contractAddress": "0x641ecbb155b8589120005de67e7abf524034ea5b", + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0x20d56e6904", + "l1GasPrice": "0x18a2d3ea1", + "l1GasUsed": "0x4ba7" + }, + { + "status": "0x1", + "cumulativeGasUsed": "0x9633a0", + "logs": [ + { + "address": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "topics": [ + "0xc4fda5d836a9aaafabd3088c5f5dcabfe179c3b392b09dbac0e8727667f3c776", + "0x000000000000000000000000641ecbb155b8589120005de67e7abf524034ea5b" + ], + "data": "0x", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "transactionHash": "0xaf2664690620643cdf51a91aa9223fe93fcf7028a7259ff7bbeaae914e464635", + "transactionIndex": "0x35", + "logIndex": "0x8d", + "removed": false + } + ], + "logsBloom": "0x00000000000001000000000000000000000000000020000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000002000000000000000000000000000000000000000000000000080000080000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0xaf2664690620643cdf51a91aa9223fe93fcf7028a7259ff7bbeaae914e464635", + "transactionIndex": "0x35", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "gasUsed": "0xb8aa", + "effectiveGasPrice": "0xe965f", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "contractAddress": null, + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0x2b661b9f3", + "l1GasPrice": "0x18a2d3ea1", + "l1GasUsed": "0x640" + } + ], + "libraries": [], + "pending": [], + "returns": { + "1": { + "internal_type": "contract DatasetToken", + "value": "0x8C26b4c8c3D276f4a3d2AB3dD967d9d633aB08d5" + }, + "0": { + "internal_type": "contract DatasetBondingCurve", + "value": "0x641eCbB155b8589120005dE67e7aBF524034EA5B" + } + }, + "timestamp": 1739352629, + "chain": 84532, + "commit": "0c8dc77" +} \ No newline at end of file diff --git a/broadcast/DeployBondingCurve.s.sol/84532/run-latest.json b/broadcast/DeployBondingCurve.s.sol/84532/run-latest.json new file mode 100644 index 0000000..ec4c764 --- /dev/null +++ b/broadcast/DeployBondingCurve.s.sol/84532/run-latest.json @@ -0,0 +1,197 @@ +{ + "transactions": [ + { + "hash": "0x9646f22492f77b13cacabbf5bfe2222122515b75469c174acfd95e22ed45ddd4", + "transactionType": "CREATE", + "contractName": "DatasetToken", + "contractAddress": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "function": null, + "arguments": [ + "ipfs://", + "0x89fEdB2167197199Fd069122e5351A1C779F91B8" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "gas": "0x30ba3c", + "value": "0x0", + "input": "0x60806040523461028457612cc9803803806100198161029e565b9283398101906040818303126102845780516001600160401b03811161028457810182601f82011215610284578051906001600160401b03821161026e5761006a601f8301601f191660200161029e565b93828552602083830101116102845760005b82811061028957846020856000828785010152015160018060a01b0381168091036102845781516001600160401b03811161026e57600254600181811c91168015610264575b602082101461024e57601f81116101e9575b50602092601f82116001146101845792819293600092610179575b50508160011b916000199060031b1c1916176002555b801561016357600380546001600160a01b03198116831790915560405191906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a36001600455612a0590816102c48239f35b631e4fbdf760e01b600052600060045260246000fd5b0151905083806100ef565b601f198216936002600052806000209160005b8681106101d157508360019596106101b8575b505050811b01600255610105565b015160001960f88460031b161c191690558380806101aa565b91926020600181928685015181550194019201610197565b60026000527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace601f830160051c81019160208410610244575b601f0160051c01905b81811061023857506100d4565b6000815560010161022b565b9091508190610222565b634e487b7160e01b600052602260045260246000fd5b90607f16906100c2565b634e487b7160e01b600052604160045260246000fd5b600080fd5b8060208092840101518282880101520161007c565b6040519190601f01601f191682016001600160401b0381118382101761026e5760405256fe6080604052600436101561001257600080fd5b60003560e01c8062fdd58e1461019657806301ffc9a7146101915780630e89341c1461018c57806318c398fe146101875780631b45f9c5146101825780632cee94181461017d5780632eb2c2d61461017857806340398d671461017357806343ff1fb81461016e57806349ee56f9146101695780634e1273f414610164578063681ece9d1461015f5780636914db601461015a578063715018a61461015557806382367b2d1461015057806387078c561461014b5780638da5cb5b14610146578063a22cb46514610141578063e985e9c51461013c578063eff1d50e14610137578063f08b82e614610132578063f242432a1461012d578063f2fde38b146101285763fcce48831461012357600080fd5b61155c565b6114d2565b611429565b61140b565b6113e2565b611385565b6112cc565b6112a3565b611213565b61110d565b6110b0565b610ffb565b610e83565b610d81565b610aae565b610a00565b61093b565b6108b1565b6107c8565b610700565b6105b9565b610309565b61023f565b6101e0565b600435906001600160a01b03821682036101b157565b600080fd5b602435906001600160a01b03821682036101b157565b35906001600160a01b03821682036101b157565b346101b15760403660031901126101b15760206102246101fe61019b565b6024356000526000835260406000209060018060a01b0316600052602052604060002090565b54604051908152f35b6001600160e01b03198116036101b157565b346101b15760203660031901126101b157602060043561025e8161022d565b63ffffffff60e01b16636cdb3d1360e11b811490811561029c575b811561028b575b506040519015158152f35b6301ffc9a760e01b14905038610280565b6303a24d0760e21b81149150610279565b60005b8381106102c05750506000910152565b81810151838201526020016102b0565b906020916102e9815180928185528580860191016102ad565b601f01601f1916010190565b9060206103069281815201906102d0565b90565b346101b15760203660031901126101b157604051600060025461032b81610f1d565b80845290600181169081156103c25750600114610363575b61035f836103538185038261041c565b604051918291826102f5565b0390f35b600260009081527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace939250905b8082106103a857509091508101602001610353610343565b919260018160209254838588010152019101909291610390565b60ff191660208086019190915291151560051b840190910191506103539050610343565b634e487b7160e01b600052604160045260246000fd5b604081019081106001600160401b0382111761041757604052565b6103e6565b90601f801991011681019081106001600160401b0382111761041757604052565b6001600160401b0381116104175760051b60200190565b81601f820112156101b15780359061046b8261043d565b92610479604051948561041c565b82845260208085019360061b830101918183116101b157602001925b8284106104a3575050505090565b6040848303126101b157602060409182516104bd816103fc565b6104c6876101cc565b81528287013583820152815201930192610495565b6001600160401b03811161041757601f01601f191660200190565b81601f820112156101b157602081359101610510826104db565b9261051e604051948561041c565b828452828201116101b15781600092602092838601378301015290565b9080601f830112156101b15781356105528161043d565b92610560604051948561041c565b81845260208085019260051b820101918383116101b15760208201905b83821061058c57505050505090565b81356001600160401b0381116101b1576020916105ae878480948801016104f6565b81520191019061057d565b346101b15760e03660031901126101b1576004356001600160401b0381116101b1576105e9903690600401610454565b6024356001600160401b0381116101b1576106089036906004016104f6565b906044356001600160401b0381116101b1576106289036906004016104f6565b6064356001600160401b0381116101b1576106479036906004016104f6565b6084356001600160401b0381116101b1576106669036906004016104f6565b9060a4359260c435956001600160401b0387116101b15761068e61069497369060040161053b565b9561158d565b005b9080602083519182815201916020808360051b8301019401926000915b8383106106c257505050505090565b90919293946020806106e0600193601f1986820301875289516102d0565b970193019301919392906106b3565b906020610306928181520190610696565b346101b15760203660031901126101b15760043560005260066020526005604060002001805461072f8161043d565b9161073d604051938461041c565b818352602083019060005260206000206000915b838310610766576040518061035f87826106ef565b60016020819261077585610f57565b815201920192019190610751565b906020808351928381520192019060005b8181106107a15750505090565b8251845260209384019390920191600101610794565b906020610306928181520190610783565b346101b15760203660031901126101b1576004356001600160401b0381116101b1576107fb6108009136906004016104f6565b611d86565b60405190816020825491828152019160005260206000209060005b81811061083e5761035f856108328187038261041c565b604051918291826107b7565b825484526020909301926001928301920161081b565b9080601f830112156101b157813561086b8161043d565b92610879604051948561041c565b81845260208085019260051b8201019283116101b157602001905b8282106108a15750505090565b8135815260209182019101610894565b346101b15760a03660031901126101b1576108ca61019b565b6108d26101b6565b906044356001600160401b0381116101b1576108f2903690600401610854565b6064356001600160401b0381116101b157610911903690600401610854565b90608435936001600160401b0385116101b1576109356106949536906004016104f6565b93611eb5565b346101b15760203660031901126101b15761095461019b565b6005549061096182611dd5565b91600091825b8281106109b25750505061097a81611dd5565b9160005b828110610993576040518061035f86826107b7565b806109a060019284611cc3565b516109ab8287611cc3565b520161097e565b6000818152602081815260408083206001600160a01b03861684529091529020546109e0575b600101610967565b926109f881856109f260019489611cc3565b52611a6d565b9390506109d8565b346101b15760203660031901126101b157610a1961019b565b610a2161220d565b6001600160a01b03168015610a6957600980546001600160a01b031916821790557fc4fda5d836a9aaafabd3088c5f5dcabfe179c3b392b09dbac0e8727667f3c776600080a2005b60405162461bcd60e51b815260206004820152601d60248201527f496e76616c696420626f6e64696e6720637572766520616464726573730000006044820152606490fd5b60203660031901126101b157600435600260045414610d70576002600455610af2610aed610ae6836000526007602052604060002090565b5460ff1690565b611f55565b600954610b0f906001600160a01b03165b6001600160a01b031690565b6040516362ae87ab60e11b81526004810183905290602090829060249082905afa8015610d3c57610b4a91600091610d41575b503414611fb0565b610b5e816000526006602052604060002090565b600601908160005b828254821015610c21576000808080610bc0610bf5610bed6001610be48a8c610bdf610bd7859f9d610bad610c199f86610b9f91611cf1565b50546001600160a01b031690565b998a916000526000602052604060002090565b9060018060a01b0316600052602052604060002090565b541515611ffc565b611cf1565b50015434611bae565b612710900490565b90610c09610c01611d71565b8b33846124f5565b5af1610c1361203e565b5061206e565b018290610b66565b600954909150610c39906001600160a01b0316610b03565b803b156101b1576040516392d76ff960e01b815260048101839052906000908290602490829084905af18015610d3c57610d21575b50815491610c7b83611dd5565b92610c8581611dd5565b9160005b828110610cd357505050610cc67f358eaa98bb414b5fd23651427cb44fff0f7de91707aed81fcac3ad09aeebec16916040519182913396836120ba565b0390a36106946001600455565b80610cff610ce6610b9f60019486611cf1565b610cf0838a611cc3565b6001600160a01b039091169052565b610d10610bed83610be48487611cf1565b610d1a8287611cc3565b5201610c89565b80610d306000610d369361041c565b806110a5565b82610c6e565b611ca1565b610d63915060203d602011610d69575b610d5b818361041c565b810190611fa1565b38610b42565b503d610d51565b633ee5aeb560e01b60005260046000fd5b346101b15760403660031901126101b1576004356001600160401b0381116101b157366023820112156101b157806004013590610dbd8261043d565b91610dcb604051938461041c565b8083526024602084019160051b830101913683116101b157602401905b828210610e1c57836024356001600160401b0381116101b15761035f91610e16610832923690600401610854565b906120df565b60208091610e29846101cc565b815201910190610de8565b602060408183019282815284518094520192019060005b818110610e585750505090565b825180516001600160a01b031685526020908101518186015260409094019390920191600101610e4b565b346101b15760203660031901126101b157600435600052600660205260066040600020018054610eb28161043d565b91610ec0604051938461041c565b818352602083019060005260206000206000915b838310610ee9576040518061035f8782610e34565b60026020600192604051610efc816103fc565b848060a01b0386541681528486015483820152815201920192019190610ed4565b90600182811c92168015610f4d575b6020831014610f3757565b634e487b7160e01b600052602260045260246000fd5b91607f1691610f2c565b9060405191826000825492610f6b84610f1d565b8084529360018116908115610fd95750600114610f92575b50610f909250038361041c565b565b90506000929192526020600020906000915b818310610fbd575050906020610f909282010138610f83565b6020919350806001915483858901015201910190918492610fa4565b905060209250610f9094915060ff191682840152151560051b82010138610f83565b346101b15760203660031901126101b1576004356000526006602052611071604060002061102881610f57565b9061109b61103860018301610f57565b9161108d61104860028301610f57565b61107f600461105960038601610f57565b9401549560405198899860a08a5260a08a01906102d0565b9088820360208a01526102d0565b9086820360408801526102d0565b9084820360608601526102d0565b9060808301520390f35b60009103126101b157565b346101b15760003660031901126101b1576110c961220d565b600380546001600160a01b031981169091556000906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346101b15760403660031901126101b15760043560243580156111ce576111c97f945c1c4e99aa89f648fbfe3df471b916f719e16d960fcec0737d4d56bd696838916111716006611168866000526006602052604060002090565b01541515612171565b6111a0611199610b03610b9f6006611193896000526006602052604060002090565b01611cdc565b33146121b5565b8060046111b7866000526006602052604060002090565b01556040519081529081906020820190565b0390a2005b60405162461bcd60e51b815260206004820152601c60248201527f5072696365206d7573742062652067726561746572207468616e2030000000006044820152606490fd5b346101b15760203660031901126101b1576004356000818152602081815260408083203384529091529020541561125f57600052600660205261035f6103536003604060002001610f57565b606460405162461bcd60e51b815260206004820152602060248201527f43616c6c657220646f6573206e6f74206f776e207468697320646174617365746044820152fd5b346101b15760003660031901126101b1576003546040516001600160a01b039091168152602090f35b346101b15760403660031901126101b1576112e561019b565b60243590811515908183036101b1576001600160a01b038116928315611370576113316113429233600052600160205260406000209060018060a01b0316600052602052604060002090565b9060ff801983541691151516179055565b6040519081527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3160203392a3005b62ced3e160e81b600052600060045260246000fd5b346101b15760403660031901126101b157602060ff6113d66113a561019b565b6113ad6101b6565b6001600160a01b0391821660009081526001865260408082209290931681526020919091522090565b54166040519015158152f35b346101b15760003660031901126101b1576009546040516001600160a01b039091168152602090f35b346101b15760003660031901126101b1576020600554604051908152f35b346101b15760a03660031901126101b15761144261019b565b61144a6101b6565b6064356044356084356001600160401b0381116101b15761146f9036906004016104f6565b6001600160a01b0385169490939033861415806114ae575b61149557610694955061254c565b8563711bec9160e11b6000523360045260245260446000fd5b50600086815260016020908152604080832033845290915290205460ff1615611487565b346101b15760203660031901126101b1576114eb61019b565b6114f361220d565b6001600160a01b0316801561154657600380546001600160a01b0319811683179091556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3005b631e4fbdf760e01b600052600060045260246000fd5b346101b15760203660031901126101b1576004356000526007602052602060ff604060002054166040519015158152f35b96919493959261159b61220d565b6115a781511515611893565b6115b3875115156118df565b6115be851515611923565b6115ca8851151561197b565b6115d6845115156119c7565b6009546115f9906001600160a01b03906115f1908216610b03565b161515611a13565b611602886122d2565b6116536005549661161a61161589611a6d565b600555565b611637846116328a6000526006602052604060002090565b611add565b600161164d896000526006602052604060002090565b01611add565b61166d81600261164d896000526006602052604060002090565b61168787600361164d896000526006602052604060002090565b84600461169e886000526006602052604060002090565b01556116c08460056116ba896000526006602052604060002090565b01611bc1565b6009546116d5906001600160a01b0316610b03565b803b156101b15760405163afe742c360e01b81526004810188905260248101879052906000908290604490829084905af18015610d3c5761187e575b5060005b885181101561177f5760019061174c600661173a8a6000526006602052604060002090565b01611745838d611cc3565b5190611d0d565b61177961176a61175c838d611cc3565b51516001600160a01b031690565b89611773611d71565b91612392565b01611715565b509193969092949560005b86518110156117b857806117b2896117ad6117a76001958c611cc3565b51611d86565b611dac565b0161178a565b50929591949093966117e46117d7846000526007602052604060002090565b805460ff19166001179055565b6117ee8551611dd5565b936117f98651611dd5565b9660005b8751811015611843578061182361181961175c6001948c611cc3565b610cf0838b611cc3565b602061182f828b611cc3565b51015161183c828c611cc3565b52016117fd565b507f803c525550fdef50c98a15210bff07d15105fa724bd751d551511f27b0a0647b979650611879949860405197889788611e44565b0390a2565b80610d30600061188d9361041c565b38611711565b1561189a57565b60405162461bcd60e51b815260206004820152601860248201527f436f6e74656e74206861736820697320726571756972656400000000000000006044820152606490fd5b156118e657565b60405162461bcd60e51b815260206004820152601560248201527412541194c81a185cda081a5cc81c995c5d5a5c9959605a1b6044820152606490fd5b1561192a57565b60405162461bcd60e51b8152602060048201526024808201527f496e697469616c207072696365206d75737420626520677265617465722074686044820152630616e20360e41b6064820152608490fd5b1561198257565b60405162461bcd60e51b815260206004820152601b60248201527f4174206c65617374206f6e65206f776e657220726571756972656400000000006044820152606490fd5b156119ce57565b60405162461bcd60e51b815260206004820152601960248201527f4174206c65617374206f6e6520746167207265717569726564000000000000006044820152606490fd5b15611a1a57565b60405162461bcd60e51b8152602060048201526015602482015274109bdb991a5b99c818dd5c9d99481b9bdd081cd95d605a1b6044820152606490fd5b634e487b7160e01b600052601160045260246000fd5b6000198114611a7c5760010190565b611a57565b818110611a8c575050565b60008155600101611a81565b9190601f8111611aa757505050565b610f90926000526020600020906020601f840160051c83019310611ad3575b601f0160051c0190611a81565b9091508190611ac6565b91909182516001600160401b03811161041757611b0481611afe8454610f1d565b84611a98565b6020601f8211600114611b45578190611b36939495600092611b3a575b50508160011b916000199060031b1c19161790565b9055565b015190503880611b21565b601f19821690611b5a84600052602060002090565b9160005b818110611b9657509583600195969710611b7d575b505050811b019055565b015160001960f88460031b161c19169055388080611b73565b9192602060018192868b015181550194019201611b5e565b81810292918115918404141715611a7c57565b815191600160401b8311610417578154838355808410611c1e575b506020611bf0910191600052602060002090565b6000915b838310611c015750505050565b6001602082611c1283945186611add565b01920192019190611bf4565b8260005283602060002091820191015b818110611c3b5750611bdc565b80611c4860019254610f1d565b80611c55575b5001611c2e565b601f81118314611c6b5750600081555b38611c4e565b611c8f9083601f611c8185600052602060002090565b920160051c82019101611a81565b60008181526020812081835555611c65565b6040513d6000823e3d90fd5b634e487b7160e01b600052603260045260246000fd5b8051821015611cd75760209160051b010190565b611cad565b805415611cd757600052602060002090600090565b8054821015611cd75760005260206000209060011b0190600090565b8054600160401b81101561041757611d2a91600182018155611cf1565b919091611d5b57805182546001600160a01b0319166001600160a01b03919091161782556020015160019190910155565b634e487b7160e01b600052600060045260246000fd5b60405190611d8060208361041c565b60008252565b6020611d9f9181604051938285809451938492016102ad565b8101600881520301902090565b805490600160401b8210156104175760018201808255821015611cd75760005260206000200155565b90611ddf8261043d565b611dec604051918261041c565b8281528092611dfd601f199161043d565b0190602036910137565b906020808351928381520192019060005b818110611e255750505090565b82516001600160a01b0316845260209384019390920191600101611e18565b93611e86611ea294611e786103069a9895611e6a611e949660e08b5260e08b0190611e07565b9089820360208b0152610783565b9087820360408901526102d0565b9085820360608701526102d0565b9083820360808501526102d0565b9260a082015260c0818403910152610696565b939291906001600160a01b0385163381141580611f31575b611f19576001600160a01b03821615611f035715611eee57610f909461259a565b626a0d4560e21b600052600060045260246000fd5b632bfa23e760e11b600052600060045260246000fd5b63711bec9160e11b6000523360045260245260446000fd5b50600081815260016020908152604080832033845290915290205460ff1615611ecd565b15611f5c57565b60405162461bcd60e51b815260206004820152601e60248201527f44617461736574206973206e6f74206c697374656420666f722073616c6500006044820152606490fd5b908160209103126101b1575190565b15611fb757565b60405162461bcd60e51b815260206004820152601860248201527f496e636f7272656374207061796d656e7420616d6f756e7400000000000000006044820152606490fd5b1561200357565b60405162461bcd60e51b81526020600482015260136024820152724f776e657220686173206e6f20746f6b656e7360681b6044820152606490fd5b3d15612069573d9061204f826104db565b9161205d604051938461041c565b82523d6000602084013e565b606090565b1561207557565b60405162461bcd60e51b815260206004820152601760248201527f5061796d656e74207472616e73666572206661696c65640000000000000000006044820152606490fd5b90916120d161030693604084526040840190611e07565b916020818403910152610783565b9190918051835180820361215a5750506120f98151611dd5565b9060005b8151811015612153578061214160019260051b60208082870101519189010151600052600060205260406000209060018060a01b0316600052602052604060002090565b5461214c8286611cc3565b52016120fd565b5090925050565b635b05999160e01b60005260045260245260446000fd5b1561217857565b60405162461bcd60e51b81526020600482015260156024820152744461746173657420686173206e6f206f776e65727360581b6044820152606490fd5b156121bc57565b60405162461bcd60e51b815260206004820152602360248201527f4f6e6c79207072696d617279206f776e65722063616e2075706461746520707260448201526269636560e81b6064820152608490fd5b6003546001600160a01b0316330361222157565b63118cdaa760e01b6000523360045260246000fd5b1561223d57565b60405162461bcd60e51b8152602060048201526015602482015274496e76616c6964206f776e6572206164647265737360581b6044820152606490fd5b91908201809211611a7c57565b1561228e57565b606460405162461bcd60e51b815260206004820152602060248201527f546f74616c2070657263656e74616765206d75737420657175616c20313030256044820152fd5b60009190825b81518410156123815760206122ed8584611cc3565b510151156123325761232a60019161231561230e610b0361175c8988611cc3565b1515612236565b60206123218786611cc3565b5101519061227a565b9301926122d8565b60405162461bcd60e51b815260206004820152602160248201527f50657263656e74616765206d7573742062652067726561746572207468616e206044820152600360fc1b6064820152608490fd5b610f90929350612710915014612287565b6001600160a01b03811692918315611f035760016123cd60405192600184526020840152604083019160018352606084015260808301604052565b9281518451908181036124de57505060005b8251811015612427578060019160051b61241f61241787610bc0602080868b010151958c010151946000526000602052604060002090565b91825461227a565b9055016123df565b5092919360018251146000146124a25760208281015184820151604080519283529282015260009133917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f629190a45b80516001036124965790602080610f90959301519101519160003361292f565b610f90936000336127fa565b60006040517f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb3391806124d688888361277b565b0390a4612476565b635b05999160e01b60005260045260245260446000fd5b9192916001600160a01b03821615611f03576001600160a01b03811615611eee576125446001610f90959160405192600184526020840152604083019160018352606084015260808301604052565b92909161259a565b92939290916001600160a01b03831615611f03576001600160a01b03821615611eee57610f909461254460405192600184526020840152604083019160018352606084015260808301604052565b94939290919384518251908181036124de5750506001600160a01b0386811695861515959185168015159391929060005b84518110156126ad578060051b90898988602080868b010151958c01015192612626575b93600194612601575b505050016125cb565b61261c91610bc0612417926000526000602052604060002090565b90553889816125f8565b505090916126428d610bc0836000526000602052604060002090565b54828110612676578291898f61266d600197968f950391610bc0856000526000602052604060002090565b559094506125ef565b6040516303dee4c560e01b81526001600160a01b038f16600482015260248101919091526044810183905260648101829052608490fd5b5091989593929790965060018851146000146127415760208881015186820151604080519283529282015233917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6291a45b61270a575b5050505050565b845160010361273057602080612726960151920151923361292f565b3880808080612703565b61273c949192336127fa565b612726565b6040517f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb339180612773898d8361277b565b0390a46126fe565b90916120d161030693604084526040840190610783565b908160209103126101b157516103068161022d565b6001600160a01b0391821681529116602082015260a06040820181905261030694919391926127ec92916127de9190860190610783565b908482036060860152610783565b9160808184039101526102d0565b9091949293853b61280e575b505050505050565b60209361283091604051968795869563bc197c8160e01b8752600487016127a7565b038160006001600160a01b0387165af1600091816128c5575b50612885575061285761203e565b805191908261287e57632bfa23e760e11b6000526001600160a01b03821660045260246000fd5b9050602001fd5b6001600160e01b0319166343e6837f60e01b016128a85750388080808080612806565b632bfa23e760e11b6000526001600160a01b031660045260246000fd5b6128e891925060203d6020116128ef575b6128e0818361041c565b810190612792565b9038612849565b503d6128d6565b6001600160a01b039182168152911660208201526040810191909152606081019190915260a060808201819052610306929101906102d0565b9091949293853b61294257505050505050565b60209361296491604051968795869563f23a6e6160e01b8752600487016128f6565b038160006001600160a01b0387165af1600091816129ae575b5061298b575061285761203e565b6001600160e01b031916630dc5919f60e01b016128a85750388080808080612806565b6129c891925060203d6020116128ef576128e0818361041c565b903861297d56fea2646970667358221220d41df3aa8aa1825e5b2593e6a90f5a8c95125657158ac8b53ace82d89cd4f1cd64736f6c634300081c0033000000000000000000000000000000000000000000000000000000000000004000000000000000000000000089fedb2167197199fd069122e5351a1c779f91b80000000000000000000000000000000000000000000000000000000000000007697066733a2f2f00000000000000000000000000000000000000000000000000", + "nonce": "0x4", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xd4965fe6110e96228abbc5f4906c13924ff0e834b9eb8c3765e94c75831396db", + "transactionType": "CREATE", + "contractName": "DatasetBondingCurve", + "contractAddress": "0x641ecbb155b8589120005de67e7abf524034ea5b", + "function": null, + "arguments": [ + "0x8C26b4c8c3D276f4a3d2AB3dD967d9d633aB08d5", + "0x89fEdB2167197199Fd069122e5351A1C779F91B8" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "gas": "0xa2e2e", + "value": "0x0", + "input": "0x60803461013857601f6108ca38819003918201601f19168301916001600160401b0383118484101761013d5780849260409485528339810103126101385761004681610153565b906001600160a01b039061005c90602001610153565b1690811561012257600080546001600160a01b031981168417825560405193916001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a36001600160a01b03169081156100e05750600180546001600160a01b03191691909117905560405161076290816101688239f35b62461bcd60e51b815260206004820152601d60248201527f496e76616c6964206461746173657420746f6b656e20616464726573730000006044820152606490fd5b631e4fbdf760e01b600052600060045260246000fd5b600080fd5b634e487b7160e01b600052604160045260246000fd5b51906001600160a01b03821682036101385756fe6080604052600436101561001257600080fd5b60003560e01c806310cee91914610621578063113990b8146105fe5780631798820f146105d25780632928a557146105a6578063715018a61461054d5780638da5cb5b14610524578063918f86741461050157806392d76ff914610444578063ae10426514610383578063afe742c31461020e578063b5713ff7146101e5578063c55d0f561461013d5763f2fde38b146100ab57600080fd5b34610138576020366003190112610138576004356001600160a01b03811690819003610138576100d9610703565b801561012257600080546001600160a01b03198116831782556001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09080a3005b631e4fbdf760e01b600052600060045260246000fd5b600080fd5b346101385760203660031901126101385760043580600052600260205261016a60406000205415156106b7565b60009081526002602090815260408083205460039092528220545b80831061019757602082604051908152f35b906714d1120d7b1600008102908082046714d1120d7b16000014901517156101cf57670de0b6b3a76400006001910492019190610185565b634e487b7160e01b600052601160045260246000fd5b34610138576000366003190112610138576001546040516001600160a01b039091168152602090f35b346101385760403660031901126101385760015460043590602435906001600160a01b031633036103245780156102d35781600052600260205260406000205461028e5760207f12c0ad9d517477ec2ebaa67b0e56cfad40b02e2c0769f65cfb36d38cb16a910591836000526002825280604060002055604051908152a2005b60405162461bcd60e51b815260206004820152601960248201527f496e697469616c20707269636520616c726561647920736574000000000000006044820152606490fd5b60405162461bcd60e51b8152602060048201526024808201527f496e697469616c207072696365206d75737420626520677265617465722074686044820152630616e20360e41b6064820152608490fd5b60405162461bcd60e51b815260206004820152603160248201527f4f6e6c79206461746173657420746f6b656e20636f6e74726163742063616e2060448201527073657420696e697469616c20707269636560781b6064820152608490fd5b34610138576020366003190112610138576004358060005260026020526103b060406000205415156106b7565b8060005260026020526040600020548160005260036020526040600020549160005b83811061040e57602083837fccfa5799e90149f8ab0bc1d481fdbe650f64035a2d299e17b342c119adc790ad83604051848152a2604051908152f35b916714d1120d7b1600008102908082046714d1120d7b16000014901517156101cf57670de0b6b3a76400006001910492016103d2565b3461013857602036600319011261013857600154600435906001600160a01b031633036104a35780600052600260205261048460406000205415156106b7565b60005260036020526040600020805460001981146101cf576001019055005b60405162461bcd60e51b815260206004820152603060248201527f4f6e6c79206461746173657420746f6b656e20636f6e74726163742063616e2060448201526f7265636f72642070757263686173657360801b6064820152608490fd5b34610138576000366003190112610138576020604051670de0b6b3a76400008152f35b34610138576000366003190112610138576000546040516001600160a01b039091168152602090f35b3461013857600036600319011261013857610566610703565b600080546001600160a01b0319811682556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a3005b346101385760203660031901126101385760043560005260026020526020604060002054604051908152f35b346101385760203660031901126101385760043560005260036020526020604060002054604051908152f35b346101385760003660031901126101385760206040516714d1120d7b1600008152f35b34610138576020366003190112610138576004356001600160a01b038116908190036101385761064f610703565b8015610672576bffffffffffffffffffffffff60a01b6001541617600155600080f35b60405162461bcd60e51b815260206004820152601d60248201527f496e76616c6964206461746173657420746f6b656e20616464726573730000006044820152606490fd5b156106be57565b60405162461bcd60e51b815260206004820152601b60248201527f546f6b656e20696e697469616c207072696365206e6f742073657400000000006044820152606490fd5b6000546001600160a01b0316330361071757565b63118cdaa760e01b6000523360045260246000fdfea2646970667358221220f8cac7623f68bbb045656de3dac0808d9edaf0fafaa568127cc630f5078c21bb64736f6c634300081c00330000000000000000000000008c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d500000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8", + "nonce": "0x5", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xaf2664690620643cdf51a91aa9223fe93fcf7028a7259ff7bbeaae914e464635", + "transactionType": "CALL", + "contractName": "DatasetToken", + "contractAddress": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "function": "setBondingCurve(address)", + "arguments": [ + "0x641eCbB155b8589120005dE67e7aBF524034EA5B" + ], + "transaction": { + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "gas": "0x10e11", + "value": "0x0", + "input": "0x43ff1fb8000000000000000000000000641ecbb155b8589120005de67e7abf524034ea5b", + "nonce": "0x6", + "chainId": "0x14a34" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "status": "0x1", + "cumulativeGasUsed": "0x8da5a3", + "logs": [ + { + "address": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8" + ], + "data": "0x", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "transactionHash": "0x9646f22492f77b13cacabbf5bfe2222122515b75469c174acfd95e22ed45ddd4", + "transactionIndex": "0x33", + "logIndex": "0x8b", + "removed": false + } + ], + "logsBloom": "0x00000000000001000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000400000000000000000000400000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000001000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0x9646f22492f77b13cacabbf5bfe2222122515b75469c174acfd95e22ed45ddd4", + "transactionIndex": "0x33", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "gasUsed": "0x257e67", + "effectiveGasPrice": "0xe965f", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": null, + "contractAddress": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0xb496679977", + "l1GasPrice": "0x18a2d3ea1", + "l1GasUsed": "0x1a01c" + }, + { + "status": "0x1", + "cumulativeGasUsed": "0x957af6", + "logs": [ + { + "address": "0x641ecbb155b8589120005de67e7abf524034ea5b", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000089fedb2167197199fd069122e5351a1c779f91b8" + ], + "data": "0x", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "transactionHash": "0xd4965fe6110e96228abbc5f4906c13924ff0e834b9eb8c3765e94c75831396db", + "transactionIndex": "0x34", + "logIndex": "0x8c", + "removed": false + } + ], + "logsBloom": "0x00000000000000000000000000000000000000000000000000c00042000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000000000000000000000000400000000000000000000000000000000000000000000000000004000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0xd4965fe6110e96228abbc5f4906c13924ff0e834b9eb8c3765e94c75831396db", + "transactionIndex": "0x34", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "gasUsed": "0x7d553", + "effectiveGasPrice": "0xe965f", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": null, + "contractAddress": "0x641ecbb155b8589120005de67e7abf524034ea5b", + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0x20d56e6904", + "l1GasPrice": "0x18a2d3ea1", + "l1GasUsed": "0x4ba7" + }, + { + "status": "0x1", + "cumulativeGasUsed": "0x9633a0", + "logs": [ + { + "address": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "topics": [ + "0xc4fda5d836a9aaafabd3088c5f5dcabfe179c3b392b09dbac0e8727667f3c776", + "0x000000000000000000000000641ecbb155b8589120005de67e7abf524034ea5b" + ], + "data": "0x", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "transactionHash": "0xaf2664690620643cdf51a91aa9223fe93fcf7028a7259ff7bbeaae914e464635", + "transactionIndex": "0x35", + "logIndex": "0x8d", + "removed": false + } + ], + "logsBloom": "0x00000000000001000000000000000000000000000020000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000002000000000000000000000000000000000000000000000000080000080000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000", + "type": "0x2", + "transactionHash": "0xaf2664690620643cdf51a91aa9223fe93fcf7028a7259ff7bbeaae914e464635", + "transactionIndex": "0x35", + "blockHash": "0x12def35f611a2adef8aefc498d39af1f1c3873413e94c8ae1191e84a61e75a1b", + "blockNumber": "0x14c85a7", + "gasUsed": "0xb8aa", + "effectiveGasPrice": "0xe965f", + "from": "0x89fedb2167197199fd069122e5351a1c779f91b8", + "to": "0x8c26b4c8c3d276f4a3d2ab3dd967d9d633ab08d5", + "contractAddress": null, + "l1BaseFeeScalar": "0x44d", + "l1BlobBaseFee": "0x1", + "l1BlobBaseFeeScalar": "0xa118b", + "l1Fee": "0x2b661b9f3", + "l1GasPrice": "0x18a2d3ea1", + "l1GasUsed": "0x640" + } + ], + "libraries": [], + "pending": [], + "returns": { + "1": { + "internal_type": "contract DatasetToken", + "value": "0x8C26b4c8c3D276f4a3d2AB3dD967d9d633aB08d5" + }, + "0": { + "internal_type": "contract DatasetBondingCurve", + "value": "0x641eCbB155b8589120005dE67e7aBF524034EA5B" + } + }, + "timestamp": 1739352629, + "chain": 84532, + "commit": "0c8dc77" +} \ No newline at end of file diff --git a/foundry.toml b/foundry.toml index b1ebca3..0d5583a 100644 --- a/foundry.toml +++ b/foundry.toml @@ -3,5 +3,9 @@ src = "src" out = "out" libs = ["lib"] remappings = ["@openzeppelin/=lib/openzeppelin-contracts/"] +via-ir = true # See more config options https://github.com/foundry-rs/foundry/blob/master/crates/config/README.md#all-options + +[fmt] +number_underscore = "thousands" diff --git a/script/DeployBondingCurve.s.sol b/script/DeployBondingCurve.s.sol new file mode 100644 index 0000000..7ddd90a --- /dev/null +++ b/script/DeployBondingCurve.s.sol @@ -0,0 +1,34 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.18; + +import {Script} from "forge-std/Script.sol"; +import {DatasetBondingCurve} from "../src/DatasetBondingCurve.sol"; +import {DatasetToken} from "../src/DeployDataset.sol"; + +contract DeployBondingCurve is Script { + function run() external returns (DatasetBondingCurve, DatasetToken) { + uint256 deployerPrivateKey = vm.envUint("PRIVATE_KEY"); + address deployerAddress = vm.addr(deployerPrivateKey); + + vm.startBroadcast(deployerPrivateKey); + + // First deploy the DatasetToken contract + DatasetToken datasetToken = new DatasetToken( + "ipfs://", + deployerAddress + ); + + // Then deploy the BondingCurve contract + DatasetBondingCurve bondingCurve = new DatasetBondingCurve( + address(datasetToken), + deployerAddress + ); + + // Set the bonding curve in the dataset token contract + datasetToken.setBondingCurve(address(bondingCurve)); + + vm.stopBroadcast(); + + return (bondingCurve, datasetToken); + } +} diff --git a/src/DeployDataset.sol b/src/DeployDataset.sol index a9a6beb..8cbbf84 100644 --- a/src/DeployDataset.sol +++ b/src/DeployDataset.sol @@ -4,6 +4,7 @@ pragma solidity ^0.8.18; import {ERC1155} from "@openzeppelin/contracts/token/ERC1155/ERC1155.sol"; import {Ownable} from "@openzeppelin/contracts/access/Ownable.sol"; import {ReentrancyGuard} from "@openzeppelin/contracts/utils/ReentrancyGuard.sol"; +import {DatasetBondingCurve} from "./DatasetBondingCurve.sol"; contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { // Token ID counter @@ -33,6 +34,9 @@ contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { // Mapping from tag to token IDs mapping(string => uint256[]) private _tagToTokenIds; + // The Bonding Curve contract + DatasetBondingCurve public bondingCurve; + // Events event DatasetTokenMinted( address[] owners, @@ -54,6 +58,8 @@ contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { event PriceUpdated(uint256 indexed tokenId, uint256 newPrice); + event BondingCurveUpdated(address indexed newBondingCurve); + /** * @dev Constructor to initialize the contract. * @param uri The base URI for metadata. @@ -82,6 +88,16 @@ contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { require(totalPercentage == 10000, "Total percentage must equal 100%"); } + /** + * @dev Set the bonding curve contract address + * @param _bondingCurve The address of the bonding curve contract + */ + function setBondingCurve(address _bondingCurve) external onlyOwner { + require(_bondingCurve != address(0), "Invalid bonding curve address"); + bondingCurve = DatasetBondingCurve(_bondingCurve); + emit BondingCurveUpdated(_bondingCurve); + } + /** * @dev Mint a new dataset token with multiple owners */ @@ -91,14 +107,15 @@ contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { string memory description, string memory contentHash, string memory ipfsHash, - uint256 price, + uint256 initialPrice, string[] memory tags ) external onlyOwner { require(bytes(contentHash).length > 0, "Content hash is required"); require(bytes(ipfsHash).length > 0, "IPFS hash is required"); - require(price > 0, "Price must be greater than 0"); + require(initialPrice > 0, "Initial price must be greater than 0"); require(owners.length > 0, "At least one owner required"); require(tags.length > 0, "At least one tag required"); + require(address(bondingCurve) != address(0), "Bonding curve not set"); validateOwnershipShares(owners); @@ -109,9 +126,12 @@ contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { tokenMetadata[tokenId].description = description; tokenMetadata[tokenId].contentHash = contentHash; tokenMetadata[tokenId].ipfsHash = ipfsHash; - tokenMetadata[tokenId].price = price; + tokenMetadata[tokenId].price = initialPrice; tokenMetadata[tokenId].tags = tags; + // Initialize bonding curve for this token + bondingCurve.setInitialPrice(tokenId, initialPrice); + // Store ownership information for (uint256 i = 0; i < owners.length; i++) { tokenMetadata[tokenId].owners.push(owners[i]); @@ -140,7 +160,7 @@ contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { name, contentHash, ipfsHash, - price, + initialPrice, tags ); } @@ -150,10 +170,8 @@ contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { */ function purchaseDataset(uint256 tokenId) external payable nonReentrant { require(isListed[tokenId], "Dataset is not listed for sale"); - require( - msg.value == tokenMetadata[tokenId].price, - "Incorrect payment amount" - ); + uint256 currentPrice = bondingCurve.getCurrentPrice(tokenId); + require(msg.value == currentPrice, "Incorrect payment amount"); DatasetMetadata storage metadata = tokenMetadata[tokenId]; uint256 totalAmount = msg.value; @@ -175,6 +193,9 @@ contract DatasetToken is ERC1155, Ownable, ReentrancyGuard { require(success, "Payment transfer failed"); } + // Record the purchase in the bonding curve + bondingCurve.recordPurchase(tokenId); + // Prepare arrays for event address[] memory sellers = new address[](metadata.owners.length); uint256[] memory amounts = new uint256[](metadata.owners.length); diff --git a/test/DatasetBondingCurve.t.sol b/test/DatasetBondingCurve.t.sol new file mode 100644 index 0000000..53df6ef --- /dev/null +++ b/test/DatasetBondingCurve.t.sol @@ -0,0 +1,173 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.18; + +import {Test, console2} from "forge-std/Test.sol"; +import {DatasetToken} from "../src/DeployDataset.sol"; +import {DatasetBondingCurve} from "../src/DatasetBondingCurve.sol"; + +contract DatasetBondingCurveTest is Test { + DatasetBondingCurve public bondingCurve; + DatasetToken public datasetToken; + address public owner; + address public user1; + address public user2; + + // Test dataset parameters + string[] public tags; + DatasetToken.OwnershipShare[] public shares; + + function setUp() public { + owner = address(this); + user1 = makeAddr("user1"); + user2 = makeAddr("user2"); + + // Deploy DatasetToken + datasetToken = new DatasetToken("ipfs://", owner); + + // Deploy BondingCurve + bondingCurve = new DatasetBondingCurve(address(datasetToken), owner); + + // Set bonding curve in dataset token + datasetToken.setBondingCurve(address(bondingCurve)); + + // Setup test data + tags.push("AI"); + tags.push("ML"); + + // Create ownership shares + shares.push(DatasetToken.OwnershipShare(user1, 5000)); // 50% + shares.push(DatasetToken.OwnershipShare(user2, 5000)); // 50% + + vm.deal(user1, 100 ether); + vm.deal(user2, 100 ether); + } + + function test_IndependentBondingCurves() public { + vm.startPrank(owner); + + // Mint first dataset token with 0.1 ether initial price + datasetToken.mintDatasetToken( + shares, + "Dataset 1", + "Description 1", + "QmHash1", + "ipfs://QmHash1", + 0.1 ether, + tags + ); + + // Mint second dataset token with 0.2 ether initial price + datasetToken.mintDatasetToken( + shares, + "Dataset 2", + "Description 2", + "QmHash2", + "ipfs://QmHash2", + 0.2 ether, + tags + ); + + vm.stopPrank(); + + // Check initial prices + assertEq( + bondingCurve.getCurrentPrice(0), + 0.1 ether, + "First token should have 0.1 ether initial price" + ); + assertEq( + bondingCurve.getCurrentPrice(1), + 0.2 ether, + "Second token should have 0.2 ether initial price" + ); + + // Purchase first token + vm.prank(user1); + datasetToken.purchaseDataset{value: 0.1 ether}(0); + + // Check prices after purchase + assertEq( + bondingCurve.getCurrentPrice(0), + 0.15 ether, + "First token price should increase by 1.5x" + ); + assertEq( + bondingCurve.getCurrentPrice(1), + 0.2 ether, + "Second token price should remain unchanged" + ); + } + + function test_PriceIncrease() public { + vm.startPrank(owner); + + // Mint token with 0.1 ether initial price + datasetToken.mintDatasetToken( + shares, + "Dataset 1", + "Description 1", + "QmHash1", + "ipfs://QmHash1", + 0.1 ether, + tags + ); + vm.stopPrank(); + + uint256 initialPrice = bondingCurve.getCurrentPrice(0); + assertEq(initialPrice, 0.1 ether, "Initial price should be 0.1 ether"); + + // First purchase + vm.prank(user1); + datasetToken.purchaseDataset{value: 0.1 ether}(0); + + uint256 secondPrice = bondingCurve.getCurrentPrice(0); + assertEq( + secondPrice, + 0.15 ether, + "Price should increase by 1.5x after first purchase" + ); + + // Second purchase + vm.prank(user2); + datasetToken.purchaseDataset{value: 0.15 ether}(0); + + uint256 thirdPrice = bondingCurve.getCurrentPrice(0); + assertEq( + thirdPrice, + 0.225 ether, + "Price should increase by 1.5x after second purchase" + ); + } + + function test_SetBondingCurve() public { + address newBondingCurve = makeAddr("newBondingCurve"); + + vm.prank(owner); + datasetToken.setBondingCurve(newBondingCurve); + + assertEq( + address(datasetToken.bondingCurve()), + newBondingCurve, + "Bonding curve address should be updated" + ); + } + + function test_OnlyOwnerCanSetBondingCurve() public { + address newBondingCurve = makeAddr("newBondingCurve"); + + vm.prank(user1); + vm.expectRevert( + abi.encodeWithSignature( + "OwnableUnauthorizedAccount(address)", + user1 + ) + ); + datasetToken.setBondingCurve(newBondingCurve); + } + + function test_CannotSetZeroAddressBondingCurve() public { + vm.prank(owner); + vm.expectRevert("Invalid bonding curve address"); + datasetToken.setBondingCurve(address(0)); + } +} diff --git a/test/DatasetToken.t.sol b/test/DatasetToken.t.sol index 4236154..01df43f 100644 --- a/test/DatasetToken.t.sol +++ b/test/DatasetToken.t.sol @@ -1,11 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.18; -import {Test, console} from "forge-std/Test.sol"; +import {Test, console2} from "forge-std/Test.sol"; import {DatasetToken} from "../src/DeployDataset.sol"; +import {DatasetBondingCurve} from "../src/DatasetBondingCurve.sol"; contract DatasetTokenTest is Test { DatasetToken public datasetToken; + DatasetBondingCurve public bondingCurve; address public owner; address public user1; address public user2; @@ -19,6 +21,7 @@ contract DatasetTokenTest is Test { string constant IPFS_HASH = "QmTest123IPFSHash"; uint256 constant PRICE = 1 ether; string[] TAGS; + DatasetToken.OwnershipShare[] shares; function setUp() public { // Set up addresses @@ -36,22 +39,35 @@ contract DatasetTokenTest is Test { // Deploy contract vm.prank(owner); datasetToken = new DatasetToken(BASE_URI, owner); + + // Deploy and set up bonding curve + bondingCurve = new DatasetBondingCurve(address(datasetToken), owner); + vm.prank(owner); + datasetToken.setBondingCurve(address(bondingCurve)); + + // Setup test data + TAGS = new string[](3); + TAGS[0] = "AI"; + TAGS[1] = "ML"; + TAGS[2] = "Data"; + + // Create ownership shares + shares = new DatasetToken.OwnershipShare[](2); + shares[0] = DatasetToken.OwnershipShare(user1, 7000); // 70% + shares[1] = DatasetToken.OwnershipShare(user2, 3000); // 30% + + vm.deal(user1, 100 ether); + vm.deal(user2, 100 ether); } function test_InitialState() public view { assertEq(datasetToken.owner(), owner); assertEq(datasetToken.getTotalTokens(), 0); + assertEq(address(datasetToken.bondingCurve()), address(bondingCurve)); } function test_MintDatasetToken() public { - // Create ownership shares - DatasetToken.OwnershipShare[] - memory shares = new DatasetToken.OwnershipShare[](2); - shares[0] = DatasetToken.OwnershipShare(user1, 7000); // 70% - shares[1] = DatasetToken.OwnershipShare(user2, 3000); // 30% - - // Mint token as owner - vm.prank(owner); + vm.startPrank(owner); datasetToken.mintDatasetToken( shares, DATASET_NAME, @@ -61,8 +77,8 @@ contract DatasetTokenTest is Test { PRICE, TAGS ); + vm.stopPrank(); - // Verify token was minted assertEq(datasetToken.getTotalTokens(), 1); assertEq(datasetToken.balanceOf(user1, 0), 1); assertEq(datasetToken.balanceOf(user2, 0), 1); @@ -77,12 +93,7 @@ contract DatasetTokenTest is Test { function test_PurchaseDataset() public { // First mint a token - DatasetToken.OwnershipShare[] - memory shares = new DatasetToken.OwnershipShare[](2); - shares[0] = DatasetToken.OwnershipShare(user1, 7000); // 70% - shares[1] = DatasetToken.OwnershipShare(user2, 3000); // 30% - - vm.prank(owner); + vm.startPrank(owner); datasetToken.mintDatasetToken( shares, DATASET_NAME, @@ -92,14 +103,15 @@ contract DatasetTokenTest is Test { PRICE, TAGS ); + vm.stopPrank(); // Record initial balances uint256 user1InitialBalance = user1.balance; uint256 user2InitialBalance = user2.balance; - // Purchase as user3 - vm.deal(user3, PRICE); + // Purchase the token vm.prank(user3); + vm.deal(user3, PRICE); datasetToken.purchaseDataset{value: PRICE}(0); // Verify token ownership transfer @@ -114,11 +126,7 @@ contract DatasetTokenTest is Test { function test_UpdatePrice() public { // First mint a token - DatasetToken.OwnershipShare[] - memory shares = new DatasetToken.OwnershipShare[](1); - shares[0] = DatasetToken.OwnershipShare(user1, 10000); // 100% - - vm.prank(owner); + vm.startPrank(owner); datasetToken.mintDatasetToken( shares, DATASET_NAME, @@ -128,6 +136,7 @@ contract DatasetTokenTest is Test { PRICE, TAGS ); + vm.stopPrank(); // Update price as primary owner uint256 newPrice = 2 ether; @@ -141,11 +150,7 @@ contract DatasetTokenTest is Test { function testFail_UpdatePriceNonOwner() public { // First mint a token - DatasetToken.OwnershipShare[] - memory shares = new DatasetToken.OwnershipShare[](1); - shares[0] = DatasetToken.OwnershipShare(user1, 10000); // 100% - - vm.prank(owner); + vm.startPrank(owner); datasetToken.mintDatasetToken( shares, DATASET_NAME, @@ -155,6 +160,7 @@ contract DatasetTokenTest is Test { PRICE, TAGS ); + vm.stopPrank(); // Try to update price as non-owner (should fail) vm.prank(user2); @@ -162,17 +168,6 @@ contract DatasetTokenTest is Test { } function test_GetTokensByTag() public { - // First mint two tokens with different tags - DatasetToken.OwnershipShare[] - memory shares = new DatasetToken.OwnershipShare[](1); - shares[0] = DatasetToken.OwnershipShare(user1, 10000); - - string[] memory tags1 = new string[](1); - tags1[0] = "AI"; - - string[] memory tags2 = new string[](1); - tags2[0] = "ML"; - vm.startPrank(owner); datasetToken.mintDatasetToken( shares, @@ -181,27 +176,22 @@ contract DatasetTokenTest is Test { CONTENT_HASH, IPFS_HASH, PRICE, - tags1 - ); - - datasetToken.mintDatasetToken( - shares, - DATASET_NAME, - DATASET_DESC, - CONTENT_HASH, - IPFS_HASH, - PRICE, - tags2 + TAGS ); vm.stopPrank(); - // Verify tag indexing uint256[] memory aiTokens = datasetToken.getTokensByTag("AI"); uint256[] memory mlTokens = datasetToken.getTokensByTag("ML"); + uint256[] memory dataTokens = datasetToken.getTokensByTag("Data"); + + // All tags should point to the same token since we only minted one + assertEq(aiTokens.length, 1, "Should have one AI token"); + assertEq(mlTokens.length, 1, "Should have one ML token"); + assertEq(dataTokens.length, 1, "Should have one Data token"); - assertEq(aiTokens.length, 1); - assertEq(mlTokens.length, 1); - assertEq(aiTokens[0], 0); - assertEq(mlTokens[0], 1); + // All should point to token ID 0 + assertEq(aiTokens[0], 0, "AI token should be token 0"); + assertEq(mlTokens[0], 0, "ML token should be token 0"); + assertEq(dataTokens[0], 0, "Data token should be token 0"); } }