AGENT SKILL

ghost-writer

Receives voice-dictated prose drafts from the GhostWriter R1 Creation and saves them as Markdown files on the host machine.

License 许可
MIT
最近更新
2026-09-04
Stars
★ 0
Forks
0

01 前言 Front Matter

name
ghost-writer
author
rabbit-r1-skillz
version
1.0.0
description
Receives voice-dictated prose drafts from the GhostWriter R1 Creation and saves them as Markdown files on the host machine.

02 资源文件 3

03 SKILL.md 正文

GhostWriter — OpenClaw Skill

This skill receives polished prose drafts generated by the GhostWriter Creation on your Rabbit R1 and saves them as Markdown files on your local machine.

What GhostWriter sends

The Creation sends two possible OpenClaw command types:

1. save-draft

Saves the finished draft as a Markdown file.

Payload:

{
  "filename": "draft-conversational-2026-06-14-09-30-00.md",
  "content": "---\ntitle: GhostWriter Draft\n...\n---\n\nFull draft text...",
  "wordCount": 420,
  "style": "conversational",
  "timestamp": "2026-06-14T09:30:00.000Z"
}

Expected response:

{
  "saved": true,
  "path": "/absolute/path/to/saved/file.md"
}

Local setup

Prerequisites

  • OpenClaw running on your machine
  • Node.js 18+ or Python 3.10+

Installation

  1. Install OpenClaw and start the daemon:

    npm install -g openclaw
    openclaw start
    
  2. Register this skill with OpenClaw by placing skill.js (below) in your OpenClaw skills directory, typically ~/.openclaw/skills/ghost-writer/.

  3. Configure the output directory (optional — defaults to ~/Documents/GhostWriter/):

    openclaw config set ghost-writer.outputDir "/path/to/your/writing/folder"
    
  4. Verify the skill is registered:

    openclaw skills list
    # Should show: ghost-writer  v1.0.0  active
    

skill.js

Place this file at ~/.openclaw/skills/ghost-writer/skill.js:

const fs   = require('fs').promises;
const path = require('path');
const os   = require('os');

const OUTPUT_DIR = process.env.GHOST_WRITER_DIR
  || path.join(os.homedir(), 'Documents', 'GhostWriter');

module.exports = {
  name: 'ghost-writer',
  version: '1.0.0',

  async onCommand(command, payload) {
    if (command === 'save-draft') {
      return await saveDraft(payload);
    }
    return { error: 'Unknown command: ' + command };
  }
};

async function saveDraft({ filename, content, wordCount, style, timestamp }) {
  await fs.mkdir(OUTPUT_DIR, { recursive: true });

  const safeName = filename.replace(/[^a-zA-Z0-9._-]/g, '-');
  const filePath = path.join(OUTPUT_DIR, safeName);

  await fs.writeFile(filePath, content, 'utf8');

  // Append to index file for quick browsing
  const indexPath = path.join(OUTPUT_DIR, 'INDEX.md');
  const indexLine = `| ${new Date(timestamp).toLocaleString()} | ${style} | ${wordCount} words | [${safeName}](./${safeName}) |\n`;
  try {
    await fs.appendFile(indexPath, indexLine, 'utf8');
  } catch (_) { /* index is optional */ }

  return { saved: true, path: filePath, wordCount };
}

Output format

Saved files are Markdown with YAML frontmatter:

---
title: GhostWriter Draft
date: 2026-06-14T09:30:00.000Z
style: conversational
wordCount: 420
revisions: 2
aiEnhanced: false
---

[Your polished draft here]

---

## Raw Dictation

[Your original stream-of-consciousness transcript here]

Files are saved to ~/Documents/GhostWriter/ by default, named:

draft-{style}-{YYYY-MM-DD}-{HH-MM-SS}.md

An INDEX.md table is maintained in the same folder for quick reference.

Security notes

  • This skill writes files only to the configured output directory. It does not traverse paths, execute code from the payload, or make outbound network requests.
  • The content field is written verbatim as-is — treat it as user-generated text.
  • OpenClaw's local-only transport means no data leaves your machine except via the R1 device connection.

04 同仓库更多 Skills

ajohnsonnow
ajohnsonnow/r1-warren

whisper-quiz

WhisperQuiz — voice-answered trivia game for Rabbit R1. Generates questions via the R1's built-in LLM, captures spoken answers via STT, and evaluates correctness with flexible LLM-based matching.

★ 0
ajohnsonnow
ajohnsonnow/r1-warren

walk-cast

Walking podcast production skill. Receives raw audio metadata and transcript from the R1, removes long pauses, applies noise reduction and normalization, generates AI chapter titles and episode metadata via LLM, and uploads the final episode to your configured podcast RSS host (Spotify for Podcasters / Anchor, Podbean, Buzzsprout, RSS.com, or any FTP-accessible feed).

★ 0
ajohnsonnow
ajohnsonnow/r1-warren

voice-novel

Local machine skill for VoiceNovel — handles story export to disk.

★ 0
ajohnsonnow
ajohnsonnow/r1-warren

voice-guide

Environment description and navigation assistant for blind and low-vision users. Analyzes camera frames via a vision LLM, reads visible text, identifies scene categories (people/vehicles/food/hazards/exits), performs 360° scans, retrieves GPS position, and sends emergency SMS alerts — all via audio feedback with zero screen dependency.

★ 0
ajohnsonnow
ajohnsonnow/r1-warren

voice-draft

Voice-driven document drafting for the Rabbit R1. Dictate stream-of-consciousness speech; the R1 formats it into Email, Blog Post, Report, Proposal, Meeting Notes, Creative Writing, Code Comments, Cover Letter, or Tweet Thread — then saves the result to a configured folder on your local machine via OpenClaw.

★ 0
ajohnsonnow
ajohnsonnow/r1-warren

voice-commit

Hands-free git and CI workflow voice controller for the Rabbit R1. Speak git/CI commands and hear results — commit, push, status, PR management, test runs, and deploy, all voice-driven via OpenClaw.

★ 0