@mindstudio-ai/agent 0.1.123 → 0.1.125
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/cli.js +16 -20
- package/dist/index.js.map +1 -1
- package/dist/postinstall.js +16 -20
- package/package.json +1 -1
package/dist/postinstall.js
CHANGED
|
@@ -8422,6 +8422,12 @@ function buildReferenceDocs(data) {
|
|
|
8422
8422
|
${data.modelsSummary}
|
|
8423
8423
|
</models>
|
|
8424
8424
|
|
|
8425
|
+
<task_agent_models>
|
|
8426
|
+
Models with tool-use support \u2014 the ONLY models valid for \`runTask()\`. Live from the platform catalog, so this list is always current; if a model is not here it cannot drive a tool-use loop, whatever else it is good at.
|
|
8427
|
+
|
|
8428
|
+
${data.taskModels}
|
|
8429
|
+
</task_agent_models>
|
|
8430
|
+
|
|
8425
8431
|
<oauth_connections>
|
|
8426
8432
|
${data.connections}
|
|
8427
8433
|
</oauth_connections>
|
|
@@ -8457,7 +8463,7 @@ var init_instructions = __esm({
|
|
|
8457
8463
|
|
|
8458
8464
|
- **Manual JSON parsing from LLM output** \u2014 if they're calling generateText and then parsing the response, they probably want structured output / response format controls instead of \`JSON.parse(content)\`.
|
|
8459
8465
|
- **Sequential calls that should be batched** \u2014 multiple independent action calls (generate image + text-to-speech + search) should use \`executeStepBatch()\`. Three round trips become one.
|
|
8460
|
-
- **Building custom HTTP integrations when a connector exists** \u2014 if they're asking how to call the Slack API, Airtable API, HubSpot API, etc. via \`httpRequest\`, the answer is \`runFromConnectorRegistry\` with an existing OAuth connector. 850+ connector actions exist for this. If the user'
|
|
8466
|
+
- **Building custom HTTP integrations when a connector exists** \u2014 if they're asking how to call the Slack API, Airtable API, HubSpot API, etc. via \`httpRequest\`, the answer is \`runFromConnectorRegistry\` with an existing OAuth connector. 850+ connector actions exist for this. If the user hasn't configured the specific connection yet, that's step one \u2014 tell them to connect it on the platform's integrations settings page (don't guess or hardcode a URL).
|
|
8461
8467
|
- **Missing MindStudioError handling** \u2014 the SDK has structured errors with \`code\`, \`status\`, \`details\`. Catching generic \`Error\` loses actionable information. Always include \`MindStudioError\` handling in code examples.
|
|
8462
8468
|
- **One-at-a-time db writes when batch exists** \u2014 N sequential \`update()\` or \`push()\` calls should be a single \`db.batch()\` call. One round trip instead of N.
|
|
8463
8469
|
- **Closure variables in filter predicates** \u2014 \`Table.filter(o => o.x === input.x)\` cannot compile to SQL (JS closures aren't introspectable from outside the function), so it scans every row in the table in JS. For filters comparing to outer-scope values, use the explicit bindings form: \`Table.filter((o, $) => o.x === $.x, { x: input.x })\`. Recommend this whenever the predicate references a value from the enclosing function and the table might have more than a few hundred rows.
|
|
@@ -8517,19 +8523,7 @@ var init_instructions = __esm({
|
|
|
8517
8523
|
- Prefer using a text generation model from the recommendations above - they all support image inputs
|
|
8518
8524
|
|
|
8519
8525
|
## Task agent models
|
|
8520
|
-
When recommending models for \`runTask()\`, ONLY use
|
|
8521
|
-
|
|
8522
|
-
Anthropic: \`claude-5-sonnet\`, \`claude-5-opus\`, \`claude-4-8-opus\`, \`claude-4-7-opus\`, \`claude-4-6-opus\`, \`claude-4-6-sonnet\`, \`claude-4.5-sonnet\`, \`claude-4-5-haiku\`, \`claude-4-5-opus\`, \`claude-fable-5\`, \`claude-fable-5-1\`
|
|
8523
|
-
Google: \`gemini-3-flash\`, \`gemini-3-pro\`, \`gemini-3.1-pro\`, \`gemini-3.5-flash\`, \`gemini-3.7-flash\`, \`gemini-3.8-flash\`
|
|
8524
|
-
OpenAI: \`gpt-5-mini\`, \`gpt-5\`, \`gpt-5.1\`, \`gpt-5.2\`, \`gpt-5.5\`, \`gpt-5.6-sol\`, \`gpt-5.6-terra\`, \`gpt-5.6-luna\`, \`gpt-5.7-sol\`, \`gpt-5.7-terra\`, \`gpt-6-astra\`
|
|
8525
|
-
Grok: \`grok-build-0.1\`, \`grok-4.5\`, \`grok-4.6\`
|
|
8526
|
-
Meta: \`muse-spark-1.1\`, \`muse-spark-1.2\`, \`muse-spark-1.3\`
|
|
8527
|
-
DeepSeek: \`deepseek-v4-flash-0731\`, \`deepseek-v4-pro\`
|
|
8528
|
-
GLM: \`glm-5.2\`, \`glm-5.3\`, \`glm-5.3-flash\`
|
|
8529
|
-
Kimi: \`kimi-k2-7-code\`, \`kimi-k3\`
|
|
8530
|
-
Qwen: \`qwen3.8-27b-deepinfra\`, \`qwen3.8-2.4t-a95b-deepinfra\`
|
|
8531
|
-
MiniMax: \`minimax-m3\`
|
|
8532
|
-
|
|
8526
|
+
When recommending models for \`runTask()\`, ONLY use a model from the \`<task_agent_models>\` list in the reference above. That list is the platform's own tool-use capability data, loaded fresh each time you run \u2014 so it is never out of date, and a model missing from it cannot drive a tool-use loop no matter how capable it is otherwise. Do NOT recommend a model for \`runTask()\` from memory or from the general \`<models>\` list.
|
|
8533
8527
|
|
|
8534
8528
|
Default to \`claude-5-sonnet\` unless the user has a preference. Do NOT recommend o-series reasoning models (o3, o4) for tasks \u2014 they are optimized for reasoning, not tool-use loops. Do NOT recommend Gemini 2.x when 3.x is available.
|
|
8535
8529
|
</model_guidance>
|
|
@@ -8738,6 +8732,7 @@ async function buildSystemPrompt(agent) {
|
|
|
8738
8732
|
const modelsSummary = modelsResult.status === "fulfilled" ? modelsResult.value.models.map(
|
|
8739
8733
|
(m) => `- ${m.id} (${m.name}, type: ${m.type}${m.popularity != null ? ", popularity: " + m.popularity : ""}${m.tags ? ", tags: " + m.tags : ""})`
|
|
8740
8734
|
).join("\n") : "(Could not load models \u2014 use the listModels tool to look them up)";
|
|
8735
|
+
const taskModels = modelsResult.status === "fulfilled" ? modelsResult.value.models.filter((m) => m.supportsToolUse && m.type === "llm_chat").map((m) => `- ${m.id} (${m.name})`).join("\n") || "(The platform reported no tool-use models \u2014 use the listModels tool.)" : "(Could not load models \u2014 use the listModels tool and check supportsToolUse)";
|
|
8741
8736
|
const connections = connectionsResult.status === "fulfilled" && connectionsResult.value.connections.length > 0 ? connectionsResult.value.connections.map((c) => `- ${c.provider}: ${c.name} (id: ${c.id})`).join("\n") : "No OAuth connections configured.";
|
|
8742
8737
|
const connectorServices = connectorsResult.status === "fulfilled" ? connectorsResult.value.services.map(
|
|
8743
8738
|
(s) => `- ${s.id}: ${s.name} (${s.actions?.length ?? 0} actions)`
|
|
@@ -8745,6 +8740,7 @@ async function buildSystemPrompt(agent) {
|
|
|
8745
8740
|
const llmsContent2 = llmsResult.status === "fulfilled" ? llmsResult.value.llmsContent : "(Could not load action reference \u2014 use getActionDetails tool)";
|
|
8746
8741
|
const referenceDocs = buildReferenceDocs({
|
|
8747
8742
|
modelsSummary,
|
|
8743
|
+
taskModels,
|
|
8748
8744
|
connections,
|
|
8749
8745
|
connectorServices,
|
|
8750
8746
|
llmsContent: llmsContent2
|
|
@@ -8979,7 +8975,7 @@ async function startMcpServer(options) {
|
|
|
8979
8975
|
capabilities: { tools: {} },
|
|
8980
8976
|
serverInfo: {
|
|
8981
8977
|
name: "mindstudio-agent",
|
|
8982
|
-
version: "0.1.
|
|
8978
|
+
version: "0.1.125"
|
|
8983
8979
|
},
|
|
8984
8980
|
instructions: 'Welcome to MindStudio \u2014 a platform with 200+ AI models, 850+ third-party integrations, and pre-built agents.\n\nGetting started:\n1. Call `ask` with any question about the SDK \u2014 it knows every action, model, and connector and returns working code with real model IDs and config options. Examples: ask("generate an image with FLUX"), ask("what models support vision?"), ask("how do I send a Slack message?").\n2. Call `changeName` to set your display name \u2014 use your name or whatever your user calls you. This is how you\'ll appear in MindStudio request logs.\n3. If you have a profile picture, pass its public image URL to `changeProfilePicture`.\n4. For manual browsing, call `listActions` to discover all available actions.\n\nThen use the tools to generate text, images, video, audio, search the web, work with data sources, run agents, and more.\n\nImportant:\n- AI-powered actions (text generation, image generation, video, audio, etc.) cost money. Before running these, call `estimateActionCost` and confirm with the user before proceeding \u2014 unless they\'ve explicitly told you to go ahead.\n- Not all agents from `listAgents` are configured for API use. Do not try to run an agent just because it appears in the list \u2014 it will likely fail. Only run agents the user specifically asks you to run.'
|
|
8985
8981
|
});
|
|
@@ -9867,7 +9863,7 @@ function isNewerVersion(current, latest) {
|
|
|
9867
9863
|
return false;
|
|
9868
9864
|
}
|
|
9869
9865
|
async function checkForUpdate() {
|
|
9870
|
-
const currentVersion = "0.1.
|
|
9866
|
+
const currentVersion = "0.1.125";
|
|
9871
9867
|
if (!currentVersion) return null;
|
|
9872
9868
|
try {
|
|
9873
9869
|
const { loadConfig: loadConfig2, saveConfig: saveConfig2 } = await Promise.resolve().then(() => (init_config(), config_exports));
|
|
@@ -9896,7 +9892,7 @@ async function checkForUpdate() {
|
|
|
9896
9892
|
}
|
|
9897
9893
|
}
|
|
9898
9894
|
function printUpdateNotice(latestVersion) {
|
|
9899
|
-
const currentVersion = "0.1.
|
|
9895
|
+
const currentVersion = "0.1.125";
|
|
9900
9896
|
process.stderr.write(
|
|
9901
9897
|
`
|
|
9902
9898
|
${ansi2.cyanBright("Update available")} ${ansi2.gray(currentVersion + " \u2192")} ${ansi2.cyanBold(latestVersion)}
|
|
@@ -9909,7 +9905,7 @@ function isStandaloneBinary() {
|
|
|
9909
9905
|
return !argv1.includes("node_modules");
|
|
9910
9906
|
}
|
|
9911
9907
|
async function cmdUpdate() {
|
|
9912
|
-
const currentVersion = "0.1.
|
|
9908
|
+
const currentVersion = "0.1.125";
|
|
9913
9909
|
process.stderr.write(
|
|
9914
9910
|
` ${ansi2.gray("Current version:")} ${currentVersion}
|
|
9915
9911
|
`
|
|
@@ -10024,7 +10020,7 @@ async function cmdLogin(options) {
|
|
|
10024
10020
|
process.stderr.write("\n");
|
|
10025
10021
|
printLogo();
|
|
10026
10022
|
process.stderr.write("\n");
|
|
10027
|
-
const ver = "0.1.
|
|
10023
|
+
const ver = "0.1.125";
|
|
10028
10024
|
process.stderr.write(
|
|
10029
10025
|
` ${ansi2.bold("MindStudio Agent")} ${ver ? " " + ansi2.gray("v" + ver) : ""}
|
|
10030
10026
|
`
|
|
@@ -10335,7 +10331,7 @@ async function main() {
|
|
|
10335
10331
|
try {
|
|
10336
10332
|
if (command === "version" || command === "-v") {
|
|
10337
10333
|
process.stdout.write(
|
|
10338
|
-
"0.1.
|
|
10334
|
+
"0.1.125\n"
|
|
10339
10335
|
);
|
|
10340
10336
|
return;
|
|
10341
10337
|
}
|