@rivet-dev/agentos-core 0.0.0-nathan-binding-workspace.abc7ec9 → 0.0.0-nathan-binding-workspace.9be0a88

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.
@@ -297,7 +297,7 @@ export interface ResumeSessionOptions {
297
297
  * fallback tier arms a continuation preamble pointing the agent at it.
298
298
  */
299
299
  transcriptPath?: string;
300
- /** Working directory for the resumed agent session (default `/home/user`). */
300
+ /** Working directory for the resumed agent session (default `/workspace`). */
301
301
  cwd?: string;
302
302
  /** Environment variables to pass to the resumed agent process. */
303
303
  env?: Record<string, string>;
package/dist/agent-os.js CHANGED
@@ -4,6 +4,7 @@ import { existsSync, mkdtempSync, readdirSync, readFileSync, rmSync, statSync, w
4
4
  import { tmpdir } from "node:os";
5
5
  import { dirname, join, posix as posixPath, resolve as resolveHostPath, } from "node:path";
6
6
  import { fileURLToPath } from "node:url";
7
+ import commonSoftware from "@agentos-software/common";
7
8
  import { validateToolkits } from "./host-tools.js";
8
9
  import { zodToJsonSchema } from "./host-tools-zod.js";
9
10
  import { resolvePublishedSidecarBinary } from "./sidecar/binary.js";
@@ -367,6 +368,7 @@ const KERNEL_POSIX_BOOTSTRAP_DIRS = [
367
368
  "/media",
368
369
  "/home",
369
370
  "/home/user",
371
+ "/workspace",
370
372
  "/usr",
371
373
  "/usr/bin",
372
374
  "/usr/games",
@@ -1430,7 +1432,10 @@ export class AgentOs {
1430
1432
  return getSharedAgentOsSidecarInternal(options);
1431
1433
  }
1432
1434
  static async create(options) {
1433
- const processed = processSoftware(options?.software ?? []);
1435
+ const software = options?.defaultSoftware === false
1436
+ ? (options.software ?? [])
1437
+ : [commonSoftware, ...(options?.software ?? [])];
1438
+ const processed = processSoftware(software);
1434
1439
  const localMounts = await resolveCompatLocalMounts(options?.mounts);
1435
1440
  const toolKits = options?.toolKits;
1436
1441
  if (toolKits && toolKits.length > 0) {
@@ -1544,7 +1549,7 @@ export class AgentOs {
1544
1549
  session,
1545
1550
  vm: nativeVm,
1546
1551
  env,
1547
- cwd: "/home/user",
1552
+ cwd: "/workspace",
1548
1553
  localMounts,
1549
1554
  commandGuestPaths,
1550
1555
  onDispose: cleanup,
@@ -2524,7 +2529,7 @@ export class AgentOs {
2524
2529
  // skipOsInstructions plus the agent's static launch args and env.
2525
2530
  const launchArgs = [...(config.launchArgs ?? [])];
2526
2531
  let launchEnv = { ...config.defaultEnv, ...options?.env };
2527
- const sessionCwd = options?.cwd ?? "/home/user";
2532
+ const sessionCwd = options?.cwd ?? "/workspace";
2528
2533
  const adapterEntrypoint = this._resolveAdapterBin(config.acpAdapter);
2529
2534
  if ((agentType === "pi" || agentType === "pi-cli") &&
2530
2535
  !launchEnv.PI_ACP_PI_COMMAND) {
@@ -2602,7 +2607,7 @@ export class AgentOs {
2602
2607
  }
2603
2608
  const adapterEntrypoint = this._resolveAdapterBin(config.acpAdapter);
2604
2609
  let launchEnv = { ...config.defaultEnv, ...options?.env };
2605
- const sessionCwd = options?.cwd ?? "/home/user";
2610
+ const sessionCwd = options?.cwd ?? "/workspace";
2606
2611
  if ((agentType === "pi" || agentType === "pi-cli") &&
2607
2612
  !launchEnv.PI_ACP_PI_COMMAND) {
2608
2613
  launchEnv = {
@@ -37,6 +37,7 @@ const KERNEL_POSIX_BOOTSTRAP_DIRS = [
37
37
  "/media",
38
38
  "/home",
39
39
  "/home/user",
40
+ "/workspace",
40
41
  "/usr",
41
42
  "/usr/bin",
42
43
  "/usr/games",
@@ -1632,7 +1633,7 @@ class NativeKernel {
1632
1633
  constructor(options) {
1633
1634
  this.options = options;
1634
1635
  this.env = { ...(options.env ?? {}) };
1635
- this.cwd = options.cwd ?? "/home/user";
1636
+ this.cwd = options.cwd ?? "/workspace";
1636
1637
  this.socketTable = {
1637
1638
  hasHostNetworkAdapter: () => Boolean(options.hostNetworkAdapter),
1638
1639
  findListener: (request) => this.proxy?.findListener(request) ?? null,
@@ -1987,7 +1988,7 @@ class NativeKernel {
1987
1988
  vm,
1988
1989
  env: this.env,
1989
1990
  cwd: this.cwd,
1990
- defaultExecCwd: this.options.cwd === undefined ? "/home/user" : this.cwd,
1991
+ defaultExecCwd: this.options.cwd === undefined ? "/workspace" : this.cwd,
1991
1992
  localMounts: this.pendingLocalMounts,
1992
1993
  commandGuestPaths: new Map(),
1993
1994
  onWasmCommandResolved: (command) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rivet-dev/agentos-core",
3
- "version": "0.0.0-nathan-binding-workspace.abc7ec9",
3
+ "version": "0.0.0-nathan-binding-workspace.9be0a88",
4
4
  "type": "module",
5
5
  "license": "Apache-2.0",
6
6
  "main": "./dist/index.js",
@@ -56,7 +56,7 @@
56
56
  "dependencies": {
57
57
  "@agentos-software/common": "0.3.0-rc.2",
58
58
  "@aws-sdk/client-s3": "^3.1019.0",
59
- "@rivet-dev/agentos-sidecar": "0.0.0-nathan-binding-workspace.abc7ec9",
59
+ "@rivet-dev/agentos-sidecar": "0.0.0-nathan-binding-workspace.9be0a88",
60
60
  "@rivetkit/bare-ts": "^0.6.2",
61
61
  "@secure-exec/core": "0.0.0-nathan-workspace-binding-agentos.83db3e3",
62
62
  "@xterm/headless": "^6.0.0",