Welcome to the Credmark Model Framework documentation!
Credmark Model Framework is a Python library building models that run on the Credmark Data Platform.
This site gives you some deep technical details of the CMF and its components. For an introduction and simple how-to-guide, please head over to the Github Readme for the CMF.
Note
This project is under active development.
Contents
- CLI credmark-dev
- Model Framework Core Components
- Error handling
- Testing Models
- Framework Reference
- credmark
- credmark.cmf
- credmark.cmf.ipython
- credmark.cmf.ipython.create_cmf
- credmark.cmf.ipython.create_cmf_context
- credmark.cmf.ipython.load_ipython_extension
- credmark.cmf.ipython.load_module_items
- credmark.cmf.ipython.CmfInit
- credmark.cmf.ipython.CredmarkMagic
CredmarkMagic
CredmarkMagic.add_traits()
CredmarkMagic.arg_err()
CredmarkMagic.class_config_rst_doc()
CredmarkMagic.class_config_section()
CredmarkMagic.class_get_help()
CredmarkMagic.class_get_trait_help()
CredmarkMagic.class_own_trait_events()
CredmarkMagic.class_own_traits()
CredmarkMagic.class_print_help()
CredmarkMagic.class_trait_names()
CredmarkMagic.class_traits()
CredmarkMagic.cross_validation_lock
CredmarkMagic.default_option()
CredmarkMagic.format_latex()
CredmarkMagic.has_trait()
CredmarkMagic.hold_trait_notifications()
CredmarkMagic.notify_change()
CredmarkMagic.observe()
CredmarkMagic.on_trait_change()
CredmarkMagic.parse_options()
CredmarkMagic.section_names()
CredmarkMagic.set_trait()
CredmarkMagic.trait_defaults()
CredmarkMagic.trait_events()
CredmarkMagic.trait_has_value()
CredmarkMagic.trait_metadata()
CredmarkMagic.trait_names()
CredmarkMagic.trait_values()
CredmarkMagic.traits()
CredmarkMagic.unobserve()
CredmarkMagic.unobserve_all()
CredmarkMagic.update_config()
- credmark.cmf.model
- credmark.cmf.model.create_error_schema_for_error_descs
- credmark.cmf.model.validate_model_slug
- credmark.cmf.model.BaseModel
- credmark.cmf.model.ImmutableModel
- credmark.cmf.model.IncrementalModel
- credmark.cmf.model.Model
- credmark.cmf.model.ModelDataErrorDesc
- credmark.cmf.model.ModelErrorDesc
- credmark.cmf.model.InvalidModelCacheKey
- credmark.cmf.model.InvalidModelSlug
- credmark.cmf.model.MissingModelBaseClass
- credmark.cmf.model.WrongModelMethodSignature
- credmark.cmf.model.context
- credmark.cmf.model.context.ModelContext
ModelContext
ModelContext.block_number
ModelContext.chain_id
ModelContext.current_context()
ModelContext.fork()
ModelContext.get_current_context()
ModelContext.historical
ModelContext.ledger
ModelContext.models
ModelContext.network
ModelContext.reset_current_context()
ModelContext.run_model()
ModelContext.set_current_context()
ModelContext.web3
ModelContext.web3_async
ModelContext.web3_batch
- credmark.cmf.model.context.ModelContext
- credmark.cmf.model.errors
- credmark.cmf.model.errors.create_instance_from_error_dict
- credmark.cmf.model.errors.MaxModelRunDepthError
- credmark.cmf.model.errors.ModelBaseError
- credmark.cmf.model.errors.ModelDataError
- credmark.cmf.model.errors.ModelDefinitionError
- credmark.cmf.model.errors.ModelEngineError
- credmark.cmf.model.errors.ModelInputError
- credmark.cmf.model.errors.ModelInvalidStateError
- credmark.cmf.model.errors.ModelNoContextError
- credmark.cmf.model.errors.ModelNotFoundError
- credmark.cmf.model.errors.ModelOutputError
- credmark.cmf.model.errors.ModelRunError
- credmark.cmf.model.errors.ModelTypeError
- credmark.cmf.model.errors.ModelCallStackEntry
- credmark.cmf.model.errors.ModelDataErrorDTO
- credmark.cmf.model.errors.ModelErrorDTO
- credmark.cmf.model.errors.ModelNotFoundErrorDTO
- credmark.cmf.model.errors.SlugAndVersionDTO
- credmark.cmf.model.ledger
- credmark.cmf.model.ledger.ledger_table_doc
- credmark.cmf.model.ledger.Ledger
- credmark.cmf.model.ledger.LedgerQueryBlock
- credmark.cmf.model.ledger.LedgerQueryContract
- credmark.cmf.model.ledger.LedgerQueryLog
- credmark.cmf.model.ledger.LedgerQueryReceipt
- credmark.cmf.model.ledger.LedgerQueryTable
- credmark.cmf.model.ledger.LedgerQueryToken
- credmark.cmf.model.ledger.LedgerQueryTokenBalance
- credmark.cmf.model.ledger.LedgerQueryTokenTransfer
- credmark.cmf.model.ledger.LedgerQueryTrace
- credmark.cmf.model.ledger.LedgerQueryTransaction
- credmark.cmf.model.models
- credmark.cmf.model.print
- credmark.cmf.model.template
- credmark.cmf.model.utils
- credmark.cmf.types
- credmark.cmf.types.abi
- credmark.cmf.types.account
- credmark.cmf.types.address
- credmark.cmf.types.adt
- credmark.cmf.types.block_number
- credmark.cmf.types.compose
- credmark.cmf.types.compose.MapBlockResult
- credmark.cmf.types.compose.MapBlockTimeSeriesInput
- credmark.cmf.types.compose.MapBlockTimeSeriesOutput
MapBlockTimeSeriesOutput
MapBlockTimeSeriesOutput.endTimestamp
MapBlockTimeSeriesOutput.exclusive
MapBlockTimeSeriesOutput.interval
MapBlockTimeSeriesOutput.results
MapBlockTimeSeriesOutput.append()
MapBlockTimeSeriesOutput.extend()
MapBlockTimeSeriesOutput.get()
MapBlockTimeSeriesOutput.to_dataframe()
MapBlockTimeSeriesOutput.to_list()
- credmark.cmf.types.compose.MapBlocksInput
- credmark.cmf.types.compose.MapBlocksOutput
- credmark.cmf.types.compose.MapInputsInput
- credmark.cmf.types.compose.MapInputsOutput
- credmark.cmf.types.compose.MapInputsResult
- credmark.cmf.types.contract
- credmark.cmf.types.contract.get_slot_proxy_address
- credmark.cmf.types.contract.Contract
Contract
Contract.address
Contract.ContractMetaData
Contract.ContractMetaData.abi
Contract.ContractMetaData.abi_hash
Contract.ContractMetaData.constructor_args
Contract.ContractMetaData.contract_name
Contract.ContractMetaData.deploy_tx_hash
Contract.ContractMetaData.deployed_block_number
Contract.ContractMetaData.is_transparent_proxy
Contract.ContractMetaData.proxy_implementation
Contract.fetch_events()
Contract.set_abi()
Contract.to_accounts()
Contract.validate()
Contract.abi
Contract.constructor_args
Contract.contract_name
Contract.deploy_tx_hash
Contract.deployed_block_number
Contract.events
Contract.functions
Contract.info
Contract.instance
Contract.is_transparent_proxy
Contract.ledger
Contract.models
Contract.proxy_for
- credmark.cmf.types.contract.ContractInfo
ContractInfo
ContractInfo.address
ContractInfo.meta
ContractInfo.ContractMetaData
ContractInfo.ContractMetaData.abi
ContractInfo.ContractMetaData.abi_hash
ContractInfo.ContractMetaData.constructor_args
ContractInfo.ContractMetaData.contract_name
ContractInfo.ContractMetaData.deploy_tx_hash
ContractInfo.ContractMetaData.deployed_block_number
ContractInfo.ContractMetaData.is_transparent_proxy
ContractInfo.ContractMetaData.proxy_implementation
ContractInfo.fetch_events()
ContractInfo.set_abi()
ContractInfo.to_accounts()
ContractInfo.validate()
ContractInfo.abi
ContractInfo.constructor_args
ContractInfo.contract_name
ContractInfo.deploy_tx_hash
ContractInfo.deployed_block_number
ContractInfo.events
ContractInfo.functions
ContractInfo.info
ContractInfo.instance
ContractInfo.is_transparent_proxy
ContractInfo.ledger
ContractInfo.models
ContractInfo.proxy_for
- credmark.cmf.types.contract.Contracts
- credmark.cmf.types.contract_web3
- credmark.cmf.types.fiat_currency
- credmark.cmf.types.ledger
- credmark.cmf.types.ledger.BlockTable
BlockTable
BlockTable.BASE_FEE_PER_GAS
BlockTable.DIFFICULTY
BlockTable.EXTRA_DATA
BlockTable.GAS_LIMIT
BlockTable.GAS_USED
BlockTable.HASH
BlockTable.LOGS_BLOOM
BlockTable.MINER
BlockTable.NONCE
BlockTable.NUMBER
BlockTable.PARENT_HASH
BlockTable.RECEIPTS_ROOT
BlockTable.SHA3_UNCLES
BlockTable.SIZE
BlockTable.STATE_ROOT
BlockTable.TIMESTAMP
BlockTable.TOTAL_DIFFICULTY
BlockTable.TRANSACTIONS_ROOT
BlockTable.TRANSACTION_COUNT
BlockTable.colnames
BlockTable.columns
- credmark.cmf.types.ledger.ColumnField
- credmark.cmf.types.ledger.ContractTable
- credmark.cmf.types.ledger.JoinType
- credmark.cmf.types.ledger.LedgerTable
- credmark.cmf.types.ledger.LogTable
- credmark.cmf.types.ledger.ReceiptTable
ReceiptTable
ReceiptTable.BLOCK_HASH
ReceiptTable.BLOCK_NUMBER
ReceiptTable.BLOCK_TIMESTAMP
ReceiptTable.CONTRACT_ADDRESS
ReceiptTable.CUMULATIVE_GAS_USED
ReceiptTable.EFFECTIVE_GAS_PRICE
ReceiptTable.GAS_USED
ReceiptTable.ROOT
ReceiptTable.STATUS
ReceiptTable.TRANSACTION_HASH
ReceiptTable.TRANSACTION_INDEX
ReceiptTable.colnames
ReceiptTable.columns
- credmark.cmf.types.ledger.TokenBalanceTable
TokenBalanceTable
TokenBalanceTable.ADDRESS
TokenBalanceTable.AMOUNT
TokenBalanceTable.BLOCK_HASH
TokenBalanceTable.BLOCK_NUMBER
TokenBalanceTable.BLOCK_TIMESTAMP
TokenBalanceTable.COUNTERPARTY_ADDRESS
TokenBalanceTable.LOG_INDEX
TokenBalanceTable.RAW_AMOUNT
TokenBalanceTable.TOKEN_ADDRESS
TokenBalanceTable.TRANSACTION_HASH
TokenBalanceTable.colnames
TokenBalanceTable.columns
- credmark.cmf.types.ledger.TokenTable
- credmark.cmf.types.ledger.TokenTransferTable
TokenTransferTable
TokenTransferTable.BLOCK_HASH
TokenTransferTable.BLOCK_NUMBER
TokenTransferTable.BLOCK_TIMESTAMP
TokenTransferTable.FROM_ADDRESS
TokenTransferTable.LOG_INDEX
TokenTransferTable.RAW_AMOUNT
TokenTransferTable.TOKEN_ADDRESS
TokenTransferTable.TO_ADDRESS
TokenTransferTable.TRANSACTION_HASH
TokenTransferTable.USD_AMOUNT
TokenTransferTable.colnames
TokenTransferTable.columns
- credmark.cmf.types.ledger.TraceTable
TraceTable
TraceTable.BLOCK_HASH
TraceTable.BLOCK_NUMBER
TraceTable.BLOCK_TIMESTAMP
TraceTable.CALL_TYPE
TraceTable.ERROR
TraceTable.FROM_ADDRESS
TraceTable.GAS
TraceTable.INPUT
TraceTable.OUTPUT
TraceTable.REWARD_TYPE
TraceTable.STATUS
TraceTable.TO_ADDRESS
TraceTable.TRACE_ADDRESS
TraceTable.TRACE_ID
TraceTable.TRACE_TYPE
TraceTable.TRANSACTION_HASH
TraceTable.TRANSACTION_INDEX
TraceTable.VALUE
TraceTable.colnames
TraceTable.columns
- credmark.cmf.types.ledger.TransactionTable
TransactionTable
TransactionTable.BLOCK_HASH
TransactionTable.BLOCK_NUMBER
TransactionTable.BLOCK_TIMESTAMP
TransactionTable.FROM_ADDRESS
TransactionTable.GAS
TransactionTable.GAS_PRICE
TransactionTable.HASH
TransactionTable.INPUT
TransactionTable.MAX_FEE_PER_GAS
TransactionTable.MAX_PRIORITY_FEE_PER_GAS
TransactionTable.NONCE
TransactionTable.TO_ADDRESS
TransactionTable.TRANSACTION_INDEX
TransactionTable.TRANSACTION_TYPE
TransactionTable.VALUE
TransactionTable.colnames
TransactionTable.columns
- credmark.cmf.types.ledger.LedgerAggregate
- credmark.cmf.types.ledger.LedgerJoin
- credmark.cmf.types.ledger.LedgerModelOutput
- credmark.cmf.types.ledger.BlockTable
- credmark.cmf.types.ledger_contract
- credmark.cmf.types.ledger_contract.ContractEntityFactory
- credmark.cmf.types.ledger_contract.ContractEntityQuery
- credmark.cmf.types.ledger_contract.ContractEntityType
- credmark.cmf.types.ledger_contract.ContractEventsTable
- credmark.cmf.types.ledger_contract.ContractFunctionsTable
- credmark.cmf.types.ledger_contract.ContractLedger
- credmark.cmf.types.ledger_contract.LedgerQueryContractEvents
- credmark.cmf.types.ledger_contract.LedgerQueryContractFunctions
- credmark.cmf.types.ledger_errors
- credmark.cmf.types.ledger_query
- credmark.cmf.types.ledger_series
- credmark.cmf.types.network
- credmark.cmf.types.portfolio
- credmark.cmf.types.position
- credmark.cmf.types.price
- credmark.cmf.types.rpc
- credmark.cmf.types.series
- credmark.cmf.types.token_erc20
- credmark.cmf.types.token_erc20.get_token_from_configuration
- credmark.cmf.types.token_erc20.NativeToken
NativeToken
NativeToken.address
NativeToken.ContractMetaData
NativeToken.ContractMetaData.abi
NativeToken.ContractMetaData.abi_hash
NativeToken.ContractMetaData.constructor_args
NativeToken.ContractMetaData.contract_name
NativeToken.ContractMetaData.deploy_tx_hash
NativeToken.ContractMetaData.deployed_block_number
NativeToken.ContractMetaData.is_transparent_proxy
NativeToken.ContractMetaData.proxy_implementation
NativeToken.TokenMetadata
NativeToken.TokenMetadata.abi
NativeToken.TokenMetadata.abi_hash
NativeToken.TokenMetadata.constructor_args
NativeToken.TokenMetadata.contract_name
NativeToken.TokenMetadata.decimals
NativeToken.TokenMetadata.deploy_tx_hash
NativeToken.TokenMetadata.deployed_block_number
NativeToken.TokenMetadata.is_transparent_proxy
NativeToken.TokenMetadata.name
NativeToken.TokenMetadata.proxy_implementation
NativeToken.TokenMetadata.set_loaded
NativeToken.TokenMetadata.symbol
NativeToken.TokenMetadata.total_supply
NativeToken.TokenMetadata.wrapped
NativeToken.TokenMetadata.get_cache()
NativeToken.TokenMetadata.update_cache()
NativeToken.as_erc20()
NativeToken.balance_of()
NativeToken.balance_of_scaled()
NativeToken.fetch_events()
NativeToken.scaled()
NativeToken.set_abi()
NativeToken.to_accounts()
NativeToken.try_erc20_property()
NativeToken.unscaled()
NativeToken.validate()
NativeToken.wrapped()
NativeToken.abi
NativeToken.constructor_args
NativeToken.contract_name
NativeToken.decimals
NativeToken.deploy_tx_hash
NativeToken.deployed_block_number
NativeToken.events
NativeToken.fiat
NativeToken.functions
NativeToken.info
NativeToken.instance
NativeToken.is_transparent_proxy
NativeToken.ledger
NativeToken.models
NativeToken.name
NativeToken.proxy_for
NativeToken.symbol
NativeToken.total_supply
NativeToken.total_supply_scaled
- credmark.cmf.types.token_erc20.Token
Token
Token.address
Token.ContractMetaData
Token.ContractMetaData.abi
Token.ContractMetaData.abi_hash
Token.ContractMetaData.constructor_args
Token.ContractMetaData.contract_name
Token.ContractMetaData.deploy_tx_hash
Token.ContractMetaData.deployed_block_number
Token.ContractMetaData.is_transparent_proxy
Token.ContractMetaData.proxy_implementation
Token.TokenMetadata
Token.TokenMetadata.abi
Token.TokenMetadata.abi_hash
Token.TokenMetadata.constructor_args
Token.TokenMetadata.contract_name
Token.TokenMetadata.decimals
Token.TokenMetadata.deploy_tx_hash
Token.TokenMetadata.deployed_block_number
Token.TokenMetadata.is_transparent_proxy
Token.TokenMetadata.name
Token.TokenMetadata.proxy_implementation
Token.TokenMetadata.set_loaded
Token.TokenMetadata.symbol
Token.TokenMetadata.total_supply
Token.TokenMetadata.wrapped
Token.TokenMetadata.get_cache()
Token.TokenMetadata.update_cache()
Token.as_erc20()
Token.balance_of()
Token.balance_of_scaled()
Token.fetch_events()
Token.scaled()
Token.set_abi()
Token.to_accounts()
Token.try_erc20_property()
Token.unscaled()
Token.validate()
Token.abi
Token.constructor_args
Token.contract_name
Token.decimals
Token.deploy_tx_hash
Token.deployed_block_number
Token.events
Token.fiat
Token.functions
Token.info
Token.instance
Token.is_transparent_proxy
Token.ledger
Token.models
Token.name
Token.proxy_for
Token.symbol
Token.total_supply
Token.total_supply_scaled
- credmark.cmf.types.token_erc20.TokenInfo
TokenInfo
TokenInfo.address
TokenInfo.meta
TokenInfo.ContractMetaData
TokenInfo.ContractMetaData.abi
TokenInfo.ContractMetaData.abi_hash
TokenInfo.ContractMetaData.constructor_args
TokenInfo.ContractMetaData.contract_name
TokenInfo.ContractMetaData.deploy_tx_hash
TokenInfo.ContractMetaData.deployed_block_number
TokenInfo.ContractMetaData.is_transparent_proxy
TokenInfo.ContractMetaData.proxy_implementation
TokenInfo.TokenMetadata
TokenInfo.TokenMetadata.abi
TokenInfo.TokenMetadata.abi_hash
TokenInfo.TokenMetadata.constructor_args
TokenInfo.TokenMetadata.contract_name
TokenInfo.TokenMetadata.decimals
TokenInfo.TokenMetadata.deploy_tx_hash
TokenInfo.TokenMetadata.deployed_block_number
TokenInfo.TokenMetadata.is_transparent_proxy
TokenInfo.TokenMetadata.name
TokenInfo.TokenMetadata.proxy_implementation
TokenInfo.TokenMetadata.set_loaded
TokenInfo.TokenMetadata.symbol
TokenInfo.TokenMetadata.total_supply
TokenInfo.TokenMetadata.wrapped
TokenInfo.TokenMetadata.get_cache()
TokenInfo.TokenMetadata.update_cache()
TokenInfo.as_erc20()
TokenInfo.balance_of()
TokenInfo.balance_of_scaled()
TokenInfo.fetch_events()
TokenInfo.scaled()
TokenInfo.set_abi()
TokenInfo.to_accounts()
TokenInfo.try_erc20_property()
TokenInfo.unscaled()
TokenInfo.validate()
TokenInfo.abi
TokenInfo.constructor_args
TokenInfo.contract_name
TokenInfo.decimals
TokenInfo.deploy_tx_hash
TokenInfo.deployed_block_number
TokenInfo.events
TokenInfo.fiat
TokenInfo.functions
TokenInfo.info
TokenInfo.instance
TokenInfo.is_transparent_proxy
TokenInfo.ledger
TokenInfo.models
TokenInfo.name
TokenInfo.proxy_for
TokenInfo.symbol
TokenInfo.total_supply
TokenInfo.total_supply_scaled
- credmark.cmf.types.token_erc20.Tokens
- credmark.cmf.types.token_erc721
- credmark.cmf.types.token_erc721.NonFungibleToken
NonFungibleToken
NonFungibleToken.address
NonFungibleToken.ContractMetaData
NonFungibleToken.ContractMetaData.abi
NonFungibleToken.ContractMetaData.abi_hash
NonFungibleToken.ContractMetaData.constructor_args
NonFungibleToken.ContractMetaData.contract_name
NonFungibleToken.ContractMetaData.deploy_tx_hash
NonFungibleToken.ContractMetaData.deployed_block_number
NonFungibleToken.ContractMetaData.is_transparent_proxy
NonFungibleToken.ContractMetaData.proxy_implementation
NonFungibleToken.fetch_events()
NonFungibleToken.set_abi()
NonFungibleToken.to_accounts()
NonFungibleToken.validate()
NonFungibleToken.abi
NonFungibleToken.constructor_args
NonFungibleToken.contract_name
NonFungibleToken.deploy_tx_hash
NonFungibleToken.deployed_block_number
NonFungibleToken.events
NonFungibleToken.functions
NonFungibleToken.info
NonFungibleToken.instance
NonFungibleToken.is_transparent_proxy
NonFungibleToken.ledger
NonFungibleToken.models
NonFungibleToken.proxy_for
- credmark.cmf.types.token_erc721.NonFungibleToken
- credmark.cmf.types.token_wei
- credmark.cmf.ipython
- credmark.dto
- credmark.dto.DTOTypesTuple
- credmark.dto.fixstr
- credmark.dto.DTOPretty
- credmark.dto.FloatDTO
- credmark.dto.HexStr
- credmark.dto.IntDTO
- credmark.dto.StrDTO
- credmark.dto.EmptyInput
- credmark.dto.EmptyInputSkipTest
- credmark.dto.IterableListGenericDTO
- credmark.dto.dto_error_schema
- credmark.dto.dto_schema
- credmark.dto.encoder
- credmark.dto.transform
- credmark.cmf
- credmark
- Credmark SDK (Python)