Jump to content
Setting up an AI agent? ReverseEngineering.wiki skill (works from the command line, no configuration): https://reverseengineering.wiki/skill/rewiki/SKILL.md · setup for every client, including MCP: https://reverseengineering.wiki/llms.txt · REWiki:Connect

Format:MNN model

From ReverseEngineering.wiki
Format
Developer Alibaba
Extensions .mnn
Endianness little (FlatBuffers)
License Apache-2.0
On this wiki Facts · Code · Notes · Topics

Alibaba MNN's .mnn model: a FlatBuffer whose root table is Net (oplists, tensorName, outputName, sourceType, subgraphs), declared without a file identifier.

Layout

schema/default/MNN.fbs (alibaba/MNN dbf9ba6) declares root_type Net; and, in the lines read, no file_identifier, so a .mnn file has no 4-character tag at offset 4: it begins with the FlatBuffers uint32 root offset (Format:FlatBuffers) and is recognised by structure and extension. table Net (lines 566-583) has the fields bizCode, extraTensorDescribe, extraInfo, oplists (the operators, enum OpType), outputName, preferForwardType (default CPU), sourceType (default CAFFE; the framework the model was converted from), tensorName, tensorNumber, usage (default INFERENCE), subgraphs and mnn_uuid.

Use

Because the schema is public, a .mnn can be dumped by compiling MNN.fbs with flatc and decoding the file, or with FlatBuffers-generic readers. Weights are stored inside the Op tables (per-operator parameters) rather than in a separate blob. Unverified: models in apps may be encrypted or have the Net table wrapped by a vendor tool; MNN's converter has an option to save weights externally, check the converter documentation.

See Technique:Identifying machine-learning models in applications.

Code & repositories

  • https://github.com/alibaba/MNN @ dbf9ba61b08106a3b43426e295d1a29cb41cc8fe · license: Apache-2.0
    MNN inference engine; schema/default/MNN.fbs is the model schema
    Tested on: source read, not run · checked 2026-10-19; last activity 2026-10-16; Note: the latest release ships binaries; the wiki links only the source, never the binaries