@llamaventures/cli 1.26.0 → 2.0.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/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@llamaventures/cli",
3
- "version": "1.26.0",
3
+ "version": "2.0.1",
4
4
  "description": "CLI + MCP server for the Llama Ventures investment workbench (command.llamaventures.vc).",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "test": "npm run test:agent-routing && npm run test:contract",
8
8
  "test:agent-routing": "node scripts/verify-agent-routing.mjs",
9
- "test:contract": "node --test scripts/build-manifest.test.mjs scripts/core-api-call-sites.test.mjs scripts/investment-workflow-contract.test.mjs scripts/memo-retirement.test.mjs scripts/server-compatibility.test.mjs scripts/verify-core-api-contract.test.mjs scripts/workflow-audit.test.mjs scripts/workflow-remediation.test.mjs && node scripts/verify-core-api-contract.mjs",
9
+ "test:contract": "node --test scripts/build-manifest.test.mjs scripts/core-api-call-sites.test.mjs scripts/deal-actions-cli.test.mjs scripts/deal-actions.test.mjs scripts/mcp-four-action-surface.test.mjs scripts/server-compatibility.test.mjs scripts/verify-core-api-contract.test.mjs && node scripts/verify-core-api-contract.mjs",
10
10
  "verify:artifact": "node scripts/verify-release-artifact.mjs",
11
11
  "verify:release": "npm test && npm run verify:artifact && node scripts/verify-tarball-clean.mjs",
12
12
  "prepack": "node scripts/prepare-build-manifest.mjs",
@@ -1,19 +0,0 @@
1
- # Investment Workflow V2 client contract
2
-
3
- CLI and MCP treat `GET/POST /api/deals/{dealId}/workflow` as the only workflow
4
- read/write surface. A write must first read the current revision, submit one
5
- typed command with a unique request id, and display the canonical response.
6
-
7
- Never add a client shortcut that writes `deals.status`,
8
- `extra.investment_workflow_v2` snapshots, `extra.stage_gates`, or
9
- `extra.stage4_gate`. Partner
10
- decisions are always made by the authenticated Partner; admin capability does
11
- not imply permission to impersonate a decision maker.
12
-
13
- `workflow initialize` is the audited bootstrap command for legacy migration.
14
- It persists the state returned by `workflow show` without advancing a stage or
15
- resolving a guard. Never translate legacy approvals into V2 approvals silently.
16
-
17
- Post-IC compatibility status is also owned by V2. Use `workflow
18
- execution-status` / `workflow_update_execution_status` for Term Sheet, Verbal
19
- Commit, and Invested; never reopen direct `deal update ... status` writes.
@@ -1,13 +0,0 @@
1
- export function workflowAuditPath(flags) {
2
- const deal = typeof flags.deal === "string" && flags.deal.trim()
3
- ? flags.deal.trim()
4
- : null;
5
- const all = flags.all === true;
6
- if ((!deal && !all) || (deal && all)) {
7
- throw new Error("Usage: llama admin workflow audit --deal <uuid> | --all");
8
- }
9
- const params = new URLSearchParams();
10
- if (deal) params.set("deal", deal);
11
- if (all) params.set("all", "true");
12
- return `/api/admin/workflow-audit?${params.toString()}`;
13
- }
@@ -1,45 +0,0 @@
1
- export const WORKFLOW_REMEDIATION_PATH = "/api/admin/workflow-remediation";
2
- export const WORKFLOW_REMEDIATION_GUARDS = [
3
- "intake.founder_identity",
4
- "intake.reason_why",
5
- ];
6
-
7
- export function workflowRemediationBody(flags, requestId) {
8
- const dealId = typeof flags.deal === "string" ? flags.deal.trim() : "";
9
- const rawGuards = typeof flags.guard === "string" ? flags.guard : "";
10
- const guardKeys = [...new Set(
11
- rawGuards.split(",").map((value) => value.trim()).filter(Boolean),
12
- )];
13
- if (!dealId || guardKeys.length < 1 || guardKeys.length > 2 ||
14
- guardKeys.some((key) => !WORKFLOW_REMEDIATION_GUARDS.includes(key))) {
15
- throw new Error(
16
- "Usage: llama admin workflow remediate --deal <uuid> " +
17
- "--guard intake.reason_why[,intake.founder_identity] " +
18
- "[--apply --expected-revision <n> --reason \"...\"]",
19
- );
20
- }
21
-
22
- if (flags.apply !== true) {
23
- if (flags["expected-revision"] !== undefined || flags.reason !== undefined) {
24
- throw new Error("--expected-revision and --reason require --apply");
25
- }
26
- return { action: "preview", dealId, guardKeys };
27
- }
28
-
29
- const expectedRevision = Number(flags["expected-revision"]);
30
- const reason = typeof flags.reason === "string" ? flags.reason.trim() : "";
31
- if (!Number.isInteger(expectedRevision) || expectedRevision < 0 || !reason) {
32
- throw new Error("--apply requires --expected-revision <n> from preview and --reason \"...\"");
33
- }
34
- if (typeof requestId !== "string" || !requestId) {
35
- throw new Error("workflow remediation apply requires a request ID");
36
- }
37
- return {
38
- action: "apply",
39
- dealId,
40
- guardKeys,
41
- expectedRevision,
42
- requestId,
43
- reason,
44
- };
45
- }