Documentation v2.5.0

Neural Stream Architecture

Build by Ethcocoders

Alien-LLM is an experimental hybrid architecture designed to bypass the quadratic bottleneck of traditional Transformers. It introduces a permanent, evolvable neural state.

Core Innovation

While Transformers use **Self-Attention** (which gets 4x slower as context doubles), Alien-LLM uses **State-Space Layers** (which stay at the same speed regardless of length).

SSM: Permanent Recurrent State

The State Space Model (SSM) treats input tokens as a continuous signal. It maintains a hidden state matrix that evolves over time without forgetting previous tokens.

x_{k+1} = A * x_k + B * u_k
y_k = C * x_k + D * u_k

RFA: Recursive Feature Attention

Recursive Feature Attention (RFA) maps input features into a high-dimensional space and summarizes them using a recurrent relationship. This allows for focus on specific patterns without the massive memory cost of KV-Caches.

Linear Complexity

Maintains O(L) time complexity where L is sequence length.

Dynamic Memory

Actively discards irrelevant token data to save RAM.

Memory Sharding (CHE)

To fit massive vocabularies into small memory footprints, we use **Compact Hashed Embeddings**. Instead of one giant matrix, we use 4 sharded hash tables.

Sharding Logic

  • Reduced memory footprint by 75%.
  • Universal hash consistency across C++ and Python.
  • Sub-linear lookup speeds.