@mindstudio-ai/agent 0.1.32 → 0.1.34
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 +15 -10
- package/dist/index.js +1133 -1129
- package/dist/index.js.map +1 -1
- package/dist/postinstall.js +15 -10
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -3295,6 +3295,10 @@ __export(client_exports, {
|
|
|
3295
3295
|
function sleep2(ms) {
|
|
3296
3296
|
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
3297
3297
|
}
|
|
3298
|
+
function resolveStepType(name) {
|
|
3299
|
+
const meta = stepMetadata[name];
|
|
3300
|
+
return meta ? meta.stepType : name;
|
|
3301
|
+
}
|
|
3298
3302
|
function resolveToken(provided, config) {
|
|
3299
3303
|
if (process.env.CALLBACK_TOKEN)
|
|
3300
3304
|
return { token: process.env.CALLBACK_TOKEN, authType: "internal" };
|
|
@@ -3320,6 +3324,7 @@ var init_client = __esm({
|
|
|
3320
3324
|
init_auth();
|
|
3321
3325
|
init_db();
|
|
3322
3326
|
init_steps();
|
|
3327
|
+
init_metadata();
|
|
3323
3328
|
DEFAULT_BASE_URL = "https://v1.mindstudio-api.com";
|
|
3324
3329
|
DEFAULT_MAX_RETRIES = 3;
|
|
3325
3330
|
MindStudioAgent = class {
|
|
@@ -3616,7 +3621,7 @@ var init_client = __esm({
|
|
|
3616
3621
|
async executeStepBatch(steps, options) {
|
|
3617
3622
|
const threadId = options?.threadId ?? (this._reuseThreadId ? this._threadId : void 0);
|
|
3618
3623
|
const { data } = await request(this._httpConfig, "POST", "/steps/execute-batch", {
|
|
3619
|
-
steps,
|
|
3624
|
+
steps: steps.map((s) => ({ ...s, stepType: resolveStepType(s.stepType) })),
|
|
3620
3625
|
...options?.appId != null && { appId: options.appId },
|
|
3621
3626
|
...threadId != null && { threadId }
|
|
3622
3627
|
});
|
|
@@ -3849,7 +3854,7 @@ var init_client = __esm({
|
|
|
3849
3854
|
/** Estimate the cost of executing an action before running it. */
|
|
3850
3855
|
async estimateStepCost(stepType, step, options) {
|
|
3851
3856
|
const { data } = await request(this._httpConfig, "POST", "/helpers/step-cost-estimate", {
|
|
3852
|
-
step: { type: stepType, ...step },
|
|
3857
|
+
step: { type: resolveStepType(stepType), ...step },
|
|
3853
3858
|
...options
|
|
3854
3859
|
});
|
|
3855
3860
|
return data;
|
|
@@ -4570,7 +4575,7 @@ var init_instructions = __esm({
|
|
|
4570
4575
|
- **Never rank vendors** or claim one provider is better than another. Popularity reflects usage patterns, not quality judgments. Present options with their model IDs and let the caller choose. Never make assumptions about the capabilities of models, or suggest that a certain model is "good" at a specific task or better/worse than another at a task.
|
|
4571
4576
|
- **Prefer popular models as defaults** in code examples unless the caller has a reason to use something specific.
|
|
4572
4577
|
- **Always recommend latest-generation models**: For Anthropic, this is Claude 4 family, GPT-5 for OpenAI, Gemini 3 for Google, etc. MindStudio supports a ton of different models, including legacy models - but they are there for niche uses or backward compatibility/existing user requirements - they should NOT be used for new projects.
|
|
4573
|
-
- Use the names of model input objects to infer capabilities. For example, any image generation model that supports source images in its config supports "remixing" or "image editing". Any video model with a start and end frame option supports creating "looping" videos.
|
|
4578
|
+
- Use the names of model input objects to infer capabilities. For example, any image generation model that supports source images in its config supports "remixing" or "image editing". Any video model with a start and end frame option supports creating "looping" videos. Do not look at model tags or descriptions to determine capabilities.
|
|
4574
4579
|
|
|
4575
4580
|
## Explicit preferences
|
|
4576
4581
|
MindStudio has hundreds of models. Many of them are for niche use cases. In general, prefer to recommend the following models unless the user specifies otherwise.
|
|
@@ -4578,7 +4583,7 @@ var init_instructions = __esm({
|
|
|
4578
4583
|
Text generation:
|
|
4579
4584
|
- Google Gemini, Anthropic Claude, OpenAI GPT
|
|
4580
4585
|
Image generation:
|
|
4581
|
-
- Seedream 4.5, Google Gemini 3.1 Flash Image (Nano Banana Pro)
|
|
4586
|
+
- Seedream 4.5, Google Gemini 3.1 Flash Image (Nano Banana Pro). Never recommend things like Flux 1 or other models that have been superseded by later generations from the same provider.
|
|
4582
4587
|
Video generation:
|
|
4583
4588
|
- Grok Imagine, Kling O3, Google Veo 3.1
|
|
4584
4589
|
Text to speech:
|
|
@@ -4880,7 +4885,7 @@ async function startMcpServer(options) {
|
|
|
4880
4885
|
capabilities: { tools: {} },
|
|
4881
4886
|
serverInfo: {
|
|
4882
4887
|
name: "mindstudio-agent",
|
|
4883
|
-
version: "0.1.
|
|
4888
|
+
version: "0.1.34"
|
|
4884
4889
|
},
|
|
4885
4890
|
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 or icon, call `uploadFile` to upload it, then `changeProfilePicture` with the returned URL.\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.'
|
|
4886
4891
|
});
|
|
@@ -5836,7 +5841,7 @@ function isNewerVersion(current, latest) {
|
|
|
5836
5841
|
return false;
|
|
5837
5842
|
}
|
|
5838
5843
|
async function checkForUpdate() {
|
|
5839
|
-
const currentVersion = "0.1.
|
|
5844
|
+
const currentVersion = "0.1.34";
|
|
5840
5845
|
if (!currentVersion) return null;
|
|
5841
5846
|
try {
|
|
5842
5847
|
const { loadConfig: loadConfig2, saveConfig: saveConfig2 } = await Promise.resolve().then(() => (init_config(), config_exports));
|
|
@@ -5865,7 +5870,7 @@ async function checkForUpdate() {
|
|
|
5865
5870
|
}
|
|
5866
5871
|
}
|
|
5867
5872
|
function printUpdateNotice(latestVersion) {
|
|
5868
|
-
const currentVersion = "0.1.
|
|
5873
|
+
const currentVersion = "0.1.34";
|
|
5869
5874
|
process.stderr.write(
|
|
5870
5875
|
`
|
|
5871
5876
|
${ansi2.cyanBright("Update available")} ${ansi2.gray(currentVersion + " \u2192")} ${ansi2.cyanBold(latestVersion)}
|
|
@@ -5878,7 +5883,7 @@ function isStandaloneBinary() {
|
|
|
5878
5883
|
return !argv1.includes("node_modules");
|
|
5879
5884
|
}
|
|
5880
5885
|
async function cmdUpdate() {
|
|
5881
|
-
const currentVersion = "0.1.
|
|
5886
|
+
const currentVersion = "0.1.34";
|
|
5882
5887
|
process.stderr.write(
|
|
5883
5888
|
` ${ansi2.gray("Current version:")} ${currentVersion}
|
|
5884
5889
|
`
|
|
@@ -6013,7 +6018,7 @@ async function cmdLogin(options) {
|
|
|
6013
6018
|
process.stderr.write("\n");
|
|
6014
6019
|
printLogo();
|
|
6015
6020
|
process.stderr.write("\n");
|
|
6016
|
-
const ver = "0.1.
|
|
6021
|
+
const ver = "0.1.34";
|
|
6017
6022
|
process.stderr.write(
|
|
6018
6023
|
` ${ansi2.bold("MindStudio Agent")} ${ver ? " " + ansi2.gray("v" + ver) : ""}
|
|
6019
6024
|
`
|
|
@@ -6340,7 +6345,7 @@ async function main() {
|
|
|
6340
6345
|
try {
|
|
6341
6346
|
if (command === "version" || command === "-v") {
|
|
6342
6347
|
process.stdout.write(
|
|
6343
|
-
"0.1.
|
|
6348
|
+
"0.1.34\n"
|
|
6344
6349
|
);
|
|
6345
6350
|
return;
|
|
6346
6351
|
}
|