Giter Site home page Giter Site logo

mhkoji / senn Goto Github PK

View Code? Open in Web Editor NEW
16.0 1.0 2.0 4.35 MB

Input method editor for the Japanese language

License: BSD 2-Clause "Simplified" License

Common Lisp 53.75% Shell 0.44% Emacs Lisp 4.70% C++ 33.21% CMake 1.16% C 2.96% Makefile 0.62% M4 0.33% Dockerfile 1.78% QMake 0.15% Python 0.90%
common-lisp lisp input-method ime tsf

senn's Introduction

Senn Input Method

Input method editor for the Japanese language

KKC Engine

  • The KKC of the ime is implemented in the separated file named kkc-engine installed at:
    • fcitx: /usr/lib/senn/fcitx/kkc-engine.
    • ibus: /usr/lib/senn/ibus/kkc-engine.
  • When the ime is turned on, it starts kkc-engine and communcates with it using a pipe.
  • kkc-engine can be replaced with any executable file as long as it satisfies the protocol described below to communication with the ime.

The protocol

kkc-engine receives a request of a line from the standard input and sends a response of a line to the standard output. A line of the requests and responses is JSON encoded.

Each json form of requests is as follows:

{ "op": "<request op>", "args": "<request args>" }

The json form of a response depends on the request.

CONVERT request

A Convert request is used to converts a sequence that the user inputs to a word sequence.

Request

  • op: "CONVERT"
  • args:
    • pron:
      • A string of the sequence (typically hiragana)

Response

  • array of objects: // An array of objects that describes a word sequence
    • pron: // A substring of the input sequence for the word
    • candidates: array of objects:
      • form: // A string of kana and kanji for the word

LIST_CANDIDATES request

A LIST_CANDIDATES request is used to list candidates for a pron.

Request

  • op: "LIST_CANDIDATES"
  • args:
    • pron:

Response

  • array of objects: // An array of objects that describes candidates
    • form: // A string of kana and kanji

senn's People

Contributors

mhkoji avatar

Stargazers

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

Watchers

 avatar

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.