init: AbleFlow 用户工作区模板基线
This commit is contained in:
commit
ac62a3dc59
0
.claude/hooks/.gitkeep
Normal file
0
.claude/hooks/.gitkeep
Normal file
16
.claude/settings.json
Normal file
16
.claude/settings.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"permissions": {
|
||||
"deny": [
|
||||
"Read(../**)",
|
||||
"Edit(../**)",
|
||||
"Write(../**)",
|
||||
"Edit(.claude/settings.json)",
|
||||
"Write(.claude/settings.json)",
|
||||
"Read(//home/core/.claude/settings.json)",
|
||||
"Edit(//home/core/.claude/settings.json)",
|
||||
"Write(//home/core/.claude/settings.json)",
|
||||
"Edit(//etc/**)",
|
||||
"Write(//etc/**)"
|
||||
]
|
||||
}
|
||||
}
|
||||
19
.gitignore
vendored
Normal file
19
.gitignore
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
# 中间数据与大产物不进版本库
|
||||
dailyspace/*/data/
|
||||
workspace/*/data/
|
||||
**/output/
|
||||
wiki/*/data.db
|
||||
|
||||
# Python / Node 运行时产物
|
||||
__pycache__/
|
||||
*.pyc
|
||||
.venv/
|
||||
node_modules/
|
||||
|
||||
# 临时文件
|
||||
*.tmp
|
||||
*.log
|
||||
.DS_Store
|
||||
|
||||
# skills 是独立 git 仓库(平台统一管理),不嵌套提交
|
||||
.claude/skills/
|
||||
67
CLAUDE.md
Normal file
67
CLAUDE.md
Normal file
@ -0,0 +1,67 @@
|
||||
# Project Conventions
|
||||
|
||||
> 本工作区属于用户 `__USERNAME__`,由 AbleFlow 平台开通时从模板生成。
|
||||
|
||||
## 工作边界 — 严格限定
|
||||
|
||||
本项目的所有操作**必须限制在 `/home/core/dev/__USERNAME__/` 内部**。
|
||||
|
||||
- **禁止**读取、修改、创建 `/home/core/dev/__USERNAME__/` 之外的任何文件
|
||||
- **禁止**访问上级目录 `../`、`/home/core/dev/` 或其他兄弟项目
|
||||
- **禁止**引用外部项目的代码、数据或配置
|
||||
- 所有路径必须使用**绝对路径**或相对于项目根的路径
|
||||
|
||||
(以上边界同时由 `.claude/settings.json` 的权限规则强制执行。)
|
||||
|
||||
## Directory Structure
|
||||
|
||||
```
|
||||
/home/core/dev/__USERNAME__/
|
||||
├── CLAUDE.md # 项目约定(本文件)
|
||||
├── .gitignore # Git 忽略规则
|
||||
├── .mcp.json # MCP 数据源配置
|
||||
├── index.html # 工作区看板
|
||||
├── scripts/ # 脚本代码
|
||||
├── workspace/ # 工作目录(按工作命名)
|
||||
│ └── {workname}/
|
||||
│ ├── docs/ # 文档
|
||||
│ ├── data/ # 数据或参考资料
|
||||
│ ├── output/ # 生成产物 (pptx, xlsx, docx, zip)
|
||||
│ └── README.md # 工作日志
|
||||
├── dailyspace/ # 日期类工作区
|
||||
│ └── YYMMDD/ # 当日工作目录,如 260519
|
||||
│ ├── data/ # 当日中间数据 (CSV/JSON)
|
||||
│ └── output/ # 当日生成产物
|
||||
├── wiki/ # auto-wiki 知识库(按主题隔离)
|
||||
│ └── {topic}/ # 如 personal-pension、treasury-futures
|
||||
│ ├── meta.yaml
|
||||
│ ├── index.md
|
||||
│ ├── data.db # 结构化数据(SQLite)
|
||||
│ └── sources/ entities/ concepts/ analyses/
|
||||
└── .claude/
|
||||
├── settings.json # 权限规则(平台管理,请勿修改)
|
||||
├── skills/ # Skill 仓库(git clone,平台统一升级,只读)
|
||||
└── hooks/ # 自定义 hooks
|
||||
```
|
||||
|
||||
## 文件管理规则
|
||||
|
||||
| 类型 | 存放位置 |
|
||||
|------|---------|
|
||||
| 长期工作 | `workspace/{workname}/`,配 README.md 记录进展 |
|
||||
| 当日临时任务 | `dailyspace/YYMMDD/`,跨日任务沿用起始日目录 |
|
||||
| 一次性脚本 | 所属工作目录内,不散落根目录 |
|
||||
| 知识沉淀 | `wiki/{topic}/` |
|
||||
| 根目录 | 零污染:不允许留下临时文件、中间产物 |
|
||||
|
||||
## Git
|
||||
|
||||
本目录是一个 Git 仓库,远端为 `git.ablemind.cc/__USERNAME__/workspace`(私有)。阶段性成果请提交并 push,作为版本史与备份。`.gitignore` 已排除中间数据与大产物。
|
||||
|
||||
## 记忆
|
||||
|
||||
Claude Code 的跨会话记忆由运行时自动管理(位于 `~/.claude/projects/` 下),随平台持久化,无需手动维护目录。
|
||||
|
||||
## 模型与密钥
|
||||
|
||||
模型配置(`ANTHROPIC_*`)由平台写入 `~/.claude/settings.json`,可在 flow.ablemind.cc 的设置页查看与修改,不要写进本目录的任何文件。
|
||||
0
dailyspace/.gitkeep
Normal file
0
dailyspace/.gitkeep
Normal file
55
index.html
Normal file
55
index.html
Normal file
@ -0,0 +1,55 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>__USERNAME__ · AbleFlow 工作区</title>
|
||||
<style>
|
||||
:root { --fg:#1a1a1a; --muted:#6b7280; --line:#e5e7eb; --accent:#b45309; --bg:#fafaf9; }
|
||||
* { box-sizing:border-box; margin:0; }
|
||||
body { font-family:-apple-system,"PingFang SC","Microsoft YaHei",sans-serif; background:var(--bg); color:var(--fg); max-width:880px; margin:0 auto; padding:48px 24px; line-height:1.7; }
|
||||
h1 { font-size:22px; font-weight:600; letter-spacing:.02em; }
|
||||
h1 small { color:var(--muted); font-weight:400; font-size:14px; margin-left:10px; }
|
||||
.rule { border-top:2px solid var(--fg); margin:14px 0 28px; }
|
||||
h2 { font-size:15px; font-weight:600; color:var(--accent); margin:28px 0 10px; }
|
||||
table { width:100%; border-collapse:collapse; font-size:14px; }
|
||||
th,td { text-align:left; padding:8px 10px; border-bottom:1px solid var(--line); }
|
||||
th { color:var(--muted); font-weight:500; font-size:13px; }
|
||||
code { background:#f3f4f6; padding:1px 6px; border-radius:4px; font-size:13px; }
|
||||
.links a { display:inline-block; margin:0 16px 8px 0; color:var(--accent); text-decoration:none; font-size:14px; }
|
||||
.links a:hover { text-decoration:underline; }
|
||||
footer { margin-top:40px; color:var(--muted); font-size:12px; border-top:1px solid var(--line); padding-top:12px; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>__USERNAME__ 的工作区<small>AbleFlow · flow.ablemind.cc</small></h1>
|
||||
<div class="rule"></div>
|
||||
|
||||
<h2>目录约定</h2>
|
||||
<table>
|
||||
<tr><th>目录</th><th>用途</th></tr>
|
||||
<tr><td><code>workspace/{workname}/</code></td><td>长期工作,按工作命名,README.md 记录进展</td></tr>
|
||||
<tr><td><code>dailyspace/YYMMDD/</code></td><td>当日任务(data/ 中间数据,output/ 产物)</td></tr>
|
||||
<tr><td><code>wiki/{topic}/</code></td><td>知识沉淀(auto-wiki)</td></tr>
|
||||
<tr><td><code>scripts/</code></td><td>常用脚本</td></tr>
|
||||
</table>
|
||||
|
||||
<h2>平台入口</h2>
|
||||
<div class="links">
|
||||
<a href="https://ablemind.cc" target="_blank">门户</a>
|
||||
<a href="https://skill.ablemind.cc" target="_blank">技能市场</a>
|
||||
<a href="https://git.ablemind.cc" target="_blank">代码仓库</a>
|
||||
<a href="https://api.ablemind.cc" target="_blank">API 中转站</a>
|
||||
<a href="https://docs.ablemind.cc" target="_blank">使用手册</a>
|
||||
</div>
|
||||
|
||||
<h2>常用操作</h2>
|
||||
<table>
|
||||
<tr><td>启动 Claude Code</td><td>终端输入 <code>claude</code></td></tr>
|
||||
<tr><td>提交工作成果</td><td><code>git add -A && git commit -m "..." && git push</code></td></tr>
|
||||
<tr><td>修改模型配置</td><td>flow.ablemind.cc 设置页(或联系管理员)</td></tr>
|
||||
</table>
|
||||
|
||||
<footer>工作边界:所有操作限于本工作区内 · 详见 CLAUDE.md</footer>
|
||||
</body>
|
||||
</html>
|
||||
0
scripts/.gitkeep
Normal file
0
scripts/.gitkeep
Normal file
0
wiki/.gitkeep
Normal file
0
wiki/.gitkeep
Normal file
0
workspace/.gitkeep
Normal file
0
workspace/.gitkeep
Normal file
Loading…
Reference in New Issue
Block a user