{
  "$schema": "https://ambiqai.github.io/helia-ui/schema/reference-model-1.json",
  "generatedFrom": {
    "sourceCommit": "cf2246a7ad439fa38d57462118e7840e5497a685",
    "tool": "pyref",
    "version": "1.7.3"
  },
  "language": "python",
  "modules": [
    {
      "description": "# AotModel API\n\nThe `AotConverter` class is responsible for converting a model into an AOT inference C module.\n\n**Classes**\n\n| Name | Description |\n| --- | --- |\n| `AotConverter` | Performs the AOT conversion process. |\n\nCopyright 2025 Ambiq. All Rights Reserved.",
      "name": "converter",
      "path": "helia_aot.converter",
      "submodules": [],
      "summary": "AotModel API",
      "symbols": [
        {
          "description": "Converts a trained model into a self-contained AOT inference C module.\n\nThe converter owns the six-stage pipeline (Load, Transform, Resolve, Plan,\nEmit, Export) described on ``convert()``, which is the single entry point;\nthe CLI is a thin wrapper around it. All behavior is driven by the\n``ConvertArgs`` config supplied at construction,\nand every dispatch (parsers, operator classes, transforms) goes through the\nregistry context, so a caller can extend the compiler without patching it.",
          "examples": [],
          "id": "helia_aot.converter.AotConverter",
          "kind": "class",
          "language": "python",
          "members": [
            {
              "description": "Conversion parameters.",
              "examples": [],
              "id": "helia_aot.converter.AotConverter.config",
              "kind": "attribute",
              "language": "python",
              "members": [],
              "name": "config",
              "params": [],
              "raises": [],
              "returns": [],
              "signature": "config: ConvertArgs = config",
              "source": {
                "line": 84,
                "path": "helia_aot/converter.py",
                "url": "https://github.com/AmbiqAI/helia-aot/blob/cf2246a7ad439fa38d57462118e7840e5497a685/helia_aot/converter.py#L84"
              },
              "summary": ""
            },
            {
              "description": "Registry context used for parser, operator and\ntransform dispatch.",
              "examples": [],
              "id": "helia_aot.converter.AotConverter.registry_context",
              "kind": "attribute",
              "language": "python",
              "members": [],
              "name": "registry_context",
              "params": [],
              "raises": [],
              "returns": [],
              "signature": "registry_context = registry_context or build_default_registry_context()",
              "source": {
                "line": 85,
                "path": "helia_aot/converter.py",
                "url": "https://github.com/AmbiqAI/helia-aot/blob/cf2246a7ad439fa38d57462118e7840e5497a685/helia_aot/converter.py#L85"
              },
              "summary": ""
            },
            {
              "description": "Convert the model to an AOT module.\n\n:::note[The conversion process consists of six stages]\n1. Load (Backend → AIR)\n2. Transform (Graph-Level Optimizations)\n3. Resolve (Final AIR Structure)\n4. Plan (Memory & Handler Planning)\n5. Emit (Code Generation)\n6. Export (Module Export)\n\n:::\n\nCode is generated in a temporary work directory that is removed once\nthe conversion ends, whether it succeeds or fails, unless\n``keep_work_dir`` is set.",
              "examples": [],
              "id": "helia_aot.converter.AotConverter.convert",
              "kind": "method",
              "language": "python",
              "members": [],
              "name": "convert",
              "params": [],
              "raises": [],
              "returns": [
                {
                  "description": "Code generation context. Its ``work_path`` no",
                  "name": "CodeGenContext",
                  "type": "CodeGenContext"
                },
                {
                  "description": "longer exists unless ``keep_work_dir`` is set.",
                  "type": "CodeGenContext"
                }
              ],
              "signature": "convert() -> CodeGenContext",
              "source": {
                "line": 87,
                "path": "helia_aot/converter.py",
                "url": "https://github.com/AmbiqAI/helia-aot/blob/cf2246a7ad439fa38d57462118e7840e5497a685/helia_aot/converter.py#L87"
              },
              "summary": "Convert the model to an AOT module."
            }
          ],
          "name": "AotConverter",
          "params": [
            {
              "description": "Conversion parameters.",
              "name": "config",
              "type": "ConvertArgs"
            },
            {
              "default": "None",
              "description": "Optional registry context for parser/operator/transform\ndispatch. If omitted, a fresh default frozen context is created.",
              "name": "registry_context",
              "type": "RegistryContext | None"
            }
          ],
          "raises": [],
          "returns": [],
          "signature": "AotConverter(config: ConvertArgs, registry_context: RegistryContext | None = None)",
          "source": {
            "line": 56,
            "path": "helia_aot/converter.py",
            "url": "https://github.com/AmbiqAI/helia-aot/blob/cf2246a7ad439fa38d57462118e7840e5497a685/helia_aot/converter.py#L56"
          },
          "summary": "Converts a trained model into a self-contained AOT inference C module."
        }
      ]
    }
  ],
  "name": "helia_aot"
}
