Foresight

Foresight

An MCP server that discovers suppliers, screens compliance and live hazards, calculates exposure, ranks alternatives, and drafts purchasing decisions for supply chain risk management.

Category
访问服务器

README

Foresight

Introduction

Our track is Industry & Manufacturing, supply chain risk and supplier sourcing sit at its center. Deloitte's 2026 Manufacturing Outlook found over 75% of manufacturers cite trade uncertainty as their top concern, yet most procurement teams still track risk manually across spreadsheets and gut feel. <br> Foresight closes that gap: an MCP-based sourcing advisor, the supply chain that finds out first. It discovers suppliers, screens compliance and live hazards, calculates exposure, ranks alternatives, and drafts a purchasing decision. Just supply the industry, goods, and requirements without any need for database.

What is real

  • Live hazards: USGS earthquakes, NASA EONET natural events, Open-Meteo severe weather, and US NWS alerts.
  • Compliance: SAM.gov public exclusions and OFAC SDN via OpenSanctions, bundled as a build-time index and matched locally.
  • Supplier discovery: optional Odoo Community ERP records, Tavily web results, and best-effort publicly indexed Open Supply Hub evidence.
  • Provenance: external findings carry their source URL and retrieval time.
  • Unknown data stays unknown. Foresight does not invent price, lead time, capacity, certifications, coordinates, or reliability.

MCP Surface

Tool Purpose
find_supplier Discover, normalize, screen, and rank supplier sites in one call, optionally relative to an incumbent
calculate_exposure Assess allocation value, hazard exposure, delay, delivery fit, compliance, verification items, and next steps for any supplied vendor
check_disruptions Run caller-provided sites through live hazard, exposure, ranking, and map processing
simulate_disruption Run the identical processing against a hypothetical event
draft_supplier_memo Build an internal supplier recommendation memo from live assessment, discovery, ranking, and an optional scenario

Resources: discovery://latest, sources://status, and watchtower://latest. Caller-context resources are disabled by default to prevent cross-client disclosure; trusted single-tenant deployments can set ENABLE_CONTEXT_RESOURCES=true. Feed and discovery caches remain bounded and temporary.

Prompts: morning_briefing and draft_mitigation_memo. The mitigation prompt calls draft_supplier_memo; the tool itself can also be called directly.

Widget: disruption-map, rendered by both live and simulated disruption tools.

supplier-memo is rendered by draft_supplier_memo. Widgets use universal MCP Apps metadata; deploy with NITROSTACK_APP_MODE=universal so Claude receives the MCP Apps bridge and ChatGPT/NitroStudio retain compatible metadata.

Quick Start

npm install
npm run compliance
npm run typecheck
npm run smoke
npm run dev

The hazard tools and compliance gate work without supplier-discovery credentials. Configure .env from .env.example to enable Tavily, structured page enrichment, geocoding, Serper fallback, or Odoo discovery.

Discovery Sources

Tavily

Set TAVILY_API_KEY. Tavily currently offers 1,000 recurring monthly API credits without requiring a credit card. Foresight uses basic search and bounded result counts.

Structured enrichment and geocoding

Set ENABLE_WEB_ENRICHMENT=true and WEB_ENRICHMENT_USER_AGENT to extract JSON-LD identity, public addresses, coordinates, and requested certification claims from up to eight candidate pages. Raw page text is never returned to the model. Set ENABLE_GEOCODING=true and GEOCODING_USER_AGENT to geocode extracted addresses through OpenStreetMap Nominatim at one request per second with a bounded in-memory cache.

Serper Places fallback

Set SERPER_API_KEY to query Google Places through Serper only when fewer than three candidates have usable coordinates. Places results provide addresses and coordinates for geographic risk assessment; capability remains an inferred claim until corroborated.

Odoo Community

Set ENABLE_ODOO_DISCOVERY=true, ODOO_ALLOWED_SUBJECTS, ODOO_URL, ODOO_DATABASE, ODOO_USERNAME, and ODOO_API_KEY for a self-hosted Odoo Community instance exposing JSON-RPC. Foresight reads standard vendor price-list and partner records only for authenticated MCP subjects on that allowlist. Odoo is disabled by default because ERP records may be private.

Open Supply Hub

Direct OS Hub production search endpoints currently require authentication. Foresight uses Tavily domain-restricted search to collect publicly indexed OS Hub evidence and never bypasses authentication or access controls. No result is fabricated when public evidence is unavailable.

Scoring

Compliance matches are hard-disqualified. Capability and required certifications are eligibility gates. Available evidence is scored as:

  • Geographic hazard risk: 40
  • Lead-time continuity: 30
  • Cost: 20
  • Reliability: 10

Missing components receive null. Every candidate reports score_earned, score_possible, and score_coverage_pct; partial evidence is not inflated to a complete 100-point score.

Each result also reports readiness: procurement_ready requires complete identity, compliance, commercial, reliability, certification, quantity-fit, and risk evidence; risk_assessed has capability evidence and usable hazard coordinates but may lack commercial facts; lead_needing_verification is not yet geographically assessable.

Unverified facts are presented as verification_pending with next_verification_steps. Foresight does not state that a supplier lacks a certificate when public evidence has simply not been located.

Architecture

src/modules/
  data/         supplier discovery and source adapters
  feeds/        live public hazard clients with timeout and visible degradation
  watchtower/   shared live/simulated site-to-hazard engine
  exposure/     stateless supplier allocation assessment
  ranking/      stateless alternate ranking and real-list compliance gate
  memo/         direct supplier memo orchestration, widget, and prompts

Live and simulated tools use the same disruption engine. The only difference is whether hazards come from public feeds or a synthetic event supplied to the simulator.

External Components

APIs and datasets: USGS Earthquake GeoJSON, NASA EONET v3, Open-Meteo Forecast API (CC-BY 4.0), US NWS Alerts API, Tavily Search, optional Serper Google Places, OpenStreetMap Nominatim, optional Odoo Community JSON-RPC, publicly indexed Open Supply Hub pages, SAM.gov Exclusions public extract, and OpenSanctions OFAC SDN (CC-BY-NC 4.0).

Map data: OpenStreetMap contributors and CARTO basemaps.

Libraries: Nitrostack SDK, Model Context Protocol Ext Apps, Cheerio, dotenv, i18n-iso-countries, Undici, Zod, TypeScript/tsx, Next.js/React, and MapLibre GL JS.

AI implementation assistance is declared in PROGRESS.md. Architectural decisions and reasons are recorded in decisions.md.

Contributors

KK Surendran <br> Khushal <br> Malavika <br> Praharsha <br>

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选