> ## Documentation Index
> Fetch the complete documentation index at: https://rekko.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Correlation Analysis

> Cross-market correlation analysis for portfolio diversification.



## OpenAPI

````yaml POST /v1/correlation
openapi: 3.1.0
info:
  title: Rekko AI — Prediction Market Intelligence
  description: >-
    The brain for prediction market trading. Deep AI research, Bayesian causal
    decomposition, portfolio-aware strategy signals, cross-platform arbitrage,
    and execution guidance — all in one API. Covers Kalshi, Polymarket,
    Robinhood, and Coinbase. Clean flat JSON designed for developers and
    autonomous trading agents.
  contact:
    name: Rekko AI
    url: https://rekko.ai/
  license:
    name: Proprietary
  version: 1.0.0
servers:
  - url: https://api.rekko.ai
security: []
tags:
  - name: Markets
    description: Prediction market listings, history, resolution, and execution guidance
  - name: Insights
    description: AI-powered research insights with causal decomposition
  - name: Strategy
    description: >-
      Actionable trading signals with Kelly-derived position sizing and causal
      decomposition
  - name: Portfolio
    description: Portfolio-aware strategy, correlation analysis, and hedge recommendations
  - name: Arbitrage
    description: Cross-platform arbitrage detection (Kalshi vs Polymarket vs Robinhood)
  - name: Analytics
    description: Calibration metrics, sentiment, and performance tracking
  - name: Streaming
    description: Real-time SSE event stream and webhooks
  - name: Consensus
    description: Agent trade aggregation and crowd probability
paths:
  /v1/correlation:
    post:
      tags:
        - Portfolio
      summary: Cross-market correlation analysis
      description: Cross-market correlation analysis for portfolio diversification.
      operationId: /v1/correlation
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CorrelationRequest'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CorrelationGraph'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    CorrelationRequest:
      properties:
        market_ids:
          items:
            type: string
          type: array
          maxItems: 20
          minItems: 2
          title: Market Ids
          description: Market IDs to correlate
        platform:
          type: string
          title: Platform
          description: Platform for all markets
          default: kalshi
        period:
          type: string
          title: Period
          description: 'Lookback period: ''48h'', ''7d'', ''30d'''
          default: 7d
      type: object
      required:
        - market_ids
      title: CorrelationRequest
      description: Request for cross-market correlation analysis.
      example:
        market_ids:
          - KXFED-26MAR19
          - KXCPI-26MAR
          - KXUNEMP-4.5
        period: 7d
        platform: kalshi
    CorrelationGraph:
      properties:
        market_ids:
          items:
            type: string
          type: array
          title: Market Ids
          description: Markets analyzed
        platform:
          type: string
          title: Platform
          description: Platform
        period:
          type: string
          title: Period
          description: Lookback period used
        pairs:
          items:
            $ref: '#/components/schemas/MarketCorrelationPair'
          type: array
          title: Pairs
          description: All pairwise correlation coefficients
        clusters:
          items:
            items:
              type: string
            type: array
          type: array
          title: Clusters
          description: Groups of correlated markets (correlation > 0.5)
        concentration_warnings:
          items:
            type: string
          type: array
          title: Concentration Warnings
          description: Warnings about highly correlated pairs
        generated_at:
          type: string
          format: date-time
          title: Generated At
          description: When this analysis was generated
      type: object
      required:
        - market_ids
        - platform
        - period
      title: CorrelationGraph
      description: Cross-market correlation analysis.
      example:
        clusters:
          - - KXFED-26MAR19
            - KXCPI-26MAR
        concentration_warnings:
          - >-
            KXFED-26MAR19 and KXCPI-26MAR are highly correlated (0.73) — holding
            both creates concentration risk on Fed policy
        generated_at: '2026-03-21T14:30:00Z'
        market_ids:
          - KXFED-26MAR19
          - KXCPI-26MAR
          - KXUNEMP-4.5
        pairs:
          - correlation: 0.73
            data_points: 168
            market_a: KXFED-26MAR19
            market_b: KXCPI-26MAR
            relationship: strong_positive
          - correlation: 0.45
            data_points: 168
            market_a: KXFED-26MAR19
            market_b: KXUNEMP-4.5
            relationship: positive
          - correlation: -0.12
            data_points: 168
            market_a: KXCPI-26MAR
            market_b: KXUNEMP-4.5
            relationship: neutral
        period: 7d
        platform: kalshi
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    MarketCorrelationPair:
      properties:
        market_a:
          type: string
          title: Market A
          description: First market ID
        market_b:
          type: string
          title: Market B
          description: Second market ID
        correlation:
          type: number
          maximum: 1
          minimum: -1
          title: Correlation
          description: Pearson correlation coefficient
        data_points:
          type: integer
          minimum: 0
          title: Data Points
          description: Number of overlapping time points
        relationship:
          type: string
          title: Relationship
          description: >-
            'strong_positive', 'positive', 'neutral', 'negative',
            'strong_negative', or 'insufficient_data'
      type: object
      required:
        - market_a
        - market_b
        - correlation
        - data_points
        - relationship
      title: MarketCorrelationPair
      description: Pairwise correlation between two markets.
      example:
        correlation: 0.73
        data_points: 168
        market_a: KXFED-26MAR19
        market_b: KXCPI-26MAR
        relationship: strong_positive
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````