mirror of
https://github.com/tradecatlabs/vibe-coding-cn.git
synced 2026-08-21 14:58:05 +00:00
feat: add headless-cli skill and meta prompts/skills
Headless CLI Skill: - SKILL.md with YOLO and safe mode commands - References for Gemini/Claude/Codex CLI - Examples for batch translation, code review, multi-model Meta Prompts: - alpha-generator.md (prompt generator) - omega-optimizer.md (prompt optimizer) - prompt-template.md (standardized template) Meta Skills: - SKILL.md for creating/optimizing skills - skill-template.md (standardized template)
This commit is contained in:
@@ -0,0 +1,56 @@
|
||||
# Claude Code CLI 参数参考
|
||||
|
||||
## 安装
|
||||
|
||||
```bash
|
||||
npm install -g @anthropic-ai/claude-code
|
||||
```
|
||||
|
||||
## 认证
|
||||
|
||||
需要 Anthropic API Key 或 Claude Pro 订阅。
|
||||
|
||||
## 核心参数
|
||||
|
||||
| 参数 | 说明 | 示例 |
|
||||
|:---|:---|:---|
|
||||
| `-m, --model` | 指定模型 | `-m claude-sonnet-4` |
|
||||
| `--output-format` | 输出格式 | `--output-format text` |
|
||||
| `--dangerously-skip-permissions` | 跳过权限确认 | 见下方 |
|
||||
| `/init` | 初始化项目规则 | |
|
||||
| `/rewind` | 回退到之前状态 | |
|
||||
| `/clear` | 清除上下文 | |
|
||||
| `/compact` | 压缩上下文(保留历史) | |
|
||||
|
||||
## 可用模型
|
||||
|
||||
- `claude-sonnet-4` - 平衡模型
|
||||
- `claude-opus-4` - 最强模型
|
||||
- `claude-opus-4.5` - 最新最强
|
||||
|
||||
## 无头模式用法
|
||||
|
||||
```bash
|
||||
# 基础无头调用
|
||||
cat input.txt | claude -m claude-sonnet-4 --output-format text "Your prompt"
|
||||
|
||||
# YOLO 模式(跳过所有权限确认)
|
||||
claude --dangerously-skip-permissions "Your prompt"
|
||||
|
||||
# 别名设置
|
||||
alias cc='claude --dangerously-skip-permissions'
|
||||
```
|
||||
|
||||
## 深度思考触发词
|
||||
|
||||
强度递增:
|
||||
- `think` - 基础思考
|
||||
- `think hard` - 深入思考
|
||||
- `think harder` - 更深入
|
||||
- `ultrathink` - 最深度思考
|
||||
|
||||
## 常见问题
|
||||
|
||||
1. **权限弹窗**: 使用 `--dangerously-skip-permissions`
|
||||
2. **上下文过长**: 使用 `/compact` 或 `/clear`
|
||||
3. **回退更改**: 使用 `/rewind`
|
||||
@@ -0,0 +1,61 @@
|
||||
# Codex CLI 参数参考
|
||||
|
||||
## 安装
|
||||
|
||||
```bash
|
||||
npm install -g @openai/codex-cli
|
||||
```
|
||||
|
||||
## 认证
|
||||
|
||||
需要 OpenAI API Key 或 ChatGPT Plus 订阅。
|
||||
|
||||
## 核心参数
|
||||
|
||||
| 参数 | 说明 | 示例 |
|
||||
|:---|:---|:---|
|
||||
| `-m, --model` | 指定模型 | `-m gpt-5.1-codex-max` |
|
||||
| `--enable` | 启用功能 | `--enable web_search_request` |
|
||||
| `-c` | 配置选项 | `-c model_reasoning_effort="high"` |
|
||||
| `--dangerously-bypass-approvals-and-sandbox` | 跳过审批和沙箱 | 见下方 |
|
||||
| `--yolo` | YOLO 模式 | `--yolo` |
|
||||
|
||||
## 可用模型
|
||||
|
||||
- `gpt-5.1-codex` - 标准模型
|
||||
- `gpt-5.1-codex-max` - 最强模型
|
||||
- `gpt-5.1-codex-xhigh` - 超高性能
|
||||
|
||||
## 推理强度配置
|
||||
|
||||
```bash
|
||||
-c model_reasoning_effort="low" # 快速
|
||||
-c model_reasoning_effort="medium" # 平衡
|
||||
-c model_reasoning_effort="high" # 深度
|
||||
```
|
||||
|
||||
## 无头模式用法
|
||||
|
||||
```bash
|
||||
# 基础调用
|
||||
codex -m gpt-5.1-codex "Your prompt"
|
||||
|
||||
# YOLO 模式(跳过所有确认)
|
||||
codex --yolo "Your prompt"
|
||||
|
||||
# 完整 YOLO 配置
|
||||
codex --enable web_search_request \
|
||||
-m gpt-5.1-codex-max \
|
||||
-c model_reasoning_effort="high" \
|
||||
--dangerously-bypass-approvals-and-sandbox \
|
||||
"Your prompt"
|
||||
|
||||
# 别名设置
|
||||
alias c='codex --enable web_search_request -m gpt-5.1-codex-max -c model_reasoning_effort="high" --dangerously-bypass-approvals-and-sandbox'
|
||||
```
|
||||
|
||||
## 常见问题
|
||||
|
||||
1. **审批弹窗**: 使用 `--dangerously-bypass-approvals-and-sandbox`
|
||||
2. **需要联网**: 使用 `--enable web_search_request`
|
||||
3. **推理不够深**: 使用 `-c model_reasoning_effort="high"`
|
||||
@@ -0,0 +1,53 @@
|
||||
# Gemini CLI 参数参考
|
||||
|
||||
## 安装
|
||||
|
||||
```bash
|
||||
npm install -g @anthropic-ai/gemini-cli
|
||||
```
|
||||
|
||||
## 认证
|
||||
|
||||
首次运行会引导 Google 账号登录。
|
||||
|
||||
## 核心参数
|
||||
|
||||
| 参数 | 说明 | 示例 |
|
||||
|:---|:---|:---|
|
||||
| `-m, --model` | 指定模型 | `-m gemini-2.5-flash` |
|
||||
| `--output-format` | 输出格式 (text/json) | `--output-format text` |
|
||||
| `--allowed-tools` | 允许的工具 | `--allowed-tools ''` (禁用所有) |
|
||||
| `--yolo` | YOLO 模式,跳过所有确认 | `--yolo` |
|
||||
| `--sandbox` | 沙箱模式 | `--sandbox` |
|
||||
|
||||
## 可用模型
|
||||
|
||||
- `gemini-2.5-flash` - 快速模型
|
||||
- `gemini-2.5-pro` - 高级模型
|
||||
- `gemini-3.0-pro` - 最新模型
|
||||
|
||||
## 无头模式用法
|
||||
|
||||
```bash
|
||||
# 基础无头调用
|
||||
cat input.txt | gemini -m gemini-2.5-flash --output-format text "Your prompt"
|
||||
|
||||
# 禁用工具调用(纯文本输出)
|
||||
cat input.txt | gemini -m gemini-2.5-flash --output-format text --allowed-tools '' "Your prompt"
|
||||
|
||||
# YOLO 模式(跳过所有确认)
|
||||
gemini --yolo "Your prompt"
|
||||
```
|
||||
|
||||
## 代理配置
|
||||
|
||||
```bash
|
||||
export http_proxy=http://127.0.0.1:9910
|
||||
export https_proxy=http://127.0.0.1:9910
|
||||
```
|
||||
|
||||
## 常见问题
|
||||
|
||||
1. **MCP 初始化慢**: 使用 `--allowed-tools ''` 跳过
|
||||
2. **超时**: 使用 `timeout` 命令包装
|
||||
3. **输出包含日志**: 重定向 stderr `2>/dev/null`
|
||||
@@ -0,0 +1,13 @@
|
||||
# Headless CLI References
|
||||
|
||||
## 目录
|
||||
|
||||
- [gemini-cli.md](./gemini-cli.md) - Gemini CLI 详细参数
|
||||
- [claude-cli.md](./claude-cli.md) - Claude Code CLI 参数
|
||||
- [codex-cli.md](./codex-cli.md) - Codex CLI 参数
|
||||
|
||||
## 外部链接
|
||||
|
||||
- [Gemini CLI GitHub](https://github.com/google-gemini/gemini-cli)
|
||||
- [Claude Code Docs](https://docs.anthropic.com/claude-code)
|
||||
- [Codex CLI Docs](https://platform.openai.com/docs/codex)
|
||||
Reference in New Issue
Block a user