Skip to content

A Java-based graph platform that maps defence supply chains, calculates sovereignty risk scores, identifies ITAR/export-restricted dependencies, and suggests NATO-aligned or Canadian SME alternatives.

Notifications You must be signed in to change notification settings

jonashall8/sovereign-shield

Repository files navigation

Sovereign Shield AI

A Graph-based AI Platform for Canadian Defence Supply Chain Sovereignty Analysis

Java Spring Boot Neo4j React

Overview

Sovereign Shield AI demonstrating a graph-based solution for analyzing Canadian defence supply chain sovereignty. It calculates "Sovereignty Scores" for suppliers, identifies ITAR/export-controlled dependencies, and suggests NATO-aligned alternatives to reduce reliance on potentially unstable US supply chains.

Key Features

Sovereignty Score Engine

  • Proprietary algorithm calculating 0-100 sovereignty risk scores
  • Factors: Country origin, ITAR exposure, trade volatility, certifications, SME status
  • Graph traversal for deep-tier supply chain analysis

Pivot Simulator

  • "What-if" tariff and border closure scenarios
  • Impact analysis on supply chain components
  • NATO-aligned alternative suggestions

Interactive Supply Chain Visualization

  • Cytoscape.js-powered network graph
  • Color-coded risk levels
  • Drill-down supplier details

AI-Powered Analysis (LangChain4j + Ollama)

  • Local LLM for data sovereignty (no US data transfer)
  • Document parsing for supplier brochures
  • Entity extraction and relationship mapping

OSINT Data Collection

  • Canadian Federal Procurement scraper
  • Company profile extraction
  • Certification verification

Tech Stack

Layer Technology Rationale
Language Java 21 (LTS) Defence-grade stability, Virtual Threads
Framework Spring Boot 3.2 Industry standard, robust security
Database Neo4j Community Graph relationships for supply chains
Cache Redis Query result caching
AI/LLM LangChain4j + Ollama Local LLM, Canadian data sovereignty
Frontend React + TypeScript Modern, widely adopted
Visualization Cytoscape.js Network graph rendering
Build Maven Defence industry standard

Project Structure

sovereign-shield-ai/
├── sovereign-shield-core/      # Domain models & interfaces
├── sovereign-shield-graph/     # Neo4j integration & repositories
├── sovereign-shield-ai/        # LangChain4j AI services
├── sovereign-shield-scraper/   # OSINT data collection
├── sovereign-shield-api/       # Spring Boot REST API
└── sovereign-shield-ui/        # React frontend

Quick Start

Prerequisites

  • Java 21+
  • Docker & Docker Compose
  • Node.js 18+ (for frontend)
  • Maven 3.9+

1. Start Infrastructure

docker-compose up -d

This starts Neo4j, Redis, and Ollama containers.

2. Build & Run Backend

mvn clean install
cd sovereign-shield-api
mvn spring-boot:run -Dspring.profiles.active=seed

The seed profile populates the database with 50 mock suppliers.

3. Start Frontend

cd sovereign-shield-ui
npm install
npm run dev

Access the UI at http://localhost:3000

Default Credentials

  • Analyst: analyst / analyst123
  • Admin: admin / admin123

Demo Scenario: Arctic Patrol Ship Supply Chain

This demo showcases the sovereignty analysis for a mock Arctic Patrol Ship component supply chain.

Scenario Setup

  1. Prime Contractor: Irving Shipbuilding (Canadian)
  2. Key Components:
    • Hull Steel: Canadian origin (Score: 80)
    • Propulsion System: US origin with ITAR controls (Score: 25)
    • Navigation System: UK origin, NATO-aligned (Score: 65)
    • Sonar Array: Canadian origin (Score: 85)

Demo Walkthrough

Step 1: View Dashboard

  • Navigate to the Sovereignty Dashboard
  • Observe the supplier distribution pie chart
  • Note the high-risk suppliers flagged (Score < 50)

Step 2: Explore Supply Chain Graph

  • Click "Supply Chain" in navigation
  • Find Irving Shipbuilding (large node)
  • Observe connected suppliers color-coded by risk
  • Click nodes to view sovereignty breakdowns

Step 3: Run Pivot Simulation

  • Navigate to "Pivot Simulator"
  • Select "25% US Tariff" preset
  • Run simulation
  • Observe affected suppliers and recommendations

Step 4: Analyze Alternatives

  • For US-origin components flagged as high-risk
  • View NATO-aligned alternatives suggested
  • Note European (German, French, UK) options with better scores

API Endpoints

Suppliers

  • GET /api/suppliers - List all suppliers
  • GET /api/suppliers/{id} - Get supplier details
  • GET /api/suppliers/canadian - Canadian suppliers only
  • GET /api/suppliers/{id}/supply-chain - Get supply chain graph

Sovereignty

  • GET /api/sovereignty/score/{supplierId} - Calculate score
  • GET /api/sovereignty/scores - All supplier scores
  • GET /api/sovereignty/high-risk - Suppliers below threshold

Simulation

  • POST /api/simulation/tariff - Run tariff scenario
  • GET /api/simulation/border-closure/usa - US border closure impact

Security Considerations

this demonstrates security awareness:

  • Role-based access control (Spring Security)
  • Input validation on all endpoints
  • Rate limiting on scraper endpoints
  • CORS configuration for frontend
  • Note: "Protected B" data handling would require additional controls in production

Future Enhancements

  • CMMC Readiness Checker for SMEs
  • Interoperability Vault for certification upload
  • NATO STANAG compliance mapping
  • PDF report generation
  • Real-time trade policy monitoring

License

This project is for educational/portfolio purposes only. Company names used are based on publicly available information.


"Strengthening Canadian Defence Industrial Sovereignty Through Technology"

About

A Java-based graph platform that maps defence supply chains, calculates sovereignty risk scores, identifies ITAR/export-restricted dependencies, and suggests NATO-aligned or Canadian SME alternatives.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages