@deepraxis/cli 0.2.2-dev.d73d5e4 → 0.2.2-dev.f2537d2

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/COMMANDS.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Generated by `bun run commands`. DO NOT EDIT.
4
4
 
5
- 619 HTTP operations; 621 commands including aliases.
5
+ 620 HTTP operations; 622 commands including aliases.
6
6
 
7
7
  Environment: `PRAXIS_ENV=develop|production` (dev package defaults to `develop`; stable package defaults to `production`). No `--env` option.
8
8
 
@@ -457,6 +457,7 @@ Handwritten commands: `login`, `logout`, `whoami`, `org list`, `org switch <orga
457
457
  | `praxis api ontology changeset create` | `ontology.changesets.create` | POST `/ontology/v1/changesets` | `--at`, `--scope` |
458
458
  | `praxis api ontology node create` | `ontology.nodes.create` | POST `/ontology/v1/nodes` | `--type`, `--ref`, `--name`, `--aliases`, `--description`, `--owner` |
459
459
  | `praxis api ontology node get <node_id>` | `ontology.nodes.retrieve` | GET `/ontology/v1/nodes/{node_id}` | `--expand`, `--as-of` |
460
+ | `praxis api ontology node get-neighborhood <node_id>` | `ontology.nodes.retrieveNeighborhood` | GET `/ontology/v1/nodes/{node_id}/neighborhood` | `--depth`, `--param-limit`, `--direction`, `--as-of`, `--include-invalid` |
460
461
  | `praxis api ontology node list` | `ontology.nodes.list` | GET `/ontology/v1/nodes` | `--type`, `--q`, `--owner`, `--as-of`, `--param-limit`, `--param-cursor` |
461
462
  | `praxis api ontology node merge create` | `ontology.nodes.merge.create` | POST `/ontology/v1/nodes/{node_id}/merge` | `--node`, `--into` |
462
463
  | `praxis api ontology node update <node_id>` | `ontology.nodes.update` | PATCH `/ontology/v1/nodes/{node_id}` | `--name`, `--aliases`, `--description` |
package/dist/praxis.js CHANGED
@@ -17012,7 +17012,7 @@ Execution errors include error.details.prints containing output printed before f
17012
17012
  name: "to",
17013
17013
  type: "number",
17014
17014
  required: false,
17015
- description: "Range end for kind mix, in seconds on the project clock, exclusive. A range longer than 120 seconds is refused; request several ranges instead."
17015
+ description: "Range end for kind mix, in seconds on the project clock, exclusive. An end up to 0.05 s past the timeline's end (a rounded duration) is read as the end; further past is refused. A range longer than 120 seconds is refused; request several ranges instead."
17016
17016
  },
17017
17017
  {
17018
17018
  name: "revision",
@@ -17166,7 +17166,7 @@ Execution errors include error.details.prints containing output printed before f
17166
17166
  name: "folder",
17167
17167
  type: "string",
17168
17168
  required: false,
17169
- description: "Optional destination path within the bound media library; omitted uses its default folder."
17169
+ description: "Optional destination path within the bound media library; omitted uses its default folder. Naming a binding or a folder also imports the finished video into that media library as an asset. Omit both and the export is a file only: read file.url to download it."
17170
17170
  },
17171
17171
  {
17172
17172
  name: "name",
@@ -17184,7 +17184,7 @@ Execution errors include error.details.prints containing output printed before f
17184
17184
  name: "binding",
17185
17185
  type: "string",
17186
17186
  required: false,
17187
- description: "Writable binding name used as the export destination; omission uses default_upload."
17187
+ description: "Writable binding name used as the export destination; omission uses default_upload. Naming a binding or a folder also imports the finished video into that media library as an asset. Omit both and the export is a file only; read file.url to download it."
17188
17188
  },
17189
17189
  {
17190
17190
  name: "revision",
@@ -17289,7 +17289,7 @@ Execution errors include error.details.prints containing output printed before f
17289
17289
  resource: "cut.projects.renders",
17290
17290
  method: "create",
17291
17291
  summary: "Create draft range render",
17292
- description: "Render one interval of the timeline so you can hear or look at how that passage comes out, without publishing anything to a media library. Choose kind audio for the mixed soundtrack as an .m4a file, or kind video for a draft-quality .mp4 with picture and sound. from and to are seconds on the project clock and must satisfy 0 <= from < to, to <= the timeline duration, and to - from <= 120; a longer passage is requested in several 分段请求 ranges and joined by the caller. The result is a temporary file (purpose user_data) that expires 24 hours after it is stored and is never imported into a library, so it is not a deliverable and carries no cut-export tag. HTTP 202 only accepts the job; poll praxis.cut.renders.retrieve using the returned id until status is done or failed, then read url while it lasts. A draft also bills like a draft export, by rendered seconds. Each project runs at most 2 draft renders at a time, a budget separate from its exports; a third answers HTTP 429 CUT_BUSY and the same call succeeds once one finishes.",
17292
+ description: "Render one interval of the timeline so you can hear or look at how that passage comes out, without publishing anything to a media library. Choose kind audio for the mixed soundtrack as an .m4a file, or kind video for a draft-quality .mp4 with picture and sound. from and to are seconds on the project clock and must satisfy 0 <= from < to, to <= the timeline duration (an end up to 0.05 s past it, a rounded duration, is read as the end), and to - from <= 120; a longer passage is requested in several 分段请求 ranges and joined by the caller. The result is a temporary file (purpose user_data) that expires 24 hours after it is stored and is never imported into a library, so it is not a deliverable and carries no cut-export tag. HTTP 202 only accepts the job; poll praxis.cut.renders.retrieve using the returned id until status is done or failed, then read url while it lasts. A draft also bills like a draft export, by rendered seconds. Each project runs at most 2 draft renders at a time, a budget separate from its exports; a third answers HTTP 429 CUT_BUSY and the same call succeeds once one finishes.",
17293
17293
  http: "POST",
17294
17294
  path: "/cut/v1/projects/{project_id}/renders",
17295
17295
  streaming: "no",
@@ -24652,7 +24652,7 @@ for more details.`
24652
24652
  resource: "ontology.nodes",
24653
24653
  method: "create",
24654
24654
  summary: "Create node",
24655
- description: "Record one entity in the graph, for a system mirroring a record it owns. type must already be registered and ref, when given, must match that type's ref_prefix. Send an Idempotency-Key header; repeating the same key with the same content returns the first result instead of creating a second node. This writes structure only — to give an agent something to remember, use POST /agent/v1/agents/{agent_id}/consolidations.",
24655
+ description: "Record one entity in the graph, for a system mirroring a record it owns. type must already be registered and ref, when given, must match that type's ref_prefix. Send an Idempotency-Key header; repeating the same key with the same content returns the first result instead of creating a second node. This writes structure only; it does not give any agent a memory.",
24656
24656
  http: "POST",
24657
24657
  path: "/ontology/v1/nodes",
24658
24658
  streaming: "no",
@@ -24807,6 +24807,60 @@ for more details.`
24807
24807
  ]
24808
24808
  }
24809
24809
  },
24810
+ {
24811
+ resource: "ontology.nodes",
24812
+ method: "retrieveNeighborhood",
24813
+ summary: "Retrieve neighborhood",
24814
+ description: "Load the subgraph around one node instead of the whole graph — the read to use when a screen or an agent needs the context of one entity. Returns the start node, every node within depth hops of it, the relations whose both ends are in that set, and truncated true when the node limit cut the walk short. direction chooses which way relations are followed; as_of and include_invalid read the graph as those parameters do elsewhere. Visibility is exactly nodes.retrieve's — a node you may reach but not read comes back restricted with its name only, and relations touching it are withheld, so this read never reaches further than a node read does. The node id comes from nodes.list, nodes.create or a changeset; an unknown one answers ONTOLOGY_NODE_NOT_FOUND, the same answer nodes.retrieve gives.",
24815
+ http: "GET",
24816
+ path: "/ontology/v1/nodes/{node_id}/neighborhood",
24817
+ streaming: "no",
24818
+ pagination: false,
24819
+ pathParams: [
24820
+ {
24821
+ name: "node_id",
24822
+ sdkName: "node_id",
24823
+ description: "Node id returned by nodes.list, nodes.create or a changeset, in the form ond_ followed by 32 lowercase letters or digits; a name or an external record id is not accepted."
24824
+ }
24825
+ ],
24826
+ query: [
24827
+ {
24828
+ name: "depth",
24829
+ type: "integer",
24830
+ required: false,
24831
+ description: "How many hops from the given node to walk, 1 to 3; defaults to 1. A value outside that range is refused 400 rather than clamped, so the answer is never a smaller graph than the one asked for."
24832
+ },
24833
+ {
24834
+ name: "limit",
24835
+ type: "integer",
24836
+ required: false,
24837
+ description: "Maximum nodes to return, 1 to 500; defaults to 200. When the walk reaches this many nodes it stops and reports truncated true, so treat a truncated answer as a sample of the neighborhood rather than all of it. This bound is not the list routes' page size, and there is no cursor to resume from."
24838
+ },
24839
+ {
24840
+ name: "direction",
24841
+ type: "string",
24842
+ enum: [
24843
+ "out",
24844
+ "in",
24845
+ "both"
24846
+ ],
24847
+ required: false,
24848
+ description: "Which way to follow relations from each node walked; out follows relations the node is the source of, in follows those it is the target of, both follows either. Defaults to both. Relations between two returned nodes are included whichever direction brought the second node in."
24849
+ },
24850
+ {
24851
+ name: "as_of",
24852
+ type: "string",
24853
+ required: false,
24854
+ description: "ISO 8601 timestamp; walk the graph as it was then — a node recorded later is absent and a relation invalidated since still counts. Omit to read current state."
24855
+ },
24856
+ {
24857
+ name: "include_invalid",
24858
+ type: "boolean",
24859
+ required: false,
24860
+ description: "Set true to walk relations whose invalid_at has passed, which is how a fact that stopped being true stays reachable. Omit or false to walk currently valid relations only."
24861
+ }
24862
+ ]
24863
+ },
24810
24864
  {
24811
24865
  resource: "ontology.relations",
24812
24866
  method: "list",
@@ -24872,7 +24926,7 @@ for more details.`
24872
24926
  resource: "ontology.relations",
24873
24927
  method: "create",
24874
24928
  summary: "Create relation",
24875
- description: "Record one fact between two existing nodes, for a system mirroring a relationship it owns. type must be registered and must admit these endpoints; fact states the relationship in one sentence. Send an Idempotency-Key header; repeating the same key returns the first result instead of writing a second relation. This writes structure only — to give an agent something to remember, use POST /agent/v1/agents/{agent_id}/consolidations.",
24929
+ description: "Record one fact between two existing nodes, for a system mirroring a relationship it owns. type must be registered and must admit these endpoints; fact states the relationship in one sentence. Send an Idempotency-Key header; repeating the same key returns the first result instead of writing a second relation. This writes structure only; it does not give any agent a memory.",
24876
24930
  http: "POST",
24877
24931
  path: "/ontology/v1/relations",
24878
24932
  streaming: "no",
@@ -24984,7 +25038,7 @@ for more details.`
24984
25038
  resource: "ontology.search",
24985
25039
  method: "create",
24986
25040
  summary: "Search nodes",
24987
- description: "Resolve text to the nodes it most likely names, when a mirror holds a name and needs the node id it corresponds to. Results are ranked candidates, not an answer, each reporting whether the match came from the node's name, an alias, its description or a relation's fact. Narrow with types, and cap the result count with limit (1–50, default 20). This reads structure; it is not an agent recall — agents recall through POST /agent/v1/agents/{agent_id}/consolidations.",
25041
+ description: "Resolve text to the nodes it most likely names, when a mirror holds a name and needs the node id it corresponds to. Results are ranked candidates, not an answer, each reporting whether the match came from the node's name, an alias, its description or a relation's fact. Narrow with types, and cap the result count with limit (1–50, default 20). This reads structure; it is not an agent's recall, which reads the graph from that agent's own viewpoint inside its sessions.",
24988
25042
  http: "POST",
24989
25043
  path: "/ontology/v1/search",
24990
25044
  streaming: "no",
@@ -38965,6 +39019,15 @@ var ontologyUpdateNode = (options) => (options.client ?? client).patch({
38965
39019
  ...options.headers
38966
39020
  }
38967
39021
  });
39022
+ var ontologyNeighborhood = (options) => (options.client ?? client).get({
39023
+ security: [{
39024
+ key: "ontology-bearerAuth",
39025
+ scheme: "bearer",
39026
+ type: "http"
39027
+ }],
39028
+ url: "/ontology/v1/nodes/{node_id}/neighborhood",
39029
+ ...options
39030
+ });
38968
39031
  var ontologyMergeNode = (options) => (options.client ?? client).post({
38969
39032
  security: [{
38970
39033
  key: "ontology-bearerAuth",
@@ -42491,6 +42554,7 @@ function createOntology(transport) {
42491
42554
  create: bind(transport, ontologyMergeNode)
42492
42555
  },
42493
42556
  retrieve: bind(transport, ontologyRetrieveNode),
42557
+ retrieveNeighborhood: bind(transport, ontologyNeighborhood),
42494
42558
  update: bind(transport, ontologyUpdateNode)
42495
42559
  },
42496
42560
  relations: {
@@ -43731,7 +43795,7 @@ async function connectActions(deps, settings) {
43731
43795
  home: settings.home,
43732
43796
  fs,
43733
43797
  now: settings.now,
43734
- fetch: deps.fetch ?? globalThis.fetch
43798
+ fetch: deps.fetch ?? globalThis.fetch.bind(globalThis)
43735
43799
  });
43736
43800
  const noPlaywright = () => new PraxisError({
43737
43801
  status: 501,
@@ -46057,6 +46121,13 @@ function workerNameOf(config) {
46057
46121
  const name = config?.name;
46058
46122
  return typeof name === "string" && name !== "" ? name : undefined;
46059
46123
  }
46124
+ function productionBlockOf(config) {
46125
+ const env = config?.env;
46126
+ if (env === null || typeof env !== "object")
46127
+ return;
46128
+ const block = env.production;
46129
+ return block !== null && typeof block === "object" ? block : undefined;
46130
+ }
46060
46131
  function bindingReferences(config) {
46061
46132
  const references = [];
46062
46133
  const own = workerNameOf(config);
@@ -46383,7 +46454,9 @@ function workspaceCloudflareProvider(options = {}) {
46383
46454
  name: workspace.packageName ?? (workspace.dir === "." ? "app" : workspace.dir.split("/").at(-1)),
46384
46455
  destination: "cloudflare",
46385
46456
  ...workspace.workerName === undefined ? {} : { workerName: workspace.workerName },
46386
- ...environments === undefined ? {} : { environments }
46457
+ ...environments === undefined ? {} : { environments },
46458
+ production: productionBlockOf(workspace.config) !== undefined,
46459
+ onTrain: lifecycle?.train !== false
46387
46460
  });
46388
46461
  }
46389
46462
  return { targets: [...partial.targets, ...targets] };
@@ -46439,12 +46512,24 @@ function closePlan(drafts, workspaces) {
46439
46512
  destination: draft.destination,
46440
46513
  dependsOn: edges.get(draft.path) ?? [],
46441
46514
  ...draft.environments === undefined ? {} : { environments: draft.environments },
46515
+ production: draft.production === true,
46516
+ onTrain: draft.onTrain !== false,
46442
46517
  workspaceDeps: workspaceClosureOf(draft.path, byName, dependenciesOf)
46443
46518
  })).sort((a, b) => a.path.localeCompare(b.path));
46444
46519
  }
46445
46520
  function targetsFor(plan, environment2) {
46446
46521
  return plan.targets.filter((target) => target.environments === undefined || target.environments.includes(environment2));
46447
46522
  }
46523
+ var TARGET_EXTERNAL_INPUTS = {
46524
+ "apps/docs": [
46525
+ "apps/api/openapi/openapi.yaml",
46526
+ "packages/praxis/rpc-kit/src/errors.ts",
46527
+ "services/agent/src/domain/error-codes.ts",
46528
+ ...["application", "database", "knowledge"].map((s) => `services/${s}/src/api/error-exit.ts`),
46529
+ ...["router", "vault", "browser", "search"].map((s) => `services/${s}/src/api/rpc-contract.ts`),
46530
+ ...["media", "automation", "sandbox", "file", "billing", "config", "eventbus", "lakehouse", "identity", "notification", "ops", "registry"].map((s) => `services/${s}/src/api/contract.ts`)
46531
+ ]
46532
+ };
46448
46533
  function diffTargets(plan, changedPaths) {
46449
46534
  const changed = new Set(changedPaths);
46450
46535
  const touches = (dir) => {
@@ -46456,7 +46541,8 @@ function diffTargets(plan, changedPaths) {
46456
46541
  return true;
46457
46542
  return false;
46458
46543
  };
46459
- return plan.targets.filter((target) => touches(target.path) || target.workspaceDeps.some(touches)).map((target) => target.path);
46544
+ const readsChangedInput = (dir) => (TARGET_EXTERNAL_INPUTS[dir] ?? []).some((file) => changed.has(file));
46545
+ return plan.targets.filter((target) => touches(target.path) || target.workspaceDeps.some(touches) || readsChangedInput(target.path) || target.workspaceDeps.some(readsChangedInput)).map((target) => target.path);
46460
46546
  }
46461
46547
  function layersOf(plan) {
46462
46548
  const paths = plan.targets.map((target) => target.path);
@@ -47259,7 +47345,7 @@ function startProgress(ctx, write = (text) => writeOutput({ stderr: text })) {
47259
47345
  }
47260
47346
 
47261
47347
  // src/main.ts
47262
- var version = "0.2.2-dev.d73d5e4";
47348
+ var version = "0.2.2-dev.f2537d2";
47263
47349
  var commands = commandTree(operations);
47264
47350
  var manual = [...workflows.map((w) => w.words), [API_WORD]];
47265
47351
  function route(argv) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deepraxis/cli",
3
- "version": "0.2.2-dev.d73d5e4",
3
+ "version": "0.2.2-dev.f2537d2",
4
4
  "type": "module",
5
5
  "bin": {
6
6
  "praxis": "dist/praxis.js"