<commit_before>
#include "BlockChain.hpp"

using namespace Eth;


int main()
{
    Provider provider("ipc://home/vic/.ethereum/geth.ipc");
    BlockChain blockchain(provider);

    uint64_t id = blockchain.setNewFilter("0x580992b51e3925e23280efb93d3047c82f17e038");
    std::cout<<"filter id "<<id<<"\n";
    
    Collection<TransactionEvent> events = blockchain.getEvents(id);
    
    std::cout<<"events ("<<events.size()<<") : \n";
    
    for(Collection<TransactionEvent>::Iterator it = events.begin(), end= events.end(); it!= end; ++it)
    {
        std::cout<<"type: "<<it->getType()<<", transaction "<<it->getTransactionHash()<<" ("<<it->getTransactionIndex()<<") "<<" block "<<it->getBlockHash()<<" ("<<it->getBlockIndex()<<") \n";
    }

    return 0;
}
<commit_msg>using FilterLog<commit_after>
#include "BlockChain.hpp"

using namespace Eth;


int main()
{
    Provider provider("ipc://home/vic/.ethereum/geth.ipc");
    BlockChain blockchain(provider);

    uint64_t id = blockchain.setNewFilter("0x1194e966965418c7d73a42cceeb254d875860356", 1);
    std::cout<<"filter id "<<id<<"\n";

    sleep(2);
    Collection<FilterLog> events = blockchain.getFilterChanges(id);
    
    std::cout<<"events ("<<events.size()<<") : \n";
    
    for(Collection<FilterLog>::Iterator it = events.begin(), end= events.end(); it!= end; ++it)
    {
        std::cout<<"type: "<<it->getType()<<", transaction "<<it->getTransactionHash()<<" ("<<it->getTransactionIndex()<<") "<<" block "<<it->getBlockHash()<<" ("<<it->getBlockIndex()<<") \n";
    }

    return 0;
}

{'fraction_non_alphanumeric': 0.2176696542893726, 'fraction_numerical': 0.04481434058898848, 'mean_word_length': 4.465034965034965, 'pattern_counts': {'":': 0, '<': 79, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6916855', 'n_tokens_mistral': 595, 'n_tokens_neox': 541, 'n_words': 89}