> **平台**: 万维易源 (ShowAPI)
> **接入方式**: 统一 API 网关 (HTTPS POST/GET)
> **认证**: showapi_appid + showapi_sign
> **文档**: https://www.showapi.com/apiGateway/view/2568/33

---
title: "公式识别 - 百度云-文字识别|万维易源ShowAPI"
canonical_url: "https://www.showapi.com/apiGateway/view/2568/33"
last_updated: "2026-09-16T03:37:49.856Z"
meta:
  description: "支持对试卷中的数学公式及题目内容进行识别，可提取公式部分进行单独识别，也可对题目和公式进行混合识别，并返回Latex格式公式内容及位置信息，便于进行后续处理。原接口订购地址：https://cloud.baidu.com/product/ocr_education"
  keywords: "大厂接口,api接口,api接口大全,免费api,免费数据接口,数据接口,api开放平台,万维易源,showapi,大模型,AI Skills"
  "og:description": "支持对试卷中的数学公式及题目内容进行识别，可提取公式部分进行单独识别，也可对题目和公式进行混合识别，并返回Latex格式公式内容及位置信息，便于进行后续处理。原接口订购地址：https://cloud.baidu.com/product/ocr_education"
  "og:title": "API 市场|万维易源ShowAPI"
---

*

*

*

# **百度云-文字识别**

**连接器**

需两次购买：①订购原厂商接口 ②免费接口，注册后直接调用；覆盖多种通用场景、多种语言的高精度整图文字检测和识别服务，包括各类印刷和手写文档、网络图片、表格、数字、二维码等；可用于纸质文档电子化、办公文档/报表识别、图像内容审核、快递面单识别等场景。

[大厂接口](https://www.showapi.com/market?search=%E5%A4%A7%E5%8E%82%E6%8E%A5%E5%8F%A3)

**免费****本接口注册后默认可免费调用，为防止滥用设有使用档次限制。**

[**了解积分与档位详情 › **](https://www.showapi.com/free-api)

权益档次可使用平台积分兑换更高调用档位，多种积分获取方式请查看积分与档位详情。

在线调试

**连接器服务**

免费接口，注册后直接调用

<dl>

<dt>原厂商</dt>
<dd>[百度智能云](https://cloud.baidu.com/)</dd>

<dt>转发服务商</dt>
<dd>昆明秀派科技有限公司</dd>

<dt>电话</dt>
<dd>400-998-8033</dd>

<dt>QQ</dt>
<dd>4009988033</dd>

<dt>邮箱</dt>
<dd>[service@showapi.com](mailto:service@showapi.com)</dd>

</dl>

<dl>

<dt>所属分类</dt>
<dd>IT技术</dd>

<dt>接入点</dt>
<dd>33 个</dd>

<dt>请求方式</dt>
<dd>POST</dd>

<dt>返回格式</dt>
<dd>JSON</dd>

</dl>

**公式识别**

接入点说明

```
支持对试卷中的数学公式及题目内容进行识别，可提取公式部分进行单独识别，也可对题目和公式进行混合识别，并返回Latex格式公式内容及位置信息，便于进行后续处理。原接口订购地址：https://cloud.baidu.com/product/ocr_education
```

接口地址

https://connector.showapi.com/2568-33?appKey={your\_appKey} [查看密钥](https://www.showapi.com/console#/myApp) [调用帮助](https://www.showapi.com/helpcenter/view#/3960/1)

返回格式JSON

请求方式POST

**案例截图**

![案例](https://oss.showapi.com/api/2568/pn/33/prod/caseImgs/43aa7d995685473996af470d75835cc1.jpg?t=1690438410848)

**请求参数**

**Header 参数**

| |
|

| |
|

**Post 表单**

| |
|

| |
|
| |
| |
| |
| |
| |

**返回参数**查看公共返回参数

该接口返回经 `showapi_res_body` 系统封装，业务数据均位于该对象内；系统级字段见公共返回参数。

**返回体**

| |
|

| |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |

**请求示例**

[查看我的 appKey](https://www.showapi.com/console#/myApp) [查看使用向导](https://www.showapi.com/helpcenter/view#/3960/1) [Python / Java 等多语言示例](https://www.showapi.com/apitest/market/2568/33)

cURL 复制

```
curl -X POST "https://connector.showapi.com/2568-33?appKey=YOUR_APPKEY" \
  -H "content-type: application/x-www-form-urlencoded" \
  -d "ds_id=&image=&url=https%3A%2F%2Fshowapi.oss-cn-hangzhou.aliyuncs.com%2Fmodleapi%2Flzh%2Fformula.jpg&detect_direction=&recognize_granularity=&disp_formula=true"
```

**返回示例**

JSON 复制

```
{
  "showapi_res_error": "",
  "showapi_res_code": 0,
  "showapi_res_id": "6030b7728d57bad81fbd730d",
  "showapi_res_body": {
    "ret_code": 0,
    "formula_result": [
      {
        "words": "\\left( a + b \\right) \\left( a - b \\right) = a ^ { 2 } - b ^ { 2 }  ",
        "location": {
          "height": 72,
          "width": 404,
          "left": 49,
          "top": 37
        }
      },
      {
        "words": "\\left( a \\pm b \\right) ^ { 2 } = a ^ { 2 } \\pm 2 a b + b ^ { 2 }  ",
        "location": {
          "height": 74,
          "width": 384,
          "left": 48,
          "top": 166
        }
      },
      {
        "words": "\\left( a + b \\right) \\left( a ^ { 2 } - a b + b ^ { 2 } \\right) = a ^ { 3 } + b ^ { 3 }  ",
        "location": {
          "height": 76,
          "width": 535,
          "left": 50,
          "top": 296
        }
      },
      {
        "words": "\\left( a - b \\right) \\left( a ^ { 2 } + a b + b ^ { 2 } \\right) = a ^ { 3 } - b ^ { 3 }  ",
        "location": {
          "height": 75,
          "width": 532,
          "left": 51,
          "top": 427
        }
      },
      {
        "words": "a ^ { 2 } + b ^ { 2 } =  ",
        "location": {
          "height": 67,
          "width": 172,
          "left": 626,
          "top": 428
        }
      },
      {
        "words": "\\left( a + b \\right) ^ { 2 } - 2 a b  ",
        "location": {
          "height": 71,
          "width": 246,
          "left": 7,
          "top": 518
        }
      },
      {
        "words": "\\left( a - b \\right) ^ { 2 } = \\left( a + b \\right) ^ { 2 } - 4 a b  ",
        "location": {
          "height": 74,
          "width": 427,
          "left": 297,
          "top": 516
        }
      }
    ],
    "formula_result_num": 7,
    "words_result": [
      {
        "words": "① \\left( a + b \\right) \\left( a - b \\right) = a ^ { 2 } - b ^ { 2 }  ;",
        "location": {
          "height": 62,
          "width": 478,
          "left": 0,
          "top": 43
        }
      },
      {
        "words": "② \\left( a \\pm b \\right) ^ { 2 } = a ^ { 2 } \\pm 2 a b + b ^ { 2 }  ;",
        "location": {
          "height": 63,
          "width": 455,
          "left": 0,
          "top": 172
        }
      },
      {
        "words": "③ \\left( a + b \\right) \\left( a ^ { 2 } - a b + b ^ { 2 } \\right) = a ^ { 3 } + b ^ { 3 }  ;",
        "location": {
          "height": 68,
          "width": 612,
          "left": 0,
          "top": 300
        }
      },
      {
        "words": "④ \\left( a - b \\right) \\left( a ^ { 2 } + a b + b ^ { 2 } \\right) = a ^ { 3 } - b ^ { 3 }  ; a ^ { 2 } + b ^ { 2 } = ",
        "location": {
          "height": 73,
          "width": 798,
          "left": 0,
          "top": 427
        }
      },
      {
        "words": "\\left( a + b \\right) ^ { 2 } - 2 a b  ; \\left( a - b \\right) ^ { 2 } = \\left( a + b \\right) ^ { 2 } - 4 a b ",
        "location": {
          "height": 62,
          "width": 717,
          "left": 7,
          "top": 523
        }
      }
    ],
    "words_result_num": 5,
    "log_id": 587011153140088400
  }
}
```

**MCP 服务集成**接口级

在 Cherry Studio、ChatBox 等支持 MCP 的客户端中配置，将 {your\_appKey} 替换为真实 AppKey（ [AppKey 管理](https://www.showapi.com/console#/myApp)）。该服务覆盖本接口全部接入点。

MCP JSON 复制

```
{
  "mcpServers": {
    "showapi-mcp-2568": {
      "url": "http://www.showapi.com.cn/mcp/2568/{your_appKey}"
    }
  }
}
```

**OpenAPI 文档**接口级

标准 OpenAPI 3.0 文档，覆盖本接口全部接入点，可导入 Apifox / Postman / Swagger UI，或供 AI Agent 直接消费。

[在线查看 YAML](https://www.showapi.com/openapi/market/2568.yaml) [下载 YAML](https://www.showapi.com/openapi/market/2568.yaml) [查看 JSON](https://www.showapi.com/openapi/market/2568.json)