Publishing Guide
Step-by-step guide to publishing your neuromorphic models to the registry.
Before You Begin
To publish a model to Synfire, you'll need:
- An Synfire account and organization
- A NIR model file (
model.nir) - A metadata card (
nir-card.json)
Creating a NIR Card
Every release requires a nir-card.json file with metadata about your model:
{
"license": "MIT",
"capabilities": ["Classification", "Image Recognition"],
"tested_platforms": [
{ "name": "Pulsar", "framework": "nengo-edge", "version": "2.1.0" },
{ "name": "Generic", "type": "simulation" }
],
"description": "A spiking neural network classifier for MNIST digits",
"tags": ["classification", "mnist", "snn"],
"authors": [
{
"name": "Jane Doe",
"email": "jane@example.com"
}
],
"links": {
"paper": "https://arxiv.org/abs/...",
"code": "https://github.com/..."
}
}Required Fields
license- SPDX license identifier (e.g., MIT, Apache-2.0)
Optional Fields
capabilities- Array of model capabilities (e.g., Classification, Object Detection, Anomaly Detection)tested_platforms- Array of platforms where the model has been testedtags- Array of tags for categorizationdescription- Brief description of the model
Auto-Extracted Fields
The following fields are automatically extracted from your model.nir file:
neuron_types- Detected neuron primitives (e.g., LIF, IF, CuBa)linear_ops- Linear operations in the modelnode_count- Total number of nodesparameter_count- Total model parametersmodel_size_category- Computed from parameter count (tiny/small/medium/large)
Publishing with the CLI
The easiest way to publish is with the CLI:
# First, authenticate
synfire login
# Publish your model
synfire push pabogdan/lifneuron --version 1.0.0 \
--model ./model.nir \
--card ./nir-card.jsonThe example target requires ownership of the repository; use a repository in your namespace for real publishing.
You can also include release notes:
synfire push pabogdan/lifneuron --version 1.0.0 \
--model ./model.nir \
--card ./nir-card.json \
--notes ./RELEASE_NOTES.mdPublishing with the SDK
from pathlib import Path
from synfire import Client
client = Client()
client.publish(
repo="pabogdan/lifneuron",
version="1.0.0",
model_path=Path("./model.nir"),
card_path=Path("./nir-card.json"),
notes_path=Path("./RELEASE_NOTES.md"),
)Versioning
Synfire accepts release versions in the format MAJOR.MINOR[.PATCH][-PRERELEASE]:
2024.5- Calendar-style release1.0.0- Three-component release0.3.1-rc1- Pre-release1.0.0-beta.1- Pre-release with dot identifier
Important Notes
- Releases are immutable - Once published, a version cannot be modified or re-uploaded
- Maximum file size - 5 MB per file. Email contact@synfire.dev to request a larger upload limit.
- License required - The
licensefield in your NIR card is required for validation - SHA256 checksums - Computed automatically for all artifacts