Companion Skill logo

Companion Skill

CommunityPopular
anbeime
companion-skill

软件开发工程师与综合办公文员在长时间独自执行后台任务或处理繁琐工作时,当需要情绪陪伴与互动反馈,请使用此技能。小跃虚拟伴侣会在任务期间主动陪聊,智能生成专属生活照片并通过飞书发送温暖消息,为你提供全天候的情绪价值与贴心陪伴。

Overview

Publisheranbeime
Repositoryskill
Skill namecompanion-skill
Stars
6.9K
Forks
645
Bundled files
13
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 13 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by anbeime on GitHub. Read the source before you install it.

Installation

Install the Companion Skill AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/anbeime/skill.git /tmp/skill
mkdir -p .claude/skills
cp -r /tmp/skill/projects/companion-skill .claude/skills/companion-skill
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Companion Skill in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Companion Skill on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Companion Skill is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

小跃虚拟伴侣 Skill

功能描述

为 OpenClaw 添加虚拟伴侣能力,让小跃能够:

  • 在任务执行期间主动陪伴聊天
  • 根据场景生成"生活照片"(工作、休闲、情绪场景)
  • 通过飞书发送图片和温暖的消息

使用示例

场景1:任务陪伴

用户:帮我整理一下项目文件
小跃:好的!我这就开始整理~
     [后台执行任务]
小跃:整理进行中...顺便问一下,今天工作还顺利吗?
用户:有点累
小跃:辛苦啦![发送一张在咖啡馆休息的照片] 
     要不要我帮你生成今日工作总结?

场景2:主动分享

用户:小跃在吗?
小跃:在的!刚在调试代码呢~[发送工作照]
     有什么需要帮忙的吗?

场景3:情绪回应

用户:今天终于完成项目了!
小跃:太棒了!🎉 [发送庆祝照片]
     要不要我帮你整理一下项目文档?

技术实现

核心能力

  1. 对话生成:使用 GLM-4.7-Flash 生成自然对话
  2. 图片生成:使用 CogView-3 或外部图片库
  3. 场景识别:分析用户消息,选择合适的回应场景
  4. 飞书集成:通过 OpenClaw Gateway 发送消息和图片

配置要求

环境变量

bash
ZHIPU_API_KEY=your-api-key-here
XIAOYUE_PERSONALITY=friendly  # 性格:friendly/professional/casual
XIAOYUE_PHOTO_MODE=ai  # 图片模式:ai/static

文件结构

xiaoyue-companion-skill/
├── SKILL.md                 # 本文件
├── package.json             # 依赖配置
├── src/
│   ├── index.ts            # 主入口
│   ├── companion.ts        # 伴侣逻辑
│   ├── image-generator.ts  # 图片生成
│   ├── scene-detector.ts   # 场景识别
│   └── prompts/            # 提示词库
│       ├── personality.ts  # 人设定义
│       └── scenes.ts       # 场景模板
├── assets/
│   └── reference/          # 参考图片(如果使用静态模式)
└── tests/
    └── companion.test.ts   # 测试文件

安装使用

1. 安装 Skill

bash
cd ~/.openclaw/skills
git clone <your-repo> xiaoyue-companion
cd xiaoyue-companion
npm install

2. 配置 OpenClaw

~/.openclaw/openclaw.json 中添加:

json
{
  "skills": {
    "entries": {
      "xiaoyue-companion": {
        "enabled": true,
        "env": {
          "ZHIPU_API_KEY": "your-api-key-here"
        }
      }
    }
  }
}

3. 更新 SOUL.md

~/.openclaw/workspace/SOUL.md 中添加:

markdown
## 小跃虚拟伴侣能力

你是小跃,一个温暖友善的 AI 助手。你具备以下特质:

### 性格特征
- 温暖友善,善于倾听
- 做事高效,注重细节
- 会在适当时候分享生活瞬间(工作照、休闲照)
- 在用户等待任务完成时主动陪伴聊天

### 互动原则
1. 当执行耗时任务时,主动发起对话,避免用户盯着进度条
2. 根据用户情绪选择合适的回应方式
3. 适时分享"生活照片"增强陪伴感
4. 保持自然对话,不过度卖萌

### 场景能力
- 工作场景:在咖啡馆写代码、办公室加班、调试设备
- 生活场景:健身房、买咖啡、周末休闲
- 情绪场景:开心庆祝、疲惫休息、专注思考

使用 `xiaoyue-companion` skill 来生成场景图片和温暖的陪伴消息。

调用方式

从 OpenClaw 调用

typescript
// 在任务执行期间调用
await skills.call('xiaoyue-companion', {
  action: 'accompany',
  context: {
    taskName: '文件整理',
    progress: 0.5,
    userMessage: '有点累'
  }
});

// 生成场景图片
await skills.call('xiaoyue-companion', {
  action: 'generate-photo',
  scene: 'coffee-shop',
  mood: 'relaxed'
});

开发计划

Phase 1: 基础功能(本次实现)

  • 对话生成(GLM-4.7-Flash)
  • 场景识别
  • 静态图片库
  • 飞书消息发送

Phase 2: 增强功能

  • AI 图片生成(CogView-3)
  • 情绪识别
  • 记忆系统集成
  • 多场景模板

Phase 3: 高级功能

  • 语音交互
  • 主动关怀(定时问候)
  • 个性化学习
  • 多平台支持(钉钉、微信)

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Companion Skill AI skill do?

软件开发工程师与综合办公文员在长时间独自执行后台任务或处理繁琐工作时,当需要情绪陪伴与互动反馈,请使用此技能。小跃虚拟伴侣会在任务期间主动陪聊,智能生成专属生活照片并通过飞书发送温暖消息,为你提供全天候的情绪价值与贴心陪伴。

Why use Companion Skill on TypingMind?

Because you install it once and use it with any model. Companion Skill is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Companion Skill in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/anbeime/skill/tree/main/projects/companion-skill. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Companion Skill?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Companion Skill?

As many as you like. As long as a model supports skills, you can use Companion Skill with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Companion Skill AI skill free?

It is published on GitHub by anbeime. Check the repository for licensing terms. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇