MCPcopy Create free account
hub / github.com/arctic-cli/interface / resolveSessionModel

Function resolveSessionModel

packages/arctic/src/session/benchmark.ts:350–357  ·  view source on GitHub ↗
(sessionID: string)

Source from the content-addressed store, hash-verified

348 }
349
350 async function resolveSessionModel(sessionID: string) {
351 const messages = await Session.messages({ sessionID })
352 const lastUser = messages.findLast((x) => x.info.role === "user")
353 if (lastUser && "model" in lastUser.info) {
354 return lastUser.info.model
355 }
356 return Provider.defaultModel()
357 }
358
359 async function isDirty() {
360 if (Instance.project.vcs !== "git") return false

Callers 1

resolveModelsFunction · 0.85

Calls 1

messagesMethod · 0.45

Tested by

no test coverage detected