mistral_common
Mistral-common is a library of common utilities for Mistral AI.
Decision gist · record as of 2026-08-14
Yes. mistral-common is actively maintained, has no known vulnerabilities, and low install friction. Install it if you are building applications with Mistral models and need local tokenization, validation, or want to ensure token counts match what the API will see. The permissive Apache 2.0 license poses no restrictions. Skip it only if you are not using Mistral models or do not need pre-flight validation.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later (supports up to 3.14); optional extras (image, audio, hf-hub, sentencepiece, server) available for extended functionality.
- Low install friction with a pure-wheel distribution and eight common dependencies (pydantic, requests, numpy, pillow, tiktoken, jsonschema, typing-extensions, pydantic-extra-types).
- Actively maintained with a release 22 days ago.
License · maintenance · safety
Apache-2.0 (permissive) — Licensed under Apache 2.0 (permissive), allowing commercial use and modification with attribution. No notable restrictions for typical integration into applications.
last release 2026-07-23 (22 days)
0 known vulnerabilities (OSV.dev, 2026-08-14) · 8,944,595 downloads/mo, #1,573 on PyPI
Alternatives
Verify before relying
pip install mistral-common
from mistral_common.tokens.tiktoken import get_encoding
encoding = get_encoding("v3")
tokens = encoding.encode("Hello, world!")- Whether the tokenizers are compatible with all current Mistral model versions or only specific releases.
- Performance characteristics (tokenization speed, memory overhead) compared to direct model APIs.
- Whether validation and normalization code is used by the official Mistral Python client or is independent.
What it is and what it does
mistral-common is a utility library that exposes Mistral AI's internal tokenization, validation, and normalization code for public use. It handles tokenization of text, images, and tool calls, plus request/response validation built on Pydantic. The library is versioned to guarantee backward compatibility with released models.
The package is designed for two audiences: developers integrating Mistral models into applications, and those building custom models who want to use Mistral's tokenization and validation approach. It ships with eight runtime dependencies (pydantic, requests, numpy, pillow, tiktoken, jsonschema, typing-extensions, pydantic-extra-types) and supports optional extras for image, audio, Hugging Face Hub integration, and experimental server mode.
Use it for
- Tokenize text and images before sending to Mistral models to verify token counts and optimize prompt engineering.
- Validate and normalize API requests and tool calls to match Mistral's expected format before calling the model.
- Build custom LLM applications that need consistent tokenization behavior across multiple model versions.
- Integrate Mistral model support into frameworks that require standardized token counting and validation.
- Develop local preprocessing pipelines that mirror Mistral's server-side validation without API calls.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
mistral-common is actively maintained, has no known vulnerabilities, and low install friction. Install it if you are building applications with Mistral models and need local tokenization, validation, or want to ensure token counts match what the API will see. The permissive Apache 2.0 license poses no restrictions. Skip it only if you are not using Mistral models or do not need pre-flight validation.
Install
mistral-common on PyPI
Before you install
Low install friction with a pure-wheel distribution and eight common dependencies (pydantic, requests, numpy, pillow, tiktoken, jsonschema, typing-extensions, pydantic-extra-types). Actively maintained with a release 22 days ago.
Requires Python 3.10 or later (supports up to 3.14); optional extras (image, audio, hf-hub, sentencepiece, server) available for extended functionality.
License in practice
Licensed under Apache 2.0 (permissive), allowing commercial use and modification with attribution. No notable restrictions for typical integration into applications.
Quickstart
pip install mistral-common
from mistral_common.tokens.tiktoken import get_encoding
encoding = get_encoding("v3")
tokens = encoding.encode("Hello, world!")
Verify before relying
- Whether the tokenizers are compatible with all current Mistral model versions or only specific releases.
- Performance characteristics (tokenization speed, memory overhead) compared to direct model APIs.
- Whether validation and normalization code is used by the official Mistral Python client or is independent.
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release <3.15,>=3.10.0 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 8 packagespydanticjsonschematyping-extensionstiktokenpillowrequestsnumpypydantic-extra-types |
| Maintenance | Actively maintained 22 days since the last release |
| First released | |
| Downloads | 8,944,595 / month, #1,573 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
Evidence: mistral_common-1.11.7-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “mistral ai tokenizer”
- mistral_commonProvides tokenizers, validation, and normalization utilities for…
- pytorch-tokenizersProvides C++ implementations of multiple tokenizers (SentencePiece,…
- langchain-mistralaiConnects Mistral AI language models to LangChain, enabling you to use…
Give your agent the search over MCP, or paste the wish link into any chat.
More Artificial Intelligence packages
LiteLLM provides a unified Python interface to call 100+ LLM providers (OpenAI, Anthropic, Gemini, Bedrock, Azure, and others) using OpenAI-compatible API format, available as both a Python SDK and a self-hosted AI Gateway proxy server.
Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization.
Client library and CLI tool for downloading, uploading, and managing models, datasets, and repositories on the Hugging Face Hub platform.
Install it if you work with Hugging Face Hub models or datasets.
LangChain provides a framework for building agents and LLM-powered applications by composing language models, tools, and memory through a unified API that abstracts over multiple model providers.
hf-xet provides chunk-based deduplication and efficient file transfer for the Hugging Face Hub, enabling faster uploads and downloads of large files with local disk caching.
Tokenizers converts raw text into token sequences for NLP models, with support for training custom vocabularies and using pre-built tokenizers (BPE, WordPiece) optimized for speed via Rust.
Transformers provides a unified framework for loading, fine-tuning, and running state-of-the-art pretrained models across text, vision, audio, video, and multimodal tasks using PyTorch, JAX, or TensorFlow.
Install it if you need to run or train any transformer-based model for NLP, vision, audio, or multimodal tasks.
See also pytorch-tokenizers · langchain-mistralai · mistralai · mistralai-workflows · mistral-vibe · lm-eval · openvino-tokenizers · opentelemetry-instrumentation-mistralai