explaingit

miaai-lab/deepseek-v4-flash-dual-dgx-spark-1m-context

Analysis updated 2026-05-18

15ShellAudience · ops devopsComplexity · 5/5Setup · hard

TLDR

Scripts and configs for running DeepSeek V4 Flash with a one million token context across two NVIDIA DGX Spark machines.

Mindmap

mindmap
  root((DeepSeek V4 Flash Dual DGX))
    What it does
      Self hosts a large model
      1M token context
      Tensor parallelism
    Tech stack
      Shell
      Docker
      InfiniBand
    Use cases
      Self host an LLM
      Serve OpenAI compatible API
      Split model across GPUs
    Audience
      DGX Spark owners
      Infra teams

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Self host DeepSeek V4 Flash across two DGX Spark nodes instead of using a cloud API.

USE CASE 2

Serve an OpenAI compatible API endpoint with up to one million tokens of context.

USE CASE 3

Run a Mixture of Experts model with tensor parallelism split across two GPUs.

What is it built with?

ShellDockerInfiniBand

How does it compare?

miaai-lab/deepseek-v4-flash-dual-dgx-spark-1m-contextaduskelebe/diffpilotamrit-regmi/immich_edge
Stars151515
LanguageShellShellShell
Setup difficultyhardeasyhard
Complexity5/52/54/5
Audienceops devopsdeveloperops devops

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · hard Time to first run · 1h+

Requires two DGX Spark nodes connected via InfiniBand, first run downloads model weights and can take 20 minutes.

In plain English

This repository provides scripts and configuration files for running a large AI language model called DeepSeek V4 Flash across two high-performance NVIDIA computers called DGX Spark nodes. The setup is designed for people who already have access to this specialized hardware and want to run the model themselves rather than relying on a cloud service. DeepSeek V4 Flash is a type of model called a Mixture-of-Experts, which means different parts of the model activate depending on what the input asks for, making it more efficient than older designs. The main headline feature in this deployment is the context length: the server is configured to accept up to one million tokens at once, which is roughly equivalent to a very long book or many hours of conversation. Most AI services limit you to a fraction of that. The two machines run the model in parallel using a technique called tensor parallelism, where the model's weights are split across the two GPUs and both do work simultaneously. They communicate through an InfiniBand connection, which is a high-speed cable type used in data centers. The setup also uses FP8 KV-cache, a memory compression technique that lets the hardware store more information about the current conversation without running out of GPU memory. Setup involves cloning the repository on both machines, copying and editing a configuration file with the IP addresses and network interface names for your specific cluster, and then running a start script from the head node. The start script remotely starts the container on the second machine via SSH and then starts its own, with the two containers connecting automatically. The whole process can take up to 20 minutes on first run because the model weights need to download. Once running, the server exposes an API at port 8000 on both nodes that is compatible with the same format used by OpenAI, so any software already written to talk to ChatGPT can talk to this server instead with minimal changes.

Copy-paste prompts

Prompt 1
Walk me through configuring the IP addresses and network interfaces for my DGX Spark cluster.
Prompt 2
Explain what tensor parallelism and FP8 KV cache do in this DeepSeek V4 Flash setup.
Prompt 3
Help me point my existing OpenAI API client at this self hosted DeepSeek V4 Flash server.

Frequently asked questions

What is deepseek-v4-flash-dual-dgx-spark-1m-context?

Scripts and configs for running DeepSeek V4 Flash with a one million token context across two NVIDIA DGX Spark machines.

What language is deepseek-v4-flash-dual-dgx-spark-1m-context written in?

Mainly Shell. The stack also includes Shell, Docker, InfiniBand.

How hard is deepseek-v4-flash-dual-dgx-spark-1m-context to set up?

Setup difficulty is rated hard, with roughly 1h+ to a first successful run.

Who is deepseek-v4-flash-dual-dgx-spark-1m-context for?

Mainly ops devops.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.