Follow this worked strategy
I connected Codex to the NexusTrade trading API and had it research NVDA, freeze intraday momentum rules, and inspect a five-fold walk-forward study with fee reruns and a trade audit. The agent operated this workflow through NexusTrade's MCP server; it did not build the integration. Native selection returned 14.13% against continuous NVDA at 49.20%, and one replay discrepancy stays open.
Follow the full journey
Connect Codex
Add the NexusTrade server
codex mcp add nexustrade --url https://nexustrade.io/api/mcpScroll horizontally to read the full command, or copy it.
In the desktop app, open Settings, then MCP servers and Add server. Enter nexustrade as the name, choose Streamable HTTP and paste the URL shown above. Save, select Restart and choose Authenticate when the server requests OAuth. Sign in to NexusTrade in the browser. Type /mcp in the composer to check connected servers.
Sign in to your NexusTrade account
codex mcp login nexustradeScroll horizontally to read the full command, or copy it.
Complete browser sign-in, then start Codex and use /mcp to inspect the connected server. The desktop app, CLI and IDE extension share the local MCP configuration. ChatGPT web does not read this local configuration.
The result identifies Apple's company filing, filing date and source URL. The connection check makes no account changes.
Inspect the request
Research NVDA and the NVD inverse ETF
Read NVIDIA company filings and the NVD daily inverse objective separately. The bearish rule buys actual NVD shares, whose daily reset and price tape matter.
A dated brief names the instrument, original sources and assumptions that matter to this strategy.
Inspect the request
Inspect the frozen intraday candidate
Preview the latest fixed research candidate copied from its saved rules: NVDA momentum or NVD breakdown, one position at a time, session entry limits and day-end exits. The quarterly selection study below uses separate winners by fold.
- NVDA entry
- 5-minute return ≥ 0.75%; above VWAP; relative volume ≥ 1.5; buy 99% of buying power while flat
- NVD entry
- NVDA below prior 60-minute low, VWAP and 5-calendar-day observed-price mean; relative volume ≥ 1.5; buy 49.5% while flat
- Session
- Enter 10:00 to before 15:20 Eastern; liquidate at 15:40; skip specified early closes
- Exits
- NVDA: 1% loss / 3% gain. NVD: 2% loss / 2% gain; inspect the saved rule JSON.
The preview contains four exact entry/exit rules. The latest fixed candidate uses a five-calendar-day observed-price mean and 2% NVD stop and profit thresholds.
- Quarterly strategy selection (native) 2026-09-30, 00:00:00 UTC
- 11,412.66
- Continuous NVDA 2026-09-30, 00:00:00 UTC
- 14,920.48
Inspect the walk-forward study and cost sensitivity
The chart chains five separately selected quarterly candidates. It is evidence about that selection procedure, not a backtest of the latest fixed candidate above. Inspect the shorter ordinary replays and fee sensitivity below.
- First recorded mark
- Jul 2, 2025 · 08:01:00 UTC
- Last recorded mark
- Sep 30, 2026 · 00:00:00 UTC
- Vertical axis range (USD)
- 9644.75 to 15521.98
The five-fold native selection returned 14.13% versus continuous NVDA 49.20%. The shorter ordinary replay returned 16.38% versus 14.17%, with a first-fold native/replay discrepancy still open.
Inspect the request
Observe NVDA intraday momentum and NVD breakdown in paper trading
Observe the fixed four-rule candidate with minute evaluations and Eastern session limits. Record the signal-to-fill delay and check that the day-end liquidation closes both instruments.
- Inspect before accepting an order
- One NVDA/NVD holding at a time, the filled-buy cooldown, minute evaluation, early-close exclusions and day-end liquidation.
Your paper portfolio has its own ID, start date, schedule and dated history. These forward observations begin with your own run.
Inspect the request
Review NVDA intraday momentum and NVD breakdown for live deployment
Review equity and inverse-ETF support together with evaluation timing and account restrictions. The live target must preserve the fixed rules you actually observed in paper.
Open the live deployment walkthrough- Account and instrument review
- NVDA/NVD eligibility, fractional support, buying power, minute scheduling, session exits, early closes and order approval.
The review identifies the target account, supported instruments, rule changes and approval settings before confirmation.
Inspect the request
Follow the Codex session
codex mcp add nexustrade --url https://nexustrade.io/api/mcpScroll horizontally to read the full command, or copy it.
This guide runs on NexusTrade's MCP server. Codex operated the trading workflow below, from connection to the live review. The agent's role here is operating the workflow through that server.
The table names the tool call, the approval checkpoint, and the artifact to keep at each stage. Placeholders such as a returned draft ID stand for values your own run returns. This page records no IDs from anyone else's run.
The recorded anchor is the walk-forward study, the fee reruns, and the trade audit below, including the unresolved first-fold replay difference.
Show the table · 6 rows, 4 columns
Scroll sideways to compare all columns. Select a heading to sort.
| Connect Codex | sec_edgar list_filings for AAPL with limit 1 | Public read only. No portfolios, ingested filings, or changes. | Filing company, form, date, and source URL |
| Research NVDA and NVD | NVDA filings plus the NVD fund prospectus | Dated brief with sources. The NVD daily reset and allocations stay explicit. | Dated NVDA and NVD brief |
| Draft the rules | build_portfolio preview, then one create_portfolio | Approve the rules before saving. Stop before paid tests. | Returned draft ID with a readback |
| Test history | Minute backtest inside supported data and compute limits at $10,000 | Show dates, rules, and estimated cost before submission. | Fixed-candidate result, kept separate from the selection study |
| Trade on paper | Separate paper-only deployment at $10,000 | Show the plan. Verify the portfolio is paper. | Running paper ID and dated history |
| Review live | Live deployment review against the actual account | Live trading stays unchanged until explicit confirmation. | Reviewed plan, or a stop report when unsupported |
No matching rows. Clear the filter to see all records.
Where Codex stops for approval
Each consequential action in this guide waits at an approval gate. The agent previews first and acts only after explicit approval.
The rules preview returns valid and issues before anything is saved. The agent resolves problems and re-previews instead of saving a candidate with open problems.
Approve the rules before the agent saves them
The agent previews the configuration with build_portfolio and shows entry, sizing, exits, valid, and issues. It saves with create_portfolio only after approval and reads the returned draft back.
Approve the test cost before the agent submits once
Historical tests are paid runs. The agent shows the exact request and estimated cost for approval before submitting once, then polls the same returned test ID until complete.
Approve the paper plan and verify it is paper
The paper deployment is a separate portfolio with its own ID. The agent shows the plan for approval, verifies the deployment type, and leaves brokerage accounts unchanged.
Confirm the live move explicitly, or nothing moves
The agent reads the actual account and broker capabilities first and keeps live trading unchanged until explicit confirmation. It reports an unsupported instrument or action and stops.
The nine-month lead and its replay discrepancy
- Selected strategies (ordinary replay) 2026-04-01, 00:00:00 UTC
- 11,637.93
- Continuous NVDA 2026-04-01, 00:00:00 UTC
- 11,416.98
Show the table · 3 rows, 4 columns
Scroll sideways to compare all columns. Select a heading to sort.
| 2025-07-02 to 2025-09-30 | 0.65% | 0.80% | 28 |
| 2025-10-01 to 2025-12-30 | 5.51% | 5.51% | 39 |
| 2025-12-31 to 2026-03-31 | 9.43% | 9.43% | 39 |
No matching rows. Clear the filter to see all records.
The native optimizer reported 16.20% across the first three test blocks. Separate ordinary backtests of the selected rules reported 16.38%, versus continuous NVDA's 14.17%. The last two folds matched exactly, including all 77 daily NAV samples in each. The first fold differed by 0.15821 percentage points despite the same 28 round trips. Its cause remains unresolved.
The chart below uses ordinary replay NAV. Its 230 matched observations gave 5.08% sampled drawdown versus 21.25% for NVDA. The longer chart uses the native five-fold path. Keeping the paths separate avoids silently substituting the more favorable replay result into the native study.
The comparison curve is continuous NVDA rather than SPY because the candidate trades NVDA and its inverse ETF. Keep that benchmark scope attached to the return and drawdown figures.
Higher costs erased the limited-period lead
The same selected replay portfolios were rerun at higher fees without another optimization. They retained the same round-trip counts. At 6 basis points per fill, the compounded return was 14.95%, still just above NVDA's 14.17%. At 10 basis points it fell to 9.40%.
These are actual fee reruns on submitted notional, not a deduction estimated from trade counts. Next-bar price changes are already reflected in modeled fills. A larger flat fee does not establish quote-based spread and market-impact realism. The NVDA benchmark is a continuous holding-price path without repeated strategy trading fees; this comparison does not separately certify dividend total returns.
Show the table · 3 rows, 3 columns
Scroll sideways to compare all columns. Select a heading to sort.
| 5 bps | 16.38% | 14.17% |
| 6 bps | 14.95% | 14.17% |
| 10 bps | 9.40% | 14.17% |
No matching rows. Clear the filter to see all records.
How the walk-forward selection worked
Training expands from January 2, 2025. Each fold has an earlier training window, a five-day embargo, a validation window and then a 91-calendar-day test block. The exhaustive grid has 36 settings: rolling means of 5, 20, 50 or 100 calendar days; inverse stops of 1%, 2% or 4%; and inverse profit targets of 2%, 4% or 6%. The other entry rules, long exits, sizing and fees stay fixed. Validation percent return selects the winner before its next test block.
The five-fold continuation preserves the first three fold calendars. The first three winners use a five-calendar-day mean and 2% inverse profit target, with inverse stops of 2%, 1% and 2%. The last two use means of 5 and 50 calendar days, 4% inverse stops and 2% profit targets.
Chronological splitting limits within-study lookahead, but the researchers inspected these historical dates repeatedly while changing strategy families. All reported results are retrospective development evidence. They are not a fresh independent out-of-sample test. A future test would require freezing both the rules and the selection procedure before observing new data.
Show the table · 5 rows, 5 columns
Scroll sideways to compare all columns. Select a heading to sort.
| 1 | 2025-05-21 | 2025-05-22 to 2025-05-26 | 2025-05-27 to 2025-07-01 | 2025-07-02 to 2025-09-30 |
| 2 | 2025-08-02 | 2025-08-03 to 2025-08-07 | 2025-08-08 to 2025-09-30 | 2025-10-01 to 2025-12-30 |
| 3 | 2025-10-14 | 2025-10-15 to 2025-10-19 | 2025-10-20 to 2025-12-30 | 2025-12-31 to 2026-03-31 |
| 4 | 2025-12-26 | 2025-12-27 to 2025-12-31 | 2026-01-01 to 2026-03-31 | 2026-04-01 to 2026-06-30 |
| 5 | 2026-03-08 | 2026-03-09 to 2026-03-13 | 2026-03-14 to 2026-06-30 | 2026-07-01 to 2026-09-29 |
No matching rows. Clear the filter to see all records.
Exact calendar dates in Eastern time. The embargo sits between training and validation. Training starts January 2, 2025 in every fold.
What the trade audit established
The three ordinary replays produced 212 filled orders and 106 closed round trips. The audit reconciled cash, quantities and fees, found no direct stock shorts or simultaneous NVDA/NVD positions, and confirmed that all audited positions closed each day. Entries met the time limits. Eighteen sampled signal events had expected trigger values and no indicator errors; the full signal-causality history was not audited.
A representative NVD sale was about 763 shares. Twelve surrounding minute bars showed 1.45 million shares traded and no zero-volume bars, but the probe returned no bid/ask quote. That checks activity near one order, not the spread or impact of every fill. The first-fold replay difference remains open. The two additional native test folds were not independently certified with an exhaustive order audit.
Show the table · 3 rows, 5 columns
Scroll sideways to compare all columns. Select a heading to sort.
| 1 | 3 | $403.99 | 25 | $-323.60 |
| 2 | 9 | $348.60 | 30 | $202.04 |
| 3 | 7 | $254.70 | 32 | $687.87 |
No matching rows. Clear the filter to see all records.
Dollar P&L from independently audited round trips in each replay, which starts with $10,000. These dollar amounts are not a continuously compounded portfolio attribution.
Inspect the session and execution settings
Inspect exact session settings
Scroll sideways to compare all columns. Select a heading to sort.
| Initial capital and shares | $10,000; fractional shares; one NVDA or NVD position at a time |
| Entry window | At or after 10:00 and before 15:20 Eastern |
| Filled-buy cooldown | More than 60 minutes for NVDA; more than 720 minutes for NVD on the shared filled-buy clock |
| Daily entry bound | Six buys; observed maximum three, with at most one bearish buy |
| NVDA exits | Position loss reaches 1%, gain reaches 3%, or 15:40 Eastern liquidation signal |
| NVD exits | Selected stop or profit threshold, or 15:40 Eastern liquidation signal |
| Early closes | Skip July 3, December 24 and the Friday after Thanksgiving when markets close early |
| Modeled execution | Observed audit delays of 1 to 2 minutes; thresholds trigger orders and do not guarantee fill prices |
| Base fee | 5 basis points (0.05%) per fill on submitted notional |
No matching rows. Clear the filter to see all records.
No comments yet.