codex-usage-tracking 0.17.0__tar.gz → 0.17.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/.codex-plugin/plugin.json +1 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/AGENTS.md +4 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/CHANGELOG.md +8 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/PKG-INFO +3 -2
- codex_usage_tracking-0.17.2/docs/agent-maintainer-guidance.md +35 -0
- codex_usage_tracking-0.17.2/docs/agent-maintainer-hardening-branch-roadmap.md +116 -0
- codex_usage_tracking-0.17.2/docs/architecture/decisions/0002-explicit-tach-module-inventory.md +19 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/development.md +2 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/one-dot-oh-readiness.md +8 -8
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/pricing-and-credits.md +4 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/usage-drain-modeling.md +1 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/pyproject.toml +46 -29
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/scripts/benchmark_synthetic_history.py +20 -14
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/scripts/check_release.py +25 -16
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/scripts/generate_social_preview.py +52 -15
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/scripts/install_local_plugin.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/scripts/model_usage_drain.py +62 -149
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/scripts/smoke_installed_package.py +9 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/skills/codex-usage-tracker/scripts/run_mcp.py +2 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/__init__.py +1 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/allowance_intelligence/model.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/allowance_intelligence/reports.py +5 -14
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/dashboard.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/main.py +8 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/mcp_server.py +138 -53
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/parser.py +27 -11
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/parser_diagnostics.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/api.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/loader.py +2 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/reader.py +14 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/call_origin.py +3 -12
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/formatting.py +3 -10
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/i18n.py +5 -4
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/json_contract_cli.py +193 -193
- codex_usage_tracking-0.17.2/src/codex_usage_tracker/core/json_contract_diagnostics.py +185 -0
- codex_usage_tracking-0.17.2/src/codex_usage_tracker/core/json_contract_server.py +126 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/json_contract_validation.py +1 -4
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/projects.py +6 -4
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/schema.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/dashboard/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/dashboard/api.py +1 -19
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/dashboard/assets.py +8 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/action_hints.py +6 -18
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/api.py +5 -19
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/fact_classifiers.py +1 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/facts.py +2 -10
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/mcp.py +7 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/reports.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_analysis.py +21 -7
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_concentration.py +15 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_events.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_report.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_rows.py +14 -4
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_source_scan.py +23 -9
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/parser/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/parser/api.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/parser/jsonl_v1.py +10 -10
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/parser/jsonl_values.py +2 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/parser/state.py +2 -7
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/rate_cards/codex-credit-rates.json +44 -9
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/allowance_config.py +4 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/allowance_rate_card.py +21 -5
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/allowance_usage.py +6 -5
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/api.py +4 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/costing.py +2 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/openai.py +29 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/reports/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/reports/agentic_dogfood.py +6 -7
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/reports/api.py +160 -62
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/reports/recommendations.py +8 -10
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/reports/support.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/allowance.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/api.py +0 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/call_detail.py +4 -4
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/call_lists.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/context.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/handler.py +14 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/open_investigator.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/recommendations.py +2 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/reports.py +8 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/request_guards.py +3 -1
- codex_usage_tracking-0.17.2/src/codex_usage_tracker/server/routes.py +69 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/usage_refresh.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/utils.py +2 -8
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/__init__.py +1 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/api.py +9 -12
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/content_index.py +14 -18
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/content_index_event_store.py +6 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/content_index_events.py +17 -5
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/dashboard_queries.py +4 -12
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/large_low_output.py +9 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/query_sql.py +2 -8
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/repeated_files.py +15 -10
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/schema.py +4 -9
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/shell_churn.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/source_records.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/sources.py +6 -22
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/allowance_breakpoints.py +8 -25
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/allowance_online.py +5 -17
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/boundary_delta_core.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/boundary_delta_rows.py +30 -32
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/boundary_delta_summary.py +10 -34
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/boundary_scopes.py +9 -7
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/boundary_summary.py +14 -47
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/error_diagnostics.py +11 -18
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/feature_history.py +6 -18
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/features.py +5 -17
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/grace.py +9 -12
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/history_state.py +4 -12
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/model.py +13 -23
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/predictive.py +7 -18
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/proxy_fit.py +2 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/regime_segments.py +12 -36
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/regression.py +8 -28
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/reports.py +10 -32
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/spans.py +7 -20
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/state_buckets.py +12 -20
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/state_diagnostics.py +13 -23
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/summary_metrics.py +11 -21
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/thread_curves.py +7 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/time_series.py +18 -8
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/token_components.py +18 -47
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/transition_gates.py +8 -11
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/transition_metrics.py +18 -34
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/types.py +2 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/utils.py +2 -7
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/walk_forward.py +9 -30
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/walk_forward_rows.py +8 -20
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracking.egg-info/PKG-INFO +3 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracking.egg-info/SOURCES.txt +3 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracking.egg-info/requires.txt +2 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_allowance_intelligence_cli_mcp.py +2 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_cli_lifecycle.py +8 -28
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_cli_module_entrypoints.py +3 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_cli_release.py +4 -5
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_mcp_integration.py +13 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_plugin_installer.py +7 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/context/test_context_evidence.py +6 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/context/test_context_scan.py +10 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/context/test_context_values.py +10 -7
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_call_origin.py +40 -32
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_i18n.py +17 -11
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_json_contracts.py +0 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/dashboard/test_dashboard_data.py +16 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/dashboard/test_dashboard_live.py +1 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/dashboard/test_dashboard_payload.py +54 -43
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/dashboard/test_dashboard_pricing_snapshot.py +1 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/dashboard/test_dashboard_state.py +8 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/diagnostics/test_diagnostic_snapshot_events.py +5 -9
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/diagnostics/test_diagnostic_snapshot_report.py +1 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/diagnostics/test_diagnostic_snapshots.py +1 -4
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/parser/test_parser.py +2 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/pricing/test_allowance.py +46 -7
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/pricing/test_pricing.py +38 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_api.py +4 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_open_investigator.py +10 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_routes.py +2 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_content_index.py +17 -19
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_refresh_parallel.py +2 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_source_records.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_store_dashboard_mcp.py +10 -17
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_store_migrations.py +5 -5
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_store_sources.py +1 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_allowance_fits.py +1 -3
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_boundary_delta_summary.py +2 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_feature_history.py +8 -1
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_model.py +30 -76
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_one_percent_capacity.py +3 -9
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_reports.py +18 -6
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_token_components.py +1 -4
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_walk_forward.py +1 -3
- codex_usage_tracking-0.17.0/src/codex_usage_tracker/core/json_contract_diagnostics.py +0 -185
- codex_usage_tracking-0.17.0/src/codex_usage_tracker/core/json_contract_server.py +0 -126
- codex_usage_tracking-0.17.0/src/codex_usage_tracker/server/routes.py +0 -63
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/.mcp.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/CONTRIBUTING.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/LICENSE +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/MANIFEST.in +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/README.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/SECURITY.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/assets/icon.svg +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/adoption-hardening-roadmap.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/agentic-briefing-and-dogfood-roadmap.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/agentic-investigation-hardening-roadmap.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/agentic-mcp-skill-roadmap.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/allowance-intelligence.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/architecture/decisions/0001-package-domain-boundaries.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/architecture-boundary-map.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/architecture.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-call-investigator-evidence.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-call-investigator-preview.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-call-investigator.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-calls-preview.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-calls.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-details.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-diagnostics-git-expanded.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-diagnostics.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-insights.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/dashboard-threads.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/cache-context-lab-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/call-drilldown-menu-concept-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/calls-analyst-view-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/calls-high-density-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/command-palette-dashboard-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/diagnostics-notebook-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/generated-dashboard-concept-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/generated-maintainer-banner-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/investigator-workbench-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/overview-dashboard-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/projected-weekly-credits-overlap-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/thread-efficiency-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/frontend-rewrite-references/usage-drain-lab-reference.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/plugin-prompts.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/plugin-thread-leaderboard.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/readme-hero-2.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/readme-hero.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/social-preview.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/ux/call-detail-panel.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/ux/insight-overview.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/assets/ux/thread-investigation.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/call-drilldown-performance-checklist.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/cli-json-schemas.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/cli-reference.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/dashboard-guide.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/examples/remediation-conversation.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/examples/token-waste-conversation.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/first-five-minutes.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/frontend-rewrite-roadmap.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/install.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/local-content-index-roadmap.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/maintainability-roadmap.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/maintainability-scorecard.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/mcp.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/privacy.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/react-dashboard-0.14-release-roadmap.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/docs/ui-ux-improvement-plan.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/scripts/check_wemake_baseline.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/setup.cfg +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/skills/codex-usage-api/SKILL.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/skills/codex-usage-tracker/SKILL.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/__main__.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/allowance.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/allowance_intelligence/__init__.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/__main__.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/config.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/diagnostics.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/output.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/cli/plugin_installer.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/action_timing.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/constants.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/serialized.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/summaries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/token_estimates.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/context/values.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/__init__.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/api_payloads.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/json_contract_common.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/json_contracts.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/models.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/paths.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/redaction.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/core/threads.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/dashboard/pricing_snapshot.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/guided_summary.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_constants.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_payloads.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshot_source_logs.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/snapshots.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/diagnostics/types.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/mcp_server.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/__init__.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/assets/icon.svg +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard.css +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_actions.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_analysis.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_call.css +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_call_diagnostics.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_call_investigator.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_cells.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_data.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_detail.css +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_details.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_diagnostics.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_diagnostics_facts.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_diagnostics_snapshots.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_events.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_filters.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_format.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_i18n.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_insights.css +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_insights.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_layout.css +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_live.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_payload_cache.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_responsive.css +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_state.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_status.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_tables.css +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_tables.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_template.html +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/dashboard_tooltips.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/ar.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/de.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/en.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/es.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/fr.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/it.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/ja.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/ko.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/pt.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/ru.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/vi.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/locales/zh-Hans.json +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/react/assets/dashboard-react.js +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/react/assets/index.css +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/dashboard/react/index.html +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-call-investigator-evidence.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-call-investigator-preview.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-call-investigator.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-calls-preview.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-calls.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-details.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-diagnostics-git-expanded.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-diagnostics.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-insights.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/dashboard-threads.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/plugin-prompts.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/assets/plugin-thread-leaderboard.png +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/dashboard-guide.html +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/examples/remediation-conversation.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/docs/examples/token-waste-conversation.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/skills/codex-usage-api/SKILL.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_data/skills/codex-usage-tracker/SKILL.md +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/plugin_installer.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/allowance.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/allowance_text.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/config.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/pricing/estimates.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/reports/filters.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/reports/project_summary.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/reports/recommendation_builder.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/context_settings.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/dashboard_shell.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/diagnostic_facts.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/diagnostic_routes.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/diagnostic_snapshots.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/live_queries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/live_rows.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/responses.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/status.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/summary.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/server/threads.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/allowance_observations.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/connection.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/content_patterns.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/diagnostic_call_queries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/diagnostic_queries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/exports.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/investigation_runs.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/refresh.py +2 -2
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/rows.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/summary_queries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/thread_summaries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/usage_api_queries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/usage_record_queries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/store/usage_timing.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/support.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/__init__.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/allowance_fits.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/boundary_delta.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/capacity_specs.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/predictive_specs.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracker/usage_drain/regime_labels.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracking.egg-info/dependency_links.txt +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracking.egg-info/entry_points.txt +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/src/codex_usage_tracking.egg-info/top_level.txt +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/__init__.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/allowance_intelligence/test_allowance_intelligence.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_cli_dashboard.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_cli_parser_diagnostics.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/cli/test_mcp_launcher.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/context/test_context_action_timing.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/context/test_context_serialized.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/context/test_context_summaries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/context/test_context_token_estimates.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_formatting.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_privacy.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_projects.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_redaction.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_schema.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/core/test_threads.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/dashboard/test_dashboard_diagnostics_snapshots.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/dashboard/test_dashboard_server.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/dashboard/test_dashboard_status.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/diagnostics/test_diagnostic_fact_classifiers.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/diagnostics/test_diagnostic_reports.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/diagnostics/test_diagnostic_snapshot_source_scan.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/diagnostics/test_doctor_first_run.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/parser/test_parser_inspect_log.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/parser/test_parser_state.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/reports/test_action_brief.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/reports/test_agentic_dogfood.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/reports/test_hypothesis_routing.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/reports/test_recommendations.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/reports/test_support.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_refresh_jobs.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_refresh_routes.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_allowance.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_call_detail.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_call_lists.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_context.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_context_settings.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_dashboard_shell.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_diagnostic_facts.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_diagnostic_refresh_auth.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_diagnostic_snapshots.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_live_queries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_live_rows.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_recommendations.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_request_guards.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_responses.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_status.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_summary.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_threads.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/server/test_server_usage_refresh.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_store_dashboard_queries.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_store_large_batches.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store/test_store_query_sql.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/store_dashboard_helpers.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_boundary_delta.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_boundary_summary.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_error_diagnostics.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_predictive.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_regime_segments.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_regression.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_report_records.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_state_buckets.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_state_diagnostics.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_summary_metrics.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_thread_curves.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_transition_gates.py +0 -0
- {codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/tests/usage_drain/test_usage_drain_transition_metrics.py +0 -0
|
@@ -136,6 +136,10 @@ Use patch releases for public blockers such as broken PyPI installs, missing pac
|
|
|
136
136
|
|
|
137
137
|
Run focused tests first, then broader checks. Run the full local CI gate before opening or updating PRs that touch release, packaging, CLI contracts, MCP behavior, dashboard behavior, privacy behavior, schemas, generated docs/assets, or bundled plugin/skill files.
|
|
138
138
|
|
|
139
|
+
## Source Inspection And Tool Output
|
|
140
|
+
|
|
141
|
+
Large command outputs in Codex chat can be visually compacted by the transcript renderer. When inspecting source, especially after broad `rg`, `sed`, `nl`, generated dashboard assets, logs, or workflow output, do not treat a mangled rendered snippet as proof that the file is corrupt. Prefer small targeted file windows, `git diff`, `python -m py_compile`, focused tests, and CI as the source of truth. If exact syntax matters, inspect a narrow range or use a parser/compiler rather than relying on large printed source dumps.
|
|
142
|
+
|
|
139
143
|
```bash
|
|
140
144
|
python -m ruff check .
|
|
141
145
|
python -m mypy
|
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## 0.17.2 - 2026-07-09
|
|
6
|
+
|
|
7
|
+
- Add GPT-5.6 Sol, Terra, and Luna API pricing and Codex credit-rate support, including the official `gpt-5.6` alias and compatibility with OpenAI's new cache-write pricing column.
|
|
8
|
+
|
|
9
|
+
## 0.17.1 - 2026-07-09
|
|
10
|
+
|
|
11
|
+
- Stabilize async dogfood cache fingerprints so repeated unchanged MCP dogfood runs can reuse cached reports even when SQLite file metadata changes during read/report activity.
|
|
12
|
+
|
|
5
13
|
## 0.17.0 - 2026-07-08
|
|
6
14
|
|
|
7
15
|
- Add agentic MCP investigation tools for hypothesis-driven usage diagnostics, compact evidence briefs, and actionable recommendation reports.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: codex-usage-tracking
|
|
3
|
-
Version: 0.17.
|
|
3
|
+
Version: 0.17.2
|
|
4
4
|
Summary: Unofficial local Codex plugin and dashboard for investigating aggregate token usage, costs, caching, and thread patterns.
|
|
5
5
|
Author: Douglas Monsky
|
|
6
6
|
License-Expression: MIT
|
|
@@ -29,8 +29,8 @@ Requires-Dist: mcp>=1.2.0
|
|
|
29
29
|
Requires-Dist: tiktoken>=0.13.0
|
|
30
30
|
Provides-Extra: dev
|
|
31
31
|
Requires-Dist: agent-maintainer[core]>=0.1.0b1; python_version >= "3.11" and extra == "dev"
|
|
32
|
-
Requires-Dist: actionlint-py>=1.7.12.24; python_version >= "3.11" and extra == "dev"
|
|
33
32
|
Requires-Dist: build>=1.2; extra == "dev"
|
|
33
|
+
Requires-Dist: check-jsonschema>=0.37.4; python_version >= "3.11" and extra == "dev"
|
|
34
34
|
Requires-Dist: git-agent-ratchet>=1.3.0; python_version >= "3.11" and extra == "dev"
|
|
35
35
|
Requires-Dist: mypy>=1.10; extra == "dev"
|
|
36
36
|
Requires-Dist: pillow>=10; extra == "dev"
|
|
@@ -40,6 +40,7 @@ Requires-Dist: ruff>=0.8; extra == "dev"
|
|
|
40
40
|
Requires-Dist: tach>=0.35.0; python_version >= "3.11" and extra == "dev"
|
|
41
41
|
Requires-Dist: tomli>=2.0; python_version < "3.11" and extra == "dev"
|
|
42
42
|
Requires-Dist: wemake-python-styleguide>=1.6.2; python_version >= "3.11" and extra == "dev"
|
|
43
|
+
Requires-Dist: yamllint>=1.38.0; python_version >= "3.11" and extra == "dev"
|
|
43
44
|
Requires-Dist: zizmor>=1.26.1; python_version >= "3.11" and extra == "dev"
|
|
44
45
|
Dynamic: license-file
|
|
45
46
|
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Agent Maintainer Guidance
|
|
2
|
+
|
|
3
|
+
`AGENTS.agent-maintainer.md` is generated from `[tool.agent_maintainer]` in
|
|
4
|
+
`pyproject.toml` by:
|
|
5
|
+
|
|
6
|
+
```bash
|
|
7
|
+
python3 -m agent_maintainer guidance
|
|
8
|
+
```
|
|
9
|
+
|
|
10
|
+
Do not edit the generated sidecar by hand. Update configuration or the upstream
|
|
11
|
+
renderer, regenerate it, and verify with:
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
python3 -m agent_maintainer guidance --check
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
This repo uses `legacy-ratchet` mode. Existing oversized files and structure
|
|
18
|
+
warnings are tracked in `.agent-maintainer/ratchet-baseline.json` so future work
|
|
19
|
+
can fail on regressions while refactor PRs reduce the baseline over time.
|
|
20
|
+
|
|
21
|
+
The first aggressive refactor targets should be the largest source files named
|
|
22
|
+
by:
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
python3 -m agent_maintainer ratchet next --limit 20
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Use the `justfile` aliases in this repo for common verification commands:
|
|
29
|
+
|
|
30
|
+
```bash
|
|
31
|
+
just vp
|
|
32
|
+
just v
|
|
33
|
+
just vc
|
|
34
|
+
just doctor
|
|
35
|
+
```
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
# Agent Maintainer Hardening Branch Roadmap
|
|
2
|
+
|
|
3
|
+
Branch: `refactor/secret-scan-hardening`
|
|
4
|
+
|
|
5
|
+
## Goal
|
|
6
|
+
|
|
7
|
+
Adopt the latest Agent Maintainer ratchet and a small set of low-noise hardening
|
|
8
|
+
checks without mixing in broad Python refactors or large documentation cleanup.
|
|
9
|
+
|
|
10
|
+
## Completed Chunks
|
|
11
|
+
|
|
12
|
+
- Upgrade generated Agent Maintainer guidance and add local `just` wrappers.
|
|
13
|
+
- Add a latest-main ratchet baseline for existing file-length and structure debt.
|
|
14
|
+
- Enable configured `gitleaks` secret scanning with allowlists for ignored local
|
|
15
|
+
artifacts and intentional fake-secret fixtures.
|
|
16
|
+
- Fix the publish workflow glob flagged by `actionlint`.
|
|
17
|
+
- Format TOML configuration with Taplo.
|
|
18
|
+
- Enable repo-configured `yamllint`.
|
|
19
|
+
- Add a repo-specific Markdown lint config and enable the gate with historical
|
|
20
|
+
prose/layout rules disabled.
|
|
21
|
+
- Add CI hardening job for `actionlint`, `gitleaks`, `markdownlint`,
|
|
22
|
+
`yamllint`, Taplo, and GitHub workflow schema validation.
|
|
23
|
+
- Fix pytest verifier imports by including the repository root in pytest's
|
|
24
|
+
Python path.
|
|
25
|
+
- Run one mechanical `ruff format` PR to clear format gate without behavior
|
|
26
|
+
changes.
|
|
27
|
+
- Enable Taplo as Agent Maintainer gate after formatting TOML configuration.
|
|
28
|
+
- Enable GitHub workflow schema validation with explicit `check-jsonschema`
|
|
29
|
+
arguments.
|
|
30
|
+
- Re-run focused validation for the enabled optional gates.
|
|
31
|
+
- Add explicit root Tach module inventory and ADR so architecture checks report
|
|
32
|
+
real dependency violations instead missing configuration.
|
|
33
|
+
|
|
34
|
+
## Branch Exit
|
|
35
|
+
|
|
36
|
+
This branch is ready for PR once the latest commit is pushed and CI confirms the
|
|
37
|
+
same hardening gates remotely.
|
|
38
|
+
|
|
39
|
+
## Follow-Up PRs
|
|
40
|
+
|
|
41
|
+
### 1. Stabilize The Existing Full Profile
|
|
42
|
+
|
|
43
|
+
First fix failures that prevent the full profile from being a useful signal.
|
|
44
|
+
These are not product refactors; verifier hygiene should be kept in small
|
|
45
|
+
mechanical PRs.
|
|
46
|
+
|
|
47
|
+
- Fix narrow Pyright errors already surfaced in `cli/main.py` and
|
|
48
|
+
`context/reader.py`. These look like concrete typing issues, not broad strict
|
|
49
|
+
mode migration.
|
|
50
|
+
|
|
51
|
+
### 2. Make Architecture And Dependency Checks Actionable
|
|
52
|
+
|
|
53
|
+
After tests and mechanical formatting are stable, make structural gates produce
|
|
54
|
+
useful review feedback.
|
|
55
|
+
|
|
56
|
+
- Fix actual `tach` boundary violations only after config is explicit.
|
|
57
|
+
- Triage `deptry` into three buckets: real unused dependencies, intentionally
|
|
58
|
+
optional/runtime dependencies, packaging/test-only dependencies. Commit
|
|
59
|
+
configuration only with a short explanation.
|
|
60
|
+
- Triage `vulture` similarly: delete true dead code, preserve public/CLI/MCP
|
|
61
|
+
entry points with explicit allowlists, avoid broad suppressions.
|
|
62
|
+
|
|
63
|
+
### 3. Security Hardening Pass
|
|
64
|
+
|
|
65
|
+
Once the codebase imports and architecture checks are stable, move to security
|
|
66
|
+
findings.
|
|
67
|
+
|
|
68
|
+
- Triage `bandit` findings. Start with medium SQL-construction warnings and URL
|
|
69
|
+
handling; classify string-literal test fixtures separately from real issues.
|
|
70
|
+
- Keep `gitleaks` enabled as the current-tree secret gate. Consider a separate
|
|
71
|
+
history-scan PR only after confirming no real credentials are present and
|
|
72
|
+
deciding how to handle historical false positives.
|
|
73
|
+
- Keep `pip-audit` disabled until the project has a pinned dependency input.
|
|
74
|
+
Decide between a constraints file, lock export, or dedicated audit
|
|
75
|
+
requirements file before enabling it.
|
|
76
|
+
- Triage `zizmor` with a repo-specific config/invocation. Do not enable as
|
|
77
|
+
blocking until it audits local workflows without remote-fetch failures.
|
|
78
|
+
|
|
79
|
+
### 4. Ratchet Large Python Files Down
|
|
80
|
+
|
|
81
|
+
After gates are trustworthy, start the actual refactor sequence. Use one PR per
|
|
82
|
+
module boundary and keep behavior covered by focused tests.
|
|
83
|
+
|
|
84
|
+
- Start with `src/codex_usage_tracker/cli/mcp_server.py`, because it directly
|
|
85
|
+
contributed to context/tool-output confusion and is far over the file-length
|
|
86
|
+
threshold.
|
|
87
|
+
- Split `src/codex_usage_tracker/reports/api.py` by report family before editing
|
|
88
|
+
behavior; it is the largest source file in the raw baseline.
|
|
89
|
+
- Split `src/codex_usage_tracker/store/content_index.py` by ingestion, FTS,
|
|
90
|
+
provenance, and query responsibilities.
|
|
91
|
+
- Then address medium oversized modules surfaced by the latest file-length log:
|
|
92
|
+
`allowance_intelligence/model.py`, `server/handler.py`, diagnostics modules,
|
|
93
|
+
and CLI parser/main files.
|
|
94
|
+
- Keep each refactor PR below the normal change budget unless a cohesive change
|
|
95
|
+
plan is created first.
|
|
96
|
+
|
|
97
|
+
### 5. Optional Strictness Later
|
|
98
|
+
|
|
99
|
+
These are useful but should wait until the above gates stop producing basic
|
|
100
|
+
noise.
|
|
101
|
+
|
|
102
|
+
- Tighten Markdown linting by re-enabling historical spacing/inline-HTML rules
|
|
103
|
+
only in dedicated docs cleanup PRs.
|
|
104
|
+
- Consider `wemake` only after file-length and complexity ratchets have reduced
|
|
105
|
+
the largest modules.
|
|
106
|
+
- Consider `interrogate` only if public API/docstring policy becomes a real
|
|
107
|
+
product requirement.
|
|
108
|
+
- Consider mutation testing as a manual/release gate after core tests and
|
|
109
|
+
complexity failures are under control.
|
|
110
|
+
|
|
111
|
+
## Validation
|
|
112
|
+
|
|
113
|
+
- `python3 scripts/check_release.py`
|
|
114
|
+
- `git diff --check`
|
|
115
|
+
- `python -m agent_maintainer guidance --check`
|
|
116
|
+
- Focused direct checks for each enabled optional gate.
|
codex_usage_tracking-0.17.2/docs/architecture/decisions/0002-explicit-tach-module-inventory.md
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Explicit Tach Module Inventory
|
|
2
|
+
|
|
3
|
+
Tach is part of the Agent Maintainer hardening profile, but the root
|
|
4
|
+
`tach.toml` previously did not enumerate source modules. That made the
|
|
5
|
+
architecture check too vague: Tach could run, but the verifier could not trust
|
|
6
|
+
it as an explicit package-boundary contract.
|
|
7
|
+
|
|
8
|
+
The root Tach config now lists each non-`__init__` Python source module under
|
|
9
|
+
`src/codex_usage_tracker` as an explicit module. This is intentionally a
|
|
10
|
+
baseline inventory, not a claim that all dependency edges are already healthy.
|
|
11
|
+
|
|
12
|
+
Existing `tach.domain.toml` files remain the local domain-ownership notes. The
|
|
13
|
+
new root module inventory gives the verifier a concrete module set so later PRs
|
|
14
|
+
can address actual `tach` dependency violations incrementally instead of first
|
|
15
|
+
failing on missing configuration.
|
|
16
|
+
|
|
17
|
+
Follow-up work should add or reduce dependency edges in focused PRs. This
|
|
18
|
+
decision does not enable circular dependency blocking or resolve existing
|
|
19
|
+
architecture drift by itself.
|
|
@@ -149,8 +149,8 @@ python scripts/smoke_installed_package.py --docker
|
|
|
149
149
|
To verify the public PyPI package instead of the local checkout:
|
|
150
150
|
|
|
151
151
|
```bash
|
|
152
|
-
python scripts/smoke_installed_package.py --from-pypi --version 0.17.
|
|
153
|
-
python scripts/smoke_installed_package.py --docker --from-pypi --version 0.17.
|
|
152
|
+
python scripts/smoke_installed_package.py --from-pypi --version 0.17.2
|
|
153
|
+
python scripts/smoke_installed_package.py --docker --from-pypi --version 0.17.2
|
|
154
154
|
```
|
|
155
155
|
|
|
156
156
|
`scripts/check_release.py` treats these public-package smoke commands as release-state claims. Keep their `--version` and `codex-usage-tracking==...` values aligned with `pyproject.toml`; the release gate fails when the docs claim a different public version. It also checks that install docs point at the real PyPI distribution, `codex-usage-tracking`, and keep the warning that `codex-usage-tracker` is a different PyPI package.
|
|
@@ -24,12 +24,12 @@ Not guaranteed:
|
|
|
24
24
|
|
|
25
25
|
## 1. Public Install And Package Metadata
|
|
26
26
|
|
|
27
|
-
- [x] Verify the current public PyPI version is visible as `0.17.
|
|
28
|
-
- [x] Verify public venv install for `0.17.
|
|
29
|
-
- [x] Verify public pipx install path for `0.17.
|
|
27
|
+
- [x] Verify the current public PyPI version is visible as `0.17.2`: `python -c "import json, urllib.request; print(json.load(urllib.request.urlopen('https://pypi.org/pypi/codex-usage-tracking/json'))['info']['version'])"`.
|
|
28
|
+
- [x] Verify public venv install for `0.17.2`: `python -m venv /tmp/codex-usage-pypi-smoke && . /tmp/codex-usage-pypi-smoke/bin/activate && python -m pip install codex-usage-tracking==0.17.2 && codex-usage-tracker --version`.
|
|
29
|
+
- [x] Verify public pipx install path for `0.17.2`: `PIPX_HOME=/tmp/codex-usage-pipx-home PIPX_BIN_DIR=/tmp/codex-usage-pipx-bin pipx install codex-usage-tracking==0.17.2 && /tmp/codex-usage-pipx-bin/codex-usage-tracker --version`.
|
|
30
30
|
- [x] Verify installed package resources from a built wheel: `python scripts/smoke_installed_package.py`.
|
|
31
31
|
- [x] Verify installed package resources in Linux Docker: `python scripts/smoke_installed_package.py --docker`.
|
|
32
|
-
- [x] Verify public PyPI package in Docker: `python scripts/smoke_installed_package.py --docker --from-pypi --version 0.17.
|
|
32
|
+
- [x] Verify public PyPI package in Docker: `python scripts/smoke_installed_package.py --docker --from-pypi --version 0.17.2`.
|
|
33
33
|
- [x] Verify PyPI metadata names remain unchanged: `python scripts/check_release.py`.
|
|
34
34
|
- [x] Add Python 3.14 as an official support target after CI, package classifiers, docs, and installed-package smoke coverage were added. Docker smoke coverage uses `python:3.14-slim` by default. Track this in issue #12.
|
|
35
35
|
|
|
@@ -134,14 +134,14 @@ Not guaranteed:
|
|
|
134
134
|
|
|
135
135
|
## Evidence References
|
|
136
136
|
|
|
137
|
-
These references are the concrete proof behind completed checklist items. Public package smoke commands are version-specific to `0.17.
|
|
137
|
+
These references are the concrete proof behind completed checklist items. Public package smoke commands are version-specific to `0.17.2`; all repo tests use synthetic or aggregate-only data.
|
|
138
138
|
|
|
139
139
|
### Public Install And Package Metadata
|
|
140
140
|
|
|
141
141
|
- Public PyPI version, public venv install, and public pipx install are proven by the exact public-install commands in section 1.
|
|
142
142
|
- Built-wheel and installed-resource coverage is proven by `scripts/smoke_installed_package.py` and `tests/test_cli_release.py::test_installed_package_smoke_checks_help_for_stable_commands`.
|
|
143
143
|
- Linux package-resource coverage is proven by `scripts/smoke_installed_package.py --docker`.
|
|
144
|
-
- Public PyPI Docker coverage is proven by `scripts/smoke_installed_package.py --docker --from-pypi --version 0.17.
|
|
144
|
+
- Public PyPI Docker coverage is proven by `scripts/smoke_installed_package.py --docker --from-pypi --version 0.17.2`.
|
|
145
145
|
- PyPI metadata, package/distribution names, package resources, source/wheel member names, Python 3.10-3.14 support metadata, CI workflow requirements, publish workflow safety text, and tracked secret patterns are proven by `scripts/check_release.py`, `scripts/check_release.py --dist`, and `tests/test_cli_release.py::test_release_check_script_passes`.
|
|
146
146
|
|
|
147
147
|
### Upgrade And Migration
|
|
@@ -219,8 +219,8 @@ These references are the concrete proof behind completed checklist items. Public
|
|
|
219
219
|
- Publish workflow package name, Trusted Publishing, TestPyPI/PyPI job presence, event guards, no push/PR publishing, no token/password publishing, and manual PyPI main/tag preflight are proven by `scripts/check_release.py::_check_publish_workflow`.
|
|
220
220
|
- The GitHub `pypi` environment gate is proven by `gh api repos/douglasmonsky/codex-usage-tracker/environments/pypi`, which reports a `required_reviewers` protection rule and `can_admins_bypass=false`.
|
|
221
221
|
- Dist filename and wheel/sdist member checks are proven by `python -m build`, `python -m twine check dist/*`, and `python scripts/check_release.py --dist`.
|
|
222
|
-
- TestPyPI publish process is proven by a workflow-dispatch run on `main`, followed by TestPyPI metadata and clean virtualenv install checks for `codex-usage-tracking==0.17.
|
|
223
|
-
- PyPI publish process is proven by a workflow-dispatch run on `main`, protected `pypi` environment approval, PyPI metadata visibility, clean virtualenv install, temporary pipx install, and Docker public-package smoke for `codex-usage-tracking==0.17.
|
|
222
|
+
- TestPyPI publish process is proven by a workflow-dispatch run on `main`, followed by TestPyPI metadata and clean virtualenv install checks for `codex-usage-tracking==0.17.2`.
|
|
223
|
+
- PyPI publish process is proven by a workflow-dispatch run on `main`, protected `pypi` environment approval, PyPI metadata visibility, clean virtualenv install, temporary pipx install, and Docker public-package smoke for `codex-usage-tracking==0.17.2`.
|
|
224
224
|
- Release recovery documentation is proven by `scripts/check_release.py` required-file and docs checks.
|
|
225
225
|
|
|
226
226
|
### Known Limitations
|
|
@@ -16,6 +16,8 @@ codex-usage-tracker update-pricing
|
|
|
16
16
|
|
|
17
17
|
This fetches OpenAI text-token pricing from `https://developers.openai.com/api/docs/pricing.md`, parses the selected tier, and writes a source-stamped local cache to `~/.codex-usage-tracker/pricing.json`. The default tier is `standard`; other supported tiers are `batch`, `flex`, and `priority`.
|
|
18
18
|
|
|
19
|
+
The updater supports both the older four-value pricing rows and the newer five-value rows used by GPT-5.6 for input, cached input, cache writes, and output. GPT-5.6 Sol, Terra, and Luna are loaded from the published table, and the documented `gpt-5.6` alias resolves to `gpt-5.6-sol`. Current Codex logs do not expose a separate cache-write token counter, so cost estimates use the logged uncached input, cached input, and output counters without adding an explicit cache-write charge.
|
|
20
|
+
|
|
19
21
|
If a pricing file already exists, the updater leaves a timestamped `.bak` copy next to it before replacing the active cache.
|
|
20
22
|
|
|
21
23
|
The updater also includes marked best-guess estimates for Codex labels that are not finalized in the public pricing table. `codex-auto-review` uses OpenAI's published `codex-mini-latest` Codex pricing from `https://openai.com/index/introducing-codex/`: `$1.50` per 1M input tokens, a 75% prompt-cache discount (`$0.375` per 1M cached input tokens), and `$6.00` per 1M output tokens. `gpt-5.3-codex-spark` is listed by OpenAI as a research preview with non-final Codex rates, so the tracker estimates it as `gpt-5.3-codex` at `$1.75` per 1M input tokens, `$0.175` per 1M cached input tokens, and `$14.00` per 1M output tokens.
|
|
@@ -41,6 +43,8 @@ Edit `~/.codex-usage-tracker/pricing.json` with USD-per-million-token rates for
|
|
|
41
43
|
|
|
42
44
|
`Codex Credits` is a calculated usage number, not a dashboard-only unit. The tracker uses Codex's logged aggregate token counters and the bundled OpenAI Codex rate-card snapshot to estimate credits consumed by local Codex calls.
|
|
43
45
|
|
|
46
|
+
The bundled rate card includes the published GPT-5.6 Sol, Terra, and Luna credit rates from the current Codex pricing documentation.
|
|
47
|
+
|
|
44
48
|
The estimate uses:
|
|
45
49
|
|
|
46
50
|
- input tokens
|
|
@@ -23,7 +23,7 @@ Sources:
|
|
|
23
23
|
|
|
24
24
|
- [Codex Speed](https://developers.openai.com/codex/speed)
|
|
25
25
|
- [Codex Pricing](https://developers.openai.com/codex/pricing)
|
|
26
|
-
- [Codex rate card](https://
|
|
26
|
+
- [Codex pricing and rate card](https://developers.openai.com/codex/pricing)
|
|
27
27
|
- [Codex app-server](https://developers.openai.com/codex/app-server)
|
|
28
28
|
- [Codex configuration reference](https://developers.openai.com/codex/config-reference)
|
|
29
29
|
|
|
@@ -4,16 +4,23 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "codex-usage-tracking"
|
|
7
|
-
version = "0.17.
|
|
7
|
+
version = "0.17.2"
|
|
8
8
|
description = "Unofficial local Codex plugin and dashboard for investigating aggregate token usage, costs, caching, and thread patterns."
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.10"
|
|
11
|
-
authors = [
|
|
12
|
-
{ name = "Douglas Monsky" }
|
|
13
|
-
]
|
|
11
|
+
authors = [{ name = "Douglas Monsky" }]
|
|
14
12
|
license = "MIT"
|
|
15
13
|
license-files = ["LICENSE"]
|
|
16
|
-
keywords = [
|
|
14
|
+
keywords = [
|
|
15
|
+
"codex",
|
|
16
|
+
"mcp",
|
|
17
|
+
"tokens",
|
|
18
|
+
"usage",
|
|
19
|
+
"dashboard",
|
|
20
|
+
"openai",
|
|
21
|
+
"prompt-caching",
|
|
22
|
+
"cost-analysis",
|
|
23
|
+
]
|
|
17
24
|
classifiers = [
|
|
18
25
|
"Development Status :: 4 - Beta",
|
|
19
26
|
"Environment :: Console",
|
|
@@ -29,10 +36,7 @@ classifiers = [
|
|
|
29
36
|
"Topic :: Software Development :: Libraries :: Python Modules",
|
|
30
37
|
"Topic :: System :: Monitoring",
|
|
31
38
|
]
|
|
32
|
-
dependencies = [
|
|
33
|
-
"mcp>=1.2.0",
|
|
34
|
-
"tiktoken>=0.13.0"
|
|
35
|
-
]
|
|
39
|
+
dependencies = ["mcp>=1.2.0", "tiktoken>=0.13.0"]
|
|
36
40
|
|
|
37
41
|
[project.urls]
|
|
38
42
|
Homepage = "https://github.com/douglasmonsky/codex-usage-tracker"
|
|
@@ -42,19 +46,20 @@ Changelog = "https://github.com/douglasmonsky/codex-usage-tracker/blob/main/CHAN
|
|
|
42
46
|
|
|
43
47
|
[project.optional-dependencies]
|
|
44
48
|
dev = [
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
49
|
+
"agent-maintainer[core]>=0.1.0b1; python_version >= '3.11'",
|
|
50
|
+
"build>=1.2",
|
|
51
|
+
"check-jsonschema>=0.37.4; python_version >= '3.11'",
|
|
52
|
+
"git-agent-ratchet>=1.3.0; python_version >= '3.11'",
|
|
53
|
+
"mypy>=1.10",
|
|
54
|
+
"pillow>=10",
|
|
55
|
+
"pytest>=8.0",
|
|
56
|
+
"pytest-cov>=5.0",
|
|
57
|
+
"ruff>=0.8",
|
|
58
|
+
"tach>=0.35.0; python_version >= '3.11'",
|
|
59
|
+
"tomli>=2.0; python_version < '3.11'",
|
|
60
|
+
"wemake-python-styleguide>=1.6.2; python_version >= '3.11'",
|
|
61
|
+
"yamllint>=1.38.0; python_version >= '3.11'",
|
|
62
|
+
"zizmor>=1.26.1; python_version >= '3.11'",
|
|
58
63
|
]
|
|
59
64
|
|
|
60
65
|
[project.scripts]
|
|
@@ -86,7 +91,7 @@ where = ["src"]
|
|
|
86
91
|
|
|
87
92
|
[tool.pytest.ini_options]
|
|
88
93
|
testpaths = ["tests"]
|
|
89
|
-
pythonpath = ["src"]
|
|
94
|
+
pythonpath = [".", "src"]
|
|
90
95
|
|
|
91
96
|
[tool.coverage.run]
|
|
92
97
|
branch = true
|
|
@@ -114,12 +119,12 @@ coverage_source = ["src"]
|
|
|
114
119
|
file_length_paths = ["src", "tests", "scripts", "skills"]
|
|
115
120
|
structure_paths = ["src"]
|
|
116
121
|
structure_ignore_paths = [
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
122
|
+
"tests/**",
|
|
123
|
+
"migrations/**",
|
|
124
|
+
"generated/**",
|
|
125
|
+
".venv/**",
|
|
126
|
+
"venv/**",
|
|
127
|
+
"**/__pycache__/**",
|
|
123
128
|
]
|
|
124
129
|
vulture_paths = ["src", "tests"]
|
|
125
130
|
require_tests = true
|
|
@@ -141,6 +146,18 @@ xenon_max_average = "A"
|
|
|
141
146
|
ruff_max_complexity = 10
|
|
142
147
|
pyright_type_checking_mode = "standard"
|
|
143
148
|
enable_pip_audit = false
|
|
149
|
+
enable_secret_scanning = true
|
|
150
|
+
enable_yamllint = true
|
|
151
|
+
enable_taplo = true
|
|
152
|
+
enable_markdownlint = true
|
|
153
|
+
enable_check_jsonschema = true
|
|
154
|
+
check_jsonschema_args = [
|
|
155
|
+
"--builtin-schema",
|
|
156
|
+
"vendor.github-workflows",
|
|
157
|
+
".github/workflows/ci.yml",
|
|
158
|
+
".github/workflows/pricing-compat.yml",
|
|
159
|
+
".github/workflows/publish.yml",
|
|
160
|
+
]
|
|
144
161
|
enable_wemake = false
|
|
145
162
|
enable_interrogate = false
|
|
146
163
|
|
{codex_usage_tracking-0.17.0 → codex_usage_tracking-0.17.2}/scripts/benchmark_synthetic_history.py
RENAMED
|
@@ -179,9 +179,11 @@ def main() -> int:
|
|
|
179
179
|
)
|
|
180
180
|
for failure in result["threshold_failures"]:
|
|
181
181
|
print(f" FAIL {failure}")
|
|
182
|
-
return
|
|
183
|
-
|
|
184
|
-
|
|
182
|
+
return (
|
|
183
|
+
1
|
|
184
|
+
if args.enforce_thresholds and any(result["threshold_failures"] for result in results)
|
|
185
|
+
else 0
|
|
186
|
+
)
|
|
185
187
|
finally:
|
|
186
188
|
if temp_dir and not args.keep_dbs:
|
|
187
189
|
shutil.rmtree(temp_dir, ignore_errors=True)
|
|
@@ -251,6 +253,7 @@ def benchmark_size(
|
|
|
251
253
|
min_tokens=9_000,
|
|
252
254
|
)
|
|
253
255
|
)
|
|
256
|
+
|
|
254
257
|
def payload_action() -> dict[str, Any]:
|
|
255
258
|
return dashboard_payload(
|
|
256
259
|
db_path=db_path,
|
|
@@ -333,9 +336,7 @@ def benchmark_size(
|
|
|
333
336
|
}
|
|
334
337
|
context_metrics: dict[str, Any] = {}
|
|
335
338
|
if source_bundle:
|
|
336
|
-
timings["dashboard_payload_with_source_logs_seconds"] =
|
|
337
|
-
dashboard_payload_active_seconds
|
|
338
|
-
)
|
|
339
|
+
timings["dashboard_payload_with_source_logs_seconds"] = dashboard_payload_active_seconds
|
|
339
340
|
context_metrics = _benchmark_context_loads(
|
|
340
341
|
db_path=db_path,
|
|
341
342
|
row_count=row_count,
|
|
@@ -495,7 +496,9 @@ def _benchmark_context_loads(
|
|
|
495
496
|
)
|
|
496
497
|
timing_name = f"context_load_{label}_line_seconds"
|
|
497
498
|
timings[timing_name] = elapsed
|
|
498
|
-
diagnostics =
|
|
499
|
+
diagnostics = (
|
|
500
|
+
payload.get("diagnostics") if isinstance(payload.get("diagnostics"), dict) else {}
|
|
501
|
+
)
|
|
499
502
|
loads[label] = {
|
|
500
503
|
"record_id": record_id,
|
|
501
504
|
"seconds": elapsed,
|
|
@@ -534,10 +537,7 @@ def _evaluate_thresholds(
|
|
|
534
537
|
if threshold is None:
|
|
535
538
|
continue
|
|
536
539
|
limit = round(
|
|
537
|
-
(
|
|
538
|
-
threshold["base_seconds"]
|
|
539
|
-
+ threshold["per_10k_seconds"] * (row_count / 10_000)
|
|
540
|
-
)
|
|
540
|
+
(threshold["base_seconds"] + threshold["per_10k_seconds"] * (row_count / 10_000))
|
|
541
541
|
* threshold_scale,
|
|
542
542
|
6,
|
|
543
543
|
)
|
|
@@ -818,9 +818,15 @@ def _synthetic_events(
|
|
|
818
818
|
subagent_type="guardian" if is_review else "thread_spawn" if is_subagent else None,
|
|
819
819
|
agent_role="reviewer" if is_review else "worker" if is_subagent else None,
|
|
820
820
|
agent_nickname=None,
|
|
821
|
-
parent_session_id=f"session-{(index - 1) % 2500:04d}"
|
|
822
|
-
|
|
823
|
-
|
|
821
|
+
parent_session_id=f"session-{(index - 1) % 2500:04d}"
|
|
822
|
+
if is_subagent or is_review
|
|
823
|
+
else None,
|
|
824
|
+
parent_thread_name=_synthetic_thread_name(index - 1)
|
|
825
|
+
if is_subagent or is_review
|
|
826
|
+
else None,
|
|
827
|
+
parent_session_updated_at=f"2026-05-{day:02d}T22:00:00Z"
|
|
828
|
+
if is_subagent or is_review
|
|
829
|
+
else None,
|
|
824
830
|
model_context_window=200_000,
|
|
825
831
|
input_tokens=metrics["input_tokens"],
|
|
826
832
|
cached_input_tokens=metrics["cached_input_tokens"],
|
|
@@ -266,10 +266,7 @@ def main() -> int:
|
|
|
266
266
|
|
|
267
267
|
def _check_required_files() -> list[str]:
|
|
268
268
|
failures: list[str] = []
|
|
269
|
-
tracked_files = {
|
|
270
|
-
path.relative_to(REPO_ROOT).as_posix()
|
|
271
|
-
for path in _tracked_files()
|
|
272
|
-
}
|
|
269
|
+
tracked_files = {path.relative_to(REPO_ROOT).as_posix() for path in _tracked_files()}
|
|
273
270
|
for path in REQUIRED_FILES:
|
|
274
271
|
if not (REPO_ROOT / path).exists():
|
|
275
272
|
failures.append(f"missing required file: {path}")
|
|
@@ -337,7 +334,9 @@ def _check_package_naming_docs() -> list[str]:
|
|
|
337
334
|
for relative_path in PACKAGE_NAMING_DOCS:
|
|
338
335
|
text = (REPO_ROOT / relative_path).read_text(encoding="utf-8")
|
|
339
336
|
if DISTRIBUTION_NAME not in text:
|
|
340
|
-
failures.append(
|
|
337
|
+
failures.append(
|
|
338
|
+
f"{relative_path} must name the public PyPI package {DISTRIBUTION_NAME}"
|
|
339
|
+
)
|
|
341
340
|
if relative_path in {"README.md", "docs/install.md"} and old_name_warning not in text:
|
|
342
341
|
failures.append(
|
|
343
342
|
f"{relative_path} must warn that {OLD_PYPI_DISTRIBUTION_NAME} "
|
|
@@ -406,9 +405,11 @@ def _check_packaging_metadata() -> list[str]:
|
|
|
406
405
|
failures: list[str] = []
|
|
407
406
|
manifest = json.loads((REPO_ROOT / ".codex-plugin/plugin.json").read_text(encoding="utf-8"))
|
|
408
407
|
if manifest != plugin_manifest():
|
|
409
|
-
failures.append(
|
|
408
|
+
failures.append(
|
|
409
|
+
".codex-plugin/plugin.json does not match plugin_installer.plugin_manifest()"
|
|
410
|
+
)
|
|
410
411
|
if project.get("license") != "MIT":
|
|
411
|
-
failures.append(
|
|
412
|
+
failures.append('pyproject.toml should use SPDX license = "MIT"')
|
|
412
413
|
if "license-files" not in project:
|
|
413
414
|
failures.append("pyproject.toml should include license-files")
|
|
414
415
|
if "urls" not in project:
|
|
@@ -427,7 +428,9 @@ def _check_packaging_metadata() -> list[str]:
|
|
|
427
428
|
if mcp_server.get("args") != ["./skills/codex-usage-tracker/scripts/run_mcp.py"]:
|
|
428
429
|
failures.append(".mcp.json should point at the bundled MCP bootstrap launcher")
|
|
429
430
|
if mcp_server.get("startup_timeout_sec") != 120:
|
|
430
|
-
failures.append(
|
|
431
|
+
failures.append(
|
|
432
|
+
".mcp.json should allow enough startup time for first-run runtime bootstrap"
|
|
433
|
+
)
|
|
431
434
|
manifest = (REPO_ROOT / "MANIFEST.in").read_text(encoding="utf-8")
|
|
432
435
|
if "recursive-include skills *.md *.py" not in manifest:
|
|
433
436
|
failures.append("MANIFEST.in should include Codex skill scripts in the source distribution")
|
|
@@ -453,7 +456,9 @@ def _check_packaging_metadata() -> list[str]:
|
|
|
453
456
|
if "importlib.metadata.version('codex-usage-tracking')" not in launcher:
|
|
454
457
|
failures.append("MCP runtime launcher must check the codex-usage-tracking distribution")
|
|
455
458
|
if "PACKAGE_SPEC_MARKER" not in launcher:
|
|
456
|
-
failures.append(
|
|
459
|
+
failures.append(
|
|
460
|
+
"MCP runtime launcher should invalidate cached runtimes when package spec changes"
|
|
461
|
+
)
|
|
457
462
|
failures.extend(_check_python_support_metadata(project))
|
|
458
463
|
failures.extend(_check_ci_workflow())
|
|
459
464
|
failures.extend(_check_publish_workflow())
|
|
@@ -506,8 +511,8 @@ def _check_publish_workflow() -> list[str]:
|
|
|
506
511
|
"python -m twine check dist/*",
|
|
507
512
|
"if: github.event_name == 'workflow_dispatch' && inputs.target == 'testpypi'",
|
|
508
513
|
"if: github.event_name == 'release' || (github.event_name == 'workflow_dispatch' && inputs.target == 'pypi')",
|
|
509
|
-
|
|
510
|
-
|
|
514
|
+
'echo "ref=$GITHUB_REF"',
|
|
515
|
+
'echo "sha=$GITHUB_SHA"',
|
|
511
516
|
"refs/heads/main|refs/tags/*",
|
|
512
517
|
"Manual PyPI publishing must run from main or a tag ref.",
|
|
513
518
|
"name: testpypi",
|
|
@@ -518,7 +523,9 @@ def _check_publish_workflow() -> list[str]:
|
|
|
518
523
|
"codex-usage-tracking {version} already exists on {index_name}; skipping upload.",
|
|
519
524
|
]:
|
|
520
525
|
if required not in workflow:
|
|
521
|
-
failures.append(
|
|
526
|
+
failures.append(
|
|
527
|
+
f"publish workflow is missing required Trusted Publishing text: {required}"
|
|
528
|
+
)
|
|
522
529
|
if re.search(r"(?m)^\s*push\s*:", workflow):
|
|
523
530
|
failures.append("publish workflow must not publish on ordinary pushes")
|
|
524
531
|
if re.search(r"(?m)^\s*pull_request\s*:", workflow):
|
|
@@ -532,9 +539,9 @@ def _check_publish_workflow() -> list[str]:
|
|
|
532
539
|
continue
|
|
533
540
|
for required in [
|
|
534
541
|
"Verify PyPI publish ref",
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
542
|
+
'echo "event=$GITHUB_EVENT_NAME"',
|
|
543
|
+
'echo "ref=$GITHUB_REF"',
|
|
544
|
+
'echo "sha=$GITHUB_SHA"',
|
|
538
545
|
"refs/heads/main|refs/tags/*",
|
|
539
546
|
"Manual PyPI publishing must run from main or a tag ref.",
|
|
540
547
|
"Check target package version",
|
|
@@ -578,7 +585,9 @@ def _check_ci_workflow() -> list[str]:
|
|
|
578
585
|
def _check_skill_packaging() -> list[str]:
|
|
579
586
|
failures: list[str] = []
|
|
580
587
|
pyproject = tomllib.loads((REPO_ROOT / "pyproject.toml").read_text(encoding="utf-8"))
|
|
581
|
-
package_data = set(
|
|
588
|
+
package_data = set(
|
|
589
|
+
pyproject["tool"]["setuptools"]["package-data"]["codex_usage_tracker.plugin_data"]
|
|
590
|
+
)
|
|
582
591
|
if "dashboard/locales/*" not in package_data:
|
|
583
592
|
failures.append("pyproject.toml package data is missing dashboard locale catalogs")
|
|
584
593
|
for source_skill in sorted((REPO_ROOT / "skills").glob("*/SKILL.md")):
|