Skip to main content

Architecture Overview

The Metatate Snowflake Native App is the Snowflake runtime of the Metatate decision layer. It runs entirely within the consumer's Snowflake account on Snowpark Container Services (SPCS). There is no external infrastructure, and all compute, storage, and AI processing happen inside Snowflake. The architecture below covers the Snowflake runtime; the decision layer itself is portable across runtimes through MCP.

High-Level Architecture

Request Flow

Component Details

The application is organized into three tiers with clear separation of concerns.

Router (nginx)

The nginx reverse proxy handles:

  • Static asset serving for the React frontend
  • API request proxying (/api/* routes to the Flask backend)
  • HTTPS termination is handled by Snowflake's SPCS ingress, not by nginx

Frontend (React)

Single-page application built with React and Rsbuild.

AreaCountDetails
Pages4Home, Policy Editor, Deployments, Settings
Component groups6AI, Policy, UI, Layout, Catalog, Common
State stores4Policy store, AI status, Table catalog, Auth
API client1Axios-based with interceptors

Backend (Flask)

Python API server with a layered architecture (routes, services, repositories, models) covering governance operations, AI integration, catalog management, and tenant configuration.

Data Layer

All persistent state lives in Snowflake tables within the application's schemas:

SchemaPurpose
app_dataGovernance tables, tenant config, activity log, snapshots, decision log
coreMCP tools (6 UDFs), MCP server registration, utility procedures
app_publicVersioned procedures, lifecycle callbacks, consumer-facing API

AI Layer

AI features are powered by Snowflake Cortex and require no external connections. See Cortex AI Integration for details.

Deployment Model

The Snowflake Native App is distributed through the Snowflake Marketplace or direct sharing:

  1. Provider publishes the application package with versioned container images
  2. Consumer installs the application in their account
  3. Application creates its schemas, tables, compute pools, and services
  4. Consumer grants references (tables for catalog, warehouse for compute)
  5. Application is fully operational with no external dependencies

All container images, application code, and configuration are bundled in the application package. The consumer does not need to provide any infrastructure beyond a warehouse and table references.