mohdel weekly downloads statistics
Self-hosted LLM gateway and SDK for Node — a LiteLLM-style unified API for 15 providers (Anthropic, OpenAI, Gemini, Mistral, Groq, xAI, DeepSeek, OpenRouter, …) with per-call USD cost tracking, streaming, tool calls, vision, speech-to-text, and built-in O
mohdel has 1,247 recorded weekly downloads on npm, a decrease of 13.1% over the past 30 days, ranking #1408 of 2,322 tracked listings.
About mohdel
Mohdel
Self-hosted LLM gateway and SDK for Node — think LiteLLM, for the JS world. One answer() call for 15 providers or local inference; swap models by changing one string; get real per-call USD cost back on every result, with OpenTelemetry built in and process isolation when you need it. Your keys, your infra, no SaaS proxy in the path.
npm install -g mohdel
mo # pick a provider, paste your key, pull its models
mo model instructions openai > mohdel-brief.md # prices live on a docs page — hand it to your agent
mo ask openai/gpt-5.6-luna "why is the sky blue"
Almost no provider API returns prices, context limits or thinking budgets.
They live on a docs page, so mohdel writes a brief and the coding agent you
already run reads the page and drafts the entries. mo offers this at the end
of setup. Nothing runs on your key but that agent.
No coding agent? OpenRouter and Novita publish per-token prices in their
own model lists, so mohdel reads them directly. mo curate openrouter or mo curate novita writes complete, priced entries on its own, and setup counts the
models that cost nothing and offers to add all of them in one keystroke. A
working catalog without a pricing page or a brief.
Providers: Anthropic, OpenAI, ChatGPT, Gemini, Mistral, Groq, xAI, Cerebras, Fireworks, DeepSeek, Qwen Cloud, Xiaomi, Meta Model API, OpenRouter, Novita. Node 22+, ES modules.
Using a ChatGPT subscription
mo chatgpt login # open the printed URL in your browser
mo chatgpt models # account-specific models, discovered from OpenAI
mo model curate chatgpt # choose models to add to the local catalog
mo ask chatgpt/<model-slug> "Hello"
chatgpt/ uses OAuth and an eligible ChatGPT plan. It always streams through
the public Responses API with store: false. openai/ continues using API
billing. Token counts are reported for both; ChatGPT's cost: 0 means no
per-call API charge is calculated, not unlimited or free plan usage. Manage
allowance and credits with mo chatgpt usage.
Use mo chatgpt list, select <account-id>, login --new, and
logout [account-id] to manage accounts. Credentials live in Mohdel's user
data directory (~/.local/share/mohdel/chatgpt/ on Linux), with owner-only
files and serialized token refresh. They are separate from the catalog.
mo chatgpt login <account-id> reuses a saved registration after sign-out
or a failed code exchange. ChatGPT lists each registration by name: a new one
is Mohdel (<hostname>), or the label from mo chatgpt login --name <label>
if you'd rather not send the hostname. The name is fixed when the registration
is made, and mo chatgpt list shows it next to the account id. If a crashed process leaves accounts.lock,
confirm its recorded PID has exited before removing that lock.
This OpenAI flow is intended for open-source and personal local tools; paid or remotely hosted offerings require OpenAI's private-app acceptance. See OpenAI's guide and library/gate integration.
Mohdel runs the inference layer of production stacks, among them docAnalyzer, a document analysis and chat platform serving hundreds of thousands of users.
Why mohdel
- Real numbers on every call. Token counts and per-call USD cost computed from your own pricing catalog (
curated.json) — not estimates, not provider-specific shapes. Bill tenants, alert on spend, reconcile invoices. Your own catalog means your negotiated rates and your own tags, and it is not a spreadsheet you maintain:mo model instructionshands the provider's docs page to your coding agent, which drafts the entries for you to review. See docs/CATALOG.md. - One interface across providers. Same
answer()call, same event stream, same{ status, output, inputTokens, outputTokens, cost }result. Switching fromanthropic/claude-sonnet-5-5toopenai/gpt-5.4-miniis one string change — adapter differences stay inside mohdel. - Self-hosted, no vendor in the path. API keys live in
~/.config/mohdel/. Mohdel calls provider APIs directly; nothing routes through a third party, nothing marks up your tokens, no extra hop of availability risk. - Inference without tool execution. Mohdel returns model output and tool calls for your harness to handle. Optional ChatGPT sign-in uses a temporary loopback listener and a protected local credential store. See Attack surface.
- Observability without instrumentation. OpenTelemetry spans, trace-linked logs, and OTLP metrics over one endpoint. Set
OTEL_EXPORTER_OTLP_ENDPOINT; everything else is wired. - Fully typed. Declarations are generated from the source's own JSDoc and ship with the package —
CallEnvelope,Event,AnswerResultandMohdelErrorare the frozen wire contract, typed as such. No@typespackage, no separate TypeScript build to keep in sync. - Two integration paths, same API. In-process factory for CLI tools, scripts, single-process services. Optional
thin-gatesubprocess for fault isolation, cross-process quota, and any-language HTTP callers — no code change to switch.
How it compares
LiteLLM is the closest analog but lives in Python. Vercel AI SDK is an application toolkit, not an infra layer. OpenRouter is the same one-API promise as a SaaS in your request path. Raw provider SDKs are N different shapes with no cost accounting.…
Description from the npm listing.
- llm
- llm-gateway
- ai-gateway
- ai-sdk
- openai
- anthropic
- claude
- gemini
- mistral
- groq
- deepseek
- openrouter
- streaming
- tool-calling
- token-cost
- rate-limiting
- opentelemetry
- self-hosted
- cli
README badge
Show your rank in a README or on your website. The badge updates automatically.
Charts
Images: 30d · 1y · all time · 1600×900 dark
Adoption over time
7/30/90-day growth
Ranking history
Listing placement
Listing placement
Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.
Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.
Recent observations
Full history (122)Similar npm AI SDKs plugins
All 20 mohdel alternativesData source
Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.
Listing: https://www.npmjs.com/package/mohdel. First seen Oct 16, 2026; last successful collection Oct 20, 2026. See the methodology.