Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
155 commits
Select commit Hold shift + click to select a range
3074386
fix: int32 deserialize for MCP count fields and notify socket ref mut
pippenz Mar 17, 2026
7dd1c1f
feat(config_gen): inject mcp__cas__* permissions into worker settings…
pippenz Mar 17, 2026
7356722
fix(factory): add .mcp.json committed-file pre-flight check for workers
pippenz Mar 17, 2026
1191395
fix(mcp): complete numeric string-coercion for all MCP Option fields
pippenz Mar 20, 2026
4d2078e
fix(tui): OSC 52 clipboard copy and auto-inject on image paste
pippenz Mar 20, 2026
7ee61e2
feat(theme): add opt-in Minions theme for factory workers and boot sc…
pippenz Mar 20, 2026
c734005
fix(theme): improve minion ASCII art, wire MinionsIcons into TUI, fix…
pippenz Mar 20, 2026
124fb3c
Merge branch 'factory/zealous-cardinal-43' into tui-upgrades
pippenz Mar 20, 2026
c630a92
fix(theme): improve minion ASCII art and use canonical character names
pippenz Mar 20, 2026
dfc86b5
fix(theme): replace non-canonical minion name 'lance' with 'tony'
pippenz Mar 20, 2026
e11e1f8
fix(factory): fix drain_clears_pending_notifications test
pippenz Mar 20, 2026
913626b
test: add coverage for OSC 52, theme variant, minions palette and icons
pippenz Mar 20, 2026
1cda031
fix(pty): fix broken mcp__cs__ tool prefixes in Codex instructions
pippenz Mar 20, 2026
7a739c5
fix(messaging): remove per-message response hints from format_agent_m…
pippenz Mar 20, 2026
8fd6cec
fix(pty): revert to mcp__cs__ prefix, keep extraction to constants
pippenz Mar 20, 2026
62ffe29
perf: cache supervisor_owned_workers() with thread_local OnceCell
pippenz Mar 20, 2026
85f8553
Merge branch 'factory/clever-cardinal-20'
pippenz Mar 20, 2026
d03b7e3
Merge branch 'factory/bright-koala-98'
pippenz Mar 20, 2026
6d9a1e5
fix(messaging): preserve full message content on undeliverable prompt…
pippenz Mar 20, 2026
1c09010
Merge branch 'factory/fair-condor-83'
pippenz Mar 20, 2026
89e0165
feat(queue): add priority levels to prompt queue
pippenz Mar 20, 2026
cdcd943
Merge branch 'factory/clever-cardinal-20'
pippenz Mar 20, 2026
edbdd33
feat: add delivery confirmation for prompt queue messages
pippenz Mar 20, 2026
3db4321
chore: update CLAUDE.md with detailed architecture docs and add MCP t…
pippenz Mar 20, 2026
b1ae3ad
fix(config): merge stale YAML settings into TOML config, bump to v1.1.0
pippenz Mar 23, 2026
e8a858d
fix(factory): defer cloud phone-home init in fork-first path to preve…
pippenz Mar 23, 2026
c5c0a30
fix(ui): skip inject mode on file drop, route keystrokes directly to PTY
pippenz Mar 24, 2026
64662a6
Merge branch 'factory/mighty-puma-38'
pippenz Mar 24, 2026
4303fea
fix(factory): add clipboard fallback via client-side write and visual…
pippenz Mar 24, 2026
bf358ae
Merge branch 'factory/fair-cheetah-13'
pippenz Mar 24, 2026
d01001a
feat(ui): add Tokyo Night theme variant
pippenz Mar 24, 2026
49c286f
fix(factory): add fallback workflow for workers when MCP tools unavai…
pippenz Mar 24, 2026
df60ca9
fix(auth): return non-zero exit code from whoami when not logged in
pippenz Mar 24, 2026
2afbe1c
fix(ui): forward Tab to PTY for autocomplete, use Ctrl+P for sidecar
pippenz Mar 24, 2026
04251c0
fix(cloud): scope pull requests by project_id to prevent cross-projec…
pippenz Mar 24, 2026
dbd830e
fix(factory): shutdown TUI when supervisor exits via /exit
pippenz Mar 24, 2026
c60d269
fix(factory): resolve verification deadlocks for supervisor and orpha…
pippenz Mar 25, 2026
c27ff9d
feat(worker): add worktree mode detection to cas-worker skill
pippenz Mar 25, 2026
0d797f7
fix(ui): supervisor border respects theme, improve agent name readabi…
pippenz Mar 25, 2026
c03872b
docs(spike): add MCP worktree investigation findings
pippenz Mar 25, 2026
c7e7ee7
fix(factory): deduplicate idle notifications and suppress from dead w…
pippenz Mar 25, 2026
bbca28e
Merge branch 'factory/clever-hound-53'
pippenz Mar 25, 2026
2b6f7c4
Merge branch 'factory/noble-lion-41'
pippenz Mar 25, 2026
75dc69f
Merge branch 'factory/watchful-badger-90'
pippenz Mar 25, 2026
848ef9b
fix(test): remove OnceCell cache causing flaky factory tests
pippenz Mar 25, 2026
2bfe4d3
fix(tui): filter task panel to active epic only
pippenz Mar 25, 2026
67fca07
fix(ui): pane labels match border color, not agent color
pippenz Mar 25, 2026
20a326a
feat(proxy): scaffold cas-mcp-proxy crate with config module
pippenz Mar 27, 2026
fe8b6a6
Merge factory/nimble-shark-87: scaffold cas-mcp-proxy crate
pippenz Mar 27, 2026
075191f
fix(tui): detect epic events before filtering to fix missing tasks
pippenz Mar 27, 2026
a44740a
feat(proxy): implement rmcp client connections in ProxyEngine
pippenz Mar 27, 2026
ba5c6e1
Merge factory/nimble-shark-87: implement rmcp client connections in P…
pippenz Mar 27, 2026
1efe27c
feat(proxy): implement search with keyword matching and server filter
pippenz Mar 27, 2026
83385ef
Merge factory/nimble-shark-87: implement search with keyword matching…
pippenz Mar 27, 2026
e82ab17
Merge factory/swift-lion-59: fix epic event ordering — detect before …
pippenz Mar 27, 2026
2af8b17
feat(proxy): implement execute with JSON dispatch and dot-call syntax
pippenz Mar 27, 2026
7f7b3f5
feat(proxy): implement config-aware hot-reload
pippenz Mar 27, 2026
6e7a722
Merge factory/nimble-shark-87: implement execute, hot-reload for Prox…
pippenz Mar 27, 2026
a0ce068
feat(proxy): integration tests, catalog cache fix, and README
pippenz Mar 27, 2026
8316706
Merge factory/nimble-shark-87: integration tests, catalog cache fix, …
pippenz Mar 27, 2026
b7eb7d9
fix(mcp): eager store init + request timing to reduce timeouts
pippenz Mar 27, 2026
a3706ff
Merge factory/swift-lion-59: eager store init + request timing to red…
pippenz Mar 27, 2026
914817f
fix(ui): suppress unused agent_color warnings
pippenz Mar 27, 2026
4053399
fix(store): eliminate N+1 queries in task_store.rs
pippenz Mar 27, 2026
266a8ba
fix(tui): detect Open-with-branch epics in runtime event detector
pippenz Mar 27, 2026
a4e091b
perf(mcp): cache search index, config; deduplicate truncate_str; remo…
pippenz Mar 27, 2026
c68c2e1
Merge factory/keen-newt-36: fix epic detection for Open-with-branch e…
pippenz Mar 27, 2026
ce1547d
Merge factory/clever-fox-92: MCP caching + dedup + dead code removal
pippenz Mar 27, 2026
1ceff67
fix(cloud): circuit breaker for TLS retry spam + cap event buffer + r…
pippenz Mar 27, 2026
fe4db1f
Merge factory/keen-newt-36: cloud client circuit breaker + buffer cap…
pippenz Mar 27, 2026
ff9e529
perf(cloud): cache get_project_canonical_id + fix git.rs unwrap panics
pippenz Mar 27, 2026
c6e3a5e
Merge factory/keen-newt-36: cache project canonical ID + fix git.rs u…
pippenz Mar 27, 2026
96f20ef
perf(store): add get_by_pid + list_by_branch queries; merge duplicate…
pippenz Mar 27, 2026
7f5cfc2
Merge factory/clever-fox-92: add get_by_pid + list_by_branch queries,…
pippenz Mar 27, 2026
5ab244c
feat(migration): add missing indexes for team_id and assignee columns
pippenz Mar 27, 2026
955b090
Merge factory/wild-dolphin-6: add missing indexes for team_id and ass…
pippenz Mar 27, 2026
d682b9a
fix(tui): update epic_state before filter in refresh_data()
pippenz Mar 27, 2026
70a0e8a
perf(mcp): cache search index, config; deduplicate truncate_str; remo…
pippenz Mar 27, 2026
755f168
fix(cloud): circuit breaker for TLS retry spam + cap event buffer + r…
pippenz Mar 27, 2026
e9b3871
perf(cloud): cache get_project_canonical_id + fix git.rs unwrap panics
pippenz Mar 27, 2026
492be4b
perf(store): add get_by_pid + list_by_branch queries; merge duplicate…
pippenz Mar 27, 2026
0c1161d
fix(store): eliminate N+1 queries in task_store.rs
pippenz Mar 27, 2026
c7eff7b
feat(migration): add missing indexes for team_id and assignee columns
pippenz Mar 27, 2026
fea932d
fix(tui): update epic_state before filter in refresh_data()
pippenz Mar 27, 2026
028d817
fix(tui): stabilize epic selection and dedup resuming log spam
pippenz Mar 27, 2026
30d6bf2
fix(factory): resolve project path from CAS root in worktree context
pippenz Mar 27, 2026
fb92881
Merge branch 'factory/brave-salmon-45'
pippenz Mar 27, 2026
58a08ee
Merge branch 'factory/eager-cobra-51'
pippenz Mar 27, 2026
df7d9b8
fix(tui): preserve scroll position when new output arrives
pippenz Mar 27, 2026
3c18e2b
Merge branch 'factory/brave-salmon-45'
pippenz Mar 27, 2026
ecd7d46
perf(hooks): consolidate SessionStart/End DB connections via HookStores
pippenz Mar 27, 2026
288491c
perf(hooks): replace task_store.list(None) with filtered queries in P…
pippenz Mar 27, 2026
6ba0808
Merge branch 'factory/eager-cobra-51'
pippenz Mar 27, 2026
55177c4
perf(search): cache IndexReader on Bm25Index instead of creating per …
pippenz Mar 27, 2026
2cd59e1
Merge branch 'factory/brave-salmon-45'
pippenz Mar 27, 2026
ae4d36e
perf(daemon): batch code symbol DB inserts in indexing daemon
pippenz Mar 27, 2026
c3df51a
fix(search): reopen Index after rebuild_atomic directory swap
pippenz Mar 27, 2026
eacc40e
perf(extraction): use batch API instead of per-observation extraction
pippenz Mar 27, 2026
edbb222
Merge branch 'factory/eager-cobra-51'
pippenz Mar 27, 2026
b03d484
Merge branch 'factory/brave-salmon-45'
pippenz Mar 27, 2026
7e6964f
fix(consolidation): process large groups in chunks instead of skipping
pippenz Mar 27, 2026
100dac7
perf(hooks): remove duplicate score_entries call in build_start
pippenz Mar 27, 2026
774db78
Merge branch 'factory/eager-cobra-51'
pippenz Mar 27, 2026
353e080
perf(extraction): pre-compute word sets in deduplicate_facts
pippenz Mar 27, 2026
6adb96e
Merge branch 'factory/brave-salmon-45'
pippenz Mar 27, 2026
ef0da40
perf(bridge): cache SQLite store handles in SSE stream
pippenz Mar 27, 2026
f9fefa3
Merge branch 'factory/eager-cobra-51'
pippenz Mar 27, 2026
7f5f49b
feat(factory): add explicit current_epic_id tracking to FactoryApp
pippenz Mar 27, 2026
39c0ec1
docs(worker): make worktree fallback the default worker mode
pippenz Mar 27, 2026
41661f1
Merge branch 'factory/brave-salmon-45'
pippenz Mar 27, 2026
67371cb
test: update doctor snapshot for schema v187
pippenz Mar 27, 2026
850ed85
feat(store): add jitter to SQLite write-retry backoff to break convoy…
pippenz Mar 30, 2026
b02fe05
feat(store): replace per-insert MAX(LIKE) scan with sequence table fo…
pippenz Mar 30, 2026
3684d37
fix(theme): improve TUI contrast and accessibility for 6 color issues
pippenz Mar 30, 2026
c4999a2
fix(theme): improve TUI contrast and accessibility (6 issues)
pippenz Mar 30, 2026
f51831d
perf(store): switch all prepare() calls to prepare_cached() for state…
pippenz Mar 30, 2026
9176b48
perf(store): replace iterative BFS cycle-check with recursive CTE in …
pippenz Mar 30, 2026
84c6fab
perf(search): cache Tantivy IndexWriter instead of allocating 50MB pe…
pippenz Mar 30, 2026
d8906f1
fix(theme): 6 more accessibility improvements for TUI contrast and co…
pippenz Mar 30, 2026
98e1a32
feat(store): make store_add event recording atomic with ImmediateTx
pippenz Mar 30, 2026
b6dfc36
fix(factory): fix task assignee name-vs-ID mismatch in director panels
pippenz Mar 30, 2026
40ffd39
fix(theme): 6 more accessibility improvements
pippenz Mar 30, 2026
47c92f0
perf: factory runtime optimizations (6 tasks)
pippenz Mar 30, 2026
9b442e4
perf(store,search): 6 storage & search performance fixes
pippenz Mar 30, 2026
c6752f0
perf(factory): 6 factory runtime performance optimizations
pippenz Mar 30, 2026
804b228
perf(store): optimize 6 SQL patterns — skip redundant queries, fix mi…
pippenz Mar 30, 2026
20a0cf9
perf(store): optimize 6 SQL patterns — skip redundant queries, fix mi…
pippenz Mar 30, 2026
d98954d
perf: batch 2 runtime optimizations (5 tasks)
pippenz Mar 30, 2026
894c153
refactor(search): simplify Bm25Index lock hierarchy
pippenz Mar 30, 2026
bed06ec
perf(search): cache QueryParser in Bm25Index instead of rebuilding pe…
pippenz Mar 30, 2026
3c551d1
perf(search): cache QueryParser + simplify lock hierarchy in Bm25Index
pippenz Mar 30, 2026
22183bd
perf(factory): 5 medium runtime optimizations
pippenz Mar 30, 2026
d3cdced
perf: 8 low-priority optimizations — alloc reduction, single-pass loa…
pippenz Mar 30, 2026
1443818
perf: 8 low-priority optimizations — alloc reduction, single-pass loa…
pippenz Mar 30, 2026
57af1f8
fix(tui): off-by-one in style run column indices clips left edge of p…
pippenz Mar 30, 2026
cb4c4d2
fix(mcp): add 55s timeout and tracing to tool calls to diagnose first…
pippenz Mar 30, 2026
e88b208
fix(cloud): enable TLS for ureq HTTP client
pippenz Mar 30, 2026
e85094b
fix(worker): detect worktree mode before first MCP attempt
pippenz Mar 30, 2026
969b53c
Revert "fix(worker): detect worktree mode before first MCP attempt"
pippenz Mar 30, 2026
bb47138
fix(verification): break supervisor self-verification deadlock
pippenz Mar 30, 2026
873a107
fix(factory): detect worktree mode in worker boot prompt before MCP a…
pippenz Mar 30, 2026
be6aa9c
fix(factory): allow supervisor to claim orphaned tasks from dead workers
pippenz Mar 30, 2026
bbdd04c
fix(factory): suppress idle notification spam and stale worker messages
pippenz Mar 30, 2026
15637b8
fix(worktree): resolve MCP server to parent repo .cas/ in worktrees
pippenz Mar 30, 2026
14e5669
refactor(factory): use native terminal selection, fix scroll viewport…
pippenz Apr 1, 2026
a0358d1
fix(hooks): detect and strip duplicate project-level CAS hooks
pippenz Apr 2, 2026
264cc95
fix(factory): restore mouse scroll by re-enabling EnableMouseCapture
pippenz Apr 2, 2026
e3d318e
chore: slim CLAUDE.md, fix dirty-flag for untracked files
pippenz Apr 2, 2026
2dfe2aa
fix(cloud): enable TLS for WebSocket client (tokio-tungstenite)
pippenz Apr 2, 2026
6e2c2c8
test: update doctor snapshot for schema v189
pippenz Apr 2, 2026
88d8235
feat(cloud): add `cas cloud team-memories` command
pippenz Apr 2, 2026
1863191
feat(cloud): add `cas cloud projects` command
pippenz Apr 2, 2026
c2244eb
merge: combine projects + team-memories commands
pippenz Apr 2, 2026
8c1203e
fix(cloud): handle 403/404 errors, pluralize contributor/memory labels
pippenz Apr 2, 2026
5abf92b
chore: add team project memories feature request from cloud team
pippenz Apr 2, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .cargo/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ jobs = 16
# on machines without sccache installed.

[target.x86_64-unknown-linux-gnu]
linker = "clang"
linker = "gcc"
rustflags = ["-C", "link-arg=-fuse-ld=lld"]
157 changes: 11 additions & 146 deletions .claude/settings.json
Original file line number Diff line number Diff line change
@@ -1,155 +1,20 @@
{
"hooks": {
"Notification": [
{
"hooks": [
{
"async": true,
"command": "cas hook Notification",
"timeout": 1000,
"type": "command"
}
],
"matcher": "permission_prompt|idle_prompt|auth_success"
}
],
"PermissionRequest": [
{
"hooks": [
{
"command": "cas hook PermissionRequest",
"timeout": 2000,
"type": "command"
}
]
}
],
"PostToolUse": [
{
"hooks": [
{
"async": true,
"command": "cas hook PostToolUse",
"timeout": 3000,
"type": "command"
}
],
"matcher": "Write|Edit|Bash"
}
],
"PreCompact": [
{
"hooks": [
{
"command": "cas hook PreCompact",
"timeout": 3000,
"type": "command"
}
]
}
],
"PreToolUse": [
{
"hooks": [
{
"command": "cas hook PreToolUse",
"timeout": 2000,
"type": "command"
}
],
"matcher": "Read|Glob|Grep|Write|Edit|Bash|WebFetch|WebSearch|Task|SendMessage"
}
],
"SessionEnd": [
{
"hooks": [
{
"async": true,
"command": "cas hook SessionEnd",
"timeout": 5000,
"type": "command"
}
]
}
],
"SessionStart": [
{
"hooks": [
{
"command": "cas hook SessionStart",
"timeout": 5000,
"type": "command"
}
]
},
{
"hooks": [
{
"command": "cas factory check-staleness",
"timeout": 5000,
"type": "command"
}
]
}
],
"Stop": [
{
"hooks": [
{
"command": "cas hook Stop",
"timeout": 10000,
"type": "command"
}
]
}
],
"SubagentStart": [
{
"hooks": [
{
"async": true,
"command": "cas hook SubagentStart",
"timeout": 2000,
"type": "command"
}
],
"matcher": "task-verifier"
}
],
"SubagentStop": [
{
"hooks": [
{
"async": true,
"command": "cas hook SubagentStop",
"timeout": 5000,
"type": "command"
}
]
}
],
"UserPromptSubmit": [
{
"hooks": [
{
"command": "cas hook UserPromptSubmit",
"timeout": 3000,
"type": "command"
}
]
}
]
},
"permissions": {
"allow": [
"Bash(cas :*)",
"Bash(cas task:*)",
"Bash(cas search:*)",
"Bash(cas add:*)"
"Bash(cas add:*)",
"mcp__cas__task",
"mcp__cas__coordination",
"mcp__cas__memory",
"mcp__cas__search",
"mcp__cas__rule",
"mcp__cas__skill",
"mcp__cas__spec",
"mcp__cas__verification",
"mcp__cas__system",
"mcp__cas__pattern"
]
},
"statusLine": {
"command": "cas statusline",
"type": "command"
}
}
28 changes: 24 additions & 4 deletions .claude/skills/cas-worker/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,38 @@ managed_by: cas

# Factory Worker

You execute tasks assigned by the Supervisor. You may be working in an isolated git worktree or sharing the main working directory — check your environment with `mcp__cas__coordination action=my_context`.
You execute tasks assigned by the Supervisor. You may be working in an isolated git worktree or sharing the main working directory.

## Workflow
## Worktree Mode (Default for Isolated Workers)

If your working directory contains `.cas/worktrees`, you are in an isolated worktree:

- **CAS MCP tools (`mcp__cas__*`) are usually unavailable** — do NOT waste turns retrying
- **Task details come from the supervisor's message** — scroll up
- **Use built-in tools only**: Read, Edit, Write, Bash, Glob, Grep
- **Report completion via `cas factory message`** or `SendMessage`
- **NEVER run** `cas init`, `cas factory`, or any `cas` CLI subcommand in a worktree

On startup, try `mcp__cas__task action=mine` **once only**. If it responds, use the MCP Workflow. Otherwise use the Fallback Workflow immediately.

## Fallback Workflow (No MCP Tools — Most Worktree Workers)

1. **Read the supervisor's assignment message** for task details
2. Implement the solution using built-in tools
3. Commit after each logical unit of work
4. Notify the supervisor: what you did, files changed, commit hash
5. The supervisor handles task closure

## MCP Workflow (When Tools Are Available)

1. Check assignments: `mcp__cas__task action=mine`
2. Start a task: `mcp__cas__task action=start id=<task-id>`
3. Read task details and understand acceptance criteria before coding: `mcp__cas__task action=show id=<task-id>`
3. Read task details: `mcp__cas__task action=show id=<task-id>`
4. Implement the solution, committing after each logical unit of work
5. Report progress: `mcp__cas__task action=notes id=<task-id> notes="..." note_type=progress`
6. Close when done: `mcp__cas__task action=close id=<task-id>`

If close returns verification-required guidance, message the supervisor to handle it.
If close returns verification-required, message the supervisor to handle it.

## Blockers

Expand Down
24 changes: 24 additions & 0 deletions .env.worktree.template
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Worktree environment template
# Generated by: cas worktree create
# Copy to .env.worktree and customize per worktree
#
# SLOT is assigned automatically by cas worktree create
# Use it to derive unique ports for this worktree

# Assigned worktree slot (do not edit)
SLOT={{SLOT}}

# Supervisor: define your port scheme below
# Example port offsets (SLOT * 10):
#
# WEB_PORT=$((3000 + ($SLOT * 10)))
# API_PORT=$((8080 + ($SLOT * 10)))
# DB_PORT=$((5432 + ($SLOT * 10)))
#
# Or use database name isolation (shared postgres):
# DATABASE_NAME=myapp_slot${SLOT}
#
# iOS Simulator UDID (assigned by supervisor or cas worktree create)
# SIM_UDID=

# Add your service-specific env vars below:
Loading
Loading