chinese-convert

n8n node to convert between Simplified and Traditional Chinese, and compare Chinese text

Package Information

Downloads: 40 weekly / 53 monthly
Latest Version: 0.1.4
Author: HKU Official

Documentation

n8n-nodes-chinese-convert

npm version
npm downloads

This is an n8n community node that provides Chinese text conversion between Simplified and Traditional Chinese, with regional locale support and text comparison capabilities.

n8n is a fair-code licensed workflow automation platform.

Features

  • Simplified to Traditional Chinese Conversion — Convert 简体中文 to 繁體中文 with support for regional variants (Hong Kong, Standard)
  • Traditional to Simplified Chinese Conversion — Convert 繁體中文 to 简体中文 with regional source locale detection
  • Text Comparison — Compare any two Chinese texts (Simplified or Traditional) to determine if they are equivalent, regardless of which variant is used
  • Regional Locale Support — Choose between Hong Kong (hk, default) or Standard Traditional Chinese variants for accurate phrase and character conversion
  • Powered by OpenCC — Uses the industry-standard OpenCC library for accurate and comprehensive Chinese text conversion

Installation

Follow the installation guide in the n8n community nodes documentation.

Quick Install

For self-hosted n8n:

# Navigate to n8n custom nodes folder
cd ~/.n8n/nodes   # Linux/Mac
# or
cd %USERPROFILE%\.n8n\nodes   # Windows CMD
# or
cd $env:USERPROFILE\.n8n\nodes   # Windows PowerShell

# Install the package
npm install n8n-nodes-chinese-convert

# Restart n8n

Note: This node uses the opencc-js dependency and is designed for self-hosted n8n installations. It is not compatible with n8n Cloud due to dependency restrictions.

Operations

1. Simplified to Traditional

Converts Simplified Chinese text to Traditional Chinese with locale options.

Parameters:

  • Text (required) — The Simplified Chinese text to convert
  • Target Locale (optional, default: Hong Kong) — Choose the target Traditional Chinese variant:
    • Hong Kong (繁體-香港) — Hong Kong-specific characters and phrases
    • Traditional (繁體) — Standard Traditional Chinese

Example:

Input: 汉语
Output: 漢語 (Hong Kong locale)

2. Traditional to Simplified

Converts Traditional Chinese text to Simplified Chinese with source locale detection.

Parameters:

  • Text (required) — The Traditional Chinese text to convert
  • Source Locale (optional, default: Hong Kong) — Specify the source Traditional Chinese variant:
    • Hong Kong (繁體-香港)
    • Traditional (繁體)

Example:

Input: 漢語
Output: 汉语

3. Compare

Compares two Chinese texts to determine if they are equivalent, regardless of whether they are Simplified or Traditional Chinese.

Parameters:

  • Chinese Text Input 1 (required) — The first Chinese text (Simplified or Traditional)
  • Chinese Text Input 2 (required) — The second Chinese text (Simplified or Traditional)
  • Target Locale (optional, default: Hong Kong) — The locale used for normalization during comparison

Returns:

  • match — Boolean indicating if texts are equivalent
  • textInput1 / textInput2 — Original input texts
  • normalized1 / normalized2 — Normalized Simplified versions (for comparison)
  • input1ToTraditional / input2ToTraditional — Traditional Chinese conversions
  • targetLocale — The locale used for normalization

Example:

{
  "match": true,
  "textInput1": "计算机",
  "textInput2": "計算機",
  "normalized1": "计算机",
  "normalized2": "计算机",
  "input1ToTraditional": "計算機",
  "input2ToTraditional": "計算機",
  "targetLocale": "hk"
}

Usage Example

Basic Conversion Workflow

  1. Add the Chinese Convert node to your workflow
  2. Select the operation (Simplified to Traditional, Traditional to Simplified, or Compare)
  3. Enter your Chinese text
  4. Execute the workflow

API Integration Example

Combine with HTTP Request node to build a Chinese text conversion API:

HTTP Request (POST) → Chinese Convert → Respond to Webhook

Data Processing Example

Process Chinese text in datasets:

Spreadsheet File → Chinese Convert → Update Database

Output Format

Conversion Operations

{
  "operation": "simplifiedToTraditional",
  "original": "计算机科学",
  "result": "計算機科學",
  "targetLocale": "hk"
}

Compare Operation

{
  "operation": "compare",
  "match": true,
  "textInput1": "计算机",
  "textInput2": "計算機",
  "normalized1": "计算机",
  "normalized2": "计算机",
  "input1ToTraditional": "計算機",
  "input2ToTraditional": "計算機",
  "targetLocale": "hk"
}

Regional Differences

The node supports regional variants for more accurate conversions:

Example Simplified (CN) Traditional (HK) Traditional (Standard)
Software 软件 軟件 軟體
Network 网络 網絡 網路
Information 信息 資訊 資訊

Compatibility

  • n8n version: 0.198.0 or higher
  • Node.js version: 18.0 or higher
  • Deployment: Self-hosted n8n only (not compatible with n8n Cloud)

Development

Want to contribute or run locally?

# Clone the repository
git clone https://github.com/hku-official/n8n-nodes-chinese-convert.git
cd n8n-nodes-chinese-convert

# Install dependencies
npm install

# Start development mode (launches n8n with hot reload)
npm run dev

# Build for production
npm run build

# Run linting
npm run lint

Version History

0.1.4 (2025-12-10)

  • Removed Taiwan locale option
  • Changed default locale to Hong Kong for all operations
  • Improved Compare operation to accept any two Chinese texts (Simplified or Traditional)
  • Renamed comparison inputs to "Chinese Text Input 1" and "Chinese Text Input 2"
  • Added Target Locale selection for Compare operation

0.1.3 (2025-12-10)

  • Added flexible text comparison with Target Locale support
  • Updated Compare operation with generic input names

0.1.2 (2025-12-10)

  • Removed example nodes and credentials
  • Cleaned up package for production

0.1.1 (2025-12-10)

  • Updated README documentation

0.1.0 (2025-12-10)

  • Initial release
  • Simplified to Traditional conversion with locale support
  • Traditional to Simplified conversion
  • Text comparison functionality
  • OpenCC integration

Resources

Support

License

MIT

Credits

This node uses opencc-js, a JavaScript implementation of OpenCC (Open Chinese Convert).

Discussion