modelc is a command-line tool and specification for packaging AI models as portable, inspectable containers.
It defines a simple, consistent way to describe:
- model artifacts (weights, tokenizer, assets)
- runtime requirements
- input and output interfaces
- execution behavior
The result is a self-contained unit that can be built, shared, inspected, and executed without guesswork.
The Problem
Running AI models today is inconsistent and often fragile.
Even when models are publicly available, using them typically requires:
- resolving dependencies manually
- reconstructing runtime environments
- understanding undocumented assumptions
- writing custom inference code
The same model may behave differently across environments, and in many cases, it is not clear what a model actually requires to run.
There is no standard unit of AI execution comparable to what containers introduced for software.
The Approach
modelc introduces a minimal standard:
A model is a portable unit with a declared structure, interface, and execution contract.
Each model container includes:
- a declarative manifest (
model.yaml) - referenced artifacts (model files, tokenizer, etc.)
- a defined entrypoint for execution
- a structured input/output interface
This creates a clear boundary between:
- what a model is
- how it runs
- what it expects and returns
Core Capabilities
modelc provides three primary operations:
Build
Package a model into a portable artifact.
modelc build
Produces:
dist/{name}-{version}.modelc.tar.gz
Inspect
Understand a model without running it.
modelc inspect
Outputs:
- metadata (name, version)
- runtime requirements
- artifacts
- input/output schema
- entrypoint
Run
Execute a model with structured input.
modelc run . --input '{"text":"I love this"}'
The model receives JSON input via stdin and returns JSON output via stdout.
Example Manifest
apiVersion: modelc.dev/v0
kind: ModelContainer
metadata:
name: sentiment-basic
version: 0.1.0
runtime:
type: python
version: "3.11"
artifacts:
weights:
path: ./model/
format: pytorch
tokenizer:
path: ./tokenizer/
format: huggingface
interface:
input:
type: text
schema:
text: string
output:
type: classification
schema:
label: string
confidence: float
entrypoint:
command: python run.py
Execution Model
modelc defines a simple and explicit execution contract:
- input is passed as JSON via
stdin - the entrypoint processes the input
- output is returned as JSON via
stdout - errors are written to
stderr
This approach keeps execution:
- predictable
- language-agnostic in principle
- easy to test and debug
Why It Matters
modelc addresses a foundational gap in AI infrastructure:
-
Reproducibility
Models can be executed consistently across environments. -
Inspectability
Model structure, requirements, and interfaces are explicit. -
Portability
Models can be packaged and moved as self-contained units. -
Composability
Standardized interfaces make models easier to integrate into larger systems.
Positioning
modelc is not a framework or platform.
It is a systems-level primitive:
- a unit of execution
- a packaging standard
- a boundary for verification and control
This makes it suitable as a foundation for:
- evaluation pipelines
- contract-based AI systems
- sovereign and local model deployment
- future registry and signing layers
Status
modelc is in early development (v0).
The current focus is:
- defining a stable manifest format
- implementing a minimal CLI
- establishing a clear execution model
Future work may include:
- dependency isolation
- signing and provenance
- registry support
- multi-language runtime support
Related Work
modelc is part of a broader effort to define composable AI system primitives, including:
-
AI Contracts
Structured definitions for model input/output behavior -
AI Evaluation Pipelines
Standardized testing and validation of model outputs
Together, these form a foundation for more reliable and inspectable AI systems.
Links
- GitHub: https://github.com/modelc-systems/modelc
- Specification: https://github.com/modelc-systems/modelc-spec