Show HN:Gene - 一種具有統一通用資料類型的 Lisp 風格程式語言

Show HN:Gene - 一種具有統一通用資料類型的 Lisp 風格程式語言

Hacker News·

Gene 是一種新的 Lisp 風格、同構性程式語言,其核心圍繞著一個獨特的、統一的「Gene」資料結構。該專案包含一個基於 Nim 的位元組碼虛擬機器,並可選整合本地 LLM 運行時。

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

To see all available qualifiers, see our documentation.

License

Uh oh!

There was an error while loading. Please reload this page.

gene-lang/gene

Folders and files

Latest commit

History

Repository files navigation

Gene Programming Language

Gene is a general-purpose, homoiconic language with a Lisp-like surface syntax.
This repository hosts the bytecode virtual machine (VM) implementation written in Nim.

Repository Layout

VM Status

Major Features

The Gene Data Structure — The Heart of Gene

The Gene data structure is unique and central to the language. Unlike JSON or S-expressions, Gene combines three structural components into one unified type:

This unified structure enables:

Example - Data as Code:

Other Key Features

Building

Local LLM Runtime (llama.cpp)

Gene ships with a genex/llm namespace that can call local GGUF models through llama.cpp. The runtime is optional — you can stay on the built-in mock backend by compiling with -d:GENE_LLM_MOCK — but if you want real inference:

Usage tips:

Command-Line Tool

All commands are dispatched through bin/gene <command> [options]:

Run bin/gene help for the complete command list and examples.

Examples

See examples/ for additional programs and CLI demonstrations.

Testing

The Nim tests exercise compiler/VM internals, while the shell suite runs real Gene code end-to-end.

Documentation

The documentation index in docs/README.md lists the current architecture notes, design discussions, and implementation diaries. Highlights include:

Performance

Latest fib(24) benchmarks (2025 measurements) place the optimised VM around 3.8M function calls/sec on macOS ARM64. See docs/performance.md for methodology, historical comparisons, and profiling insights.

License

MIT License

About

Resources

License

Uh oh!

There was an error while loading. Please reload this page.

Stars

Watchers

Forks

Releases

Packages

  0

Contributors

  2

Uh oh!

There was an error while loading. Please reload this page.

Languages

Footer

Footer navigation

Hacker News

相關文章

  1. Show HN:一個為大型語言模型優化的程式語言

    3 個月前

  2. Show HN:CIE – 開源程式碼智慧引擎,專為 AI 編碼助手打造

    3 個月前

  3. Show HN:GlyphLang – 一種AI優先的程式語言

    3 個月前

  4. Show HN:Semlib – 利用 LLM 進行語義資料處理

    7 個月前

  5. Show HN:Giselle – 用於建構 AI 工作流程的開源視覺化編輯器

    4 個月前