Explorar o código

docs: add local skill path to OpenClaw section, bump SKILL.md to v1.4.0

- Both READMEs now explain that cloned-repo users can read skills/SKILL.md
  directly without clawhub install
- SKILL.md v1.4.0: add creative brief (--brief), custom provider,
  structured logging (JSON Lines, -q quiet mode)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Ma hai 7 meses
pai
achega
b8b7f7fddc
Modificáronse 3 ficheiros con 48 adicións e 10 borrados
  1. 19 2
      README.en.md
  2. 19 2
      README.md
  3. 10 6
      skills/SKILL.md

+ 19 - 2
README.en.md

@@ -28,6 +28,23 @@ Open-source CLI agent that autonomously writes, audits, and revises novels — w
 npm i -g @actalk/inkos
 npm i -g @actalk/inkos
 ```
 ```
 
 
+### Use via OpenClaw
+
+InkOS is published as an [OpenClaw](https://clawhub.ai) Skill, callable by any compatible agent (Claude Code, OpenClaw, etc.):
+
+```bash
+clawhub install inkos          # Install from ClawHub
+```
+
+If you've already cloned this repo, the skill file is at `skills/SKILL.md` — your agent can read it directly without installing:
+
+```bash
+# For cloned repo users: point your agent to the local skill
+clawhub install ./skills       # Or just let your agent read skills/SKILL.md
+```
+
+Once installed, agents can invoke all InkOS atomic commands (`draft`/`audit`/`revise`/`write next`) via `exec`, with `--json` output for structured decision-making. You can also browse it on [ClawHub](https://clawhub.ai) by searching `inkos`.
+
 ### Configure
 ### Configure
 
 
 **Option 1: Global config (recommended, one-time setup)**
 **Option 1: Global config (recommended, one-time setup)**
@@ -164,7 +181,7 @@ inkos audit my-book 31 --json
 inkos revise my-book 31 --json
 inkos revise my-book 31 --json
 ```
 ```
 
 
-Each command performs a single operation independently. `--json` outputs structured data. Can be called by OpenClaw or other AI agents via `exec`, or used in scripts.
+Each command performs a single operation independently. `--json` outputs structured data. Can be called by external AI agents via `exec`, or used in scripts.
 
 
 ### 3. Natural Language Agent Mode
 ### 3. Natural Language Agent Mode
 
 
@@ -242,7 +259,7 @@ Telegram, Feishu, WeCom, and Webhook. In daemon mode, get notified on your phone
 
 
 ### External Agent Integration
 ### External Agent Integration
 
 
-Atomic commands + `--json` output make InkOS callable by OpenClaw and other AI agents. OpenClaw executes `inkos draft`/`audit`/`revise` via `exec`, reads JSON results, and decides next steps.
+Atomic commands + `--json` output make InkOS callable by external AI agents (OpenClaw, Claude Code, etc.). Agents execute `inkos draft`/`audit`/`revise` via `exec`, read JSON results, and decide next steps.
 
 
 ## Architecture
 ## Architecture
 
 

+ 19 - 2
README.md

@@ -28,6 +28,23 @@ Agent 写小说。写、审、改,全程接管。
 npm i -g @actalk/inkos
 npm i -g @actalk/inkos
 ```
 ```
 
 
+### 通过 OpenClaw 使用
+
+InkOS 已发布为 [OpenClaw](https://clawhub.ai) Skill,可被任何兼容 Agent(Claude Code、OpenClaw 等)直接调用:
+
+```bash
+clawhub install inkos          # 从 ClawHub 安装 InkOS Skill
+```
+
+如果你已克隆本项目,Skill 文件已在 `skills/SKILL.md`,Agent 可直接读取——无需额外安装:
+
+```bash
+# 已克隆项目的用户:告诉你的 Agent 读取本地 skill
+clawhub install ./skills       # 或直接让 Agent 读取 skills/SKILL.md
+```
+
+安装后,Agent 可通过 `exec` 调用 InkOS 的所有原子命令(`draft`/`audit`/`revise`/`write next`),`--json` 输出结构化数据供 Agent 解析决策。也可以在 [ClawHub](https://clawhub.ai) 搜索 `inkos` 在线查看。
+
 ### 配置
 ### 配置
 
 
 **方式一:全局配置(推荐,只需一次)**
 **方式一:全局配置(推荐,只需一次)**
@@ -164,7 +181,7 @@ inkos audit 吞天魔帝 31 --json
 inkos revise 吞天魔帝 31 --json
 inkos revise 吞天魔帝 31 --json
 ```
 ```
 
 
-每个命令独立执行单一操作,`--json` 输出结构化数据。可被 OpenClaw 等 AI Agent 通过 `exec` 调用,也可用于脚本编排。
+每个命令独立执行单一操作,`--json` 输出结构化数据。可被外部 AI Agent 通过 `exec` 调用,也可用于脚本编排。
 
 
 ### 3. 自然语言 Agent 模式
 ### 3. 自然语言 Agent 模式
 
 
@@ -260,7 +277,7 @@ inkos agent "先扫描市场趋势,然后根据结果创建一本新书"
 
 
 ### 外部 Agent 集成
 ### 外部 Agent 集成
 
 
-原子命令 + `--json` 输出让 InkOS 可以被 OpenClaw 等 AI Agent 调用。OpenClaw 通过 `exec` 工具执行 `inkos draft`/`audit`/`revise`,读取 JSON 结果决定下一步操作。
+原子命令 + `--json` 输出让 InkOS 可以被外部 AI Agent(如 OpenClaw、Claude Code 等)调用。Agent 通过 `exec` 执行 `inkos draft`/`audit`/`revise`,读取 JSON 结果决定下一步操作。
 
 
 ## 项目结构
 ## 项目结构
 
 

+ 10 - 6
skills/SKILL.md

@@ -1,7 +1,7 @@
 ---
 ---
 name: inkos
 name: inkos
-description: Autonomous novel writing CLI agent - use for creative fiction writing, novel generation, style imitation, chapter continuation/import, EPUB export, and AIGC detection. Supports Chinese web novel genres (xuanhuan, xianxia, urban, horror, other) with multi-agent pipeline, two-phase writer (creative + settlement), 33-dimension auditing, and token usage analytics.
-version: 1.3.0
+description: Autonomous novel writing CLI agent - use for creative fiction writing, novel generation, style imitation, chapter continuation/import, EPUB export, and AIGC detection. Supports Chinese web novel genres (xuanhuan, xianxia, urban, horror, other) with multi-agent pipeline, two-phase writer (creative + settlement), 33-dimension auditing, token usage analytics, creative brief input, structured logging (JSON Lines), and custom OpenAI-compatible provider support.
+version: 1.4.0
 metadata: { "openclaw": { "emoji": "📖", "requires": { "bins": ["inkos", "node"], "env": [] }, "primaryEnv": "", "homepage": "https://github.com/Narcooo/inkos", "install": [{ "id": "npm", "kind": "node", "package": "@actalk/inkos", "label": "Install InkOS (npm)" }] } }
 metadata: { "openclaw": { "emoji": "📖", "requires": { "bins": ["inkos", "node"], "env": [] }, "primaryEnv": "", "homepage": "https://github.com/Narcooo/inkos", "install": [{ "id": "npm", "kind": "node", "package": "@actalk/inkos", "label": "Install InkOS (npm)" }] } }
 ---
 ---
 
 
@@ -29,8 +29,10 @@ The Writer uses a two-phase architecture: Phase 1 (creative writing, temp 0.7) p
 # Initialize a project directory (creates config structure)
 # Initialize a project directory (creates config structure)
 inkos init my-writing-project
 inkos init my-writing-project
 
 
-# Configure your LLM provider (OpenAI, Anthropic, or compatible)
+# Configure your LLM provider (OpenAI, Anthropic, or any OpenAI-compatible API)
 inkos config set-global --provider openai --base-url https://api.openai.com/v1 --api-key sk-xxx --model gpt-4o
 inkos config set-global --provider openai --base-url https://api.openai.com/v1 --api-key sk-xxx --model gpt-4o
+# For compatible/proxy endpoints, use --provider custom:
+# inkos config set-global --provider custom --base-url https://your-proxy.com/v1 --api-key sk-xxx --model gpt-4o
 ```
 ```
 
 
 ### View System Status
 ### View System Status
@@ -49,6 +51,8 @@ inkos status
 1. **Initialize and create book**:
 1. **Initialize and create book**:
    ```bash
    ```bash
    inkos book create --title "My Novel Title" --genre xuanhuan --chapter-words 3000
    inkos book create --title "My Novel Title" --genre xuanhuan --chapter-words 3000
+   # Or with a creative brief (your worldbuilding doc / ideas):
+   inkos book create --title "My Novel Title" --genre xuanhuan --chapter-words 3000 --brief my-ideas.md
    ```
    ```
    - Genres: `xuanhuan` (cultivation), `xianxia` (immortal), `urban` (city), `horror`, `other`
    - Genres: `xuanhuan` (cultivation), `xianxia` (immortal), `urban` (city), `horror`, `other`
    - Returns a `book-id` for all subsequent operations
    - Returns a `book-id` for all subsequent operations
@@ -282,7 +286,7 @@ inkos genre copy xuanhuan --name "dark-xuanhuan" --rules "darker tone, more viol
 | Command | Purpose | Notes |
 | Command | Purpose | Notes |
 |---------|---------|-------|
 |---------|---------|-------|
 | `inkos init [name]` | Initialize project | One-time setup |
 | `inkos init [name]` | Initialize project | One-time setup |
-| `inkos book create` | Create new book | Returns book-id |
+| `inkos book create` | Create new book | Returns book-id. `--brief <file>` for creative brief |
 | `inkos book list` | List all books | Shows IDs, statuses |
 | `inkos book list` | List all books | Shows IDs, statuses |
 | `inkos write next` | Full pipeline (draft→audit→revise) | Primary workflow command |
 | `inkos write next` | Full pipeline (draft→audit→revise) | Primary workflow command |
 | `inkos draft` | Generate draft only | No auditing/revision |
 | `inkos draft` | Generate draft only | No auditing/revision |
@@ -297,10 +301,10 @@ inkos genre copy xuanhuan --name "dark-xuanhuan" --rules "darker tone, more viol
 | `inkos export` | Export finished book | Formats: txt, md, epub |
 | `inkos export` | Export finished book | Formats: txt, md, epub |
 | `inkos analytics` / `inkos stats` | View book statistics | Word count, audit rates, token usage |
 | `inkos analytics` / `inkos stats` | View book statistics | Word count, audit rates, token usage |
 | `inkos radar scan` | Platform trend analysis | Informs new book ideas |
 | `inkos radar scan` | Platform trend analysis | Informs new book ideas |
-| `inkos config set-global` | Configure LLM provider | OpenAI/Anthropic/compatible |
+| `inkos config set-global` | Configure LLM provider | OpenAI/Anthropic/custom (any OpenAI-compatible) |
 | `inkos doctor` | Diagnose issues | Check installation |
 | `inkos doctor` | Diagnose issues | Check installation |
 | `inkos update` | Update to latest version | Self-update |
 | `inkos update` | Update to latest version | Self-update |
-| `inkos up/down` | Daemon mode | Background processing |
+| `inkos up/down` | Daemon mode | Background processing. Logs to `inkos.log` (JSON Lines). `-q` for quiet mode |
 | `inkos review list/approve-all` | Manage chapter approvals | Quality gate |
 | `inkos review list/approve-all` | Manage chapter approvals | Quality gate |
 
 
 ## Error Handling
 ## Error Handling