AMF (AML Modeling Framework) is an open-source library capable of parsing and validating AML metadata documents. AMF is written in Scala.js, and you can execute it in the JVM, with Node.js, or from a browser. You can use AMF as a standalone command-line tool or as a library in Scala and Java, and in web and Node.js applications.
AMF project vision
AML enables you to formally describe different kinds of models, whether syntactic models—specific to languages or specifications-or semantic models specific to industries and domains.
AMF can parse and generate descriptions of those models as sets of modular documents and store those connected descriptions into a single unified data graph.
The modular design of AMF enables you to create plugins capable of parsing other metadata syntaxes not defined by AML. For example, the most used AMF module, the web-api module, can parse RAML, OAS (formerly Swagger), and AsyncAPI specification languages.
Furthermore, AMF can also validate APIs and emit them in different API languages.
AMF project goals
The AMF project supports:
- Multiple formats with a unified programming interface and model
- Syntactic and semantic model layers
- Validation at syntactic and semantic model layers
- Production of formal specifications of any specification language
- An Extensible, single syntactic model for multiple semantic models
- The creation of consistent parsing behaviors across different syntactic models
- Bi-directional transformation and export
- Custom parsing, resolution, and generation pipelines
AMF natively supports the following formats and semantic and syntactic models:
- WebApi (or "Web APIs" as in "APIs accessible over the network")
- JSON-LD "AMF model"
- RAML 0.8 and 1.0 (mapped to "WebApi")
- OpenAPI (OAS) 2.0 and 3.0 (mapped to "WebApi")
- AsyncAPI 2.0 (mapped to "AsyncApi")
You can extend these models and others using custom AML-defined models. For formats and models that cannot be expressed with AML, you can create custom plugins.
The key features of AMF include:
- Stages and pipelines
- Custom model constraints (WebApi)
- SHACL (vocabularies and custom validations)
Artifacts to use AMF can be obtained from: