Skip to content
AI agents

Portfolio research with ChatGPT and Codex.

Connect ENSEMBLE to ChatGPT through the directory or Codex CLI via OAuth MCP to screen ETFs, build allocation models, and inspect retained runs.

By Updated 2 min read

ChatGPT and Codex CLI handle two complementary halves of quantitative investment work. ChatGPT is fast for conversational screening, framing hypotheses, and reviewing tear-sheet tradeoffs. Codex CLI shines when you are iterating directly on Python strategy files, writing reusable optimizers, or scripting CLI/API checks in a local repository.

Because both connect to the same remote ENSEMBLE MCP server (https://api.ensemble.markets/mcp), a model you draft in ChatGPT is immediately inspectable from Codex CLI, the web workspace, and the REST API.

Connecting ChatGPT vs. Codex CLI

Option 1: ChatGPT (Official plugin directory)

ENSEMBLE is published in the U.S. ChatGPT plugin directory (version 2.0.0; host plan and workspace settings apply). Visit the ChatGPT connection guide or follow three steps:

  1. Open ENSEMBLE in the ChatGPT plugin directory and select Install plugin.
  2. Sign in to your intended ENSEMBLE account via OAuth when prompted.
  3. Start a conversation and ask ChatGPT to confirm your connected ENSEMBLE account and available credit before building or running anything.

Option 2: Codex CLI (Terminal OAuth MCP)

If you work in the terminal with OpenAI Codex CLI, connect ENSEMBLE with two documented OAuth commands:

codex mcp add ensemble --url https://api.ensemble.markets/mcp
codex mcp login ensemble

Complete the OAuth sign-in flow in the browser window that opens, then launch Codex. Discover available tools directly from the connected MCP server rather than hardcoding a tool count.

Four high-signal workflows in ChatGPT and Codex

WorkflowBest clientWhat the agent executes via ENSEMBLE
ETF structure screeningChatGPTQueries list_assets and get_asset for tax form, reset cadence, exposure components, and prospectus citations
Rapid strategy prototypingChatGPTChecks data coverage and credit, creates a model with declared inputs_schema, and inspects baseline metrics
Custom Python & optimizer authoringCodex CLIEdits local strategy or optimizer Python, calls create_model with validate_only=true (free) before spending build credit
Matched-window sensitivity sweepsEitherRuns isolated tests (intent=test) varying one input at a time, then summarizes compare_runs over identical dates

Guardrails for safe agentic research

Follow three operational habits whenever working with ChatGPT or Codex on portfolio models:

  1. Confirm the workspace first. Start every session by confirming get_profile / get_account so you know which account and spending cap are active.
  2. Validate before spending. When supplying Python strategy code from Codex, run free validate_only checks to verify imports, runtime contract, and inputs_schema before launching a metered build.
  3. Keep tests separate from live defaults. Always ask the agent to run variations with intent=test and inspect compare_runs over matched dates before promoting a run or changing a scheduled model.

Connect ChatGPT or Codex now

Use the starter request below to connect your client, confirm your workspace, and build your first saved allocation model with explicit inputs and retained runs.

Start with this request

Use ENSEMBLE to confirm my connected account. Help me turn an investment idea into a saved allocation model. Establish the universe, rules and inputs with me, check data coverage and available credit, then build it and explain the saved results.

Frequently asked questions

How do I install ENSEMBLE inside ChatGPT?
Open ENSEMBLE in the U.S. ChatGPT plugin directory (v2.0.0), choose Install plugin, and sign in to your ENSEMBLE account via OAuth. Account and workspace access settings in ChatGPT control plugin availability. See /chatgpt for the current directory link and setup steps.
How do I connect ENSEMBLE to OpenAI's Codex CLI?
Run `codex mcp add ensemble --url https://api.ensemble.markets/mcp` followed by `codex mcp login ensemble` in your terminal, complete the browser OAuth sign-in, and start a Codex session. Both ChatGPT and Codex talk to the same ENSEMBLE workspace.
Can ChatGPT or Codex place live brokerage trades through ENSEMBLE?
No. ENSEMBLE is research and allocation infrastructure. Agents can screen assets, build and test models, compare runs, and prepare CSV or broker-format export files (on Business), but ENSEMBLE never connects to a brokerage to submit orders.
How do I prevent an agent from overwriting my live model defaults during a chat?
Ask the agent to run parameter variations with test intent (intent=test) and compare them with compare_runs over matching dates. Live defaults only change when you explicitly decide to promote a verified run.

Backtests are illustrative. Past performance does not guarantee future results. ENSEMBLE is a software platform, not an investment adviser.

Part of Keep investment research available across conversations..

Use the same models across MCP, REST API, CLI, and the web.Connect your agent