@aigne/lmstudio 1.2.1-beta → 1.74.0-beta

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 +0,0 @@
1
- export * from "./lmstudio-chat-model.js";
package/lib/cjs/index.js DELETED
@@ -1,17 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./lmstudio-chat-model.js"), exports);
@@ -1,24 +0,0 @@
1
- import { OpenAIChatModel, type OpenAIChatModelOptions } from "@aigne/openai";
2
- /**
3
- * Implementation of the ChatModel interface for LM Studio
4
- *
5
- * This model allows you to run local LLMs through LM Studio,
6
- * with an OpenAI-compatible API interface.
7
- *
8
- * Default model: 'llama-3.2-3b-instruct'
9
- *
10
- * @example
11
- * Here's how to create and use an LM Studio chat model:
12
- * {@includeCode ../test/lmstudio-chat-model.test.ts#example-lmstudio-chat-model}
13
- *
14
- * @example
15
- * Here's an example with streaming response:
16
- * {@includeCode ../test/lmstudio-chat-model.test.ts#example-lmstudio-chat-model-streaming}
17
- */
18
- export declare class LMStudioChatModel extends OpenAIChatModel {
19
- constructor(options?: OpenAIChatModelOptions);
20
- protected apiKeyEnvName: string;
21
- protected apiKeyDefault: string;
22
- protected supportsNativeStructuredOutputs: boolean;
23
- protected supportsTemperature: boolean;
24
- }
@@ -1,36 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.LMStudioChatModel = void 0;
4
- const openai_1 = require("@aigne/openai");
5
- const LM_STUDIO_DEFAULT_BASE_URL = "http://localhost:1234/v1";
6
- const LM_STUDIO_DEFAULT_CHAT_MODEL = "llama-3.2-3b-instruct";
7
- /**
8
- * Implementation of the ChatModel interface for LM Studio
9
- *
10
- * This model allows you to run local LLMs through LM Studio,
11
- * with an OpenAI-compatible API interface.
12
- *
13
- * Default model: 'llama-3.2-3b-instruct'
14
- *
15
- * @example
16
- * Here's how to create and use an LM Studio chat model:
17
- * {@includeCode ../test/lmstudio-chat-model.test.ts#example-lmstudio-chat-model}
18
- *
19
- * @example
20
- * Here's an example with streaming response:
21
- * {@includeCode ../test/lmstudio-chat-model.test.ts#example-lmstudio-chat-model-streaming}
22
- */
23
- class LMStudioChatModel extends openai_1.OpenAIChatModel {
24
- constructor(options) {
25
- super({
26
- ...options,
27
- model: options?.model || LM_STUDIO_DEFAULT_CHAT_MODEL,
28
- baseURL: options?.baseURL || process.env.LM_STUDIO_BASE_URL || LM_STUDIO_DEFAULT_BASE_URL,
29
- });
30
- }
31
- apiKeyEnvName = "LM_STUDIO_API_KEY";
32
- apiKeyDefault = "not-required";
33
- supportsNativeStructuredOutputs = false;
34
- supportsTemperature = true;
35
- }
36
- exports.LMStudioChatModel = LMStudioChatModel;
@@ -1,3 +0,0 @@
1
- {
2
- "type": "commonjs"
3
- }
@@ -1 +0,0 @@
1
- export * from "./lmstudio-chat-model.js";
@@ -1 +0,0 @@
1
- export * from "./lmstudio-chat-model.js";
package/lib/esm/index.js DELETED
@@ -1 +0,0 @@
1
- export * from "./lmstudio-chat-model.js";
@@ -1,32 +0,0 @@
1
- import { OpenAIChatModel } from "@aigne/openai";
2
- const LM_STUDIO_DEFAULT_BASE_URL = "http://localhost:1234/v1";
3
- const LM_STUDIO_DEFAULT_CHAT_MODEL = "llama-3.2-3b-instruct";
4
- /**
5
- * Implementation of the ChatModel interface for LM Studio
6
- *
7
- * This model allows you to run local LLMs through LM Studio,
8
- * with an OpenAI-compatible API interface.
9
- *
10
- * Default model: 'llama-3.2-3b-instruct'
11
- *
12
- * @example
13
- * Here's how to create and use an LM Studio chat model:
14
- * {@includeCode ../test/lmstudio-chat-model.test.ts#example-lmstudio-chat-model}
15
- *
16
- * @example
17
- * Here's an example with streaming response:
18
- * {@includeCode ../test/lmstudio-chat-model.test.ts#example-lmstudio-chat-model-streaming}
19
- */
20
- export class LMStudioChatModel extends OpenAIChatModel {
21
- constructor(options) {
22
- super({
23
- ...options,
24
- model: options?.model || LM_STUDIO_DEFAULT_CHAT_MODEL,
25
- baseURL: options?.baseURL || process.env.LM_STUDIO_BASE_URL || LM_STUDIO_DEFAULT_BASE_URL,
26
- });
27
- }
28
- apiKeyEnvName = "LM_STUDIO_API_KEY";
29
- apiKeyDefault = "not-required";
30
- supportsNativeStructuredOutputs = false;
31
- supportsTemperature = true;
32
- }
@@ -1,3 +0,0 @@
1
- {
2
- "type": "module"
3
- }