Docs
AI Assistant

Models and Routing

How EQUIRE routes AI workloads across model tiers, attributes usage to your organization, enforces zero-retention, and applies per-task timeouts.

EQUIRE runs every AI request through the Vercel AI Gateway when configured, with a direct-Anthropic fallback. Each workload is bound to a model tier (semantic alias) and a feature tag (workflow it originated from). Tier and tag together determine the exact model used, the data-handling guarantees applied, and how the request is attributed to your organization.

Gateway routing is multi-provider when a model passes compatibility gates (capabilities, Anthropic-only rules, and — when platform Zero Data Retention is on — Corbis ZDR overlay). Shipped defaults stay on the Claude family below; additional frontier models may appear as opt-in pilots (admin or per-run override), not as the platform auto-default.

Model Tiers

The platform exposes five semantic aliases. Code calls a tier by name; the resolver picks the concrete model based on whether the Gateway is in play.

TierPurposeGateway modelDirect fallback
chatGeneral reasoning, deal Q&A, draftinganthropic/claude-sonnet-4.6claude-sonnet-4-6
fastCheap classification, gap detection, simple summariesanthropic/claude-haiku-4-5claude-haiku-4-5
criticalHighest-stakes reasoning — IC memo critical sections, expert opinionanthropic/claude-opus-4.7claude-opus-4-7
extractionDocument extraction with long context (up to 64k tokens)anthropic/claude-sonnet-4.6claude-sonnet-4-6
verificationLightweight second-pass verification of extracted valuesanthropic/claude-haiku-4-5claude-haiku-4-5

Aliases let admins swap underlying models without touching feature code. Calling chat always returns the currently-blessed mid-tier model, even after a version bump.

Gateway versus Direct Fallback

  • Gateway (preferred) — used when AI_GATEWAY_API_KEY or a Vercel OIDC token is configured. Adds attribution, optional zero-retention (platform toggle), and unified routing across providers.
  • Direct Anthropic — used when only ANTHROPIC_API_KEY is set. Same Claude models, but no Gateway-side attribution metadata; embeddings are not available on this fallback.

The platform does not silently mix providers on a single request. If you have only Anthropic configured, every request uses Anthropic; if the Gateway is configured, eligible requests use the Gateway.

How Features Map to Tiers

Every workload that calls the AI is tagged with a feature (from a closed enum). The tag drives both attribution and the default tier. Admin overrides (below) can change the model behind a feature without changing the tag.

Chat Surfaces

Feature tagDefault tierNotes
chatchat (Sonnet)Deal-mode chat assistant
portfolio-chatchat (Sonnet)Portfolio-mode chat
mandate-dashboardchat (Sonnet)Mandate-dashboard advisor
digestchat (Sonnet)Prospecting digest narrative

Documents and Extraction

Feature tagDefault tierNotes
document-processingextraction then verificationSonnet 64k for the extraction pass; Haiku 8k for the verification pass

document-processing is the umbrella tag for the entire ingestion pipeline. Extraction and verification share the same tag so usage reports show one line for the workflow rather than splitting across passes.

IC Memo

ic-memo mixes tiers section-by-section based on stakes:

  • Opus (critical) — Executive Summary, Investment Thesis, Market Analysis, Risk Factors
  • Sonnet (chat) — all other narrative sections
  • Haiku (fast) — section classification and gap detection

The mix is fixed in code rather than configurable per memo, so every memo gets the same provenance posture. Admin overrides can swap the model under any tier without changing the section-to-tier mapping.

Other Workflows

Feature tagDefault tierNotes
expert-opinioncritical (Opus)Per-assumption expert commentary
valuationchat (Sonnet)Valuation analyst pipeline
deal-health-coherencechat (Sonnet)Tier-2 coherence analyzer
deal-health-deep-scanchat (Sonnet)Tier-3 deep scan
researchchat or fastSonnet for narrative, Haiku for filtering
originationchat (Sonnet)Origination AI advisor and prospect briefs
organization-enrichmentchat (Sonnet)Org research cache
corbis-researchchat (Sonnet)Corbis MCP research agent
deliverablechat (Sonnet)Deliverable drafting
image-genn/aImage generation routes through a separate provider, not the LLM stack

Anthropic-Only Features

A small set of features is restricted to Anthropic models even when the Gateway has alternatives configured:

  • document-processing
  • extraction (legacy alias retained for older usage rows)
  • deal-health-deep-scan

These features rely on capabilities — native PDF vision, long-context caching, multi-step reasoning depth — that are currently best-served by Anthropic. If an admin tries to override one of these to a non-Anthropic model, the override is silently rejected and the default tier is used. The admin UI shows the same restriction so the constraint is visible up front.

Additional frontier models (pilot)

EQUIRE can route selected non-Claude models as opt-in pilots (admin feature override or per-run model picker). They are not the platform auto-default and must not be promoted to the platform-wide default without the promotion gate.

Grok 4.5 (xai/grok-4.5) is the current frontier pilot: listed on the Gateway, surfaced in Admin Model Config via frontier pilots, and selectable when platform ZDR is off. With ZDR on, Grok appears with a not ZDR badge but cannot be saved as an override — the Gateway has no ZDR route for this model (NoZdrProvidersError), and Corbis marks gatewaySupportsZeroDataRetention=false. Never used for Anthropic-only extraction/document-processing/deal-health-deep-scan. Server-side reasoning effort is pinned for cost and latency; UI streams set sendReasoning: false (AI SDK 7 default is true) — effort pin does not stream chain-of-thought to the UI.

Admin Overrides

Platform admins can override the model behind any feature tag without changing application code. Overrides live in Supabase (credeals.platform_ai_config) and are read with a 60-second in-memory cache.

The admin UI draws candidates from the live Gateway catalog, filtered by feature compatibility (capability tags, ZDR policy when enabled, and Anthropic-only rules). Frontier pilots (e.g. Grok 4.5) stay visible under ZDR-on with a not ZDR badge; saving a non–ZDR-compliant override returns 409 until platform ZDR is off or the model gains a ZDR route. Toggle ZDR at Admin → Model Config → Gateway controls → Zero Data Retention (/admin?tab=model-config). Clearing an override returns the feature to its default tier on the next cache refresh.

Override changes take effect within 60 seconds; there is no application restart required.

Gateway Attribution

Every AI call goes out with attribution metadata so usage reports, audit trails, and cost analytics line up with the workflow that triggered the call.

What Gets Sent

  • feature — the workflow tag (e.g. ic-memo, valuation, chat)
  • org — your organization ID, omitted only for system-level calls with no org context
  • user — the user who initiated the action, when available
  • zeroDataRetention — follows the platform ZDR toggle (credeals.platform_ai_settings.gateway_zero_data_retention); default on, super-admin can disable. Document-processing may omit ZDR when prompt-cache is enabled for that feature.

Telemetry Allowlist

EQUIRE writes telemetry events to its own observability layer alongside the Gateway. The allowed metadata keys are limited to a closed set including feature, orgId, surface, documentType, documentId, attachmentCount, pdfPageCount, tenantCount, confidence, verificationMode, readiness, mandateCount, steps, and hitStepLimit. Anything outside the allowlist is dropped before being recorded.

Crucially, prompts and completions are never persisted in telemetry. recordInputs and recordOutputs are hard-coded to false.

Zero Data Retention

When platform ZDR is on (code/env default ON; super-admins toggle at Admin → Model Config → Gateway controls → Zero Data Retention — currently off in the shared platform as of 2026-07-09 for Grok pilots), eligible Gateway requests carry zeroDataRetention: true, which the Gateway honors by short-circuiting request-body logging or training-set capture on upstream providers that expose a ZDR route.

When ZDR is off, requests omit the ZDR flag and non–ZDR-qualified models (e.g. xai/grok-4.5) can be selected for pilot overrides. Models without a Gateway ZDR route or with Corbis gatewaySupportsZeroDataRetention=false cannot pass ZDR-on compatibility checks regardless of catalog presence.

In practical terms (when ZDR is on and the model is ZDR-qualified):

  • Prompts and completions are not retained by the Gateway after the response is delivered.
  • They are not used to train any model.
  • They are not visible in cross-org analytics.

EQUIRE's own database stores the outputs of AI work (extracted fields, IC memo text, valuation assumptions, audit log entries) where they are needed for the product. Those outputs live under your org's RLS scope and are deleted when you delete the underlying deal or scheduled account-level deletion runs.

Timeouts

Every AI call carries an explicit timeout drawn from a small set of presets. Total timeout is the upper bound for the whole call; chunk timeout is the maximum gap between streamed tokens before the call is aborted.

PresetTotalChunkUsed for
quick25s8sLightweight classification, gap checks
standard90s20sMost chat, narrative, and deal-tool calls
verification90s20sHaiku verification pass on extracted documents
pdfVerification240s60sPDF vision verification — vision TTFT can be 20–60s for 30–100 page OMs before tokens flow
extraction480s90sLong-context document extraction (up to 64k output tokens)
icMemo180s45sIC memo section generate/refine

pdfVerification is the longest preset by design. Native-PDF vision ingestion has a long time-to-first-token before any streaming starts, so a shorter preset would abort valid calls mid-think.

Embeddings

When the Gateway is configured, embeddings use openai/text-embedding-3-small (1536 dimensions). They carry the same feature, orgId, and userId attribution as LLM calls.

Direct Anthropic does not provide an embeddings endpoint. When only the Anthropic fallback is in place, embedding calls fail soft — the helper returns an empty array and any features that require embeddings degrade gracefully (text search falls back to keyword matching, research narratives skip the semantic-similarity stage). Production deployments should always configure the Gateway so embeddings are available.

Where to Go Next

  • For the data-handling and human-in-the-loop posture of every AI surface, see Trust and safety.
  • For which tools each chat mode exposes, see Tool reference.
  • For specialist agents that drive the bulk of document-processing and corbis-research traffic, see Specialist agents.
  • For implementers: model resolution lives in src/lib/ai/ (resolveModelCall, profiles). Confirm AI SDK / Gateway call shapes via AI SDK 7 docs, vercel:ai-sdk, and vercel:ai-gateway — not this product page.
Edit on GitHub

Last updated on

On this page