Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
df07849
feat: surface MCP availability hints and gate MCP tools via config (#…
ksamaschke Nov 17, 2025
abef2d4
fix: allow docs/documentation writes in main scope allowlist (#247)
ksamaschke Nov 18, 2025
9be36e6
chore: add config presets and docs allowlist coverage (#248)
ksamaschke Nov 18, 2025
bcea744
docs: streamline README and docs index (#249)
ksamaschke Nov 18, 2025
cb86910
fix: allow docs heredoc writes without infra blocking (#250)
ksamaschke Nov 18, 2025
0ca9756
feat: inject best practices & memory guidance; keep exec pattern in a…
ksamaschke Nov 18, 2025
a921e85
fix: allow markdown when any path segment is docs (#259)
ksamaschke Nov 18, 2025
d5d2a01
fix: enforce parent-path before markdown segment allowlist (#261)
ksamaschke Nov 19, 2025
e4aa0a2
fix: markdown segment allowlist respects parent-path gate (#262)
ksamaschke Nov 19, 2025
a29073b
fix: enforce infra policy on full command including ssh wrapper (#264)
ksamaschke Nov 19, 2025
837ab56
fix: make doc fast-path allow literal markdown code (#269)
ksamaschke Nov 19, 2025
3611c1b
fix: support nested markdown allowlist segments (#266)
ksamaschke Nov 19, 2025
f91cd0c
feat: linux main-scope friendly config + guardrail defaults (#272)
ksamaschke Nov 19, 2025
294b244
fix: doc fast-path & constraint display (#274)
ksamaschke Nov 19, 2025
1cde3e3
chore: sync dev with main (#275)
ksamaschke Nov 19, 2025
0e213c0
Merge remote-tracking branch 'origin/main' into dev
ksamaschke Nov 19, 2025
a84c600
Merge pull request #276 from intelligentcode-ai/dev-merge-main
ksamaschke Nov 19, 2025
a7b9cbe
feat: main scope agent privilege flag (#278)
ksamaschke Nov 19, 2025
07721fa
Merge dev into main (v8.20.89) (#273) (#280)
ksamaschke Nov 19, 2025
f16e5c9
Merge dev into main (v8.20.89) (#273) (#281)
ksamaschke Nov 19, 2025
48c3567
chore: sync dev into dev-workflows (#283)
ksamaschke Nov 19, 2025
55b9b76
feat: enforce reviewed workflow sequence when enabled
ksamaschke Nov 19, 2025
fb38cc5
fix: match workflow steps against expected tool
ksamaschke Nov 19, 2025
263e8dd
fix: respect agent privileges in project-scope enforcement
ksamaschke Nov 19, 2025
b6ff43b
fix: keep install protection when main scope is agent (#285)
ksamaschke Nov 19, 2025
b6186ad
infra: harden doc fast-path and register workflow hook
ksamaschke Nov 19, 2025
f14ccd5
config: relax project boundary in main-scope-dev preset
ksamaschke Nov 20, 2025
6f1a657
scope: allow parent docs for main-scope-dev and fix marker tests
ksamaschke Nov 20, 2025
2c3691f
pm-constraints: honor env allow_parent_allowlist_paths in markdown fa…
ksamaschke Nov 20, 2025
1ad4b02
Merge pull request #287 from intelligentcode-ai/feature/workflow-doc-…
ksamaschke Nov 20, 2025
5d8dcf9
infra: allow <<- heredoc docs; resolve main merge conflicts
ksamaschke Nov 20, 2025
fc47b3e
pm: let docs bypass pm blacklist fast-path
ksamaschke Nov 20, 2025
0a2d7ef
chore: resolve dev merge conflicts
ksamaschke Nov 20, 2025
b055e1a
Merge pull request #289 from intelligentcode-ai/fix/dev-workflows-merge
ksamaschke Nov 20, 2025
9b8fce2
Merge dev-workflows fixes into dev (#292)
ksamaschke Nov 20, 2025
79c8d7a
infra: ignore destructive keywords inside quotes (allow grep kubectl …
ksamaschke Nov 20, 2025
a314a11
chore: bump version to 8.20.93 (#295)
ksamaschke Nov 20, 2025
66be3e3
infra: markdown allowlisted fast-path; quoted keyword guard; bump 8.2…
ksamaschke Nov 20, 2025
3ea77a9
infra/main-scope: full bypass; codex review reminder enabled in main-…
ksamaschke Nov 21, 2025
19ccd1c
stop: schema-safe output; bump 8.20.95 (#298)
ksamaschke Nov 21, 2025
f8eb0c8
pm: let allowlisted docs bypass PM tool blacklist (#291)
ksamaschke Nov 21, 2025
2a4f6bb
chore: align root VERSION to 8.20.95 (#299)
ksamaschke Nov 21, 2025
0aa594a
chore: bump version to 8.20.96 and align changelog (#301)
ksamaschke Nov 21, 2025
e12e562
infra: respect ICC_TEST_MARKER_DIR; honor env main bypass; block quot…
ksamaschke Nov 21, 2025
586e6a0
infra: align ICC_MAIN_SCOPE_AGENT parsing with other hooks
ksamaschke Nov 21, 2025
a36adec
infra: env false overrides main-scope bypass
ksamaschke Nov 22, 2025
0ef8b89
infra: env override explicitly supports false; remove redundant keywo…
ksamaschke Nov 22, 2025
cdd0a1a
infra: block quoted destructive cmds and align marker cleanup
ksamaschke Nov 23, 2025
9573df2
infra: avoid false positive on quoted markdown heredocs
ksamaschke Nov 23, 2025
e64e452
infra: catch quoted substitutions in doc writes
ksamaschke Nov 23, 2025
8ad7a32
routing: allow memory writes in memory/memories folders
ksamaschke Nov 30, 2025
ddc7db8
Merge pull request #303 from intelligentcode-ai/fix/infra-marker-over…
ksamaschke Dec 2, 2025
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
56 changes: 56 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,62 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).


## [8.20.96] - 2025-11-21

### Fixed
- Align root VERSION with src/VERSION to keep init/version reporting accurate.

### Testing
- `bash tests/run-tests.sh`

## [8.20.95] - 2025-11-20

### Fixed
- Stop hook now outputs schema-compliant JSON only (no auto-review context), preventing validation errors in Stop events.

### Testing
- `bash tests/run-tests.sh`

## [8.20.94] - 2025-11-20

### Fixed
- Infra protection: allow markdown writes in allowlisted dirs (docs/stories/bugs/memory/summaries/agenttasks) even when they live in sibling trees.
- Infra protection: still block markdown writes that contain command substitution, even if keywords are quoted.
- Destructive/write keyword scans now ignore matches that appear only inside quotes, preventing blocks on grep/printf examples.

### Testing
- `bash tests/run-tests.sh`

## [8.20.93] - 2025-11-20

### Fixed
- Infra protection: no longer flags destructive keywords that appear only inside quoted strings (e.g., `grep "kubectl apply"`).

### Testing
- `bash tests/run-tests.sh`

## [8.20.92] - 2025-11-19

### Changed
- Documentation fast-path now requires quoted heredoc delimiters or a substitution-free body; unquoted heredocs with command substitution fall back to full infra checks.
- Marker detection accepts hookInput or path and hashes the active working directory, keeping agent/PM context consistent when agents run from subdirectories.
- Workflow enforcement hook is now registered by default in installer templates (Ansible/PowerShell) raising production hooks to 16.
- Summary ALL-CAPS guard skips paths containing shell variables to avoid false positives on `$SUMMARY_FILE` style redirects.
- `icc.config.main-scope-dev.json` relaxes project boundary (`allow_parent_allowlist_paths: true`) so Main Scope/agents can work in sibling dirs while install protection still blocks `~/.claude`.

### Testing
- `bash tests/run-tests.sh`

## [8.20.91] - 2025-11-19

### Added
- Optional workflow enforcement hook (`workflow-enforcement.js`) that ensures the configured Task → Plan → Review → Execute → Review → Document sequence runs in order for both Main Scope and agents.
- Config support: `workflow.enforcement` block in `icc.config.default.json` plus a ready-to-use `icc.config.workflow-reviewed.json` preset.
- Integration tests for the workflow state machine (uses per-test config/state directories).

### Testing
- `bash tests/run-tests.sh`

## [8.20.90] - 2025-11-19

### Added
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,12 @@ Then work conversationally:
- `config.main-scope.json` – coordination-only main scope (agents execute work)
- `config.strict-main-scope.json` – read-only/Task-only main scope (ultra-safe mode)
- `config.main-scope-dev.json` – Linux/macOS friendly preset where Main Scope may run curated `git`/`gh` commands locally while all guardrails (file naming, folders, git privacy, @codex review, best practices, memory output) remain enabled
- `config.workflow-reviewed.json` – Enables workflow enforcement (Task → Plan → Review → Execute → Review → Document) for Main Scope + agents

See `sample-configs/README.md` for usage instructions and run `make install CONFIG_FILE=sample-configs/<name>.json` to apply one system-wide.

- Toggle `enforcement.main_scope_has_agent_privileges: true` if you want the Main Scope treated exactly like an agent (strict main-scope enforcement, PM-only limits, doc routing, etc. all short-circuit). Default is `false`; `icc.config.main-scope-dev.json` turns it on for systems impacted by the V8 issue.
- Enable `enforcement.workflow` to require the Task → Plan → Review → Execute → Review → Document sequence (see `icc.config.workflow-reviewed.json` for the default step mapping).

## Documentation
- Start: [docs/index.md](docs/index.md)
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.20.90
8.20.96
7 changes: 4 additions & 3 deletions ansible/roles/intelligent-claude-code/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,7 @@
- { type: 'command', command: 'node {{ claude_install_path }}/hooks/agent-infrastructure-protection.js', timeout: 5000 }
- { type: 'command', command: 'node {{ claude_install_path }}/hooks/config-protection.js', timeout: 5000 }
- { type: 'command', command: 'node {{ claude_install_path }}/hooks/pre-agenttask-validation.js', timeout: 5000 }
- { type: 'command', command: 'node {{ claude_install_path }}/hooks/workflow-enforcement.js', timeout: 5000 }
- { type: 'command', command: 'node {{ claude_install_path }}/hooks/project-scope-enforcement.js', timeout: 5000 }
- { type: 'command', command: 'node {{ claude_install_path }}/hooks/summary-file-enforcement.js', timeout: 5000 }
SessionStart:
Expand Down Expand Up @@ -365,13 +366,13 @@

- name: Report hook registration
debug:
msg: "All 15 production hooks configured in settings.json - comprehensive enforcement active"
msg: "All 16 production hooks configured in settings.json - comprehensive enforcement active"

when: settings_json_exists.stat.exists

- name: Display settings creation notice
debug:
msg: "Settings file created with all 15 production hooks - comprehensive enforcement active"
msg: "Settings file created with all 16 production hooks - comprehensive enforcement active"
when: not settings_json_exists.stat.exists and ansible_verbosity >= 1

# badges.md file removed - scoring system simplified to clean progress reporting
Expand All @@ -389,5 +390,5 @@
- "✅ Installation complete!"
- "📍 Location: {{ claude_install_path }}"
- "🤖 Virtual Team: 14 core roles + unlimited specialists"
- "🔒 Behavioral Hooks: All 15 production hooks active (PreToolUse, UserPromptSubmit, SubagentStop, Stop)"
- "🔒 Behavioral Hooks: All 16 production hooks active (PreToolUse, UserPromptSubmit, SubagentStop, Stop)"
- "🚀 Use @Role communication to activate team members"
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@
"type": "command",
"command": "node {{ claude_install_path }}/hooks/pre-agenttask-validation.js",
"timeout": 5000
}, {
"type": "command",
"command": "node {{ claude_install_path }}/hooks/workflow-enforcement.js",
"timeout": 5000
}, {
"type": "command",
"command": "node {{ claude_install_path }}/hooks/project-scope-enforcement.js",
Expand Down Expand Up @@ -78,4 +82,4 @@
}]
}]
}
}
}
11 changes: 11 additions & 0 deletions icc.config.default.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,17 @@
"violation_logging": true,
"auto_correction": true,
"main_scope_has_agent_privileges": false,
"workflow": {
"enabled": false,
"steps": [
{ "name": "Task", "tools": ["Task"] },
{ "name": "Plan", "tools": ["Plan"] },
{ "name": "Review Plan", "tools": ["Review"] },
{ "name": "Execute", "tools": ["Execute"] },
{ "name": "Review Execute", "tools": ["Review"] },
{ "name": "Document", "tools": ["Document", "Write", "Edit"] }
]
},
"strict_main_scope": true,
"strict_main_scope_message": "Main scope is limited to coordination work only. Create AgentTasks via Task tool for all technical operations.",
"pm_allowed_bash_commands": [
Expand Down
7 changes: 4 additions & 3 deletions install.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ function Register-ProductionHooks {
)

try {
Write-Host " Registering all 15 production hooks in settings.json..." -ForegroundColor Gray
Write-Host " Registering all 16 production hooks in settings.json..." -ForegroundColor Gray

# Load or create settings
$Settings = Get-SettingsJson -SettingsPath $SettingsPath
Expand All @@ -189,6 +189,7 @@ function Register-ProductionHooks {
[PSCustomObject]@{ type = "command"; command = "node `"$HooksPath\agent-marker.js`""; timeout = 5000 }
[PSCustomObject]@{ type = "command"; command = "node `"$HooksPath\config-protection.js`""; timeout = 5000 }
[PSCustomObject]@{ type = "command"; command = "node `"$HooksPath\pre-agenttask-validation.js`""; timeout = 5000 }
[PSCustomObject]@{ type = "command"; command = "node `"$HooksPath\workflow-enforcement.js`""; timeout = 5000 }
[PSCustomObject]@{ type = "command"; command = "node `"$HooksPath\project-scope-enforcement.js`""; timeout = 5000 }
[PSCustomObject]@{ type = "command"; command = "node `"$HooksPath\summary-file-enforcement.js`""; timeout = 5000 }
)
Expand Down Expand Up @@ -238,7 +239,7 @@ function Register-ProductionHooks {
$JsonOutput = $Settings | ConvertTo-Json -Depth 10
Set-Content -Path $SettingsPath -Value $JsonOutput -Encoding UTF8

Write-Host " ✅ All 15 production hooks registered successfully in settings.json" -ForegroundColor Green
Write-Host " ✅ All 16 production hooks registered successfully in settings.json" -ForegroundColor Green

} catch {
Write-Warning " Failed to register production hooks in settings.json: $($_.Exception.Message)"
Expand All @@ -254,7 +255,7 @@ function Install-HookSystem {
[string]$SourceDir
)

Write-Host "Installing hook system (15 production hooks)..." -ForegroundColor Yellow
Write-Host "Installing hook system (16 production hooks)..." -ForegroundColor Yellow

try {
# Create hooks directory structure
Expand Down
5 changes: 3 additions & 2 deletions sample-configs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@ Configs included (all prefixed `icc.config.*`)
- `icc.config.relaxed.json` — Looser for local hacking: markdown outside allowlist permitted, parent paths allowed, blocking disabled.
- `icc.config.strict-main-scope.json` — Hard lock for Main Scope: no Write/Edit/Bash; delegation only; agents perform work under standard path restrictions.
- `icc.config.local-backup.json` — Snapshot of the previously active local config (before switching to the main-scope variant). Safety copy only.
- `icc.config.main-scope-dev.json` — Linux-friendly profile where Main Scope can run curated git/gh commands (e.g., merging PRs) without spawning agents; guardrails, privacy, and @codex review reminder remain enabled.
- `icc.config.main-scope-dev.json` — Linux-friendly profile where Main Scope can run curated git/gh commands (e.g., merging PRs) without spawning agents; guardrails, privacy, and @codex review reminder remain enabled. Project boundary is relaxed (`allow_parent_allowlist_paths: true`) so Main Scope/agents can work in sibling directories while still blocking `~/.claude`.
- `icc.config.workflow-reviewed.json` — Enables workflow enforcement (Task → Plan → Review → Execute → Review → Document) for both Main Scope and agents.

Main-scope agent privileges
- The new `enforcement.main_scope_has_agent_privileges` flag controls whether the Main Scope is treated like an agent (skips PM-only write limits, uses the agent allowlists). All presets keep it `false` except `icc.config.main-scope-dev.json`, which sets it to `true` so Ops/Dev work can run directly from the Main Scope.
- The `enforcement.main_scope_has_agent_privileges` flag controls whether the Main Scope is treated like an agent (skips PM-only write limits, uses the agent allowlists). All presets keep it `false` except `icc.config.main-scope-dev.json`, which sets it to `true` so Ops/Dev work can run directly from the Main Scope.

How the PR review reminder is activated
- Each config sets `enforcement.require_codex_review_comment: true`.
Expand Down
8 changes: 7 additions & 1 deletion sample-configs/icc.config.main-scope-dev.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,16 @@
"enforcement": {
"blocking_enabled": true,
"strict_main_scope": false,
"allow_parent_allowlist_paths": false,
"allow_parent_allowlist_paths": true,
"allow_markdown_outside_allowlist": false,
"allow_markdown_outside_allowlist_agents": false,
"main_scope_has_agent_privileges": true,
"output_constraints_and_best_practices": true,
"output_best_practices": true,
"auto_commit_review": {
"enabled": true,
"command": "@codex review"
},
"heredoc_allowed_commands": ["git", "gh", "glab", "hub"],
"pm_allowed_bash_commands": ["gh pr list", "gh pr view", "gh pr status"],
"main_scope_allowed_bash_commands": [
Expand Down
17 changes: 17 additions & 0 deletions sample-configs/icc.config.workflow-reviewed.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"enforcement": {
"blocking_enabled": true,
"main_scope_has_agent_privileges": false,
"workflow": {
"enabled": true,
"steps": [
{ "name": "Task", "tools": ["Task"] },
{ "name": "Plan", "tools": ["Plan"] },
{ "name": "Review Plan", "tools": ["Review"] },
{ "name": "Execute", "tools": ["Execute"] },
{ "name": "Review Execute", "tools": ["Review"] },
{ "name": "Document", "tools": ["Document", "Write", "Edit"] }
]
}
}
}
2 changes: 1 addition & 1 deletion src/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.20.90
8.20.96
Loading