@ornexus/neocortex 4.59.1
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/LICENSE +56 -0
- package/LICENSE-COMMERCIAL.md +70 -0
- package/README.md +58 -0
- package/dist/sbom.cdx.json +7067 -0
- package/docs/install/coderabbit-manual-setup.md +86 -0
- package/docs/install/installer-diagnostics.md +107 -0
- package/docs/install/linux-global-install.md +97 -0
- package/install.js +572 -0
- package/install.ps1 +2214 -0
- package/install.sh +2013 -0
- package/package.json +118 -0
- package/packages/client/dist/adapters/adapter-registry.d.ts +61 -0
- package/packages/client/dist/adapters/adapter-registry.js +1 -0
- package/packages/client/dist/adapters/antigravity-adapter.d.ts +18 -0
- package/packages/client/dist/adapters/antigravity-adapter.js +2 -0
- package/packages/client/dist/adapters/claude-code-adapter.d.ts +19 -0
- package/packages/client/dist/adapters/claude-code-adapter.js +3 -0
- package/packages/client/dist/adapters/codex-adapter.d.ts +19 -0
- package/packages/client/dist/adapters/codex-adapter.js +2 -0
- package/packages/client/dist/adapters/cursor-adapter.d.ts +19 -0
- package/packages/client/dist/adapters/cursor-adapter.js +4 -0
- package/packages/client/dist/adapters/gemini-adapter.d.ts +18 -0
- package/packages/client/dist/adapters/gemini-adapter.js +2 -0
- package/packages/client/dist/adapters/index.d.ts +19 -0
- package/packages/client/dist/adapters/index.js +1 -0
- package/packages/client/dist/adapters/platform-detector.d.ts +48 -0
- package/packages/client/dist/adapters/platform-detector.js +1 -0
- package/packages/client/dist/adapters/target-adapter.d.ts +70 -0
- package/packages/client/dist/adapters/target-adapter.js +0 -0
- package/packages/client/dist/adapters/vscode-adapter.d.ts +19 -0
- package/packages/client/dist/adapters/vscode-adapter.js +2 -0
- package/packages/client/dist/agent/refresh-stubs.d.ts +80 -0
- package/packages/client/dist/agent/refresh-stubs.js +2 -0
- package/packages/client/dist/agent/update-agent-yaml.d.ts +26 -0
- package/packages/client/dist/agent/update-agent-yaml.js +1 -0
- package/packages/client/dist/agent/update-description.d.ts +45 -0
- package/packages/client/dist/agent/update-description.js +1 -0
- package/packages/client/dist/cache/crypto-utils.d.ts +30 -0
- package/packages/client/dist/cache/crypto-utils.js +1 -0
- package/packages/client/dist/cache/encrypted-cache.d.ts +30 -0
- package/packages/client/dist/cache/encrypted-cache.js +1 -0
- package/packages/client/dist/cache/in-memory-asset-cache.d.ts +62 -0
- package/packages/client/dist/cache/in-memory-asset-cache.js +1 -0
- package/packages/client/dist/cache/index.d.ts +13 -0
- package/packages/client/dist/cache/index.js +1 -0
- package/packages/client/dist/cache/protected-pi-boundary.d.ts +19 -0
- package/packages/client/dist/cache/protected-pi-boundary.js +1 -0
- package/packages/client/dist/checkpoint/checkpoint-client-reader.d.ts +45 -0
- package/packages/client/dist/checkpoint/checkpoint-client-reader.js +2 -0
- package/packages/client/dist/checkpoint/index.d.ts +12 -0
- package/packages/client/dist/checkpoint/index.js +1 -0
- package/packages/client/dist/checkpoint/shared-checkpoint-types.d.ts +85 -0
- package/packages/client/dist/checkpoint/shared-checkpoint-types.js +1 -0
- package/packages/client/dist/cli.d.ts +14 -0
- package/packages/client/dist/cli.js +48 -0
- package/packages/client/dist/commands/activate.d.ts +55 -0
- package/packages/client/dist/commands/activate.js +8 -0
- package/packages/client/dist/commands/cache-status.d.ts +39 -0
- package/packages/client/dist/commands/cache-status.js +2 -0
- package/packages/client/dist/commands/invoke.d.ts +229 -0
- package/packages/client/dist/commands/invoke.js +63 -0
- package/packages/client/dist/commands/refresh-memory.d.ts +11 -0
- package/packages/client/dist/commands/refresh-memory.js +1 -0
- package/packages/client/dist/config/resolver-selection.d.ts +40 -0
- package/packages/client/dist/config/resolver-selection.js +1 -0
- package/packages/client/dist/config/secure-config.d.ts +78 -0
- package/packages/client/dist/config/secure-config.js +12 -0
- package/packages/client/dist/constants.d.ts +25 -0
- package/packages/client/dist/constants.js +1 -0
- package/packages/client/dist/context/context-collector.d.ts +28 -0
- package/packages/client/dist/context/context-collector.js +2 -0
- package/packages/client/dist/context/context-sanitizer.d.ts +28 -0
- package/packages/client/dist/context/context-sanitizer.js +1 -0
- package/packages/client/dist/continuity/continuity-client-state-store.d.ts +183 -0
- package/packages/client/dist/continuity/continuity-client-state-store.js +1 -0
- package/packages/client/dist/continuity/invoke-hooks.d.ts +18 -0
- package/packages/client/dist/continuity/invoke-hooks.js +1 -0
- package/packages/client/dist/continuity/migrations/001-initial-schema.d.ts +11 -0
- package/packages/client/dist/continuity/migrations/001-initial-schema.js +263 -0
- package/packages/client/dist/continuity/sqlite-store.d.ts +409 -0
- package/packages/client/dist/continuity/sqlite-store.js +226 -0
- package/packages/client/dist/errors/error-messages.d.ts +40 -0
- package/packages/client/dist/errors/error-messages.js +2 -0
- package/packages/client/dist/graph-retrieval/pre-command-hook.d.ts +31 -0
- package/packages/client/dist/graph-retrieval/pre-command-hook.js +1 -0
- package/packages/client/dist/graph-retrieval/shared-graph-retrieval-contract.d.ts +77 -0
- package/packages/client/dist/graph-retrieval/shared-graph-retrieval-contract.js +1 -0
- package/packages/client/dist/i18n/first-run.d.ts +23 -0
- package/packages/client/dist/i18n/first-run.js +2 -0
- package/packages/client/dist/index.d.ts +56 -0
- package/packages/client/dist/index.js +1 -0
- package/packages/client/dist/license/index.d.ts +5 -0
- package/packages/client/dist/license/index.js +1 -0
- package/packages/client/dist/license/license-client.d.ts +79 -0
- package/packages/client/dist/license/license-client.js +1 -0
- package/packages/client/dist/machine/fingerprint.d.ts +34 -0
- package/packages/client/dist/machine/fingerprint.js +2 -0
- package/packages/client/dist/machine/index.d.ts +5 -0
- package/packages/client/dist/machine/index.js +1 -0
- package/packages/client/dist/memory/project-memory-writer.d.ts +74 -0
- package/packages/client/dist/memory/project-memory-writer.js +36 -0
- package/packages/client/dist/memory/shared-project-memory-types.d.ts +370 -0
- package/packages/client/dist/memory/shared-project-memory-types.js +2 -0
- package/packages/client/dist/policy/architecture-policy.d.ts +40 -0
- package/packages/client/dist/policy/architecture-policy.js +2 -0
- package/packages/client/dist/policy/index.d.ts +8 -0
- package/packages/client/dist/policy/index.js +1 -0
- package/packages/client/dist/policy/shared-policy-types.d.ts +89 -0
- package/packages/client/dist/policy/shared-policy-types.js +0 -0
- package/packages/client/dist/resilience/circuit-breaker.d.ts +70 -0
- package/packages/client/dist/resilience/circuit-breaker.js +1 -0
- package/packages/client/dist/resilience/degradation-manager.d.ts +67 -0
- package/packages/client/dist/resilience/degradation-manager.js +1 -0
- package/packages/client/dist/resilience/freshness-indicator.d.ts +59 -0
- package/packages/client/dist/resilience/freshness-indicator.js +1 -0
- package/packages/client/dist/resilience/index.d.ts +8 -0
- package/packages/client/dist/resilience/index.js +1 -0
- package/packages/client/dist/resilience/recovery-detector.d.ts +59 -0
- package/packages/client/dist/resilience/recovery-detector.js +1 -0
- package/packages/client/dist/resolvers/asset-resolver.d.ts +79 -0
- package/packages/client/dist/resolvers/asset-resolver.js +0 -0
- package/packages/client/dist/resolvers/local-resolver.d.ts +26 -0
- package/packages/client/dist/resolvers/local-resolver.js +8 -0
- package/packages/client/dist/resolvers/remote-resolver.d.ts +91 -0
- package/packages/client/dist/resolvers/remote-resolver.js +1 -0
- package/packages/client/dist/runner/cli.d.ts +121 -0
- package/packages/client/dist/runner/cli.js +20 -0
- package/packages/client/dist/runner/scheduler.d.ts +116 -0
- package/packages/client/dist/runner/scheduler.js +6 -0
- package/packages/client/dist/runner-cli.d.ts +9 -0
- package/packages/client/dist/runner-cli.js +3 -0
- package/packages/client/dist/state/project-state-snapshot.d.ts +15 -0
- package/packages/client/dist/state/project-state-snapshot.js +1 -0
- package/packages/client/dist/state/state-json-repair.d.ts +17 -0
- package/packages/client/dist/state/state-json-repair.js +3 -0
- package/packages/client/dist/telemetry/index.d.ts +5 -0
- package/packages/client/dist/telemetry/index.js +1 -0
- package/packages/client/dist/telemetry/offline-queue.d.ts +57 -0
- package/packages/client/dist/telemetry/offline-queue.js +1 -0
- package/packages/client/dist/tier/index.d.ts +5 -0
- package/packages/client/dist/tier/index.js +1 -0
- package/packages/client/dist/tier/tier-aware-client.d.ts +105 -0
- package/packages/client/dist/tier/tier-aware-client.js +1 -0
- package/packages/client/dist/types/index.d.ts +140 -0
- package/packages/client/dist/types/index.js +1 -0
- package/packages/client/dist/yoloop/discovery-hook.d.ts +85 -0
- package/packages/client/dist/yoloop/discovery-hook.js +2 -0
- package/packages/client/dist/yoloop/index.d.ts +10 -0
- package/packages/client/dist/yoloop/index.js +1 -0
- package/packages/client/dist/yoloop/invoke-hooks.d.ts +125 -0
- package/packages/client/dist/yoloop/invoke-hooks.js +5 -0
- package/packages/client/dist/yoloop/shared-discover-epics.d.ts +289 -0
- package/packages/client/dist/yoloop/shared-discover-epics.js +1 -0
- package/packages/client/dist/yoloop/shared-yoloop-types.d.ts +172 -0
- package/packages/client/dist/yoloop/shared-yoloop-types.js +1 -0
- package/packages/client/dist/yoloop/yoloop-client-state-store.d.ts +124 -0
- package/packages/client/dist/yoloop/yoloop-client-state-store.js +1 -0
- package/postinstall.js +754 -0
- package/targets-stubs/antigravity/README.md +36 -0
- package/targets-stubs/antigravity/gemini.md +29 -0
- package/targets-stubs/antigravity/install-antigravity.sh +153 -0
- package/targets-stubs/antigravity/mcp-config.json +30 -0
- package/targets-stubs/antigravity/skill/SKILL.md +159 -0
- package/targets-stubs/claude-code/.mcp.json +32 -0
- package/targets-stubs/claude-code/README.md +20 -0
- package/targets-stubs/claude-code/neocortex-root.agent.yaml +42 -0
- package/targets-stubs/claude-code/neocortex-root.md +310 -0
- package/targets-stubs/claude-code/neocortex.agent.yaml +42 -0
- package/targets-stubs/claude-code/neocortex.md +378 -0
- package/targets-stubs/codex/AGENTS.md +244 -0
- package/targets-stubs/codex/README.md +47 -0
- package/targets-stubs/codex/config-mcp.toml +22 -0
- package/targets-stubs/codex/install-codex.sh +63 -0
- package/targets-stubs/codex/neocortex.toml +29 -0
- package/targets-stubs/cursor/README.md +33 -0
- package/targets-stubs/cursor/agent.md +204 -0
- package/targets-stubs/cursor/install-cursor.sh +50 -0
- package/targets-stubs/cursor/mcp.json +30 -0
- package/targets-stubs/gemini-cli/README.md +34 -0
- package/targets-stubs/gemini-cli/agent.md +234 -0
- package/targets-stubs/gemini-cli/agents/neocortex.md +54 -0
- package/targets-stubs/gemini-cli/gemini.md +46 -0
- package/targets-stubs/gemini-cli/install-gemini.sh +70 -0
- package/targets-stubs/gemini-cli/settings-mcp.json +30 -0
- package/targets-stubs/kimi/mcp.json +33 -0
- package/targets-stubs/kimi/neocortex.md +54 -0
- package/targets-stubs/lib/mcp-merge.js +189 -0
- package/targets-stubs/openclaw/README.md +12 -0
- package/targets-stubs/openclaw/SKILL.md +88 -0
- package/targets-stubs/opencode/neocortex-root.md +261 -0
- package/targets-stubs/opencode/neocortex.md +59 -0
- package/targets-stubs/opencode/opencode-mcp.json +35 -0
- package/targets-stubs/vscode/README.md +34 -0
- package/targets-stubs/vscode/copilot-instructions.md +47 -0
- package/targets-stubs/vscode/install-vscode.sh +72 -0
- package/targets-stubs/vscode/mcp.json +36 -0
- package/targets-stubs/vscode/neocortex.agent.md +245 -0
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# Neocortex - Copilot Instructions (Thin Client)
|
|
2
|
+
|
|
3
|
+
This project uses Neocortex, a Development Orchestrator.
|
|
4
|
+
|
|
5
|
+
All orchestration logic is delivered by the remote Neocortex server.
|
|
6
|
+
Use the `@neocortex` agent (in `.github/agents/neocortex.md`) to interact with the pipeline.
|
|
7
|
+
|
|
8
|
+
Keep this always-loaded instruction file compact. Use it for universal project
|
|
9
|
+
rules, active context, and references to architecture docs; do not paste full
|
|
10
|
+
documents from `docs/architecture` or `docs/arquitetura-software`.
|
|
11
|
+
|
|
12
|
+
## Canonical Project Memory
|
|
13
|
+
|
|
14
|
+
`NEOCORTEX.md` is the canonical project-memory source. This Copilot wrapper must
|
|
15
|
+
resolve shared context back to that file and preserve VS Code/Copilot-specific
|
|
16
|
+
instructions around it. When durable context is discovered here, run
|
|
17
|
+
`*update-memory` so the finding is fed back into `NEOCORTEX.md` instead of
|
|
18
|
+
drifting in a platform-only file.
|
|
19
|
+
|
|
20
|
+
Neocortex may return curated design-intelligence guidance for UI stories. Treat
|
|
21
|
+
that guidance as server output from `neocortex-client invoke`; do not install,
|
|
22
|
+
fetch, or run upstream skills locally, and do not paste private prompt bodies or
|
|
23
|
+
protected source material into this file.
|
|
24
|
+
|
|
25
|
+
## Usage
|
|
26
|
+
|
|
27
|
+
Invoke the `@neocortex` agent with your command. The agent will call `neocortex-client invoke` to fetch instructions from the server.
|
|
28
|
+
|
|
29
|
+
Safe UI/UX review examples:
|
|
30
|
+
|
|
31
|
+
```text
|
|
32
|
+
@neocortex *ui-ux-review
|
|
33
|
+
@neocortex *ui-ux-review docs/architecture
|
|
34
|
+
@neocortex *ui-ux-review revise https://app.example.com com foco em onboarding
|
|
35
|
+
@neocortex *ui-ux-review --architecture-dir docs/architecture --url "$APP_BASE_URL"
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
For `*ui-ux-review`, flags are optional overrides. Free-form text after the
|
|
39
|
+
command is accepted as the review brief. Architecture commands such as
|
|
40
|
+
`*arch-plan`, `*arch-design-system`, and `*arch-ux-design` prepare the corpus
|
|
41
|
+
consumed by the review; findings can feed `*yolo` or `*yoloop` remediation.
|
|
42
|
+
|
|
43
|
+
## Activation
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
neocortex activate YOUR-LICENSE-KEY # Get yours at https://neocortex.sh/portal/login
|
|
47
|
+
```
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
# Neocortex - VSCode / GitHub Copilot Install Adapter (Thin Client)
|
|
3
|
+
# Simplified installer for npm tarball mode (targets-stubs only)
|
|
4
|
+
|
|
5
|
+
# Additive user/global JSON merge for VSCode MCP config (uses "servers" key).
|
|
6
|
+
# Preserves user-defined servers and replaces only Neocortex-managed servers.
|
|
7
|
+
_merge_vscode_mcp() {
|
|
8
|
+
local stub_file="$1"
|
|
9
|
+
local dest_file="$2"
|
|
10
|
+
|
|
11
|
+
if command -v node >/dev/null 2>&1; then
|
|
12
|
+
node "$(dirname "$stub_file")/../lib/mcp-merge.js" json "$stub_file" "$dest_file" servers VSCODE
|
|
13
|
+
return $?
|
|
14
|
+
fi
|
|
15
|
+
|
|
16
|
+
echo "[VSCODE] WARN: node not found; leaving existing $dest_file untouched"
|
|
17
|
+
echo "[VSCODE] WARN: Stub available at: $stub_file"
|
|
18
|
+
return 0
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
_vscode_user_mcp_path() {
|
|
22
|
+
if [ -n "$VSCODE_MCP_FILE" ]; then
|
|
23
|
+
printf '%s\n' "$VSCODE_MCP_FILE"
|
|
24
|
+
elif [ "$(uname -s 2>/dev/null)" = "Darwin" ]; then
|
|
25
|
+
printf '%s\n' "$HOME/Library/Application Support/Code/User/mcp.json"
|
|
26
|
+
else
|
|
27
|
+
printf '%s\n' "${XDG_CONFIG_HOME:-$HOME/.config}/Code/User/mcp.json"
|
|
28
|
+
fi
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
install_vscode() {
|
|
32
|
+
local source_dir="${1:?SOURCE_DIR required}"
|
|
33
|
+
local dest_dir="${2:?DEST_DIR required}"
|
|
34
|
+
local vscode_target="$source_dir/targets-stubs/vscode"
|
|
35
|
+
|
|
36
|
+
if [ ! -d "$vscode_target" ]; then
|
|
37
|
+
echo "[VSCODE] ERROR: Stub directory not found: $vscode_target" >&2
|
|
38
|
+
return 1
|
|
39
|
+
fi
|
|
40
|
+
|
|
41
|
+
echo "[VSCODE] Installing Neocortex for VSCode / GitHub Copilot (thin-client mode)..."
|
|
42
|
+
|
|
43
|
+
# Create destination directories
|
|
44
|
+
mkdir -p "$dest_dir/.github/agents" \
|
|
45
|
+
"$dest_dir/.vscode"
|
|
46
|
+
|
|
47
|
+
# 1. Copy agent stub
|
|
48
|
+
# P124.02: Source file renamed to neocortex.agent.md (canonical Custom Agents extension).
|
|
49
|
+
# P127.04: install the canonical .agent.md path for VS Code and GitHub Copilot CLI.
|
|
50
|
+
# A legacy .md copy is retained because VS Code also detects .md files in .github/agents.
|
|
51
|
+
if [ -f "$vscode_target/neocortex.agent.md" ]; then
|
|
52
|
+
cp "$vscode_target/neocortex.agent.md" "$dest_dir/.github/agents/neocortex.agent.md"
|
|
53
|
+
cp "$vscode_target/neocortex.agent.md" "$dest_dir/.github/agents/neocortex.md"
|
|
54
|
+
echo "[VSCODE] Installed agent stub: .github/agents/neocortex.agent.md"
|
|
55
|
+
echo "[VSCODE] Installed compatibility stub: .github/agents/neocortex.md"
|
|
56
|
+
fi
|
|
57
|
+
|
|
58
|
+
# 2. Copy copilot-instructions stub
|
|
59
|
+
if [ -f "$vscode_target/copilot-instructions.md" ]; then
|
|
60
|
+
cp "$vscode_target/copilot-instructions.md" "$dest_dir/.github/copilot-instructions.md"
|
|
61
|
+
echo "[VSCODE] Installed: .github/copilot-instructions.md"
|
|
62
|
+
fi
|
|
63
|
+
|
|
64
|
+
# 3. User-level additive merge MCP config
|
|
65
|
+
if [ -f "$vscode_target/mcp.json" ]; then
|
|
66
|
+
_merge_vscode_mcp "$vscode_target/mcp.json" "$(_vscode_user_mcp_path)" || true
|
|
67
|
+
fi
|
|
68
|
+
|
|
69
|
+
echo "[VSCODE] Thin-client installation complete!"
|
|
70
|
+
echo "[VSCODE] Content delivered by remote server. Activate: neocortex activate YOUR-LICENSE-KEY # Get yours at https://neocortex.sh/portal/login"
|
|
71
|
+
return 0
|
|
72
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
{
|
|
2
|
+
"servers": {
|
|
3
|
+
"playwright": {
|
|
4
|
+
"type": "stdio",
|
|
5
|
+
"command": "npx",
|
|
6
|
+
"args": ["-y", "@playwright/mcp@latest"]
|
|
7
|
+
},
|
|
8
|
+
"context7": {
|
|
9
|
+
"type": "http",
|
|
10
|
+
"url": "https://mcp.context7.com/mcp"
|
|
11
|
+
},
|
|
12
|
+
"browser_use": {
|
|
13
|
+
"type": "stdio",
|
|
14
|
+
"command": "uvx",
|
|
15
|
+
"args": ["--from", "browser-use[cli]", "browser-use", "--mcp"],
|
|
16
|
+
"env": {
|
|
17
|
+
"OPENAI_API_KEY": "${env:OPENAI_API_KEY}",
|
|
18
|
+
"ANTHROPIC_API_KEY": "${env:ANTHROPIC_API_KEY}"
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
"figma": {
|
|
22
|
+
"type": "http",
|
|
23
|
+
"url": "https://mcp.figma.com/mcp"
|
|
24
|
+
},
|
|
25
|
+
"shadcn": {
|
|
26
|
+
"type": "stdio",
|
|
27
|
+
"command": "npx",
|
|
28
|
+
"args": ["shadcn@latest", "mcp"]
|
|
29
|
+
},
|
|
30
|
+
"chrome-devtools": {
|
|
31
|
+
"type": "stdio",
|
|
32
|
+
"command": "npx",
|
|
33
|
+
"args": ["-y", "chrome-devtools-mcp@latest"]
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: "neocortex"
|
|
3
|
+
description: "Neocortex v4.59.1 | OrNexus Team"
|
|
4
|
+
tools:
|
|
5
|
+
# Read / Edit (built-in tool sets)
|
|
6
|
+
- read
|
|
7
|
+
- edit
|
|
8
|
+
# Search codebase, files, usages
|
|
9
|
+
- search
|
|
10
|
+
# Execute commands in terminal
|
|
11
|
+
- execute # /loop equivalent (P95.09): VS Code com Claude Code extension expoe Skill(loop). Em Continue/Cline, usar shell loop via execute. Cap iteracoes recomendado: 30.
|
|
12
|
+
# Web fetch + search
|
|
13
|
+
- web
|
|
14
|
+
# Todo tracking
|
|
15
|
+
- todos
|
|
16
|
+
# MCP servers (wildcards grant access to all tools from each connected server)
|
|
17
|
+
- context7/*
|
|
18
|
+
- playwright/*
|
|
19
|
+
- browser_use/*
|
|
20
|
+
model:
|
|
21
|
+
- "claude-sonnet-4"
|
|
22
|
+
user-invocable: true
|
|
23
|
+
agents: []
|
|
24
|
+
target: vscode
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
<!-- CRITICAL: Plugin Conflict Prevention -->
|
|
28
|
+
## IMPORTANT: Do NOT Intercept Neocortex Arguments
|
|
29
|
+
|
|
30
|
+
**ALL text after `@neocortex` or trigger keywords MUST be passed VERBATIM to `neocortex-client invoke`.**
|
|
31
|
+
|
|
32
|
+
Tokens starting with `*` (e.g. `*commit-push`, `*implement`, `*status`, `*diagnose`,
|
|
33
|
+
`*yolo`, `*review`, `*create-epic`, `*help`) are **Neocortex server triggers**, NOT
|
|
34
|
+
VSCode commands, Copilot skills, or extension actions.
|
|
35
|
+
|
|
36
|
+
**Rules**:
|
|
37
|
+
- NEVER interpret `*`-prefixed arguments as VSCode commands, Copilot skills, or extension actions
|
|
38
|
+
- NEVER invoke any local command, skill, or extension based on these arguments
|
|
39
|
+
- NEVER attempt to resolve or execute these tokens as anything other than neocortex-client args
|
|
40
|
+
- ALWAYS delegate the ENTIRE argument string to `neocortex-client invoke --args "..."`
|
|
41
|
+
- The ONLY action this agent takes is: collect args -> invoke thin client -> follow server instructions
|
|
42
|
+
|
|
43
|
+
<!-- END: Plugin Conflict Prevention -->
|
|
44
|
+
|
|
45
|
+
# Neocortex - Thin Client Interface
|
|
46
|
+
|
|
47
|
+
Voce e o agente Neocortex. Toda a logica de orquestracao e resolvida pelo server remoto.
|
|
48
|
+
|
|
49
|
+
## Canonical Project Memory
|
|
50
|
+
|
|
51
|
+
`NEOCORTEX.md` is the canonical project-memory source. This VS Code/Copilot agent
|
|
52
|
+
wrapper preserves frontmatter/tool configuration while shared context resolves
|
|
53
|
+
back to `NEOCORTEX.md`. Run `*update-memory` when durable findings should be fed
|
|
54
|
+
back into the canonical file.
|
|
55
|
+
|
|
56
|
+
## Banner
|
|
57
|
+
|
|
58
|
+
SEMPRE que este agente for invocado, imprima o banner abaixo como PRIMEIRO output, dentro de um bloco de codigo (triple backticks). Copie o conteudo entre as tags `<banner>` EXATAMENTE como esta:
|
|
59
|
+
|
|
60
|
+
<banner>
|
|
61
|
+
┌────────────────────────────────────────────────────────────┐
|
|
62
|
+
│ │
|
|
63
|
+
│ ####### N E O C O R T E X │
|
|
64
|
+
│ ### ######## v4.59.1 │
|
|
65
|
+
│ ######### ##### │
|
|
66
|
+
│ ## ############## Development Orchestrator │
|
|
67
|
+
│ ## ### ###### ## OrNexus Team │
|
|
68
|
+
│ ## ### ### ## │
|
|
69
|
+
│ ## ###### ### ## │
|
|
70
|
+
│ ############### ## │
|
|
71
|
+
│ ##### ######## │
|
|
72
|
+
│ ######## ## │
|
|
73
|
+
│ ####### │
|
|
74
|
+
│ │
|
|
75
|
+
└────────────────────────────────────────────────────────────┘
|
|
76
|
+
</banner>
|
|
77
|
+
|
|
78
|
+
Apos imprimir o banner, prossiga com o protocolo de invocacao abaixo.
|
|
79
|
+
|
|
80
|
+
## Auto-Update Check
|
|
81
|
+
|
|
82
|
+
BEFORE the first `neocortex-client invoke` call in each session, run this silent update check:
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
UPDATE_MARKER="$HOME/.neocortex/.update-check"
|
|
86
|
+
if [ -f "$UPDATE_MARKER" ] && [ "$(find "$UPDATE_MARKER" -mmin -1440 2>/dev/null)" ]; then
|
|
87
|
+
: # Recently checked, skip
|
|
88
|
+
else
|
|
89
|
+
INSTALLED=$(neocortex --version 2>/dev/null | head -1 | grep -oE '[0-9]+\.[0-9]+\.[0-9]+')
|
|
90
|
+
LATEST=$(npm view @ornexus/neocortex version 2>/dev/null)
|
|
91
|
+
if [ -n "$INSTALLED" ] && [ -n "$LATEST" ] && [ "$INSTALLED" != "$LATEST" ]; then
|
|
92
|
+
npm install -g @ornexus/neocortex@latest 2>/dev/null
|
|
93
|
+
fi
|
|
94
|
+
mkdir -p "$HOME/.neocortex" && touch "$UPDATE_MARKER" 2>/dev/null
|
|
95
|
+
fi
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Rules:
|
|
99
|
+
- Run ONCE per session, NEVER repeat within the same conversation
|
|
100
|
+
- If ANY command fails, ignore and proceed with `neocortex-client invoke` normally
|
|
101
|
+
- Do NOT show output to user unless explicitly asked
|
|
102
|
+
|
|
103
|
+
## Invocacao
|
|
104
|
+
|
|
105
|
+
Quando o usuario invocar este agente, siga EXATAMENTE este protocolo:
|
|
106
|
+
|
|
107
|
+
1. **Coletar argumentos do usuario** - Tudo que o usuario escreveu apos `@neocortex`
|
|
108
|
+
2. **Executar o thin client** para obter instrucoes do server:
|
|
109
|
+
|
|
110
|
+
```bash
|
|
111
|
+
neocortex-client invoke \
|
|
112
|
+
--args "{ARGS_DO_USUARIO}" \
|
|
113
|
+
--project-root "$(git rev-parse --show-toplevel 2>/dev/null || pwd -P)" \
|
|
114
|
+
--format plain
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
3. **Seguir EXATAMENTE as instrucoes retornadas** pelo thin client no stdout
|
|
118
|
+
|
|
119
|
+
### Compatibilidade para entrada grande
|
|
120
|
+
|
|
121
|
+
Use `--args` exatamente como mostrado acima para triggers normais e prompts
|
|
122
|
+
delegados; isso preserva o encaminhamento legado verbatim. Se o usuario fornecer
|
|
123
|
+
explicitamente uma story sintetica ou mega prompt grande demais para caber com
|
|
124
|
+
seguranca em um argumento de shell, use exatamente uma fonte de entrada grande:
|
|
125
|
+
|
|
126
|
+
```bash
|
|
127
|
+
neocortex-client invoke --stdin --project-root "$(git rev-parse --show-toplevel 2>/dev/null || pwd -P)" --format plain < synthetic.story.md
|
|
128
|
+
neocortex-client invoke --args-file ./synthetic.story.md --project-root "$(git rev-parse --show-toplevel 2>/dev/null || pwd -P)" --format plain
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
Nao force migracao para estas opcoes, nao combine com `--args`, e nao use estas
|
|
132
|
+
opcoes para passar uma invocacao root externa ou historico completo para um
|
|
133
|
+
child agent.
|
|
134
|
+
|
|
135
|
+
## P127 Subagent Isolation Contract
|
|
136
|
+
|
|
137
|
+
This stub is a public thin wrapper. It may describe how to call the thin client
|
|
138
|
+
and consume public response metadata, but it must not contain proprietary step
|
|
139
|
+
bodies, core prompts, or server-only implementation identifiers.
|
|
140
|
+
|
|
141
|
+
Do not embed, reveal, summarize, or reconstruct Neocortex core prompts,
|
|
142
|
+
server-side source, proprietary workflow logic, or private implementation
|
|
143
|
+
identifiers.
|
|
144
|
+
|
|
145
|
+
Runtime flow:
|
|
146
|
+
|
|
147
|
+
1. The root VS Code/Copilot agent intercepts the user trigger and invokes
|
|
148
|
+
`neocortex-client`.
|
|
149
|
+
2. The root agent follows stdout exactly.
|
|
150
|
+
3. Only when returned metadata contains `metadata.skillDirectives[]` with a
|
|
151
|
+
`kind: 'task'` directive does the root agent spawn or request a native
|
|
152
|
+
`neocortex` subagent.
|
|
153
|
+
4. The root agent passes only the task directive prompt to that subagent after
|
|
154
|
+
placeholder substitution. Never pass the original root invocation
|
|
155
|
+
(`@neocortex *...` or the outer `*yoloop ...`) as the subagent prompt.
|
|
156
|
+
|
|
157
|
+
`subagentType: 'neocortex'` is a native VS Code/Copilot agent profile name, not a
|
|
158
|
+
Neocortex server trigger. If no task directive is returned, continue in the root
|
|
159
|
+
agent or use the shell-loop fallback below.
|
|
160
|
+
This is the legacy skill-only fallback: never spawn a child subagent from
|
|
161
|
+
`kind: 'skill'`, and never pass `@neocortex *yoloop ...` to a child.
|
|
162
|
+
|
|
163
|
+
A child `*yolo` terminal success, including a merge/status `done` result, stops
|
|
164
|
+
only that child story. It is not a yoloop stop. After the child returns, the root
|
|
165
|
+
VS Code/Copilot agent resumes ownership and re-invokes `*yoloop` when the latest
|
|
166
|
+
yoloop metadata has `yoloopComplete === false` and `yoloopAborted === false`.
|
|
167
|
+
|
|
168
|
+
## Exemplos
|
|
169
|
+
|
|
170
|
+
| Invocacao do Usuario | Comando invoke |
|
|
171
|
+
|---------------------|----------------|
|
|
172
|
+
| `@neocortex *menu` | `invoke --args "*menu"` |
|
|
173
|
+
| `@neocortex` (vazio) | `invoke --args ""` |
|
|
174
|
+
| `@neocortex *status` | `invoke --args "*status"` |
|
|
175
|
+
| `@neocortex *diagnose @docs/stories/P126.01.story.md` | `invoke --args "*diagnose @docs/stories/P126.01.story.md"` |
|
|
176
|
+
| `@neocortex *diagnose "investigar falha intermitente no deploy"` | `invoke --args '*diagnose "investigar falha intermitente no deploy"'` |
|
|
177
|
+
| `@neocortex *yolo @docs/stories/1.1.story.md` | `invoke --args "*yolo @docs/stories/1.1.story.md"` |
|
|
178
|
+
| `@neocortex *implement @docs/stories/1.1.story.md` | `invoke --args "*implement @docs/stories/1.1.story.md"` |
|
|
179
|
+
|
|
180
|
+
## Erros
|
|
181
|
+
|
|
182
|
+
| Exit Code | Significado | Acao |
|
|
183
|
+
|-----------|-------------|------|
|
|
184
|
+
| 0 | Sucesso | Seguir instrucoes do stdout |
|
|
185
|
+
| 1 | Erro do server | Mostrar stderr ao usuario |
|
|
186
|
+
| 2 | Nao configurado | Instruir: "Visite https://neocortex.sh/portal/login para obter sua license key, depois execute: `neocortex activate SUA-LICENSE-KEY`" |
|
|
187
|
+
|
|
188
|
+
## Regras
|
|
189
|
+
|
|
190
|
+
### Orquestracao (triggers `*xxx`)
|
|
191
|
+
- NUNCA invente logica de orquestracao - toda logica de pipeline/step/workflow vem do server
|
|
192
|
+
- NUNCA pule o thin client para argumentos prefixados com `*` - sempre execute `neocortex-client invoke`
|
|
193
|
+
- SEMPRE siga as instrucoes retornadas pelo server literalmente
|
|
194
|
+
- Se o thin client falhar, mostre o erro e aguarde input do usuario
|
|
195
|
+
|
|
196
|
+
### Pesquisa livre / analise (sem prefixo `*`)
|
|
197
|
+
Quando o usuario pedir pesquisa, analise, brainstorm, validacao de hipotese, ou qualquer
|
|
198
|
+
tarefa free-form que NAO seja um trigger de orquestracao, voce TEM permissao para usar
|
|
199
|
+
diretamente as tools do VS Code / Copilot Chat:
|
|
200
|
+
|
|
201
|
+
- **`search` tool set** (`search/codebase`, `search/fileSearch`, `search/textSearch`,
|
|
202
|
+
`search/usages`) - exploracao e analise do projeto local
|
|
203
|
+
- **`read` tool set** (`read/readFile`, `read/problems`, `read/terminalLastCommand`) -
|
|
204
|
+
leitura de arquivos, problemas e output de terminal
|
|
205
|
+
- **`web` tool set** (`web/fetch`) - pesquisa de mercado, validacao de hipoteses,
|
|
206
|
+
fetching de documentacao oficial
|
|
207
|
+
- **`execute` tool set** (`execute/runInTerminal`, `execute/getTerminalOutput`) -
|
|
208
|
+
qualquer ferramenta CLI (jq, curl, psql, docker, fly, gh, etc.)
|
|
209
|
+
- **`edit` tool set** (`edit/editFiles`, `edit/createFile`, `edit/createDirectory`) -
|
|
210
|
+
manipulacao direta do projeto quando solicitado
|
|
211
|
+
- **`agent` tool set** - delegar trabalho a subagents especializados quando util
|
|
212
|
+
- **MCP servers configurados** (`context7/*`, `playwright/*`, `browser_use/*`) -
|
|
213
|
+
documentacao atualizada, browser automation, visual research
|
|
214
|
+
|
|
215
|
+
NUNCA recuse uma pesquisa por falta de tools. NUNCA fabrique fontes - se nao encontrar
|
|
216
|
+
dados reais, diga isso explicitamente. Quando a pesquisa resultar em decisoes que
|
|
217
|
+
precisem virar epic/stories, ai sim invoque `neocortex-client invoke --args "*create-epic ..."`
|
|
218
|
+
para entrar no fluxo de orquestracao.
|
|
219
|
+
|
|
220
|
+
## Yoloop on VSCode Copilot (P122.05)
|
|
221
|
+
|
|
222
|
+
VSCode Copilot agent lacks a native `/loop` skill. Use `runInTerminal` with the same
|
|
223
|
+
bash snippet documented in `docs/arquitetura-software/loop-usage-guide.md` (Platform
|
|
224
|
+
Matrix).
|
|
225
|
+
|
|
226
|
+
When a response includes a `kind: 'task'` directive, the root VS Code/Copilot
|
|
227
|
+
agent may run the returned per-story prompt in the native `neocortex` subagent
|
|
228
|
+
profile once that profile is installed. The shell loop remains the fallback for
|
|
229
|
+
loop repetition; it must not pass the outer `*yoloop` trigger into a child
|
|
230
|
+
subagent.
|
|
231
|
+
The shell-loop fallback must also treat a child `*yolo` terminal success as a
|
|
232
|
+
per-story boundary and continue polling `*yoloop` until yoloop metadata or
|
|
233
|
+
termination tokens report complete/aborted.
|
|
234
|
+
|
|
235
|
+
```bash
|
|
236
|
+
while true; do
|
|
237
|
+
RESPONSE=$(neocortex-client invoke --args "*yoloop @docs/epics/" --format plain)
|
|
238
|
+
echo "$RESPONSE"
|
|
239
|
+
echo "$RESPONSE" | grep -q '\[YOLOOP_COMPLETE\]' && break
|
|
240
|
+
echo "$RESPONSE" | grep -q '\[YOLOOP_ABORTED\]' && break
|
|
241
|
+
done
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
The loop terminates on `[YOLOOP_COMPLETE]` (success) or `[YOLOOP_ABORTED]` (failure).
|
|
245
|
+
For full details see `docs/arquitetura-software/loop-usage-guide.md`.
|