# Import and export

The typed graph sits in the middle; most things can become one, and the graph can become most things you need to ship.

## In

- **From a paper**: paste an arXiv link, id, or any article URL; the architecture is parsed from the page into an editable graph.
- **From PyTorch code**: paste an `nn.Module`; the graph is reconstructed. Round-trip fidelity (graph to code to graph) is 100% on names, types, and edges across 8 canonical fixtures (BERT, GPT-2, ViT, LLaMA, ResNet-50, Whisper encoder, Mamba, MLP), gated in CI.
- **From HuggingFace**: load a model by id; the config is fetched and the matching graph built, with shapes inferred on import. Covers transformer, vision, diffusion, and ASR families.
- **From ONNX / safetensors**: drop a file; the graph is reconstructed as editable nodes.
- **From a figure**: import an architecture diagram image; the structure is extracted.
- **Cross-validate**: check that a paper's described architecture matches a code implementation.

Every import is verified before it loads; malformed or degenerate architectures are rejected with a reason.

## Out

- **PyTorch** `nn.Module`, a runnable Jupyter notebook, and a full training project you can run on your own infrastructure.
- **Deploy bundle**: FastAPI server + Dockerfile + project zip.
- **ONNX** straight from the canvas; drop it back in the browser to run inference live (WASM/WebGPU).
- **Docs and figures**: model card, architecture report, slides, TikZ, publication-style SVG/PNG figures.
- **Customize before generate**: exporters accept an audience / hardware / constraints context, so a model card for reviewers and a deploy README for your infra team come out different.

## Training

Real GPU training via Modal, a free Colab/Kaggle round-trip loop (the notebook trains, reports per-epoch curves back, and uploads the best checkpoint), or simulation mode for iterating on the design. The mode is always shown explicitly, so you never think you are paying for GPU time when you are not.
