Project Info

DecentraSign

Devpost

Inspiration

Traditional e-signature platforms like DocuSign face critical limitations: they're centralized, prone to manipulation, lack transparency, and charge hefty fees. We envisioned a future where contracts are immutable, verifiable, and truly decentralized. The inspiration struck when we realized that blockchain technology could solve these pain points elegantly. By combining the Sui blockchain's speed and efficiency with AI-powered document parsing, we could create a platform that not only matches traditional e-signature tools but surpasses them with: Immutable records that can't be altered after signing Transparent verification on a public blockchain Zero intermediaries - no company controlling your contracts Smart contract automation - payments and conditions execute automatically DecentraSign represents the convergence of legal tech and Web3, making blockchain accessible to everyday users who just want to sign a contract.

What it does

DecentraSign transforms traditional PDF contracts into executable smart contracts on the Sui blockchain with a seamless, intuitive workflow: Core Features πŸ€– AI-Powered Contract Parsing Upload any PDF contract AI extracts key terms: parties, payments, deadlines, penalties Supports two parsing modes: AI (flexible) and Template (structured) Identifies ambiguous terms that need clarification πŸ€– AI-Powered Contract Parsing Upload any PDF contract AI extracts key terms: parties, payments, deadlines, penalties Supports two parsing modes: AI (flexible) and Template (structured) Identifies ambiguous terms that need clarification ✍️ Flexible Signature Options Draw directly on PDF: Natural pen tool with customizable color and size Type signature: Human-like handwriting fonts for typed names Multi-page support with transparent signatures Real-time signature placement and editing ✍️ Flexible Signature Options Draw directly on PDF: Natural pen tool with customizable color and size Type signature: Human-like handwriting fonts for typed names Multi-page support with transparent signatures Real-time signature placement and editing ⚑ Sui Blockchain Integration Generates Move smart contracts from extracted terms Deploys contracts to Sui blockchain Immutable storage using Walrus for document permanence zkLogin via Enoki for seamless authentication ⚑ Sui Blockchain Integration Generates Move smart contracts from extracted terms Deploys contracts to Sui blockchain Immutable storage using Walrus for document permanence zkLogin via Enoki for seamless authentication πŸ“‹ Interactive Review & Editing Edit extracted contract terms before blockchain deployment Add Sui wallet addresses for all parties Real-time validation and error checking Beautiful, warm terracotta-themed UI πŸ“‹ Interactive Review & Editing Edit extracted contract terms before blockchain deployment Add Sui wallet addresses for all parties Real-time validation and error checking Beautiful, warm terracotta-themed UI πŸ”— Smart Contract Execution Automatic milestone tracking Conditional payment releases Deadline enforcement with penalties Multi-party signature workflows πŸ”— Smart Contract Execution Automatic milestone tracking Conditional payment releases Deadline enforcement with penalties Multi-party signature workflows

How we built it

Frontend Architecture Tech Stack: React 18 with Vite for fast development Framer Motion for fluid animations and interactions react-pdf for PDF rendering and manipulation React Router for seamless navigation Custom Canvas API for signature drawing with transparent backgrounds Key Components: Backend Infrastructure Python Flask API: Contract parsing endpoint (/api/parse-contract) Two parsing engines: AI Parser: Claude API for flexible document understanding Template Parser: Fixed OCR for standardized contracts AI Parser: Claude API for flexible document understanding Template Parser: Fixed OCR for standardized contracts Extracts: parties, payments, deadlines, penalties, ambiguous terms Data Flow: Blockchain Integration (Sui) Move Smart Contracts: Custom contract modules in Move language Milestone-based payment logic Multi-signature validation Automated penalty enforcement Sui Services Used: Sui Blockchain: Fast, low-cost contract deployment Walrus: Decentralized document storage (immutable PDF archives) Enoki: zkLogin for wallet-less authentication dApp Kit: React SDK for wallet connections Smart Contract Structure: Signature System We built a sophisticated multi-modal signature system: Canvas-based drawing with signature_pad library Transparent PNG export for professional appearance Direct PDF annotation using HTML5 Canvas overlay Typed signatures with cursive fonts (Brush Script MT) Drag-and-drop positioning with Framer Motion Per-page signature tracking for multi-page documents Design Philosophy We chose a warm, trustworthy aesthetic to make blockchain feel approachable: Terracotta and gold color palette (vs. typical crypto blue) Serif fonts (Fraunces) for legal gravitas Smooth animations to reduce anxiety around "blockchain complexity" Clear visual hierarchy and generous whitespace

Challenges we ran into

1. PDF Text Layer Interference ⚑ Problem: When users tried to draw signatures, they were selecting text instead. Solution: Conditionally disabled text/annotation layers when pen is active Added userSelect: 'none' to prevent highlighting Implemented e.preventDefault() on mouse events Set pointerEvents: 'none' on PDF layer during drawing 2. AI Contract Parsing Accuracy πŸ€– Problem: Generic AI models struggled with legal jargon and contract structure. Solution: Crafted specialized prompts with legal terminology Implemented dual-mode parsing (AI + Template) Added "ambiguous terms" detection Structured output validation with JSON schema 3. Signature Transparency 🎨 Problem: Signatures had white backgrounds, looking unprofessional on PDFs. Solution: Used backgroundColor: 'rgba(255, 255, 255, 0)' in SignaturePad Exported as PNG with full alpha channel Applied CSS filter: drop-shadow() for visibility Removed all hardcoded background colors 4. Sui Blockchain Learning Curve ⛓️ Problem: Move language and Sui concepts were entirely new to the team. Solution: Built MCP (Model Context Protocol) documentation server Indexed 300+ pages from Sui docs, Move book, Walrus, Enoki Created local SQLite database with full-text search Used Claude to query documentation in real-time 5. Multi-Page PDF Rendering πŸ“„ Problem: Initially showed only one page, users couldn't sign all pages. Solution: 6. Signature Placement UX 🎯 Problem: Dragging signatures felt clunky and imprecise. Solution: Switched to direct drawing on PDF Added typed signature option with handwriting fonts Implemented page-specific signature tracking Added visual feedback with dashed borders

Accomplishments we're proud of

🎨 Beautiful, Intuitive UI We created a design that makes blockchain feel warm and approachable, not intimidating. The terracotta color scheme and smooth animations set us apart from typical "crypto blue" applications. πŸ€– AI That Actually Works Our contract parser successfully extracts complex terms from real legal documents, not just demos. It handles ambiguity gracefully and provides structured output ready for blockchain deployment. ⚑ Seamless Sui Integration Despite Sui being new to us, we successfully: Wrote Move smart contracts Integrated Walrus for storage Implemented Enoki zkLogin Connected wallet providers via dApp Kit ✍️ Revolutionary Signature System Our dual-mode signature approach (draw + type) with transparent backgrounds and direct PDF annotation is more flexible than traditional e-signature tools. πŸ“š MCP Documentation Server We built a local documentation server that indexed 300+ pages of Sui ecosystem docs, making development significantly faster. πŸš€ Full-Stack Blockchain App From PDF upload to blockchain deployment, we built a complete end-to-end application in 48 hours.

What we learned

Blockchain Development Move language syntax and paradigms Sui's object model and how it differs from Ethereum Smart contract security considerations (reentrancy, overflow) Gas optimization techniques for Sui transactions Frontend Engineering Canvas API mastery for signature drawing and PDF annotation Event handling complexity (preventing text selection, mouse event capture) State management for multi-step workflows Animation performance with Framer Motion AI Integration Prompt engineering for legal document parsing Structured output generation with Claude Error handling for AI unpredictability Hybrid AI/template approaches for reliability UX/UI Design Progressive disclosure to reduce cognitive load Animation as communication (not just decoration) Color psychology for trust and warmth Accessibility in blockchain applications Backend Architecture Flask API design for ML integration CORS handling for local development File upload processing at scale Error propagation from AI to frontend Web3 Ecosystem Wallet integration patterns (Sui Wallet, zkLogin) Decentralized storage with Walrus On-chain vs off-chain data tradeoffs Transaction signing UX flows

What's next

Short-term (Next 3 Months) πŸ” Enhanced Security Multi-signature requirements for high-value contracts Time-locked signatures (must sign by deadline) Revocation mechanisms for unsigned contracts πŸ” Enhanced Security Multi-signature requirements for high-value contracts Time-locked signatures (must sign by deadline) Revocation mechanisms for unsigned contracts πŸ“± Mobile App React Native port for iOS/Android Touch-optimized signature drawing Push notifications for signature requests πŸ“± Mobile App React Native port for iOS/Android Touch-optimized signature drawing Push notifications for signature requests 🌐 Multi-Chain Support Ethereum/Polygon integration for EVM contracts Cross-chain contract verification Bridge contracts for multi-chain enforcement 🌐 Multi-Chain Support Ethereum/Polygon integration for EVM contracts Cross-chain contract verification Bridge contracts for multi-chain enforcement πŸ“Š Analytics Dashboard Contract status tracking Payment milestone visualization Time-to-signature metrics πŸ“Š Analytics Dashboard Contract status tracking Payment milestone visualization Time-to-signature metrics Mid-term (6-12 Months) 🀝 Enterprise Features Organization accounts with role-based access Template libraries for common contracts Bulk contract deployment API access for integrations 🀝 Enterprise Features Organization accounts with role-based access Template libraries for common contracts Bulk contract deployment API access for integrations βš–οΈ Legal Compliance eIDAS compliance (EU electronic signatures) ESIGN Act validation (US) Audit trails and evidence packages Court-admissible blockchain proofs βš–οΈ Legal Compliance eIDAS compliance (EU electronic signatures) ESIGN Act validation (US) Audit trails and evidence packages Court-admissible blockchain proofs πŸŽ“ Smart Contract Templates Pre-built modules: NDAs, employment agreements, leases Industry-specific contract libraries (real estate, freelance, M&A) Community-contributed templates marketplace πŸŽ“ Smart Contract Templates Pre-built modules: NDAs, employment agreements, leases Industry-specific contract libraries (real estate, freelance, M&A) Community-contributed templates marketplace πŸ” Advanced AI Features Contract risk analysis and flagging Clause recommendation engine Automatic contract comparison (v1 vs v2) Natural language contract generation πŸ” Advanced AI Features Contract risk analysis and flagging Clause recommendation engine Automatic contract comparison (v1 vs v2) Natural language contract generation Long-term (1+ Years) 🌍 Decentralized Dispute Resolution On-chain arbitration protocols Community jury systems Escrow integration for contested payments Kleros integration for decentralized justice 🌍 Decentralized Dispute Resolution On-chain arbitration protocols Community jury systems Escrow integration for contested payments Kleros integration for decentralized justice πŸ’° DeFi Integration Contract-backed loans (use signed contracts as collateral) Automatic payment streaming (Superfluid) Stablecoin-denominated contracts Insurance protocols for contract breaches πŸ’° DeFi Integration Contract-backed loans (use signed contracts as collateral) Automatic payment streaming (Superfluid) Stablecoin-denominated contracts Insurance protocols for contract breaches πŸ€– AI Negotiation Agents Autonomous contract negotiation bots Optimal term suggestion based on historical data Real-time contract redlining Multi-party negotiation orchestration πŸ€– AI Negotiation Agents Autonomous contract negotiation bots Optimal term suggestion based on historical data Real-time contract redlining Multi-party negotiation orchestration πŸ”— Interoperability Layer Traditional e-signature import (DocuSign, Adobe Sign) Legacy system API bridges Hybrid on-chain/off-chain contracts Government registry integrations πŸ”— Interoperability Layer Traditional e-signature import (DocuSign, Adobe Sign) Legacy system API bridges Hybrid on-chain/off-chain contracts Government registry integrations Vision: The Future of Contracts We envision a world where: Every contract is verifiable on-chain in seconds Smart contracts self-execute without lawyers or courts AI negotiators handle routine agreements Decentralized arbitration resolves disputes fairly Anyone, anywhere can enforce agreements without intermediaries DecentraSign is the first step toward trustless, transparent, and accessible legal agreements for everyone. Technical Metrics Lines of Code: ~15,000 Components: 25+ React components API Endpoints: 5 backend routes Smart Contracts: 3 Move modules Documentation Indexed: 300+ pages Supported File Types: PDF, DOC, DOCX Blockchain: Sui Testnet Storage: Walrus decentralized storage Try It Out Upload a PDF contract Sign with our intuitive draw/type tools Review AI-extracted terms Deploy to Sui blockchain Share with other parties for co-signing DecentraSign: Where Web2 contracts meet Web3 trust. Built with ❀️ at CalHacks 2025

Analysis

Compare with all teams

View

Metric

Figures cover GitHub contributors during the hackathon window. A co-authored commit counts in full for each author, so per-member totals add up to more than the whole-team figures.

Technology

Found in codeClaimed only
  • CSSIn code
  • HTMLIn code
  • ReactIn code
  • Tailwind CSSIn code
  • TypeScriptIn code
  • FlaskClaimed
  • PythonClaimed

5 of 7 appear in the indexed code. 2 claimed on Devpost could not be matched to code, which may simply mean the tool leaves no trace in the repository.

AI coding agents

No AI coding agent signals were found in this repository.

Detected from committed agent config files and commit authorship. Absence of a signal is not proof an agent was unused.

Codebase size

Source size

372 KB

Source files

38

Counts recognized source files only; vendored directories, binaries and lockfiles are excluded, so this is smaller than the repository on disk.

0 stars