@rubytech/create-maxy-code 0.1.108 → 0.1.110
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/dist/index.js +11 -125
- package/dist/snap-chromium.js +1 -2
- package/dist/uninstall.js +10 -9
- package/package.json +1 -1
- package/payload/platform/plugins/admin/PLUGIN.md +1 -0
- package/payload/platform/plugins/admin/mcp/dist/index.js +1 -1
- package/payload/platform/plugins/admin/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/admin/skills/upgrade/SKILL.md +34 -0
- package/payload/platform/plugins/cloudflare/.claude-plugin/plugin.json +1 -1
- package/payload/platform/plugins/cloudflare/PLUGIN.md +9 -16
- package/payload/platform/plugins/cloudflare/mcp/dist/index.js +7 -12
- package/payload/platform/plugins/cloudflare/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/cloudflare/references/dashboard-guide.md +3 -3
- package/payload/platform/plugins/cloudflare/references/manual-setup.md +16 -51
- package/payload/platform/plugins/cloudflare/references/reset-guide.md +24 -25
- package/payload/platform/plugins/cloudflare/skills/setup-tunnel/SKILL.md +29 -144
- package/payload/platform/plugins/docs/references/admin-session.md +1 -1
- package/payload/platform/plugins/docs/references/admin-ui.md +1 -1
- package/payload/platform/plugins/docs/references/cloudflare.md +20 -29
- package/payload/platform/plugins/docs/references/platform.md +4 -22
- package/payload/platform/plugins/docs/references/plugins-guide.md +1 -1
- package/payload/platform/plugins/docs/references/troubleshooting.md +4 -316
- package/payload/platform/plugins/venture-studio/PLUGIN.md +35 -4
- package/payload/platform/plugins/venture-studio/bin/scaffold.sh +104 -0
- package/payload/platform/plugins/venture-studio/skills/investor-data-room/SKILL.md +3 -1
- package/payload/platform/plugins/work/mcp/dist/cli/project-create-cli.d.ts +2 -0
- package/payload/platform/plugins/work/mcp/dist/cli/project-create-cli.d.ts.map +1 -0
- package/payload/platform/plugins/work/mcp/dist/cli/project-create-cli.js +78 -0
- package/payload/platform/plugins/work/mcp/dist/cli/project-create-cli.js.map +1 -0
- package/payload/platform/scripts/check-no-task-id-leaks.mjs +1 -1
- package/payload/platform/scripts/vnc.sh +4 -3
- package/payload/platform/templates/agents/admin/IDENTITY.md +1 -1
- package/payload/premium-plugins/venture-studio/PLUGIN.md +35 -4
- package/payload/premium-plugins/venture-studio/bin/scaffold.sh +104 -0
- package/payload/premium-plugins/venture-studio/skills/investor-data-room/SKILL.md +3 -1
- package/payload/server/{chunk-AGFS3TVN.js → chunk-FSPPVVWM.js} +1303 -496
- package/payload/server/maxy-edge.js +21 -259
- package/payload/server/public/assets/{ChatInput-DJsqm_Gf.js → ChatInput-CsnIedhS.js} +1 -5
- package/payload/server/public/assets/{Checkbox-DGZG9BKc.js → Checkbox-CWugFyFT.js} +1 -1
- package/payload/server/public/assets/admin-D3gZuyUn.js +217 -0
- package/payload/server/public/assets/{architectureDiagram-Q4EWVU46-Dw16BhiX.js → architectureDiagram-Q4EWVU46-CeTRKWDb.js} +1 -1
- package/payload/server/public/assets/{blockDiagram-DXYQGD6D-DIOpmf5Y.js → blockDiagram-DXYQGD6D-DeeIX5U3.js} +1 -1
- package/payload/server/public/assets/{c4Diagram-AHTNJAMY-Tdb_HZeX.js → c4Diagram-AHTNJAMY-CFsqZuil.js} +1 -1
- package/payload/server/public/assets/channel-CrSx5mnG.js +1 -0
- package/payload/server/public/assets/{chunk-336JU56O-CebpwDDe.js → chunk-336JU56O-DpIXuFM0.js} +2 -2
- package/payload/server/public/assets/{chunk-426QAEUC-BtRCmfDU.js → chunk-426QAEUC-Qk8qqrvA.js} +1 -1
- package/payload/server/public/assets/{chunk-4TB4RGXK-BZ3GEWs3.js → chunk-4TB4RGXK-DtM8-CUn.js} +1 -1
- package/payload/server/public/assets/{chunk-5FUZZQ4R-iDI6Xu0U.js → chunk-5FUZZQ4R-CrSQ4ySU.js} +1 -1
- package/payload/server/public/assets/{chunk-5PVQY5BW-SQD_EpYa.js → chunk-5PVQY5BW-Bn2nQwdj.js} +1 -1
- package/payload/server/public/assets/{chunk-EDXVE4YY-CtCcA7_e.js → chunk-EDXVE4YY-CzCPnR0P.js} +1 -1
- package/payload/server/public/assets/{chunk-ENJZ2VHE-pXVGVCbb.js → chunk-ENJZ2VHE-CgZj9RoG.js} +1 -1
- package/payload/server/public/assets/{chunk-ICPOFSXX-Dkzg9o2N.js → chunk-ICPOFSXX-wy-eNjwW.js} +1 -1
- package/payload/server/public/assets/{chunk-OYMX7WX6-1ZZWzf9F.js → chunk-OYMX7WX6-CMmJtL8S.js} +1 -1
- package/payload/server/public/assets/{chunk-U2HBQHQK-CpQ3kzO0.js → chunk-U2HBQHQK-CFCW7OaT.js} +1 -1
- package/payload/server/public/assets/{chunk-X2U36JSP-C2LkxroC.js → chunk-X2U36JSP-Bgh-CJSN.js} +1 -1
- package/payload/server/public/assets/{chunk-YZCP3GAM-Bl5jBOt5.js → chunk-YZCP3GAM-BXKwZ4vN.js} +1 -1
- package/payload/server/public/assets/{chunk-ZZ45TVLE-CHtnptPS.js → chunk-ZZ45TVLE-BiOuK5NP.js} +1 -1
- package/payload/server/public/assets/classDiagram-6PBFFD2Q-C3IDJsqN.js +1 -0
- package/payload/server/public/assets/classDiagram-v2-HSJHXN6E-BOIrJ5Zb.js +1 -0
- package/payload/server/public/assets/clone-P8Fkz7JD.js +1 -0
- package/payload/server/public/assets/{dagre-BziN0Nkh.js → dagre-DyCxa9Q2.js} +1 -1
- package/payload/server/public/assets/{dagre-KV5264BT-B7OG1g1Y.js → dagre-KV5264BT-Cffo_hmf.js} +1 -1
- package/payload/server/public/assets/data-DRfwJPja.js +1 -0
- package/payload/server/public/assets/{diagram-5BDNPKRD-Bf31nIDs.js → diagram-5BDNPKRD-Bt93Du3V.js} +1 -1
- package/payload/server/public/assets/{diagram-G4DWMVQ6-DQu85hhH.js → diagram-G4DWMVQ6-v4r-tBsC.js} +1 -1
- package/payload/server/public/assets/{diagram-MMDJMWI5-5tstbs4y.js → diagram-MMDJMWI5-DKrVPOP-.js} +1 -1
- package/payload/server/public/assets/{diagram-TYMM5635--MOV1U4o.js → diagram-TYMM5635-B1PzWQb9.js} +1 -1
- package/payload/server/public/assets/{erDiagram-SMLLAGMA-BtAnOJmd.js → erDiagram-SMLLAGMA-ClQzsQAs.js} +1 -1
- package/payload/server/public/assets/{flowDiagram-DWJPFMVM-CybiCIih.js → flowDiagram-DWJPFMVM-h3IbpN_7.js} +1 -1
- package/payload/server/public/assets/{ganttDiagram-T4ZO3ILL-B44jN7Cy.js → ganttDiagram-T4ZO3ILL-ClaxOJi8.js} +1 -1
- package/payload/server/public/assets/{gitGraphDiagram-UUTBAWPF-CT7iYcwg.js → gitGraphDiagram-UUTBAWPF-pM-U4ClD.js} +1 -1
- package/payload/server/public/assets/graph-B4FFYwus.js +1 -0
- package/payload/server/public/assets/graph-labels-Cpk9Ktt0.js +1 -0
- package/payload/server/public/assets/{graphlib-DP4o0pYL.js → graphlib-CwimOv_M.js} +1 -1
- package/payload/server/public/assets/{infoDiagram-42DDH7IO-CvxFpFHN.js → infoDiagram-42DDH7IO-DcO3Giwe.js} +1 -1
- package/payload/server/public/assets/{ishikawaDiagram-UXIWVN3A-CUwWLPeR.js → ishikawaDiagram-UXIWVN3A-BcdSL5VS.js} +1 -1
- package/payload/server/public/assets/{journeyDiagram-VCZTEJTY-y-OnGgLi.js → journeyDiagram-VCZTEJTY-CYahHYzf.js} +1 -1
- package/payload/server/public/assets/{kanban-definition-6JOO6SKY-BhrSe8R4.js → kanban-definition-6JOO6SKY-Cl5KhoS4.js} +1 -1
- package/payload/server/public/assets/lib--yuBd0Xi.js +33 -0
- package/payload/server/public/assets/{line-C9uS7z4J.js → line-d_2oTxLp.js} +1 -1
- package/payload/server/public/assets/{mermaid-parser.core-Cg4ZdKp-.js → mermaid-parser.core-CMMDGv3x.js} +1 -1
- package/payload/server/public/assets/{mermaid.core-BHdKOsex.js → mermaid.core-DK9ENGbr.js} +3 -3
- package/payload/server/public/assets/{mindmap-definition-QFDTVHPH-NBYiXHo7.js → mindmap-definition-QFDTVHPH-mA3x3MFG.js} +1 -1
- package/payload/server/public/assets/page-CgDmg_fX.js +1 -0
- package/payload/server/public/assets/{page-D9YpwhIu.js → page-D9lluVl7.js} +2 -2
- package/payload/server/public/assets/{pieDiagram-DEJITSTG-CbojC64C.js → pieDiagram-DEJITSTG-CW1nGFlY.js} +1 -1
- package/payload/server/public/assets/public-DdLMkNdS.js +7 -0
- package/payload/server/public/assets/{quadrantDiagram-34T5L4WZ-CnnoZXcL.js → quadrantDiagram-34T5L4WZ-DI5igJhR.js} +1 -1
- package/payload/server/public/assets/{requirementDiagram-MS252O5E-DFRFRtyJ.js → requirementDiagram-MS252O5E-DyVeI4e_.js} +1 -1
- package/payload/server/public/assets/{sankeyDiagram-XADWPNL6-DU5gcpzO.js → sankeyDiagram-XADWPNL6-CCTTBYKY.js} +1 -1
- package/payload/server/public/assets/{sequenceDiagram-FGHM5R23-BN7HZ6Hq.js → sequenceDiagram-FGHM5R23-hVVf35ly.js} +1 -1
- package/payload/server/public/assets/{stateDiagram-FHFEXIEX-DG6cCjvg.js → stateDiagram-FHFEXIEX-CSLuQDUX.js} +1 -1
- package/payload/server/public/assets/stateDiagram-v2-QKLJ7IA2-C5JejhQU.js +1 -0
- package/payload/server/public/assets/{timeline-definition-GMOUNBTQ-qmV-8SEV.js → timeline-definition-GMOUNBTQ-sxC3W8Q4.js} +1 -1
- package/payload/server/public/assets/{vennDiagram-DHZGUBPP-BMXQ1s3n.js → vennDiagram-DHZGUBPP-Ro-ton6Z.js} +1 -1
- package/payload/server/public/assets/{wardleyDiagram-NUSXRM2D-CoAdP1Gw.js → wardleyDiagram-NUSXRM2D-T-dKD0Zx.js} +1 -1
- package/payload/server/public/assets/{xychartDiagram-5P7HB3ND-CZlfGTEn.js → xychartDiagram-5P7HB3ND-CfProPts.js} +1 -1
- package/payload/server/public/data.html +4 -4
- package/payload/server/public/graph.html +5 -5
- package/payload/server/public/index.html +7 -7
- package/payload/server/public/public.html +4 -4
- package/payload/server/server.js +299 -1392
- package/payload/platform/plugins/cloudflare/scripts/__tests__/tunnel-ingress.test.ts +0 -241
- package/payload/platform/plugins/cloudflare/scripts/_stream-log.sh +0 -154
- package/payload/platform/plugins/cloudflare/scripts/list-cf-domains.sh +0 -98
- package/payload/platform/plugins/cloudflare/scripts/list-cf-domains.ts +0 -749
- package/payload/platform/plugins/cloudflare/scripts/reset-tunnel.sh +0 -107
- package/payload/platform/plugins/cloudflare/scripts/setup-tunnel.sh +0 -854
- package/payload/platform/plugins/cloudflare/scripts/tunnel-ingress.ts +0 -291
- package/payload/server/chunk-BDFOTLPW.js +0 -759
- package/payload/server/chunk-JRBCOVA4.js +0 -1305
- package/payload/server/cloudflare-task-tracker-M5ONAGUT.js +0 -22
- package/payload/server/public/assets/admin-BvzMvMGo.js +0 -217
- package/payload/server/public/assets/channel-DThrH4QF.js +0 -1
- package/payload/server/public/assets/classDiagram-6PBFFD2Q-BC6oGTNX.js +0 -1
- package/payload/server/public/assets/classDiagram-v2-HSJHXN6E-COwC5Umh.js +0 -1
- package/payload/server/public/assets/clone-Chp7hvnA.js +0 -1
- package/payload/server/public/assets/data-BAgaPs4j.js +0 -1
- package/payload/server/public/assets/graph-Cma7EArf.js +0 -1
- package/payload/server/public/assets/graph-labels-DyKk6Sxf.js +0 -1
- package/payload/server/public/assets/lib-CpkYtEDz.js +0 -29
- package/payload/server/public/assets/page-B4IWl3aZ.js +0 -1
- package/payload/server/public/assets/public-BtOXjy3A.js +0 -8
- package/payload/server/public/assets/stateDiagram-v2-QKLJ7IA2-CvVd1Q_q.js +0 -1
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
# Venture-studio data-room scaffold — deterministic enforcement of the
|
|
3
|
+
# scaffold-first principle (Task 286 + feedback_doctrine_paragraph_is_not_a_gate).
|
|
4
|
+
#
|
|
5
|
+
# Creates exactly one Project (with eight pre-seeded artefact Tasks) in
|
|
6
|
+
# the graph, then materialises the ten-section data-room directory tree
|
|
7
|
+
# on disk. The venture-studio agent's downstream skills are gated on
|
|
8
|
+
# both signals existing — see venture-studio/PLUGIN.md.
|
|
9
|
+
#
|
|
10
|
+
# Order of operations: graph write first, directories second. The CLI's
|
|
11
|
+
# duplicate-name guard makes the script safely re-runnable after any
|
|
12
|
+
# partial failure: a second run finds the existing Project, returns its
|
|
13
|
+
# id, and retries the mkdir step.
|
|
14
|
+
#
|
|
15
|
+
# Usage:
|
|
16
|
+
# ACCOUNT_ID=<uuid> scaffold.sh <project-root> <business-name>
|
|
17
|
+
#
|
|
18
|
+
# Exit codes:
|
|
19
|
+
# 0 scaffold complete (or already existed)
|
|
20
|
+
# 2 bad arguments / missing ACCOUNT_ID
|
|
21
|
+
# 1 graph write failed, directory mkdir failed, or CLI binary missing
|
|
22
|
+
|
|
23
|
+
set -euo pipefail
|
|
24
|
+
|
|
25
|
+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
26
|
+
# Deployed layout per packages/create-maxy-code/scripts/bundle.js:
|
|
27
|
+
# <install>/premium-plugins/venture-studio/bin/scaffold.sh
|
|
28
|
+
# <install>/platform/plugins/work/mcp/dist/cli/project-create-cli.js
|
|
29
|
+
CLI_BIN="${SCRIPT_DIR}/../../../platform/plugins/work/mcp/dist/cli/project-create-cli.js"
|
|
30
|
+
|
|
31
|
+
if [[ $# -ne 2 ]]; then
|
|
32
|
+
echo "scaffold.sh: usage: ACCOUNT_ID=<uuid> $0 <project-root> <business-name>" >&2
|
|
33
|
+
exit 2
|
|
34
|
+
fi
|
|
35
|
+
|
|
36
|
+
PROJECT_ROOT="$1"
|
|
37
|
+
BUSINESS_NAME="$2"
|
|
38
|
+
|
|
39
|
+
if [[ -z "${ACCOUNT_ID:-}" ]]; then
|
|
40
|
+
echo "scaffold.sh: ACCOUNT_ID env var required" >&2
|
|
41
|
+
exit 2
|
|
42
|
+
fi
|
|
43
|
+
|
|
44
|
+
if [[ ! -d "$PROJECT_ROOT" ]]; then
|
|
45
|
+
echo "scaffold.sh: project root does not exist: $PROJECT_ROOT" >&2
|
|
46
|
+
exit 2
|
|
47
|
+
fi
|
|
48
|
+
|
|
49
|
+
if [[ ! -f "$CLI_BIN" ]]; then
|
|
50
|
+
echo "scaffold.sh: project-create CLI not built or missing at: $CLI_BIN" >&2
|
|
51
|
+
exit 1
|
|
52
|
+
fi
|
|
53
|
+
|
|
54
|
+
DATA_ROOM="${PROJECT_ROOT}/.docs/data-room"
|
|
55
|
+
|
|
56
|
+
# Eight pre-seeded artefact tasks — order and names match
|
|
57
|
+
# premium-plugins/venture-studio/PLUGIN.md § First-conversation routing.
|
|
58
|
+
# Section order is preserved so the agent can walk them sequentially.
|
|
59
|
+
PAYLOAD=$(cat <<JSON
|
|
60
|
+
{
|
|
61
|
+
"accountId": "${ACCOUNT_ID}",
|
|
62
|
+
"name": "${BUSINESS_NAME}",
|
|
63
|
+
"description": "Venture-studio data room for ${BUSINESS_NAME}. Root: ${DATA_ROOM}",
|
|
64
|
+
"tier": "full",
|
|
65
|
+
"workItems": [
|
|
66
|
+
{"name": "Stage 1 — Office-hours design doc", "description": "Produces 01-narrative/office-hours-design.md via the office-hours skill."},
|
|
67
|
+
{"name": "Brand pack", "description": "Produces brand identity (palette, typography, logo) into 06-product-ip/brand/ via the brand-pack skill."},
|
|
68
|
+
{"name": "Stage 2 — Wedge validation + landing page + PRD", "description": "Produces 01-narrative/{PMF,LANDING,PRD}.md via the zero-to-prototype skill."},
|
|
69
|
+
{"name": "Stage 3 — Business plan", "description": "Produces 01-narrative/business-plan.md via investor-data-room Stage 3."},
|
|
70
|
+
{"name": "Stage 3b — Term sheet", "description": "Produces html/prospectus/term_sheet.html via investor-data-room Stage 3b."},
|
|
71
|
+
{"name": "Stage 4 — Deck blueprint", "description": "Produces 01-narrative/deck-blueprint.md via investor-data-room Stage 4."},
|
|
72
|
+
{"name": "Stage 4b — Prospectus", "description": "Produces html/prospectus/index.html via investor-data-room Stage 4b."},
|
|
73
|
+
{"name": "Stage 5 — Rendered PDFs", "description": "Produces html/{business-plan,prospectus,deck}/*.pdf via investor-data-room Stage 5."}
|
|
74
|
+
]
|
|
75
|
+
}
|
|
76
|
+
JSON
|
|
77
|
+
)
|
|
78
|
+
|
|
79
|
+
# Graph write first. CLI returns {projectId, existing:bool} on stdout;
|
|
80
|
+
# on any failure it exits non-zero with a literal stderr message that
|
|
81
|
+
# propagates here verbatim — no prose-parsing for control flow
|
|
82
|
+
# (memory: feedback_no_stdout_parsing_for_control_flow).
|
|
83
|
+
RESULT=$(node "$CLI_BIN" "$PAYLOAD")
|
|
84
|
+
echo "scaffold.sh: project-create CLI returned: $RESULT"
|
|
85
|
+
|
|
86
|
+
# Directories second. The agent's pre-flight gate keys on the existence
|
|
87
|
+
# of 01-narrative/ (it AND-checks with project-list); creating it last
|
|
88
|
+
# means partial state (graph-only) is naturally invisible to the gate
|
|
89
|
+
# until mkdir succeeds.
|
|
90
|
+
for section in \
|
|
91
|
+
01-narrative \
|
|
92
|
+
02-corporate-legal \
|
|
93
|
+
03-cap-table \
|
|
94
|
+
04-financials \
|
|
95
|
+
05-team \
|
|
96
|
+
06-product-ip \
|
|
97
|
+
07-customers \
|
|
98
|
+
08-market \
|
|
99
|
+
09-traction-metrics \
|
|
100
|
+
10-supporting; do
|
|
101
|
+
mkdir -p "${DATA_ROOM}/${section}"
|
|
102
|
+
done
|
|
103
|
+
|
|
104
|
+
echo "scaffold.sh: data-room scaffolded at ${DATA_ROOM}"
|
|
@@ -96,7 +96,9 @@ This file is the working substrate. It stays internal-only. Every later artefact
|
|
|
96
96
|
|
|
97
97
|
## Stage 2 — Data room scaffold
|
|
98
98
|
|
|
99
|
-
|
|
99
|
+
When invoked under the venture-studio agent, scaffolding is done by the deterministic script at `premium-plugins/venture-studio/bin/scaffold.sh` — it creates the Project + eight artefact Tasks and the ten-section directory tree in one atomic invocation. The script is idempotent; re-runs against an existing data room are a no-op. See `venture-studio/PLUGIN.md` § "Scaffolding script".
|
|
100
|
+
|
|
101
|
+
When invoked outside the venture-studio agent (standalone usage of this skill), build the directory tree manually. Each section gets a `README.md` that doubles as a content checklist (purpose, expected contents, current state, gaps). The graph structure is fixed: ten numbered sections (`01-narrative` through `10-supporting`) plus a top-level README and an `html/` subdirectory for rendered deliverables.
|
|
100
102
|
|
|
101
103
|
**File-naming conventions:**
|
|
102
104
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-create-cli.d.ts","sourceRoot":"","sources":["../../src/cli/project-create-cli.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
// CLI bridge for shell scripts that need to scaffold a Project + Tasks
|
|
2
|
+
// atomically (e.g. premium-plugins/venture-studio/bin/scaffold.sh). The
|
|
3
|
+
// scaffold script is the deterministic enforcement layer for the
|
|
4
|
+
// venture-studio scaffold-first principle (see Task 286 +
|
|
5
|
+
// feedback_doctrine_paragraph_is_not_a_gate); to remain deterministic it
|
|
6
|
+
// must invoke a single binary, not narrate intent for the LLM. This CLI
|
|
7
|
+
// is that binary.
|
|
8
|
+
//
|
|
9
|
+
// Contract:
|
|
10
|
+
// node project-create-cli.js '<json-payload>'
|
|
11
|
+
// payload: { accountId, name, description, tier, workItems[], createdBy }
|
|
12
|
+
// exit 0 + stdout JSON { projectId, existing: boolean } on success
|
|
13
|
+
// exit non-zero + literal stderr message on any failure
|
|
14
|
+
//
|
|
15
|
+
// Idempotency guard lives here, NOT in projectCreate(). projectCreate()
|
|
16
|
+
// always mints a fresh UUID — modifying it to MERGE on (accountId, name)
|
|
17
|
+
// would change semantics for every existing caller. The CLI runs a
|
|
18
|
+
// pre-check MATCH on (accountId, name); if a Project exists, it returns
|
|
19
|
+
// the existing projectId with existing=true and skips the write. This
|
|
20
|
+
// makes the scaffold script safely re-runnable after a partial failure
|
|
21
|
+
// (e.g. graph write succeeds but mkdir fails — second run finds the
|
|
22
|
+
// Project and only retries mkdir).
|
|
23
|
+
import { projectCreate } from "../tools/project-create.js";
|
|
24
|
+
import { getDriver } from "../lib/neo4j.js";
|
|
25
|
+
async function findExistingProject(accountId, name) {
|
|
26
|
+
const driver = getDriver();
|
|
27
|
+
const session = driver.session();
|
|
28
|
+
try {
|
|
29
|
+
const result = await session.run(`MATCH (p:Project {accountId: $accountId, name: $name})
|
|
30
|
+
RETURN p.taskId AS projectId LIMIT 1`, { accountId, name });
|
|
31
|
+
if (result.records.length === 0)
|
|
32
|
+
return null;
|
|
33
|
+
return result.records[0].get("projectId");
|
|
34
|
+
}
|
|
35
|
+
finally {
|
|
36
|
+
await session.close();
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
async function main() {
|
|
40
|
+
const raw = process.argv[2];
|
|
41
|
+
if (!raw) {
|
|
42
|
+
process.stderr.write("project-create-cli: missing JSON payload argument\n");
|
|
43
|
+
process.exit(2);
|
|
44
|
+
}
|
|
45
|
+
let payload;
|
|
46
|
+
try {
|
|
47
|
+
payload = JSON.parse(raw);
|
|
48
|
+
}
|
|
49
|
+
catch (err) {
|
|
50
|
+
process.stderr.write(`project-create-cli: malformed JSON payload: ${err.message}\n`);
|
|
51
|
+
process.exit(2);
|
|
52
|
+
}
|
|
53
|
+
if (!payload.accountId || !payload.name) {
|
|
54
|
+
process.stderr.write("project-create-cli: payload missing required field (accountId, name)\n");
|
|
55
|
+
process.exit(2);
|
|
56
|
+
}
|
|
57
|
+
const createdBy = payload.createdBy ?? {
|
|
58
|
+
tool: "project-create-cli",
|
|
59
|
+
source: "scaffold-script",
|
|
60
|
+
};
|
|
61
|
+
const existing = await findExistingProject(payload.accountId, payload.name);
|
|
62
|
+
if (existing) {
|
|
63
|
+
process.stdout.write(JSON.stringify({ projectId: existing, existing: true }) + "\n");
|
|
64
|
+
return;
|
|
65
|
+
}
|
|
66
|
+
const result = await projectCreate({
|
|
67
|
+
...payload,
|
|
68
|
+
createdBy,
|
|
69
|
+
});
|
|
70
|
+
process.stdout.write(JSON.stringify({ projectId: result.projectId, existing: false, childTaskIds: result.childTaskIds }) + "\n");
|
|
71
|
+
}
|
|
72
|
+
main()
|
|
73
|
+
.then(() => process.exit(0))
|
|
74
|
+
.catch((err) => {
|
|
75
|
+
process.stderr.write(`project-create-cli: ${err.message}\n`);
|
|
76
|
+
process.exit(1);
|
|
77
|
+
});
|
|
78
|
+
//# sourceMappingURL=project-create-cli.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-create-cli.js","sourceRoot":"","sources":["../../src/cli/project-create-cli.ts"],"names":[],"mappings":"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"}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Build-time gate: rejects `(Task NNN)` citations in operator-visible production
|
|
3
3
|
// strings. Citations are allowed in inline comments and test titles/bodies only.
|
|
4
4
|
//
|
|
5
|
-
// Live repro that motivated the gate: setup
|
|
5
|
+
// Live repro that motivated the gate: a setup script on realagent 192.168.88.8
|
|
6
6
|
// emitted `Re-run the installer to provision Chromium.` to the
|
|
7
7
|
// operator's chat surface — the citation made the operator chase task
|
|
8
8
|
// history rather than execute the verb. Operator surfaces strip citations;
|
|
@@ -323,9 +323,10 @@ start_chrome() {
|
|
|
323
323
|
}
|
|
324
324
|
|
|
325
325
|
# ---------------------------------------------------------------------------
|
|
326
|
-
#
|
|
327
|
-
#
|
|
328
|
-
# the
|
|
326
|
+
# Retired in Task 287: the admin-UI terminal and browser-overlay surfaces
|
|
327
|
+
# are gone. This script still launches Chromium for legacy installs where
|
|
328
|
+
# the brand VNC is used for ad-hoc operator browsing; on maxy-code the
|
|
329
|
+
# admin chat PTY is the only interactive surface.
|
|
329
330
|
# ---------------------------------------------------------------------------
|
|
330
331
|
|
|
331
332
|
start_chrome_native() {
|
|
@@ -10,7 +10,7 @@ Your job is to do useful work for the operator. How useful you can be depends on
|
|
|
10
10
|
|
|
11
11
|
## Before you speak
|
|
12
12
|
|
|
13
|
-
Before your first message, do reconnaissance. Treat your starting knowledge as whatever your tools can surface, not what the system prompt names. Search the memory graph for what's known about the operator and their business, read the profile, check today's calendar, active projects, open work, and recent conversations. Infer the domain from the plugins and skills installed; they were chosen for a reason and are evidence of what this operation does.
|
|
13
|
+
Before your first message, do reconnaissance. Treat your starting knowledge as whatever your tools can surface, not what the system prompt names. Search the memory graph for what's known about the operator and their business, read the profile, check today's calendar, active projects, open work, and recent conversations. Infer the domain from the plugins and skills installed; they were chosen for a reason and are evidence of what this operation does. Check whether an upgrade is available for this install (the upgrade skill describes the lookup); if so, offer it in your first message.
|
|
14
14
|
|
|
15
15
|
Then lead with what you found. When you have enough knowledge of the operator and their business to make a useful proposal, follow with one suited to where they are in their day; otherwise, gather more before proposing. Ask only the questions you genuinely could not answer through investigation. You are expected to drive the day, not to solicit instructions for it.
|
|
16
16
|
|
|
@@ -23,13 +23,44 @@ Outcome (binding):
|
|
|
23
23
|
|
|
24
24
|
Constraint (binding): **No downstream venture-studio skill (`brand-pack`, `zero-to-prototype`, `investor-data-room` Stages 3+, etc.) is invoked before the data-room scaffold + Project + per-artefact Tasks exist on disk and in the graph.** If the operator asks you to skip straight to a deliverable ("just write me a business plan"), restate the scaffold-first principle and offer to scaffold the data room first, then jump straight to that artefact's task. The principle is the outcome contract; the scaffold proves it.
|
|
25
25
|
|
|
26
|
+
### Deterministic pre-flight gate
|
|
27
|
+
|
|
28
|
+
Before invoking any downstream skill, both checks below must pass. Both are deterministic — exit-code on `ls`, structured output on `project-list`. Neither check depends on LLM judgement.
|
|
29
|
+
|
|
30
|
+
1. **Directory check:** `[ -d "${PROJECT_ROOT}/.docs/data-room/01-narrative" ]` returns exit 0.
|
|
31
|
+
2. **Graph check:** the `project-list` tool returns a Project whose `name` matches the business's working name.
|
|
32
|
+
|
|
33
|
+
If either check fails, run the scaffolding script (see below) before the skill fires. If the script fails, surface the literal stderr error to the operator — do not narrate around it (memory: [[feedback_no_stdout_parsing_for_control_flow]]).
|
|
34
|
+
|
|
35
|
+
### Scaffolding script
|
|
36
|
+
|
|
37
|
+
`bin/scaffold.sh` is the deterministic enforcement layer. It creates the Project + eight artefact Tasks (via the work plugin's `project-create-cli` bridge) and materialises the ten-section directory tree. Graph write first, directories second; idempotent re-run if any partial state lands.
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
ACCOUNT_ID="${ACCOUNT_ID}" \
|
|
41
|
+
premium-plugins/venture-studio/bin/scaffold.sh \
|
|
42
|
+
"${PROJECT_ROOT}" \
|
|
43
|
+
"${BUSINESS_NAME}"
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
The script is the binding check, not the prose principle above. The prose explains why; the script is what makes it true.
|
|
47
|
+
|
|
26
48
|
## First-conversation routing
|
|
27
49
|
|
|
28
|
-
When the operator first invokes this agent, confirm the intent ("Are we founding a new business, or working on an existing one?") and run the scaffolding
|
|
50
|
+
When the operator first invokes this agent, confirm the intent ("Are we founding a new business, or working on an existing one?") and run the scaffolding script — it does steps 1–3 below in a single atomic invocation:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
ACCOUNT_ID="${ACCOUNT_ID}" \
|
|
54
|
+
premium-plugins/venture-studio/bin/scaffold.sh \
|
|
55
|
+
"${PROJECT_ROOT}" \
|
|
56
|
+
"${BUSINESS_NAME}"
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
The script's three effects:
|
|
29
60
|
|
|
30
|
-
1. **
|
|
31
|
-
2. **
|
|
32
|
-
3. **
|
|
61
|
+
1. **Scaffolds the data room.** Materialises the ten-section directory tree under `<project-root>/.docs/data-room/`. Every artefact has a slot to land in before any artefact is produced.
|
|
62
|
+
2. **Creates the `Project` node.** Tier `full` (data-room work is multi-phase). Project name is the business's working name; description references the data-room root path.
|
|
63
|
+
3. **Enumerates the eight artefact Tasks** in section order — one transaction, atomic with the Project. The work-item list the script pre-seeds:
|
|
33
64
|
- **Stage 1 — Office-hours design doc** → produces `01-narrative/office-hours-design.md` (skill: `office-hours`)
|
|
34
65
|
- **Brand pack** → produces brand identity files into `06-product-ip/brand/` (skill: `brand-pack`)
|
|
35
66
|
- **Stage 2 — Wedge validation + landing page + PRD** → produces `01-narrative/{PMF, LANDING, PRD}.md` (skill: `zero-to-prototype`)
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
# Venture-studio data-room scaffold — deterministic enforcement of the
|
|
3
|
+
# scaffold-first principle (Task 286 + feedback_doctrine_paragraph_is_not_a_gate).
|
|
4
|
+
#
|
|
5
|
+
# Creates exactly one Project (with eight pre-seeded artefact Tasks) in
|
|
6
|
+
# the graph, then materialises the ten-section data-room directory tree
|
|
7
|
+
# on disk. The venture-studio agent's downstream skills are gated on
|
|
8
|
+
# both signals existing — see venture-studio/PLUGIN.md.
|
|
9
|
+
#
|
|
10
|
+
# Order of operations: graph write first, directories second. The CLI's
|
|
11
|
+
# duplicate-name guard makes the script safely re-runnable after any
|
|
12
|
+
# partial failure: a second run finds the existing Project, returns its
|
|
13
|
+
# id, and retries the mkdir step.
|
|
14
|
+
#
|
|
15
|
+
# Usage:
|
|
16
|
+
# ACCOUNT_ID=<uuid> scaffold.sh <project-root> <business-name>
|
|
17
|
+
#
|
|
18
|
+
# Exit codes:
|
|
19
|
+
# 0 scaffold complete (or already existed)
|
|
20
|
+
# 2 bad arguments / missing ACCOUNT_ID
|
|
21
|
+
# 1 graph write failed, directory mkdir failed, or CLI binary missing
|
|
22
|
+
|
|
23
|
+
set -euo pipefail
|
|
24
|
+
|
|
25
|
+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
26
|
+
# Deployed layout per packages/create-maxy-code/scripts/bundle.js:
|
|
27
|
+
# <install>/premium-plugins/venture-studio/bin/scaffold.sh
|
|
28
|
+
# <install>/platform/plugins/work/mcp/dist/cli/project-create-cli.js
|
|
29
|
+
CLI_BIN="${SCRIPT_DIR}/../../../platform/plugins/work/mcp/dist/cli/project-create-cli.js"
|
|
30
|
+
|
|
31
|
+
if [[ $# -ne 2 ]]; then
|
|
32
|
+
echo "scaffold.sh: usage: ACCOUNT_ID=<uuid> $0 <project-root> <business-name>" >&2
|
|
33
|
+
exit 2
|
|
34
|
+
fi
|
|
35
|
+
|
|
36
|
+
PROJECT_ROOT="$1"
|
|
37
|
+
BUSINESS_NAME="$2"
|
|
38
|
+
|
|
39
|
+
if [[ -z "${ACCOUNT_ID:-}" ]]; then
|
|
40
|
+
echo "scaffold.sh: ACCOUNT_ID env var required" >&2
|
|
41
|
+
exit 2
|
|
42
|
+
fi
|
|
43
|
+
|
|
44
|
+
if [[ ! -d "$PROJECT_ROOT" ]]; then
|
|
45
|
+
echo "scaffold.sh: project root does not exist: $PROJECT_ROOT" >&2
|
|
46
|
+
exit 2
|
|
47
|
+
fi
|
|
48
|
+
|
|
49
|
+
if [[ ! -f "$CLI_BIN" ]]; then
|
|
50
|
+
echo "scaffold.sh: project-create CLI not built or missing at: $CLI_BIN" >&2
|
|
51
|
+
exit 1
|
|
52
|
+
fi
|
|
53
|
+
|
|
54
|
+
DATA_ROOM="${PROJECT_ROOT}/.docs/data-room"
|
|
55
|
+
|
|
56
|
+
# Eight pre-seeded artefact tasks — order and names match
|
|
57
|
+
# premium-plugins/venture-studio/PLUGIN.md § First-conversation routing.
|
|
58
|
+
# Section order is preserved so the agent can walk them sequentially.
|
|
59
|
+
PAYLOAD=$(cat <<JSON
|
|
60
|
+
{
|
|
61
|
+
"accountId": "${ACCOUNT_ID}",
|
|
62
|
+
"name": "${BUSINESS_NAME}",
|
|
63
|
+
"description": "Venture-studio data room for ${BUSINESS_NAME}. Root: ${DATA_ROOM}",
|
|
64
|
+
"tier": "full",
|
|
65
|
+
"workItems": [
|
|
66
|
+
{"name": "Stage 1 — Office-hours design doc", "description": "Produces 01-narrative/office-hours-design.md via the office-hours skill."},
|
|
67
|
+
{"name": "Brand pack", "description": "Produces brand identity (palette, typography, logo) into 06-product-ip/brand/ via the brand-pack skill."},
|
|
68
|
+
{"name": "Stage 2 — Wedge validation + landing page + PRD", "description": "Produces 01-narrative/{PMF,LANDING,PRD}.md via the zero-to-prototype skill."},
|
|
69
|
+
{"name": "Stage 3 — Business plan", "description": "Produces 01-narrative/business-plan.md via investor-data-room Stage 3."},
|
|
70
|
+
{"name": "Stage 3b — Term sheet", "description": "Produces html/prospectus/term_sheet.html via investor-data-room Stage 3b."},
|
|
71
|
+
{"name": "Stage 4 — Deck blueprint", "description": "Produces 01-narrative/deck-blueprint.md via investor-data-room Stage 4."},
|
|
72
|
+
{"name": "Stage 4b — Prospectus", "description": "Produces html/prospectus/index.html via investor-data-room Stage 4b."},
|
|
73
|
+
{"name": "Stage 5 — Rendered PDFs", "description": "Produces html/{business-plan,prospectus,deck}/*.pdf via investor-data-room Stage 5."}
|
|
74
|
+
]
|
|
75
|
+
}
|
|
76
|
+
JSON
|
|
77
|
+
)
|
|
78
|
+
|
|
79
|
+
# Graph write first. CLI returns {projectId, existing:bool} on stdout;
|
|
80
|
+
# on any failure it exits non-zero with a literal stderr message that
|
|
81
|
+
# propagates here verbatim — no prose-parsing for control flow
|
|
82
|
+
# (memory: feedback_no_stdout_parsing_for_control_flow).
|
|
83
|
+
RESULT=$(node "$CLI_BIN" "$PAYLOAD")
|
|
84
|
+
echo "scaffold.sh: project-create CLI returned: $RESULT"
|
|
85
|
+
|
|
86
|
+
# Directories second. The agent's pre-flight gate keys on the existence
|
|
87
|
+
# of 01-narrative/ (it AND-checks with project-list); creating it last
|
|
88
|
+
# means partial state (graph-only) is naturally invisible to the gate
|
|
89
|
+
# until mkdir succeeds.
|
|
90
|
+
for section in \
|
|
91
|
+
01-narrative \
|
|
92
|
+
02-corporate-legal \
|
|
93
|
+
03-cap-table \
|
|
94
|
+
04-financials \
|
|
95
|
+
05-team \
|
|
96
|
+
06-product-ip \
|
|
97
|
+
07-customers \
|
|
98
|
+
08-market \
|
|
99
|
+
09-traction-metrics \
|
|
100
|
+
10-supporting; do
|
|
101
|
+
mkdir -p "${DATA_ROOM}/${section}"
|
|
102
|
+
done
|
|
103
|
+
|
|
104
|
+
echo "scaffold.sh: data-room scaffolded at ${DATA_ROOM}"
|
|
@@ -96,7 +96,9 @@ This file is the working substrate. It stays internal-only. Every later artefact
|
|
|
96
96
|
|
|
97
97
|
## Stage 2 — Data room scaffold
|
|
98
98
|
|
|
99
|
-
|
|
99
|
+
When invoked under the venture-studio agent, scaffolding is done by the deterministic script at `premium-plugins/venture-studio/bin/scaffold.sh` — it creates the Project + eight artefact Tasks and the ten-section directory tree in one atomic invocation. The script is idempotent; re-runs against an existing data room are a no-op. See `venture-studio/PLUGIN.md` § "Scaffolding script".
|
|
100
|
+
|
|
101
|
+
When invoked outside the venture-studio agent (standalone usage of this skill), build the directory tree manually. Each section gets a `README.md` that doubles as a content checklist (purpose, expected contents, current state, gaps). The graph structure is fixed: ten numbered sections (`01-narrative` through `10-supporting`) plus a top-level README and an `html/` subdirectory for rendered deliverables.
|
|
100
102
|
|
|
101
103
|
**File-naming conventions:**
|
|
102
104
|
|