{"id":28651879,"url":"https://github.com/Thomvanoorschot/zigma","last_synced_at":"2025-06-13T06:05:55.823Z","repository":{"id":282590028,"uuid":"949069291","full_name":"Thomvanoorschot/zigma","owner":"Thomvanoorschot","description":"Zigma is an algorithmic trading framework built with the Zig programming language, leveraging an actor-based concurrency model. It aims to provide an efficient, low-latency system for algorithmic trading through components handling market data, strategy execution, order management, risk, and data persistence.","archived":false,"fork":false,"pushed_at":"2025-06-12T20:51:52.000Z","size":27366,"stargazers_count":25,"open_issues_count":0,"forks_count":0,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-06-12T21:52:22.988Z","etag":null,"topics":["actor","actor-framework","concurrency","quantitative-finance","trading","wasm","websockets","zig","ziglang"],"latest_commit_sha":null,"homepage":"","language":"Zig","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/Thomvanoorschot.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":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-03-15T15:53:46.000Z","updated_at":"2025-06-12T20:51:55.000Z","dependencies_parsed_at":"2025-04-20T18:25:27.690Z","dependency_job_id":"28dbc200-e2dd-4f1a-b45d-237c6b6a2910","html_url":"https://github.com/Thomvanoorschot/zigma","commit_stats":null,"previous_names":["thomvanoorschot/zigma"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Thomvanoorschot/zigma","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thomvanoorschot%2Fzigma","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thomvanoorschot%2Fzigma/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thomvanoorschot%2Fzigma/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thomvanoorschot%2Fzigma/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Thomvanoorschot","download_url":"https://codeload.github.com/Thomvanoorschot/zigma/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Thomvanoorschot%2Fzigma/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259592260,"owners_count":22881265,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["actor","actor-framework","concurrency","quantitative-finance","trading","wasm","websockets","zig","ziglang"],"created_at":"2025-06-13T06:01:40.599Z","updated_at":"2025-06-13T06:05:55.295Z","avatar_url":"https://github.com/Thomvanoorschot.png","language":"Zig","funding_links":[],"categories":["Data \u0026 Science"],"sub_categories":["Machine Learning"],"readme":"# Zigma: Actor-Based Algorithmic Trading Framework\n\n## Overview\n\nZigma is an algorithmic trading framework built with the Zig programming language, leveraging an actor-based concurrency model. This project serves as both a practical trading system and an educational exploration of Zig's memory management capabilities and concurrency patterns.\n\n## Goals\n• Implement a robust actor framework for handling concurrent trading operations \\\n• Explore Zig's memory management features in depth \\\n• Develop efficient, low-latency trading algorithms \\\n• Create a modular system that can be extended with new strategies and market connectors  \\\n• Serve as a learning resource for Zig programming best practices\n\n## Architecture \n\nZigma is built around an actor model, where independent components communicate through message passing:\n\n### Server (Zig)\n• Market Data Actors – Connect to exchanges and process incoming market data \\\n• Strategy Actors – Implement trading algorithms and generate signals \\\n• Order Management Actors – Handle order creation, modification, and cancellation \\\n• Risk Management Actors – Monitor positions and enforce trading limits \\\n• Persistence Actors – Handle data storage and retrieval \\\n• WebSocket Server – Provides real-time data streaming to clients via non-blocking WebSocket connections\n\n### Client (WASM)\n• WASM Application – Runs entirely in the browser for real-time market data visualization \\\n• Web Workers – Handle WebSocket connections in separate threads for non-blocking data fetching \\\n• Real-time UI – Interactive orderbook visualization with ImGui-based interface\n\n## Features\n\n### Server\n• Non-blocking, concurrent processing of market data \\\n• Memory-efficient implementation with minimal allocations \\\n• Type-safe message passing between actors \\\n• WebSocket-based client communication \\\n• Pluggable strategy system for implementing various trading algorithms \\\n• Comprehensive logging and monitoring\n\n### Client\n• WASM-based client application for cross-platform compatibility \\\n• Non-blocking data fetching using WASM Web Workers \\\n• Real-time WebSocket communication with the server \\\n• Interactive orderbook windows with live market data \\\n• Responsive UI that doesn't block on network operations\n\n## Learning Outcomes\n\nThis project provides hands-on experience with: \\\n• Zig's comptime features and metaprogramming \\\n• Manual memory management with allocators \\\n• Error handling patterns in Zig \\\n• Concurrency without shared state \\\n• Performance optimization techniques \\\n• Safe interoperability with C libraries \\\n• WebAssembly compilation and deployment \\\n• Web Workers for non-blocking browser applications \\\n• WebSocket protocol implementation and optimization\n\n## Getting Started\n\n(Instructions for building and running the project will be added as development progresses.)\n\n## Project Status\n\n![](example_full.gif)\n![](example_start.gif)\n\n🚧 Early Development – The actor framework and core components are currently being designed and implemented.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FThomvanoorschot%2Fzigma","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FThomvanoorschot%2Fzigma","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FThomvanoorschot%2Fzigma/lists"}