{"id":51025382,"url":"https://github.com/edycutjong/synod","last_synced_at":"2026-06-21T19:01:53.125Z","repository":{"id":366139755,"uuid":"1275205724","full_name":"edycutjong/synod","owner":"edycutjong","description":"🏛️ Atomic multi-agent transactional orchestration engine running inside Intel TDX TEE boundary with 100% cryptographic rollback guarantees, powered by Terminal 3 ADK.","archived":false,"fork":false,"pushed_at":"2026-06-20T12:49:46.000Z","size":1297,"stargazers_count":0,"open_issues_count":4,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-20T13:26:02.406Z","etag":null,"topics":["cryptography","governance","hackathon","intel-tdx","multi-agent","nextjs","react","secp256k1","tee","terminal3","wasm"],"latest_commit_sha":null,"homepage":"https://synod.edycu.dev","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/edycutjong.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-06-20T11:45:50.000Z","updated_at":"2026-06-20T12:49:50.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/edycutjong/synod","commit_stats":null,"previous_names":["edycutjong/synod"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/edycutjong/synod","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/edycutjong%2Fsynod","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/edycutjong%2Fsynod/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/edycutjong%2Fsynod/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/edycutjong%2Fsynod/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/edycutjong","download_url":"https://codeload.github.com/edycutjong/synod/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/edycutjong%2Fsynod/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34622271,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-21T02:00:05.568Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cryptography","governance","hackathon","intel-tdx","multi-agent","nextjs","react","secp256k1","tee","terminal3","wasm"],"created_at":"2026-06-21T19:01:51.156Z","updated_at":"2026-06-21T19:01:53.119Z","avatar_url":"https://github.com/edycutjong.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n  \u003cimg src=\"docs/icon-animated.svg\" alt=\"Synod Icon\" width=\"120\"\u003e\n  \u003ch1\u003eSynod 🏛️\u003c/h1\u003e\n  \u003cp\u003e\u003cem\u003eAtomic, multi-agent transactional orchestration engine built inside secure enclaves with 100% cryptographic rollback guarantees.\u003c/em\u003e\u003c/p\u003e\n  \u003cimg src=\"docs/readme-hero.svg\" alt=\"Synod — Multi-Agent Transaction Engine\" width=\"100%\"\u003e\n\n  \u003cbr/\u003e\n\n  [![Live Demo](https://img.shields.io/badge/🚀_Live-Demo-06b6d4?style=for-the-badge)](https://synod.edycu.dev)\n  [![Pitch Video](https://img.shields.io/badge/🎬_Pitch-Video-ef4444?style=for-the-badge)](https://youtu.be/your-video)\n  [![Pitch Deck](https://img.shields.io/badge/📊_Pitch-Deck-f59e0b?style=for-the-badge)](https://synod.edycu.dev/pitch.html)\n  [![Built for DoraHacks](https://img.shields.io/badge/DoraHacks-Terminal%203%20ADK%20Hackathon-8b5cf6?style=for-the-badge)](https://dorahacks.io/hackathon/t3adk-launch-2026)\n\n  \u003cbr/\u003e\n\n  ![Next.js](https://img.shields.io/badge/Next.js_14-black?style=flat\u0026logo=next.js)\n  ![React](https://img.shields.io/badge/React_18-61DAFB?style=flat\u0026logo=react\u0026logoColor=black)\n  ![TypeScript](https://img.shields.io/badge/TypeScript-3178C6?style=flat\u0026logo=typescript\u0026logoColor=white)\n  ![Tailwind CSS](https://img.shields.io/badge/Tailwind_v3-38B2AC?style=flat\u0026logo=tailwindcss\u0026logoColor=white)\n  ![Rust WASM](https://img.shields.io/badge/Rust_WASM-de782f?style=flat\u0026logo=rust\u0026logoColor=white)\n  ![Intel TDX](https://img.shields.io/badge/Intel_TDX-0071c5?style=flat\u0026logo=intel\u0026logoColor=white)\n  ![T3 ADK](https://img.shields.io/badge/T3_ADK-8b5cf6?style=flat)\n  ![Playwright](https://img.shields.io/badge/Playwright-2EAD33?style=flat\u0026logo=playwright\u0026logoColor=white)\n  ![Jest](https://img.shields.io/badge/Jest-C21325?style=flat\u0026logo=jest\u0026logoColor=white)\n  [![CI](https://github.com/edycutjong/synod/actions/workflows/ci.yml/badge.svg)](https://github.com/edycutjong/synod/actions/workflows/ci.yml)\n  [![npm sdk version](https://img.shields.io/npm/v/@edycutjong/synod-sdk.svg?style=flat\u0026logo=npm\u0026color=8b5cf6)](https://www.npmjs.com/package/@edycutjong/synod-sdk)\n\n\u003c/div\u003e\n\n---\n\n\u003e ⚡ **Reviewers / judges:** fastest path is **[GOLDEN_PATH.md](GOLDEN_PATH.md)** — the entire flow in ~2 minutes, **no credentials**. Bug-bounty track: **[SDK_AUDIT.md](SDK_AUDIT.md)** (confirmed, code-cited findings from the real `@terminal3` SDK).\n\n## 📸 See it in Action\n\n\u003cdiv align=\"center\"\u003e\n  \u003cimg src=\"ui/public/og-image.png\" alt=\"Synod Demo Console\" width=\"100%\"\u003e\n\u003c/div\u003e\n\n\u003e **Atomically orchestrated multi-agent transaction:**\n\u003e 1. Client submits payout envelope encrypted via ECIES and a Groth16 limit proof.\n\u003e 2. Coordinator stages CCF KV states and evaluates specialists sequentially (Treasury and Compliance).\n\u003e 3. If either agent vetos or fails, TEE state rolls back with zero side-effects. On success, the Blind Paymaster executes the payout.\n\n---\n\n## 💡 The Problem \u0026 Solution\n\n### The Problem\nIn enterprise treasury operations, a single agent should never have unilateral authority to release funds. Traditional Web2 agent frameworks (like LangChain or crewAI) orchestrate multi-agent actions sequentially over HTTP. \n\nIf Agent B (Compliance) vetoes a transaction *after* Agent A (Treasury) has already committed its database write or triggered an intermediate API request, the system is left in a broken, half-executed state. Resolving these race conditions requires complex distributed transaction coordinators (e.g. the Saga pattern), which cannot guarantee hardware-isolated privacy or prevent front-running.\n\n### The Solution\n**Synod** turns independent agents into a unified, transactional agent platform. By leveraging the **Terminal 3 Agent Dev Kit (ADK)** inside secure TEE enclaves, Synod runs cross-contract workflows under a single atomic transaction boundary.\n\nEither every agent approves and the final blind paymaster executes, or the entire transaction aborts—rolling back all staged states inside the TEE KV store with zero side effects. Privacy is guaranteed: no intermediate agent, not even the coordinator, can view the plaintext payment credentials.\n\n**Key Features:**\n- 🔒 **TEE Secure Boundary:** Executes multi-agent sequence inside Intel TDX enclaves ensuring hardware-isolated privacy.\n- ⚡ **Atomic Rollback Journal:** Automatically reverts all staged CCF KV writes and aborts egress webhooks on veto/outage.\n- 🔑 **ECIES Envelope Encryption:** Client-side payload encryption ensures only the final Executor Agent can decrypt recipient details inside secure memory.\n- 🛡️ **ZK Compliance Proofs:** Groth16 zero-knowledge proofs verify payout limits without exposing transaction amounts in audit logs.\n\n---\n\n## 🏗️ Architecture \u0026 Tech Stack\n\n| Layer | Component / Technology |\n|---|---|\n| **Frontend Console** | Next.js 14, React 18, Tailwind CSS |\n| **Client SDK** | `@edycutjong/synod-sdk` (ECIES payload encryption, ZK commitments generation) |\n| **TEE Contracts** | Rust WASM (`wasm32-wasip2`), Cargo Workspace (`coordinator`, `approver-a`, `approver-b`, `executor`) |\n| **State Storage** | File-based JSON Database / CCF-replicated KV namespace simulator |\n| **Core Security** | Intel TDX Hardware Enclaves |\n\n```mermaid\nsequenceDiagram\n    autonumber\n    actor User as Client Dashboard\n    participant Coord as Synod Coordinator Agent\n    participant AppA as Approver A (Treasury)\n    participant AppB as Approver B (Compliance)\n    participant Exec as Executor (Paymaster)\n    participant KV as CCF KV Store (TEE)\n\n    User-\u003e\u003eCoord: compose-action (ECIES envelope, ZK proof)\n    activate Coord\n    Note over Coord: Stage KV state as \"submitting\"\n    Coord-\u003e\u003eKV: Stage State\n    \n    Coord-\u003e\u003eAppA: contracts-call: evaluate()\n    activate AppA\n    AppA--\u003e\u003eCoord: approved\n    deactivate AppA\n    \n    Coord-\u003e\u003eAppB: contracts-call: evaluate-zk(proof, limit)\n    activate AppB\n    Note over AppB: Verify Groth16 proof relation\n    AppB--\u003e\u003eCoord: approved / vetoed\n    deactivate AppB\n    \n    alt If Approved\n        Coord-\u003e\u003eExec: contracts-call: execute-blind(envelope)\n        activate Exec\n        Note over Exec: Decrypt ECIES payload in TEE memory\n        Note over Exec: http-with-placeholders: POST bank/webhook\n        Exec--\u003e\u003eCoord: settled + signed VC receipt\n        deactivate Exec\n        Coord-\u003e\u003eKV: Commit transaction state as \"committed\"\n        Coord--\u003e\u003eUser: committed + VC receipt\n    else If Vetoed / Aborted\n        Coord-\u003e\u003eKV: Roll back staged KV states to \"aborted\"\n        Coord--\u003e\u003eUser: aborted (Zero side-effects)\n    end\n    deactivate Coord\n```\n\n---\n\n## 🏆 Sponsor Tracks Targeted\n\nSynod is built around the **Terminal 3 Agent Dev Kit (ADK)** and would be technically impossible to implement on conventional Web2 agent frameworks. We utilize 6 key Host API methods:\n\n1. **`contracts-call`**: Invokes leaf enclaves synchronously within a single hardware transaction boundary, enabling true all-or-nothing rollback semantics.\n2. **`http-with-placeholders`**: Securely replaces ECIES decrypted account placeholders at the egress network edge.\n3. **`signing`**: Signs composite Verifiable Credential receipts verifying the approval trace.\n4. **`kv-store`**: Manages staged/committed state variables in a replicated database.\n5. **`logging`**: Securely streams execution traces to the war-room panel without exposing private variables.\n6. **`clock`**: Validates consensus windows and transaction timeouts.\n\n### ⚠️ Honest Limitations \u0026 Gaps\n* **Contracts Call Stack Depth:** The current `contracts-call` API restricts nested calls to a stack depth of 3. Synod works around this by implementing a flat coordinator-leaf design.\n* **Strict Interface Serialization:** The VM requires strict interface layouts; any discrepancy in calldata byte alignments crashes the WASM runtime. Synod wraps calls in explicit validation containers to prevent silent failures.\n\n---\n\n## 🚀 Getting Started\n\n### Prerequisites\n- Node.js ≥ 20\n- npm\n- Rust \u0026 Cargo (to compile contracts)\n- target wasm32-wasip2:\n  ```bash\n  rustup target add wasm32-wasip2\n  ```\n\n### Installation \u0026 Bootstrapping\nSynod uses a root-level Makefile to coordinate its packages.\n\n1. Clone the repository and navigate to the project directory:\n   ```bash\n   git clone https://github.com/edycutjong/dorahacks-t3launch-synod.git\n   cd dorahacks-t3launch-synod\n   ```\n2. Bootstrap all dependencies:\n   ```bash\n   make bootstrap\n   ```\n3. Compile all packages (Contract, UI, SDK, CLI):\n   ```bash\n   make build\n   ```\n4. Configure environment variables:\n   ```bash\n   cp .env.example .env\n   ```\n5. Run the local dev server:\n   ```bash\n   cd ui \u0026\u0026 npm run dev\n   ```\n\n---\n\n## 🧪 Testing \u0026 CI\n\nSynod is guarded by a comprehensive **6-stage production-grade CI/CD pipeline** (Quality → Security → Build → E2E → Performance → Deploy).\n\n```bash\n# ── Setup and Installation ──────────────────\nmake bootstrap        # Install dependencies in all folders\n\n# ── Code Quality ────────────────────────────\nmake lint             # Run ESLint checks\nmake typecheck        # Verify TypeScript compilation safety\nmake test             # Run unit and integration tests (Contract, UI)\nmake ci               # Run the core CI checks (lint, typecheck, test)\n\n# ── Advanced Verification ───────────────────\nmake e2e              # Run Playwright E2E tests (demo mode)\nmake lighthouse       # Run Lighthouse CI audit on the UI dashboard\nmake security-scan    # Run vulnerability audits and license compliance checks\n```\n\n| Layer | Tool | Status |\n|---|---|---|\n| Code Quality | ESLint + TypeScript Strict | ✅ |\n| Unit Testing | Jest (UI) + Cargo test (Contract) | ✅ |\n| E2E Testing | Playwright (3 suites, responsive, smoke, transactional flow) | ✅ |\n| Security (SAST) | CodeQL Semantic Analysis | ✅ |\n| Security (SCA) | Dependabot + npm audit | ✅ |\n| Secret Scanning | TruffleHog Commits/Secrets | ✅ |\n| Performance | Lighthouse CI (A11y \u003e= 90%, Perf \u003e= 80%) | ✅ |\n\n---\n\n## 📁 Project Structure\n\n```text\ndorahacks-t3launch-synod/\n├── .github/             # GitHub Actions workflows \u0026 Dependabot\n├── cli/                 # CCF Enclave CLI administration utilities\n├── contract/            # Rust enclave WASM contract workspace\n│   ├── coordinator/     # Transaction orchestrator contract\n│   ├── approver-a/      # Budget treasury specialist contract\n│   ├── approver-b/      # Compliance Groth16 verification contract\n│   └── executor/        # Blind paymaster enclave contract\n├── data/                # Seed database and transaction payloads\n├── docs/                # README assets (hero, screenshots, audit reports)\n├── scripts/             # Benchmarking and seed scripts\n├── sdk/                 # Client cryptography helper library\n├── ui/                  # Next.js Dashboard UI (port 3000)\n│   ├── e2e/             # Playwright E2E tests\n│   ├── src/             # Next.js page components\n│   └── lighthouserc.json\n├── Makefile             # Automation shortcuts\n├── package.json         # Root package workspace runner\n└── README.md            # You are here\n```\n\n## 🧠 Terminal 3 ADK Dev Challenge: Audit \u0026 Discovered Bugs\n\nThis project is submitted to the **Terminal 3 ADK Dev Challenge 2026** as part of the **Vouch Suite** (a 5-enclave system including Epoch, Lethe, Silo, Synod, and Visor).\n\nWhile building these enclaves we audited the T3 ADK host APIs and SDK and documented **10 concrete onboarding bugs and documentation gaps** — each with a repro, impact, and the workaround we shipped — for the **Track 2 bug bounty**.\n\n➡️ **See [BUGS.md](BUGS.md)** for the full audit. Highlights for Synod:\n\n- **Gap #10 — `contracts-call` nested-revert \u0026 reentrancy semantics** are undocumented — Synod's whole premise (a single approver veto reverting the Treasury→Compliance→Executor tree) depends on this.\n- **Gap #8 — transaction rollback boundary** is unspecified — what an `Err` reverts across staged KV writes is the core atomicity guarantee.\n- **Bug #2 — `kv-store` interface discrepancy:** WIT declares `get(map-name, key)` but the C ABI is flat `(key_ptr, key_len)` (Synod stages `submitting`/`committed`/`aborted`).\n\n---\n\n## 📄 License\n\nMIT © 2026 Synod Authors\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fedycutjong%2Fsynod","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fedycutjong%2Fsynod","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fedycutjong%2Fsynod/lists"}