@nexus-cortex/server 4.71.0 → 4.72.0

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.
Files changed (2) hide show
  1. package/.cortex/orient +69 -0
  2. package/package.json +3 -3
package/.cortex/orient ADDED
@@ -0,0 +1,69 @@
1
+ #!/bin/sh
2
+ # Generic mechanical orient — the shipped scaffold's boot-minimal turn-1 target
3
+ # (HARNESS_IMPROVEMENT_BACKLOG item 9b). Vendored by prepack to
4
+ # <pkg>/.cortex/orient; the boot-minimal clause points here when the project
5
+ # has no .cortex/orient of its own. Deterministic, read-only except for one
6
+ # mechanical .cortex/CORTEX.md render (never overwrites), always exits 0.
7
+ W="$(pwd)"
8
+ echo "== WORKSPACE MAP: $W =="
9
+ ls -1A "$W" 2>/dev/null | head -40
10
+ PROJECT=""
11
+ CMDS=""
12
+ if [ -f package.json ]; then
13
+ if command -v node >/dev/null 2>&1; then
14
+ PROJECT=$(node -e 'try{console.log(require("./package.json").name||"")}catch(e){}' 2>/dev/null)
15
+ SCRIPTS=$(node -e 'try{Object.keys(require("./package.json").scripts||{}).forEach(k=>console.log(k))}catch(e){}' 2>/dev/null | head -12)
16
+ else
17
+ PROJECT=$(sed -n 's/.*"name"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p' package.json | head -1)
18
+ SCRIPTS=$(tr ',' '\n' < package.json | sed -n 's/.*"\([A-Za-z0-9:_-]*\)"[[:space:]]*:[[:space:]]*".*/\1/p' | head -12)
19
+ fi
20
+ if [ -n "$SCRIPTS" ]; then
21
+ echo "-- package.json scripts --"
22
+ printf '%s\n' "$SCRIPTS" | sed 's/^/ npm run /'
23
+ CMDS=$(printf '%s\n' "$SCRIPTS" | head -8 | sed 's/^/- `npm run /;s/$/`/')
24
+ fi
25
+ fi
26
+ [ -f requirements.txt ] && echo "-- python deps: requirements.txt ($(wc -l < requirements.txt | tr -d ' ') lines)"
27
+ [ -f pyproject.toml ] && echo "-- python: pyproject.toml present"
28
+ [ -f Cargo.toml ] && echo "-- rust: Cargo.toml present (cargo build / cargo test)"
29
+ if [ -f Makefile ]; then
30
+ echo "-- make targets --"
31
+ sed -n 's/^\([A-Za-z0-9_.-][A-Za-z0-9_.-]*\):.*/ make \1/p' Makefile | head -8
32
+ fi
33
+ if [ -f README.md ]; then
34
+ echo "-- README head --"
35
+ head -12 README.md
36
+ fi
37
+ # Capability index — harness-owned steering (item 9b): the skills shipped with
38
+ # the install, reachable through plain bash reads (works under any tool frame).
39
+ SK="${CORTEX_ROOT:-$HOME}/.cortex/skills"
40
+ if [ -d "$SK" ]; then
41
+ echo "== CAPABILITY GUIDES (load one with: cat <path>/SKILL.md) =="
42
+ for d in "$SK"/*/; do
43
+ [ -d "$d" ] || continue
44
+ n=$(basename "$d")
45
+ desc=$(sed -n 's/^description:[[:space:]]*//p' "$d/SKILL.md" 2>/dev/null | head -1 | cut -c1-90)
46
+ case "$desc" in ">"|"|"|"") desc="guide";; esac
47
+ echo " $SK/$n — $desc"
48
+ done | head -14
49
+ fi
50
+ echo "note: when your tool list is limited, additional tools may be discoverable via the SearchTools tool."
51
+ # Mechanical CORTEX.md (item 9c feed): written synchronously so the deferred
52
+ # doctrine corpus delivered at anchor-lift carries project context. Refine
53
+ # later with the init_cortex_context tool; never overwritten here.
54
+ if [ ! -f .cortex/CORTEX.md ]; then
55
+ mkdir -p .cortex 2>/dev/null
56
+ {
57
+ echo "# CORTEX.md (mechanical orient scan — refine with init_cortex_context)"
58
+ echo
59
+ echo "## Project"
60
+ echo "${PROJECT:-$(basename "$W")} — see README for details."
61
+ echo
62
+ echo "## Key Commands"
63
+ if [ -n "$CMDS" ]; then printf '%s\n' "$CMDS"; else echo "- (no package.json scripts; check README/Makefile)"; fi
64
+ echo
65
+ echo "## Structure (top level)"
66
+ ls -1A "$W" 2>/dev/null | head -25 | sed 's/^/- /'
67
+ } > .cortex/CORTEX.md 2>/dev/null && echo "(wrote mechanical .cortex/CORTEX.md)"
68
+ fi
69
+ exit 0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nexus-cortex/server",
3
- "version": "4.71.0",
3
+ "version": "4.72.0",
4
4
  "description": "Thin Express server wrapper for Nexus Cortex core library",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -20,8 +20,8 @@
20
20
  "prepack": "node ../../scripts/copy-pkg-cortex-scaffold.mjs"
21
21
  },
22
22
  "dependencies": {
23
- "@nexus-cortex/core": "4.71.0",
24
- "@nexus-cortex/executors": "4.71.0",
23
+ "@nexus-cortex/core": "4.72.0",
24
+ "@nexus-cortex/executors": "4.72.0",
25
25
  "chalk": "^5.3.0",
26
26
  "cors": "^2.8.5",
27
27
  "dotenv": "^16.4.5",