chore: generate

This commit is contained in:
opencode-agent[bot] 2026-06-05 14:49:06 +00:00
commit e9aa33d4bd
3 changed files with 11 additions and 3 deletions

View file

@ -58,7 +58,8 @@ export const Plugin = PluginV2.define({
yield* agent.update((editor) => {
const global = documents.flatMap((document) => document.info.permissions ?? [])
const configuredDefault = documents.findLast((document) => document.info.default_agent !== undefined)?.info.default_agent
const configuredDefault = documents.findLast((document) => document.info.default_agent !== undefined)?.info
.default_agent
if (configuredDefault !== undefined) editor.default(AgentV2.ID.make(configuredDefault))
for (const current of editor.list()) {
editor.update(current.id, (agent) => agent.permissions.push(...global))

View file

@ -152,7 +152,9 @@ export const layer = Layer.effect(
const context = yield* store.runnerContext(session.id, system.baselineSeq)
const request = LLM.request({
model,
system: [agent?.system, system.baseline].filter((part): part is string => part !== undefined && part.length > 0).map(SystemPart.make),
system: [agent?.system, system.baseline]
.filter((part): part is string => part !== undefined && part.length > 0)
.map(SystemPart.make),
messages: toLLMMessages(context, model),
tools: yield* tools.definitions(),
})