@heretek-ai/epistemic-swarm 0.7.23 → 0.7.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +1 -1
- package/package.json +1 -1
- package/plugins/antigravity/README.md +19 -10
- package/plugins/antigravity/antigravity_hooks.py +118 -20
- package/plugins/antigravity/commands/audit.md +6 -5
- package/plugins/antigravity/commands/brainstorm.md +9 -0
- package/plugins/antigravity/commands/brainstorming.md +6 -8
- package/plugins/antigravity/commands/darkharvest.md +6 -5
- package/plugins/antigravity/commands/domainexpansion.md +8 -5
- package/plugins/antigravity/commands/factory.md +10 -5
- package/plugins/antigravity/commands/grill.md +6 -5
- package/plugins/antigravity/commands/scout.md +6 -5
- package/plugins/antigravity/commands/swarm-config.md +4 -5
- package/plugins/antigravity/commands/swarm.md +6 -3
- package/plugins/antigravity/hook_bus_bridge.js +352 -0
- package/plugins/antigravity/hooks.json +1 -1
- package/plugins/antigravity/plugin.json +1 -1
- package/plugins/opencode/analysis-bridge.js +86 -32
- package/plugins/opencode/hook-bus.js +81 -19
- package/plugins/opencode/index.js +6 -9
- package/plugins/opencode/weight-signals.js +2 -2
- package/prompts/agent_brainstormer.md +29 -0
- package/prompts/agent_darkharvest.md +30 -0
- package/runner/__pycache__/__init__.cpython-311.pyc +0 -0
- package/runner/__pycache__/auctioneer.cpython-311.pyc +0 -0
- package/runner/__pycache__/auditor_engine.cpython-311.pyc +0 -0
- package/runner/__pycache__/claim_store.cpython-311.pyc +0 -0
- package/runner/__pycache__/claim_witness.cpython-311.pyc +0 -0
- package/runner/__pycache__/darkharvest_claims.cpython-311.pyc +0 -0
- package/runner/__pycache__/errors.cpython-311.pyc +0 -0
- package/runner/__pycache__/living_dossiers.cpython-311.pyc +0 -0
- package/runner/__pycache__/mcp_protocol.cpython-311.pyc +0 -0
- package/runner/__pycache__/mcp_server.cpython-311.pyc +0 -0
- package/runner/__pycache__/path_safety.cpython-311.pyc +0 -0
- package/runner/__pycache__/pcrb.cpython-311.pyc +0 -0
- package/runner/__pycache__/pcrb_verify.cpython-311.pyc +0 -0
- package/runner/__pycache__/preflight.cpython-311.pyc +0 -0
- package/runner/__pycache__/refinement.cpython-311.pyc +0 -0
- package/runner/__pycache__/research_swarm.cpython-311.pyc +0 -0
- package/runner/__pycache__/retrieval_log.cpython-311.pyc +0 -0
- package/runner/__pycache__/schema_validate.cpython-311.pyc +0 -0
- package/runner/__pycache__/schemas.cpython-311.pyc +0 -0
- package/runner/__pycache__/state_machine.cpython-311.pyc +0 -0
- package/runner/antigravity_hooks.py +118 -20
- package/runner/auditor_engine.py +194 -44
- package/runner/claim_store.py +64 -20
- package/runner/claim_witness.py +243 -14
- package/runner/pcrb.py +34 -11
- package/runner/refinement.py +140 -31
- package/runner/schemas.py +2 -0
- package/runner/tests/__pycache__/test_analysis_bridge.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_antigravity_plugin.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_auction_order.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_backends.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_bet1_spike.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_claim_store.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_claim_witness.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_claude_plugin.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_config_schema.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_contract_tooling.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_darkharvest_audit.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_dep_health.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_domain_packs.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_dossier_contract.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_factory.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_fleet_seam.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_frontier_concurrency.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_frontier_mirror_standalone.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_grounding.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_hardening_contract.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_hook_bus.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_living_dossiers.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_manifest_concurrency.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_mcp_server.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_nk_hardening.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_opencode_ux.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_opencode_v2_registrars.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_pcrb.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_phase08_waiver_reopens.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_refinement.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_search_anomaly.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_search_provider.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_search_provider_plugin.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_swarm.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_swarm_config.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_sweep_regressions.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_webcache.cpython-311.pyc +0 -0
- package/runner/tests/__pycache__/test_weight_signals.cpython-311.pyc +0 -0
- package/runner/tests/test_analysis_bridge.py +95 -1
- package/runner/tests/test_antigravity_plugin.py +164 -9
- package/runner/tests/test_dep_health.py +111 -0
- package/runner/tests/test_hook_bus.py +161 -7
- package/runner/tests/test_nk_hardening.py +1046 -0
- package/runner/tests/test_weight_signals.py +40 -0
- package/schemas/audit_report.schema.json +3 -0
- package/scripts/__pycache__/bet1_advisory_spike.cpython-311.pyc +0 -0
- package/scripts/__pycache__/build_adapters.cpython-311.pyc +0 -0
- package/scripts/__pycache__/check_docs.cpython-311.pyc +0 -0
- package/scripts/__pycache__/divergence_experiment.cpython-311.pyc +0 -0
- package/scripts/__pycache__/gen_schemas.cpython-311.pyc +0 -0
- package/scripts/build_adapters.py +1 -0
- package/skills/epistemic_search/scripts/__pycache__/search.cpython-311.pyc +0 -0
- package/skills/grilling/__pycache__/__init__.cpython-311.pyc +0 -0
- package/skills/grilling/__pycache__/socratic_tree.cpython-311.pyc +0 -0
- package/skills/research_cache/__pycache__/__init__.cpython-311.pyc +0 -0
- package/skills/research_cache/__pycache__/hasher.cpython-311.pyc +0 -0
- package/skills/swarm_config/__pycache__/__init__.cpython-311.pyc +0 -0
- package/skills/swarm_config/__pycache__/configure.cpython-311.pyc +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@heretek-ai/epistemic-swarm",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.24",
|
|
4
4
|
"description": "IUMBTEMS (Epistemic Swarm) \u2014 High-Integrity Dialectic Research Agent Harness for Claude Code, OpenCode V2, Pi (pi.dev), OMP (oh-my-pi), Gemini CLI, Codex CLI, and AntiGravity",
|
|
5
5
|
"main": "bin/cli.js",
|
|
6
6
|
"bin": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# IUMBTEMS for AntiGravity
|
|
2
2
|
|
|
3
|
-
First-class native AntiGravity plugin (`agy`) delivering dialectic research, architecture auditing, competitor teardowns, lateral brainstorming, and
|
|
3
|
+
First-class native AntiGravity plugin (`agy`) delivering dialectic research, architecture auditing, competitor teardowns, lateral brainstorming, Socratic planning, and automated quality gates.
|
|
4
4
|
|
|
5
5
|
## Installation
|
|
6
6
|
|
|
@@ -22,13 +22,16 @@ agy plugin validate /path/to/IUMBTEMS/plugins/antigravity
|
|
|
22
22
|
|
|
23
23
|
```text
|
|
24
24
|
plugins/antigravity/
|
|
25
|
-
├── plugin.json
|
|
26
|
-
├── hooks.json
|
|
27
|
-
├──
|
|
28
|
-
├──
|
|
29
|
-
├──
|
|
30
|
-
├──
|
|
31
|
-
|
|
25
|
+
├── plugin.json # Manifest conforming to https://antigravity.google/schemas/v1/plugin.json
|
|
26
|
+
├── hooks.json # PreToolUse, PreInvocation, PostToolUse, and Stop lifecycle hooks
|
|
27
|
+
├── antigravity_hooks.py # Python lifecycle dispatcher with zero-overhead fast-paths
|
|
28
|
+
├── hook_bus_bridge.js # 6-event Hook Bus & Quality Gates bridge (Analysis, Dep Health, Weight)
|
|
29
|
+
├── mcp_config.json # First-party stdio MCP server (17 iumbtems_* tools) + search fallbacks
|
|
30
|
+
├── mcp_launcher.py # MCP runtime launcher and environment resolver
|
|
31
|
+
├── commands/ # Interactive slash commands (/audit, /swarm, /grill, /factory, etc.)
|
|
32
|
+
├── agents/ # Specialized subagents (alpha-thesis, beta-antithesis, auditor, etc.)
|
|
33
|
+
├── rules/ # Workspace rules (AGENTS.md and epistemic-integrity.md)
|
|
34
|
+
└── skills/ # Generated skill stubs for progressive disclosure
|
|
32
35
|
```
|
|
33
36
|
|
|
34
37
|
## Slash Commands
|
|
@@ -40,6 +43,7 @@ In the `agy` TUI prompt box, type `/` to access commands:
|
|
|
40
43
|
- `/factory <action>`: Phased engineering factory with dual QA gating.
|
|
41
44
|
- `/scout <feature>`: Open-source package discovery and copyleft license auditing.
|
|
42
45
|
- `/brainstorming <prompt>`: Divergent lateral ideation and falsifiable spikes.
|
|
46
|
+
- `/brainstorm <prompt>`: Alias for `/brainstorming`.
|
|
43
47
|
- `/domainexpansion <query>`: Domain pack discovery and frontier synthesis.
|
|
44
48
|
- `/swarm-config`: Interactive inspection and configuration of research parameters.
|
|
45
49
|
|
|
@@ -57,7 +61,12 @@ Manage and delegate to specialized subagents using the `/agents` panel or `Alt+J
|
|
|
57
61
|
- `qa-a`: Functional QA (verifies acceptance criteria).
|
|
58
62
|
- `qa-b`: Adversarial QA (hunts edge cases and loopholes).
|
|
59
63
|
|
|
60
|
-
## Lifecycle Interception &
|
|
64
|
+
## Lifecycle Interception & Quality Gates
|
|
61
65
|
- **Search Interception**: Web searches and fetches are intercepted to ensure citations are content-addressed and stored in `.research/sources/<sha256>.md`.
|
|
62
|
-
- **
|
|
66
|
+
- **PreCommit Gating**: File writes to `.research/config.json` are gated by schema validation and `expected_hash` optimistic concurrency.
|
|
67
|
+
- **Analysis Bridge**: Advisory Biome static analysis checks modified JS/TS files in fast tier.
|
|
68
|
+
- **Dependency Health**: Advisory OSV.dev vulnerability auditing scans npm, pip, Dockerfile, and GitHub Actions dependencies.
|
|
69
|
+
- **Weight Signals**: Advisory esbuild bundling tracks package weight and coverage deltas against checked-in baselines.
|
|
70
|
+
- **Compaction Preservation**: Preserves `.research` state (mode, engine, depth, degraded claims, requeued scopes) across context compaction turns.
|
|
71
|
+
- **Termination Gating**: The agent loop is gated from stopping prematurely if unresolved claims (`STALE`/`SUSPECT`) or failing gates remain in `.research/`.
|
|
63
72
|
- **MCP Tools**: All 17 canonical `iumbtems_*` tools are exposed via `runner/mcp_server.py`.
|
|
@@ -3,7 +3,13 @@
|
|
|
3
3
|
Antigravity Lifecycle Hook Interceptor & Epistemic Gate Bridge.
|
|
4
4
|
|
|
5
5
|
Binds Antigravity's lifecycle events (PreToolUse, PreInvocation, PostToolUse, Stop)
|
|
6
|
-
to IUMBTEMS's epistemic evidence verification pipeline
|
|
6
|
+
to IUMBTEMS's epistemic evidence verification pipeline and the 6-event Hook Bus:
|
|
7
|
+
1. Analysis Bridge (Biome CLI static analysis for JS/TS)
|
|
8
|
+
2. Dependency Health Gate (OSV.dev vulnerability & freshness scanner)
|
|
9
|
+
3. Weight Signals (esbuild bundle weight & coverage deltas vs baseline)
|
|
10
|
+
4. Pre-commit gating on .research/config.json with optimistic concurrency (expected_hash)
|
|
11
|
+
5. Session context & compaction preservation (buildCompactionContext)
|
|
12
|
+
6. Living dossier claim degradation stop-gating
|
|
7
13
|
|
|
8
14
|
Contract Invariants:
|
|
9
15
|
- Input is received as JSON on stdin (camelCase per Antigravity hook protojson).
|
|
@@ -14,15 +20,19 @@ Contract Invariants:
|
|
|
14
20
|
|
|
15
21
|
import json
|
|
16
22
|
import os
|
|
23
|
+
import shutil
|
|
24
|
+
import subprocess
|
|
17
25
|
import sys
|
|
18
26
|
from pathlib import Path
|
|
19
|
-
from typing import Any, Dict
|
|
27
|
+
from typing import Any, Dict, List, Optional
|
|
20
28
|
|
|
21
29
|
|
|
22
30
|
def _get_workspace_dir(payload: Dict[str, Any]) -> Path:
|
|
23
31
|
workspaces = payload.get("workspacePaths", [])
|
|
24
|
-
if workspaces:
|
|
32
|
+
if workspaces and workspaces[0]:
|
|
25
33
|
return Path(workspaces[0]).resolve()
|
|
34
|
+
if payload.get("workspaceRoot"):
|
|
35
|
+
return Path(payload["workspaceRoot"]).resolve()
|
|
26
36
|
if "IUMBTEMS_WORKSPACE" in os.environ:
|
|
27
37
|
return Path(os.environ["IUMBTEMS_WORKSPACE"]).resolve()
|
|
28
38
|
if "IUMBTEMS_ROOT" in os.environ:
|
|
@@ -34,6 +44,48 @@ def _get_workspace_dir(payload: Dict[str, Any]) -> Path:
|
|
|
34
44
|
return curr
|
|
35
45
|
|
|
36
46
|
|
|
47
|
+
def _find_hook_bus_bridge(workspace_dir: Path) -> Optional[Path]:
|
|
48
|
+
script_dir = Path(__file__).resolve().parent
|
|
49
|
+
candidates = [
|
|
50
|
+
script_dir / "hook_bus_bridge.js",
|
|
51
|
+
script_dir.parent / "antigravity" / "hook_bus_bridge.js",
|
|
52
|
+
workspace_dir / "plugins" / "antigravity" / "hook_bus_bridge.js",
|
|
53
|
+
]
|
|
54
|
+
for c in candidates:
|
|
55
|
+
if c.is_file():
|
|
56
|
+
return c
|
|
57
|
+
return None
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
def _run_node_bridge(action: str, payload: Dict[str, Any], timeout: int = 5) -> Dict[str, Any]:
|
|
61
|
+
try:
|
|
62
|
+
node_bin = shutil.which("node")
|
|
63
|
+
if not node_bin:
|
|
64
|
+
return {}
|
|
65
|
+
workspace_dir = _get_workspace_dir(payload)
|
|
66
|
+
bridge_script = _find_hook_bus_bridge(workspace_dir)
|
|
67
|
+
if not bridge_script:
|
|
68
|
+
return {}
|
|
69
|
+
|
|
70
|
+
proc = subprocess.run(
|
|
71
|
+
[node_bin, str(bridge_script), action],
|
|
72
|
+
input=json.dumps(payload),
|
|
73
|
+
capture_output=True,
|
|
74
|
+
text=True,
|
|
75
|
+
timeout=timeout,
|
|
76
|
+
cwd=str(workspace_dir),
|
|
77
|
+
)
|
|
78
|
+
if proc.returncode == 0 and proc.stdout.strip():
|
|
79
|
+
# Parse the last line starting with { to avoid node warnings
|
|
80
|
+
for line in reversed(proc.stdout.strip().splitlines()):
|
|
81
|
+
line = line.strip()
|
|
82
|
+
if line.startswith("{") and line.endswith("}"):
|
|
83
|
+
return json.loads(line)
|
|
84
|
+
except Exception:
|
|
85
|
+
pass
|
|
86
|
+
return {}
|
|
87
|
+
|
|
88
|
+
|
|
37
89
|
def _read_stdin_payload() -> Dict[str, Any]:
|
|
38
90
|
try:
|
|
39
91
|
content = sys.stdin.read()
|
|
@@ -45,10 +97,12 @@ def _read_stdin_payload() -> Dict[str, Any]:
|
|
|
45
97
|
|
|
46
98
|
|
|
47
99
|
def handle_pre_tool(payload: Dict[str, Any]) -> Dict[str, Any]:
|
|
48
|
-
"""Intercept ungrounded search/fetch
|
|
100
|
+
"""Intercept ungrounded search/fetch, pre-commit config edits, and pre-tool hooks."""
|
|
49
101
|
tool_call = payload.get("toolCall", {})
|
|
50
102
|
name = str(tool_call.get("name", "")).lower()
|
|
103
|
+
args = tool_call.get("args", {})
|
|
51
104
|
|
|
105
|
+
# 1. Epistemic Search & Fetch Quarantine (<1ms fast-path)
|
|
52
106
|
if "search_web" in name or "websearch" in name:
|
|
53
107
|
return {
|
|
54
108
|
"decision": "deny",
|
|
@@ -69,27 +123,58 @@ def handle_pre_tool(payload: Dict[str, Any]) -> Dict[str, Any]:
|
|
|
69
123
|
),
|
|
70
124
|
}
|
|
71
125
|
|
|
126
|
+
# 2. Mutating tool calls: run pre-commit config check & hook bus
|
|
127
|
+
target_file = str(args.get("TargetFile") or args.get("file") or args.get("path") or "")
|
|
128
|
+
is_mutating = name in ("write_to_file", "replace_file_content", "run_command")
|
|
129
|
+
|
|
130
|
+
if is_mutating or (".research" in target_file):
|
|
131
|
+
bridge_res = _run_node_bridge("pre_tool", payload, timeout=3)
|
|
132
|
+
if bridge_res.get("decision") == "deny" or bridge_res.get("allowed") is False:
|
|
133
|
+
return {
|
|
134
|
+
"decision": "deny",
|
|
135
|
+
"reason": bridge_res.get("reason", "Blocked by Pre-Commit quality gate"),
|
|
136
|
+
}
|
|
137
|
+
|
|
72
138
|
return {"decision": "allow"}
|
|
73
139
|
|
|
74
140
|
|
|
75
141
|
def handle_pre_invocation(payload: Dict[str, Any]) -> Dict[str, Any]:
|
|
76
|
-
"""Inject ephemeral evidence tagging constraints
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
"
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
142
|
+
"""Inject ephemeral evidence tagging constraints, compaction context, and quality gate notices."""
|
|
143
|
+
inject_steps: List[Dict[str, Any]] = [
|
|
144
|
+
{
|
|
145
|
+
"ephemeralMessage": (
|
|
146
|
+
"[EPISTEMIC INTEGRITY] Every factual claim must carry "
|
|
147
|
+
"[VERIFIED: <sha256>] (verbatim quote in .research/sources/<hash>.md), "
|
|
148
|
+
"[INFERRED: <parents>], [HYPOTHESIS: <test>], or [NEGATIVE_KNOWLEDGE: <query>]. "
|
|
149
|
+
"Unverified parametric recall is strictly quarantined."
|
|
150
|
+
)
|
|
151
|
+
}
|
|
152
|
+
]
|
|
153
|
+
|
|
154
|
+
# Query Node bridge for compaction context and pending quality gate annotations
|
|
155
|
+
bridge_res = _run_node_bridge("pre_invocation", payload, timeout=3)
|
|
156
|
+
compaction = bridge_res.get("compactionContext")
|
|
157
|
+
if compaction and isinstance(compaction, str):
|
|
158
|
+
inject_steps.append({"ephemeralMessage": compaction})
|
|
159
|
+
|
|
160
|
+
annotations = bridge_res.get("annotations") or []
|
|
161
|
+
if annotations and isinstance(annotations, list):
|
|
162
|
+
notices = []
|
|
163
|
+
for a in annotations:
|
|
164
|
+
if isinstance(a, dict) and a.get("reason"):
|
|
165
|
+
notices.append(f"- {a.get('handler', 'QualityGate')}: {a['reason']}")
|
|
166
|
+
elif isinstance(a, str):
|
|
167
|
+
notices.append(f"- {a}")
|
|
168
|
+
if notices:
|
|
169
|
+
inject_steps.append({
|
|
170
|
+
"ephemeralMessage": "[QUALITY GATES ADVISORY]\n" + "\n".join(notices)
|
|
171
|
+
})
|
|
172
|
+
|
|
173
|
+
return {"injectSteps": inject_steps}
|
|
89
174
|
|
|
90
175
|
|
|
91
176
|
def handle_post_tool(payload: Dict[str, Any]) -> Dict[str, Any]:
|
|
92
|
-
"""Log tool completions
|
|
177
|
+
"""Log tool completions, record negative knowledge, and dispatch to quality gates."""
|
|
93
178
|
try:
|
|
94
179
|
workspace_dir = _get_workspace_dir(payload)
|
|
95
180
|
research_dir = workspace_dir / ".research"
|
|
@@ -104,19 +189,24 @@ def handle_post_tool(payload: Dict[str, Any]) -> Dict[str, Any]:
|
|
|
104
189
|
}
|
|
105
190
|
with log_file.open("a", encoding="utf-8") as f:
|
|
106
191
|
f.write(json.dumps(entry) + "\n")
|
|
192
|
+
|
|
193
|
+
tool_call = payload.get("toolCall", {})
|
|
194
|
+
name = str(tool_call.get("name", "")).lower()
|
|
195
|
+
if name in ("write_to_file", "replace_file_content", "run_command"):
|
|
196
|
+
_run_node_bridge("post_tool", payload, timeout=4)
|
|
107
197
|
except Exception:
|
|
108
198
|
pass
|
|
109
199
|
return {}
|
|
110
200
|
|
|
111
201
|
|
|
112
202
|
def handle_stop(payload: Dict[str, Any]) -> Dict[str, Any]:
|
|
113
|
-
"""Prevent agent from terminating if an active swarm run has unverified claims."""
|
|
203
|
+
"""Prevent agent from terminating if an active swarm run has unverified claims or unsettled gates."""
|
|
114
204
|
try:
|
|
115
205
|
workspace_dir = _get_workspace_dir(payload)
|
|
116
206
|
research_dir = workspace_dir / ".research"
|
|
117
207
|
|
|
118
208
|
# If a STOP signal file was placed by user or factory, respect it immediately
|
|
119
|
-
factory_stop =
|
|
209
|
+
factory_stop = workspace_dir / ".factory" / "STOP"
|
|
120
210
|
if factory_stop.exists():
|
|
121
211
|
return {"decision": "allow"}
|
|
122
212
|
|
|
@@ -139,6 +229,14 @@ def handle_stop(payload: Dict[str, Any]) -> Dict[str, Any]:
|
|
|
139
229
|
}
|
|
140
230
|
except Exception:
|
|
141
231
|
pass
|
|
232
|
+
|
|
233
|
+
# Query Node hook bus bridge for stop event denial
|
|
234
|
+
bridge_res = _run_node_bridge("stop", payload, timeout=3)
|
|
235
|
+
if bridge_res.get("decision") == "continue" or bridge_res.get("allowed") is False:
|
|
236
|
+
return {
|
|
237
|
+
"decision": "continue",
|
|
238
|
+
"reason": bridge_res.get("reason", "Blocked by Hook Bus stop policy"),
|
|
239
|
+
}
|
|
142
240
|
except Exception:
|
|
143
241
|
pass
|
|
144
242
|
return {"decision": "allow"}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
---
|
|
2
|
-
description:
|
|
2
|
+
description: Run dialectic codebase architectural and security audit with line-level proof
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Run
|
|
5
|
+
Run an IUMBTEMS dialectic codebase audit (structural architect vs adversarial red-teamer).
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Target: $ARGUMENTS (path, component, or empty for full-repository architecture and vulnerability audit)
|
|
8
|
+
If $ARGUMENTS names a path that does not exist, ask the user to clarify the target first; never audit a placeholder path.
|
|
8
9
|
|
|
9
|
-
|
|
10
|
-
|
|
10
|
+
1. Execute `iumbtems_code_audit` with `{"target": "<target>"}` (or `python3 runner/research_swarm.py --mode audit --objective "$ARGUMENTS"`).
|
|
11
|
+
2. Summarize `.research/code_audit_report.md` with line-level proof pointers (`file:///path#Lstart-Lend`) and concrete remediation blueprints.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Alias for /brainstorming
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
Alias for /brainstorming: run lateral brainstorming (divergent what-if ideation, never bug-fix lists).
|
|
6
|
+
|
|
7
|
+
Prompt: $ARGUMENTS (defaults to "Where do we go from here?" when empty)
|
|
8
|
+
|
|
9
|
+
Execute `iumbtems_brainstorm` with {"objective": "$ARGUMENTS"} and report feature vectors, paradigm inversions, and falsifiable spikes.
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Lateral brainstorming
|
|
2
|
+
description: Lateral brainstorming: novel feature vectors, paradigm inversions, falsifiable spikes
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Run
|
|
6
|
-
and `prompts/agent_brainstormer.md`):
|
|
5
|
+
Run lateral brainstorming (divergent what-if ideation, never bug-fix lists).
|
|
7
6
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
4. Write `.research/brainstorm_report.md` (or run `python3 runner/research_swarm.py --mode brainstorm --objective "$1"`).
|
|
7
|
+
Prompt: $ARGUMENTS (defaults to "Where do we go from here?" when empty)
|
|
8
|
+
|
|
9
|
+
1. Execute `iumbtems_brainstorm` with `{"objective": "<prompt>"}` (or `python3 runner/research_swarm.py --mode brainstorm --objective "$ARGUMENTS"`).
|
|
10
|
+
2. Report novel feature vectors, paradigm inversions, and falsifiable spikes (`[HYPOTHESIS:<test>]`) from `.research/brainstorm_report.md`.
|
|
@@ -2,10 +2,11 @@
|
|
|
2
2
|
description: Product competitor teardown with per-feature harvest verdicts
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Run a product competitor teardown
|
|
5
|
+
Run a product competitor teardown (seed inspirations plus prompt, expand to adjacents).
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Objective: $ARGUMENTS (product arena; seeds may be embedded as URLs)
|
|
8
|
+
If $ARGUMENTS is empty, ask the user for the product arena and seed URLs first; never call with placeholder arguments.
|
|
8
9
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
1. Execute `iumbtems_darkharvest` with `{"objective": "<objective>", "seeds": ["<url>", "..."]}` (or `python3 runner/research_swarm.py --mode darkharvest --objective "$ARGUMENTS"`).
|
|
11
|
+
2. Report the competitor x capability matrix, white-space gaps both ways, and the SPDX-attributed harvest backlog in `.research/darkharvest_report.md`.
|
|
12
|
+
3. Legal rule: permissive-only vendor; GPL/AGPL clean-room-rebuild only; workflows clonable, assets never.
|
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Autonomous agent-guided self-improvement loop (count-flagged)
|
|
2
|
+
description: Autonomous agent-guided self-improvement loop over the codebase (count-flagged)
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Run the IUMBTEMS domain-expansion loop
|
|
5
|
+
Run the IUMBTEMS domain-expansion loop as the manager agent.
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
Loops: $ARGUMENTS (integer count, max 10)
|
|
8
|
+
If $ARGUMENTS is not a positive integer, ask the user for the loop count first.
|
|
9
|
+
|
|
10
|
+
1. Bypass per-loop gates; stop on count OR .factory/STOP file OR user kill, whichever first (enforce via the `iumbtems_factory` tool, command: expansion, with loops/max_loops).
|
|
11
|
+
2. Each loop: agents propose direction, quick `iumbtems_brainstorm`/`iumbtems_darkharvest` check, implement via programmer spawn, dual-QA verify.
|
|
12
|
+
3. All expansion proposals carry the strict VERIFIED evidence bar; log every loop to `.factory/state.json`.
|
|
@@ -1,9 +1,14 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Coding-factory Manager loop
|
|
2
|
+
description: Coding-factory Manager loop: grill-gated phased build with programmer spawns and dual QA
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Run the IUMBTEMS coding-factory Manager loop
|
|
5
|
+
Run the IUMBTEMS coding-factory Manager loop as the manager agent.
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
Arena: $ARGUMENTS
|
|
8
|
+
If $ARGUMENTS is empty, ask the user what to build first; never proceed on placeholder input.
|
|
9
|
+
|
|
10
|
+
1. Grill the user until `.factory/frontier.json` is settled (max 5 brainstorm+darkharvest swarm cycles per gate); explicit user approve advances each gate.
|
|
11
|
+
2. Per gate run `iumbtems_brainstorm` and `iumbtems_darkharvest` (mock_mode only for dry runs), then synthesize `.roadmap/<phase>/` GOAL.md + dossier.json (goal/evidence/acceptance/brief/verdict/hashes; every claim needs a VERIFIED hash).
|
|
12
|
+
3. Spawn the programmer subagent per phase with the phase dossier (cite phase hashes); run qa-a and qa-b (diverged prompts) per phase; track retries with the `iumbtems_factory` tool (command: phase-add / qa-record; 3 failures escalate to manager). Never invoke factory helper scripts by relative path.
|
|
13
|
+
4. Manager tiebreaks QA disagreements; explicit user sign-off closes each phase.
|
|
14
|
+
Swarm agents use the host-native backend automatically. Do not debug backend selection, config pins, or binary availability as part of a gate — if a swarm call fails, report the error and continue.
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Socratic grilling and decision frontier exploration
|
|
2
|
+
description: Launch Socratic grilling and decision tree frontier exploration
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Launch
|
|
5
|
+
Launch Socratic grilling on the decision frontier.
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
`python3 skills/grilling/socratic_tree.py --export
|
|
7
|
+
Objective: $ARGUMENTS (may be empty to inspect the current frontier)
|
|
8
|
+
|
|
9
|
+
Call `iumbtems_socratic_frontier` with `{"objective": "<objective>", "file": ".research/frontier.json"}` (or `python3 skills/grilling/socratic_tree.py --export`); omit "objective" to inspect.
|
|
10
|
+
Challenge premises, invert assumptions, and report open frontier nodes.
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Scout open-source libraries
|
|
2
|
+
description: Scout open-source libraries, audit copyleft licenses, generate clean-room blueprints
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Scout open-source solutions for
|
|
5
|
+
Scout open-source solutions for the requested capability.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Feature: $ARGUMENTS
|
|
8
|
+
If $ARGUMENTS is empty, ask the user for the feature or algorithm first; never call with placeholder arguments.
|
|
8
9
|
|
|
9
|
-
|
|
10
|
-
Report
|
|
10
|
+
1. Execute `iumbtems_oss_scout` with `{"feature": "<feature>"}` (or `python3 runner/research_swarm.py --mode scout --objective "$ARGUMENTS"`).
|
|
11
|
+
2. Report mature candidates, GPL/AGPL copyleft risks, and the clean-room blueprint in `.research/oss_scout_report.md`.
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Inspect or
|
|
2
|
+
description: Inspect or update Epistemic Swarm parameters (engine, depth, mode)
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Inspect or
|
|
5
|
+
Inspect or update the Epistemic Swarm configuration.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Arguments: $ARGUMENTS (may be empty to inspect current settings)
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
Modes: `research`, `audit`, `scout`, `hybrid`, `brainstorm`. Depth: 1-4.
|
|
9
|
+
Call `iumbtems_config`; map `--engine`/`--depth`/`--mode`/`--show` style flags to search_engine/max_iterations/mode, or pass through no arguments to inspect (or run `python3 skills/swarm_config/configure.py $ARGUMENTS`).
|
|
@@ -2,8 +2,11 @@
|
|
|
2
2
|
description: Run IUMBTEMS dialectic research swarm on an objective
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
Run
|
|
5
|
+
Run an IUMBTEMS dialectic research swarm.
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
Objective: $ARGUMENTS
|
|
8
|
+
If $ARGUMENTS is empty, ask the user for the research objective first; never call with placeholder, empty, or literal "<objective>" arguments.
|
|
9
|
+
|
|
10
|
+
1. If the objective is ambiguous, frame it first via `iumbtems_socratic_frontier`.
|
|
11
|
+
2. Execute `iumbtems_swarm_research` with `{"objective": "<objective>"}` (or `python3 runner/research_swarm.py --objective "$ARGUMENTS"`).
|
|
9
12
|
3. Summarize `.research/final_synthesis.md`, preserving `[VERIFIED:<hash>]` pointers.
|