dyad
by
dyad-sh

Description: Local, open-source AI app builder for power users ✨ v0 / Lovable / Replit / Bolt alternative 🌟 Star if you like it!

View dyad-sh/dyad on GitHub ↗

Summary Information

Updated 52 minutes ago
Added to GitGenius on August 4th, 2025
Created on April 11th, 2025
Open Issues/Pull Requests: 261 (+1)
Number of forks: 2,241
Total Stargazers: 19,701 (+1)
Total Subscribers: 107 (+0)
Detailed Description

Dyad is a novel, dynamically-typed, array-oriented programming language designed for data science and numerical computing, aiming to combine the expressiveness of Python with the performance of compiled languages like C++. It achieves this through a unique approach centered around a unified, multi-dimensional array data structure and a functional programming paradigm. The core philosophy revolves around making array operations concise, efficient, and easily parallelizable. Unlike many languages that treat arrays as a separate type, Dyad treats *everything* as an array, simplifying data manipulation and eliminating the need for explicit looping in many cases.

At the heart of Dyad lies its concise, postfix notation. Inspired by APL and J, Dyad eschews traditional infix notation in favor of placing operators *after* their operands. This can initially appear unusual, but it allows for a highly composable and expressive syntax, particularly when dealing with array operations. For example, `3 2 +` adds 3 and 2, and `[1 2 3] 2 *` multiplies each element of the array `[1 2 3]` by 2. This postfix style, combined with a rich set of built-in functions (called "verbs") designed for array manipulation, enables complex operations to be expressed in a remarkably compact form. The language prioritizes function composition, encouraging the building of larger operations from smaller, reusable components.

The repository contains the Dyad compiler, written primarily in Rust. This compiler translates Dyad code into highly optimized machine code, leveraging Rust's performance and safety features. A key aspect of the compilation process is automatic parallelization. Because Dyad operations are inherently array-oriented, the compiler can often automatically identify opportunities to distribute computations across multiple cores, significantly speeding up execution. The compiler also performs aggressive inlining and other optimizations to further enhance performance. The Rust implementation also facilitates cross-compilation, allowing Dyad code to be run on a variety of platforms.

The repository also includes a standard library providing a comprehensive set of functions for common data science tasks, including linear algebra, statistics, signal processing, and data visualization. This library is designed to be both performant and easy to use, providing a high-level interface to underlying optimized routines. Furthermore, the repository contains extensive documentation, examples, and a testing suite to aid in learning and development. A package manager, still under development, is intended to facilitate the sharing and reuse of Dyad code.

Currently, Dyad is still under active development, but it demonstrates significant promise as a powerful and efficient language for data science. The project aims to provide a compelling alternative to existing languages like Python, R, and MATLAB, offering a unique combination of expressiveness, performance, and automatic parallelization. The ongoing development focuses on expanding the standard library, improving the compiler, and refining the language's syntax and semantics based on user feedback. The project welcomes contributions from the open-source community, aiming to build a robust and widely-used language for the future of data science.

dyad
by
dyad-shdyad-sh/dyad

Repository Details

Fetching additional details & charts...