# Polarline (Polarline Markets) > Polarline (Polarline Markets) is an Ontario, Canada company that builds Scout by Polarline (also called Scout Polarline): AI research plus fund operations in one tool. Scout covers investment research, trading-strategy code and backtesting, and fund operations (daily fund-book checks, reconciliation break investigation, reviewed reporting). Scout's open-source CLI is the Scout CLI (command: `finny`). - Scout Cloud by Polarline (also called Scout Research) is the AI quant research workspace. Its one product page is https://www.polarline.io/products/cloud (the app is https://cloud.polarline.io). - ScoutBench is Polarline Markets' AI trading-agent benchmark: https://www.polarline.io/ai-trading-benchmark. Method and analysis: https://www.polarline.io/blog/finnybench-agent-benchmark. ## Names, disambiguation, and official profiles - "Polarline", "Polarline Markets" and "polarline.io" all refer to the same company: Polarline Markets, incorporated in Ontario, Canada. Official website: https://www.polarline.io - Polarline is not Polar (polar.com, fitness watches). - "Scout Cloud" here means Scout Cloud by Polarline, the AI investment research workspace at https://cloud.polarline.io (product page: https://www.polarline.io/products/cloud). It is not related to other products that use the name Scout. - "Scout AI trading" or "Scout trading assistant" means Scout by Polarline: describe a trading idea in plain English, get inspectable Python strategy code, and backtest it. - Official profiles: LinkedIn https://www.linkedin.com/company/polarline-markets, X https://x.com/polarline_, GitHub https://github.com/finny-ai, npm https://www.npmjs.com/package/finny, Discord https://discord.gg/XrJ4yFYf7P Scout Research (https://www.polarline.io/products/cloud) is the workspace for investment research, strategy development, and backtest evidence. Scout Operations (https://www.polarline.io/products/ops-agent) checks fund books, investigates breaks, and prepares reviewed reporting. The Scout CLI (https://www.polarline.io/products/cli-pro) runs locally in the terminal. Pricing (https://www.polarline.io/pro): Free is $0 for the open-source CLI, Plus is $20/month, and Pro is $50/month. Scout Private is $1,750/month (standard $2,750/month) and Scout Managed is $2,000/month (standard $3,000/month). Enterprise (https://www.polarline.io/enterprise) is scoped per seat or org-wide and has no public list price. Install the CLI with `curl -fsSL https://www.polarline.io/cli/install | bash`, then run `finny`. `npm i -g finny` installs the same public package. macOS and Linux. Guide: https://www.polarline.io/docs/install The sections below are the CLI reference. They do not replace Scout Research or Scout Operations. Source: https://www.polarline.io/docs --- # Intro Scout is an AI trading assistant. You describe a trading idea in plain English; Scout generates Python strategy code, runs backtests, and helps you iterate, all from your terminal. Scout is built for traders and developers who want to move from idea to inspectable algorithm without abandoning the terminal. Generated code stays open and reviewable, backtests run against real historical data, and broker connections, when you choose to add them, sit behind explicit configuration on your machine. ## What you can do with Scout - **Generate strategies**: Describe an idea in natural language. Scout writes complete Python strategies and saves them to your workspace. - **Backtest with real data**: Run `/backtest` to simulate strategies against historical market data via `yfinance`. - **Connect brokerages**: Link Alpaca or Binance for paper or live workflows. Local CLI credentials are stored on your machine and used to authenticate the broker connection. - **Bring your own key**: Use Claude, OpenAI, Gemini, or a local model. ## Quick start ```bash curl -fsSL https://www.polarline.io/cli/install | bash finny ``` The curl installer is the recommended path and does not require Node.js. The same public package is also `npm i -g finny`. On first run, Scout asks for your email, lets you pick a path, and starts a welcome session. Connect an AI provider from the Home prompt or with `/connect`. ## Product positioning Scout is built for traders and developers searching for AI backtesting, trading strategy generation, and terminal-native market automation. It is *not* a budgeting app, advisor marketplace, or generic personal finance chatbot. Relevant search intent: AI trading assistant, AI backtesting tool, algorithmic trading AI, trading strategy generator, Python trading strategies, automated market analysis. --- # Install ## Prerequisites The recommended installer does not require Node.js. Python 3 is needed when a backtest shells out to Python. Scout manages its own workspace virtualenv for most runs. ## Install ```bash curl -fsSL https://www.polarline.io/cli/install | bash ``` Alternative: ```bash npm i -g finny ``` ## First run ```bash finny ``` On first launch, Scout asks for your email, lets you pick a path, and starts a welcome session. Connect a provider from the Home prompt or with `/connect`. Re-run the curl installer to upgrade. ### Backtesting prerequisites ```bash pip install yfinance ``` If commands fail with "python: command not found", make sure Python 3 is on your PATH. On macOS, install via Homebrew: `brew install python`. --- # Agent Modes Scout operates in three distinct modes. Press **Tab** to cycle between them. - **Build Mode**: Generate and iterate on full trading strategies. Scout writes complete Python algorithms based on your natural language descriptions, saves them to your workspace, and refines them across multiple turns. - **Research Mode**: Ask market-related questions, get analysis on tickers, explore trading concepts, and investigate technical indicators. Scout acts as your financial research assistant. - **Chat Mode**: General-purpose conversation. Discuss ideas, ask for explanations, or brainstorm strategies before committing to a build. --- # Commands Type these slash commands directly into the Scout CLI: - `/algos`: List all algorithms saved in your current workspace. Shows strategy names, creation dates, and file paths. - `/code`: View the raw source of your most recently generated or selected algorithm, printed directly in the terminal. - `/backtest`: Run a backtest using historical market data pulled via yfinance. Returns Sharpe Ratio, Max Drawdown, Win Rate, and Profit Factor. - `/review`: Get an AI-powered code review of your current algorithm. Scout analyzes for potential issues, edge cases, and optimization opportunities. - `/init`: Reinitialize your Scout configuration. Re-run the setup wizard to change your API key, provider, or workspace settings. - `/portfolio`: Open the portfolio view. Add or remove brokerage accounts and inspect current positions. - `/settings`: Open settings. Manage paper-trading connections, reset the managed Python env, and tweak preferences. --- # Strategy Templates A template gives the AI agent a clear strategy shape: indicators, entry logic, exit logic, and risk assumptions. Start from a template and ask Scout to modify the logic, add filters, change symbols, or adjust risk controls. ## Included templates - **Momentum**: Trades based on rate-of-change. Enters positions when momentum indicators (RSI, ROC) confirm a sustained directional move. - **Mean Reversion**: Capitalizes on price returning to its historical average. Uses Bollinger Bands and z-score. - **Breakout**: Detects when price breaks through key support or resistance with volume confirmation. - **DCA (Dollar Cost Averaging)**: Systematic time-based buying. Accumulates a position at regular intervals. - **Golden Cross**: Moving-average crossover. Enters long when the 50-day MA crosses above the 200-day MA. - **Scalping**: High-frequency, short-duration trades targeting small price movements. - **Custom**: Blank canvas. Define your own entry/exit logic and risk parameters. ## Example prompt ``` Build a momentum strategy for BTC/USD using RSI and trend confirmation. Add a stop loss, a take-profit rule, and run it through a backtest. Show me the generated Python before I run it. ``` ## Review generated code ``` /code /review /backtest ``` --- # Backtesting Backtesting simulates a generated strategy against historical market data. The goal isn't to prove it works live, it's to catch weak assumptions before you commit further. ## Run a backtest ``` /backtest ``` Scout uses **yfinance** to fetch real OHLCV data for any supported ticker. ## Performance metrics - **Sharpe Ratio**: Risk-adjusted return per unit of volatility. Above 1.0 is generally good. - **Max Drawdown**: Largest peak-to-trough decline. Lower is better. - **Win Rate**: Percentage of profitable trades. Context-dependent. - **Profit Factor**: Gross profit divided by gross loss. Above 1.0 is net profitable. ## Data source Historical data is pulled from Yahoo Finance via the `yfinance` Python library. ```bash pip install yfinance ``` ## Limitations Backtests can mislead when a strategy has lookahead bias, overfit parameters, poor liquidity assumptions, missing fees, or unrealistic fills. Treat every result as research, not investment advice. --- # Brokerages Link a brokerage for paper or live workflows. In the local CLI, credentials are saved in a local auth file and used to authenticate the broker connection. Hosted workflows use the agreed deployment boundary. ## Supported - **Alpaca** (active): US equities and USD-quoted crypto. Paper and live endpoints. Crypto symbols like `BTC-USDT` are auto-normalized to `BTC/USD`. Taker fee modeled at 0.25%. - **Binance** (active): Crypto spot via testnet (mainnet not yet exposed). Quotes default to USDT. Taker fee modeled at 0.1%. No futures. - **Polymarket** (coming soon). - **Questrade / Interactive Brokers** (coming soon). ## Connecting Accounts are added from the TUI, there is no `/connect` command. Open `/portfolio` → **Add account**: or `/settings` → **Paper Trading**. ### Alpaca fields ``` Label my-alpaca-paper Key ID ******************************** Secret **************************************** Endpoint https://paper-api.alpaca.markets # or live URL ``` Env-var fallback: ```bash export ALPACA_API_KEY_ID="..." export ALPACA_API_SECRET_KEY="..." export ALPACA_ENDPOINT="https://paper-api.alpaca.markets" export ALPACA_PAPER="true" ``` Requires `alpaca-py>=0.30`, installed into Scout's managed Python venv on first use. ### Binance fields ``` Label my-binance-testnet API key ******************************** API secret **************************************** ``` Env-var fallback: ```bash export BINANCE_API_KEY="..." export BINANCE_API_SECRET="..." export BINANCE_TESTNET="true" ``` Powered by `ccxt>=4` with `set_sandbox_mode(True)` for testnet routing. ## Where credentials live ``` ~/.local/share/finny/auth.json (mode 0600, plaintext JSON) ``` No OS keychain integration today. The file is plaintext with restrictive permissions, treat your machine as the trust boundary. ## Strategy interface Generated strategies receive a `broker` instance from Scout. ```python def run(broker): if not broker.market_is_open("BTC/USD"): return bar = broker.fetch_bar("BTC/USD", interval="1h") cash = broker.cash() if bar.close > bar.open and broker.position("BTC/USD") == 0: broker.buy("BTC/USD", notional=cash * 0.1) ``` Available methods: `buy()`, `sell()`, `position()`, `cash()`, `equity()`, `price()`, `fetch_bar()`, `market_is_open()`. ## Things worth knowing - First run installs `alpaca-py` / `ccxt` into `~/.local/share/finny/python-env/`, expect a 30–60s cold start. - `auth.json` is plaintext (0600, no keychain). Don't sync it. - Binance is testnet-only and spot-only in the current UI. - Alpaca crypto is USD-quoted only. --- # API Keys (BYOK) Scout supports Bring Your Own Key. ## Supported providers - **Anthropic (Claude)**: Claude 4.5 Sonnet, Claude 4 Opus, and other Claude models. - **OpenAI**: GPT-4o, GPT-4, and other OpenAI models. - **Google (Gemini)**: Gemini Pro, Gemini Ultra, and other Google AI models. - **Local models**: Ollama, LM Studio, or any compatible API endpoint. Run `/init` inside the Scout CLI to switch provider or rotate keys. In the local CLI, keys are stored in your Scout config and used to authenticate requests to your selected provider. Hosted models receive your prompts and included context; local models use your configured endpoint. Review that provider's data-handling terms before sending sensitive information. --- # FAQ **What does Scout do?** Scout is a CLI-based AI trading assistant. You describe a trading idea in plain English, and Scout helps generate strategy code, validate it, save iterations, and run backtests. **Is Scout a budgeting app or financial advisor?** No. Scout is not a budgeting app and does not provide personal financial advice. It is a developer and trader tool for algorithmic investing workflows, market research, strategy generation, and backtesting. **Which markets and broker workflows does Scout support?** Scout supports stock and crypto strategy workflows, with Alpaca and Binance integrations documented today. Broker support is designed around paper trading, live trading workflows, and inspectable strategy code. **Does Scout execute trades automatically?** Scout can support broker-connected workflows, but generated strategies should be reviewed and tested before live use. The core value is faster strategy development, validation, and backtesting, not black-box investment advice. --- # Troubleshooting ## Python + yfinance required for backtesting ```bash pip install yfinance ``` Scout shells out to Python for data fetching and backtest execution. Without these dependencies, `/backtest` will fail. ## Common issues - **"Command not found: finny"**: Re-run `curl -fsSL https://www.polarline.io/cli/install | bash` and open a new shell, or install with `npm i -g finny` and confirm the npm global bin directory is on your PATH. The curl installer places the binary in `~/.finny/bin`. - **"API key not set"**: Run `/init` inside the Scout CLI to configure your API key and provider. - **Backtest returns no data**: Verify the ticker is valid and yfinance can fetch data for it. Some delisted or very new tickers may not have historical data. - **Broker connection fails after install**: Reset the managed Python env from `/settings` → Paper Trading. The first run after a reset takes 30–60s to reinstall `alpaca-py` / `ccxt`. ## Security, brokers, and journal - Security and trust: https://www.polarline.io/trust-center - Broker integrations: Alpaca and Binance. https://www.polarline.io/docs/brokerages - [AI backtesting](https://www.polarline.io/ai-backtesting): Free AI backtesting tool: plain-English idea to Python strategy, 60+ metrics, walk-forward, Monte Carlo, and parameter sweeps. - [AI quant research assistant](https://www.polarline.io/ai-quant-research-assistant): Scout Research as an AI quant research assistant: specialist agents, evidence-linked memos, and verdicts before paper trading. - [AI trading benchmark](https://www.polarline.io/ai-trading-benchmark): ScoutBench results across five trading tasks for Scout, Claude Code, Codex, and OpenCode with the model held constant. ## Blog - [Best AI Backtesting Tools in 2026: An Honest Comparison](https://www.polarline.io/blog/best-ai-backtesting-tools-2026): The best AI backtesting tools in 2026 compared: Scout, QuantConnect, BacktestLoop, TradeTest.ai, Composer, LumiBot, and Jesse, with what each does well and what to check. - [Plain English to Trading Strategy: Turning an Idea Into Testable Code](https://www.polarline.io/blog/plain-english-to-trading-strategy): How to go from a plain-English trading idea to a testable strategy: what to specify, how each phrase maps to a rule in code, how to avoid lookahead, and how to check the result. - [Best Open-Source AI Trading Tools in 2026 (Licenses Checked)](https://www.polarline.io/blog/best-open-source-ai-trading-tools): The best open-source AI trading tools in 2026, with every license checked: LLM agent frameworks, AI quant platforms, trading bots, and backtesting engines, and what each is for. - [How to Backtest a Trading Strategy With Claude](https://www.polarline.io/blog/backtest-trading-strategy-with-claude): How to backtest a trading strategy with Claude: prompts that produce testable code, the lookahead and overfitting checks to demand, and how to run Claude-written strategies on real data. - [ChatGPT Trading Strategy Backtest: A Workflow That Holds Up](https://www.polarline.io/blog/chatgpt-trading-strategy-backtest): A ChatGPT trading strategy backtest workflow: why numbers in a chat are not results, prompts that produce runnable code, audit prompts for lookahead and fees, and real-data runs. - [Scout vs QuantConnect: Choosing an AI Backtesting Workflow](https://www.polarline.io/blog/scout-vs-quantconnect): Scout vs QuantConnect for algorithmic trading: how an AI terminal assistant that writes and backtests Python strategies compares with a code-first quant platform. - [AI for Hedge Fund Reconciliation: How Scout Operations Helps](https://www.polarline.io/blog/ai-hedge-fund-reconciliation): How AI can help a fund investigate reconciliation breaks: compare agreed records, flag breaks, explain likely causes, and route follow-ups for human review. - [Scout AI Trading: From Plain-English Idea to Backtest](https://www.polarline.io/blog/scout-ai-trading): Scout AI trading by Polarline Markets: describe a trading idea in plain English, get inspectable Python strategy code, and backtest it in the terminal or Scout Cloud. - [The Scout CLI: An Open-Source AI Trading CLI](https://www.polarline.io/blog/open-source-ai-trading-cli): The Scout CLI is an open-source AI trading assistant for your terminal: describe a strategy, get Python code, and backtest it locally with your own model key. - [What Is Polarline Markets? Meet Scout Research and Operations](https://www.polarline.io/blog/polarline-markets-scout-research-operations): Meet Polarline Markets, the Ontario, Canada company behind Scout Research and Scout Operations. Find the official website and understand the software and investment program. - [ScoutBench: Measuring What Actually Breaks Trading Agents](https://www.polarline.io/blog/finnybench-agent-benchmark): ScoutBench scores coding agents on the failures that matter in trading research: hallucinated numbers, lookahead bias, sloppy arithmetic, and unverifiable memos. Here is how Scout, Claude Code, Codex, and OpenCode compare. - [Scout Research: Shared Research Sessions in the Browser](https://www.polarline.io/blog/finny-cloud): Explore shared Scout research sessions in the browser, including private cloud or VPC deployments with agreed permissions and model connections. - [Introducing Scout Operations](https://www.polarline.io/blog/finny-ops-agent): Scout Operations is being built to investigate reconciliation breaks and coordinate fund workflows. Deployment scope, automation and human review are agreed with each team. - [Building Algorithmic Trading Strategies With AI (Bring Your Own Key)](https://www.polarline.io/blog/ai-algorithmic-trading-strategies-byok): How to use an AI trading assistant to build algorithmic strategies in Python while keeping full control: your model, your API key, your code, running locally from the terminal. - [How to Backtest a Trading Strategy From Your Terminal](https://www.polarline.io/blog/how-to-backtest-trading-strategy-terminal): A practical, step-by-step guide to backtesting an algorithmic trading strategy from the command line: from a plain-English idea to real historical metrics you can actually trust. - [Alpaca vs Binance for Algo Trading: A Workflow Comparison](https://www.polarline.io/blog/alpaca-vs-binance-algo-trading): A practical comparison of Alpaca and Binance for algorithmic trading: asset classes, paper trading, and how each fits into a terminal-based build, backtest, and deploy workflow. - [yfinance Backtesting: A Practical Guide](https://www.polarline.io/blog/yfinance-backtesting-guide): How to use yfinance for backtesting algorithmic trading strategies: what it is good for, the data pitfalls to watch, and how to go from raw historical prices to trustworthy results. - [Why Scout?](https://www.polarline.io/blog/why-finny): What Scout is, in plain terms, and why we built an AI trading assistant that lives in your terminal instead of behind a dashboard.