Skip to main content
Glama
contract-sentinel

contract-sentinel

πŸ›‘οΈ C Sentinel β€” Autonomous AI Contract Sentinel

An enterprise-grade, MCP-powered AI agent system for automated contract ingestion, clause extraction, continuous risk monitoring, and real-time LLM integration.


πŸš€ Live Demos


Related MCP server: legal-contract-mcp

πŸ“Œ Overview

C Sentinel is an autonomous risk-analysis agent built to solve enterprise legal bottlenecks. Powered by the Model Context Protocol (MCP), C Sentinel continuously monitors, ingests, and analyzes legal agreements (MSAs, NDAs, SLAs) to extract critical risk factors, uncapped liabilities, and dangerous SLA terms.

It provides both a modern, interactive web dashboard for human operators and a standardized MCP server interface that seamlessly integrates with external LLMs like ChatGPT and Claude.


✨ Key Features

  • πŸ“„ Automated Contract Ingestion: Ingest vendor agreements and instantly calculate overall risk scores (0–100%).

  • 🧠 Continuous Sentinel Analysis Cycle: Autonomous background cycle that audits all stored agreements for non-compliant clauses.

  • ⚑ Model Context Protocol (MCP) Native: Exposed as a streamable MCP server, allowing LLMs (like ChatGPT or Claude Desktop) to invoke tool actions (ingest, fetch_contracts, run_analysis) natively.

  • πŸ“Š Real-Time Operations Dashboard: Built with React, Vite, and Tailwind CSS to display contract velocity, risk breakdown charts, and active alerts.


πŸ—οΈ Architecture & Deployment

   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
   β”‚                  ChatGPT / LLM Connectors               β”‚
   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                                β”‚ (MCP Protocol)
                                β–Ό
 β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
 β”‚   Vercel Frontend    │──▢│      NitroCloud Backend       β”‚
 β”‚    (React / Vite)    β”‚   β”‚     (NitroStack MCP Server)   β”‚
 β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Component

Tech Stack

Hosting Platform

Frontend UI

React, TypeScript, Vite, Tailwind CSS

Vercel

Agent Backend

Node.js, TypeScript, NitroStack MCP SDK

NitroCloud

Repository

Monorepo Structure (/ui & /server)

GitHub


βš™οΈ Environment Variables

Frontend (/ui)

Configure the backend connection URL in your .env file or deployment settings:

VITE_API_BASE_URL=https://c-sentinel-6a6ca7d2-dcoders-srmist.app.nitrocloud.ai

πŸ› οΈ Local Development Quickstart

Prerequisites

  • Node.js (v18+)

  • npm / pnpm

1. Clone the Repository

git clone https://github.com/sachin0610-srm/contract-sentinel.git
cd contract-sentinel

2. Run Backend (MCP Server)

cd server
npm install
npm run dev

3. Run Frontend UI

cd ../ui
npm install
npm run dev

Open http://localhost:5173 to access the local dashboard.


πŸ”Œ Connecting to ChatGPT / External MCP Clients

  1. Open ChatGPT $\rightarrow$ Settings $\rightarrow$ Developer Mode / Apps.

  2. Add a new MCP Connector / Server.

  3. Set Server URL to:

    https://c-sentinel-6a6ca7d2-dcoders-srmist.app.nitrocloud.ai/mcp
  4. Set Authentication to No Auth and save!


πŸ‘₯ Authors & Credits

Developed with ❀️ for the Hackathon by Sachin K (@sachin0610-srm).

Available Tools

4 tools
ingest-contractIngest contractA

Store a contract from its raw text. Assigns a unique id, extracts key clauses, the deadline date and the obligations into structured data, and adds it to the tracked contract portfolio.

Inputs: contractText (required), title.

review-portfolioReview contract portfolioA
Read-onlyIdempotent

Return the contract board: every tracked contract as a card with its risk score, classification (safe or danger), the exact clause text that drove the score, and the recommended action. Optionally filter to safe, danger, or contracts needing attention. Renders the contract-board widget.

Inputs: filter.

run-sentinel-cycleRun sentinel cycle (agent loop)A

Run the autonomous Contract Sentinel agent loop over the entire tracked portfolio: perceive every contract, score its clause risk with full evidence, decide whether it needs action (deadline close, high risk score, or never reviewed), then act by setting status to needs_attention and recording a recommended action (renew as-is / renegotiate with talking points / let lapse). Designed to run on a schedule in production; runnable on demand here. Renders the contract-board widget.

Inputs: dryRun, onlyContractId.

set-company-profileSet company profileA
Idempotent

Store the company context (industry, headcount, jurisdiction, risk tolerance) for this session. Every other Contract Sentinel tool reads this profile when scoring contracts.

Inputs: industry (required), companySize (required), jurisdiction (required), riskTolerance (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.4/5.0

    Scored across 4 tools

    Disambiguation5/5

    Each tool serves a distinct role: profile setup, contract ingestion, automated analysis, and portfolio review. There is no functional overlap between them.

    Naming Consistency5/5

    All tool names follow a clear verb-noun pattern using hyphens (set-, ingest-, run-, review-), making the naming predictable and consistent.

    Tool Count5/5

    With four tools, the set is well-scoped for a contract monitoring workflow: setup, input, processing, and output. No redundancy or excessive expansion.

    Completeness4/5

    The core lifecycle (profile setup, contract ingestion, analysis, and review) is covered. Minor gaps like deleting or manually updating contracts are not essential for the sentinel's autonomous monitoring purpose.

    Related MCP Connectors

    Related MCP Servers