AGENT SKILL

deep-learning

Assemble and debug ML-From-Scratch NeuralNetwork, layers, activations, losses, optimizers, MLP/CNN/RNN, and generative model-building workflows.

License 许可
MIT
最近更新
2026-09-03
Stars
★ 351
Forks
27

01 前言 Front Matter

name
deep-learning
license
MIT
metadata
{ "disco-role": "operating" }
description
Assemble and debug ML-From-Scratch NeuralNetwork, layers, activations, losses, optimizers, MLP/CNN/RNN, and generative model-building workflows.
disable-model-invocation
true

02 资源文件 5

03 SKILL.md 正文

deep-learning

Use this sub-skill when a task involves ML-From-Scratch's neural-network framework: NeuralNetwork, deep-learning layers, activation/loss/optimizer selection, MLP/CNN/RNN model assembly, or advanced generative model builders.

Route here for

  • Building or debugging NeuralNetwork(optimizer, loss, validation_data=None) workflows.
  • Selecting and ordering layers such as Dense, Activation, Dropout, Flatten, Conv2D, pooling, BatchNormalization, RNN, Reshape, and UpSampling2D.
  • Choosing optimizers, losses, and activations for small CPU examples.
  • Diagnosing shape errors in MLP, CNN, RNN, autoencoder, GAN, or DCGAN-style builders.
  • Creating a tiny CPU smoke check that imports the installed package and performs one deterministic epoch.

Route away

  • Classical supervised estimators such as tree, regression, SVM, Naive Bayes, perceptron, or GMM classifier workflows: use supervised-learning.
  • Clustering, dimensionality reduction, association mining, and non-neural unsupervised estimators: use unsupervised-learning.
  • Gym environment loops, replay memory, epsilon decay, CartPole training/play loops, and DQN compatibility: use reinforcement-learning. This sub-skill only covers the neural model-builder portion.

Operating procedure

  1. Treat the installed mlfromscratch package as the runtime source of truth. Do not require source-checkout reads or original demo scripts during user work.
  2. Start with the framework contracts in references/api-reference.md, especially input shape conventions and exact constructor names.
  3. Use references/workflows.md for MLP, CNN, RNN, autoencoder, GAN/DCGAN, and fast validation recipes.
  4. If a user reports an exception or unexpected output, diagnose from references/troubleshooting.md before changing model code.
  5. For quick environment validation, run one of the bundled scripts:
    • python scripts/run_mlp_smoke.py
    • python scripts/run_cnn_smoke.py

High-signal rules

  • The first shape-bearing layer must receive input_shape without the batch dimension: e.g. Dense(..., input_shape=(n_features,)), Conv2D(..., input_shape=(channels, height, width)), or RNN(..., input_shape=(timesteps, input_dim)).
  • CrossEntropy expects one-hot encoded targets with the same final class dimension as the network output. For multiclass classification, finish with Dense(n_classes) then Activation('softmax').
  • The framework expects channels-first image batches for convolution: (n_samples, channels, height, width), not channels-last.
  • Add transform layers in data-flow order: shape-bearing first layer, activation after affine/convolution/recurrent output, Flatten() before dense layers after image-like tensors.
  • Full demos can be slow and plot by default. Prefer the bundled smokes or reduce epochs/sample counts and set a headless Matplotlib backend before importing plotting libraries.

04 同仓库更多 Skills

VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-triton-opt

Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-solve

END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-skill

PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-pattern-fusion

Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-orchestrate

Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-feedback

Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).

★ 351