CLEAR (Comprehensive Vessel Trajectory Analysis Platform) is a knowledge-centric platform that transforms raw AIS (Automatic Identification System) data into complete, interpretable, and easily explorable vessel trajectories. By leveraging Large Language Models (LLMs) and a Structured Data-derived Knowledge Graph (SD-KG), CLEAR makes maritime trajectory analysis accessible to non-expert users.
Maritime vessel trajectories from AIS provide critical insights for analyzing ship movements, operational efficiency, and safety compliance. However, AIS data presents two major challenges:
- Missing Observations: Gaps from communication outages, intentional AIS switch-off, and heterogeneous sampling policies
- Semantic Complexity: Requires combining kinematic signals with vessel attributes, regulations, and contextual information
CLEAR addresses these challenges through:
- Automated trajectory completion using knowledge-driven imputation
- Transparent explanations for all inferred behaviors and imputation decisions
- Interactive exploration of both trajectories and underlying maritime knowledge
- Accessible interface designed for users without deep maritime or database expertise
Built on the VISTA framework, CLEAR implements a continuous loop that:
- Distills knowledge from observed AIS trajectories into a structured knowledge graph
- Applies knowledge back to complete missing trajectory segments
- Updates knowledge as new data is processed
The SD-KG integrates three types of nodes:
- Static Attribute Nodes: Vessel types, navigation statuses, spatial contexts, vessel dimensions, etc.
- Behavior Pattern Nodes: Port-Entry: DecelerateβAlign, Open-Sea: Steady Cruise, etc.
- Imputation Method Nodes: Executable functions optimized for specific behavior patterns
CLEAR offers three core analysis functions that enable non-expert users to interpret individual trajectories and explore the underlying maritime knowledge:
CLEAR provides detailed, evidence-backed reports for all SD-KG node types:
- Segment Reports: Display static attributes, inferred behavior context (previous, current, and next behaviors), and explanatory reasoning for behavioral and imputation estimates, alongside a SD-KG subgraph showing related nodes
- Static Attribute Reports: Show vessels, behaviors, and imputation methods associated with specific attributes (e.g., vessel type "Cargo", navigation status "Underway using engine")
- Behavior Pattern Reports: Present detailed pattern characteristics (speed, course, heading, navigation intent, duration) and associated static attributes and imputation methods
- Imputation Method Reports: Describe function implementations, applicable behavior patterns, and success metrics with SD-KG evidence
- Segment-level Interaction: Click any trajectory segment on the map to open its knowledge-centric analysis report
- Visual Distinction: Observed segments displayed in purple, imputed segments in red
- Filtering Capabilities: Filter trajectories by MMSI, time range, or geographic region
- Knowledge Navigation: Seamlessly navigate from map segments to related SD-KG nodes and their analysis reports
CLEAR supports deep knowledge exploration through two complementary modes:
- Graph Visualization: Interactive network graph presenting SD-KG nodes and their connections
- Filter nodes by type (static attributes, behavior patterns, imputation methods) or keyword
- Drag nodes to highlight connected edges and explore relationships
- Zoom to view node labels and examine graph structure
- Click nodes to open their detailed analysis reports
- Reciprocal Report Navigation: Within any analysis report, click related nodes to access their reports, enabling seamless exploration of evidence chains and knowledge connections across the SD-KG
CLEAR is a full-stack web platform built on the VISTA framework:
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β CLEAR Platform β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββΌββββββββββββββββββ
βΌ βΌ βΌ
ββββββββββββββββ ββββββββββββββββ ββββββββββββββββββββ
β Frontend β β Backend β β VISTA Framework β
β (Vue 3) ββββ€ (FastAPI) ββββ€ (Git Submodule) β
ββββββββββββββββ ββββββββββββββββ ββββββββββββββββββββ
β β β β
β β’ Map View β β’ Trajectory β β’ SD-KG β
β β’ SD-KG β API β Construction β
β Explorer β β’ SD-KG API β β’ Trajectory β
β β’ Node Docs β β’ VISTA β Imputation β
β β’ Settings β Integration β β’ Workflow Mgmt β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
VISTA Framework is integrated as a Git submodule (clear-backend/vista/). For detailed information about the VISTA framework architecture and its data-knowledge-data loop, see the VISTA documentation.
CLEAR/
βββ clear-frontend/ # Vue 3 + Vite frontend application
β βββ src/
β β βββ views/
β β β βββ Home.vue # Landing page
β β β βββ Map.vue # Interactive trajectory map
β β β βββ SDKG.vue # Knowledge graph explorer
β β β βββ NodeDoc.vue # Node documentation viewer
β β β βββ Settings.vue # Configuration interface
β β βββ components/ # Reusable Vue components
β β βββ router/ # Vue Router configuration
β β βββ main.js # Application entry point
β βββ package.json
β
βββ clear-backend/ # FastAPI backend application
β βββ app/
β β βββ api/v1/
β β β βββ trajectory.py # Trajectory endpoints
β β β βββ sdkg.py # SD-KG endpoints
β β β βββ vista.py # VISTA integration
β β β βββ update.py # Update endpoints
β β βββ core/
β β β βββ config.py # Application configuration
β β βββ main.py # FastAPI application
β βββ requirements.txt
β βββ vista/ # VISTA framework (Git submodule)
β
βββ README.md
- Python 3.8+
- Node.js 16+ and npm
- Git (for cloning and submodule management)
- An LLM API key (OpenAI, Alibaba Cloud DashScope, or compatible service)
# Clone the repository with submodules
git clone --recurse-submodules https://github.com/hyLiu1994/CLEAR.git
cd CLEAR
# If you already cloned without --recurse-submodules, initialize the submodule
git submodule update --init --recursive
# Install backend dependencies
cd clear-backend
pip install -r requirements.txt
# Install VISTA framework environment
cd vista
bash environment_install.sh
cd ..
# Install frontend dependencies
cd ../clear-frontend
npm install
cd ..# Terminal 1: Start the backend server
cd clear-backend
uvicorn app.main:app --reload --host 0.0.0.0 --port 8000
# Terminal 2: Start the frontend development server
cd clear-frontend
npm run devAccess the platform at http://localhost:5173 (Vite default port)
- Open Map Viewer: Click the "Map" button
- Filter Trajectories: Use the sidebar to filter by MMSI, time range, or geographic region
- Select a Segment: Click any trajectory segment on the map
- View Analysis Report: Examine:
- Behavior patterns (speed, course, heading, intent)
- Static vessel attributes
- Imputation methods (for reconstructed segments)
- Related SD-KG subgraph
- Open Graph Viewer: Click the "SD-KG" button
- Filter Nodes: Use keyword search or filter by node type
- Examine Relationships:
- Drag nodes to highlight connected edges
- Zoom to view node labels
- Click nodes to open detailed analysis reports
- Navigate Between Views: Seamlessly move between graph view and map view
- Open Settings: Click the "Settings" button to configure data processing
- Select Data Source: Choose AIS-DK (Denmark) or AIS-US (United States)
- Configure Parameters: Set date range, time intervals, and VISTA processing options
- Execute Pipeline: Click buttons to build SD-KG, run imputation, and generate reports
- View Results: Navigate to Map or SD-KG views to explore completed trajectories and knowledge graph
For detailed data preparation instructions, see the Data Guide.
For SD-KG construction and trajectory imputation details, see the VISTA Pipeline.
This research is funded by the European Union's Horizon Europe programme through the MobiSpaces project (grant agreement no. 101070279) and 6G-XCEL project (grant agreement no. 101139194).