mirror of
https://github.com/anomalyco/opencode.git
synced 2026-11-14 20:21:39 +03:00
fix(core): accept null context length from LM Studio models (#63198)
This commit is contained in:
committed by
GitHub
Unverified
parent
c4bf172532
commit
05b32ea324
@@ -11,7 +11,8 @@ const RemoteModel = Schema.Struct({
|
||||
config: Schema.Struct({ context_length: Schema.Int }),
|
||||
}),
|
||||
),
|
||||
max_context_length: Schema.Int,
|
||||
// Null for decision models whose context is unknown.
|
||||
max_context_length: Schema.NullOr(Schema.Int),
|
||||
capabilities: Schema.Struct({
|
||||
vision: Schema.Boolean,
|
||||
trained_for_tool_use: Schema.Boolean,
|
||||
|
||||
@@ -74,7 +74,7 @@ describe("LMStudioPlugin", () => {
|
||||
key: "clef-flash",
|
||||
display_name: "Clef Flash",
|
||||
loaded_instances: [],
|
||||
max_context_length: 262_144,
|
||||
max_context_length: null,
|
||||
},
|
||||
],
|
||||
}),
|
||||
|
||||
Reference in New Issue
Block a user