memeloop 0.2.2 → 0.2.3
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.
- package/dist/{chunk-K6P63KD4.js → chunk-HY3U3GLE.js} +16 -4
- package/dist/chunk-HY3U3GLE.js.map +1 -0
- package/dist/{fetchProvider-BhqRqi5-.d.ts → fetchProvider-B_vva3b3.d.ts} +26 -2
- package/dist/{fetchProvider-HJ_FkORN.d.cts → fetchProvider-Bz4CE3_R.d.cts} +26 -2
- package/dist/index.cjs +16 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/llm-providers.cjs +17 -6
- package/dist/llm-providers.cjs.map +1 -1
- package/dist/llm-providers.d.cts +2 -0
- package/dist/llm-providers.d.ts +2 -0
- package/dist/llm-providers.js +4 -4
- package/dist/llm-providers.js.map +1 -1
- package/dist/loop-api.cjs +16 -3
- package/dist/loop-api.cjs.map +1 -1
- package/dist/loop-api.d.cts +1 -1
- package/dist/loop-api.d.ts +1 -1
- package/dist/loop-api.js +4 -2
- package/dist/mobile.cjs +14 -3
- package/dist/mobile.cjs.map +1 -1
- package/dist/mobile.d.cts +1 -1
- package/dist/mobile.d.ts +1 -1
- package/dist/mobile.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-K6P63KD4.js.map +0 -1
package/dist/loop-api.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { A as AGENT_AGENT_LOOP_ID, a as AGENT_TOOL_LOOP_ID, b as AgentAgentBatchRunInput, c as AgentAgentBatchRunResult, d as AgentAgentConfigEntry, e as AgentAgentContext, f as AgentAgentDescriptor, g as AgentAgentFormatResultsOptions, h as AgentAgentLoopContext, i as AgentAgentLoopScript, j as AgentAgentLoopScriptArguments, k as AgentAgentLoopScriptReference, l as AgentAgentRunAgentFailure, m as AgentAgentRunAgentInput, n as AgentAgentRunAgentResult, o as AgentAgentScriptContext, p as AgentToolLoopContext, q as AgentToolLoopIterationGenerator, r as AgentToolLoopIterationResult, s as AgentToolLoopScript, t as AgentToolLoopScriptContext, u as AgentToolLoopScriptReference, v as AgentToolLoopState, w as AgentToolLoopTurnStartResult, B as BUILTIN_AGENT_AGENT_LOOP_ARTIFACT_RESOURCE_LIFECYCLE_SCRIPT_ID, x as BUILTIN_AGENT_AGENT_LOOP_DECLARATIVE_AGENT_RUN_SCRIPT_ID, y as BUILTIN_AGENT_AGENT_LOOP_QUALITY_GATE_SCRIPT_ID, z as BUILTIN_AGENT_TOOL_LOOP_DEFAULT_SCRIPT_ID, C as BUILTIN_TOOL_PLUGIN_IDS, D as CompactionOptions, E as CompactionResult, H as HookRegistry, L as LoadAgentAgentLoopScriptOptions, F as LoadAgentToolLoopScriptOptions, G as LoopRegistryImpl, P as PLUGIN_ASK_QUESTION, I as PLUGIN_ASK_USER_QUESTION, J as PLUGIN_MCP_CLIENT, K as PLUGIN_MCP_FORWARD, M as PLUGIN_ORCHESTRATION, N as PLUGIN_REMOTE_AGENT, O as PLUGIN_SPAWN_AGENT, Q as PLUGIN_TASK, R as PLUGIN_TODO_WRITE, S as PromptConcatPluginPreview, T as PromptConcatStreamState, U as TokenTracker, V as autoCompact, W as builtinAgentAgentLoopSources, X as builtinAgentToolLoopSources, Y as clearHooks, Z as compactMessages, _ as createAgentAgentLoopDefinition, $ as createAgentToolLoopDefinition, a0 as createAgentToolLoopRunner, a1 as executeHooks, a2 as findPromptById, a3 as flattenPrompts, a4 as getAgentAgentLoopId, a5 as getBuiltinAgentAgentLoopSource, a6 as getBuiltinAgentToolLoopSource, a7 as getBuiltinToolPlugins, a8 as getDefaultHookRegistry, a9 as getHookCount, aa as getLoopRegistry, ab as hasHooks, ac as listRegisteredHookTypes, ad as loadAgentAgentLoopScript, ae as loadAgentToolLoopScript, af as promptConcatStream, ag as registerBuiltinLoops, ah as registerBuiltinPromptPlugins, ai as registerBuiltinToolPlugins, aj as registerHook, ak as resetLoopRegistry, al as shouldCompact, am as unregisterHook } from './promptConcat-VLe5SEN4.cjs';
|
|
2
|
-
export { F as FetchLLMProviderConfig, R as RunAgentToolLoopTurnCallbacks, a as RunAgentToolLoopTurnResult, c as createFetchLLMProvider, g as getBuiltinLoopProfile, b as getBuiltinLoopProfiles,
|
|
2
|
+
export { F as FetchLLMChatRequest, e as FetchLLMProviderConfig, R as RunAgentToolLoopTurnCallbacks, a as RunAgentToolLoopTurnResult, c as createFetchLLMProvider, g as getBuiltinLoopProfile, b as getBuiltinLoopProfiles, f as registerBuiltinLoopProfiles, r as resolveAgentToolLoopTerminalState, h as resolveFetchLLMCallSettings, d as runAgentToolLoopTurn } from './fetchProvider-Bz4CE3_R.cjs';
|
|
3
3
|
export { A as ALL_CATEGORIES, a as AgentProfileRegistry, b as AgentStartData, c as AgentStopData, C as CategoryConfig, d as ContextCompactionData, e as CreateAgentLoopRunnerOptions, f as CreateAgentOptions, H as HookContext, g as HookHandler, h as HookResult, i as HookType, L as LoadPluginModuleOptions, j as LoadedPlugin, M as MemeLoopRuntime, k as MergedPermissions, P as PERMISSIONS_TABLE_DDL, l as PermissionAction, m as PermissionRule, n as PermissionSet, o as PermissionSqlDatabase, p as PermissionSqlStatement, q as PluginAPI, r as PluginAPIOptions, s as PluginExports, t as PluginManifest, u as PluginModule, v as PostToolUseData, w as PreToolUseData, S as SendMessageOptions, T as TaskCategory, U as UserPromptSubmitData, x as checkPermission, y as clearPluginRegistrations, z as createAgentLoopRunner, B as createAgentLoopScriptRunner, D as createAgentProfileRunner, E as createMemeLoopRuntime, F as createPluginAPI, G as getAgentProfileRegistry, I as getCategoryConfig, J as getLoadedPlugin, K as getPluginRegistrations, N as isPluginLoaded, O as isTaskCategory, Q as listPlugins, R as loadPluginModule, V as loadPluginModules, W as loadUserPermissions, X as matchPattern, Y as mergePermissionSets, Z as registerPluginHooks, _ as registerPluginTools, $ as resetAgentProfileRegistry, a0 as resolveCategory, a1 as saveUserPermissions, a2 as unloadAllPlugins, a3 as unloadPlugin, a4 as validatePluginManifest } from './registry-DNSEVYug.cjs';
|
|
4
4
|
export { A as AgentFrameworkContext, a as AgentInstance, b as AgentInstanceLatestStatus, a as AgentInstanceModel, c as AgentInstanceState, d as AgentLoopDefinition, e as AgentLoopGenerator, f as AgentLoopInput, g as AgentLoopRuntime, h as AgentLoopScriptPolicy, i as AgentLoopStep, j as AgentToolLoopOptions, I as IChatSyncAdapter, k as ILLMProvider, l as INetworkService, m as IToolRegistry, L as LoopPlugin, n as LoopProfile, o as LoopProfilePluginEntry, p as LoopProfilePrompt, q as LoopProfileScriptReference, r as LoopScriptCheckpointStore, M as MemeLoopLogger, S as ScriptLoadGate, s as ScriptLoadGateDecision, t as ScriptLoadGateRequest, T as TOOL_PARAMETER_PARSE_ERROR_KEY, w as ToolCallingMatch, x as matchAllToolCallings, y as matchToolCalling } from './scriptDeploymentPipeline-XJzQyYys.cjs';
|
|
5
5
|
export { A as AgentProfile, a as AgentProfileType, B as BUILTIN_AGENT_PROFILES, P as ProviderConfig, b as ProviderRegistry, R as RegisteredProvider, T as ToolPermissionRules, c as buildAgent, e as exploreAgent, l as librarianAgent, o as oracleAgent, p as planAgent } from './providerRegistry-BDGGs5gz.cjs';
|
package/dist/loop-api.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { A as AGENT_AGENT_LOOP_ID, a as AGENT_TOOL_LOOP_ID, b as AgentAgentBatchRunInput, c as AgentAgentBatchRunResult, d as AgentAgentConfigEntry, e as AgentAgentContext, f as AgentAgentDescriptor, g as AgentAgentFormatResultsOptions, h as AgentAgentLoopContext, i as AgentAgentLoopScript, j as AgentAgentLoopScriptArguments, k as AgentAgentLoopScriptReference, l as AgentAgentRunAgentFailure, m as AgentAgentRunAgentInput, n as AgentAgentRunAgentResult, o as AgentAgentScriptContext, p as AgentToolLoopContext, q as AgentToolLoopIterationGenerator, r as AgentToolLoopIterationResult, s as AgentToolLoopScript, t as AgentToolLoopScriptContext, u as AgentToolLoopScriptReference, v as AgentToolLoopState, w as AgentToolLoopTurnStartResult, B as BUILTIN_AGENT_AGENT_LOOP_ARTIFACT_RESOURCE_LIFECYCLE_SCRIPT_ID, x as BUILTIN_AGENT_AGENT_LOOP_DECLARATIVE_AGENT_RUN_SCRIPT_ID, y as BUILTIN_AGENT_AGENT_LOOP_QUALITY_GATE_SCRIPT_ID, z as BUILTIN_AGENT_TOOL_LOOP_DEFAULT_SCRIPT_ID, C as BUILTIN_TOOL_PLUGIN_IDS, D as CompactionOptions, E as CompactionResult, H as HookRegistry, L as LoadAgentAgentLoopScriptOptions, F as LoadAgentToolLoopScriptOptions, G as LoopRegistryImpl, P as PLUGIN_ASK_QUESTION, I as PLUGIN_ASK_USER_QUESTION, J as PLUGIN_MCP_CLIENT, K as PLUGIN_MCP_FORWARD, M as PLUGIN_ORCHESTRATION, N as PLUGIN_REMOTE_AGENT, O as PLUGIN_SPAWN_AGENT, Q as PLUGIN_TASK, R as PLUGIN_TODO_WRITE, S as PromptConcatPluginPreview, T as PromptConcatStreamState, U as TokenTracker, V as autoCompact, W as builtinAgentAgentLoopSources, X as builtinAgentToolLoopSources, Y as clearHooks, Z as compactMessages, _ as createAgentAgentLoopDefinition, $ as createAgentToolLoopDefinition, a0 as createAgentToolLoopRunner, a1 as executeHooks, a2 as findPromptById, a3 as flattenPrompts, a4 as getAgentAgentLoopId, a5 as getBuiltinAgentAgentLoopSource, a6 as getBuiltinAgentToolLoopSource, a7 as getBuiltinToolPlugins, a8 as getDefaultHookRegistry, a9 as getHookCount, aa as getLoopRegistry, ab as hasHooks, ac as listRegisteredHookTypes, ad as loadAgentAgentLoopScript, ae as loadAgentToolLoopScript, af as promptConcatStream, ag as registerBuiltinLoops, ah as registerBuiltinPromptPlugins, ai as registerBuiltinToolPlugins, aj as registerHook, ak as resetLoopRegistry, al as shouldCompact, am as unregisterHook } from './promptConcat-CUEIA_3T.js';
|
|
2
|
-
export { F as FetchLLMProviderConfig, R as RunAgentToolLoopTurnCallbacks, a as RunAgentToolLoopTurnResult, c as createFetchLLMProvider, g as getBuiltinLoopProfile, b as getBuiltinLoopProfiles,
|
|
2
|
+
export { F as FetchLLMChatRequest, e as FetchLLMProviderConfig, R as RunAgentToolLoopTurnCallbacks, a as RunAgentToolLoopTurnResult, c as createFetchLLMProvider, g as getBuiltinLoopProfile, b as getBuiltinLoopProfiles, f as registerBuiltinLoopProfiles, r as resolveAgentToolLoopTerminalState, h as resolveFetchLLMCallSettings, d as runAgentToolLoopTurn } from './fetchProvider-B_vva3b3.js';
|
|
3
3
|
export { A as ALL_CATEGORIES, a as AgentProfileRegistry, b as AgentStartData, c as AgentStopData, C as CategoryConfig, d as ContextCompactionData, e as CreateAgentLoopRunnerOptions, f as CreateAgentOptions, H as HookContext, g as HookHandler, h as HookResult, i as HookType, L as LoadPluginModuleOptions, j as LoadedPlugin, M as MemeLoopRuntime, k as MergedPermissions, P as PERMISSIONS_TABLE_DDL, l as PermissionAction, m as PermissionRule, n as PermissionSet, o as PermissionSqlDatabase, p as PermissionSqlStatement, q as PluginAPI, r as PluginAPIOptions, s as PluginExports, t as PluginManifest, u as PluginModule, v as PostToolUseData, w as PreToolUseData, S as SendMessageOptions, T as TaskCategory, U as UserPromptSubmitData, x as checkPermission, y as clearPluginRegistrations, z as createAgentLoopRunner, B as createAgentLoopScriptRunner, D as createAgentProfileRunner, E as createMemeLoopRuntime, F as createPluginAPI, G as getAgentProfileRegistry, I as getCategoryConfig, J as getLoadedPlugin, K as getPluginRegistrations, N as isPluginLoaded, O as isTaskCategory, Q as listPlugins, R as loadPluginModule, V as loadPluginModules, W as loadUserPermissions, X as matchPattern, Y as mergePermissionSets, Z as registerPluginHooks, _ as registerPluginTools, $ as resetAgentProfileRegistry, a0 as resolveCategory, a1 as saveUserPermissions, a2 as unloadAllPlugins, a3 as unloadPlugin, a4 as validatePluginManifest } from './registry-yGnYHWhq.js';
|
|
4
4
|
export { A as AgentFrameworkContext, a as AgentInstance, b as AgentInstanceLatestStatus, a as AgentInstanceModel, c as AgentInstanceState, d as AgentLoopDefinition, e as AgentLoopGenerator, f as AgentLoopInput, g as AgentLoopRuntime, h as AgentLoopScriptPolicy, i as AgentLoopStep, j as AgentToolLoopOptions, I as IChatSyncAdapter, k as ILLMProvider, l as INetworkService, m as IToolRegistry, L as LoopPlugin, n as LoopProfile, o as LoopProfilePluginEntry, p as LoopProfilePrompt, q as LoopProfileScriptReference, r as LoopScriptCheckpointStore, M as MemeLoopLogger, S as ScriptLoadGate, s as ScriptLoadGateDecision, t as ScriptLoadGateRequest, T as TOOL_PARAMETER_PARSE_ERROR_KEY, w as ToolCallingMatch, x as matchAllToolCallings, y as matchToolCalling } from './scriptDeploymentPipeline-B1q-UhrO.js';
|
|
5
5
|
export { A as AgentProfile, a as AgentProfileType, B as BUILTIN_AGENT_PROFILES, P as ProviderConfig, b as ProviderRegistry, R as RegisteredProvider, T as ToolPermissionRules, c as buildAgent, e as exploreAgent, l as librarianAgent, o as oracleAgent, p as planAgent } from './providerRegistry-CaFK_aUd.js';
|
package/dist/loop-api.js
CHANGED
|
@@ -74,8 +74,9 @@ import {
|
|
|
74
74
|
runAgentToolLoopTurn
|
|
75
75
|
} from "./chunk-K5KZJNDP.js";
|
|
76
76
|
import {
|
|
77
|
-
createFetchLLMProvider
|
|
78
|
-
|
|
77
|
+
createFetchLLMProvider,
|
|
78
|
+
resolveFetchLLMCallSettings
|
|
79
|
+
} from "./chunk-HY3U3GLE.js";
|
|
79
80
|
import {
|
|
80
81
|
HookRegistry,
|
|
81
82
|
TOOL_PARAMETER_PARSE_ERROR_KEY,
|
|
@@ -215,6 +216,7 @@ export {
|
|
|
215
216
|
resetLoopRegistry,
|
|
216
217
|
resolveAgentToolLoopTerminalState,
|
|
217
218
|
resolveCategory,
|
|
219
|
+
resolveFetchLLMCallSettings,
|
|
218
220
|
runAgentToolLoopTurn,
|
|
219
221
|
saveUserPermissions,
|
|
220
222
|
shouldCompact,
|
package/dist/mobile.cjs
CHANGED
|
@@ -40,6 +40,15 @@ module.exports = __toCommonJS(mobile_exports);
|
|
|
40
40
|
|
|
41
41
|
// src/llm/fetchProvider.ts
|
|
42
42
|
var import_ai = require("ai");
|
|
43
|
+
function resolveFetchLLMCallSettings(body) {
|
|
44
|
+
return {
|
|
45
|
+
maxOutputTokens: body.maxOutputTokens ?? body.max_tokens,
|
|
46
|
+
temperature: body.temperature,
|
|
47
|
+
topP: body.topP,
|
|
48
|
+
providerOptions: body.providerOptions,
|
|
49
|
+
abortSignal: body.abortSignal
|
|
50
|
+
};
|
|
51
|
+
}
|
|
43
52
|
function createFetchLLMProvider(config) {
|
|
44
53
|
return {
|
|
45
54
|
name: config.name,
|
|
@@ -64,9 +73,7 @@ function createFetchLLMProvider(config) {
|
|
|
64
73
|
};
|
|
65
74
|
});
|
|
66
75
|
const system = body.system ?? (systemMessages.length > 0 ? systemMessages.join("\n\n") : void 0);
|
|
67
|
-
const temperature = body
|
|
68
|
-
const abortSignal = body.abortSignal;
|
|
69
|
-
const maxOutputTokens = body.max_tokens;
|
|
76
|
+
const { abortSignal, maxOutputTokens, providerOptions, temperature, topP } = resolveFetchLLMCallSettings(body);
|
|
70
77
|
if (body.stream !== false) {
|
|
71
78
|
let streamingError;
|
|
72
79
|
const result2 = (0, import_ai.streamText)({
|
|
@@ -75,6 +82,8 @@ function createFetchLLMProvider(config) {
|
|
|
75
82
|
messages,
|
|
76
83
|
maxOutputTokens,
|
|
77
84
|
temperature,
|
|
85
|
+
topP,
|
|
86
|
+
providerOptions,
|
|
78
87
|
abortSignal,
|
|
79
88
|
onError: ({ error }) => {
|
|
80
89
|
streamingError = error;
|
|
@@ -95,6 +104,8 @@ function createFetchLLMProvider(config) {
|
|
|
95
104
|
messages,
|
|
96
105
|
maxOutputTokens,
|
|
97
106
|
temperature,
|
|
107
|
+
topP,
|
|
108
|
+
providerOptions,
|
|
98
109
|
abortSignal
|
|
99
110
|
});
|
|
100
111
|
return result.text;
|