Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add topprismdata/cultivating-ml-agent --skill onnx-minimal-network-designgit clone --depth 1 https://github.com/topprismdata/cultivating-ml-agentWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/topprismdata/cultivating-ml-agent/onnx-minimal-network-design)<a href="https://agentmods.dev/skills/topprismdata/cultivating-ml-agent/onnx-minimal-network-design"><img src="https://agentmods.dev/badge/skills/topprismdata/cultivating-ml-agent/onnx-minimal-network-design/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/topprismdata/cultivating-ml-agent/onnx-minimal-network-design"><img src="https://agentmods.dev/badge/skills/topprismdata/cultivating-ml-agent/onnx-minimal-network-design.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00144 | $0.00982 |
| Opus 5.5 | $0.00058 | $0.00393 |
| Sonnet 5.5 | $0.00029 | $0.00196 |
| Haiku 4.5 | $0.00014 | $0.00098 |
Grade A, and why
onnx-minimal-network-design scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 95 lines — stays where its author put it; the contents beside it link to each section on GitHub.
ONNX Minimal Network Design
Problem
Neural network golf competitions require the smallest possible ONNX network
that correctly implements a transformation. Score = max(1, 25 - ln(memory + params)).
Smaller networks → exponentially higher scores. The key insight: memory dominates cost (intermediate tensor bytes), not parameters.
Solution
Core Scoring Formula
memory = Σ(bytes of all intermediate tensors) # input/output are FREE
params = Σ(initializer element counts)
score = max(1, 25 - ln(memory + params))
Design Principle 1: Single-Node = Zero Memory
A single-node graph (1 Conv/Gather/Transpose) has zero intermediate memory (output tensor is free). Only params count.
Implication: A 1-node Conv with 900 params (cost=900, score=18.2) beats a 4-node net with 200 params + 5000 memory (cost=5200, score=16.3).
Design Principle 2: Conv is a Linear Classifier
A Conv node maps 3×3 one-hot neighborhoods → output channels. This is a linear classifier on 90-dim features (9 positions × 10 colors).
To find Conv weights for a local rule:
- Collect all (3×3 neighborhood, output color) pairs from training data
- Verify the rule is deterministic (same neighborhood → same output)
- Train LogisticRegression (multi-class, C=1e4, solver='newton-cg') on the pairs
- Extract coef_ as Conv W[10,10,3,3], intercept_ as B[10]
- Verify ONNX runtime output matches ground truth on ALL examples
Limitation: If LogReg accuracy < 100%, the rule is NOT linearly separable. Need nonlinear ops (Cast/Equal/Where) — a single Conv cannot implement it.
Design Principle 3: Gather for Color Permutations
A pixel-wise color map (e.g., swap color 3↔4) is a 1-node Gather:
- idx = [0,5,6,4,3,1,2,7,9,8] (10-element lookup table)
- Gather(input, idx, axis=1) maps each one-hot vector to the permuted one
- Cost: 10 params, 0 memory → score ≈ 22.7
Design Principle 4: Sparse Initializers REJECTED
Converting dense sparse weights to sparse_initializer reduces params but
onnx.checker.check_model(full_check=True) rejects sparse Conv weights:
W typestr: T, has unsupported type: sparse_tensor(float)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3mo ago First seen · 95 lines · 144 tokens per session scan A 1c45f9c64651
onnx-minimal-network-design is a skill published in the GitHub repository topprismdata/cultivating-ml-agent (5 stars, last pushed 1mo ago), licensed MIT. It adds 144 tokens to every session and 982 once invoked, about $0.0006 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
onnx-minimal-network-design compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| onnx-minimal-network-designtopprismdata/cultivating-ml-agent | Skill | 5 | 1mo ago | MIT | A | 144 | Claude Code, Codex |
| huggingface-hubbraxtonROSE4/zorro-agent | Skill | 11 | 7mo ago | MIT | C | 43 | Claude Code, Codex |
| agent-v3-memory-specialistruvnet/ruflo | Skill | 83k | today | MIT | A | 25 | Claude Code |
| agent-safla-neuralruvnet/ruflo | Skill | 83k | today | MIT | A | 24 | Claude Code |
| neural-trainingruvnet/ruflo | Skill | 83k | today | MIT | A | 64 | Claude Code |
| kv-cache-designbojieli/ai-agent-book | Skill | 60k | yesterday | Apache-2.0 | A | 91 | Claude Code, Codex |
| reward-designbojieli/ai-agent-book | Skill | 60k | yesterday | Apache-2.0 | A | 131 | Claude Code, Codex |