diff options
| author | Dax Raad <[email protected]> | 2025-06-05 13:33:14 -0400 |
|---|---|---|
| committer | Dax Raad <[email protected]> | 2025-06-05 13:51:18 -0400 |
| commit | 299a74061a46f5eb14d459b561f42d85fd359a18 (patch) | |
| tree | 4ada49f626ca9adabc336cad92457b2fef44e4c9 /packages | |
| parent | e3d5af28559bcbc38b4e531c509692ed29183808 (diff) | |
| download | opencode-299a74061a46f5eb14d459b561f42d85fd359a18.tar.gz opencode-299a74061a46f5eb14d459b561f42d85fd359a18.zip | |
sync
Diffstat (limited to 'packages')
| -rw-r--r-- | packages/opencode/src/config/config.ts | 1 | ||||
| -rw-r--r-- | packages/opencode/src/session/index.ts | 23 |
2 files changed, 13 insertions, 11 deletions
diff --git a/packages/opencode/src/config/config.ts b/packages/opencode/src/config/config.ts index 4079c971e..53a253cdc 100644 --- a/packages/opencode/src/config/config.ts +++ b/packages/opencode/src/config/config.ts @@ -57,6 +57,7 @@ export namespace Config { }) .optional(), mcp: z.record(z.string(), Mcp).optional(), + models: z.record(z.string(), Provider.Model.array()).optional(), }) .strict() diff --git a/packages/opencode/src/session/index.ts b/packages/opencode/src/session/index.ts index b33993e1c..0d3990814 100644 --- a/packages/opencode/src/session/index.ts +++ b/packages/opencode/src/session/index.ts @@ -239,17 +239,18 @@ export namespace Session { }, { type: "text", - text: `Here is some useful information about the environment you are running in: -<env> -Working directory: ${app.path.cwd} -Is directory a git repo: ${app.git ? "yes" : "no"} -Platform: ${process.platform} -Today's date: ${new Date().toISOString()} -</env> -<project> -${app.git ? await ListTool.execute({ path: app.path.cwd }, { sessionID: input.sessionID }).then((x) => x.output) : ""} -</project> - `, + text: [ + `Here is some useful information about the environment you are running in:`, + `<env>`, + `Working directory: ${app.path.cwd}`, + `Is directory a git repo: ${app.git ? "yes" : "no"}`, + `Platform: ${process.platform}`, + `Today's date: ${new Date().toISOString()}`, + `</env>`, + `<project>`, + `${app.git ? await ListTool.execute({ path: app.path.cwd }, { sessionID: input.sessionID }).then((x) => x.output) : ""}`, + `</project>`, + ].join("\n"), }, ], metadata: { |
