Conversation
Farrell-A
marked this pull request as ready for review
September 12, 2026 05:46
3 of 8 tasks
This was referenced Sep 29, 2026
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.
Summary
Production LEAN can connect to an Interactive Brokers Financial Advisor master and can attach IB FA order properties, but currently does not expose a coherent visibility of the underlying managed accounts and unified Allocation Groups. This PR implements opt-in unified Interactive Brokers Financial Advisor account services and allocation-group routing on top of the brokerage-neutral contracts in the companion LEAN PR. This gives advisers granular visibility and control of client accounts, and allows advisers to ensure that client accounts are managed in alignment with the algorithm intent.
This closes: QuantConnect/Lean.Brokerages.InteractiveBrokers#259
** This is part of a coordinated multi-repo feature release. See the attached files for thorough details**
Use cases
Solves:
groups in live trading. IBKR FA Group allocation causes drift between algorithm intent and actual
holdings for individual sub accounts across several inevitable edge cases that are currently invisible.
following intent because Client D added money to their brokerage account.
Enhancements:
A execute orders to make it in alignment with Group B intent and then move the account to Group B.
from trading for N days so it doesn't immediately trade what was intentionally liquidated.
Downstream effect is to be able to create methods similar to setHoldings for groups in an algo that ensures
each individual sub account is in alignment with algo intent, and not just allocated based on IBKR computed
methods that lack realistic case-management.
routed to groups, or individual client accounts that may or may not be in a group.
What changed
FailedorStale; LEAN, the brokerage connection, and the worker continue running, and a later refresh can retry.Compatibility
QuantConnect.IBAutomater2.0.93 upgrade and the companion LEAN FA contracts.Validation
fav2LEAN source and a freshly packed, isolatedQuantConnect.IBAutomater2.0.93 feed: 0 errors.Readytwo-account snapshot with no IB errors. Independent pre/post audits showed zero open orders, zero positions, and unchanged topology.InteractiveBrokersBrokerage.csmatches current upstream concurrency counts: 17lock (/ 3Interlocked./ 0Task.Run.The pre-existing Composer smoke test was not part of the focused run because its implicit job is invalid when no local IB trading-mode configuration is supplied. The focused suites and guarded live-paper matrix cover the FA-specific factory-to-Gateway behavior.
Related PRs and sequencing
The coordinated PRs can be reviewed concurrently, but their release has package and platform dependencies:
The hosted deployment schema/UI must expose the unified-groups and group-management inputs under their exact brokerage-data keys. That platform work is external to this repository.
IBAutomater version: Updated 2.0.93 to be in alignment with the linked PRs. Update required with version drift.
Files attached explaining the full fav2 linked PR scope across repos, and testing conducted
fav2_live_verification_report.md
fav2_enhancement_summary.md
enhancement_change_inventory.md
enhancement_goals_findings.md
enhancement_scope.md
test_file_scope.md
Documentation
This update requires documentation changes. A separate PR is open for the documentation changes.
Types of changes
Checklist: