Skip to content

morlay/playpen

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

playpen

基于 ACP(Agent Client Protocol)的 coding agent 后端。可选 macOS seatbelt 沙箱隔离。

快速开始

# 安装
just rust build playpen

# ACP 模式(供 Zed 等编辑器连接)
playpen acp

# 或直接 CLI 使用
playpen agent "你好"
playpen agent --profile=code -i

功能

  • ACP 协议 — 与任何支持 ACP 的编辑器集成
  • 沙箱隔离 — macOS seatbelt 沙箱,保障 LLM 工具执行安全(可选)
  • 工具集 — 文件读写/编辑、Shell 执行、网页抓取、grep/find
  • 全自定义 Profile — 每个 profile 可独立配置 system instruction、模型、thinking level、可用工具、AGENTS.md 规范,数量不限
  • Skills — 可复用技能包,通过 /skill:{name} 在 prompt 中注入
  • 对话持久化 — SQLite 存储对话历史

配置

# ~/.config/playpen/settings.toml
[model_providers.deepseek]
api_key = "${DEEPSEEK_API_KEY}"

[sandbox]
enabled = true

[sandbox.filesystem]
access = ["rw .", "r- ~/"]

Profile 是完全自定义的——每个 profile 可以指定不同的 system instruction、模型、推理深度、启用的工具集,以及 AGENTS.md 编码规范文件。你可以为不同场景创建多个 profile:

~/.config/playpen/profiles/
├── code/profile.toml          # 编程助手
├── review/profile.toml        # 代码审查
└── terminal/profile.toml      # 终端操作

一个典型的 profile.toml

description = "编程助手"
instruction = "你是一个编程助手..."

[default_model_profile]
model = "deepseek/deepseek-v4-flash"
thinking_level = "off"

详细文档见 docs

About

基于沙箱的极简 coding-agent wip

Topics

Resources

Stars

Watchers

Forks

Contributors