Skip to main content

CLI tool for LIM-compatible micro model project scaffolding

Project description

LIM MM CLI: Command Line Interface for Micro Model Management

🎯 LIM Concept

LIM (Large Integration Model) aims to be an open source, realtime data retrieval and micro model training enhancement framework.

Philosophy: "Human Socialism Model Network"

LIM represents a paradigm shift from monolithic "God Models" (LLMs) to a decentralized, collaborative network of specialized intelligence.

  • Socialism of Intelligence: Democratized AI through community-driven micro models.
  • Model on the Air: Intelligence is fluid. MMs are lightweight, rapidly trainable, and deployable (MaaS).
  • The Anti-Monolith: Unlike traditional LLMs, LIM routes intent to the exact source of truth or specialist model.
  • LIM > MCP: While MCP standardizes connections, LIM resolves the execution problem by autonomously routing queries.

Core Architecture (The L-I-M Trinity)

L - Large Integration Model (The Conductor)

  • Role: Intent Understanding & Routing.
  • Function: The "Generalist" that parses queries and directs them into the network.

I - Integration Network (The Nervous System)

  • Role: Discovery, Transport, & Protocol.
  • Function: The infrastructure layer connecting the Conductor to the Specialists.

M - Micro Model (The Specialist) / MMS

  • Role: Domain-Specific Execution.
  • Philosophy: Minimize context, rapid training, and hot-swappable.

CLI Commands

The CLI exposes two entry points: mm (Micro Model lifecycle) and lim (LIM node). The mm commands are also mounted under lim, so the canonical launch_command lim mm run works as well as the shorter mm run.

Project Management

mm start <name>            # Create a new micro model project from template
mm validate [-H URL]       # Validate res.json (schema + URL policy); with -H, live-check the service
mm build                   # Containerize the current MM (docker compose build)
mm run                     # Execute the project locally (python run/start.py -> docker compose up -d)
mm stop                    # Stop the containers started by `mm run` (docker compose down)

Registry Operations

mm push                    # Publish the MM to the LIM(s) in integration.lim
mm distribute [-t URL]     # Register the MM with a local LIM node (default: http://localhost:8000)
mm pull <mm1,mm2>          # Git-clone MMs into limmm/mm/ (names via integration.mm, or git URLs)
mm list [name]             # List MMs under limmm/mm/ (or show one MM's metadata)

LIM node

lim validate               # Validate this LIM node's res.json
lim push                   # Start the LIM and verify its /res.json matches res.json
lim mm <command>           # Same Micro Model commands, namespaced under lim

Local distribution: mm distribute reuses the push contract but targets a single local LIM instead of the cloud LIM(s) listed in integration.lim. The target resolves from --target/-t, then $LIM_LOCAL_URL, then http://localhost:8000. Use it to register a model on the local network with no cloud dependency.

Git-based pull: mm pull clones each MM into limmm/mm/<repo> ("take your AI experts home"). A plain name is resolved through this LIM's res.json (integration.mm[] → the MM's live /res.jsonrepository.url, honoring branch and a pinned commit); a git URL is cloned directly. If the target directory already exists as a git repo, it is fast-forwarded instead.

Micro Model Service (MMS) Standard

All MMs must adhere to the Open Source MMS Standard for interoperability:

Structure

  • res.json: The contract. Defines input/output schemas and configuration.
  • mms/: Service logic (API, Agents, RAG).
  • models/: Model artifacts (weights, embeddings).
  • data/: Specialized datasets or knowledge base.
  • run/: Execution scripts & Docker config.
my-model/
├── res.json                # Model contract and metadata
├── mms/                    # Service implementation (the Quart app)
│   ├── app/                # Application logic (blueprints, routes)
│   ├── tests/              # Tests
│   ├── .env                # 12-Factor runtime config
│   └── requirements.txt    # Service dependencies
├── models/                 # AI Model artifacts
├── data/                   # Domain-specific data
├── run/
│   ├── server.py           # ASGI entrypoint (uvicorn run.server:app)
│   ├── start.py            # Launcher (docker compose up --build)
│   └── docker/             # Dockerfile, docker-compose.yml, entrypoint.sh
└── README.md               # Documentation

The scaffold produced by mm start is immediately runnable: mm run boots the service with uvicorn run.server:app inside Docker (HTTP in dev mode so a local LIM can reach it over the http:// base_url in res.json).

Protocol

  • Discovery: Must expose <host>:8000/res.json (served by the app).
  • Git-Based: MMs are versioned and distributed via Git repositories.

Getting Started

  1. Install the CLI:

    pip install lim-mm-cli
    
  2. Create a new model:

    mm start my-model
    cd my-model
    
  3. Configure & Validate: Edit res.json and run:

    mm validate
    mm run
    
  4. Deploy:

    mm build
    mm push
    

Technology Stack

  • Backend: Python, Quart (Async)
  • Infra: Docker, PostgreSQL
  • Ops: Loki, Grafana
  • Interface: CLI, REST API

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lim_mm_cli-0.3.0.tar.gz (21.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lim_mm_cli-0.3.0-py3-none-any.whl (24.4 kB view details)

Uploaded Python 3

File details

Details for the file lim_mm_cli-0.3.0.tar.gz.

File metadata

  • Download URL: lim_mm_cli-0.3.0.tar.gz
  • Upload date:
  • Size: 21.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.10

File hashes

Hashes for lim_mm_cli-0.3.0.tar.gz
Algorithm Hash digest
SHA256 deca262a8c551d4b29f5c822e0aea4d15cce04f2d6baeae89aa3e19076807804
MD5 2ecab34191f21a1da90d3db08096954a
BLAKE2b-256 b424e9ad01403b1ecf755096e570de109b89040cbbd02a77b61a770d74f0607d

See more details on using hashes here.

File details

Details for the file lim_mm_cli-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: lim_mm_cli-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 24.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.10

File hashes

Hashes for lim_mm_cli-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4cd145d3ab8ed8557aeb6f381e777b66f96d2b1639b07806ba85fb21278ade25
MD5 d289dd31286b8944f95d4fef2b52fa7c
BLAKE2b-256 18934f74ce506fc8f3196424d0dcf5dc65b215dd9343990fe63772bfdc1d08fe

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page