Skip to content

Commit

Permalink
add readme
Browse files Browse the repository at this point in the history
  • Loading branch information
oott123 committed Dec 5, 2017
1 parent d255171 commit 8a26356
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Alfred Clipboard OCR

一个对剪贴板中的图片内容调用百度云 API 做 OCR 识别的 Alfred 工作流。

![演示动画](./assets/demo.gif)

<center><small>感谢:V2EX, Firefox, Snipaste, CotEditor 在上图中的出场(排名不分先后)</small></center>

## 安装方法

1. 下载 workflow 并使用 Alfred 安装
2.[百度云控制台](https://console.bce.baidu.com/ai/#/ai/ocr/overview/index) 申请一个文字识别的应用,并记下 API Key 和 API Secret
3. 打开 Alfred 设置,找到这个 workflow 并打开变量控制面板
![变量控制面板的位置](./assets/open-variables-panel.jpg)
4. 将第二步中获得的 API Key 和 API Secret 填入对应的变量中
![添加变量的示意图](./assets/set-variables.jpg)

## 使用说明

首先,使用任意一个截图软件将想要识别的区域截取下来。你也可以复制图片内容(而非图片文件)到剪贴板中。

在 Alfred 中输入 `ocr` 并回车,稍等片刻,即可获得识别的文字。

识别后的文字会自动复制到你的剪贴板中。识别并复制成功后,Alfred 会弹出桌面通知提醒你。

## 授权协议

AGPLv3

### 开源软件使用许可

[pngpaste](./pngpaste/LICENSE)

Binary file added assets/demo.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/open-variables-panel.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/set-variables.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 8a26356

Please sign in to comment.