Views
No views yet
mlx_vlm.convert. Architecture, training data, and intended use are described on the upstream model page; this repo only changes the storage format (PyTorch safetensors → MLX safetensors, same bf16 precision).pip install mlx-vlm1from mlx_vlm import load, generate
2from mlx_vlm.prompt_utils import apply_chat_template
3
4model, processor = load("mlx-community/CodeFormulaV2-mlx-bf16")
5prompt = apply_chat_template(processor, model.config, "<formula>", num_images=1)
6result = generate(
7 model, processor,
8 prompt=prompt,
9 image="path/to/image.png",
10 temperature=0.0,
11)
12print(result.text)"<formula>" as the prompt for a math-expression image, "<code>" for a code-block image, per the upstream model card.1@techreport{Docling,
2 author = {Deep Search Team},
3 month = {8},
4 title = {{Docling Technical Report}},
5 url = {https://arxiv.org/abs/2408.09869},
6 eprint = {2408.09869},
7 year = {2024}
8}