Mistral Codestral. Mistral本地推理. Mistral IA Local.

v1.0.1

Mistral and Codestral — run Mistral Large, Mistral-Nemo, Codestral, and Mistral-Small locally. Mistral AI's open-source LLMs for code generation and reasonin...

0· 18·0 current·0 all-time
byTwin Geeks@twinsgeeks
MIT-0
Download zip
LicenseMIT-0 · Free to use, modify, and redistribute. No attribution required.
Security Scan
VirusTotalVirusTotal
Benign
View report →
OpenClawOpenClaw
Benign
medium confidence
Purpose & Capability
Name/description (local Mistral/Codestral inference) aligns with what the skill asks for: local HTTP endpoints, optional python/pip, and local fleet config files (~/.fleet-manager). Required binaries (curl or wget) and optional python3/pip are reasonable for the described tasks.
Instruction Scope
SKILL.md stays within the Mistral/local-inference scope: it instructs installing 'ollama-herd', starting 'herd' and 'herd-node', and calling a local API at http://localhost:11435. It references local config files and explicitly says model downloads require user confirmation. Note: the instructions tell the agent to run pip install and start persistent services, which will write files and spawn processes on the host — this is expected for the purpose but is an elevated action compared to read-only guidance.
Install Mechanism
There is no registry install spec (skill is instruction-only). The SKILL.md tells users/agents to run 'pip install ollama-herd', which will fetch and execute third-party code. That is expected for an instruction that sets up a local fleet router, but lack of an explicit, auditable install source in the registry means the agent/user should verify the package source (PyPI or GitHub) before running it.
Credentials
The skill declares no required environment variables or credentials and uses a local base_url with api_key set to 'not-needed'. The only declared config paths (~/.fleet-manager/...) are clearly related to a fleet manager and are proportionate to the skill's functionality.
Persistence & Privilege
The skill does not request always:true and does not alter other skills. However, it instructs starting persistent services (herd, herd-node) that will run in the background and may open local ports — this increases runtime privilege and blast radius compared to a purely stateless skill, so run with caution (e.g., verify service binding, firewall, and run as non-root).
Assessment
This skill is coherent with its stated goal (running Mistral/Codestral locally) but it instructs installing and running third-party software. Before installing or letting an agent execute these commands: 1) Inspect the 'ollama-herd' package source (PyPI/GitHub) and recent commits/maintainers; 2) Prefer to manually run 'pip install' yourself in a sandbox or VM so you can review what's installed; 3) Verify the service binds only to localhost and check open ports (11435) and firewall rules; 4) Do not run installs as root; 5) Confirm any model downloads are manual and explicit (they may be very large); 6) Inspect files under ~/.fleet-manager if present, and avoid allowing the agent to delete or modify unrelated files. If you need higher assurance, run the stack in an isolated VM or container and review the project's repository and package metadata before running the commands.

Like a lobster shell, security has layers — review code before you run it.

apple-siliconvk97521w8en3fz3vzba3a2gbfx1840efzcode-generationvk97521w8en3fz3vzba3a2gbfx1840efzcodestralvk97521w8en3fz3vzba3a2gbfx1840efzfleet-routingvk97521w8en3fz3vzba3a2gbfx1840efzlatestvk97521w8en3fz3vzba3a2gbfx1840efzlocal-llmvk97521w8en3fz3vzba3a2gbfx1840efzmistralvk97521w8en3fz3vzba3a2gbfx1840efzmistral-aivk97521w8en3fz3vzba3a2gbfx1840efzmistral-largevk97521w8en3fz3vzba3a2gbfx1840efzmistral-nemovk97521w8en3fz3vzba3a2gbfx1840efzmultilingualvk97521w8en3fz3vzba3a2gbfx1840efzollamavk97521w8en3fz3vzba3a2gbfx1840efz

License

MIT-0
Free to use, modify, and redistribute. No attribution required.

Runtime requirements

sparkles Clawdis
OSmacOS · Linux
Any bincurl, wget

SKILL.md

Mistral & Codestral — Mistral AI Models on Your Local Fleet

Mistral AI's open-source models run locally on your hardware. Mistral Large for frontier reasoning, Mistral-Nemo for efficiency, Codestral for code generation. The fleet router picks the best device for every Mistral request.

Supported Mistral models

Mistral ModelParametersOllama nameBest for
Codestral (by Mistral)22BcodestralMistral's code specialist — 80+ languages
Mistral Large123Bmistral-largeMistral's frontier reasoning, multilingual
Mistral-Nemo12Bmistral-nemoMistral's efficient general-purpose model
Mistral-Small22Bmistral-smallMistral's fast reasoning model
Mistral 7B7Bmistral:7bMistral's lightweight model

Setup Mistral locally

pip install ollama-herd    # install Mistral fleet router
herd                       # start the Mistral-compatible router
herd-node                  # run on each device — Mistral requests route automatically

No Mistral models downloaded during installation. All Mistral model pulls are user-initiated.

Codestral code generation

Codestral is Mistral AI's dedicated coding model — trained on 80+ programming languages with fill-in-the-middle support.

from openai import OpenAI

# Connect to local Mistral fleet
mistral_fleet = OpenAI(base_url="http://localhost:11435/v1", api_key="not-needed")

# Codestral by Mistral for code generation
codestral_response = mistral_fleet.chat.completions.create(
    model="codestral",  # Mistral's Codestral model
    messages=[{"role": "user", "content": "Write a Redis-backed rate limiter in Go"}],
)
print(codestral_response.choices[0].message.content)

Codestral via curl

# Codestral code generation on local Mistral fleet
curl http://localhost:11435/v1/chat/completions \
  -H "Content-Type: application/json" \
  -d '{"model": "codestral", "messages": [{"role": "user", "content": "Implement a B-tree in Rust — Mistral Codestral excels at systems programming"}]}'

Mistral Large reasoning

# Mistral Large for complex reasoning
curl http://localhost:11435/api/chat -d '{
  "model": "mistral-large",
  "messages": [{"role": "user", "content": "Compare Mistral vs GPT-4 for enterprise deployments"}],
  "stream": false
}'

Mistral-Nemo for efficiency

# Mistral-Nemo — best quality/size ratio from Mistral AI
curl http://localhost:11435/api/chat -d '{
  "model": "mistral-nemo",
  "messages": [{"role": "user", "content": "Summarize this Mistral AI technical paper"}],
  "stream": false
}'

Mistral hardware recommendations

Mistral ModelMin RAMRecommended for Mistral
mistral:7b8GBAny Mac — lightweight Mistral
mistral-nemo10GBMac Mini (16GB) — efficient Mistral
codestral16GBMac Mini (24GB) — Mistral's code model
mistral-small16GBMac Mini (24GB) — fast Mistral
mistral-large80GBMac Studio (128GB) — Mistral's best

Monitor Mistral fleet

# See which Mistral models are loaded
curl -s http://localhost:11435/api/ps | python3 -m json.tool

# Mistral fleet overview
curl -s http://localhost:11435/fleet/status | python3 -m json.tool

# Mistral model performance stats
curl -s http://localhost:11435/dashboard/api/models | python3 -m json.tool

Example Mistral fleet response:

{
  "node_id": "Mistral-Server",
  "models_loaded": ["codestral:22b", "mistral-nemo:12b"],
  "mistral_inference": "active"
}

Mistral dashboard at http://localhost:11435/dashboard.

Also available alongside Mistral

Other LLMs (same Mistral-compatible endpoint)

Llama 3.3, Qwen 3.5, DeepSeek-V3, Phi 4, Gemma 3 — route alongside Mistral models.

Image generation

curl http://localhost:11435/api/generate-image \
  -d '{"model": "z-image-turbo", "prompt": "Mistral AI logo reimagined as abstract art", "width": 512, "height": 512}'

Speech-to-text

curl http://localhost:11435/api/transcribe -F "file=@mistral_meeting.wav" -F "model=qwen3-asr"

Embeddings

curl http://localhost:11435/api/embed \
  -d '{"model": "nomic-embed-text", "input": "Mistral AI open source language models Codestral"}'

Full documentation

Contribute

Ollama Herd is open source (MIT). Run Mistral locally, contribute globally:

  • Star on GitHub — help Mistral users find local inference
  • Open an issue — share your Mistral setup
  • PRs welcomeCLAUDE.md gives AI agents full context. 412 tests.

Guardrails

  • Mistral model downloads require explicit user confirmation — Mistral models range from 4GB to 70GB+.
  • Mistral model deletion requires explicit user confirmation.
  • Never delete or modify files in ~/.fleet-manager/.
  • No Mistral models downloaded automatically — all pulls are user-initiated.

Files

1 total
Select a file
Select a file to preview.

Comments

Loading comments…