Downloads · 30 days
567
8% of all-time downloads
Reza2kn/Bina-0.1-Koochik
Bina-0.1-Koochik is a image-text-to-text model from Reza2kn. Use it for the image-text-to-text task on the model card, and read the license before you ship it in a product. It is set up for transformers. The card lists the license as openrail.
The merged BF16 release of the Persian OCR LoRA checkpoint at step 8,000 from Reza2kn/surya-ocr-2-persian-lora-7m, based on datalab-to/surya-ocr-2.
Downloads · 30 days
567
8% of all-time downloads
All-time downloads
7K
Public
Parameters
666M
1.3 GB on disk
Likes
32
Public
Click a slice to open those files.
.safetensors1.3 GB · 100%
From the Hugging Face model README
The merged BF16 release of the Persian OCR LoRA checkpoint at step 8,000 from
Reza2kn/surya-ocr-2-persian-lora-7m,
based on datalab-to/surya-ocr-2.
This repository is the immutable BF16 transcription baseline for Bina 0.1 Koochik. Quantized/runtime-specific derivatives should be compared against this model before being described as parity-preserving.
Bina 0.1 Koochik is compatible with the Surya OCR 2 inference package. The easiest supported setup is Linux (or WSL2) with an NVIDIA GPU.
Then install or upgrade Surya:
python -m pip install -U "surya-ocr>=0.20.0"
Replace document.pdf with an image, a PDF, or a folder containing images/PDFs:
export SURYA_MODEL_CHECKPOINT=Reza2kn/Bina-0.1-Koochik
export SURYA_INFERENCE_BACKEND=vllm
surya_ocr ./document.pdf --output_dir ./bina-output
On the first run, Surya downloads the model and starts a vLLM server in Docker,
so startup can take a few minutes. For the example above, the OCR result is
written to ./bina-output/document/results.json. Each page contains ordered
blocks with recognized HTML/text, labels, confidence scores, and bounding boxes.
Useful options:
# Process only pages 0 through 2
surya_ocr ./document.pdf --page_range 0-2 --output_dir ./bina-output
# Also save annotated page images
surya_ocr ./document.pdf --images --output_dir ./bina-output
Set the environment variables before importing surya:
import os
os.environ["SURYA_MODEL_CHECKPOINT"] = "Reza2kn/Bina-0.1-Koochik"
os.environ["SURYA_INFERENCE_BACKEND"] = "vllm"
from PIL import Image
from surya.inference import SuryaInferenceManager
from surya.recognition import RecognitionPredictor
image = Image.open("page.jpg").convert("RGB")
manager = SuryaInferenceManager()
predictor = RecognitionPredictor(manager)
result = predictor([image])[0]
for block in result.blocks:
print(block.html)
CPU and Apple Silicon: this repository contains BF16 weights, not a GGUF build. The automatic
llama.cpppath therefore cannot run Bina 0.1 Koochik directly; use the NVIDIA/vLLM setup above or a Bina-specific GGUF conversion.
بینا ۰.۱ کوچک با بستهٔ استنتاج Surya OCR 2 سازگار است. سادهترین روش پشتیبانیشده، استفاده از لینوکس (یا WSL2) و کارت گرافیک NVIDIA است.
سپس Surya را نصب یا بهروز کنید:
python -m pip install -U "surya-ocr>=0.20.0"
بهجای document.pdf میتوانید مسیر یک تصویر، فایل PDF یا پوشهای از
تصاویر/PDFها را قرار دهید:
export SURYA_MODEL_CHECKPOINT=Reza2kn/Bina-0.1-Koochik
export SURYA_INFERENCE_BACKEND=vllm
surya_ocr ./document.pdf --output_dir ./bina-output
در اجرای اول، Surya مدل را دانلود و سرور vLLM را در Docker راهاندازی میکند؛
بنابراین شروع کار ممکن است چند دقیقه طول بکشد. در مثال بالا، نتیجه در مسیر
./bina-output/document/results.json ذخیره میشود. خروجی هر صفحه شامل بلوکهای
مرتبشده، متن/HTML تشخیصدادهشده، نوع بلوک، میزان اطمینان و مختصات کادرها است.
چند گزینهٔ کاربردی:
# فقط پردازش صفحههای ۰ تا ۲
surya_ocr ./document.pdf --page_range 0-2 --output_dir ./bina-output
# ذخیرهٔ تصویر صفحهها همراه با کادرهای تشخیصدادهشده
surya_ocr ./document.pdf --images --output_dir ./bina-output
متغیرهای محیطی را پیش از import کردن surya تنظیم کنید:
import os
os.environ["SURYA_MODEL_CHECKPOINT"] = "Reza2kn/Bina-0.1-Koochik"
os.environ["SURYA_INFERENCE_BACKEND"] = "vllm"
from PIL import Image
from surya.inference import SuryaInferenceManager
from surya.recognition import RecognitionPredictor
image = Image.open("page.jpg").convert("RGB")
manager = SuryaInferenceManager()
predictor = RecognitionPredictor(manager)
result = predictor([image])[0]
for block in result.blocks:
print(block.html)
CPU و Apple Silicon: این مخزن شامل وزنهای BF16 است و فایل GGUF ندارد؛ بنابراین مسیر خودکار
llama.cppنمیتواند بینا ۰.۱ کوچک را مستقیماً اجرا کند. از روش NVIDIA/vLLM بالا یا یک تبدیل GGUF مخصوص بینا استفاده کنید.
checkpoints/checkpoint-step-0008000/home/rezo/triple-threat/hf-cache/surya-step8000-mergedQwen3_5ForConditionalGenerationmodel.safetensors SHA-256: 2193be4ef3d2366438121a15b7a1dea2bb85b24f83145e5a39bfa1f387891adaconfig.json SHA-256: e0de22be177070f206106c184d062176fcda591d9114068c42489ffc550488dePersian document OCR. The model is currently served as بینا ۰.۱ کوچک on PersianVLM.com. Use deterministic decoding for baseline comparisons.
This release follows the upstream Surya OCR 2 OpenRAIL license. Review the upstream license before redistribution or deployment.