Skip to content

Commit ab6c49f

Browse files
author
unraid
committed
feat: 整合功能恢复与技能学习闭环(含 ECC v2.1 parity + Opus 4.7 接入)
Skill Learning 闭环: runtime observer + instinct store + evolution pipeline + LLM observer backend + DiscoverSkillsTool(TF-IDF) + /skill-learning 命令。 ECC v2.1 parity: conflict-hold 态、confidence decay、observation purge、 单条 64KB 上限、LLM prompt 注入防护(JSON.stringify 转义)、统一 stringifyField 消除双重序列化、instinct 原子写(tmp+rename) + 同进程串行化。 Autonomy: /autonomy status/runs/flows/flow cancel|resume + autonomyPanel + autonomyCommandSpec 集中参数规格。 Opus 4.7: model configs/options/capabilities/validation/migration 全链路、 getDefaultOpusModel 切换 4.7、getOpus46Option 显式上一代。 Provider Usage: Anthropic/Bedrock/OpenAI adapter + DeepSeek/generic balance provider + poller(10s fetch 超时)。generic balance URL SSRF 防护(协议/私网 校验) + 凭证回退链注释。 Bedrock Client: 独立实现修复 SDK anthropic_beta body 注入 bug。 UltraReview: ultrareviewCommand + OverageDialog + 本地 gate 默认值。 Assistant Teams: session-scoped team bootstrap + TeamStatus/TeamsDialog。 Bridge/Pipe: status visualization、mute sync、circuit breaker、webhook sanitizer。 Component migrations: TS → TSX(Ink 组件)。 安全: 删除泄露的 Claude-Opus-4.7.txt + gitignore 防护。 Tested: tsc --noEmit 零错误 / bun test 全量 pass / skill-learning 89 pass
1 parent 96ec96c commit ab6c49f

283 files changed

Lines changed: 26921 additions & 6047 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/claude.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Claude Code
2+
3+
on:
4+
issue_comment:
5+
types: [created]
6+
pull_request_review_comment:
7+
types: [created]
8+
issues:
9+
types: [opened, assigned]
10+
11+
permissions:
12+
contents: write
13+
pull-requests: write
14+
issues: write
15+
16+
jobs:
17+
claude:
18+
if: |
19+
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) ||
20+
(github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude')) ||
21+
(github.event_name == 'issues' && contains(github.event.issue.body, '@claude'))
22+
runs-on: ubuntu-latest
23+
steps:
24+
- uses: actions/checkout@v4
25+
26+
- uses: anthropics/claude-code-action@v1
27+
with:
28+
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,11 @@ src/utils/vendor/
1919
/*.png
2020
*.bmp
2121

22+
# Internal system prompt documents
23+
Claude-Opus-*.txt
24+
Claude-Sonnet-*.txt
25+
Claude-Haiku-*.txt
26+
2227
# Agent / tool state dirs
2328
.swarm/
2429
.agents/__pycache__/

AGENTS.md

Lines changed: 283 additions & 0 deletions
Large diffs are not rendered by default.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
| **自定义模型供应商** | OpenAI/Anthropic/Gemini/Grok 兼容 | [文档](https://ccb.agent-aura.top/docs/features/custom-platform-login) |
2727
| Voice Mode | Push-to-Talk 语音输入 | [文档](https://ccb.agent-aura.top/docs/features/voice-mode) |
2828
| Computer Use | 屏幕截图、键鼠控制 | [文档](https://ccb.agent-aura.top/docs/features/computer-use) |
29-
| Chrome Use | 浏览器自动化、表单填写、数据抓取 | [自托管](https://ccb.agent-aura.top/docs/features/chrome-use-mcp) [原生版](https://ccb.agent-aura.top/docs/features/claude-in-chrome-mcp) |
29+
| Chrome Use | 浏览器自动化、表单填写、数据抓取 | [魔改版](docs/features/chrome-use-mcp) [原生版](https://ccb.agent-aura.top/docs/features/claude-in-chrome-mcp) |
3030
| Sentry | 企业级错误追踪 | [文档](https://ccb.agent-aura.top/docs/internals/sentry-setup) |
3131
| GrowthBook | 企业级特性开关 | [文档](https://ccb.agent-aura.top/docs/internals/growthbook-adapter) |
3232
| /dream 记忆整理 | 自动整理和优化记忆文件 | [文档](https://ccb.agent-aura.top/docs/features/auto-dream) |

build.ts

Lines changed: 67 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,63 @@
11
import { readdir, readFile, writeFile, cp } from 'fs/promises'
22
import { join } from 'path'
33
import { getMacroDefines } from './scripts/defines.ts'
4-
import { DEFAULT_BUILD_FEATURES } from './scripts/defines.ts'
54

65
const outdir = 'dist'
76

87
// Step 1: Clean output directory
98
const { rmSync } = await import('fs')
109
rmSync(outdir, { recursive: true, force: true })
1110

11+
// Default features that match the official CLI build.
12+
// Additional features can be enabled via FEATURE_<NAME>=1 env vars.
13+
const DEFAULT_BUILD_FEATURES = [
14+
'BRIDGE_MODE',
15+
'AGENT_TRIGGERS_REMOTE',
16+
'CHICAGO_MCP',
17+
'VOICE_MODE',
18+
'SHOT_STATS',
19+
'PROMPT_CACHE_BREAK_DETECTION',
20+
'TOKEN_BUDGET',
21+
// P0: local features
22+
'AGENT_TRIGGERS',
23+
'ULTRATHINK',
24+
'BUILTIN_EXPLORE_PLAN_AGENTS',
25+
'LODESTONE',
26+
// P1: API-dependent features
27+
'EXTRACT_MEMORIES',
28+
'VERIFICATION_AGENT',
29+
'KAIROS_BRIEF',
30+
'AWAY_SUMMARY',
31+
'ULTRAPLAN',
32+
// P2: daemon + remote control server
33+
'DAEMON',
34+
// ACP (Agent Client Protocol) agent mode
35+
'ACP',
36+
// PR-package restored features
37+
'WORKFLOW_SCRIPTS',
38+
'HISTORY_SNIP',
39+
'CONTEXT_COLLAPSE',
40+
'MONITOR_TOOL',
41+
'FORK_SUBAGENT',
42+
'UDS_INBOX',
43+
'KAIROS',
44+
'COORDINATOR_MODE',
45+
'LAN_PIPES',
46+
'BG_SESSIONS',
47+
'TEMPLATES',
48+
// 'REVIEW_ARTIFACT', // API 请求无响应,需进一步排查 schema 兼容性
49+
// API content block types
50+
'CONNECTOR_TEXT',
51+
// Attribution tracking
52+
'COMMIT_ATTRIBUTION',
53+
// Server mode (claude server / claude open)
54+
'DIRECT_CONNECT',
55+
// Skill search
56+
'EXPERIMENTAL_SKILL_SEARCH',
57+
// P3: poor mode (disable extract_memories + prompt_suggestion)
58+
'POOR',
59+
]
60+
1261
// Collect FEATURE_* env vars → Bun.build features
1362
const envFeatures = Object.keys(process.env)
1463
.filter(k => k.startsWith('FEATURE_'))
@@ -80,7 +129,23 @@ const vendorDir = join(outdir, 'vendor', 'audio-capture')
80129
await cp('vendor/audio-capture', vendorDir, { recursive: true })
81130
console.log(`Copied vendor/audio-capture/ → ${vendorDir}/`)
82131

83-
// Step 5: Generate cli-bun and cli-node executable entry points
132+
// Step 5: Bundle download-ripgrep script as standalone JS for postinstall
133+
const rgScript = await Bun.build({
134+
entrypoints: ['scripts/download-ripgrep.ts'],
135+
outdir,
136+
target: 'node',
137+
})
138+
if (!rgScript.success) {
139+
console.error('Failed to bundle download-ripgrep script:')
140+
for (const log of rgScript.logs) {
141+
console.error(log)
142+
}
143+
// Non-fatal — postinstall fallback to bun run scripts/download-ripgrep.ts
144+
} else {
145+
console.log(`Bundled download-ripgrep script to ${outdir}/`)
146+
}
147+
148+
// Step 6: Generate cli-bun and cli-node executable entry points
84149
const cliBun = join(outdir, 'cli-bun.js')
85150
const cliNode = join(outdir, 'cli-node.js')
86151

0 commit comments

Comments
 (0)