Deep learningyou can see inside.
CodefyUI is an open-source, node-based builder for deep learning. Drag layers onto a canvas, wire them into a graph, press Run, then click any node to see the exact numbers that came out of it.
This graph runs right here.
1,1,8,8explicit1122heatmapOne canvas, from the first layer to a trained model.
The real editor is a browser app served by a single local process. Everything you build is a graph you can save, share and run again.
MNISTtrainCrossEntropyLoss64true7Adam0.0015autoMNISTtest256lineTest accuracy—Every node, by name.
The built-in library spans classical ML, CNNs, sequence models, transformers, LLMs, diffusion, reinforcement learning and vision-language-action models. Each category keeps its colour on the canvas.
- Start
- Dataset
- ImageFolderDataset
- DataLoader
- DatasetBatch
- Transform
- HuggingFaceDataset
- KaggleDataset
- TensorInput
- TextInput
- CSVReader
- ColumnSelector
- RowSelector
- Normalize
- SyntheticDataset
- SyntheticShapes
- SyntheticSegmentation
- SyntheticSequence
- TrainTestSplit
- ResizeTransform
- ToTensorTransform
- NormalizeTransform
- RandomCrop
- RandomHorizontalFlip
- RandomRotation
- ColorJitter
- RandAugment
- ComposeTransform
- Map
- Reduce
- Switch
- Conv2d
- Conv1d
- Conv2dExplicit
- ConvTranspose2d
- MaxPool2d
- AvgPool2d
- AdaptiveAvgPool2d
- BatchNorm2d
- Dropout
- Activation
- LSTM
- GRU
- RNNCell
- MultiHeadAttention
- TransformerEncoder
- TransformerDecoder
- MoELayer
- LLMChat
- Tokenizer
- WordVector
- TextEmbedding
- EmbeddingScatter
- CosineSimilarity
- AttentionMask
- AttentionHeatmap
- PositionalEncoding
- CausalLMModel
- LMCrossEntropyLoss
- LMTokenizer
- TextCorpusDataset
- LMTokenizedDataset
- DataMixDataset
- PerplexityEvaluate
- TextGenerate
- DocumentLoader
- TextChunker
- VectorStore
- Retriever
- PromptBuilder
- HFTextGenerate
- Upsample
- TimestepEmbedding
- Lerp
- GaussianNoise
- DDPMSampler
- DiffusionUNet
- DiffusionTrainingLoop
- DQN
- PPO
- EnvWrapper
- RewardModel
- KLDivergence
- PolicyRollout
- PPOClipObjective
- GroupRelativeAdvantage
- Discount
- GridWorldEnv
- PreferenceDataset
- BradleyTerryLoss
- BradleyTerryTrain
- VLAModel
- VLARollout
- VLAActionEval
- PushWorldEnv
- PushWorldDemos
- KNN
- LinearRegression
- LogisticRegression
- DecisionTreeClassifier
- RandomForestClassifier
- SVMClassifier
- MLPClassifier
- Accuracy
- Optimizer
- Loss
- TrainingLoop
- EvaluateModel
- LRScheduler
- SequentialModel
- BackwardOnce
- BatchNorm1d
- LayerNorm
- GroupNorm
- InstanceNorm2d
- Add
- MatMul
- Mean
- Multiply
- ScalarMultiply
- Permute
- Softmax
- Argmax
- Split
- Squeeze
- Stack
- TensorCreate
- Unsqueeze
- MaskedFill
- ImageReader
- ImageWriter
- ImageBatchReader
- FileReader
- CheckpointSaver
- CheckpointLoader
- ModelLoader
- ModelSaver
- Inference
- GraphInput
- GraphOutput
- VideoLoad
- VideoWrite
- Reshape
- Concat
- Flatten
- Linear
- Visualize
- Embedding
- PythonScript
- ScatterPlot2D
- DecisionBoundary
Made to be taught with.
CodefyUI grew up in the classroom. Plugin packs follow a textbook module by module, and every Edu node breaks one idea into named steps that the Teaching Inspector shows a row at a time.
Teaching Inspector
Record every node’s full output, compare a segment’s head input with its tail output, and turn on verbose internals to see attention scores and other values a layer normally hides.
How the Teaching Inspector worksEdu-ColumnStats
foundations · ClassicalPopulation standard deviation, one step per row. Edit the column and watch each step recompute.
- sumΣx
- divideΣx ÷ n = mean
- deviations²(x − mean)²
- variancemean of deviations²
- sqrt√variance = σ
Plugin packs
foundationsI1 Data representation · I2 Classical MLdeepI3 Vision · I4 SequencesrlI5 Reinforcement learningeduHands-on labs for I1 and I2statsDescriptive statistics for any dataset
cdui plugin install foundations deep rlWhen the graph works, put it to work.
The same graph you sketched in a lesson can run overnight, answer HTTP requests and live in git.
Runs belong to the server and queue per device, so closing the tab does not stop them. Sweep one graph over a grid or a random sample of parameters.
Read more about queue runs and sweepsFreeze a saved graph as a versioned app behind API keys. Every invoke is recorded, and editing the canvas never changes what is published.
Read more about publish as an apiThe Source Control tab stages, commits, branches, pulls and pushes a project directory without leaving the editor.
Read more about keep it in gitThe ResNet-18 CIFAR-10 example reaches 95.48% test accuracy, and two runs with the same seed match bit for bit.
Read more about reproduce a baseline
# Submit a graph to the server's queue. # The run keeps going after the terminal closes. $ cdui run examples/Usage_Example/CNN-MNIST/TrainCNN-MNIST/graph.json # Run one graph over a grid of parameter values. $ curl -X POST http://127.0.0.1:8000/api/sweeps \ -H "X-CodefyUI-Token: $TOKEN" \ --data "@sweep.json"
Start from a graph that already works.
Example graphs open as tabs. Run one as it is, then take it apart.
Browse the examples galleryModel architectures
- ResNetCNN
- ConvNeXtCNN
- EfficientNetCNN
- U-NetCNN
- ViTTransformer
- Swin TransformerTransformer
- BERTLLM
- GPTLLM
- LLaMALLM
- DiTDiffusion
- LSTM time seriesRNN
- BiGRU speech recognitionRNN
- Seq2Seq with attentionRNN
- DQN AtariRL
- PPO roboticsRL
Hands-on
- Train a CNN on MNIST
- Train ResNet-18 on CIFAR-10
- king − man + woman ≈ queen
- Fully local RAG
- Pretrain an LM on TinyStories
- Forward diffusion on a digit
- Mixture-of-experts routing
- Train a VLA on PushWorld
A new node is one Python file.
Subclass BaseNode, declare ports and parameters, and drop the file into custom_nodes. Reload, and it appears in the library with its own card.
Plugins
Install packs from the Plugin Center or the terminal. Third-party packs come from GitHub, pinned to a commit and checked before they load.
cdui plugin install owner/repoGraph Copilot, a community plugin, builds and edits graphs through chat with OpenAI, Claude, OpenRouter or a local model.
from app.core.node_base import BaseNode, DataType, PortDefinition
class MyNode(BaseNode):
NODE_NAME = "MyNode"
CATEGORY = "Custom"
DESCRIPTION = "Does something"
@classmethod
def define_inputs(cls):
return [PortDefinition(name="input", data_type=DataType.TENSOR)]
@classmethod
def define_outputs(cls):
return [PortDefinition(name="output", data_type=DataType.TENSOR)]
def execute(self, inputs, params):
return {"output": inputs["input"]}Install in one line.
The installer sets up git, uv and Python, downloads a prebuilt editor and picks a PyTorch build for your GPU. Node.js is not needed.
Runs on CPU, NVIDIA CUDA, Apple Silicon MPS and AMD ROCm.
Full installation guide- 01
Install
curl -fsSL https://raw.githubusercontent.com/CodefyUI/CodefyUI/main/install.sh | bashpowershell -ExecutionPolicy ByPass -c "irm https://raw.githubusercontent.com/CodefyUI/CodefyUI/main/install.ps1 | iex" - 02
Start the server, from any new terminal
cdui start - 03
Open the editor
localhost:8000
Free to use, open to read.
CodefyUI is licensed under AGPL-3.0. Running it as published, on a laptop, in a lab or on a school server, needs no commercial license. For closed-source, SaaS or OEM use, a commercial license is available from the maintainers.
Star on GitHub