@opencode-ai/server 0.0.0-dev-18212 → 0.0.0-dev-18215

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.
@@ -1,5 +1,6 @@
1
1
  import { Session } from "@opencode-ai/core/session";
2
2
  import { SessionStats } from "@opencode-ai/core/session/stats";
3
+ import { SessionTitle } from "@opencode-ai/core/session/title";
3
4
  import { SessionTransfer } from "@opencode-ai/core/session/transfer";
4
5
  import { InstructionEntry } from "@opencode-ai/core/session/instruction-entry";
5
6
  import { DateTime, Effect, Stream } from "effect";
@@ -125,7 +126,11 @@ export const SessionHandler = HttpApiBuilder.group(Api, "server.session", (handl
125
126
  yield* session.switchModel({ sessionID: ctx.params.sessionID, model: ctx.payload.model }).pipe(Effect.catchTag("Session.NotFoundError", missingSession));
126
127
  return HttpApiSchema.NoContent.make();
127
128
  })).handle("session.rename", Effect.fn(function* (ctx) {
128
- yield* session.rename({ sessionID: ctx.params.sessionID, title: ctx.payload.title }).pipe(Effect.catchTag("Session.NotFoundError", missingSession));
129
+ if (ctx.payload.title) {
130
+ yield* session.rename({ sessionID: ctx.params.sessionID, title: ctx.payload.title }).pipe(Effect.catchTag("Session.NotFoundError", missingSession));
131
+ return HttpApiSchema.NoContent.make();
132
+ }
133
+ yield* (yield* SessionTitle.Service).generate(ctx.params.sessionID);
129
134
  return HttpApiSchema.NoContent.make();
130
135
  })).handle("session.move", Effect.fn(function* (ctx) {
131
136
  yield* session.move({
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@opencode-ai/server",
4
- "version": "0.0.0-dev-18212",
4
+ "version": "0.0.0-dev-18215",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -30,11 +30,11 @@
30
30
  "dependencies": {
31
31
  "@effect/platform-node": "4.0.0-rc.111",
32
32
  "@effect/platform-node-shared": "4.0.0-rc.111",
33
- "@opencode-ai/core": "0.0.0-dev-18212",
34
- "@opencode-ai/protocol": "0.0.0-dev-18212",
35
- "@opencode-ai/schema": "0.0.0-dev-18212",
36
- "@opencode-ai/simulation": "0.0.0-dev-18212",
37
- "@opencode-ai/util": "0.0.0-dev-18212",
33
+ "@opencode-ai/core": "0.0.0-dev-18215",
34
+ "@opencode-ai/protocol": "0.0.0-dev-18215",
35
+ "@opencode-ai/schema": "0.0.0-dev-18215",
36
+ "@opencode-ai/simulation": "0.0.0-dev-18215",
37
+ "@opencode-ai/util": "0.0.0-dev-18215",
38
38
  "drizzle-orm": "1.0.0-rc.5-169397b",
39
39
  "effect": "4.0.0-rc.111"
40
40
  },