create-agent-adapter

分类: 开发与编程 | 上传者: WeAreBiniWeAreBini | 下载: 0 | 版本: v1.0(最新)

Technical guide for creating a new Paperclip agent adapter. Use when building a new adapter package, adding support for a new AI coding tool (e.g. a new CLI agent, API-based agent, or custom process), or when modifying the adapter system. Covers the required interfaces, module structure, registration points, and conventions derived from the existing claude-local and codex-local adapters. --- # Creating a Paperclip Agent Adapter An adapter bridges Paperclip's orchestration layer to a specific AI agent runtime (Claude Code, Codex CLI, a custom process, an HTTP endpoint, etc.). Each adapter is a self-contained package that provides implementations for **three consumers**: the server, the UI, and the CLI. --- ## 1. Architecture Overview ``` packages/adapters/<name>/ src/ index.ts # Shared metadata (type, label, models, agentConfigurationDoc) server/ index.ts # Server exports: execute, sessionCodec, parse helpers execute.ts # Core execution logic (AdapterExecutionContext -> AdapterExecutionResult) parse.ts # Stdout/result parsing for the agent's output format ui/ index.ts # UI exports: parseStdoutLine, buildConfig parse-stdout.ts # Line-by-line stdout -> TranscriptEntry[] for the run viewer build-config.ts # CreateConfigValues -> adapterConfig JSON for agent creation form cli/ index.ts # CLI exports: formatStdoutEvent format-event.ts # Colored terminal output for `paperclipai run --watch` package.json tsconfig.json ```

更新日志: Source: GitHub https://github.com/WeAreBini/paperclip

目录结构

当前层级: .agents/skills/create-agent-adapter/

SKILL.md

登录后下载/点赞/收藏 ❤ 3 | ★ 0
评论 0

请先登录后评论。

还没有评论,快来第一个发言吧。