Add AI inference validation & retries, improve reporting, and harden data/clients#44
Merged
Rohan5commit merged 2 commits intoMay 19, 2026
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Description
disable_core_tradinginput, added core and AI retry steps, added aValidate Cerebrium primary configurationstep, aVerify Cerebrium predict endpointpreflight that POSTs a sample payload, updatedplan_ai_runtimeusage to considerTRAINED_MODEL_INFERENCE_URL, and added anEnsure Daily Email Coverageguard and more granular failure reporting conditions in/.github/workflows/daily_trading_bot.yml.email_notifier.pyto stop rewriting model reasons and instead return model-provideddecision_reason, includeperformance_period_startand detailed AI runtime metadata whensubject_tag == 'AI', and adjust pipeline summary behavior.ingest_prices.pyto iterate candidate tickers robustly, useon_bad_lines='skip', validate required columns, and log warnings rather than failing.llm_trader.pyadded neutral-breakout soft-cash deployment logic that can convert neutral predictions into directional signals under controlled criteria and introduced guards usingsoft_cash_deploy_enabledand whether positions are open.performance_period_startpropagation to core and AI reports inmain.py, suppressed rotation closes when the model signalled skipped reasons (e.g.all_neutral/no_action) and record aHOLDdecision, and addedget_performance_period_starthelper topositions.py.trained_model_client.pyadded support for additional provider name variants, improved retry/backoff logic including trying alternate prediction URL shapes on404, made/healthhandling tolerant for providers that lack a/healthroute, and exposed additional settings like backoff and batch sizing.Testing
Codex Task