/install feishu-chat-importer
Feishu Chat History Importer
Import Feishu chat history exports into OpenClaw episodic memory. Converts feishu JSON exports into daily episodic summaries that the Dreaming system can process and display in Imported Insights and Memory Palace views.
Quick Start
# Dry run — preview what would be imported
python3 skills/feishu-chat-importer/scripts/batch.py --dir memory/Chat-history --dry-run
# Import all Feishu chats
python3 skills/feishu-chat-importer/scripts/batch.py --dir memory/Chat-history
# Import only chats since a date
python3 skills/feishu-chat-importer/scripts/batch.py --dir memory/Chat-history --since 2026-03-01
# Verbose — show every message
python3 skills/feishu-chat-importer/scripts/batch.py --dir memory/Chat-history --dry-run --verbose
How It Works
- Read
feishu_chat_YYYYMMDD.jsonfiles from the source directory - Group messages by date (from
create_time/ millisecond timestamp) - Normalize each message to
{role, content, timestamp}sender.sender_type = "user"→ role =usersender.sender_type = "app"→ role =assistant(Feishu bot = AI)
- Write daily episodic summaries to
memory/episodic/YYYY-MM-DD.md - Dreaming processes episodic files → appears in Imported Insights + Memory Palace
Output Format
Writes to memory/episodic/YYYY-MM-DD.md:
## Feishu Chat: \x3Cchat_id> (2026-03-19)
- Messages: \x3Ccount>
- Participants: user_id, app_id
### user (首长):
message content here...
### assistant (飞书机器人):
message content here...
Key Concepts
- Daily grouping: All messages from the same YYYYMMDD file land in the same episodic file
- Deduplication: Chat IDs tracked — re-running never creates duplicates
- Role mapping: User messages →
user, App/bot messages →assistant - Content extraction: Handles
textandpostmsg_type automatically - OPENCLAW_WORKSPACE: Set this env var to point imports to the right agent workspace
Source Format
Expects Feishu export files named feishu_chat_YYYYMMDD.json with this structure:
[
{
"message_id": "om_xxx",
"chat_id": "oc_xxx",
"create_time": "1773899372102",
"msg_type": "text|post",
"sender": {
"id": "ou_xxx",
"sender_type": "user|app"
},
"body": {
"content": "{\"text\":\"message text\"}" // text type
// or
"content": "{\"title\":\"\",\"content\":[[{\"tag\":\"text\",\"text\":\"...\"}]]}" // post type
}
}
]
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install feishu-chat-importer - After installation, invoke the skill by name or use
/feishu-chat-importer - Provide required inputs per the skill's parameter spec and get structured output
What is Feishu Chat Importer?
Convert Feishu chat history exports into OpenClaw episodic memory format. Parses feishu_chat_YYYYMMDD.json files, normalizes messages, and writes daily episo... It is an AI Agent Skill for Claude Code / OpenClaw, with 62 downloads so far.
How do I install Feishu Chat Importer?
Run "/install feishu-chat-importer" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is Feishu Chat Importer free?
Yes, Feishu Chat Importer is completely free, licensed under MIT-0. You can download, install and use it at no cost.
Which platforms does Feishu Chat Importer support?
Feishu Chat Importer is cross-platform and runs anywhere OpenClaw / Claude Code is available (win32, linux, darwin).
Who created Feishu Chat Importer?
It is built and maintained by arkerro (@arkerro); the current version is v1.0.0.