Auto-translate content with AI on save
Overview
Kuroco's AI post-processing lets you run AI operations automatically whenever content is saved. This tutorial shows you how to set up automatic translation: when you save a Japanese body text, AI translates it into English and writes the result to a separate English field.
What you'll learn
Prerequisites
- A Kuroco site is already created
1. Create a content definition
Create a content definition with a source (Japanese) field and a target (English) field.
Click Content structure, then click Add.

Fill in the form as follows.
| Field | Value |
|---|---|
| Content structure name | Translation test |
Then add the following extended fields.
| Slug | Field name | Field type |
|---|---|---|
| body_ja | Body (Japanese) | Textarea |
| body_en | Body (English) | Textarea |

Click Add to save the content definition.
2. Configure AI post-processing
Open the content definition you just created and click AI post-processing in the left sidebar.

Enable AI post-processing
Turn on the Enable toggle under AI post-processing.

Add a rule
Click Add rule and configure it as follows.
| Field | Value |
|---|---|
| Prompt | See below |
| Execution timing | On create / update |
| Creation status | Published |
Example prompt:
Translate the Japanese text in the body_ja field into natural English and write it to the body_en field. Return only the translation, with no explanation or preamble.
Also, translate the English text in the body_en field into natural Japanese and write it to the body_ja field. Return only the translation, with no explanation or preamble.
Because this prompt is bidirectional, saving content when body_en is empty may cause the AI to overwrite body_ja with the result of "translating empty text." For one-directional use (Japanese → English only), remove the second sentence of the prompt.

Click Update to save the settings.
3. Verify the result
Create a new content entry from the content definition you configured.
Click Content structure, then click List under Translation test. Click Add.

Enter Japanese text in the Body (Japanese) field and click Add.
| Field | Example value |
|---|---|
| Body (Japanese) | Kuroco is a headless content management system. |

After saving, open the content detail view. Confirm that the Body (English) field has been filled in automatically by AI.

You have now completed the AI auto-translation setup.
Related documentation
Support
If you have any other questions, please contact us or check out Our Slack Community.