Code Monkey home page Code Monkey logo

dictionaries's Introduction

Rime 擴充詞庫

使用方法

  1. 下載詞庫 https://github.com/rime-aca/dictionaries.git (或是直接 clone / pull 這個 repo)

    注意到其中應該有六個檔案:

    double_pinyin.custom.yaml
    luna_pinyin.custom.yaml
    luna_pinyin.hanyu.dict.yaml
    luna_pinyin.cn_en.dict.yaml
    luna_pinyin.extended.dict.yaml
    luna_pinyin.poetry.dict.yaml*
    
  2. 將上述檔案中後面五個移至你的 Rime 目錄底下 (depends on your OS),以 OS X 來說,就是在 ~/Library/Rime/ 底下

    # 部署位置:
    # ~/.config/ibus/rime  (Linux)
    # ~/Library/Rime  (Mac OS)
    # %APPDATA%\Rime  (Windows)
    
  3. 若爲雙拼使用者,請將 double_pinyin.custom.yaml 改名成你所使用的雙拼方案的代碼 如 double_pinyin_abc.custom.yaml,並放入第二步所說的目錄底下 若該目錄底下已有這個檔案,那麼將這兩個檔案中的內容 merge 即可

    附雙拼方案與其對應的 id 一覽表:

    輸入方案 id
    自然碼雙拼 double_pinyin
    智能ABC雙拼 double_pinyin_abc
    小鶴雙拼 double_pinyin_flypy
    MSPY雙拼 double_pinyin_mspy
  4. 若爲「朙月拼音」系列輸入方案使用者,請將補靪文件 luna_pinyin.custom.yaml 改名爲你所使用的輸入方案對應的 id。(比如朙月拼音·簡化字方案,則將 luna_pinyin.custom.yaml 改名爲 luna_pinyin_simp.custom.yaml)。

驗證:切換到拼音或其他適用方案,輸入「一介書生」(驗證擴充詞庫之基本詞庫)、「一丈紅」(驗證擴充詞庫之漢語大詞典詞彙)、「疑是地上霜」(驗證擴充詞庫之詩詞詞庫)、輸入「哆啦A夢(duo la a meng)」(驗證擴充詞庫之西文詞庫,此子詞庫爲朙月拼音系列方案專有,雙拼方案不推薦使用)。

增加自己的詞庫

在這個架構底下增加自己的詞庫相當容易,只需新增一個自訂的 *.dict.yaml 檔案,內容可以仿照 luna_pinyin.extended.dict.yaml,並於其中引入 luna_pinyin.extended 及相關字典檔,例如:

# lazywei.dict.yaml
---
name: lazywei
version: "2015.1.10"
sort: by_weight
use_preset_vocabulary: true
import_tables:
  - luna_pinyin
  - luna_pinyin.extended
  - luna_pinyin.hanyu
  - luna_pinyin.poetry
...

這是我的詞

接着再於 *.schema.yaml*.custom.yaml 中將 translator/dictionary 設置成此字典檔即可,例如:

patch:
  translator/dictionary: lazywei

如此,往後 luna_pinyin.extended 升級時並不會影響到這個 lazywei.dict.yaml,所以直接將所有檔案覆蓋即可。

dictionaries's People

Contributors

keyvec avatar kunki avatar lazywei avatar leoyoon-tsaw avatar lotem avatar xfelino avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dictionaries's Issues

正在找开源词库 这里的词库有版权问题吗

想在自己弄的输入方案dict里加入高频词库并开源出来,就考虑到版权的问题。
比如 luna_pinyin.extended.dict里写的:
Thanks to the following works:

都允许我们自由复制修改传播吧?
还有权重/频率怎么都是1?

词库导入失败

我按照教程将对应的yaml文件拷贝到了rime目录下,部署出现如下错误

 ❯ rime_deployer --build
E0503 17:28:37.237483 23722 deployment_tasks.cc:242] source file 'luna_pinyin.dict.yaml' does not exist.
E0503 17:28:37.237565 23722 deployment_tasks.cc:300] dictionary 'luna_pinyin.extended' failed to compile.
E0503 17:28:37.239971 23722 deployment_tasks.cc:242] source file 'wubi86.dict.yaml' does not exist.
E0503 17:28:37.243857 23722 deployment_tasks.cc:242] source file 'luna_pinyin.dict.yaml' does not exist.
E0503 17:28:37.259425 23722 deployment_tasks.cc:242] source file 'luna_pinyin.dict.yaml' does not exist.
E0503 17:28:37.263039 23722 deployment_tasks.cc:242] source file 'stroke.dict.yaml' does not exist.
E0503 17:28:37.269115 23722 deployment_tasks.cc:242] source file 'pinyin_simp.dict.yaml' does not exist.

环境是Archlinux , fcitx

luna_pinyin_ziam_tuan.dict 的用途

請問一下,這個 repo 中有

luna_pinyin_ziam_tuan.dict

但是在 bintray 下載的詞庫中並沒有這個檔案,請問這個資料夾的用途是什麼?
謝謝!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.