{
"cells": [
{
"cell_type": "code",
"execution_count": 2,
"metadata": {},
"outputs": [],
"source": [
"import pandas as pd\n",
"import matplotlib.pyplot as plt\n",
"import seaborn as sns\n",
"import gc"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {},
"outputs": [],
"source": [
"weekly_mech_calls = pd.read_parquet(\"../data/weekly_mech_calls.parquet\")"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {},
"outputs": [],
"source": [
"tools = pd.read_parquet(\"../tmp/tools.parquet\")"
]
},
{
"cell_type": "code",
"execution_count": 5,
"metadata": {},
"outputs": [],
"source": [
"fpmmTrades = pd.read_parquet(\"../data/fpmmTrades.parquet\")"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 8,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"Index(['request_id', 'request_block', 'prompt_request', 'tool', 'nonce',\n",
" 'trader_address', 'deliver_block', 'error', 'error_message',\n",
" 'prompt_response', 'mech_address', 'p_yes', 'p_no', 'confidence',\n",
" 'info_utility', 'vote', 'win_probability', 'market_creator', 'title',\n",
" 'currentAnswer', 'request_time', 'request_month_year',\n",
" 'request_month_year_week'],\n",
" dtype='object')"
]
},
"execution_count": 8,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"tools.columns"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"
\n",
"\n",
"
\n",
" \n",
" \n",
" | \n",
" trader_address | \n",
" month_year_week | \n",
" total_trades | \n",
" total_mech_calls | \n",
"
\n",
" \n",
" \n",
" \n",
" 0 | \n",
" 0x358e58683e54b2b1b0536727df52a001df5acdf8 | \n",
" Nov-03 | \n",
" 3 | \n",
" 45 | \n",
"
\n",
" \n",
" 1 | \n",
" 0x358e58683e54b2b1b0536727df52a001df5acdf8 | \n",
" Nov-10 | \n",
" 10 | \n",
" 33 | \n",
"
\n",
" \n",
" 2 | \n",
" 0x358e58683e54b2b1b0536727df52a001df5acdf8 | \n",
" Nov-17 | \n",
" 10 | \n",
" 22 | \n",
"
\n",
" \n",
" 3 | \n",
" 0x358e58683e54b2b1b0536727df52a001df5acdf8 | \n",
" Nov-24 | \n",
" 35 | \n",
" 40 | \n",
"
\n",
" \n",
" 4 | \n",
" 0x358e58683e54b2b1b0536727df52a001df5acdf8 | \n",
" Dec-01 | \n",
" 6 | \n",
" 11 | \n",
"
\n",
" \n",
"
\n",
"
"
],
"text/plain": [
" trader_address month_year_week total_trades \\\n",
"0 0x358e58683e54b2b1b0536727df52a001df5acdf8 Nov-03 3 \n",
"1 0x358e58683e54b2b1b0536727df52a001df5acdf8 Nov-10 10 \n",
"2 0x358e58683e54b2b1b0536727df52a001df5acdf8 Nov-17 10 \n",
"3 0x358e58683e54b2b1b0536727df52a001df5acdf8 Nov-24 35 \n",
"4 0x358e58683e54b2b1b0536727df52a001df5acdf8 Dec-01 6 \n",
"\n",
" total_mech_calls \n",
"0 45 \n",
"1 33 \n",
"2 22 \n",
"3 40 \n",
"4 11 "
]
},
"execution_count": 4,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"weekly_mech_calls.head()"
]
},
{
"cell_type": "code",
"execution_count": 5,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"\n",
"\n",
"
\n",
" \n",
" \n",
" | \n",
" trader_address | \n",
" month_year_week | \n",
" total_trades | \n",
" total_mech_calls | \n",
"
\n",
" \n",
" \n",
" \n",
" 7573 | \n",
" 0x5992ba3c19482e899521a0422132895d97a12f0c | \n",
" Dec-01 | \n",
" 0 | \n",
" 0 | \n",
"
\n",
" \n",
" 7574 | \n",
" 0x5992ba3c19482e899521a0422132895d97a12f0c | \n",
" Dec-08 | \n",
" 0 | \n",
" 0 | \n",
"
\n",
" \n",
" 7575 | \n",
" 0x5992ba3c19482e899521a0422132895d97a12f0c | \n",
" Dec-15 | \n",
" 0 | \n",
" 0 | \n",
"
\n",
" \n",
" 7576 | \n",
" 0x5992ba3c19482e899521a0422132895d97a12f0c | \n",
" Dec-22 | \n",
" 0 | \n",
" 0 | \n",
"
\n",
" \n",
" 7577 | \n",
" 0x5992ba3c19482e899521a0422132895d97a12f0c | \n",
" Dec-29 | \n",
" 1 | \n",
" 21 | \n",
"
\n",
" \n",
"
\n",
"
"
],
"text/plain": [
" trader_address month_year_week \\\n",
"7573 0x5992ba3c19482e899521a0422132895d97a12f0c Dec-01 \n",
"7574 0x5992ba3c19482e899521a0422132895d97a12f0c Dec-08 \n",
"7575 0x5992ba3c19482e899521a0422132895d97a12f0c Dec-15 \n",
"7576 0x5992ba3c19482e899521a0422132895d97a12f0c Dec-22 \n",
"7577 0x5992ba3c19482e899521a0422132895d97a12f0c Dec-29 \n",
"\n",
" total_trades total_mech_calls \n",
"7573 0 0 \n",
"7574 0 0 \n",
"7575 0 0 \n",
"7576 0 0 \n",
"7577 1 21 "
]
},
"execution_count": 5,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"weekly_mech_calls.tail()"
]
},
{
"cell_type": "code",
"execution_count": 6,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"count 7578.000000\n",
"mean 106.832014\n",
"std 157.655569\n",
"min 0.000000\n",
"25% 0.000000\n",
"50% 12.000000\n",
"75% 244.000000\n",
"max 795.000000\n",
"Name: total_mech_calls, dtype: float64"
]
},
"execution_count": 6,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"weekly_mech_calls.total_mech_calls.describe()"
]
}
],
"metadata": {
"kernelspec": {
"display_name": "hf_dashboards",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.12.2"
}
},
"nbformat": 4,
"nbformat_minor": 2
}