AI Agent Hub
Back to skills
iFlytek Invoice OCR Recognition icon

iFlytek Invoice OCR Recognition

Office Efficiency Updated 2026.08.30

Paste the following prompt into your AI chat to install this skill:

Please follow https://skillhub.cn/install/skillhub.md to install @user_265fda35/test1-v2-new.

About this skill

The Problem

Manually transcribing amounts, dates, and vendor names from paper or scanned invoices—VAT invoices, taxi receipts, train tickets, medical bills—gets slow and error-prone once volume grows past a handful of documents per day. Maintaining an expense ledger by hand stops being viable. This skill collapses the "snap a photo → get structured data" step into a single API call.

How It Works

  • Stdlib only: the script scripts/invoice.py relies solely on the Python 3 standard library—no pip install required.
  • Auth handled for you: set XFYUN_APP_ID, XFYUN_API_KEY, and XFYUN_API_SECRET as environment variables. The script computes the HMAC-SHA256 signature and calls the iFlytek endpoint internally, so you never write signing logic by hand.
  • Broad format support: png, jpg/jpeg, bmp, gif, tif/tiff, and pdf are all accepted; scanned documents can be passed as PDF directly.
  • Two output modes: by default the output is human-readable structured fields (amount, date, vendor, etc.). Pass --raw to get the full API JSON response for downstream parsing or database ingestion.
  • Traceable errors: code 0 means success; codes like 10105 (invalid signature), 10163 (request body too large), and 11200 (quota exceeded) are documented, making it straightforward to debug.

Boundaries & Caveats

  • Recognition accuracy is heavily dependent on image quality—blur, occlusion, or poor lighting will degrade field extraction. Shoot clearly and crop to the invoice area when possible.
  • The API enforces image-size and call-quota limits that vary by your iFlytek service tier; verify your quota before batch runs.
  • The skill targets Chinese invoice and receipt types (VAT invoices, taxi receipts, train tickets, medical bills); English or non-Chinese invoices are not listed in the supported scope.

Use Cases

  • Finance receives taxi receipt or train ticket photos and needs amounts, dates, and vendors for a reimbursement ledger.
  • Operations staff convert multiple receipt photos into structured fields after business trips to avoid manual form entry.
  • Administrative staff convert scanned PDF medical bills into readable fields for archiving and reconciliation.
  • Developers call the recognition script in an automation flow to get formatted text or `--raw` JSON output.

Best For

  • Finance or expense accounting staff who want amounts, dates, and vendors from Chinese receipts turned into bookkeeping-ready fields.
  • Operations or administrative staff who need to organize trip receipts into reimbursement data without manual transcription.
  • Automation engineers who want to integrate the recognition script and consume `--raw` JSON output downstream.
  • Administrative or audit assistants who need scanned bills converted into structured text for review and archiving.